Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GitHubWebhookHandler ¶
type GitHubWebhookHandler interface { httphandler.FastHTTPHandler }
GitHubWebhookHandler defines http handler behaviours.
type Handler ¶
type Handler struct { MessageQueue chan *sarama.ProducerMessage Logger *slog.Logger Topic kafkacp.KafkaTopicIdentifier Secret string }
Handler represents http handler configuration and must satisfy GitHubWebhookHandler interface.
func (Handler) Handle ¶
func (h Handler) Handle(ctx *fasthttp.RequestCtx)
Handle is a fasthttp handler function.
type Option ¶
Option represents option function type.
func WithProducerGitHubMessageQueue ¶
func WithProducerGitHubMessageQueue(mq chan *sarama.ProducerMessage) Option
WithProducerGitHubMessageQueue sets kafka producer message queue for github webhooks.
func WithTopic ¶
func WithTopic(s kafkacp.KafkaTopicIdentifier) Option
WithTopic sets topic name to consume.
func WithWebhookSecret ¶
WithWebhookSecret sets github webhook secret.
Click to show internal directories.
Click to hide internal directories.