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
Retry to initialize the token store correctly on exception for PSEP. #2277
Conversation
I feel this is not the right way to fix this problem. Looking at the I would suggest:
|
...ging/src/main/java/org/axonframework/eventhandling/pooled/PooledStreamingEventProcessor.java
Outdated
Show resolved
Hide resolved
d77e0e3
to
72a1c63
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bunch of things to discuss.
messaging/src/main/java/org/axonframework/common/ProcessUtils.java
Outdated
Show resolved
Hide resolved
messaging/src/main/java/org/axonframework/common/ProcessUtils.java
Outdated
Show resolved
Hide resolved
messaging/src/main/java/org/axonframework/common/ProcessUtils.java
Outdated
Show resolved
Hide resolved
...ging/src/main/java/org/axonframework/eventhandling/pooled/PooledStreamingEventProcessor.java
Outdated
Show resolved
Hide resolved
...ging/src/main/java/org/axonframework/eventhandling/pooled/PooledStreamingEventProcessor.java
Outdated
Show resolved
Hide resolved
...ging/src/main/java/org/axonframework/eventhandling/pooled/PooledStreamingEventProcessor.java
Outdated
Show resolved
Hide resolved
18d338b
to
7fdefa7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Getting there! Couple of arguments again, though.
.../src/test/java/org/axonframework/eventhandling/pooled/PooledStreamingEventProcessorTest.java
Outdated
Show resolved
Hide resolved
messaging/src/main/java/org/axonframework/eventhandling/pooled/Coordinator.java
Outdated
Show resolved
Hide resolved
messaging/src/main/java/org/axonframework/common/ProcessUtils.java
Outdated
Show resolved
Hide resolved
.../src/test/java/org/axonframework/eventhandling/pooled/PooledStreamingEventProcessorTest.java
Show resolved
Hide resolved
messaging/src/main/java/org/axonframework/eventhandling/pooled/Coordinator.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Being nitpicky here, mostly. But I assume we can resolve these, so I am preemptively approving.
messaging/src/main/java/org/axonframework/common/ProcessUtils.java
Outdated
Show resolved
Hide resolved
messaging/src/main/java/org/axonframework/common/ProcessUtils.java
Outdated
Show resolved
Hide resolved
messaging/src/main/java/org/axonframework/common/ProcessUtils.java
Outdated
Show resolved
Hide resolved
messaging/src/main/java/org/axonframework/eventhandling/pooled/Coordinator.java
Show resolved
Hide resolved
messaging/src/main/java/org/axonframework/eventhandling/pooled/Coordinator.java
Outdated
Show resolved
Hide resolved
messaging/src/main/java/org/axonframework/eventhandling/pooled/Coordinator.java
Outdated
Show resolved
Hide resolved
messaging/src/main/java/org/axonframework/eventhandling/pooled/Coordinator.java
Outdated
Show resolved
Hide resolved
messaging/src/main/java/org/axonframework/common/AxonRetriesExhaustedException.java
Outdated
Show resolved
Hide resolved
Kudos, SonarCloud Quality Gate passed! |
This is a fix for #2274
If the token store wasn't initialized the first time, this will keep trying to initialize the token store.
Current state will try every 100 ms from the coordinator to initialize the tokens, until 30 tries, so about 3 seconds. if still failing it throws an exception.