You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Transform-V2] SQL lower and upper depend on the worker default locale #11949
The SQL transform functions lower() and upper() call Java String.toLowerCase() and String.toUpperCase() without an explicit locale. As a result, their output depends on the default locale of the SeaTunnel worker JVM.
For example, under the Turkish locale, lower("I") returns the dotless character ı and upper("i") returns İ, instead of the locale-independent SQL results i and I. A distributed job can therefore produce different transformed data depending on the host locale.
Steps to reproduce
Check out SeaTunnel dev.
In seatunnel-transforms-v2, invoke the existing StringFunction methods with the JVM default locale set to Turkish:
Run the corresponding test or a small Java harness.
Before the fix, the output is:
lower=ı upper=İ
The same harness passes with the proposed fix and produces:
lower=i upper=I
Expected behavior
SQL case conversion should be deterministic and independent of the worker machine’s default locale. lower("I") should return i and upper("i") should return I regardless of the JVM locale.
Environment
SeaTunnel branch: dev
Module: seatunnel-transforms-v2
JVM: Java 8+
Reproduction does not require an external connector, database, or cluster.
I have prepared a focused fix on the fork branch tagadearpit:fix/sql-string-case-locale, replacing the implicit default locale with Locale.ROOT and adding a regression test. The focused StringFunctionTest passes with 34 tests, and the transforms module verification lifecycle passes.
Activity