Skip to content

Conversation

deepthidevaki
Copy link
Contributor

Description

Forward port of #37064

Related issues

closes #37046

@github-actions github-actions bot added the component/zeebe Related to the Zeebe component/team label Aug 25, 2025
@deepthidevaki
Copy link
Contributor Author

Auto-backport failed due to merge conflict for this commit 2836ecc because the test is not disabled in main. This commit is removed from this PR. In addition, spot bug reported a false positive which is now excluded.

Other than that there are no changes from the original PR.

@deepthidevaki deepthidevaki marked this pull request as ready for review August 25, 2025 12:20
Comment on lines +19 to +23
<Match>
<!-- This is a false positive for property 'commitPosition' because it is updated with in an actor. So atomic updates are guaranteed. -->
<Class name="io.camunda.zeebe.broker.system.partitions.impl.AsyncSnapshotDirector"/>
<Bug pattern="AT_NONATOMIC_OPERATIONS_ON_SHARED_VARIABLE"/>
</Match>
Copy link
Member

Choose a reason for hiding this comment

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

❓ But the getter is executed from the Main thread right, so this is an issue then? As long updates are not atomic.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The getter is only used for testing though.

Copy link
Member

Choose a reason for hiding this comment

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

Yeah, right now. I feel this is dangerous. It especially needs a specific test setup, as you did with the Controlled actor. There is no guarantee that someone creates a test with a normal actor or different executor. Idk I feel this has a high chance of creating flaky tests.

Copy link
Member

Choose a reason for hiding this comment

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

I think you can wrap it with actor.call to be safe and it should work with your test set up as well. But avoid potential future misuse.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Changed the getter to return an actor future.

Copy link
Member

@ChrisKujawa ChrisKujawa left a comment

Choose a reason for hiding this comment

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

Thanks @deepthidevaki sorry for the delay 🙇🏼

We probably want to adjust this on the other branches as well.

@deepthidevaki
Copy link
Contributor Author

We probably want to adjust this on the other branches as well.

I will update them.

@deepthidevaki deepthidevaki added this pull request to the merge queue Aug 28, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Aug 28, 2025
@deepthidevaki deepthidevaki added this pull request to the merge queue Aug 28, 2025
Merged via the queue into main with commit fd52c34 Aug 28, 2025
165 of 168 checks passed
@deepthidevaki deepthidevaki deleted the backport-37064-to-main branch August 28, 2025 09:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/zeebe Related to the Zeebe component/team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[8.6][8.7] Investigate failing test ExporterDisableTest.exporterStaysDisabledAfterRestart
2 participants