Skip to content

Support array-of-string in formatted HEC additional fields #447

New issue

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

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from

Conversation

javabrett
Copy link
Contributor

Currently the sink cannot handle JSON fields keys/values where the value is an array of string e.g. ["value1", "value2"], when running with splunk.hec.json.event.formatted=true. HEC supports these records but the sink doesn't. This PR fixes that. See issue #444 for details.

Main change is project-wide change of fields map definition from Map<String, String> to Map<String, Object>. Jackson can then parse the array of string.

Added unit test.

Fixes #444 .

@javabrett javabrett requested a deployment to workflow-approval July 24, 2025 21:53 — with GitHub Actions Waiting
@javabrett javabrett requested a deployment to workflow-approval July 28, 2025 04:09 — with GitHub Actions Waiting
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unable to parse List type metadata under "fields" key
1 participant