IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Maven Java Discussion :

[MAVEN]Web services et plugin "axistools-maven-plugin"


Sujet :

Maven Java

  1. #1
    Membre habitué Avatar de DanielW33
    Profil pro
    Inscrit en
    Mai 2006
    Messages
    327
    Détails du profil
    Informations personnelles :
    Localisation : France, Gironde (Aquitaine)

    Informations forums :
    Inscription : Mai 2006
    Messages : 327
    Points : 164
    Points
    164
    Par défaut [MAVEN]Web services et plugin "axistools-maven-plugin"
    Je souhaite utiliser ce plugin pour generer mon code WebService de plusieur wsdl present dans mon repertoire src/main/wsdl et j'ai cette erreur lorsque je lance mvn compile

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
     
    [DEBUG] -- end configuration --
    [INFO] [axistools:wsdl2java {execution: default}]
    [INFO] about to add compile source root
    [INFO] processing wsdl: C:\WorkspacePROJET\PROJETWs_AXIS\src\main\wsdl\toto_PROJET.wsdl
    26 sept. 2007 10:04:51 org.apache.axis.utils.JavaUtils isAttachmentSupported
    ATTENTION: Unable to find required classes (javax.activation.DataHandler and javax.mail.internet.MimeMultipart). Attachment support is disabled.
    [DEBUG] argslist: [-o, C:\WorkspacePROJET\PROJETWs_AXIS\src\main\generated, -w, C:\WorkspacePROJET\PROJETWs_AXIS\src\main\wsdl\toto_PROJET.wsdl]
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] error executing plugin
     
    Embedded error: WSDL2Java execution failed
    [INFO] ------------------------------------------------------------------------
    [DEBUG] Trace
    org.apache.maven.lifecycle.LifecycleExecutionException: error executing plugin
    	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:564)
    	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:480)
    	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:459)
    	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:311)
    	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:278)
    	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:143)
    	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:334)
    	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:125)
    	at org.apache.maven.cli.MavenCli.main(MavenCli.java:280)
    	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    	at java.lang.reflect.Method.invoke(Method.java:324)
    	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
    	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
    	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
    	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
    Caused by: org.apache.maven.plugin.MojoExecutionException: error executing plugin
    	at org.codehaus.mojo.axistools.WSDL2JavaMojo.execute(WSDL2JavaMojo.java:335)
    	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:443)
    	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:539)
    	... 16 more
    Caused by: org.codehaus.mojo.axistools.axis.AxisPluginException: WSDL2Java execution failed
    	at org.codehaus.mojo.axistools.wsdl2java.DefaultWSDL2JavaPlugin.execute(DefaultWSDL2JavaPlugin.java:316)
    	at org.codehaus.mojo.axistools.WSDL2JavaMojo.execute(WSDL2JavaMojo.java:331)
    	... 18 more
    Caused by: org.codehaus.mojo.axistools.axis.AxisPluginException: java.lang.NullPointerException
    	at org.codehaus.mojo.axistools.wsdl2java.WSDL2JavaWrapper.execute(WSDL2JavaWrapper.java:84)
    	at org.codehaus.mojo.axistools.wsdl2java.DefaultWSDL2JavaPlugin.execute(DefaultWSDL2JavaPlugin.java:305)
    	... 19 more
    Caused by: java.lang.NullPointerException
    	at org.apache.crimson.tree.ElementNode2.getAttributeNodeNS(ElementNode2.java:432)
    	at com.ibm.wsdl.util.xml.DOMUtils.getAttributeNS(Unknown Source)
    	at com.ibm.wsdl.util.xml.DOMUtils.getNamespaceURIFromPrefix(Unknown Source)
    	at com.ibm.wsdl.util.xml.DOMUtils.getQName(Unknown Source)
    	at com.ibm.wsdl.util.xml.DOMUtils.getQualifiedAttributeValue(Unknown Source)
    	at com.ibm.wsdl.xml.WSDLReaderImpl.getQualifiedAttributeValue(Unknown Source)
    	at com.ibm.wsdl.xml.WSDLReaderImpl.parsePort(Unknown Source)
    	at com.ibm.wsdl.xml.WSDLReaderImpl.parseService(Unknown Source)
    	at com.ibm.wsdl.xml.WSDLReaderImpl.parseDefinitions(Unknown Source)
    	at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)
    	at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)
    	at com.ibm.wsdl.xml.WSDLReaderImpl.readWSDL(Unknown Source)
    	at org.apache.axis.wsdl.symbolTable.SymbolTable.populate(SymbolTable.java:516)
    	at org.apache.axis.wsdl.symbolTable.SymbolTable.populate(SymbolTable.java:495)
    	at org.apache.axis.wsdl.gen.Parser$WSDLRunnable.run(Parser.java:361)
    	at java.lang.Thread.run(Thread.java:534)
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 2 seconds
    [INFO] Finished at: Wed Sep 26 10:04:51 CEST 2007
    [INFO] Final Memory: 5M/1016M
    [INFO] ------------------------------------------------------------------------

    mon pom :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
     
    <plugin>
    	<groupId>org.codehaus.mojo</groupId>
    	<artifactId>axistools-maven-plugin</artifactId>
    	<configuration>
    		<sourceDirectory>main/wsdl</sourceDirectory>
    		<outputDirectory>main/generated</outputDirectory>
    	</configuration>
    	<executions>
    		<execution>
    			<goals>
    				<goal>wsdl2java</goal>
    			</goals>
    		</execution>
    	</executions>
    </plugin>

  2. #2
    Membre confirmé

    Inscrit en
    Septembre 2006
    Messages
    466
    Détails du profil
    Informations forums :
    Inscription : Septembre 2006
    Messages : 466
    Points : 515
    Points
    515
    Par défaut
    Citation Envoyé par DanielW33 Voir le message
    Je souhaite utiliser ce plugin pour generer mon code WebService de plusieur wsdl present dans mon repertoire src/main/wsdl

    mon pom :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
     
    <plugin>
    	<groupId>org.codehaus.mojo</groupId>
    	<artifactId>axistools-maven-plugin</artifactId>
    	<configuration>
    		<sourceDirectory>main/wsdl</sourceDirectory>
    		<outputDirectory>main/generated</outputDirectory>
    	</configuration>
    	<executions>
    		<execution>
    			<goals>
    				<goal>wsdl2java</goal>
    			</goals>
    		</execution>
    	</executions>
    </plugin>
    Est-ce que tu as essayé avec
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
     
    <plugin>
    	<groupId>org.codehaus.mojo</groupId>
    	<artifactId>axistools-maven-plugin</artifactId>
    	<configuration>
    		<sourceDirectory>${basedir}/src/main/wsdl</sourceDirectory>
    		<outputDirectory>${basedir}/target/generated</outputDirectory>
    	</configuration>
    	<executions>
    		<execution>
    			<goals>
    				<goal>wsdl2java</goal>
    			</goals>
    		</execution>
    	</executions>
    </plugin>
    Je mettrai le code généré sous target plutôt que sous src.

    Rémy

  3. #3
    Membre habitué Avatar de DanielW33
    Profil pro
    Inscrit en
    Mai 2006
    Messages
    327
    Détails du profil
    Informations personnelles :
    Localisation : France, Gironde (Aquitaine)

    Informations forums :
    Inscription : Mai 2006
    Messages : 327
    Points : 164
    Points
    164
    Par défaut
    Meme en specifiant un path absolu la meme erreur est leve

  4. #4
    Expert éminent

    Avatar de denisC
    Profil pro
    Développeur Java
    Inscrit en
    Février 2005
    Messages
    4 050
    Détails du profil
    Informations personnelles :
    Âge : 44
    Localisation : Canada

    Informations professionnelles :
    Activité : Développeur Java
    Secteur : Service public

    Informations forums :
    Inscription : Février 2005
    Messages : 4 050
    Points : 7 641
    Points
    7 641
    Par défaut
    Citation Envoyé par DanielW33 Voir le message
    Meme en specifiant un path absolu la meme erreur est leve
    Question un peu bete : Mais ton WSDL, il est bien formé? IL semble se plaindre de la lecture de ton WSDL, non?

  5. #5
    Membre habitué Avatar de DanielW33
    Profil pro
    Inscrit en
    Mai 2006
    Messages
    327
    Détails du profil
    Informations personnelles :
    Localisation : France, Gironde (Aquitaine)

    Informations forums :
    Inscription : Mai 2006
    Messages : 327
    Points : 164
    Points
    164
    Par défaut
    les classes etaient generees precedement par une tahce ANT ce qui me fait dire que : oui il est bien formé

  6. #6
    Membre confirmé

    Inscrit en
    Septembre 2006
    Messages
    466
    Détails du profil
    Informations forums :
    Inscription : Septembre 2006
    Messages : 466
    Points : 515
    Points
    515
    Par défaut
    Citation Envoyé par DanielW33 Voir le message
    les classes etaient generees precedement par une tahce ANT ce qui me fait dire que : oui il est bien formé
    Mais ce n'est pas parce que le wsdl est bien formé qu'il est correcte.
    Est-ce que tu as essayé de passer les tests WS-I ?
    Il se peut que tu ais un problème de nommage de namespace ou encore que ta tache ant n'avait pas besoin d'un attribut optionel alors que le plugin maven oui.

    Néanmoins, le problème peut venir aussi d'ailleurs.

    Rémy

Discussions similaires

  1. Réponses: 2
    Dernier message: 20/11/2007, 16h00
  2. configuration des plugins Ant pour MAVEN 2
    Par DanielW33 dans le forum Maven
    Réponses: 2
    Dernier message: 31/07/2006, 16h05
  3. dev de plugin Ant pour Maven 2
    Par DanielW33 dans le forum Maven
    Réponses: 7
    Dernier message: 28/07/2006, 16h24
  4. PLUGIN [Eclipse][MDA]Web services Modeling
    Par jmeclipse dans le forum Eclipse Java
    Réponses: 4
    Dernier message: 27/04/2006, 10h40
  5. [Plugin][Jonas]Eclipse et Web services
    Par Abik dans le forum Eclipse Java
    Réponses: 4
    Dernier message: 17/01/2005, 19h22

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo