java.lang.ArithmeticException: / by zero in RoundRobinSelectionStrategy.select

Description

Suggested Release Note:

Fixed a rare `java.lang.ArithmeticException: / by zero` exception in `RoundRobinSelectionStrategy.select` that could occur during rebalance.

 

Stack trace:

Environment

None

Gerrit Reviews

None

Release Notes Description

None

Activity

Show:

David Nault August 23, 2023 at 4:25 PM
Edited

Intermittent / transient.

Race condition. Looks like it can happen if the list of endpoints becomes empty between PooledService.send where we check if `endpoints` is empty, and RoundRobinSelectionStrategy.select where we use the size as a divisor for %.

Visual inspection makes me think the consequence of this bug is that the a few requests will fail with that arithmetic exception, and then we'll recover by realizing the `endpoints` list is empty.

Fixed
Pinned fields
Click on the next to a field label to start pinning.

Details

Assignee

Reporter

Story Points

Sprint

Fix versions

Priority

Instabug

Open Instabug

PagerDuty

Sentry

Zendesk Support

Created August 23, 2023 at 4:24 PM
Updated August 30, 2023 at 5:20 PM
Resolved August 30, 2023 at 5:20 PM
Instabug