Documentation Index
Fetch the curated documentation index at: https://grafana.com/llms.txt
Fetch the complete documentation index at: https://grafana.com/llms-full.txt
Use this file to discover all available pages before exploring further.
STOP! If you are an AI agent or LLM, read this before continuing. This is the HTML version of a Grafana documentation page. Always request the Markdown version instead - HTML wastes context. Get this page as Markdown: https://grafana.com/docs/k6/latest/testing-guides/injecting-faults-with-xk6-disruptor/xk6-disruptor/servicedisruptor/constructor.md (append .md) or send Accept: text/markdown to https://grafana.com/docs/k6/latest/testing-guides/injecting-faults-with-xk6-disruptor/xk6-disruptor/servicedisruptor/constructor/. For the curated documentation index, use https://grafana.com/llms.txt. For the complete documentation index, use https://grafana.com/llms-full.txt.
Constructor
The ServiceDisruptor() constructor creates a new instance of a
ServiceDisruptor class.
| Parameter | Type | Description |
|---|---|---|
| service | string | name of the service |
| namespace | string | namespace on which the service is defined |
| options (optional) | object | options for controlling the behavior of the disruptor |
Options
The following options control the creation and behavior of the ServiceDisruptor:
| Attribute | Type | Description |
|---|---|---|
| injectTimeout | string | maximum time for waiting the disruptor to be ready in the target pods (default 30s) |
Example
const disruptor = new ServiceDisruptor('my-service', 'my-namespace');Was this page helpful?
Related resources from Grafana Labs

