[ 
https://issues.apache.org/jira/browse/ABDERA-284?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13157129#comment-13157129
 ] 

Andreas Veithen commented on ABDERA-284:
----------------------------------------

It's actually the other way round: 
StAXUtils#getXMLInputFactory(StAXParserConfiguration) exists in Axiom 1.2.10 
(and is used intentionally in Abdera because the default parser configuration 
is not suitable for Abdera), but not in 1.2.5. You need to use a recent Axiom 
version with recent Abdera versions.

For WebSphere 7 the problem is different: an Axiom version is included in the 
WebSphere runtime (for the JAX-WS support which is based on Axis2) and these 
classes are visible to applications. In case of conflict, you therefore need to 
change the class loader policy of the application to parent last. Probably 
WebSphere 8 contains a newer version of Axiom or the Axiom classes are no 
longer visible to applications, so that the problem doesn't occur with that 
version.
                
> Deprecated Axiom interface is used in FOMParser; Axiom version conflict: in 
> compile-time 1.2.5 is used; in runtime (with dependencies through maven) 
> 1.2.10;
> ------------------------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: ABDERA-284
>                 URL: https://issues.apache.org/jira/browse/ABDERA-284
>             Project: Abdera
>          Issue Type: Bug
>    Affects Versions: 1.1, 1.1.1, 1.1.2
>         Environment: tomcat6
> java1.6.0_22
>            Reporter: Ilya A. Pimenov
>            Priority: Critical
>         Attachments: ABDERA-284-fix.diff
>
>
> In FOMParser.java in getXMLInputFactory() method 
> StAXUtils.getXMLInputFactory(StAXParserConfiguration) is used from Axiom-Api, 
> which is there no more in axiom 1.2.10 (that is used as a dependency in root 
> pom.xml).
> Also about Axiom dependency:
> In file -
> trunk\dependencies\ deps.properties 
> you can find dependency to axiom-1.2.5
> axiom.api.jar=axiom-api-1.2.5.jar
> axiom.impl.jar=axiom-impl-1.2.5.jar
> While in pom.xml Axiom-1.2.10 is used (and their interfaces are a bit 
> different)
>       <dependency>
>         <groupId>org.apache.ws.commons.axiom</groupId>
>         <artifactId>axiom-api</artifactId>
>         <version>1.2.10</version>  
>       </dependency>
>       <dependency>
>         <groupId>org.apache.ws.commons.axiom</groupId>
>         <artifactId>axiom-impl</artifactId>
>         <version>1.2.10</version>  
>       <exclusions>
>         <exclusion>
>           <groupId>javax.mail</groupId>
>           <artifactId>mail</artifactId>
>         </exclusion>
>         <exclusion>
>           <groupId>stax</groupId>
>           <artifactId>stax-api</artifactId>
>         </exclusion>
>       </exclusions>
>       </dependency>
> ----
> For this reason, if you will follow directly this instructions -
> https://cwiki.apache.org/confluence/display/ABDERA/Your+first+AtomPub+Server
> with Abdera v >1.0 you will get 
> Exception in thread "main" java.lang.NoSuchMethodError: 
> org.apache.axiom.om.util.StAXUtils.getXMLInputFactory(Lorg/apache/axiom/om/util/StAXParserConfiguration;)Ljavax/xml/stream/XMLInputFactory;
>  at 
> org.apache.abdera.parser.stax.FOMParser.getXMLInputFactory(FOMParser.java:152)
>  at 
> org.apache.abdera.parser.stax.FOMParser.createXMLStreamReader(FOMParser.java:178)
>  at org.apache.abdera.parser.stax.FOMParser.parse(FOMParser.java:143) at 
> org.apache.abdera.protocol.client.AbstractClientResponse.getDocument(AbstractClientResponse.java:111)
>  at 
> org.apache.abdera.protocol.client.AbstractClientResponse.getDocument(AbstractClientResponse.java:89)
>  at 
> org.apache.abdera.protocol.client.AbstractClientResponse.getDocument(AbstractClientResponse.java:71)
> The same problem is reported here - 
> http://stackoverflow.com/questions/5337162/apache-abdera-client-response-getdocument-method

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to