Commit Graph

10779 Commits

Author SHA1 Message Date
Matthias J. Sax 88bb23617e MINOR: fix HTML for topology.optimization config (#16953)
The HTML rendering broke via https://issues.apache.org/jira/browse/KAFKA-14209 in 3.4 release. The currently shown value is some garbage org.apache.kafka.streams.StreamsConfig$$Lambda$20/0x0000000800c0cf18@b1bc7ed

cf https://kafka.apache.org/documentation/#streamsconfigs_topology.optimization

Verified the fix via running StreamsConfig#main() locally.

Reviewers: Bill Bejeck <bill@confluent.io>, Chia-Ping Tsai <chia7712@gmail.com>
2024-08-22 19:05:53 -07:00
Matthias J. Sax 65e223a76c MINOR: update Kafka Streams docs with 3.4 KIP information (#16336)
Reviewers: Jim Galasyn <jim.galasyn@confluent.io>, Bill Bejeck <bill@confluent.io>
2024-06-14 15:09:27 -07:00
Matthias J. Sax f2e78fc7b8 MINOR: update Kafka Streams docs with 3.3 KIP information (#16316)
Reviewers: Lucas Brutschy <lbrutschy@confluent.io>, Jim Galasyn <jim.galasyn@confluent.io>
2024-06-13 15:20:07 -07:00
Matthias J. Sax 6e769f861e MINOR: update Kafka Streams docs with 3.2 KIP information (#16313)
Reviewers: Bruno Cadonna <bruno@confluent.io>, Jim Galasyn <jim.galasyn@confluent.io>
2024-06-13 15:08:48 -07:00
Bruno Cadonna 028b841a4e KAFKA-16017: Checkpoint restored offsets instead of written offsets (#15177)
Kafka Streams checkpoints the wrong offset when a task is closed during
restoration. If under exactly-once processing guarantees a
TaskCorruptedException happens, the affected task is closed dirty, its
state content is wiped out and the task is re-initialized. If during
the following restoration the task is closed cleanly, the task writes
the offsets that it stores in its record collector to the checkpoint
file. Those offsets are the offsets that the task wrote to the changelog
topics. In other words, the task writes the end offsets of its changelog
topics to the checkpoint file. Consequently, when the task is
initialized again on the same Streams client, the checkpoint file is
read and the task assumes it is fully restored although the records
between the last offsets the task restored before closing clean and
the end offset of the changelog topics are missing locally.

The fix is to clear the offsets in the record collector on close.

Cherry-pick of 19727f8

Reviewer: Lucas Brutschy <lbrutschy@confluent.io>
2024-01-12 10:58:07 +01:00
Robert Wagner a618f2095f KAFKA-15755: LeaveGroupResponse v0 - v2 loses its member under certain error conditions (#14635)
This patch fixes a bug in the LeaveGroupResponse construction. Basically, when a top level error is set, no members are expected but the current check always requires one for versions prior to version 3.

Reviewers: David Jacot <djacot@confluent.io>
(cherry picked from commit 3fd6293449)
2023-11-16 10:30:24 +01:00
Matthias J. Sax bc435f07e3 HOTFIX: remove unused import to fix checkstyle error 2023-10-30 14:54:10 -07:00
Matthias J. Sax 0c637ba16e KAFKA-15602: revert KAFKA-4852 (#14617)
This PR reverts
 - 51dbd175b0
 - 496ae054c2

Reviewers:  Philip Nee <pnee@confluent.io>, Guozhang Wang <guozhang@confluent.io>
2023-10-30 14:44:49 -07:00
Greg Harris 7a3085ce69 KAFKA-14767: Fix missing commitId build error after git gc (#13315)
git gc moves commit hashes from individual .git/refs/heads/ to .git/packed-refs which is not read
by the determineCommitId function.

Replace the existing lookup within the .git directory with a GrGit lookup that handles packed and
unpacked refs transparently.

Reviewers: Ismael Juma <ismael@juma.me.uk>
2023-10-23 09:45:28 -07:00
Matthias J. Sax c229972643 KAFKA-15378: fix streams upgrade system test (#14539)
Fixing bad test setup. We tried to fix an upgrade bug for FK-joins in 3.1 release, but it later turned out that the PR was not sufficient to fix it. We finally fixed in 3.4 release.

This PR updates the system test matrix to only test working versions with FK-joins, limited to available test versions.

Reviewers: Guozhang Wang <wangguoz@gmail.com>, Hao Li <hli@confluent.io>, Mickael Maison <mickael.maison@gmail.com>
2023-10-20 16:42:15 -07:00
Matthias J. Sax 89a275fb54
MINOR: upgrade Kafka versions for system tests (#14499)
Reviewers: Bill Bejeck <bill@confluent.io>
2023-10-05 10:59:56 -07:00
Divij Vaidya 493452ced7 Upgrade Jetty to 9.4.52.v20230823 (#14438)
Reviewers: Viktor Somogyi-Vass <viktorsomogyi@gmail.com>, Luke Chen <showuon@gmail.com>, Satish Duggana <satishd@apache.org>
2023-09-26 08:51:09 +00:00
Manikumar Reddy 71310ac711 KAFKA-15502: Update SslEngineValidator to handle large stores (#14445)
We have observed an issue where inter broker SSL listener is not coming up when running with TLSv3/JDK 17 .
SSL debug logs shows that TLSv3 post handshake messages >16K are not getting read and causing SslEngineValidator process to stuck while validating the provided trust/key store.

- Right now, WRAP returns if there is already data in the buffer. But if we need more data to be wrapped for UNWRAP to succeed, we end up looping forever. To fix this, now we always attempt WRAP and only return early on BUFFER_OVERFLOW.
- Update SslEngineValidator to unwrap post-handshake messages from peer when local handshake status is FINISHED.

Reviewers: Rajini Sivaram <rajinisivaram@googlemail.com>
2023-09-26 12:37:50 +05:30
David Arthur 04866a2a08 KAFKA-15450 Don't allow ZK migration with JBOD (#14367)
Reviewers: Ron Dagostino <rndgstn@gmail.com>
2023-09-12 13:08:09 -04:00
atu-sharm ec1ab53dcd KAFKA-15338: The metric group documentation for metrics added in KAFKA-13945 is incorrect (#14221)
Reviewers: Matthias J. Sax <matthias@confluent.io>
2023-09-07 19:07:00 -07:00
Vincent Jiang 6624d07034 KAFKA-15375: fix broken clean shutdown detection logic in LogManager
When running in kraft mode, LogManager.startup is called in a different thread than the main broker (#14239)
startup thread (by BrokerMetadataPublisher when the first metadata update is received.) If a fatal
error happens during broker startup, before LogManager.startup is completed, LogManager.shutdown may
 mark log dirs as clean shutdown improperly.

This PR includes following change:
1. During LogManager startup time:
  - track hadCleanShutdwon info for each log dir
  - track loadLogsCompleted status for each log dir
2. During LogManager shutdown time:
  - do not write clean shutdown marker file for log dirs which have hadCleanShutdown==false and loadLogsCompleted==false

Reviewers: Colin P. McCabe <cmccabe@apache.org>
2023-08-30 12:41:46 -07:00
Greg Harris 938edea6b5 KAFKA-15211: Mock InvalidParameterException in DistributedConfigTest (#14039)
Signed-off-by: Greg Harris <greg.harris@aiven.io>
Reviewed-by: Chris Egerton <chris.egerton@aiven.io>
2023-08-24 16:09:56 -07:00
Yash Mayya 65c4544301 KAFKA-15377: Don't expose externalized secret values in tasks-config API endpoint (#14244)
Reviewers: Greg Harris <greg.harris@aiven.io>
2023-08-24 16:09:50 -07:00
Greg Harris 3bbd614664 KAFKA-15393: Improve shutdown behavior in MM2 integration tests (#14278)
Reviewers: Yash Mayya <yash.mayya@gmail.com>, Chris Egerton <chrise@aiven.io>
2023-08-24 12:41:53 -07:00
Omnia G.H Ibrahim e173a826bc
KAFKA-15102: Add replication.policy.internal.topic.separator.enabled property to MirrorMaker 2 (KIP-949) (#14082)
Reviewers: Chris Egerton <chrise@aiven.io>
2023-08-15 20:10:53 -04:00
Greg Harris e21aa5e7a2 KAFKA-15202: Fix MM2 offset translation when syncs are variably spaced (#14156)
Reviewers: Chris Egerton <chrise@aiven.io>
2023-08-10 13:52:53 -07:00
Greg Harris f8f4b752ff MINOR: Optimize runtime of MM2 integration tests by batching transactions (#13816)
Reviewers: Chris Egerton <chrise@aiven.io>
2023-08-10 13:52:41 -07:00
Luke Chen 7c464deab7 Merge branch '3.4' of https://github.com/apache/kafka into 3.4 2023-08-10 11:22:39 +08:00
Luke Chen 0b3a5d7061 MINOR: Update 3.4 branch version to 3.4.1-SNAPSHOT 2023-08-10 11:21:11 +08:00
José Armando García Sancio 9f6f8bfe9e KAFKA-15100; KRaft data race with the expiration service (#14141)
The KRaft client uses an expiration service to complete FETCH requests that have timed out. This expiration service uses a different thread from the KRaft polling thread. This means that it is unsafe for the expiration service thread to call tryCompleteFetchRequest. tryCompleteFetchRequest reads and updates a lot of states that is assumed to be only be read and updated from the polling thread.

The KRaft client now does not call tryCompleteFetchRequest when the FETCH request has expired. It instead will send the FETCH response that was computed when the FETCH request was first handled.

This change also fixes a bug where the KRaft client was not sending the FETCH response immediately, if the response contained a diverging epoch or snapshot id.

Reviewers: Jason Gustafson <jason@confluent.io>
2023-08-09 08:21:40 -07:00
Colin Patrick McCabe b8732bb649 HOFIX: fix missing import in SnapshottableHashTableTest.java 2023-08-08 23:11:21 -07:00
Colin Patrick McCabe cbe847c457 KAFKA-15271: Historicalterator can exposes elements that are too new (#14125)
A HistoricalIterator at epoch N is supposed to only reveal elements at epoch N or earlier. However,
due to a bug, we sometimes will reveal elements which are at a newer epoch than N. The bug does
not affect elements that are in the latest epoch (aka topTier). It only affects elements that are
newer than N, but which do not persist until the latest epoch.  This PR fixes the bug and adds a
unit test for this case.

Reviewers: David Arthur <mumrah@gmail.com>
2023-08-08 22:36:09 -07:00
José Armando García Sancio a33681d782 KAFKA-15312; Force channel before atomic file move (#14162)
On ext4 file systems we have seen snapshots with zero-length files. This is possible if
the file is closed and moved before forcing the channel to write to disk.

Reviewers: Ron Dagostino <rndgstn@gmail.com>, Alok Thatikunta <athatikunta@confluent.io>
2023-08-08 15:07:05 -07:00
Matthias J. Sax e68045ed1b MINOR: update Kafka Streams state.dir doc (#14155)
Default state directory was changes in 2.8.0 release (cf KAFKA-10604)

Reviewers: Guozhang Wang <wangguoz@gmail.com>
2023-08-07 10:38:23 -07:00
sciclon2 e046a89b9c KAFKA-15243: Set decoded user names to DescribeUserScramCredentialsResponse (#14094)
Reviewers: Manikumar Reddy <manikumar.reddy@gmail.com>
2023-07-27 13:17:38 +05:30
Yash Mayya e92e920031
KAFKA-15216: InternalSinkRecord::newRecord should not ignore new headers (#14044)
Reviewers: Chris Egerton <chrise@aiven.io>
2023-07-20 10:28:28 -04:00
Yash Mayya 278c4cde7b
KAFKA-15091: Fix misleading Javadoc for SourceTask::commit (#13948)
Reviewers: Chris Egerton <chrise@aiven.io>
2023-07-18 16:41:09 -04:00
Sambhav Jain 3808bda679
KAFKA-14938: Fixing flaky test testConnectorBoundary (#13646)
Reviewers: Sagar Rao <sagarmeansocean@gmail.com>, Yash Mayya <yash.mayya@gmail.com>,
Sudesh Wasnik <swasnik@confluent.io>, Chris Egerton <chrise@aiven.io>
2023-07-12 12:00:26 -04:00
Yash Mayya 4f270f271d
MINOR: Replace synchronization with atomic update in Connect's StateTracker::changeState method (#13934)
Reviewers: Chris Egerton <chrise@aiven.io>
2023-06-29 15:11:52 -04:00
Bo Gao a25cc752a4 KAFKA-15053: Use case insensitive validator for security.protocol config (#13831)
Fixed a regression described in KAFKA-15053 that security.protocol only allows uppercase values like PLAINTEXT, SSL, SASL_PLAINTEXT, SASL_SSL. With this fix, both lower case and upper case values will be supported (e.g. PLAINTEXT, SSL, SASL_PLAINTEXT, SASL_SSL, plaintext, ssl, sasl_plaintext, sasl_ssl)

Reviewers: Chris Egerton <chrise@aiven.io>, Divij Vaidya <diviv@amazon.com>
2023-06-29 08:29:36 +00:00
Manyanda Chitimbo cdafa2fa7e MINOR: Bump requests (python package) from 2.24.0 to 2.31.0 in /tests (#13903)
Update "requests" lib used in system tests to version "2.31.0" to fix CVE-2023-32681: Unintended leak of Proxy-Authorization header in requests

Reviewers: Divij Vaidya <diviv@amazon.com>
2023-06-28 13:23:39 +00:00
minjian.cai 667bb1e915
MINOR: Fix typos for connect (#13885)
Reviewers: Chris Egerton <chrise@aiven.io>
2023-06-20 16:25:40 -04:00
Josep Prat 338d4a8197
MINOR: fix wrong merge conflict resolution for LICENSE-binary
Signed-off-by: Josep Prat <josep.prat@aiven.io>
2023-06-19 12:33:45 +02:00
Manyanda Chitimbo 323d218e64
KAFKA-15096: Update snappy-java to 1.1.10.1 (#13865)
The release notes are available at https://github.com/xerial/snappy-java/releases/tag/v1.1.10.1
https://github.com/google/snappy/releases/tag/1.1.9
https://github.com/xerial/snappy-java/releases/tag/v1.1.9.1
https://github.com/xerial/snappy-java/releases/tag/v1.1.10.0

Reviewers:  Divij Vaidya <diviv@amazon.com>, Josep Prat <josep.prat@aiven.io>
2023-06-19 12:22:51 +02:00
Luke Chen 42e2758351
MINOR: use debug level to log handleCommit (#13763)
Reviewers: Josep Prat <josep.prat@aiven.io>, Federico Valeri <fedevaleri@gmail.com>
2023-05-26 09:37:21 +08:00
Luke Chen 6e7a6810c9
MINOR: update 3.4.1 licence (#13744)
update licence binary for 3.4.1

Reviewers: Mickael Maison <mickael.maison@gmail.com>
2023-05-24 09:40:56 +08:00
atu-sharm b80152c88e KAFKA-15015: Explicit on reload4j version (#13745)
Defining a specific version for reload4j

Reviewers: Luke Chen <showuon@gmail.com>
2023-05-24 09:34:53 +08:00
Mickael Maison a08f2c51db MINOR: Don't throw if MirrorMaker topics already exist (#13005)
Reviewers: Luke Chen <showuon@gmail.com>
2023-05-23 18:30:42 +08:00
egyedt f683178805 Fix log DateTime format unit test (#13441)
Reviewers: Viktor Somogyi-Vass <viktorsomogyi@gmail.com>
2023-05-23 18:29:55 +08:00
Matthias J. Sax 2f13471181 KAFKA-14862 (HOTFIX): Fix ConcurrentModificationException (#13734)
Reviewers: Walker Carlson <<wcarlson@confluent.io>
2023-05-22 10:23:00 +08:00
Manikumar Reddy bf7bc5399c MINOR: Add System Properties to config documentation section (#13737)
Reviewers: Josep Prat <josep.prat@aiven.io>
2023-05-20 21:57:25 +05:30
Colin Patrick McCabe 8f89a12c8e MINOR: fix some flaky KRaft-related tests (#13543) (#13543)
In SharedServer, fix some cases where a volatile variable could change to null while we were using
it, during shutdown. This is mainly a junit test issue, although it could also cause ugly error
messages during shutdown when running the server in a production context.

Fix a race in KafkaEventQueueTest.testSize.

Reviewers: David Arthur <mumrah@gmail.com>
2023-05-15 16:26:01 +08:00
atu-sharm e2f4929f34 KAFKA-14994: jose4j is vulnerable to CVE- Improper Cryptographic Algorithm (#13717)
Reviewers: Manikumar Reddy <manikumar.reddy@gmail.com>
2023-05-13 17:03:26 +05:30
Divij Vaidya dd93665095 MINOR: Update dependencies (minor versions only) (#13673)
All dependency upgrades in the PR are minor upgrades with backward compatible changes. Note that no major version for dependencies have been changed to make it a low risk change. No code changes are required for any of these dependencies.

Reviewers: Luke Chen <showuon@gmail.com>
2023-05-12 17:52:32 +08:00
Luke Chen cb3810225f Merge branch '3.4' of https://github.com/apache/kafka into 3.4 2023-05-12 17:51:08 +08:00