From 34c00a1f3bbcea33317e5a8f9d5e37ed087cb17d Mon Sep 17 00:00:00 2001 From: Takahiro Yamashita Date: Sun, 7 Jan 2024 16:44:16 +0900 Subject: [PATCH] storage: modify log message Signed-off-by: Takahiro Yamashita --- src/flb_storage.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/flb_storage.c b/src/flb_storage.c index 98462bfcf5c..6d8a8e7b715 100644 --- a/src/flb_storage.c +++ b/src/flb_storage.c @@ -533,8 +533,12 @@ int flb_storage_input_create(struct cio_ctx *cio, } } else if (stream->type != cio_storage_type) { - flb_info("[storage] storage type mismatch. input type=%s", - flb_storage_get_type(in->storage_type)); + flb_debug("[storage] storage type mismatch. input type=%s", + flb_storage_get_type(in->storage_type)); + if (stream->type == FLB_STORAGE_FS) { + flb_warn("[storage] Need to remove '%s/%s' if it is empty", cio->options.root_path, in->name); + } + cio_stream_destroy(stream); stream = cio_stream_create(cio, in->name, cio_storage_type); if (!stream) { @@ -542,7 +546,7 @@ int flb_storage_input_create(struct cio_ctx *cio, in->name); return -1; } - flb_info("[storage] re-create stream"); + flb_info("[storage] re-create stream type=%s", flb_storage_get_type(in->storage_type)); } /* allocate storage context for the input instance */