Skip to content

Commit

Permalink
Increase Error details for Publish call.
Browse files Browse the repository at this point in the history
  • Loading branch information
AndreasBergmeier6176 committed Jan 16, 2024
1 parent 8644177 commit eb5c499
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion pkg/publisher/publisher.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,16 @@ func WithOrderingKey(orderingKey string) Option {
}
}

type PublishError interface {
errorreports.Error

// IsACK returns true if recipient acknowledged the event.
IsACK() bool
}

type Publisher[EV any] interface {
// Publish publishes an Event to Target.
Publish(ctx context.Context, event *EV, opts ...Option) errorreports.Error
Publish(ctx context.Context, event *EV, opts ...Option) PublishError
}

// ApplyCloudEventsPubSubOrderingKey extracts a OrderingKey from Options and
Expand Down

0 comments on commit eb5c499

Please sign in to comment.