Documentation
¶
Index ¶
- func LogErrorToNewRelic(nrApp newrelic.Application) func(next ConsumeFunc) ConsumeFunc
- func NewRelicToRedis(c *redis.Client) func(next ConsumeFunc) ConsumeFunc
- func RetryWithError(publisher producer_manager.Producer, retryCount int, ...) func(next ConsumeFunc) ConsumeFunc
- func SetDbManagerToCtx(dbConn *gorm.DB) func(next ConsumeFunc) ConsumeFunc
- func WithNewRelicForConsumer(nrApp newrelic.Application) func(next ConsumeFunc) ConsumeFunc
- type ConsumeFunc
- func LogFailedMessage(next ConsumeFunc) ConsumeFunc
- func MessageLog(next ConsumeFunc) ConsumeFunc
- func NewrelicAcceptTraceId(next ConsumeFunc) ConsumeFunc
- func Recover(next ConsumeFunc) ConsumeFunc
- func RecoverWithRetry(next ConsumeFunc) ConsumeFunc
- func StoreTraceIdIntoContext(next ConsumeFunc) ConsumeFunc
- func StoreUserIdIntoContext(next ConsumeFunc) ConsumeFunc
- type Middleware
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LogErrorToNewRelic ¶
func LogErrorToNewRelic(nrApp newrelic.Application) func(next ConsumeFunc) ConsumeFunc
func NewRelicToRedis ¶
func NewRelicToRedis(c *redis.Client) func(next ConsumeFunc) ConsumeFunc
func RetryWithError ¶
func RetryWithError(publisher producer_manager.Producer, retryCount int, delayRoutingKeys ...string) func(next ConsumeFunc) ConsumeFunc
func SetDbManagerToCtx ¶
func SetDbManagerToCtx(dbConn *gorm.DB) func(next ConsumeFunc) ConsumeFunc
func WithNewRelicForConsumer ¶
func WithNewRelicForConsumer(nrApp newrelic.Application) func(next ConsumeFunc) ConsumeFunc
Types ¶
type ConsumeFunc ¶
type ConsumeFunc func(ctx context.Context, message *eventbusclient.Message)
func LogFailedMessage ¶
func LogFailedMessage(next ConsumeFunc) ConsumeFunc
func NewrelicAcceptTraceId ¶
func NewrelicAcceptTraceId(next ConsumeFunc) ConsumeFunc
func Recover ¶
func Recover(next ConsumeFunc) ConsumeFunc
Recover the consumer_manager from panic, prevent consumer_manager from dying unexpectedly
func RecoverWithRetry ¶
func RecoverWithRetry(next ConsumeFunc) ConsumeFunc
func StoreTraceIdIntoContext ¶
func StoreTraceIdIntoContext(next ConsumeFunc) ConsumeFunc
func StoreUserIdIntoContext ¶
func StoreUserIdIntoContext(next ConsumeFunc) ConsumeFunc
type Middleware ¶
type Middleware func(next ConsumeFunc) ConsumeFunc
Click to show internal directories.
Click to hide internal directories.