Skip to content

make listDelimiter volatile#767

Open
sahvx655-wq wants to merge 1 commit into
Netflix:2.xfrom
sahvx655-wq:listdelimiter-volatile
Open

make listDelimiter volatile#767
sahvx655-wq wants to merge 1 commit into
Netflix:2.xfrom
sahvx655-wq:listdelimiter-volatile

Conversation

@sahvx655-wq

Copy link
Copy Markdown

reading the change that made decoder and interpolator volatile, listDelimiter is the third setter-backed field in AbstractConfig with the same shape: setListDelimiter writes it and getListDelimiter reads it (CommonsToConfig joins on it from the read path). it was missed, so a write still has no happens-before with reads on other threads and a stale delimiter can be observed indefinitely. same single-assignment setter, so volatile is the right level here too.

listDelimiter is mutated through setListDelimiter and read concurrently via getListDelimiter, but was left non-volatile when decoder and interpolator were marked volatile. without it a write has no happens-before with reads on other threads, so stale values can be observed.
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.

1 participant