Skip to content

[CALCITE-7852] Geode schema fails with NullPointerException when pdxSerializablePackagePath is not set - #5325

Open
vlsi wants to merge 1 commit into
apache:mainfrom
vlsi:CALCITE-7852
Open

vlsi wants to merge 1 commit into
apache:mainfrom
vlsi:CALCITE-7852

Conversation

@vlsi

@vlsi vlsi commented Oct 14, 2026

Copy link
Copy Markdown
Contributor

Jira: CALCITE-7852

Since CALCITE-7787, a model may set pdxSerializablePackagePath only when calcite.geode.pdxSerializablePackagePath.allowed is true, so a default deployment leaves the operand out. Creating a schema with a new client cache then fails in both GeodeSchemaFactory and GeodeSimpleSchemaFactory, because GeodeUtils.createClientCache passes the absent operand to new ReflectionBasedAutoSerializer(String...):

java.lang.NullPointerException: Cannot invoke "String.split(String)" because "value" is null

With the operand absent, createClientCache now creates a ReflectionBasedAutoSerializer with no class pattern.

Two new tests in GeodeSchemaFactoryTest, one per factory, create the schema without the operand after closing the client cache; both fail on main with the exception above.

The same fix was first made inside #5213 (CALCITE-7736), which now leaves createClientCache as main has it, so the two pull requests touch GeodeUtils independently.

🤖 Generated with Claude Code

…erializablePackagePath is not set

Since CALCITE-7787 a model may set pdxSerializablePackagePath only when
calcite.geode.pdxSerializablePackagePath.allowed is true, so a default
deployment leaves it out. GeodeUtils.createClientCache passed the absent
operand to new ReflectionBasedAutoSerializer(String...), which reads it
as a class pattern, and creating a schema with a new client cache failed
in both Geode schema factories:

    java.lang.NullPointerException: Cannot invoke "String.split(String)" because "value" is null

createClientCache now creates a serializer with no class pattern when the
operand is absent.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@sonarqubecloud

Copy link
Copy Markdown

@rubenada

Copy link
Copy Markdown
Contributor

Thanks for catching this @vlsi ! This was my mistake on the original ticket.

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