Commit Graph

14665 Commits

Author SHA1 Message Date
TengYao Chi ab4f4a5515
MINOR: Remove PaswwordEncoderConfig related entries from upgrade.html (#18362)
Reviewers: Ken Huang <s7133700@gmail.com>, TaiJuWu <tjwu1217@gmail.com>, Chia-Ping Tsai <chia7712@gmail.com>
2025-01-01 00:06:12 +08:00
TengYao Chi 09647c9b95
MINOR: Fix broken javadoc in BatchAccumulator (#18348)
Reviewers: Andrew Schofield <aschofield@confluent.io>
2024-12-31 11:03:20 +00:00
TengYao Chi 3161115ada
KAFKA-18361 Remove PasswordEncoderConfigs (#18347)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-31 00:18:23 +08:00
YunKui Lu af7f403ae3
MINOR: Optimize log printing format for AbstractHerder#validateConverterConfig (#18199)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-30 23:29:34 +08:00
Mickael Maison 4080f19c5c
KAFKA-17615 Remove KafkaServer from tests (#18271)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-30 22:57:16 +08:00
TaiJuWu 6737178c12
KAFKA-18280 fix e2e TestSecurityRollingUpgrade.test_rolling_upgrade_sasl_mechanism_phase_one (#18308)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-30 22:36:47 +08:00
TengYao Chi 585b7db482
MINOR: log4j2 upgrade follow-up (#18290)
Reviewers: PoAn Yang <payang@apache.org>, Chia-Ping Tsai <chia7712@gmail.com>
2024-12-30 20:38:58 +08:00
TaiJuWu 03f16f368b
KAFKA-18313 Fix to Kraft or remove tests associate with Zk Broker config in SocketServerTest and ReplicaFetcherThreadTest (#18327)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-30 02:27:40 +08:00
Ken Huang f2ae20a5c1
KAFKA-18316 Fix to Kraft or remove tests associate with Zk Broker config in ConnectionQuotasTest (#18279)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-30 02:20:10 +08:00
TengYao Chi 96527be90d
KAFKA-18243 Fix compatibility of Loggers class between log4j and log4j2 (#18185)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-30 01:50:52 +08:00
Ismael Juma 3654bc4513
KAFKA-18339: Fix parseRequestHeader error handling (#18340)
A minor refactoring just before merging #18295 introduced a regression and no test failed. Throw the correct exception and add test to verify it. Also refactor the code slightly to make that possible.

Thanks to Chia-Ping for catching the issue.

Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-29 09:31:14 -08:00
Ken Huang 1156d5c294
KAFKA-18315 Fix to Kraft or remove tests associate with Zk Broker config in DynamicBrokerConfigTest, ReplicaManagerTest, DescribeTopicPartitionsRequestHandlerTest, KafkaConfigTest (#18269)
Reviewers: PoAn Yang <payang@apache.org>, Chia-Ping Tsai <chia7712@gmail.com>
2024-12-30 00:47:46 +08:00
Dongnuo Lyu e47f6983df
MINOR: Replace enum name with state name when parsing `ConsumerGroupState` (#18315)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-29 23:11:55 +08:00
Ken Huang 106fd5f601
KAFKA-18354 Use log4j2 APIs to refactor LogCaptureAppender (#18338)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-29 22:50:53 +08:00
TengYao Chi e9a03b3a86
KAFKA-18314 Fix to Kraft or remove tests associate with Zk Broker config in KafkaApisTest (#18309)
Reviewers: TaiJuWu <tjwu1217@gmail.com>, Chia-Ping Tsai <chia7712@gmail.com>
2024-12-29 19:02:27 +08:00
PoAn Yang 91a2b58616
KAFKA-18359 Set zkConnect to null in LocalLeaderEndPointTest, HighwatermarkPersistenceTest, IsrExpirationTest, ReplicaManagerQuotasTest, OffsetsForLeaderEpochTest (#18344)
Reviewers: TaiJuWu <tjwu1217@gmail.com>, Chia-Ping Tsai <chia7712@gmail.com>
2024-12-29 18:23:42 +08:00
Peter Lee be4d1a6277
KAFKA-18135: ShareConsumer HB UnsupportedVersion msg mixed with Consumer HB (#18101)
Add specific error handling for unsupported version in share consumer and consumer

Reviewers: Lianet Magrans <lmagrans@confluent.io>, Andrew Schofield <aschofield@confluent.io>
2024-12-28 15:39:58 +00:00
Ken Huang bc7a1a8969
KAFKA-18317 Remove zookeeper.connect from RemoteLogManagerTest (#18283)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-28 21:51:08 +08:00
PoAn Yang e67172ce6d
MINOR: remove zkBroker from StreamsGroupHeartbeatRequest and StreamsGroupDescribeRequest (#18319)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-28 16:58:29 +08:00
mingdaoy d95cb7d65e
MINOR: remove unused previousPartition from RoundRobinPartitioner.java (#18331)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-28 16:33:32 +08:00
Ismael Juma 875da35ec3
KAFKA-18339: Remove raw unversioned direct SASL protocol (KIP-896) (#18295)
Clients that support SASL but don't implement KIP-43 (eg Kafka producer/consumer 0.9.0.x) will
fail to connect after this change.

Added unit tests and also manually tested with the console producer 0.9.0.

While testing, I noticed that the logged message when a 0.9.0 Java client is used without sasl is
slightly misleading - fixed that too.

Reviewers: Manikumar Reddy <manikumar.reddy@gmail.com>
2024-12-27 10:23:25 -08:00
PoAn Yang e6d2421136
KAFKA-18295 Remove deprecated function Partitioner#onNewBatch (#18282)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-27 18:40:19 +08:00
Ismael Juma dfb178a1d8
KAFKA-18272: Deprecated protocol api usage should be logged at info level (#18313)
This makes it possible to enable request logs for deprecated protocol api versions without enabling it for the rest. Combined with the ability to enable/disable dynamically, it makes it a bit easier to collect the information about deprecated clients that is not available via metrics.

This isn't particularly useful in trunk/4.0 since there are no deprecated api versions in these versions, but it will be useful for older branches. I intend to backport to those branches and add a release note in the backport regarding the change in behavior.

I manually verified that:
1. If the request logger is configured at `INFO` level, only deprecated protocol api versions are logged and they are logged at `INFO` level.
2. If the request logger is configured at `DEBUG` level, all requests are logged but the log level is `INFO` for deprecated protocol api versions and `DEBUG` for the rest.
3. If the request logger is configured at `WARN` level (the default), no requests are logged.

Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-27 00:04:19 -08:00
xijiu 6139840e98
KAFKA-18348 Remove the deprecated MockConsumer#setException (#18317)
Reviewers: TengYao Chi <kitingiao@gmail.com>, TaiJuWu <tjwu1217@gmail.com>, Chia-Ping Tsai <chia7712@gmail.com>
2024-12-27 12:31:23 +08:00
Ismael Juma 2e3b4cb957
KAFKA-18352: Add back DeleteGroups v0, it incorrectly tagged as deprecated (#18324)
The Sarama version listed in the KIP only supports v0.

Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-26 16:53:50 -08:00
Peter Lee c7c1364b0f
KAFKA-18274 Failed to restart controller in testing due to closed socket channel [1/2] (#18310)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-25 20:52:06 +08:00
Chung, Ming-Yen 88adb94c81
KAFKA-18093 Remove deprecated DeleteTopicsResult#values (#18250)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-25 14:46:14 +08:00
Kuan-Po Tseng 4567f39825
KAFKA-18343: Use java_pids to implement pids (#18312)
Related to KAFKA-18343,

Currently, there is an issue that the ps ax output is truncated, which causes the Kafka process ID to be unavailable. This issue can be mitigated by replacing ps ax with jcmd (i.e. using java_pids in ducktape), as it does not suffer from the truncation problem.

Reviewers: Justine Olshan <jolshan@confluent.io>
2024-12-24 14:52:26 -08:00
David Arthur 649cd6b42c
MINOR Fix conditional in Update Test Catalog workflow (#18289)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-24 09:05:37 -05:00
Kuan-Po Tseng 5a4590c020
KAFKA-18338 add log4j.yaml to test-common-api and remove unsed log4j.properties from test-common (#18294)
Reviewers: TengYao Chi <kitingiao@gmail.com>, Chia-Ping Tsai <chia7712@gmail.com>
2024-12-24 16:22:47 +08:00
Jhen-Yung Hsu a940d52070
KAFKA-18342 Use `File.exist` instead of `File.exists` to ensure the `Vagrantfile` works with Ruby 3.2+ (#18306)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-24 15:04:42 +08:00
Logan Zhu 4d6535e60d
KAFKA-18290 Remove deprecated methods of FeatureUpdate (#18246)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-24 14:53:32 +08:00
Nick Guo 1a3dce72fa
KAFKA-18289 Remove deprecated methods of DescribeTopicsResult (#18255)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-24 01:48:15 +08:00
Nick Guo 1cf514313e
KAFKA-18291 Remove deprecated methods of ListConsumerGroupOffsetsOptions (#18265)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-24 01:37:10 +08:00
Ismael Juma 6fc5c64928
MINOR: Various README tweaks (#18301)
1. Fix ambiguous statement where it could be interpreted that scalac is used for the clients module
2. Remove "in KRaft mode" because that's the only mode
3. Put IntelliJ first in IDE section and only mention the native gradle integration
4. Restore instructions for installing all projects to the local Maven repo, this was accidentally removed as part of the Scala 2.12 support removal.
2024-12-23 06:58:26 -08:00
Logan Zhu e0f35e025a
KAFKA-18278: Correct name and description for run-gradle step (#18223)
Reviewers: David Arthur <mumrah@gmail.com>, Chia-Ping Tsai <chia7712@gmail.com>
2024-12-23 09:50:08 -05:00
Sanskar Jhajharia de7a75a978
MINOR: Fix the failure in streams:testAll (#18303)
Currently, the command ./gradlew :streams:testAll as suggested in README is failing with an error. Following this commit, the command is able to pass and start running the tests in streams suite.

Reviewers: Chia-Ping Tsai <chia7712@gmail.com>, Lucas Brutschy <lbrutschy@confluent.io>
2024-12-23 15:35:08 +01:00
Ismael Juma 2e1134284c
MINOR: Add release note for Java 17 requirement (#18302)
Also remove confusing comment related to connect & Java 17 from build.gradle.
I also updated KIP-1013 to note the implications of KIP-1032.

Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-22 19:36:03 -08:00
PoAn Yang b4be178599
KAFKA-17393: Remove log.message.format.version/message.format.version (KIP-724) (#18267)
Based on [KIP-724](https://cwiki.apache.org/confluence/display/KAFKA/KIP-724%3A+Drop+support+for+message+formats+v0+and+v1), the `log.message.format.version` and `message.format.version` can be removed in 4.0.

These configs effectively a no-op with inter-broker protocol version 3.0 or higher
since Apache Kafka 3.0, so the impact should be minimal.

Reviewers: Ismael Juma <ismael@juma.me.uk>
2024-12-21 15:35:15 -08:00
Justine Olshan 8bd3746e0c
KAFKA-17705: Add Transactions V2 system tests and mark as production ready (#18132)
Added transaction version 2 to some of the system tests. Also marking TV2 as production ready.

Also fixes the defaultVersion test. 

Reviewers: Jun Rao <jun@confluent.io>
2024-12-21 14:01:54 -08:00
Ismael Juma fe56fc98fa
KAFKA-18269: Remove deprecated protocol APIs support (KIP-896, KIP-724) (#18218)
Included in this change:
1. Remove deprecated protocol api versions from json files.
3. Remove fields that are no longer used from json files (affects ListOffsets, OffsetCommit, DescribeConfigs).
4. Remove record down-conversion support from KafkaApis.
5. No longer return `Errors.UNSUPPORTED_COMPRESSION_TYPE` on the fetch path[1].
6. Deprecate `TopicConfig. MESSAGE_DOWNCONVERSION_ENABLE_CONFIG` and made the relevant
configs (`message.downconversion.enable` and `log.message.downcoversion.enable`) no-ops since
down-conversion is no longer supported. It was an oversight not to deprecate this via KIP-724.
7. Fix `shouldRetainsBufferReference` to handle null request schemas for a given version.
8. Simplify producer logic since it only supports the v2 record format now.
9. Fix tests so they don't exercise protocol api versions that have been removed.
10. Add upgrade note.

Testing:
1. System tests have a lot of failures, but those tests fail for trunk too and I didn't see any issues specific to this change - it's hard to be sure given the number of failing tests, but let's not block on that given the other testing that has been done (see below).
3. Java producers and consumers with version 0.9-0.10.1 don't have api versions support and hence they fail in an ungraceful manner: the broker disconnects and the clients reconnect until the relevant timeout is triggered.
4. Same thing seems to happen for the console producer 0.10.2 although it's unclear why since api versions should be supported. I will look into this separately, it's unlikely to be related to this PR.
5. Console consumer 0.10.2 fails with the expected error and a reasonable message[2].
6. Console producer and consumer 0.11.0 works fine, newer versions should naturally also work fine.
7. kcat 1.5.0 (based on librdkafka 1.1.0) produce and consume fail with a reasonable message[3][4].
8. kcat 1.6.0-1.7.0 (based on librdkafka 1.5.0 and 1.7.0 respectively) consume fails with a reasonable message[5].
9. kcat 1.6.0-1.7.0 produce works fine.
10. kcat 1.7.1  (based on librdkafka 1.8.2) works fine for consumer and produce.
11. confluent-go-client (librdkafka based) 1.8.2 works fine for consumer and produce.
12. I will test more clients, but I don't think we need to block the PR on that.

Note that this also completes part of KIP-724: produce v2 and lower as well as fetch v3 and lower are no longer supported.

Future PRs will remove conditional code that is no longer needed (some of that has been done in KafkaApis,
but only what was required due to the schema changes). We can probably do that in master only as it does
not change behavior.

Note that I did not touch `ignorable` fields even though some of them could have been
changed. The reasoning is that this could result in incompatible changes for clients
that use new protocol versions without setting such fields _if_ we don't manually
validate their presence. I will file a JIRA ticket to look into this carefully for each
case (i.e. if we do validate their presence for the appropriate versions, we can
set them to ignorable=false in the json file).

[1] We would return this error if a fetch < v10 was used and the compression topic config was set
to zstd, but we would not do the same for the case where zstd was compressed at the producer
level (the most common case). Since there is no efficient way to do the check for the common
case, I made it consistent for both by having no checks.
[2] ```org.apache.kafka.common.errors.UnsupportedVersionException: The broker is too new to support JOIN_GROUP version 1```
[3]```METADATA|rdkafka#producer-1| [thrd:main]: localhost:9092/bootstrap: Metadata request failed: connected: Local: Required feature not supported by broker (0ms): Permanent```
[4]```METADATA|rdkafka#consumer-1| [thrd:main]: localhost:9092/bootstrap: Metadata request failed: connected: Local: Required feature not supported by broker (0ms): Permanent```
[5] `ERROR: Topic test-topic [0] error: Failed to query logical offset END: Local: Required feature not supported by broker`

Reviewers: David Arthur <mumrah@gmail.com>
2024-12-20 19:52:00 -08:00
Ismael Juma 288d4de834
KAFKA-18334: Produce v4-v6 should be undeprecated (#18288)
Librdkafka totally breaks if produce v3 is removed - it starts sending records with record format v0.
These api versions have to be undeprecated - KIP-896 has been updated.

Reviewers: David Arthur <mumrah@gmail.com>
2024-12-20 16:59:51 -08:00
Matthias J. Sax 8c21857877
KAFKA-13722: code cleanup after deprecated StateStore.init() was removed (#18249)
We remove the deprecated overload of StateStore.init() and thus do not
need to cast any longer. This PR removes all unnecessary casts, and
additionally cleans ups all related classed to reduce warnings.

Reviewers: Bill Bejeck <bill@confluent.io>
2024-12-20 14:31:44 -08:00
Artem Livshits 3ef10a3f61
KAFKA-15370: Support Participation in 2PC (KIP-939) (1/N) (#17687)
This is just a mechanical change to make prepareTransitionTo method use named parameters instead of positional parameters.

Reviewers: Justine Olshan <jolshan@confluent.io>, Ritika Reddy <rreddy@confluent.io>
2024-12-20 14:09:32 -08:00
Chirag Wadhwa 6e61bfee91
KAFKA-18312: Added entityType: topicName to SubscribedTopicNames in ShareGroupHeartbeatRequest.json (#18285)
This PR Adds entityType: topicName to SubscribedTopicNames in ShareGroupHeartbeatRequest.json as per the recent update to kip-932.

Reviewers: Manikumar Reddy <manikumar.reddy@gmail.com>
2024-12-20 21:31:47 +05:30
PoAn Yang 748ad6a793
HOTFIX: fix incompatible types: Optional<TimestampAndOffset> cannot be converted to Option<TimestampAndOffset> (#18284)
Signed-off-by: PoAn Yang <payang@apache.org>

Reviewers: Christo Lolov <lolovc@amazon.com>
2024-12-20 14:57:33 +00:00
David Arthur af5d6c2578
MINOR Fix some test-catalog issues (#18272)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-20 08:42:57 -05:00
Ken Huang e8863c9ee2
KAFKA-18180: Move OffsetResultHolder to storage module (#18100)
Reviewers: Christo Lolov <lolovc@amazon.com>
2024-12-20 11:52:34 +00:00
David Jacot d67379c310
KAFKA-18301; Make coordinator records first class citizen (#18261)
This patch is the first one in a series to improve how coordinator records are managed. It focuses on making coordinator records first class citizen in the generator.
* Introduce `coordinator-key` and `coordinator-value` in the schema;
* Introduce `apiKey` for those. This is done to avoid relying on the version to determine the type.
* It also allows the generator to enforce some rules: the key cannot use flexible versions, the key must have a single version `0`, there must be a key and a value for a given api key, etc.
* It generates an enum with all the coordinator record types. This is pretty handy in the code.

The patch also updates the group coordinators to use those.

Reviewers: Jeff Kim <jeff.kim@confluent.io>, Andrew Schofield <aschofield@confluent.io>
2024-12-20 12:16:14 +01:00
PoAn Yang 753a003480
KAFKA-18262 Remove DefaultPartitioner and UniformStickyPartitioner (#18204)
Reviewers: Chia-Ping Tsai <chia7712@gmail.com>
2024-12-20 15:33:51 +08:00