commit | 4a44e534128a0415ebca61ad7a6751905f0f4242 | [log] [tgz] |
---|---|---|
author | Adithya Chakilam <achakila@codeaurora.org> | Fri Jan 15 11:08:05 2021 -0600 |
committer | Adithya Chakilam <achakila@codeaurora.org> | Fri Jan 15 22:57:50 2021 -0600 |
tree | 68527d26dd607a38d25b03ab49e1c2daa777dbea | |
parent | ba2c8e16b798c2eaf4e56dd66d8c1cd00999e096 [diff] |
Use volatile and AtomicIntegers to be thread safe Modify the fields in ReplicationState class to be volatile and AtomicIntegers so that changes to them are reflected to other threads. By not doing so, modifications made by one thread to these fields may not be reflected instantly depending on cpu caching thus resulting in incorrect state Change-Id: I76512b17c19cc68e4f1e6a5223899f9a184bb549