From 8c8e8ae04c0d8fbfeda42a1a4f3e3e46fbc89a9b Mon Sep 17 00:00:00 2001 From: Mahad Zaryab Date: Sun, 3 Nov 2024 20:14:34 -0500 Subject: [PATCH] Fix Lint Error And Comment Out Archive Flags Signed-off-by: Mahad Zaryab --- cmd/remote-storage/app/server.go | 3 ++- plugin/storage/integration/elasticsearch_test.go | 7 ++++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/cmd/remote-storage/app/server.go b/cmd/remote-storage/app/server.go index bf73527a617..606255649bd 100644 --- a/cmd/remote-storage/app/server.go +++ b/cmd/remote-storage/app/server.go @@ -54,7 +54,7 @@ func NewServer(options *Options, storageFactory storage.Factory, tm *tenancy.Man }, nil } -func createGRPCHandler(f storage.Factory, logger *zap.Logger) (*shared.GRPCHandler, error) { +func createGRPCHandler(f storage.Factory, _ *zap.Logger) (*shared.GRPCHandler, error) { reader, err := f.CreateSpanReader() if err != nil { return nil, err @@ -78,6 +78,7 @@ func createGRPCHandler(f storage.Factory, logger *zap.Logger) (*shared.GRPCHandl // borrow code from Query service for archive storage qOpts := &querysvc.QueryServiceOptions{} // when archive storage not initialized (returns false), the reader/writer will be nil + // TODO: what should we do here? // _ = qOpts.InitArchiveStorage(f, logger) impl.ArchiveSpanReader = func() spanstore.Reader { return qOpts.ArchiveSpanReader } impl.ArchiveSpanWriter = func() spanstore.Writer { return qOpts.ArchiveSpanWriter } diff --git a/plugin/storage/integration/elasticsearch_test.go b/plugin/storage/integration/elasticsearch_test.go index 8cfe053445a..88171df27d6 100644 --- a/plugin/storage/integration/elasticsearch_test.go +++ b/plugin/storage/integration/elasticsearch_test.go @@ -109,9 +109,10 @@ func (*ESStorageIntegration) initializeESFactory(t *testing.T, allTagsAsFields b fmt.Sprintf("--es.tags-as-fields.all=%v", allTagsAsFields), fmt.Sprintf("--es.bulk.actions=%v", 1), fmt.Sprintf("--es.bulk.flush-interval=%v", time.Nanosecond), - "--es-archive.enabled=true", - fmt.Sprintf("--es-archive.tags-as-fields.all=%v", allTagsAsFields), - fmt.Sprintf("--es-archive.index-prefix=%v", indexPrefix), + // TODO: are these flags being used at the moment? + // "--es-archive.enabled=true", + // fmt.Sprintf("--es-archive.tags-as-fields.all=%v", allTagsAsFields), + // fmt.Sprintf("--es-archive.index-prefix=%v", indexPrefix), } require.NoError(t, command.ParseFlags(args)) f.InitFromViper(v, logger)