mirror of
https://github.com/Unleash/unleash.git
synced 2025-01-11 00:08:30 +01:00
docs: improve datadog integration docs (#4802)
## About the changes Improvement to the description of the datadog integration. Adds 2 missing event types, removes an event type that is deprecated and about to be completely removed, adds missing description of extra json headers and source type name, and adds description for the new configuration option for JSON body support --------- Co-authored-by: Nuno Góis <github@nunogois.com> Co-authored-by: Thomas Heartman <thomas@getunleash.ai>
This commit is contained in:
parent
45aca5b09e
commit
0938b2e545
@ -12,8 +12,8 @@ import {
|
||||
FEATURE_STRATEGY_ADD,
|
||||
FEATURE_METADATA_UPDATED,
|
||||
FEATURE_PROJECT_CHANGE,
|
||||
FEATURE_VARIANTS_UPDATED,
|
||||
FEATURE_POTENTIALLY_STALE_ON,
|
||||
FEATURE_ENVIRONMENT_VARIANTS_UPDATED,
|
||||
} from '../types/events';
|
||||
import { IAddonDefinition } from '../types/model';
|
||||
|
||||
@ -55,8 +55,8 @@ const dataDogDefinition: IAddonDefinition = {
|
||||
name: 'customHeaders',
|
||||
displayName: 'Extra HTTP Headers',
|
||||
placeholder: `{
|
||||
"ISTIO_USER_KEY": "hunter2",
|
||||
"SOME_OTHER_CUSTOM_HTTP_HEADER": "SOMEVALUE"
|
||||
"SOME_CUSTOM_HTTP_HEADER": "SOME_VALUE",
|
||||
"SOME_OTHER_CUSTOM_HTTP_HEADER": "SOME_OTHER_VALUE"
|
||||
}`,
|
||||
description:
|
||||
'(Optional) Used to add extra HTTP Headers to the request the plugin fires off. This must be a valid json object of key-value pairs where both the key and the value are strings',
|
||||
@ -94,7 +94,7 @@ const dataDogDefinition: IAddonDefinition = {
|
||||
FEATURE_STRATEGY_ADD,
|
||||
FEATURE_METADATA_UPDATED,
|
||||
FEATURE_PROJECT_CHANGE,
|
||||
FEATURE_VARIANTS_UPDATED,
|
||||
FEATURE_ENVIRONMENT_VARIANTS_UPDATED,
|
||||
FEATURE_POTENTIALLY_STALE_ON,
|
||||
],
|
||||
tagTypes: [
|
||||
|
@ -28,6 +28,8 @@ You can choose to trigger updates for the following events:
|
||||
- feature-stale-off
|
||||
- feature-environment-enabled
|
||||
- feature-environment-disabled
|
||||
- feature-environment-variants-updated
|
||||
- feature-potentially-stale-on
|
||||
|
||||
> *) Deprecated, and will not be used after transition to environments in Unleash v4.3
|
||||
|
||||
@ -35,12 +37,54 @@ You can choose to trigger updates for the following events:
|
||||
|
||||
Unleash Datadog integration takes the following parameters.
|
||||
|
||||
- **Datadog Events URL** - This property is optional. The default url is https://api.datadoghq.com/api/v1/events. Needs to be changed if you are not not on the US1 [Datadog site](https://docs.datadoghq.com/getting_started/site/). Possible alternatives:
|
||||
- **Datadog Events URL** - This is an optional property. The default URL is https://api.datadoghq.com/api/v1/events. If you are not not using the US1 [Datadog site](https://docs.datadoghq.com/getting_started/site/), you'll need to change this. Some instances and their URLs are:
|
||||
- EU: https://app.datadoghq.eu/api/v1/events
|
||||
- US1: https://app.datadoghq.com/api/v1/events
|
||||
- US3: https://us3.datadoghq.com/api/v1/events
|
||||
- US1-FED: https://app.ddog-gov.com/api/v1/events
|
||||
- **DD API KEY** - This is a required property.
|
||||
|
||||
|
||||
- **Datadog API key** - This is a required property. The API key to use to authenticate with Datadog.
|
||||
|
||||
- **Datadog Source Type Name** - This is an optional property. Sets `source_type_name` parameter to be included in Datadog events.
|
||||
|
||||
- **Extra HTTP Headers** - This is an optional property. Used to set the additional headers when Unleash communicates with Datadog.
|
||||
|
||||
Example:
|
||||
|
||||
```json
|
||||
{
|
||||
"SOME_CUSTOM_HTTP_HEADER": "SOME_VALUE",
|
||||
"SOME_OTHER_CUSTOM_HTTP_HEADER": "SOME_OTHER_VALUE"
|
||||
}
|
||||
```
|
||||
|
||||
:::info Body template availability
|
||||
|
||||
The body template property will be introduced as a beta feature in Unleash 5.5 and is expected to be made generally available in Unleash 5.6.
|
||||
|
||||
:::
|
||||
|
||||
- **Body template** - This is an optional property. The template is used to override the body template used by Unleash when performing the HTTP POST. You can format your message using a [Mustache template](https://mustache.github.io). Refer to the [Unleash event types](/reference/event-types) reference to find out which event properties you have access to in the template.
|
||||
|
||||
Example:
|
||||
|
||||
```mustache
|
||||
{
|
||||
"event": "{{event.type}}",
|
||||
"createdBy": "{{event.createdBy}}",
|
||||
"featureToggle": "{{event.data.name}}",
|
||||
"timestamp": "{{event.data.createdAt}}"
|
||||
}
|
||||
```
|
||||
|
||||
If you don't specify anything Unleash will send a formatted markdown body.
|
||||
|
||||
Example:
|
||||
|
||||
```markdown
|
||||
username created feature toggle (featurename)[http://your.url/projects/projectname/features/featurename] in project *projectname*
|
||||
```
|
||||
|
||||
#### Tags {#tags}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user