From c4865c149f466ba693ca410515a2705f05c0b467 Mon Sep 17 00:00:00 2001 From: William Petit Date: Fri, 24 Feb 2023 10:38:48 +0100 Subject: [PATCH] feat(store,document,sqlite): log upsert query in debug level --- pkg/storage/sqlite/document_store.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pkg/storage/sqlite/document_store.go b/pkg/storage/sqlite/document_store.go index 5679a98..cceebb4 100644 --- a/pkg/storage/sqlite/document_store.go +++ b/pkg/storage/sqlite/document_store.go @@ -190,6 +190,12 @@ func (s *DocumentStore) Upsert(ctx context.Context, collection string, document args := []any{id, collection, JSONMap(document), now, now} + logger.Debug( + ctx, "executing query", + logger.F("query", query), + logger.F("args", args), + ) + row := tx.QueryRowContext(ctx, query, args...) var (