Skip to content
This repository has been archived by the owner on Jan 19, 2024. It is now read-only.

Disable automatic response for configure monitoring event handler #372

Open
3 tasks
TannerGabriel opened this issue Sep 7, 2022 · 0 comments
Open
3 tasks
Labels
good first issue Good for newcomers help wanted Extra attention is needed

Comments

@TannerGabriel
Copy link
Member

The configure-monitoring event handler receives a sh.keptn.event.monitoring.configure event but is expected to return a sh.keptn.event.configure-monitoring.started and sh.keptn.event.configure-monitoring.finished event (See this issue). Currently, we work around that by taking advantage of the fact that the go-sdk does not seem to automatically send a .started and .finished event for cloud events that or not of type TriggeredEvent (see).

To make clear that the events are sent manually, we would like to add the new SkipAutomaticResponse option to the ConfigureMonitoringEventHandler (see).

log.Fatal(sdk.NewKeptn(
		serviceName,
		sdk.WithTaskHandler(
			monitoringTriggeredEvent,
			eventhandling.NewConfigureMonitoringEventHandler(),
			prometheusTypeFilter,
                        sdk.TaskHandlerOptions{
			        SkipAutomaticResponse: true,
		        }),
		...
		sdk.WithLogger(logrus.New()),
	).Start())

Definition of done

  • go-utils updated to version that supports SkipAutomaticResponse for event handler level
  • SkipAutomaticResponse option added to ConfigureMonitoringEventHandler
  • Unit and Integration tests are green
@TannerGabriel TannerGabriel added help wanted Extra attention is needed good first issue Good for newcomers labels Sep 7, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant