Announcement Announcement Module
Collapse
No announcement yet.
Samples do not Compile Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Samples do not Compile

    Your samples do not compile because Maven cannot download what it needs from the web. Here is an idea, why not set the samples so that maven does not need to download anything from the web, this way, if a person trying this out does not have an internet connection, they can still get this working.

    By the way, I do have an internet connection, but maven still fails to download what it needs.

    Here is the error I get:

    c:\devtools\tools\java-tools\exe\spring-ws\spring-ws-1.5.6\samples\tutorial>mvn package
    [INFO] Scanning for projects...
    Downloading: http://s3.amazonaws.com/maven.spring...rent-1.5.6.pom
    [WARNING] Unable to get resource 'org.springframework.ws:spring-ws-parentom:1.5.6' from repository spring-milestone (http://s3.amazonaws.com/maven.springframework.org/m
    ilestone): Error transferring file: Connection timed out: connect
    Downloading: http://repo1.maven.org/maven2/org/sp...rent-1.5.6.pom
    [WARNING] Unable to get resource 'org.springframework.ws:spring-ws-parentom:1.5.6' from repository central (http://repo1.maven.org/maven2): Error transferring file: Con
    nection timed out: connect
    [INFO] ------------------------------------------------------------------------
    [ERROR] FATAL ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Failed to resolve artifact.

    GroupId: org.springframework.ws
    ArtifactId: spring-ws-parent
    Version: 1.5.6

    Reason: Unable to download the artifact from any repository

    org.springframework.ws:spring-ws-parentom:1.5.6

    from the specified remote repositories:
    central (http://repo1.maven.org/maven2),
    spring-milestone (http://s3.amazonaws.com/maven.spring....org/milestone)

  • #2
    Section 3.5 from the Tutorial also does not compile

    Section 3.5 from the Tutorial also does not compile because Maven cannot get what it needs:

    c:\devtools\tools\java-tools\exe\spring-ws\spring-ws-1.5.6\samples\3.5>mvn archetype:create -DarchetypeGroupId=org.springframework.ws -DarchetypeArtifactId=spring-ws-arch
    etype -DarchetypeVersion=1.5.6 -DgroupId=com.mycompany.hr -DartifactId=holidayService
    [INFO] Scanning for projects...
    [INFO] Searching repository for plugin with prefix: 'archetype'.
    [INFO] org.apache.maven.plugins: checking for updates from central
    [WARNING] repository metadata for: 'org.apache.maven.plugins' could not be retrieved from repository: central due to an error: Error transferring file: Connection timed o
    ut: connect
    [INFO] Repository 'central' will be blacklisted
    [INFO] ------------------------------------------------------------------------
    [ERROR] BUILD ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] The plugin 'org.apache.maven.plugins:maven-archetype-plugin' does not exist or no valid version could be found
    [INFO] ------------------------------------------------------------------------
    [INFO] For more information, run Maven with the -e switch
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 21 seconds
    [INFO] Finished at: Mon Mar 30 12:21:06 EDT 2009
    [INFO] Final Memory: 1M/254M
    [INFO] ------------------------------------------------------------------------

    Comment


    • #3
      It works with the proper proxy config

      Used the settings.xml in Maven to setup access to the internet via the proxy and it worked; i was able to build the samples.

      Comment


      • #4
        Jaxws MTOM Client Sample does not compile

        Hi,

        I tried following your instructions and running the ant build command for the JAXWS MTOM client example and finally gave up after a day of retrying and resolving dependencies that Maven failed to download. The worst part is that it does not report all unresolved dependencies at once and you have to run through the build process over and over until you no longer get missing dependencies errors and each build process, on a fast network takes about 8 minutes. I finally resolved all the missing dependencies manually and now the project still does not build and complains about a class that it should find since I manually installed jaxws-api.jar and verified the class is inside the jar.

        Here are the packages I had to manually download and install:

        call mvn install:install-file -DgroupId=com.sun.xml.stream -DartifactId=sjsxp -Dversion=1.0 -Dpackaging=jar -Dfile=C:/devtools/tools/java-tools/exe/spring-ws/jars/sjsxp.jar
        call mvn install:install-file -DgroupId=com.sun.xml.ws -DartifactId=jaxws-tools -Dversion=EA3 -Dpackaging=jar -Dfile=C:/devtools/tools/java-tools/exe/spring-ws/jars/jaxws-tools.jar
        call mvn install:install-file -DgroupId=com.sun.xml.stream.buffer -DartifactId=streambuffer -Dversion=0.3 -Dpackaging=jar -Dfile=C:/devtools/tools/java-tools/exe/spring-ws/jars/streambuffer.jar
        call mvn install:install-file -DgroupId=com.sun.xml.bind -DartifactId=jaxb-xjc -Dversion=2.1-EA2 -Dpackaging=jar -Dfile=C:/devtools/tools/java-tools/exe/spring-ws/jars/jaxb-xjc.jar
        call mvn install:install-file -DgroupId=org.jvnet.staxex -DartifactId=stax-ex -Dversion=1.0 -Dpackaging=jar -Dfile=C:/devtools/tools/java-tools/exe/spring-ws/jars/stax-ex.jar
        call mvn install:install-file -DgroupId=javax.activation -DartifactId=activation -Dversion=1.0.2 -Dpackaging=jar -Dfile=C:/devtools/tools/java-tools/exe/spring-ws/jars/activation.jar
        call mvn install:install-file -DgroupId=javax.xml.ws -DartifactId=jaxws-api -Dversion=2.1-SNAPSHOT -Dpackaging=jar -Dfile=C:/devtools/tools/java-tools/exe/spring-ws/jars/jaxws-api.jar
        call mvn install:install-file -DgroupId=org.springframework -DartifactId=spring-core -Dversion=2.0.5 -Dpackaging=jar -Dfile=C:/devtools/tools/java-tools/exe/spring-ws/jars/spring-core.jar
        call mvn install:install-file -DgroupId=com.sun.xml.ws -DartifactId=jaxws-rt -Dversion=EA3 -Dpackaging=jar -Dfile=C:/devtools/tools/java-tools/exe/spring-ws/jars/jaxws-rt.jar
        call mvn install:install-file -DgroupId=com.sun.xml.bind -DartifactId=jaxb-impl -Dversion=2.1-EA2 -Dpackaging=jar -Dfile=C:/devtools/tools/java-tools/exe/spring-ws/jars/jaxb-impl.jar


        And here is the final error:


        C:\devtools\tools\java-tools\exe\spring-ws\spring-ws-1.5.6\samples\mtom\client\jaxws>ant build
        Buildfile: build.xml

        init:
        [artifact:dependencies] Downloading: com/sun/xml/ws/jaxws-tools/EA3/jaxws-tools-EA3.pom
        [artifact:dependencies] Downloading: com.sun.xml.ws/poms/jaxws-tools-EA3.pom
        [artifact:dependencies] Downloading: com/sun/xml/bind/jaxb-xjc/2.1-EA2/jaxb-xjc-2.1-EA2.pom
        [artifact:dependencies] Downloading: com.sun.xml.bind/poms/jaxb-xjc-2.1-EA2.pom
        [artifact:dependencies] Downloading: com/sun/xml/stream/buffer/streambuffer/0.3/streambuffer-0.3.pom
        [artifact:dependencies] Downloading: com.sun.xml.stream.buffer/poms/streambuffer-0.3.pom
        [artifact:dependencies] Downloading: com/sun/xml/stream/sjsxp/1.0/sjsxp-1.0.pom
        [artifact:dependencies] Downloading: com.sun.xml.stream/poms/sjsxp-1.0.pom
        [artifact:dependencies] Downloading: org/jvnet/staxex/stax-ex/1.0/stax-ex-1.0.pom
        [artifact:dependencies] Downloading: org.jvnet.staxex/poms/stax-ex-1.0.pom
        [artifact:dependencies] Downloading: javax/activation/activation/1.0.2/activation-1.0.2.pom
        [artifact:dependencies] Downloading: javax.activation/poms/activation-1.0.2.pom
        [artifact:dependencies] Downloading: javax/xml/ws/jaxws-api/2.1-SNAPSHOT/jaxws-api-2.1-SNAPSHOT.pom
        [artifact:dependencies] Downloading: javax.xml.ws/poms/jaxws-api-2.1-SNAPSHOT.pom
        [artifact:dependencies] Downloading: org/springframework/spring-core/2.0.5/spring-core-2.0.5.pom
        [artifact:dependencies] Downloading: org.springframework/poms/spring-core-2.0.5.pom
        [artifact:dependencies] Downloading: com/sun/xml/ws/jaxws-rt/EA3/jaxws-rt-EA3.pom
        [artifact:dependencies] Downloading: com.sun.xml.ws/poms/jaxws-rt-EA3.pom
        [artifact:dependencies] Downloading: com/sun/xml/bind/jaxb-impl/2.1-EA2/jaxb-impl-2.1-EA2.pom
        [artifact:dependencies] Downloading: com.sun.xml.bind/poms/jaxb-impl-2.1-EA2.pom

        generate:

        BUILD FAILED
        C:\devtools\tools\java-tools\exe\spring-ws\spring-ws-1.5.6\samples\mtom\client\jaxws\build.xml:56: java.lang.NoClassDefFoundError: javax/xml/ws/Service

        Total time: 7 minutes 1 second

        Comment

        Working...
        X