SamplingRuleArgs

data class SamplingRuleArgs(val attributes: Output<Map<String, String>>? = null, val fixedRate: Output<Double>? = null, val host: Output<String>? = null, val httpMethod: Output<String>? = null, val priority: Output<Int>? = null, val reservoirSize: Output<Int>? = null, val resourceArn: Output<String>? = null, val ruleName: Output<String>? = null, val serviceName: Output<String>? = null, val serviceType: Output<String>? = null, val tags: Output<Map<String, String>>? = null, val urlPath: Output<String>? = null, val version: Output<Int>? = null) : ConvertibleToJava<SamplingRuleArgs>

Creates and manages an AWS XRay Sampling Rule.

Example Usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.xray.SamplingRule;
import com.pulumi.aws.xray.SamplingRuleArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new SamplingRule("example", SamplingRuleArgs.builder()
.attributes(Map.of("Hello", "Tris"))
.fixedRate(0.05)
.host("*")
.httpMethod("*")
.priority(10000)
.reservoirSize(1)
.resourceArn("*")
.ruleName("example")
.serviceName("*")
.serviceType("*")
.urlPath("*")
.version(1)
.build());
}
}

Import

XRay Sampling Rules can be imported using the name, e.g.,

$ pulumi import aws:xray/samplingRule:SamplingRule example example

Constructors

Link copied to clipboard
constructor(attributes: Output<Map<String, String>>? = null, fixedRate: Output<Double>? = null, host: Output<String>? = null, httpMethod: Output<String>? = null, priority: Output<Int>? = null, reservoirSize: Output<Int>? = null, resourceArn: Output<String>? = null, ruleName: Output<String>? = null, serviceName: Output<String>? = null, serviceType: Output<String>? = null, tags: Output<Map<String, String>>? = null, urlPath: Output<String>? = null, version: Output<Int>? = null)

Properties

Link copied to clipboard
val attributes: Output<Map<String, String>>? = null

Matches attributes derived from the request.

Link copied to clipboard
val fixedRate: Output<Double>? = null

The percentage of matching requests to instrument, after the reservoir is exhausted.

Link copied to clipboard
val host: Output<String>? = null

Matches the hostname from a request URL.

Link copied to clipboard
val httpMethod: Output<String>? = null

Matches the HTTP method of a request.

Link copied to clipboard
val priority: Output<Int>? = null

The priority of the sampling rule.

Link copied to clipboard
val reservoirSize: Output<Int>? = null

A fixed number of matching requests to instrument per second, prior to applying the fixed rate. The reservoir is not used directly by services, but applies to all services using the rule collectively.

Link copied to clipboard
val resourceArn: Output<String>? = null

Matches the ARN of the AWS resource on which the service runs.

Link copied to clipboard
val ruleName: Output<String>? = null

The name of the sampling rule.

Link copied to clipboard
val serviceName: Output<String>? = null

Matches the name that the service uses to identify itself in segments.

Link copied to clipboard
val serviceType: Output<String>? = null

Matches the origin that the service uses to identify its type in segments.

Link copied to clipboard
val tags: Output<Map<String, String>>? = null

Key-value mapping of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level

Link copied to clipboard
val urlPath: Output<String>? = null

Matches the path from a request URL.

Link copied to clipboard
val version: Output<Int>? = null

The version of the sampling rule format (1 )

Functions

Link copied to clipboard
open override fun toJava(): SamplingRuleArgs