probeDynatrace

failure_rate

Validates the failure rate of a specific service

Activity as code

Below are the details and signature of the activity Python module.

Typeprobe
Modulechaosdynatrace.probes
Namefailure_rate
Returnboolean

Usage

JSON

{
  "name": "failure-rate",
  "type": "probe",
  "provider": {
    "type": "python",
    "module": "chaosdynatrace.probes",
    "func": "failure_rate",
    "arguments": {
      "entity": "",
      "relative_time": "",
      "failed_percentage": 0
    }
  }
}

YAML

name: failure-rate
provider:
  arguments:
    entity: ""
    failed_percentage: 0
    relative_time: ""
  func: failure_rate
  module: chaosdynatrace.probes
  type: python
type: probe

Arguments

NameTypeDefaultRequiredTitleDescription
entitystringYesServiceName of the service
relative_timestringYesRelative Time
failed_percentageintegerYesExpected Failed Percentage

Returns true if the failure rate is less than the expected failure rate

For more information check the API documentation: https://www.dynatrace.com/support/help/dynatrace-api/environment-api/metric-v1/

Signature

def failure_rate(entity: str,
                 relative_time: str,
                 failed_percentage: int,
                 configuration: Dict[str, Dict[str, str]],
                 secrets: Dict[str, Dict[str, str]] = None) -> bool:
    pass