Unable to get URL for Apache HTTP commons client error for a weblogic application. This shows under backends - WebService at UnknownProtocol_//UnknownHost_UnknownPort.

Document ID : KB000006791
Last Modified Date : 29/03/2018
Show Technical Document Details
Issue:

Looking in the Introscope Workstation, Under backends node>  it is showing WebService at UnknownProtocol_//UnknownHost_UnknownPort for a weblogic application monitored by APM agent .

The following error message appears:

[IntroscopeAgent.Apache HTTP Commons Client Data Resolver] getURI : Unable to get URL for Apache Http commons client -<client URL: http :<ip address>/...>

Environment:
APM 10.3 and later have fixed this issue. So, it is only in APM 10.2 and earlier.

 
Cause:

The culprit is Apache 3.x HTTP client library, There is a bug in Apache 3.x http client. HTTP client tracer is relying on custom URI object returned by an Apache 3.x HTTP client , for URL data.

The Apache documentation claims that URI object returned will be escaped to comply with RFC standard. But below exception shows that  the Apache custom URI object does not follow the RFC standard.

Note: This issue will not be seen with Apache 4.x http Client because 4.x versions are directly providing “Java.net.URI” object instead of custom URI object.

Resolution:

To solve this issue

1. Either stay on Apache 3.x and upgrade the APM agent to 10.3 or higher.
Note: APM EMs also will need  to be at 10.3 or higher .
           This is because the upgraded APM agent should  communicate with same or higher version of EM .

OR

2. Stay on APM 10.2 and  upgrade Apache to 4.x