java - EWSHttpException: Connection not established -
i'm using ews java api connect exchange server , retrieve info mail, calendar appointment , task.
it's working lot of user, except 1 account. got next error :
microsoft.exchange.webservices.data.ewshttpexception: connection not established @ microsoft.exchange.webservices.data.httpclientwebrequest.throwifconnisnull(httpclientwebrequest.java:394) @ microsoft.exchange.webservices.data.httpclientwebrequest.getresponseheaders(httpclientwebrequest.java:280) @ microsoft.exchange.webservices.data.exchangeservicebase.processhttpresponseheaders(exchangeservicebase.java:1045) @ microsoft.exchange.webservices.data.simpleservicerequestbase.internalexecute(simpleservicerequestbase.java:58) @ microsoft.exchange.webservices.data.multiresponseservicerequest.execute(multiresponseservicerequest.java:144) @ microsoft.exchange.webservices.data.exchangeservice.bindtofolder(exchangeservice.java:350) @ microsoft.exchange.webservices.data.exchangeservice.bindtofolder(exchangeservice.java:374) here code found connection :
exchangeservice service = new exchangeservice(); exchangecredentials credentials = new webcredentials(<user>, <password>); service.setcredentials(credentials); service.seturl(new uri(url)); i suspect specific business relationship configuration explaining error i'm unable determine parameter.
that exception due bug. i've seen many, many times. problem lies in simpleservicerequest class. if there's error when reading response, close response in block in readresponse(). go internalexecute(), grab block seek process headers...and tries read response has been closed. closing won't null out response, null out info in response, ews tries read display errors. exception because connection null due response beingness closed earlier.
the solution either prepare bug or enable tracing , @ response see kind of error you're dealing with. also, measure, create sure strings class reading in strings.properties file or it'll throw different exception when can't find error messages.
java exchangewebservices ewsjavaapi
No comments:
Post a Comment