Class MockRouteFault

Namespace
Kuestenlogik.Bowire.Mocking
Assembly
Kuestenlogik.Bowire.dll

The latency and fault of one route (#1101). It names either a step, by Service and Method (as field overrides do), or a CRUD route, by CrudRoute; HttpMethod narrows either to one verb. The fault fields read as a mock fault rule's do.

public sealed class MockRouteFault
Inheritance
MockRouteFault
Inherited Members

Constructors

MockRouteFault()

public MockRouteFault()

Properties

CrudRoute

The path of a MockCrudRoute; its records are covered too. Not with Service or Method.

[JsonPropertyName("crudRoute")]
public string? CrudRoute { get; set; }

Property Value

string

ErrorStatusCode

Status an error answers with (default 503).

[JsonPropertyName("errorStatusCode")]
public int? ErrorStatusCode { get; set; }

Property Value

int?

HttpMethod

Only requests with this HTTP method (GET, POST, …). Null = any.

[JsonPropertyName("httpMethod")]
public string? HttpMethod { get; set; }

Property Value

string

Kind

latency-only (default), error, partial-response, connection-drop or malformed-response.

[JsonPropertyName("kind")]
public string? Kind { get; set; }

Property Value

string

Latency

The delay of every request on the route; null for none.

[JsonPropertyName("latency")]
public MockLatency? Latency { get; set; }

Property Value

MockLatency

Method

Method of the step. Null/empty/* = any.

[JsonPropertyName("method")]
public string? Method { get; set; }

Property Value

string

PartialBytes

Body bytes sent before a partial-response or connection-drop cuts off (default 1024).

[JsonPropertyName("partialBytes")]
public int? PartialBytes { get; set; }

Property Value

int?

PartialFrames

Frames sent before a streaming reply is cut off (default 0: bytes decide).

[JsonPropertyName("partialFrames")]
public int? PartialFrames { get; set; }

Property Value

int?

Rate

Probability the fault fires per request, 0..1 (default 1). The latency applies on every request.

[JsonPropertyName("rate")]
public double? Rate { get; set; }

Property Value

double?

Service

Service of the step. Null/empty/* = any.

[JsonPropertyName("service")]
public string? Service { get; set; }

Property Value

string