From b35c25a484640e5f052db8fa3ee116bf15134a15 Mon Sep 17 00:00:00 2001 From: Nitish Tiwari Date: Sun, 7 May 2023 12:32:37 +0530 Subject: [PATCH] Retention config shouldn't need logstream to be initialized It is common for users to create stream and set the retention (and be done with initial config) before sending logs to the log stream. Accordingly we're going to add support in Helm chart to declaratively create logstream and set retention. To allow that setup we need to ensure log stream retention can be set before log stream has events (i.e. initialized) --- server/src/handlers/http/logstream.rs | 4 ---- 1 file changed, 4 deletions(-) diff --git a/server/src/handlers/http/logstream.rs b/server/src/handlers/http/logstream.rs index 6775e20a2..a4f9b800c 100644 --- a/server/src/handlers/http/logstream.rs +++ b/server/src/handlers/http/logstream.rs @@ -212,10 +212,6 @@ pub async fn put_retention( Err(err) => return Err(StreamError::InvalidRetentionConfig(err)), }; - if !STREAM_INFO.stream_initialized(&stream_name)? { - return Err(StreamError::UninitializedLogstream); - } - CONFIG .storage() .get_object_store()