phax / peppol-commons

Java library with shared Peppol components - identifier handling, codelists, SBDH handler, SMP Client, SML Client
Apache License 2.0
29 stars 8 forks source link

sml client libraries in wildfly-10: jaxb error (with apache cxf) #7

Closed fiorenzino closed 7 years ago

fiorenzino commented 8 years ago

H Philip,

in wildfly-10 using your sml client libraries, we have this error:

The element name {http://busdox.org/transport/identifiers/1.0/}ParticipantIdentifier has more than one mapping. this problem is related to the following location: at public javax.xml.bind.JAXBElement com.helger.peppol.identifier.ObjectFactory.createParticipantIdentifier(com.helger.peppol.identifier.ParticipantIdentifierType) at com.helger.peppol.identifier.ObjectFactory this problem is related to the following location: at public javax.xml.bind.JAXBElement com.helger.peppol.smlclient.participant.ObjectFactory.createParticipantIdentifier(com.helger.peppol.identifier.ParticipantIdentifierType) at com.helger.peppol.smlclient.participant.ObjectFactory

In your code you have the same namespace for ParticipantIdentifier in two module:

I'm creating a branch, to remove the duplicated namespace (using a static modules - named peppol-jaxb), because i don't know how do it, in the xjc generated code from maven.

Best Regards

Fiorenzo

phax commented 8 years ago

What version are you using? 4.3.5? You need it for the SMP right? What SMP version are you using? This seems to be the same as https://github.com/phax/peppol-smp-server/issues/18

phax commented 8 years ago

Do you need any more input or are you fine?

fiorenzino commented 8 years ago

Hi Philip,

sorry for the delay in the response. At end, following your code, we decided to rewrite your library to be compliant with wildfly.

phax commented 8 years ago

Okay, thanks for the Info. So the proposed fix from SMP Server project did not help you? What did you change, so that I can evaluate whether I should integrate it into the HEAD revision?

phax commented 8 years ago

Do you have any news for me??? If not please close the issue.

fiorenzino commented 8 years ago

I think, you should remove the duplicated classes from peppol-commons and peppol-sml. We solved the problem in our project by creating a library with only the jaxb artifacts needed to answer incoming smp requests.

phax commented 8 years ago

Hi Fiorenzo! I just checked with peppol-commons 5.0.0: the class ParticipantIdentifier is contained exactly once for namespace http://busdox.org/transport/identifiers/1.0/. The project peppol-sml-client (I think this is what you are referring to) does no longer create this file and so version 5.0.0 should do the trick. I previously had troubles with the episode handling in the jaxws-maven plugin, but I now found a way to handle the issues and it should be fine. Please cross check if that works for you. Thanks for your effort!

phax commented 7 years ago

Can you please check if it works with the latest peppol-commons. I got the information that the SMP server 5 works with Wildfly with a minor modification.

phax commented 7 years ago

Closed because of inactivity