找不到awssdk_config_override.json文件-异常AWSSDK [英] awssdk_config_override.json file not found - Exception AWSSDK

查看:357
本文介绍了找不到awssdk_config_override.json文件-异常AWSSDK的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个非常简单的调用,可以像这样创建一个新的AmazonS3Client(使用Java AWSSDK 1.10.12):

I have a very simple call to just create a new AmazonS3Client (using Java AWSSDK 1.10.12) like this:

AmazonS3 s3Client =新的AmazonS3Client();

AmazonS3 s3Client = new AmazonS3Client();

在此通话中,我从AWSDK收到异常消息: Internalconfig.java-找不到awssdk_config_override.json文件"

And during this call I'm getting the exception message from the AWSDK: Internalconfig.java - "awssdk_config_override.json file not found"

实际消息: 6656 [http-bio-8080-exec-8]调试com.amazonaws.internal.config.InternalConfig-找不到配置覆盖awssdk_config_override.json.

Actual message: 6656 [http-bio-8080-exec-8] DEBUG com.amazonaws.internal.config.InternalConfig -Configuration override awssdk_config_override.json not found.

完全困惑这里发生的事情.目前,我只能在一个项目上重现此内容,而从头开始创建新项目时则无法重现此内容.

Totally baffled what's going on here. I can currently only reproduce this on one project, but can't reproduce it when creating new projects from scratch.

知道这个json文件是做什么用的吗?还是为什么找不到它或感觉需要找到它?

Any idea what this json file is even used for? Or why it can't find it or feels the need to find it?

推荐答案

SDK捆绑了一个名为

The SDK comes bundled with a file called awssdk_config_default.json with various bits of trivia about how to find and authenticate to the different AWS services. When loading up, it also looks for a file on the classpath called "awssdk_config_override.json" that you can optionally provide to override these settings - for example if you want to use a different authentication protocol than what the SDK chooses by default.

完全不需要此文件,并且几乎所有SDK用户都对默认配置感到非常满意.如果找不到所需的文件,SDK会在DEBUG级别记录一条消息,以帮助调试发生的问题.可以安全地忽略此消息(以及SDK记录在DEBUG级别的所有其他消息),除非您试图弄清为什么某事不起作用.

This file is not at all required, and almost all users of the SDK will be perfectly happy with the default configuration. The SDK logs a message at the DEBUG level if it can't find the file to help debug what's going wrong if you're expecting it to pick up an override config file but it's not for some reason. This message (and all of the other messages the SDK logs at the DEBUG level) are safe to ignore unless you're trying to figure out why something isn't working.

我绝对建议在部署到生产环境之前关闭DEBUG级别的日志记录-DEBUG日志可能会变得很冗长.

I would definitely recommend turning off DEBUG level logging before deploying to production - the DEBUG logs can get quite verbose.

这篇关于找不到awssdk_config_override.json文件-异常AWSSDK的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆