Zipkin 플러그인 구성 참조
Zipkin 플러그인 구성 참조 (Zipkin Plugin Configuration Reference)
이 문서는 Kong Gateway에서 Zipkin 플러그인을 구성할 때 설정할 수 있는 모든 파라미터를 스키마 형태로 정리한 참조 자료예요. connect_timeout이나 header_type 같은 각 옵션의 기본값, 허용 범위, 역할을 한눈에 확인할 수 있어요. Zipkin으로 트레이싱 데이터를 수집하면서 플러그인 동작을 세밀하게 조정하고 싶을 때 참고하면 좋아요
출처: 문서
본문
{
"properties": {
"config": {
"properties": {
"connect_timeout": {
"default": 2000,
"description": "An integer representing a timeout in milliseconds. Must be between 0 and 2^31-2.",
"maximum": 2147483646,
"minimum": 0,
"type": "integer"
},
"default_header_type": {
"default": "b3",
"description": "Allows specifying the type of header to be added to requests with no pre-existing tracing headers and when `config.header_type` is set to `\"preserve\"`. When `header_type` is set to any other value, `default_header_type` is ignored.",
"enum": [
"aws",
"b3",
"b3-single",
"datadog",
"gcp",
"instana",
"jaeger",
"ot",
"w3c"
],
"type": "string"
},
"default_service_name": {
"description": "Set a default service name to override `unknown-service-name` in the Zipkin spans.",
"type": "string"
},
"header_type": {
"default": "preserve",
"description": "All HTTP requests going through the plugin are tagged with a tracing HTTP request. This property codifies what kind of tracing header the plugin expects on incoming requests",
"enum": [
"aws",
"b3",
"b3-single",
"datadog",
"gcp",
"ignore",
"instana",
"jaeger",
"ot",
"preserve",
"w3c"
],
"type": "string"
},
"http_endpoint": {
"description": "A string representing a URL, such as https://example.com/path/to/resource?q=search.",
"type": "string"
},
"http_response_header_for_traceid": {
"type": "string"
},
"http_span_name": {
"default": "method",
"description": "Specify whether to include the HTTP path in the span name.",
"enum": [
"method",
"method_path"
],
"type": "string"
},
"include_credential": {
"default": true,
"description": "Specify whether the credential of the currently authenticated consumer should be included in metadata sent to the Zipkin server.",
"type": "boolean"
},
"local_service_name": {
"default": "kong",
"description": "The name of the service as displayed in Zipkin.",
"type": "string"
},
"phase_duration_flavor": {
"default": "annotations",
"description": "Specify whether to include the duration of each phase as an annotation or a tag.",
"enum": [
"annotations",
"tags"
],
"type": "string"
},
"propagation": {
"default": {
"default_format": "b3"
},
"properties": {
"clear": {
"description": "Header names to clear after context extraction. This allows to extract the context from a certain header and then remove it from the request, useful when extraction and injection are performed on different header formats and the original header should not be sent to the upstream. If left empty, no headers are cleared.",
"items": {
"type": "string"
},
"type": "array"
},
"default_format": {
"default": "b3",
"description": "The default header format to use when extractors did not match any format in the incoming headers and `inject` is configured with the value: `preserve`. This can happen when no tracing header was found in the request, or the incoming tracing header formats were not included in `extract`.",
"enum": [
"aws",
"b3",
"b3-single",
"datadog",
"gcp",
"instana",
"jaeger",
"ot",
"w3c"
],
"type": "string"
},
"extract": {
"description": "Header formats used to extract tracing context from incoming requests. If multiple values are specified, the first one found will be used for extraction. If left empty, Kong will not extract any tracing context information from incoming requests and generate a trace with no parent and a new trace ID.",
"items": {
"enum": [
"aws",
"b3",
"datadog",
"gcp",
"instana",
"jaeger",
"ot",
"w3c"
],
"type": "string"
},
"type": "array"
},
"inject": {
"description": "Header formats used to inject tracing context. The value `preserve` will use the same header format as the incoming request. If multiple values are specified, all of them will be used during injection. If left empty, Kong will not inject any tracing context information in outgoing requests.",
"items": {
"enum": [
"aws",
"b3",
"b3-single",
"datadog",
"gcp",
"instana",
"jaeger",
"ot",
"preserve",
"w3c"
],
"type": "string"
},
"type": "array"
}
},
"type": "object"
},
"queue": {
"properties": {
"breaker_cooldown": {
"default": 60,
"description": "Time in seconds the circuit breaker stays open (fast-shedding entries) before it allows a single batch through to probe whether the destination has recovered.",
"maximum": 1000000,
"minimum": 0,
"type": "number"
},
"concurrency_limit": {
"default": 1,
"description": "The number of of queue delivery timers. -1 indicates unlimited.",
"enum": [
-1,
1
],
"type": "integer"
},
"failure_threshold": {
"default": 0,
"description": "Number of consecutive failed batches after which the queue opens its circuit breaker and drops entries instead of retrying. 0 disables the circuit breaker.",
"maximum": 1000000,
"minimum": 0,
"type": "integer"
},
"initial_retry_delay": {
"default": 0.01,
"description": "Time in seconds before the initial retry is made for a failing batch.",
"maximum": 1000000,
"minimum": 0.001,
"type": "number"
},
"max_batch_size": {
"default": 1,
"description": "Maximum number of entries that can be processed at a time.",
"maximum": 1000000,
"minimum": 1,
"type": "integer"
},
"max_bytes": {
"description": "Maximum number of bytes that can be waiting on a queue, requires string content.",
"type": "integer"
},
"max_coalescing_delay": {
"default": 1,
"description": "Maximum number of (fractional) seconds to elapse after the first entry was queued before the queue starts calling the handler.",
"maximum": 3600,
"minimum": 0,
"type": "number"
},
"max_entries": {
"default": 10000,
"description": "Maximum number of entries that can be waiting on the queue.",
"maximum": 1000000,
"minimum": 1,
"type": "integer"
},
"max_retry_delay": {
"default": 60,
"description": "Maximum time in seconds between retries, caps exponential backoff.",
"maximum": 1000000,
"minimum": 0.001,
"type": "number"
},
"max_retry_time": {
"default": 60,
"description": "Time in seconds before the queue gives up calling a failed handler for a batch.",
"type": "number"
}
},
"type": "object"
},
"read_timeout": {
"default": 5000,
"description": "An integer representing a timeout in milliseconds. Must be between 0 and 2^31-2.",
"maximum": 2147483646,
"minimum": 0,
"type": "integer"
},
"sample_ratio": {
"default": 0.001,
"description": "How often to sample requests that do not contain trace IDs. Set to `0` to turn sampling off, or to `1` to sample **all** requests. ",
"maximum": 1,
"minimum": 0,
"type": "number"
},
"send_timeout": {
"default": 5000,
"description": "An integer representing a timeout in milliseconds. Must be between 0 and 2^31-2.",
"maximum": 2147483646,
"minimum": 0,
"type": "integer"
},
"static_tags": {
"description": "The tags specified on this property will be added to the generated request traces.",
"items": {
"properties": {
"name": {
"type": "string"
},
"value": {
"type": "string"
}
},
"required": [
"name",
"value"
],
"type": "object"
},
"type": "array"
},
"tags_header": {
"default": "Zipkin-Tags",
"description": "The Zipkin plugin will add extra headers to the tags associated with any HTTP requests that come with a header named as configured by this property.",
"type": "string"
},
"traceid_byte_count": {
"default": 16,
"description": "The length in bytes of each request's Trace ID.",
"enum": [
8,
16
],
"type": "integer"
}
},
"type": "object"
},
"consumer": {
"additionalProperties": false,
"description": "If set, the plugin will activate only for requests where the specified has been authenticated. (Note that some plugins can not be restricted to consumers this way.). Leave unset for the plugin to activate regardless of the authenticated Consumer.",
"properties": {
"id": {
"type": "string"
}
},
"type": "object"
},
"expressions": {
"additionalProperties": true,
"type": "object"
},
"protocols": {
"default": [
"grpc",
"grpcs",
"http",
"https"
],
"description": "A set of strings representing protocols.",
"items": {
"description": "A string representing a protocol, such as HTTP or HTTPS.",
"enum": [
"grpc",
"grpcs",
"http",
"https",
"tcp",
"tls",
"tls_passthrough",
"udp",
"ws",
"wss"
],
"type": "string"
},
"type": "array"
},
"route": {
"additionalProperties": false,
"description": "If set, the plugin will only activate when receiving requests via the specified route. Leave unset for the plugin to activate regardless of the route being used.",
"properties": {
"id": {
"type": "string"
}
},
"type": "object"
},
"service": {
"additionalProperties": false,
"description": "If set, the plugin will only activate when receiving requests via one of the routes belonging to the specified Service. Leave unset for the plugin to activate regardless of the Service being matched.",
"properties": {
"id": {
"type": "string"
}
},
"type": "object"
}
}
}
관련 자료
더 알아보기 (Learn more)
- Kong Gateway의 트레이싱 기능 전반을 다루는 공식 문서예요 — Kong Gateway tracing
- Kong Gateway에서 Zipkin 트레이싱을 실제로 적용하는 방법을 소개하는 글이에요 — Tracing With Zipkin in Kong Gateway
- Zipkin 대안으로 활용할 수 있는 OpenTelemetry 플러그인 문서예요 — OpenTelemetry plugin
- Kong Gateway의 모니터링과 메트릭 수집 방법을 설명해요 — Kong Gateway monitoring and metrics