mirror of
https://github.com/featurebasedb/featurebase.git
synced 2026-08-28 10:54:59 +00:00
FB 1646 : Code updated to make the debug message more helpful
This commit is contained in:
parent
c60a037065
commit
f194cb216b
1 changed files with 11 additions and 1 deletions
|
|
@ -232,11 +232,17 @@ func (r *Record) Commit(ctx context.Context) error {
|
|||
p = x.Partition
|
||||
}
|
||||
|
||||
_, err := r.src.CommitMessages(r.src.highmarks)
|
||||
committedOffsets, err := r.src.CommitMessages(r.src.highmarks)
|
||||
if err != nil {
|
||||
return errors.Wrap(err, "failed to commit messages")
|
||||
}
|
||||
|
||||
if r.src.Verbose {
|
||||
for _, o := range committedOffsets {
|
||||
r.src.Log.Debugf("p: %v o: %v t: %v", o.Partition, o.Offset, o.Topic)
|
||||
}
|
||||
}
|
||||
|
||||
r.src.spool = remaining
|
||||
r.src.spoolBase = idx
|
||||
return nil
|
||||
|
|
@ -310,6 +316,10 @@ func (s *Source) Open() error {
|
|||
return errors.Wrap(err, "subscribe topics")
|
||||
}
|
||||
|
||||
if s.Verbose {
|
||||
s.Log.Debugf("subscribed to %v", s.Topics)
|
||||
}
|
||||
|
||||
s.client = cl
|
||||
s.opened = true
|
||||
s.wg.Add(1)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue