Sage - anodot/daria GitHub Wiki

Source file config

Property Type Description
type String Specify source type. Value - sage
name String Unique source name - also the config file name
config Object Source configuration

All properties are required

config object properties:

Property Type Required Description
url String Yes Sage API URL
token String Yes Sage API token

All properties are required

Example

[
  {
    "type": "sage",
    "name": "sage_source",
    "config": {
      "url": "https://ui.sage/mage/api/search",
      "token": "verylongtokenhere"
    }
  }
]

Pipeline File config

Properties list

Property Required Value type Description
source yes String Source config name
pipeline_id yes String Unique pipeline identifier (use a human-readable name so you could easily use it further)
interval yes Integer How often to make a query, unit - minutes
delay no Integer default 0, how much time to wait until data is ready, unit - minutes
days_to_backfill no Integer default 0, days t backfill
static_what no bool If measurement_name is static. Default true
count_records no bool to include the number of records as separate metric, default false
count_records_measurement_name no String what property for counting records
values yes Object Key-value pairs (target_type). A target type represents how samples of the same metric are aggregated in Anodot. Valid values are gauge (average aggregation), counter (sum aggregation), running_counter. If what property is not static - instead of an actual target type specify a property name where the target type is stored
units no Object Key-value pairs (value:unit). The value must be from the values column, units can be any.
measurement_names yes Object Key-value pairs (property:name). If what property is not static - instead of an actual what value specify a property name where it is stored.
dimensions yes Array Dimensions names
properties no Object Dimensions with static values to pass to Anodot. Object with key-value pairs
tags no Object Tags. Object with key-value pairs
dvpConfig no Object Defines the way missing data points will be completed in this schema
baseRollup yes String Defines which is the minimal Anodot rollup to complete the data for. The possible values are: MEDIUMROLLUP (5 minutes), LONGROLLUP (1 hour), LONGLONGROLLUP (1 day), WEEKLY (1 week). Default: MEDIUMROLLUP
maxDVPDurationHours yes Integer The number of hours Anodot will complete missing data points for a metric. The maximal completion period depends on the stream's interval. Daily streams can be filled up to 31 days (744 hours), hourly streams up to 7 days (168 hours) and less than hourly streams can be filled up to 1 day (24 hours)
preventNoData no bool Keep this as "true". If not provided, will be set automatically
gaugeValue / counterValue no Object The definition for gauge (average) or counter (sum) aggregation type measures in the stream related to this schema
keepLastValue no bool True - use the last received value as the completion value. False - set the completion value manually. Default: false
value no Float The completion value to use, in case keepLastValue is false. Default: 0.0

Example

[
  {
    "source": "sage_source",
    "pipeline_id": "sage_pipeline",
    "count_records": true,
    "count_records_measurement_name": "count_events",
    "measurement_names": {"property":  "measurement_name"},
    "values": {"property":  "gauge"},
    "units": {"property":  "unit"},
    "dimensions": ["dim1", "dim2"],
    "query_file": "/usr/src/app/data/sage_queries/query.txt",
    "interval": 5,
    "days_to_backfill": 7,
    "delay": 1,
    "dvpConfig": {
      "baseRollup": "LONGROLLUP",
      "maxDVPDurationHours": 24,
      "gaugeValue": {"keepLastValue": true},
      "counterValue": {"value": 0}
    }
  }
]

Troubleshooting

If you see no data for a pipeline check sage_http_error metric.

  • 4xx errors mean authentication problems like an incorrect Sage token.
  • 5xx errors mean problems either with the query or with Sage itself being unavailable. To troubleshoot check query in the Sage UI

Recommended alerts to set:

  • Non-negative delta for pipeline_outgoing_records_total equals 0 or no data. This will track if the pipeline stops sending data.