修改华为云obs引入版本
微信jsapi支付修改使用openID
This commit is contained in:
parent
72471168d7
commit
d48e5a05a6
@ -440,7 +440,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.huaweicloud</groupId>
|
<groupId>com.huaweicloud</groupId>
|
||||||
<artifactId>esdk-obs-java</artifactId>
|
<artifactId>esdk-obs-java</artifactId>
|
||||||
<version>${huaweicloud.version}</version>
|
<version>${huaweicloud-obs.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.qcloud</groupId>
|
<groupId>com.qcloud</groupId>
|
||||||
|
@ -44,7 +44,7 @@ public class HuaweiFilePlugin implements FilePlugin {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
private ObsClient getObsClient() {
|
private ObsClient getObsClient() {
|
||||||
return new ObsClient(ossSetting.getHuaweicloudOBSAccessKey(), ossSetting.getHuaweicloudOBSSecretKey(), ossSetting.getAliyunOSSEndPoint());
|
return new ObsClient(ossSetting.getHuaweicloudOBSAccessKey(), ossSetting.getHuaweicloudOBSSecretKey(), ossSetting.getHuaweicloudOBSEndPoint());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -72,14 +72,17 @@ public class HuaweiFilePlugin implements FilePlugin {
|
|||||||
public String inputStreamUpload(InputStream inputStream, String key) {
|
public String inputStreamUpload(InputStream inputStream, String key) {
|
||||||
ObsClient obsClient = getObsClient();
|
ObsClient obsClient = getObsClient();
|
||||||
try {
|
try {
|
||||||
obsClient.putObject(new PutObjectRequest(ossSetting.getHuaweicloudOBSBucketName(), key, inputStream));
|
PutObjectRequest putObjectRequest=new PutObjectRequest(ossSetting.getHuaweicloudOBSBucketName(), key, inputStream);
|
||||||
|
obsClient.putObject(putObjectRequest);
|
||||||
} catch (ObsException obsException) {
|
} catch (ObsException obsException) {
|
||||||
|
obsException.printStackTrace();
|
||||||
throw new ServiceException(ResultCode.OSS_EXCEPTION_ERROR);
|
throw new ServiceException(ResultCode.OSS_EXCEPTION_ERROR);
|
||||||
} finally {
|
} finally {
|
||||||
try {
|
try {
|
||||||
// 关闭OBS连接
|
// 关闭OBS连接
|
||||||
obsClient.close();
|
obsClient.close();
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
|
e.printStackTrace();
|
||||||
log.error("OBS关闭连接报错!" + e.getMessage());
|
log.error("OBS关闭连接报错!" + e.getMessage());
|
||||||
throw new ServiceException(ResultCode.OSS_EXCEPTION_ERROR);
|
throw new ServiceException(ResultCode.OSS_EXCEPTION_ERROR);
|
||||||
}
|
}
|
||||||
|
@ -179,7 +179,7 @@ public class WechatPlugin implements Payment {
|
|||||||
|
|
||||||
try {
|
try {
|
||||||
Connect connect = connectService.queryConnect(
|
Connect connect = connectService.queryConnect(
|
||||||
ConnectQueryDTO.builder().userId(UserContext.getCurrentUser().getId()).unionType(ConnectEnum.WECHAT.name()).build()
|
ConnectQueryDTO.builder().userId(UserContext.getCurrentUser().getId()).unionType(SourceEnum.WECHAT_OFFIACCOUNT_OPEN_ID.name()).build()
|
||||||
);
|
);
|
||||||
if (connect == null) {
|
if (connect == null) {
|
||||||
return null;
|
return null;
|
||||||
|
2
pom.xml
2
pom.xml
@ -61,7 +61,7 @@
|
|||||||
<spring-boot-admin>2.3.1</spring-boot-admin>
|
<spring-boot-admin>2.3.1</spring-boot-admin>
|
||||||
<owasp-java-html-sanitizer>20211018.2</owasp-java-html-sanitizer>
|
<owasp-java-html-sanitizer>20211018.2</owasp-java-html-sanitizer>
|
||||||
<minio.version>8.0.3</minio.version>
|
<minio.version>8.0.3</minio.version>
|
||||||
<huaweicloud.version>3.21.8</huaweicloud.version>
|
<huaweicloud-obs.version>3.20.6.2</huaweicloud-obs.version>
|
||||||
<cos.version>5.6.97</cos.version>
|
<cos.version>5.6.97</cos.version>
|
||||||
<tencentcloud.version>3.1.693</tencentcloud.version>
|
<tencentcloud.version>3.1.693</tencentcloud.version>
|
||||||
<kuaidi100-api.version>1.0.11</kuaidi100-api.version>
|
<kuaidi100-api.version>1.0.11</kuaidi100-api.version>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user