paimon icon indicating copy to clipboard operation
paimon copied to clipboard

[Bug] SparkCatalog converts catalog option keys to lower case

Open tachun-shen-appier opened this issue 2 months ago • 0 comments

Search before asking

  • [x] I searched in the issues and found nothing similar.

Paimon version

1.2.0

Compute Engine

Spark

Minimal reproduce step

SparkCatalog::initialize accepts a CaseInsensitiveStringMap as the input and Options.fromMap(options) will create an Options with lower case keys. https://github.com/apache/paimon/blob/release-1.2.0/paimon-spark/paimon-spark-common/src/main/java/org/apache/paimon/spark/SparkCatalog.java#L125

What doesn't meet your expectations?

Sometimes the catalog options should be case sensitive. For example, the jdbc.socketFactory option will be passed to the PostgreSQL JDBC driver and the driver only recognizes socketFactory, not socketfactory.

We can fix this problem by using the original case sensitive map Options.fromMap(options.asCaseSensitiveMap()).

Anything else?

No response

Are you willing to submit a PR?

  • [x] I'm willing to submit a PR!

tachun-shen-appier avatar Nov 05 '25 14:11 tachun-shen-appier