You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
106396: server: de-flake a decommission test race condition r=abarganier a=knz
Informs cockroachdb#103698 (will fix when backported to 23.1).
Epic: CRDB-28893
When a Decommission request is sent that addresses multiple nodes simultaneously, a race condition existed in the code that logs the decommission event to the event log.
This is because the `sql.InsertEventRecords` API expects to take ownership over the events. The `Decommission` handler was violating the expectation by passing the same event references to multiple subsequent calls.
This was not visible in practice however, because the racy writes were always overwriting the same value to the same field.
This patch fixes it by allocating a new event for each subsequent node decommission.
Release note: None
Co-authored-by: Raphael 'kena' Poss <[email protected]>
0 commit comments