func NewEventProcessor()

in pkg/event_processor/bitbucket/bitbucket.go [29:47]


func NewEventProcessor(ksClient ctrlClient.Reader, options *EventProcessorOptions) *EventProcessor {
	if options == nil {
		options = &EventProcessorOptions{}
	}

	if options.Logger == nil {
		options.Logger = zap.NewNop().Sugar()
	}

	if options.RestyClient == nil {
		options.RestyClient = resty.New().SetHostURL("https://api.bitbucket.org/2.0")
	}

	return &EventProcessor{
		ksClient:    ksClient,
		logger:      options.Logger,
		restyClient: options.RestyClient,
	}
}