-
Notifications
You must be signed in to change notification settings - Fork 14k
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
MINOR: Fix deprecation warnings in SlidingWindowedCogroupedKStreamImplTest #10703
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR @ijuma! This should not have slipped when we added the deprecation to the old constructor....
@@ -156,7 +156,7 @@ public void slidingWindowAggregateStreamsTest() { | |||
final TestInputTopic<String, String> testInputTopic = driver.createInputTopic( | |||
TOPIC, new StringSerializer(), new StringSerializer()); | |||
final TestOutputTopic<Windowed<String>, String> testOutputTopic = driver.createOutputTopic( | |||
OUTPUT, new TimeWindowedDeserializer<>(new StringDeserializer()), new StringDeserializer()); | |||
OUTPUT, new TimeWindowedDeserializer<>(new StringDeserializer(), Long.MAX_VALUE), new StringDeserializer()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems we setup the window with 500ms
:
SlidingWindows.withTimeDifferenceAndGrace(ofMillis(500L),...)
Thus we should pass in the same value instead of MAX_VAVLUE
.
We should also change TestRecord<String,String>
below to TestRecorded<Windowed<String>,String>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've changed the code to pass 500L
, but the TestRecord
change causes compilation errors since we explicitly use a nonWindowedRecord
:
results.add(nonWindowedRecord);
Can we address that separately? I think we can focus on fixing the deprecation warning in this PR, if that's ok with you.
@@ -212,7 +212,7 @@ public void slidingWindowAggregateOverlappingWindowsTest() { | |||
final TestInputTopic<String, String> testInputTopic = driver.createInputTopic( | |||
TOPIC, new StringSerializer(), new StringSerializer()); | |||
final TestOutputTopic<Windowed<String>, String> testOutputTopic = driver.createOutputTopic( | |||
OUTPUT, new TimeWindowedDeserializer<>(new StringDeserializer()), new StringDeserializer()); | |||
OUTPUT, new TimeWindowedDeserializer<>(new StringDeserializer(), Long.MAX_VALUE), new StringDeserializer()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
as above
Thanks. Did a follow up PR: #10745 |
…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) ...
Committer Checklist (excluded from commit message)