在 weblogic 上部署了一个应用程序,该应用程序使用 s3 协议定期将文件上传到云端。使用 AWS SDK for Java 1.x。部分代码
public AmazonS3 connect() {
AWSCredentials cr = new BasicAWSCredentials(k, s);
AmazonS3ClientBuilder standard = AmazonS3ClientBuilder.standard();
standard.withCredentials(new AWSStaticCredentialsProvider(cr));
standard.withEndpointConfiguration(new AwsClientBuilder.EndpointConfiguration(s, r));
AmazonS3 s3client = standard.build();
return s3client;
}
但是当我在 WebLogic 12c 上部署和启动应用程序(作为 war 包)时,它会在第 6 行的build()中冻结(我通过在每一行的日志中留下一个条目来确定它)。没有例外,没有错误的日志消息。在 IntellijIdea 本地构建和运行此代码,无需在 WebLogic 12c 上部署,运行良好!我是为服务器开发应用程序的新手,我看不到日志。
可能是什么问题呢?