Amazon s3 将AWS S3 bucket用作安装在本地计算机上的Spring云数据流服务器中的接收器

Amazon s3 将AWS S3 bucket用作安装在本地计算机上的Spring云数据流服务器中的接收器,amazon-s3,spring-cloud,spring-cloud-dataflow,Amazon S3,Spring Cloud,Spring Cloud Dataflow,我在本地计算机上安装了一个Spring云数据流服务器。在创建从源(文件)到AWS-S3作为接收器的流时,出现以下错误: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.cloud.aws.context.support.io.ResourceLoaderBeanPostProcessor#0': Cannot resolv

我在本地计算机上安装了一个Spring云数据流服务器。在创建从源(文件)到AWS-S3作为接收器的流时,出现以下错误:

org.springframework.beans.factory.BeanCreationException: Error creating bean with name     'org.springframework.cloud.aws.context.support.io.ResourceLoaderBeanPostProcessor#0': Cannot resolve reference to bean 'amazonS3' while setting constructor argument; nested exception is
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'amazonS3' defined in
org.springframework.cloud.stream.app.s3.AmazonS3Configuration: Bean instantiation via factory method failed; nested exception is 
org.springframework.beans.BeanInstantiationException: Failed to instantiate
[com.amazonaws.services.s3.AmazonS3]: Factory method 'amazonS3' threw exception;
nested exception is java.lang.IllegalStateException: There is not EC2 meta data available, because the application is not running in the EC2 environment. Region detection is only possible if the application is running on a EC2 instance
原因:

Caused by: org.springframework.beans.factory.BeanCreationException: Error 
creating bean with name 'amazonS3' defined in org.springframework.cloud.stream.app.s3.AmazonS3Configuration: Bean instantiation via factory method failed; nested exception is
 org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.amazonaws.services.s3.AmazonS3]: Factory method 'amazonS3' threw exception;
 nested exception is java.lang.IllegalStateException: There is not EC2 meta data available, because the application is not running in the EC2 environment. Region detection is only possible if the application is running on a EC2 instance
我观察到的是,如果AWSEC2上安装了SpringCloudDataflow服务器,S3只能用作接收器


是否有任何方式可以使用安装在本地计算机上的Spring Cloud Data Flow Server连接到AWS S3 bucket并使用与sink相同的数据流服务器

对于Spring Cloud Brixton.SR7版本,在您的开发环境中手动配置您将在application.properties中设置的区域可能是一个配置问题(或.xml、.yml,无论您在使用什么)。此参数应仅适用于您的开发环境,除非您确实需要在生产环境中指定它

cloud.aws.region.static=us-east-1
我还必须为dev设置下一个属性,但也许您不需要它

cloud.aws.stack.auto=false

您可以分享您的流定义吗?另外,了解您使用的文件源和s3接收器的版本也很有用。