You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "CHC (Jira)" <ji...@apache.org> on 2022/03/04 16:33:00 UTC
[jira] [Commented] (SPARK-32432) Add support for reading ORC/Parquet files with SymlinkTextInputFormat
[ https://issues.apache.org/jira/browse/SPARK-32432?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17501427#comment-17501427 ]
CHC commented on SPARK-32432:
-----------------------------
As follows example, analyze the table size will be 100 instead of 19999, which affects the join optimization, and it will attempt to deliver a large table broadcast if `manifest` file size is less than `spark.sql.autoBroadcastJoinThreshold`, and after this PR, analyze the table size will be 19999
we have files:
```
size filepath
100 hdfs:///path/to/table/manifest
9999 hdfs:///path/to/other/part-1.parquet.orc
10000 hdfs:///path/to/other/part-2.parquet.orc
```
content of `hdfs:///path/to/table/manifest` :
```
hdfs:///path/to/other/part-1.parquet.orc
hdfs:///path/to/other/part-2.parquet.orc
```
table ddl:
```
CREATE EXTERNAL TABLE symlink_orc ( name STRING, version DOUBLE, sort INT )
ROW FORMAT SERDE 'org.apache.hadoop.hive.ql.io.orc.OrcSerde'
STORED AS INPUTFORMAT 'org.apache.hadoop.hive.ql.io.SymlinkTextInputFormat'
OUTPUTFORMAT 'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat'
LOCATION 'hdfs:///path/to/table';
```
> Add support for reading ORC/Parquet files with SymlinkTextInputFormat
> ---------------------------------------------------------------------
>
> Key: SPARK-32432
> URL: https://issues.apache.org/jira/browse/SPARK-32432
> Project: Spark
> Issue Type: Improvement
> Components: SQL
> Affects Versions: 3.1.0
> Reporter: Noritaka Sekiyama
> Priority: Major
>
> Hive style symlink (SymlinkTextInputFormat) is commonly used in different analytic engines including prestodb and prestosql.
> Currently SymlinkTextInputFormat works with JSON/CSV files but does not work with ORC/Parquet files in Apache Spark (and Apache Hive).
> On the other hand, prestodb and prestosql support SymlinkTextInputFormat with ORC/Parquet files.
> This issue is to add support for reading ORC/Parquet files with SymlinkTextInputFormat in Apache Spark.
>
> Related links
> * Hive's SymlinkTextInputFormat: [https://github.com/apache/hive/blob/master/ql/src/java/org/apache/hadoop/hive/ql/io/SymlinkTextInputFormat.java]
> * prestosql's implementation to add support for reading avro files with SymlinkTextInputFormat: [https://github.com/vincentpoon/prestosql/blob/master/presto-hive/src/main/java/io/prestosql/plugin/hive/BackgroundHiveSplitLoader.java]
--
This message was sent by Atlassian Jira
(v8.20.1#820001)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org