From 1a8db0f59f7ebe48d78a8b808af63007173b4d5f Mon Sep 17 00:00:00 2001 From: mcrakhman Date: Thu, 25 Jan 2024 13:13:30 +0100 Subject: [PATCH] Add debug logs --- commonspace/object/acl/syncacl/syncacl.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/commonspace/object/acl/syncacl/syncacl.go b/commonspace/object/acl/syncacl/syncacl.go index bc58332b..b959263a 100644 --- a/commonspace/object/acl/syncacl/syncacl.go +++ b/commonspace/object/acl/syncacl/syncacl.go @@ -3,6 +3,9 @@ package syncacl import ( "context" "errors" + + "go.uber.org/zap" + "github.com/anyproto/any-sync/commonspace/object/acl/syncacl/headupdater" "github.com/anyproto/any-sync/commonspace/object/syncobjectgetter" @@ -119,6 +122,7 @@ func (s *syncAcl) AddRawRecords(rawRecords []*consensusproto.RawRecordWithId) (e if err != nil { return } + log.Debug("records updated, final state", zap.String("head", s.AclList.Head().Id), zap.Int("len(total)", len(s.AclList.Records()))) headUpdate := s.syncClient.CreateHeadUpdate(s, rawRecords) s.headUpdater.UpdateHeads(s.Id(), []string{rawRecords[len(rawRecords)-1].Id}) s.syncClient.Broadcast(headUpdate)