Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

发送短信模块报错 BASE64Encoder 错误 #394

Open
techzhai opened this issue Jul 14, 2021 · 3 comments
Open

发送短信模块报错 BASE64Encoder 错误 #394

techzhai opened this issue Jul 14, 2021 · 3 comments

Comments

@techzhai
Copy link

techzhai commented Jul 14, 2021

1. 环境
docker 环境 jdk11版本

<dependency>
            <groupId>com.aliyun</groupId>
            <artifactId>dysmsapi20170525</artifactId>
            <version>2.0.4</version>
</dependency>

2. 报错栈信息
Caused by: java.lang.NoClassDefFoundError: sun/misc/BASE64Encoder
at com.aliyun.openapiutil.Client.getRPCSignature(Client.java:374)
at com.aliyun.teaopenapi.Client.doRPCRequest(Client.java:154)
at com.aliyun.dysmsapi20170525.Client.sendSmsWithOptions(Client.java:238)
at com.aliyun.dysmsapi20170525.Client.sendSms(Client.java:243)

  1. 具体报错位置
    com.aliyun.openapiutil.Client类使用了jdk11里已经被废弃的 BASE64Encoder类,导致出现运行时报错

希望能早点修复,谢谢

@fengzehao
Copy link

同样的问题,我只能先降级了

@yndu13
Copy link
Collaborator

yndu13 commented Sep 28, 2021

@fengzehao
Copy link

fengzehao commented Oct 8, 2021

已修改, diff: aliyun/darabonba-openapi-util@865c888#diff-db8cdb300359b1afbb412addce71639d6ebdd0855b0bace8c3d08f586c2d0288 请将 SDK 升级到最新版试试

https://github.com/aliyun/alibabacloud-java-sdk/blob/master/dysmsapi-20170525/pom.xml
中该库的依赖没有更新,所以还是不行,请协助更新此库pom文件

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants