From c64e0ce037a2e92e19ca5beb12beee9d6ab9d976 Mon Sep 17 00:00:00 2001 From: Darun Seethammagari Date: Wed, 15 Nov 2023 12:32:49 -0800 Subject: [PATCH 1/2] fix: Coordinator Not Updating Redis Indexer Config --- indexer/queryapi_coordinator/src/indexer_registry.rs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/indexer/queryapi_coordinator/src/indexer_registry.rs b/indexer/queryapi_coordinator/src/indexer_registry.rs index ddf8d0593..90fef92f2 100644 --- a/indexer/queryapi_coordinator/src/indexer_registry.rs +++ b/indexer/queryapi_coordinator/src/indexer_registry.rs @@ -176,7 +176,15 @@ async fn index_and_process_register_calls( streamers_lock.insert(new_indexer_function.get_full_name(), streamer); } - fns.insert(update.method_name.clone(), new_indexer_function); + storage::set( + context.redis_connection_manager, + storage::generate_real_time_storage_key(&new_indexer_function.get_full_name()), + serde_json::to_string(&new_indexer_function.clone())?, + None, + ) + .await?; + + fns.insert(new_indexer_function.function_name.clone(), new_indexer_function); } }; } From 476c4b923a65de32aa819c34e2749ba4f54c85c3 Mon Sep 17 00:00:00 2001 From: Darun Seethammagari Date: Wed, 15 Nov 2023 13:50:52 -0800 Subject: [PATCH 2/2] Fix format issues --- indexer/queryapi_coordinator/src/indexer_registry.rs | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/indexer/queryapi_coordinator/src/indexer_registry.rs b/indexer/queryapi_coordinator/src/indexer_registry.rs index 90fef92f2..b3c695fb4 100644 --- a/indexer/queryapi_coordinator/src/indexer_registry.rs +++ b/indexer/queryapi_coordinator/src/indexer_registry.rs @@ -178,13 +178,18 @@ async fn index_and_process_register_calls( storage::set( context.redis_connection_manager, - storage::generate_real_time_storage_key(&new_indexer_function.get_full_name()), + storage::generate_real_time_storage_key( + &new_indexer_function.get_full_name(), + ), serde_json::to_string(&new_indexer_function.clone())?, None, ) .await?; - - fns.insert(new_indexer_function.function_name.clone(), new_indexer_function); + + fns.insert( + new_indexer_function.function_name.clone(), + new_indexer_function, + ); } }; }