Skip to content

Commit

Permalink
fix conflicts
Browse files Browse the repository at this point in the history
Signed-off-by: qupeng <qupeng@pingcap.com>
  • Loading branch information
hicqu committed Sep 9, 2024
1 parent 4b5c832 commit b8b3732
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions cdc/processor/sourcemanager/engine/pebble/event_sorter.go
Original file line number Diff line number Diff line change
Expand Up @@ -319,16 +319,6 @@ func (s *EventSorter) SlotsAndHasher() (slotCount int, hasher func(tablepb.Span,
// Next implements sorter.EventIterator.
func (s *EventIter) Next() (event *model.PolymorphicEvent, pos engine.Position, err error) {
valid := s.iter != nil && s.iter.Valid()
<<<<<<< HEAD:cdc/processor/sourcemanager/engine/pebble/event_sorter.go
var value []byte
for valid {
nextStart := time.Now()
value = s.iter.Value()
s.nextDuration.Observe(time.Since(nextStart).Seconds())

event = &model.PolymorphicEvent{}
if _, err = s.serde.Unmarshal(event, value); err != nil {
=======
var nextEvent *model.PolymorphicEvent

// We need to decide whether the current event is the last event in this transactions
Expand All @@ -337,19 +327,14 @@ func (s *EventIter) Next() (event *model.PolymorphicEvent, pos engine.Position,
for valid {
nextEvent = &model.PolymorphicEvent{}
if _, err = s.serde.Unmarshal(nextEvent, s.iter.Value()); err != nil {
>>>>>>> 50659c4b5d (sorter: correct wrong metric about next duration (#11577)):cdc/processor/sourcemanager/sorter/pebble/event_sorter.go
return
}

nextStart := time.Now()
valid = s.iter.Next()
<<<<<<< HEAD:cdc/processor/sourcemanager/engine/pebble/event_sorter.go
if s.headItem != nil {
=======
s.nextDuration.Observe(time.Since(nextStart).Seconds())

if s.currentEvent != nil {

Check failure on line 337 in cdc/processor/sourcemanager/engine/pebble/event_sorter.go

View workflow job for this annotation

GitHub Actions / Mac OS Build

s.currentEvent undefined (type *EventIter has no field or method currentEvent)

Check failure on line 337 in cdc/processor/sourcemanager/engine/pebble/event_sorter.go

View workflow job for this annotation

GitHub Actions / Arm Build (ARM64)

s.currentEvent undefined (type *EventIter has no field or method currentEvent)
>>>>>>> 50659c4b5d (sorter: correct wrong metric about next duration (#11577)):cdc/processor/sourcemanager/sorter/pebble/event_sorter.go
break
}
s.headItem, event = event, nil
Expand Down

0 comments on commit b8b3732

Please # to comment.