对象存储服务 OBS-其他高频问题汇总(Java SDK):升级SDK后okhttp报错问题

时间:2024-11-06 21:55:01

升级SDK后okhttp报错问题

1
2
3
4
5
6
Exception in thread "main" java.lang.NoSuchMethodError: 'okhttp3.RequestBody okhttp3.RequestBody.create(java.lang.String, okhttp3.MediaType)'
	at com.obs.services.internal.RestConnectionService.createRequestBuilder(RestConnectionService.java:157)
	at com.obs.services.internal.RestConnectionService.setupConnection(RestConnectionService.java:148)
	at com.obs.services.internal.RestConnectionService.setupConnection(RestConnectionService.java:124)
	at com.obs.services.internal.RestStorageService.performRequest(RestStorageService.java:395)
	at com.obs.services.internal.RestStorageService.performRequest(RestStorageService.java:388)
support.huaweicloud.com/sdk-java-devg-obs/obs_21_0302.html