httphandler

package
v0.11.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 15, 2025 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewGinEventHandler

func NewGinEventHandler[T any](ginHandler GinEventHandlerFunc[T], eventHandler event.EventHandler[T]) gin.HandlerFunc

NewGinEventHandler function creates a new Gin HTTP handler function that processes incoming JSON data, unmarshals it into an event message, executes business logic, and handles the event using a provided event handler.

Types

type GinEventHandlerFunc

type GinEventHandlerFunc[T any] func(ctx *gin.Context, msg event.EventMessage[T]) error

GinEventHandlerFunc is a function that handles a business logic of an event message

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL