我们正在从 S3 流式传输文件并对其进行处理,在处理完成后,我们将文件作为错误/存档文件上传回 S3,而从 S3 流式传输文件则流式传输数据,并且在两者之间停止处理,错误为“akka.http.scaladsl.model. EntityStreamException:实体流截断”,不确定这取决于来自 S3 的文件大小流还是损坏的文件?
val source = s3Client.download(baseConfig.bucketName.get,
content.key)._1.via(Gzip.decoderFlow).
via(Framing.delimiter(ByteString("\n"), 256,
byeFormatterFlag).map(_.utf8String))
val flow = flowDefintion(list)
val resp = source.via(flow).runWith(Sink.seq)
akka {
loglevel = "INFO"
stdout-loglevel = "INFO"
logging-filter = "akka.event.slf4j.Slf4jLoggingFilter"
http {
routing {
decode-max-size = 25m
}
parsing {
max-to-strict-bytes = 20m
max-content-length = 20m
max-chunk-size=10m
}
} }