Java Amazon SQS旧版配置文件格式警告

Java Amazon SQS旧版配置文件格式警告,java,maven,amazon-web-services,Java,Maven,Amazon Web Services,我正在向Amazon SQS队列发布消息。在启动时,我在日志中收到以下警告 [http-nio-9090-exec-2][BasicProfileConfigLoader] The legacy profile format requires the 'profile ' prefix before the profile name. The latest code does not require such prefix, and will consider it as part of t

我正在向Amazon SQS队列发布消息。在启动时,我在日志中收到以下警告

[http-nio-9090-exec-2][BasicProfileConfigLoader] The legacy profile format 
requires the 'profile ' prefix before the profile name. The latest code does 
not require such prefix, and will consider it as part of the profile name. 
Please remove the prefix if you are seeing this warning.
我在Maven中使用以下版本的Amazon SQS:

    <dependency>
        <groupId>com.amazonaws</groupId>
        <artifactId>aws-java-sdk-sqs</artifactId>
        <version>1.11.125</version>
    </dependency>

亚马逊网站
aws java sdk sqs
1.11.125

我怎样才能摆脱这个警告

这很可能是指保存部分aws凭据的配置文件。这在您的计算机上的位置将取决于您使用的操作系统,但例如在我的Mac上,它位于\users\myname.aws\config中

旧格式如下(例如):

[profile]
地区=美国东部-1
输出=json
现在应该是这样的:

[<profilename>]
region=us-east-1
output=json
[]
地区=美国东部-1
输出=json

这解决了问题。通过从aws配置文件中删除“profile”一词,它从我的日志中删除了警告。在我的Windows 10计算机上,aws配置位于C:\Users\MyName\.aws\config。@CaleSweeney是的,我做了和你说的一样的事情&它起了作用。从我的应用程序的角度来看,这对我也起了作用。但是,AWS s3 ls会从AWS CLI命令中查找profile关键字。我仍然使用AWS CLI 1。可能是问题所在,请注意。
[<profilename>]
region=us-east-1
output=json