GitHub user MaxGekk opened a pull request:
https://github.com/apache/spark/pull/23039
[SPARK-26066][SQL] Moving truncatedString to sql/catalyst
## What changes were proposed in this pull request?
I propose to move truncatedString out of `core` to `sql/catalyst` because
it is used only in sql/catalyst for restricting number of fields converted to
strings from `TreeNode` and expressions of`StructType`. Also I introduced new
SQL config `spark.sql.debug.maxToStringFields` to control maximum number fields
up to which `truncatedString` cuts its input sequences.
## How was this patch tested?
Added a test to `QueryExecutionSuite` to check that
`spark.sql.debug.maxToStringFields` impacts to behavior of `truncatedString`.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/MaxGekk/spark-1 truncated-string-catalyst
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/spark/pull/23039.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #23039
----
commit 265a81031f670392f9a78a0b9fb130a7e3908727
Author: Maxim Gekk <maxim.gekk@...>
Date: 2018-09-25T11:31:02Z
Moving truncatedString out of core
commit 36de047eca9848288146f4e3491b437e38671105
Author: Maxim Gekk <maxim.gekk@...>
Date: 2018-11-14T21:34:40Z
Adding spark.sql.debug.maxToStringFields
----
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]