Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make serialization key checks uniform for Hive Text file read/write. #11824

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions integration_tests/src/main/python/hive_delimited_text_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
from enum import Enum
from marks import *
from pyspark.sql.types import *
from spark_session import is_spark_cdh, with_cpu_session
from spark_session import is_before_spark_330, is_spark_cdh, with_cpu_session

hive_text_enabled_conf = {"spark.rapids.sql.format.hive.text.enabled": True,
"spark.rapids.sql.format.hive.text.read.enabled": True}
Expand Down Expand Up @@ -522,7 +522,12 @@ def create_table_with_compressed_files(spark):
"https://github.com/NVIDIA/spark-rapids/pull/7628")
@approximate_float
@ignore_order(local=True)
@pytest.mark.parametrize('mode', [TableWriteMode.CTAS, TableWriteMode.CreateThenWrite])
@pytest.mark.parametrize('mode', [pytest.param(TableWriteMode.CTAS,
marks=pytest.mark.xfail(condition=is_before_spark_330(),
reason="Spark 3.2.x seems not to set a table's "
"serialization.format to 1, by default. "
"Other Spark versions seem fine.")),
TableWriteMode.CreateThenWrite])
@pytest.mark.parametrize('input_dir,schema,options', [
('hive-delim-text/simple-boolean-values', make_schema(BooleanType()), {}),
('hive-delim-text/simple-int-values', make_schema(ByteType()), {}),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ object GpuHiveFileFormat extends Logging {
s"only $lazySimpleSerDe is currently supported for text")
}

val serializationFormat = storage.properties.getOrElse(serializationKey, "1")
val serializationFormat = storage.properties.getOrElse(serializationKey, "")
if (serializationFormat != ctrlASeparatedFormat) {
meta.willNotWorkOnGpu(s"unsupported serialization format found: " +
s"$serializationFormat, " +
Expand Down
Loading