[SPARK-57055][SQL][DOCS] Document non-binary collation gap in DataFrameStatFunctions.bloomFilter#56114
Open
yaooqinn wants to merge 1 commit into
Open
[SPARK-57055][SQL][DOCS] Document non-binary collation gap in DataFrameStatFunctions.bloomFilter#56114yaooqinn wants to merge 1 commit into
yaooqinn wants to merge 1 commit into
Conversation
…meStatFunctions.bloomFilter ### What changes were proposed in this pull request? Add @note Scaladoc to all four DataFrameStatFunctions.bloomFilter overloads and a Migration Guide entry stating that bloom filters built over string columns use raw UTF-8 byte equality and are collation-blind for non-binary collations (UTF8_LCASE, ICU). For collation-consistent membership, the docs recommend using a UTF8_BINARY-collated column, or normalizing values manually (e.g. lower(col) for ASCII data under UTF8_LCASE). ### Why are the changes needed? Since Spark 4.0, columns may carry non-binary collations. The bloom filter path does not collation-normalize values, so users get silent inconsistent mightContain results without any documented warning. See SPARK-57055. ### Does this PR introduce _any_ user-facing change? Documentation only. ### How was this patch tested? Scaladoc renders cleanly via build/sbt 'sql-api/doc'. Behavior reproduced on master via spark-shell (see PR description for repro snippet and verbatim output). ### Scope note PySpark / R / Connect docstring synchronization is intentionally deferred to a follow-up PR to keep this change docs-only and minimal.
d65d451 to
8d22bf3
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes were proposed in this pull request?
Add
@noteScaladoc to all fourDataFrameStatFunctions.bloomFilteroverloads and a Migration Guide entry stating that bloom filters built
over string columns use raw UTF-8 byte equality and are collation-blind
for non-binary collations (UTF8_LCASE, ICU). For collation-consistent
membership, the docs recommend using a UTF8_BINARY-collated column, or
normalizing values manually (e.g.
lower(col)for ASCII data underUTF8_LCASE).
Why are the changes needed?
Since Spark 4.0, columns may carry non-binary collations. The bloom
filter path does not collation-normalize values, so users get silent
inconsistent
mightContainresults without any documented warning.See SPARK-57055.
Does this PR introduce any user-facing change?
Documentation only.
How was this patch tested?
Scaladoc renders cleanly via
build/sbt "sql-api/doc"(49s, no newwarnings).
Behavior reproduced on master via
spark-shell:No new unit tests — this is a documentation-only change with no
behavior to assert.
Scope note
PySpark / R / Connect docstring synchronization is intentionally
deferred to a follow-up PR to keep this change docs-only and minimal.