We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
You can continue the conversation there. Go to discussion →
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hello. I periodically get an error:
{ "_index": "vector-dev-2023-08-15", "_id": "p8of-4kB8-sMq-fMul89", "_version": 1, "_score": null, "_source": { "error": "Missing fields on event: [\".service_name\"]", "error_type": "template_failed", "host": "vector-j89tn", "internal_log_rate_limit": true, "message": "Failed to render template for \"index\".", "metadata": { "kind": "event", "level": "ERROR", "module_path": "vector::internal_events::template", "target": "vector::internal_events::template" }, "pid": 1, "source_type": "internal_logs", "stage": "processing", "timestamp": "2023-08-15T21:35:06.829736905Z", "vector": { "component_id": "opensearch", "component_kind": "sink", "component_name": "opensearch", "component_type": "elasticsearch" } }, "fields": { "timestamp": [ "2023-08-15T21:35:06.829Z" ] }, "sort": [ 1692135306829 ] }
But I can't catch an event where this field is not present. I catch through type: "filter".
type: "filter"
customConfig: data_dir: /var/lib/vector api: enabled: true address: 127.0.0.1:8686 playground: false sources: k8s: type: kubernetes_logs exclude_paths_glob_patterns: ["*kube-system*"] extra_namespace_label_selector: vector.dev/logging=true transforms: k8s-remap: type: remap inputs: ["k8s"] source: |- kubernetes = {"service_namespace":(.kubernetes.pod_namespace), "service_name":(.kubernetes.container_name), "pod_name": (.kubernetes.pod_name), "@timestamp": (parse_timestamp!(.timestamp, format: "MMM D, YYYY @ HH:mm:ss.SSS"))} ., err = parse_json(.message) ., err = merge(., kubernetes) drop_on_error: true reroute_dropped: true k8s-reforge: type: remap inputs: ["*dropped"] source: |- ., err = {"message": (to_string(.message)), "dropped": true, "service_namespace":(.kubernetes.pod_namespace), "service_name":(.kubernetes.container_name), "pod_name": (.kubernetes.pod_name), "metadata": (.metadata), "@timestamp": (parse_timestamp!(.timestamp, format: "MMM D, YYYY @ HH:mm:ss.SSS"))} exists-service-name: type: "filter" inputs: ["k8s-remap","k8s-reforge"] condition: type: "vrl" source: |- !exists(.container_name) sinks: opensearch-debug: type: elasticsearch inputs: ["exists-service-name"] api_version: v8 endpoints: ["elasticsearch"] bulk: index: "vector-debug-%Y-%m-%d" opensearch: type: elasticsearch inputs: ["k8s-remap","k8s-reforge"] api_version: v8 endpoints: ["elasticsearch"] bulk: index: "dev-{{ .service_name }}-%Y-%m-%d"
### Version 0.31.0 ### Debug Output _No response_ ### Example Data _No response_ ### Additional Context _No response_ ### References _No response_
The text was updated successfully, but these errors were encountered:
#17487 Same problem?
Sorry, something went wrong.
No branches or pull requests
A note for the community
Problem
Hello. I periodically get an error:
But I can't catch an event where this field is not present. I catch through
type: "filter"
.Configuration
The text was updated successfully, but these errors were encountered: