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

KAFKA-12800: Configure generator to fail on trailing JSON tokens #10717

Merged
merged 1 commit into from
May 25, 2021

Conversation

cursedquail
Copy link
Contributor

See #10709 for an example of this happening.

The tl;dr is that Jackson will ignore trailing tokens by default, but other Json parsers cannot be configured to ignore them. This makes sure we don't regress :).

Testing

I ran ./gradlew processMessages and saw that everything completed succesfully. I then put a trailing } into one of the files and saw that processMessages failed.

Committer Checklist (excluded from commit message)

  • Verify design and implementation
  • Verify test coverage and CI build status
  • Verify documentation (including upgrade notes)

@dajac dajac self-requested a review May 18, 2021 18:30
Copy link
Member

@dajac dajac left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for the patch.

@dajac dajac merged commit 63b6db3 into apache:trunk May 25, 2021
@cursedquail cursedquail deleted the KAFKA-12800 branch May 25, 2021 13:19
ijuma added a commit to ijuma/kafka that referenced this pull request May 26, 2021
…e-allocations-lz4

* apache-github/trunk: (43 commits)
  KAFKA-12800: Configure generator to fail on trailing JSON tokens (apache#10717)
  MINOR: clarify message ordering with max in-flight requests and idempotent producer (apache#10690)
  MINOR: Add log identifier/prefix printing in Log layer static functions (apache#10742)
  MINOR: update java doc for deprecated methods (apache#10722)
  MINOR: Fix deprecation warnings in SlidingWindowedCogroupedKStreamImplTest (apache#10703)
  KAFKA-12499: add transaction timeout verification (apache#10482)
  KAFKA-12620 Allocate producer ids on the controller (apache#10504)
  MINOR: Kafka Streams code samples formating unification (apache#10651)
  KAFKA-12808: Remove Deprecated Methods under StreamsMetrics (apache#10724)
  KAFKA-12522: Cast SMT should allow null value records to pass through (apache#10375)
  KAFKA-12820: Upgrade maven-artifact dependency to resolve CVE-2021-26291
  HOTFIX: fix checkstyle issue in KAFKA-12697
  KAFKA-12697: Add OfflinePartitionCount and PreferredReplicaImbalanceCount metrics to Quorum Controller (apache#10572)
  KAFKA-12342: Remove MetaLogShim and use RaftClient directly (apache#10705)
  KAFKA-12779: KIP-740, Clean up public API in TaskId and fix TaskMetadata#taskId() (apache#10735)
  KAFKA-12814: Remove Deprecated Method StreamsConfig getConsumerConfigs (apache#10737)
  MINOR: Eliminate redundant functions in LogTest suite (apache#10732)
  MINOR: Remove unused maxProducerIdExpirationMs parameter in Log constructor (apache#10723)
  MINOR: Updating files with release 2.7.1 (apache#10660)
  KAFKA-12809: Remove deprecated methods of Stores factory (apache#10729)
  ...
ijuma added a commit to ijuma/kafka that referenced this pull request May 27, 2021
…nups

* apache-github/trunk:
MINOR: Adjust parameter ordering of `waitForCondition` and
`retryOnExceptionWithTimeout` (apache#10759)
KAFKA-12796: Removal of deprecated classes under streams-scala
(apache#10710)
KAFKA-12819: Add assert messages to MirrorMaker tests plus other
quality of life improvements (apache#10762)
  Update implementation.html (apache#10771)
  MINOR: Log constructor: Flip logical NOT for readability (apache#10756)
MINOR: deprecate TaskMetadata constructor and add KIP-740 notes to
upgrade guide (apache#10755)
  MINOR: Log more information when producer snapshot is written (apache#10757)
  KAFKA-12260: Avoid hitting NPE for partitionsFor (apache#10017)
MINOR: add window verification to sliding-window co-group test
(apache#10745)
KAFKA-12800: Configure generator to fail on trailing JSON tokens
(apache#10717)
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.

2 participants