Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/amazon-s3/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Apache spark 当从包含大量文件的s3存储桶读取时,AWS粘合作业在从选项创建动态帧时失败_Apache Spark_Amazon S3_Parquet_Aws Glue - Fatal编程技术网

Apache spark 当从包含大量文件的s3存储桶读取时,AWS粘合作业在从选项创建动态帧时失败

Apache spark 当从包含大量文件的s3存储桶读取时,AWS粘合作业在从选项创建动态帧时失败,apache-spark,amazon-s3,parquet,aws-glue,Apache Spark,Amazon S3,Parquet,Aws Glue,s3存储桶中的数据如下所示。。。 s3://bucketName/prefix/userId/XYZ.gz 大约有2000万用户,在每个用户的子文件夹中,将有1-10个文件 我的胶水工作是这样开始的 datasource0=glueContext。从选项(“s3”,{'paths':[“s3://bucketname/prefix/”],'useS3ListImplementation':True,'recurse':True,'groupFiles':'inPartition','groupS

s3存储桶中的数据如下所示。。。 s3://bucketName/prefix/userId/XYZ.gz

大约有2000万用户,在每个用户的子文件夹中,将有1-10个文件

我的胶水工作是这样开始的

datasource0=glueContext。从选项(“s3”,{'paths':[“s3://bucketname/prefix/”],'useS3ListImplementation':True,'recurse':True,'groupFiles':'inPartition','groupSize':100*1024*1024},format=“json”,transformation\u ctx=“datasource0”)

如上图所示,我尝试了一系列优化,如groupFiles、groupSize和uses3list实现

我使用G.2X worker实例为作业提供最大内存

但是,此作业在第一行始终失败,在启用UseS3ListImplements时出现“SDKClientException,无法执行HTTP请求:不支持的记录版本未知-0.0”,以及“无法执行HTTP请求:在握手期间收到关闭通知”错误

从监控中,我观察到这个作业只使用一个执行器,尽管我已经分配了10个(在某些运行中是20个),并且驱动程序内存正在增长到100%,CPU徘徊在50%左右

我知道我的s3文件夹的组织方式不是最好的。考虑到这种结构,有没有办法让这种胶水工作起来

我的目标是一次性将这些历史文件夹中的json数据转换为拼花地板。我们也欢迎任何更好的方法来实现这一点