Skip to content

feat: add Dash0 data source type, metric, and direct config#895

Open
matkaras wants to merge 9 commits intomainfrom
dash0-integration
Open

feat: add Dash0 data source type, metric, and direct config#895
matkaras wants to merge 9 commits intomainfrom
dash0-integration

Conversation

@matkaras
Copy link
Contributor

@matkaras matkaras commented Mar 10, 2026

Motivation

Add Dash0 as a new data source type. Dash0 is a Prometheus-compatible monitoring platform with bearer token authentication, supporting both Agent and Direct modes.

Summary

  • Add Dash0 to DataSourceType enum and generated code (value 29)
  • Add Dash0Metric with PromQL field and validation in slo/metrics_dash0.go
  • Add Dash0Config for Direct (URL, AccessToken, Step) and Agent (URL, Step)
  • Add Dash0 to MetricSpec, DataSourceType(), Query(), and validateExactlyOneMetricSpecType
  • Add query delay default (0s), data retrieval max (30 days agent+direct)
  • Register Dash0 as valid direct type
  • Add agent, direct, and SLO metric examples
  • Add Dash0 to validMetricSpecs test map

Related Changes

Testing

  • TestValidateExactlyOneMetricSpecType updated to cover Dash0
  • All existing SLO validation tests pass
  • Example generation succeeds for agent, direct, and SLO variants

## Motivation

Add Dash0 as a new data source type for the Prometheus-compatible
monitoring platform with bearer token authentication.

## Summary

- Add Dash0 to DataSourceType enum and generated code
- Add Dash0Metric with PromQL field and validation
- Add Dash0Config for Direct with URL, AccessToken, Step
- Add query delay default (0s) and data retrieval max (30 days)
- Register Dash0 as valid direct type
@matkaras
Copy link
Contributor Author

- Add Dash0Config to agent Spec with URL and Step
- Add Dash0 to agent GetType switch
- Add Dash0 to agentDataRetrievalMaxDuration
- Add agent, direct, and SLO examples for Dash0
- Add Dash0 to validateExactlyOneMetricSpecType
- Add Dash0 to validMetricSpecs test map
- Add dash0Validation for agent (URL required, step >= 15)
- Add dash0Validation for direct (URL required, accessToken required)
- Add Dash0 to exactlyOneDataSourceTypeValidationRule in both agent and direct
- Add Dash0 to validAgentSpec and validDirectSpec test maps
- Add omitempty to Dash0Metric.PromQL json tag
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request go minor

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants