-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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 flaky test in reactive-messaging-hibernate-orm #29433
Fix flaky test in reactive-messaging-hibernate-orm #29433
Conversation
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.
I spotted a small thing.
Now, tbh, I have no real idea of what you're doing :).
...untime/src/main/java/io/quarkus/smallrye/reactivemessaging/kafka/HibernateOrmStateStore.java
Outdated
Show resolved
Hide resolved
@Sanne @cescoffier to give more context: This test was stable before I add the other one involving Hibernate transactions. So this is the code that started to behave flaky:
I verified that the completion stage completes on the same Vert.x context (blocking) as the method call. But then I cannot reproduce it locally :) |
@ozangunalp thanks! I wonder if it could relate to #29159 |
896e85f
to
fe34d67
Compare
The MutinyEmitter makes sure that the caller Vert.x context is preserved when the send Uni returns, but in this case the thread won't be the same, as it'll return on the event loop instead of the worker thread. Looking at the |
The test is still flaky |
This comment has been minimized.
This comment has been minimized.
Trying to remove the named persistence-unit configured to use with the checkpointing state store in the test. |
This comment has been minimized.
This comment has been minimized.
5e7bb76
to
b910fde
Compare
First run was green. Triggered a re-run |
This comment has been minimized.
This comment has been minimized.
The test is still flaky. I'll disable the test in this PR. I don't think that I am doing anything wrong on HibernateOrmStateStore, maybe it reproduces that issue more consistently - I still cannot reproduce it locally. @Sanne can you take a look when you have some time? |
b910fde
to
92ff131
Compare
Let's keep this PR open as a basis to dig into this issue but I created a simple PR that we can merge right away there: #29478 . |
53a9f4e
to
dd55793
Compare
a03e1ec
to
cb21e65
Compare
This comment has been minimized.
This comment has been minimized.
cb21e65
to
c737b2b
Compare
This comment has been minimized.
This comment has been minimized.
c737b2b
to
cb8496f
Compare
This comment has been minimized.
This comment has been minimized.
cb8496f
to
cd7f943
Compare
cd7f943
to
6b3d0fd
Compare
@gsmet @cescoffier I think we can take this in. I added a note on the Kafka guide example |
This comment has been minimized.
This comment has been minimized.
Uses DTO for sending Kafka records Separate PUs for fruit and people entities
6b3d0fd
to
7851580
Compare
🙈 The PR is closed and the preview is expired. |
I think when the hibernate orm state store test has been added to that IT the test using Emitter in
@Transactional
method reproduced the issue in #21948 .To fix the flaky test the method using transactional no longer returns a completion stage.
The original issue is still to investigate.