DDMSence 2.0.0 hangs when used with WebLogic Server 10.3.5.

Description

(Imported from Google Code)
Submitted by Charlie Anamateros:

We are using DDMSence 2.0 on a project to assist with the creation of DDMS 4.0 records. We encountered an issue when executing under Oracle WebLogic Server 10.3.5 – I am not sure if anyone has reported this issue already and wanted to bring it to your attention. I was able to bypass the problem however it looks like it bypasses validation – I don't believe it is a huge concern for us since all other elements call the commit() method to validate.

DDMSence causes an error when creating DDMS records under Oracle WebLogic Server 10.3.5 (WLS). Works fine when using the provided samples or from a Java application (using the same Java version 1.6.0_34).

There were no error messages or logs written, the DDMSense libraries just failed to create the record. The debugger seemed to hang in the Resource.java class. Debugging indicated that the cause may be due to line 582 of the Resource constructor in the call to validateWithSchema(toXML).

---------------
populatedOrderedList();
for (IDDMSComponent component : getTopLevelComponents()) {
element.appendChild(component.getXOMElementCopy());
}
setXOMElement(element, true);
// Bypass validation - workaround for error
// DDMSReader.validateWithSchema(toXML());
}
catch (InvalidDDMSException e) {
e.setLocator(getQualifiedName());
throw (e);
}

--------------------

The Resource constructor is called when creating the DDMS records as follows:

Resource resource = new Resource(components,true, getCurrentDate(),
null, argIsmDESVersion, argNTKDESVersion, secAttr.commit(), null, null);

Environment

None

Activity

Show:

Brian Uri March 25, 2013 at 5:18 PM

Attempt to reproduce, which worked okay:

  • Had a simple JSP that loaded a DDMS resource in an XML file in a Scriptlet.

  • Added the base DDMSence JARs to WEB-INF/lib: xml-apis, xerces, xom, saxon. Deployed the WAR file on Weblogic 10.3.4.

  • Visited the JSP.

  • The XML file was displayed without any issues.

Brian Uri March 21, 2013 at 4:08 PM

Had no luck reproducing this with Weblogic Server 10.3.4 and JDK 1.7.0_11.

Brian Uri November 30, 2012 at 5:23 PM

Thank you for letting me know about this bug. I have opened a defect ticket to track it:
http://code.google.com/p/ddmsence/issues/detail?id=189

Unfortunately, I do not have an instance of WLS that i can try to reproduce this on. However, based on past experience with Weblogic, I would imagine that WLS has its own custom XML library JARs that are forcing themselves to be higher priority than the XML libraries bundled with Java or DDMSence. On a previous project, we encountered bugs where the Weblogic XML SAX libraries failed to parse XML documents in the same manner as a standalone Xerces JAR might.

The options I see:
1) If you are comfortable building DDMSence from the source, the commenting you have done in your email should suffice. The drawbacks: a) Some XML correctness errors may not get caught (e.g. two gml Position elements with the same gml:id value) and b) Using DDMSence to load existing DDMS resources from XML files may still hang with the same problem.

2) If you can raise the priority of the xml-apis JAR and the xercesImpl JAR in the server classpath, you may be able to suppress the misbehaving Weblogic libraries. Alternately, if you can identify which of Weblogic's many JARs is the culprit, Weblogic documentation might offer configuration instructions for overriding them.

Please let me know how it goes – I'll be glad to help where possible.

Cannot Reproduce

Assignee

Reporter

Priority

Created November 30, 2012 at 5:15 PM
Updated April 6, 2015 at 2:28 PM
Resolved April 6, 2015 at 2:28 PM