Skip to content

ZOOKEEPER-4970: Deprecate ZKConfig methods which throw QuorumPeerConfig.ConfigException - #2309

Merged
kezhuw merged 1 commit into
apache:masterfrom
kezhuw:ZOOKEEPER-4970-deprecate-ConfigException-from-ZKConfig
Aug 30, 2025
Merged

kezhuw merged 1 commit into
apache:masterfrom
kezhuw:ZOOKEEPER-4970-deprecate-ConfigException-from-ZKConfig

Conversation

@kezhuw

@kezhuw kezhuw commented Aug 22, 2025

Copy link
Copy Markdown
Member

QuorumPeerConfig belongs to and ties with other server code. To separate a slimmer zookeeper-client jar, we have to break the dependency from ZKConfig to QuorumPeerConfig. But this is a breaking change, it would be good to deprecate these methods first to ease future migration.

Refs: ZOOKEEPER-4966, ZOOKEEPER-4970, ZOOKEEPER-233.

@kezhuw

kezhuw commented Aug 22, 2025

Copy link
Copy Markdown
Member Author

See also #2306, #2307.

…ig.ConfigException

`QuorumPeerConfig` belongs to and ties with other server code. To
separate a slimmer `zookeeper-client` jar, we have to break the
dependency from `ZKConfig` to `QuorumPeerConfig`. But this is a breaking
change, it would be good to deprecate these methods first to ease future
migration.

Refs: ZOOKEEPER-4966, ZOOKEEPER-4970, ZOOKEEPER-233.
@kezhuw
kezhuw force-pushed the ZOOKEEPER-4970-deprecate-ConfigException-from-ZKConfig branch from eb9421f to 1985e82 Compare August 22, 2025 17:36

@tisonkun tisonkun left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks!

@tisonkun

tisonkun commented Aug 22, 2025 •

Copy link
Copy Markdown
Member

To separate a slimmer zookeeper-client jar

Maybe we can instead create a zookeeper-server jar, and make the zookeeper jar depend on it now. Later, we break the dependency and rename zookeeper to zookeeper-client. This would help us to verify the situation while keeping the b/w compatibility before we do the break.

But Java has no re-export or force bundle deps. So it's still a break .. I mean, how can we properly mark a class would be located in the future client/server module, so that we don't introduce an unexpected dependency later.

@tisonkun

Copy link
Copy Markdown
Member

OK. I see #2307 now. So just go for 4.0 :D

@kezhuw
kezhuw merged commit bb76c97 into apache:master Aug 30, 2025
kezhuw added a commit to kezhuw/zookeeper that referenced this pull request Oct 1, 2025
…ig.ConfigException

`QuorumPeerConfig` belongs to and ties with other server code. To
separate a slimmer `zookeeper-client` jar, we have to break the
dependency from `ZKConfig` to `QuorumPeerConfig`. But this is a breaking
change, it would be good to deprecate these methods first to ease future
migration.

Refs: ZOOKEEPER-4966, ZOOKEEPER-4970, ZOOKEEPER-233.

Reviewers: tisonkun
Author: kezhuw

Closes apache#2309 from kezhuw/ZOOKEEPER-4970-deprecate-ConfigException-from-ZKConfig

(cherry picked from bb76c97)
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