Announcement Announcement Module
Collapse
No announcement yet.
problem running the sample code Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • problem running the sample code

    I am a newbie to Spring and Maven. I downloaded spring-ws-1.0-m2-full.zip Mirror. In it there's this "airline" example. As I tried to run the "maven package" in a DOS command box, I got the following error. Can someone give me a pointer as what the problem is? Why Maven is trying to download something from the web? It doesn't seem to be a valid location.

    Thanks.

    [INFO] Scanning for projects...
    Downloading: http://repo1.maven.org/maven2/org/sp...0-m2/spring-ws
    -samples-1.0-m2.pom
    [WARNING] Unable to get resource from repository central (http://repo1.maven.org/maven2)
    [INFO] ------------------------------------------------------------------------
    [ERROR] FATAL ERROR
    [INFO] ------------------------------------------------------------------------
    [INFO] Failed to resolve artifact.

    GroupId: org.springframework.ws
    ArtifactId: spring-ws-samples
    Version: 1.0-m2

    Reason: Unable to download the artifact from any repository

    org.springframework.ws:spring-ws-samplesom:1.0-m2

    from the specified remote repositories:
    central (http://repo1.maven.org/maven2)


    [INFO] ------------------------------------------------------------------------
    [INFO] Trace
    org.apache.maven.reactor.MavenExecutionException: Cannot find parent: org.springframework.ws:spring-
    ws-samples for project: null:airline:war:null
    at org.apache.maven.DefaultMaven.getProjects(DefaultM aven.java:365)
    at org.apache.maven.DefaultMaven.doExecute(DefaultMav en.java:278)
    at org.apache.maven.DefaultMaven.execute(DefaultMaven .java:115)
    at org.apache.maven.cli.MavenCli.main(MavenCli.java:2 56)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Nativ e Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Native MethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(De legatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at org.codehaus.classworlds.Launcher.launchEnhanced(L auncher.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.ja va:375)
    Caused by: org.apache.maven.project.ProjectBuildingException: Cannot find parent: org.springframewor
    k.ws:spring-ws-samples for project: null:airline:war:null
    at org.apache.maven.project.DefaultMavenProjectBuilde r.assembleLineage(DefaultMavenProjectBu
    ilder.java:1161)
    at org.apache.maven.project.DefaultMavenProjectBuilde r.buildInternal(DefaultMavenProjectBuil
    der.java:674)
    at org.apache.maven.project.DefaultMavenProjectBuilde r.buildFromSourceFileInternal(DefaultMa
    venProjectBuilder.java:416)
    at org.apache.maven.project.DefaultMavenProjectBuilde r.build(DefaultMavenProjectBuilder.java
    :192)
    at org.apache.maven.DefaultMaven.getProject(DefaultMa ven.java:515)
    at org.apache.maven.DefaultMaven.collectProjects(Defa ultMaven.java:447)
    at org.apache.maven.DefaultMaven.getProjects(DefaultM aven.java:351)
    ... 11 more
    Caused by: org.apache.maven.project.ProjectBuildingException: POM 'org.springframework.ws:spring-ws-
    samples' not found in repository: Unable to download the artifact from any repository

    org.springframework.ws:spring-ws-samplesom:1.0-m2

    from the specified remote repositories:
    central (http://repo1.maven.org/maven2)

    at org.apache.maven.project.DefaultMavenProjectBuilde r.findModelFromRepository(DefaultMavenP
    rojectBuilder.java:513)
    at org.apache.maven.project.DefaultMavenProjectBuilde r.assembleLineage(DefaultMavenProjectBu
    ilder.java:1157)
    ... 17 more
    Caused by: org.apache.maven.artifact.resolver.ArtifactNotFoun dException: Unable to download the arti
    fact from any repository

    org.springframework.ws:spring-ws-samplesom:1.0-m2

    from the specified remote repositories:
    central (http://repo1.maven.org/maven2)

    at org.apache.maven.artifact.resolver.DefaultArtifact Resolver.resolve(DefaultArtifactResolve
    r.java:136)
    at org.apache.maven.artifact.resolver.DefaultArtifact Resolver.resolve(DefaultArtifactResolve
    r.java:63)
    at org.apache.maven.project.DefaultMavenProjectBuilde r.findModelFromRepository(DefaultMavenP
    rojectBuilder.java:467)
    ... 18 more
    Caused by: org.apache.maven.wagon.ResourceDoesNotExistExcepti on: Unable to download the artifact fro
    m any repository
    at org.apache.maven.artifact.manager.DefaultWagonMana ger.getArtifact(DefaultWagonManager.jav
    a:260)
    at org.apache.maven.artifact.resolver.DefaultArtifact Resolver.resolve(DefaultArtifactResolve
    r.java:124)
    ... 20 more
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: < 1 second
    [INFO] Finished at: Thu Dec 14 15:58:01 GMT-05:00 2006
    [INFO] Final Memory: 1M/2M
    [INFO] ------------------------------------------------------------------------

  • #2
    There is one final missing in that release, which is necessary for the samples to work. You can download it here. Place that file in the samples directory (i.e. the parent dir of echo and airline), and everything should work.

    Comment

    Working...
    X