From: SourceForge.net <no...@so...> - 2012-11-26 14:07:17
|
Bugs item #3557283, was opened at 2012-08-14 01:03 Message generated for change (Settings changed) made by blaschke-oss You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=712784&aid=3557283&group_id=128809 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: Java Client (JSR48) Group: None >Status: Pending Resolution: Fixed Priority: 5 Private: No Submitted By: chen wang (wchencdl) Assigned to: Dave Blaschke (blaschke-oss) Summary: Print full response when get EOF from CIMOM Initial Comment: Currently, we always get such logs during communication with CIMOM. It's hard to prove what's wrong with CIMOM and this error message becomes confused. If JCC dumps the full response of CIMOM when it get the EOF error, it will be specific and provides the evidence of CIMOM side issue. 2012/08/11 10:19:15.165 WARNING CIM2002W Connection failed with URL https://10.10.18.26:9510/cimom. Reason: Unexpected EOF. ::class.method=unknown ::thread=LEDService-thread-1 ::loggername=org.sblim.cimclient 2012/08/11 10:19:15.551 WARNING CIM2002W Connection failed with URL https://10.10.18.26:9510/cimom. Reason: Unexpected EOF. ::class.method=unknown ::thread=LEDService-thread-1 ::loggername=org.sblim.cimclient ---------------------------------------------------------------------- Comment By: Dave Blaschke (blaschke-oss) Date: 2012-11-26 06:07 Message: The community review has completed and we received no substantial criticism. Therefore the patch has been approved and merged into the "HEAD" branch. The next release will pick it up. ---------------------------------------------------------------------- Comment By: Dave Blaschke (blaschke-oss) Date: 2012-11-05 14:59 Message: Patch sent for community review. During a 2 week period any exploiter may comment on the patch, request changes or turn it down completely (with good reason). For the time being the patch is part of the "Experimental" branch in CVS. ---------------------------------------------------------------------- Comment By: Dave Blaschke (blaschke-oss) Date: 2012-11-05 12:30 Message: After further discussions, #3 below will not be implemented, it was for debugging purposes only ---------------------------------------------------------------------- Comment By: Dave Blaschke (blaschke-oss) Date: 2012-11-05 07:00 Message: The second proposed patch was tested and works as expected. There will be three changes in the final patch: 1) The warning in HttpMethod.java will be changed from "Unexpected EOF trying to read line from input stream" to "Unexpected EOF trying to read line from input stream - CIMOM closed its end of socket, check its connection settings" because the only way for this to occur is when the client attempts to read a line from the HTTP header and gets -1 2) The "Http connection failed after _____ milliseconds" warning in HttpClient.java will be enhanced to include the time that passed since the previous use of the connection ("Http connection failed after _____ milliseconds, _____ milliseconds after previous use of connection") 3) The "HTTP 200 received after _____ milliseconds" warning in HttpClient.java will be issued after a user-configurable number of seconds instead of the hard-coded 10 seconds 4) The "Socket status: _____" warning in HttpClient.java will be removed since Socket.isXxx methods only return client's view of socket, not server's ---------------------------------------------------------------------- Comment By: Dave Blaschke (blaschke-oss) Date: 2012-10-22 08:26 Message: This patch will display something along the lines of the following: 2012.10.22 10:12:56 >10< org.sblim.cimclient.internal.http.HttpClient.getResponseCode(HttpClient.java:768) WARNING: CIM2002W Connection failed with URL http://sjccabt.austin.ibm.com:5988/cimom. Reason: Unexpected EOF. 2012.10.22 10:12:56 >10< org.sblim.cimclient.internal.http.HttpClient.getResponseCode(HttpClient.java:770) WARNING: Http connection failed after 579 milliseconds ---> java.io.IOException: Unexpected EOF at org.sblim.cimclient.internal.http.HttpClient.getResponseCode(HttpClient.java:698) at org.sblim.cimclient.internal.http.HttpUrlConnection.getResponseCode(HttpUrlConnection.java:230) at org.sblim.cimclient.internal.wbem.WBEMClientCIMXML.transmitRequest(WBEMClientCIMXML.java:1741) at org.sblim.cimclient.internal.wbem.WBEMClientCIMXML.getClass(WBEMClientCIMXML.java:1175) at org.sblim.cimclient.samples.Jsr48OperationSample.getClass(Jsr48OperationSample.java:309) at org.sblim.cimclient.samples.Jsr48OperationSample.main(Jsr48OperationSample.java:350) 2012.10.22 10:12:56 >10< org.sblim.cimclient.internal.http.HttpClient.getResponseCode(HttpClient.java:773) WARNING: Socket status: bound=true, closed=false, connected=true, inputshutdown=false, outputshutdown=false ---------------------------------------------------------------------- Comment By: Dave Blaschke (blaschke-oss) Date: 2012-10-22 04:27 Message: This bug has now been open for over two months, any decision on whether a patch is needed here or not? ---------------------------------------------------------------------- Comment By: Dave Blaschke (blaschke-oss) Date: 2012-10-09 06:55 Message: The second proposed patch logs critical trace messages at Level.WARNING, logs method that generates "Unexpected EOF" exception, logs duration of CIM2002W call, and logs any HTTP 200 response with duration > 10sec ---------------------------------------------------------------------- Comment By: Dave Blaschke (blaschke-oss) Date: 2012-10-09 05:35 Message: Sample exception from Director log: ./error-log-0.html:2012/09/14 16:10:58.667 WARNING CIM2002W Connection failed with URL https://[fd8c:215d:178e:c0de:5ef3:fcff:fe25:e0fd]:5989/cimom. Reason: Unexpected EOF. ::class.method=unknown ::thread=ExtendedDiscoveryThread-5 ::loggername=org.sblim.cimclient ---------------------------------------------------------------------- Comment By: Dave Blaschke (blaschke-oss) Date: 2012-08-19 09:15 Message: The problem is that the unexpected EOF exception you are seeing is being generated in HttpClient.getResponseCode() BEFORE any CIM-XML is read/parsed, so a full response is not available. There are already trace statements in HttpClient.getResponseCode() to follow the progress through the method: 1) FINER, "Attempting http request" - beginning request attempt 2) FINER, "HTTP Operation" - HttpClientMethod created 3) FINER, "HTTP Headers" - request headers written to socket 4) FINER, "HTTP Response" - response received 5) FINER, "KeepAlive" - output streams assigned I have attached a patch that will dump more information that may prove useful in figuring out what is going on. ---------------------------------------------------------------------- Comment By: chen wang (wchencdl) Date: 2012-08-14 19:25 Message: I will dump the stack and update here. ---------------------------------------------------------------------- Comment By: Dave Blaschke (blaschke-oss) Date: 2012-08-14 18:54 Message: Is there a stack trace logged for the exception? It would be very helpful to see which routine is generating the EOF exception. If not, please see if you can add the following four lines into HttpClient.getResponseCode() in the "catch (IOException e)" block immediately after the " logger.trace(Level.FINER, "Http connection failed", e);" line: StringWriter sw = new StringWriter(); PrintWriter pw = new PrintWriter(sw); e.printStackTrace(pw); logger.trace(Level.FINEST, sw.toString()); ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=712784&aid=3557283&group_id=128809 |