You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Hyukjin Kwon (Jira)" <ji...@apache.org> on 2019/10/08 05:45:09 UTC
[jira] [Resolved] (SPARK-24200) Read subdirectories with out
asterisks
[ https://issues.apache.org/jira/browse/SPARK-24200?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Hyukjin Kwon resolved SPARK-24200.
----------------------------------
Resolution: Incomplete
> Read subdirectories with out asterisks
> --------------------------------------
>
> Key: SPARK-24200
> URL: https://issues.apache.org/jira/browse/SPARK-24200
> Project: Spark
> Issue Type: Improvement
> Components: SQL
> Affects Versions: 2.3.0
> Reporter: kumar
> Priority: Major
> Labels: bulk-closed
>
> String folder = "/Users/test/data/* /* ";
> sparkContext.textFile(folder, 1).toJavaRDD()
> Is asterisks mandatory to read a folder -Yes, otherwise it does not read files under subdirectories.
> What if I get a folder which is having more subdirectories than the number of asterisks mentioned ?
> For example:
> 1) {{/Users/test/data/}} This would work ONLY if I get data as /Users/test/data/folder1/file.txt
> 2)How to make this expression as *generic* ? It should still work if I get a folder as: {{/Users/test/data/folder1/folder2/folder3/folder4}}
> My input folder structure is not same all the time.
> Is there anything exists in Spark to handle this kind of scenario ? I know you might have thought about this, but i am wondering why this has not been implemented ?
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org