It looks like this change has broken XSLT transformations. The Xalan library we ship with Synapse fails when the xml-apis library is not present. If we also remove the Xalan library from Synapse, things work fine. But I noticed some security failures in that case. Any idea what is the best way to fix this?
Thanks, Hiranya On Thu, Dec 22, 2011 at 4:02 PM, Kasun Indrasiri <[email protected]> wrote: > Removed xml-apis. > > > On Wed, Dec 21, 2011 at 11:38 PM, Andreas Veithen < > [email protected]> wrote: > >> On Wed, Dec 21, 2011 at 16:53, Hiranya Jayathilaka <[email protected]> >> wrote: >> > Hi Folks, >> > >> > This is with regard to >> https://issues.apache.org/jira/browse/SYNAPSE-410. I >> > have upgraded the XML APIs library version to 2.0.2. Andreas pointed out >> > that we don't really have to ship this library at all since we are on >> JDK 5. >> > It seems having this library around can actually break stuff. I got the >> > following exception from neethi while trying some throttling stuff: >> > >> > 2011-12-21 21:08:58,636 [-] [HttpServerWorker-1] ERROR NativeWorkerPool >> > Uncaught exception >> > java.lang.NoSuchMethodError: >> > org.w3c.dom.Element.getTextContent()Ljava/lang/String; >> > at >> > >> org.apache.neethi.builders.xml.XMLPrimitiveAssertionBuilder.newPrimitiveAssertion(XMLPrimitiveAssertionBuilder.java:85) >> > at >> > >> org.apache.neethi.builders.xml.XMLPrimitiveAssertionBuilder.build(XMLPrimitiveAssertionBuilder.java:70) >> > at >> > >> org.apache.neethi.builders.xml.XMLPrimitiveAssertionBuilder.build(XMLPrimitiveAssertionBuilder.java:40) >> > at >> > >> org.apache.neethi.AssertionBuilderFactoryImpl.invokeBuilder(AssertionBuilderFactoryImpl.java:129) >> > at >> > >> org.apache.neethi.AssertionBuilderFactoryImpl.build(AssertionBuilderFactoryImpl.java:110) >> > at >> > >> org.apache.neethi.PolicyBuilder.processOperationElement(PolicyBuilder.java:220) >> > at >> org.apache.neethi.PolicyBuilder.getPolicyOperator(PolicyBuilder.java:172) >> > at org.apache.neethi.PolicyBuilder.getPolicy(PolicyBuilder.java:125) >> > at org.apache.neethi.PolicyEngine.getPolicy(PolicyEngine.java:113) >> > at >> > >> org.wso2.throttle.ThrottleFactory.createThrottle(ThrottleFactory.java:134) >> > at >> > >> org.wso2.throttle.ThrottleFactory.createMediatorThrottle(ThrottleFactory.java:88) >> > at >> > >> org.apache.synapse.mediators.throttle.ThrottleMediator.mediate(ThrottleMediator.java:152) >> > at >> > >> org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:60) >> > at >> > >> org.apache.synapse.mediators.filters.InMediator.mediate(InMediator.java:55) >> > at >> > >> org.apache.synapse.mediators.AbstractListMediator.mediate(AbstractListMediator.java:60) >> > at >> > >> org.apache.synapse.mediators.base.SequenceMediator.mediate(SequenceMediator.java:114) >> > at >> > >> org.apache.synapse.core.axis2.Axis2SynapseEnvironment.injectMessage(Axis2SynapseEnvironment.java:188) >> > at >> > >> org.apache.synapse.core.axis2.SynapseMessageReceiver.receive(SynapseMessageReceiver.java:83) >> > at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:181) >> > at >> > >> org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:176) >> > at >> > >> org.apache.synapse.transport.nhttp.ServerWorker.processEntityEnclosingMethod(ServerWorker.java:454) >> > at >> > >> org.apache.synapse.transport.nhttp.ServerWorker.run(ServerWorker.java:280) >> > at >> > >> org.apache.axis2.transport.base.threads.NativeWorkerPool$1.run(NativeWorkerPool.java:173) >> > >> > The getTextContent method was not available in the old DOM API. When I >> > removed the xml-apis library from Synapse, it started to use the one >> > provided by JDK and things worked as expected. So looks like we have to >> get >> > rid of this. Does anybody see any issues with removing this? >> > >> > Andreas, is it really safe to remove this? >> >> Yes >> >> > Will there be issues on other >> > JDKs (eg: IBM JDK)? >> >> No >> >> > Thanks >> > -- >> > Hiranya Jayathilaka >> > Associate Technical Lead; >> > WSO2 Inc.; http://wso2.org >> > E-mail: [email protected]; Mobile: +94 77 633 3491 >> > Blog: http://techfeast-hiranya.blogspot.com >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [email protected] >> For additional commands, e-mail: [email protected] >> >> > > > -- > Kasun Indrasiri > Associate Technical Lead, > WSO2 Inc. - "Lean . Enterprise . Middleware" - http://www.wso2.com/ > Blog : http://kasunpanorama.blogspot.com/ > > -- Hiranya Jayathilaka Associate Technical Lead; WSO2 Inc.; http://wso2.org E-mail: [email protected]; Mobile: +94 77 633 3491 Blog: http://techfeast-hiranya.blogspot.com
