vector
vector copied to clipboard
DataDog Lambda Extension Integration - ERROR: invalid type: map, expected byte array
A note for the community
- Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
- If you are interested in working on this issue or have submitted a pull request, please leave a comment
Problem
Hello,
I'm trying to post logs/metrics from Lambda function to Vector Aggregator using DataDog lambda extension. This should be now supported see this
I get an error when i test this:
The error is:
024-01-16 15:26:14 UTC | DD_EXTENSION | DEBUG | The payload was not too big, returning the full payload
2024-01-16 15:26:14 UTC | DD_EXTENSION | DEBUG | The payload was not too big, returning the full payload
2024-01-16 15:26:14 UTC | DD_EXTENSION | INFO | Successfully posted payload to "https://vector-agg.test.com/api/v1/series", the agent will only log transaction success every 500 transactions
2024-01-16 15:26:14 UTC | DD_EXTENSION | DEBUG | SyncForwarder has flushed 1 transactions
2024-01-16 15:26:14 UTC | DD_EXTENSION | DEBUG | Demultiplexer: sendIterableSeries: stop routine
2024-01-16 15:26:14 UTC | DD_EXTENSION | WARN | failed to post http payload. code=400 host=vector-agg.test.com response=
{
"code": 400,
"message": "Error parsing JSON: Error("invalid type: map, expected byte array", line: 1, column: 12)"
}
Configuration
I'm injecting the Vector URL to the Lambda function as environment variable as below:
DD_VECTOR_LOGS_ENABLED true
DD_VECTOR_LOGS_URL https://vector-agg.test.com/
DD_VECTOR_METRICS_ENABLED true
DD_VECTOR_METRICS_URL https://vector-agg.test.com/
The lambda code I'm testing with is forked from here.
In Vector Aggregator there's a DataDog agent source configured as below that sinks to stdout:
sources:
datadog_agent:
address: 0.0.0.0:8282
type: datadog_agent
multiple_outputs: true
### Version
vector 0.32.1 (x86_64-apple-darwin 9965884 2023-08-21 14:52:38.330227446)
### Additional Context
https://discord.com/channels/742820443487993987/1196848735188177087
I changed this to a feature since the datadog_agent
source wasn't designed to receive data from the Datadog Lambda Extension. Thanks for opening!
Any update on this feature?
Is there a workaround solution for this error we can rely upon till we get the datadog_lambda_extension
as a source?
As a workaround, though I haven't tested this, I think you could likely use the http
source to receive the log events and the datadog_agent
source to receive metric events. The http
source just doesn't do the same parsing of incoming payloads.
Hey all, any news on this? Is it still unsupported?
Hey all, any news on this? Is it still unsupported?
It is still unsupported.