Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #365: Unable to retry presence check init #385

Merged
merged 1 commit into from
Sep 22, 2022

Conversation

banterCZ
Copy link
Member

  • Allow to send event PRESENCE_CHECK_INIT during PRESENCE_CHECK_IN_PROGRESS
  • Remove IProovConst
  • Add another initPresenceCheck to repeatPresenceCheckStartTest
  • Improve logging of IdentityVerification phase changes

@@ -130,6 +132,7 @@ public void checkDocumentUploadLimit(OwnerId ownerId, IdentityVerificationEntity
identityVerification.setTimestampLastUpdated(ownerId.getTimestamp());
identityVerification.setTimestampFailed(ownerId.getTimestamp());
identityVerificationRepository.save(identityVerification);
logger.info("Switched to {}/FAILED; process ID: {}", identityVerification.getPhase(), identityVerification.getProcessId());
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without extensive logging, it was difficult to debug this issue.

/**
* Session parameter name of the verification token
*/
public static final String VERIFICATION_TOKEN = "iproov-verification-token";
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Simplify namespace, there is no need to have this constant public.

@@ -317,6 +317,15 @@ private void configurePresenceCheckTransitions(StateMachineTransitionConfigurer<
.action(presenceCheckInitAction)
.target(OnboardingState.PRESENCE_CHECK_IN_PROGRESS)

.and()
.withExternal()
.source(OnboardingState.PRESENCE_CHECK_IN_PROGRESS)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The main change! Allow to send PRESENCE_CHECK_INIT event during PRESENCE_CHECK_IN_PROGRESS, respectively to call /api/identity/presence-check/init to get iProov token. cc @kober32

"Missing presence check verification token in session 1"
);

SessionInfo sessionInfo2 = provider.startPresenceCheck(ownerId);
initPresenceCheck(ownerId);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To be sure to call init at iProov twice, but works anyway.

Copy link
Member

@romanstrobl romanstrobl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, let's deploy this change and test it.

- Allow to send event PRESENCE_CHECK_INIT during PRESENCE_CHECK_IN_PROGRESS
- Remove IProovConst
- Add another initPresenceCheck to repeatPresenceCheckStartTest
- Improve logging of IdentityVerification phase changes
@banterCZ banterCZ force-pushed the issues/365-retry-presence-check branch from 8e920db to d56f093 Compare September 22, 2022 13:02
@banterCZ banterCZ merged commit 2f07e4e into develop Sep 22, 2022
@banterCZ banterCZ deleted the issues/365-retry-presence-check branch September 22, 2022 13:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants