Skip to content
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

Fix bug where exception is thrown when csv source key does not exist … #3053

Merged
merged 1 commit into from
Jul 25, 2023

Conversation

graytaylor0
Copy link
Member

@graytaylor0 graytaylor0 commented Jul 23, 2023

…or is null

Description

If the source specified in the csv processor does not exist in the Event or contains a null value in the Event, an exception is thrown and the Events are dropped

ava.lang.IllegalArgumentException: argument "content" is null
    at com.fasterxml.jackson.databind.ObjectReader._assertNotNull(ObjectReader.java:2456) ~[jackson-databind-2.15.2.jar:2.15.2]
    at com.fasterxml.jackson.databind.ObjectReader.createParser(ObjectReader.java:1154) ~[jackson-databind-2.15.2.jar:2.15.2]
    at com.fasterxml.jackson.databind.ObjectReader.readValues(ObjectReader.java:1943) ~[jackson-databind-2.15.2.jar:2.15.2]
    at org.opensearch.dataprepper.plugins.processor.csv.CsvProcessor.doExecute(CsvProcessor.java:66) ~[csv-processor-2.4.0-SNAPSHOT.jar:?]
    at org.ope

This fixes that bug so that it is a no-op and the Event continues processing through the pipeline

Issues Resolved

Check List

  • New functionality includes testing.
  • New functionality has been documented.
    • New functionality has javadoc added
  • Commits are signed with a real name per the DCO

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@graytaylor0 graytaylor0 merged commit 9341a33 into opensearch-project:main Jul 25, 2023
24 checks passed
chenqi0805 pushed a commit that referenced this pull request Jul 25, 2023
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.

3 participants