Repository navigation
[core] Move Redis health check runner back to GCS server main - #55812
Conversation
There was a problem hiding this comment.
Code Review
This pull request aims to deflake the Redis client tests. The main change is disabling the Redis health check during tests, which is a reasonable approach given that Redis is torn down between test cases. The change from INFO to DEBUG for logging is also good for reducing log noise.
I found a race condition in TEST_F(RedisStoreClientTest, Complicated) which was likely exposed by another fix in this PR. The AsyncExists check was not waiting for AsyncBatchDelete to complete. I've provided a suggestion to fix this, which should improve test stability.
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
e6389fa to
b373556
Compare
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
Signed-off-by: Edward Oakes <[email protected]>
dayshah
left a comment
There was a problem hiding this comment.
ok with this for now but shouldn't the io service stop and cancel everything before things are destructed
IMO the |
…oject#55812) TSAN tests are failing after my refactor PR: ray-project#55655 This is because the `PeriodicalRunner` does not wait for any spawned async tasks to complete in its destructor. In the current setup, after the `PeriodicalRunner` is destroyed, the `RedisStoreClient` is immediately destroyed. However, there may still be tasks on the IO service that didn't get cancelled and will try to access the `RedisStoreClient`, leading to invalid memory accesses. Simplest fix is to move the `PeriodicalRunner` back to `gcs_server.cc` and capture a shared pointer to the client in the callback. I also considered fixing the `PeriodicalRunner` destructor, but that code is hard to navigate right now. --------- Signed-off-by: Edward Oakes <[email protected]> Signed-off-by: jugalshah291 <[email protected]>
TSAN tests are failing after my refactor PR: #55655 This is because the `PeriodicalRunner` does not wait for any spawned async tasks to complete in its destructor. In the current setup, after the `PeriodicalRunner` is destroyed, the `RedisStoreClient` is immediately destroyed. However, there may still be tasks on the IO service that didn't get cancelled and will try to access the `RedisStoreClient`, leading to invalid memory accesses. Simplest fix is to move the `PeriodicalRunner` back to `gcs_server.cc` and capture a shared pointer to the client in the callback. I also considered fixing the `PeriodicalRunner` destructor, but that code is hard to navigate right now. --------- Signed-off-by: Edward Oakes <[email protected]> Signed-off-by: Douglas Strodtman <[email protected]>
…oject#55812) TSAN tests are failing after my refactor PR: ray-project#55655 This is because the `PeriodicalRunner` does not wait for any spawned async tasks to complete in its destructor. In the current setup, after the `PeriodicalRunner` is destroyed, the `RedisStoreClient` is immediately destroyed. However, there may still be tasks on the IO service that didn't get cancelled and will try to access the `RedisStoreClient`, leading to invalid memory accesses. Simplest fix is to move the `PeriodicalRunner` back to `gcs_server.cc` and capture a shared pointer to the client in the callback. I also considered fixing the `PeriodicalRunner` destructor, but that code is hard to navigate right now. --------- Signed-off-by: Edward Oakes <[email protected]>
TSAN tests are failing after my refactor PR: #55655
This is because the
PeriodicalRunnerdoes not wait for any spawned async tasks to complete in its destructor. In the current setup, after thePeriodicalRunneris destroyed, theRedisStoreClientis immediately destroyed. However, there may still be tasks on the IO service that didn't get cancelled and will try to access theRedisStoreClient, leading to invalid memory accesses.Simplest fix is to move the
PeriodicalRunnerback togcs_server.ccand capture a shared pointer to the client in the callback. I also considered fixing thePeriodicalRunnerdestructor, but that code is hard to navigate right now.