MCPcopy Index your code
hub / github.com/NdoleStudio/httpsms / EventDispatcher

Method EventDispatcher

api/pkg/di/container.go:724–740  ·  view source on GitHub ↗

EventDispatcher creates a new instance of services.EventDispatcher

()

Source from the content-addressed store, hash-verified

722
723// EventDispatcher creates a new instance of services.EventDispatcher
724func (container *Container) EventDispatcher() (dispatcher *services.EventDispatcher) {
725 if container.eventDispatcher != nil {
726 return container.eventDispatcher
727 }
728
729 container.logger.Debug(fmt.Sprintf("creating %T", dispatcher))
730 dispatcher = services.NewEventDispatcher(
731 container.Logger(),
732 container.Tracer(),
733 container.Float64Histogram("event.publisher.duration", "ms", "measures the duration of processing CloudEvents"),
734 container.EventsQueue(),
735 container.EventsQueueConfiguration(),
736 )
737
738 container.eventDispatcher = dispatcher
739 return dispatcher
740}
741
742// Float64Histogram creates a new instance of metric.Float64Histogram
743func (container *Container) Float64Histogram(name, unit, description string) otelMetric.Float64Histogram {

Callers 15

HeartbeatServiceMethod · 0.95
DiscordServiceMethod · 0.95
WebhookServiceMethod · 0.95
PhoneServiceMethod · 0.95
UserServiceMethod · 0.95
MessageThreadServiceMethod · 0.95
EventsHandlerMethod · 0.95
LemonsqueezyServiceMethod · 0.95

Calls 6

LoggerMethod · 0.95
TracerMethod · 0.95
Float64HistogramMethod · 0.95
EventsQueueMethod · 0.95
DebugMethod · 0.65

Tested by

no test coverage detected