Skip to content

Fix cursor handling in ClusterEventService#26089

Open
moesterheld wants to merge 3 commits into
masterfrom
fix/cluster-event-bus-cursor
Open

Fix cursor handling in ClusterEventService#26089
moesterheld wants to merge 3 commits into
masterfrom
fix/cluster-event-bus-cursor

Conversation

@moesterheld
Copy link
Copy Markdown
Contributor

Description

The ClusterEventService opened a cursor with TailableAwait, causing it to always stay in the cursor.hasNext() while loop in iterateEvents.
This replaces the loop condition with isRunning(). The tryNext() is sufficient as it will already null if no data is returned within maxAwaitTime. To make sure this is will not delay server shutdown maxAwaitTime is now set to 1s.

/nocl

Motivation and Context

fixes #25878

How Has This Been Tested?

adjusted unit tests

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Refactoring (non-breaking change)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have requested a documentation update.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.

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.

ClusterEventService warning on shutdown

1 participant