Skip to content

[KYUUBI #7435][SERVER] Honor server-level kyuubi.server.info.provider in getInfo#7519

Open
Sunwoo-Shin wants to merge 1 commit into
apache:masterfrom
Sunwoo-Shin:kyuubi-7435-honor-server-info-provider
Open

[KYUUBI #7435][SERVER] Honor server-level kyuubi.server.info.provider in getInfo#7519
Sunwoo-Shin wants to merge 1 commit into
apache:masterfrom
Sunwoo-Shin:kyuubi-7435-honor-server-info-provider

Conversation

@Sunwoo-Shin

@Sunwoo-Shin Sunwoo-Shin commented Jun 18, 2026

Copy link
Copy Markdown

Why are the changes needed?

Closes #7435.

kyuubi.server.info.provider was declared .serverOnly, so KyuubiConf#getUserDefaults stripped it from the per-session conf that KyuubiSessionManager#openSession builds. As a result KyuubiSessionImpl#getInfo read it through sessionConf.get(SERVER_INFO_PROVIDER), which never saw the server-level value and always returned the hard-coded default ENGINE. Setting kyuubi.server.info.provider=SERVER in kyuubi-defaults.conf was therefore silently ignored, and every GetInfo request waited for the engine to launch and forwarded to it instead of being answered by the server directly.

SERVER_INFO_PROVIDER is only read on the server frontend (KyuubiSessionImpl#getInfo); the engine never reads it. Dropping the serverOnly flag lets the server-level value flow into the session conf so getInfo honors it, while an explicit per-session value still wins as before.

Affected versions: 1.11.1.

How was this patch tested?

Added KyuubiServerInfoProviderSuite, which boots a server with kyuubi.server.info.provider=SERVER set only at the server level (no per-session override) and asserts GetInfo(CLI_DBMS_NAME) returns Apache Kyuubi. Before the fix it returns the engine name (Spark SQL).

build/mvn test -pl kyuubi-server -am \
  -Dtest=none \
  -DwildcardSuites=org.apache.kyuubi.operation.KyuubiServerInfoProviderSuite

Was this patch authored or co-authored using generative AI tooling?

Assisted-by: Claude:claude-opus-4-8

Comment on lines +301 to +306
// SERVER_INFO_PROVIDER is `.serverOnly`, so KyuubiConf.getUserDefaults strips it from
// sessionConf. Unless the client set it explicitly for this session, fall back to the
// server-level conf so the operator's kyuubi-defaults.conf setting is honored.
val provider = sessionConf.getOption(SERVER_INFO_PROVIDER.key)
.getOrElse(sessionManager.getConf.get(SERVER_INFO_PROVIDER))
provider match {

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.

Would removing serverOnly from SERVER_INFO_PROVIDER be sufficient?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Agreed — cleaner. kyuubi.server.info.provider is only consumed by KyuubiSessionImpl#getInfo, never by the engine, so dropping serverOnly is safe.

Reverted the getInfo change, removed the flag, and added KyuubiServerInfoProviderSuite.

…ovider in getInfo

kyuubi.server.info.provider is `.serverOnly`, so KyuubiConf.getUserDefaults
strips it from the per-session conf and KyuubiSessionImpl#getInfo always saw the
default ENGINE, ignoring the operator's kyuubi-defaults.conf. The provider is
only read on the server frontend, never on the engine, so drop the serverOnly
flag and let the server-level value flow into the session conf.
@Sunwoo-Shin Sunwoo-Shin force-pushed the kyuubi-7435-honor-server-info-provider branch from 02302d2 to 81db479 Compare June 19, 2026 02:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] kyuubi.server.info.provider set in kyuubi-defaults.conf is silently ignored

2 participants