[英]java.lang.NoClassDefFoundError: org/apache/http/nio/conn/NHttpClientConnectionManager
I currently have these jars: 我目前有这些罐子:
My java method where the error comes from is: 错误的来源是我的java方法:
private HttpResponse<JsonNode> jwtAuthPost(String assertion) throws UnirestException {
HttpResponse<JsonNode> jsonResponse = Unirest.post(AUTH_URL)
.header("accept", "application/json")
.field("grant_type", JWT_GRANT_TYPE)
.field("client_id", this.clientId)
.field("client_secret", this.clientSecret)
.field("assertion", assertion)
.asJson(); //error here
return jsonResponse;
}
I'm guessing there is a plugin somewhere that I'm missing for this, but I can't seem to find it anywhere. 我猜想这个地方我缺少一个插件,但是我似乎在任何地方都找不到它。
Rest of Error Log 其余错误日志
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/http/nio/conn/NHttpClientConnectionManager
at com.mashape.unirest.http.HttpClientHelper.prepareRequest(HttpClientHelper.java:154)
at com.mashape.unirest.http.HttpClientHelper.request(HttpClientHelper.java:134)
at com.mashape.unirest.request.BaseRequest.asJson(BaseRequest.java:68)
Include 包括
httpasyncclient-4.0-beta 4 .jar httpasyncclient-4.0-beta 4 .jar
instead of 代替
httpasyncclient-4.0-beta 3 .jar httpasyncclient-4.0-beta 3 .jar
See: http://www.java2s.com/Code/Jar/h/Downloadhttpasyncclient40beta4jar.htm 请参阅: http : //www.java2s.com/Code/Jar/h/Downloadhttpasyncclient40beta4jar.htm
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.