title: Spring Maven - Unable to generate WSDL
body: <p>I'm trying to generate the WSDL from a URL but it's/I'm unable to do it. My POM.xml file is configured like this:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"&gt;
  &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
  
  &lt;groupId&gt;org.springframework&lt;/groupId&gt;
  &lt;artifactId&gt;gs-consuming-web-service&lt;/artifactId&gt;
  &lt;version&gt;0.1.0&lt;/version&gt;
  
  &lt;parent&gt;
      &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
      &lt;artifactId&gt;spring-boot-starter-parent&lt;/artifactId&gt;
      &lt;version&gt;1.2.2.RELEASE&lt;/version&gt;
  &lt;/parent&gt;
  
  &lt;properties&gt;
      &lt;!-- use UTF-8 for everything --&gt;
      &lt;project.build.sourceEncoding&gt;UTF-8&lt;/project.build.sourceEncoding&gt;
      &lt;project.reporting.outputEncoding&gt;UTF-8&lt;/project.reporting.outputEncoding&gt;
  &lt;/properties&gt;
  
  &lt;dependencies&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
          &lt;artifactId&gt;spring-boot-starter&lt;/artifactId&gt;
      &lt;/dependency&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;org.springframework.ws&lt;/groupId&gt;
          &lt;artifactId&gt;spring-ws-core&lt;/artifactId&gt;
      &lt;/dependency&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;com.sun.xml.bind&lt;/groupId&gt;
          &lt;artifactId&gt;jaxb-xjc&lt;/artifactId&gt;
          &lt;version&gt;2.2.5&lt;/version&gt;
      &lt;/dependency&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;org.jvnet.jaxb2.maven2&lt;/groupId&gt;
          &lt;artifactId&gt;maven-jaxb2-plugin&lt;/artifactId&gt;
          &lt;version&gt;0.12.3&lt;/version&gt;
      &lt;/dependency&gt;
  &lt;/dependencies&gt;
  
  &lt;build&gt;
      &lt;plugins&gt;
          &lt;plugin&gt;
              &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
              &lt;artifactId&gt;spring-boot-maven-plugin&lt;/artifactId&gt;
          &lt;/plugin&gt;
          &lt;!-- tag::wsdl[] --&gt;
          &lt;plugin&gt;
              &lt;groupId&gt;org.jvnet.jaxb2.maven2&lt;/groupId&gt;
              &lt;artifactId&gt;maven-jaxb2-plugin&lt;/artifactId&gt;
              &lt;version&gt;0.12.3&lt;/version&gt;
              &lt;executions&gt;
                  &lt;execution&gt;
                      &lt;goals&gt;
                          &lt;goal&gt;generate&lt;/goal&gt;
                      &lt;/goals&gt;
                  &lt;/execution&gt;
              &lt;/executions&gt;
              &lt;configuration&gt;
                  &lt;schemaLanguage&gt;WSDL&lt;/schemaLanguage&gt;
                  &lt;generatePackage&gt;hello.wsdl&lt;/generatePackage&gt;
                  &lt;schemas&gt;
                      &lt;schema&gt;
                          &lt;url&gt;http://wsf.cdyne.com/WeatherWS/Weather.asmx?wsdl&lt;/url&gt;
                      &lt;/schema&gt;
                  &lt;/schemas&gt;
              &lt;/configuration&gt;
          &lt;/plugin&gt;
          &lt;!-- end::wsdl[] --&gt;
      &lt;/plugins&gt;
      &lt;pluginManagement&gt;
          &lt;plugins&gt;
              &lt;!--This plugin's configuration is used to store Eclipse m2e settings 
                  only. It has no influence on the Maven build itself. --&gt;
              &lt;plugin&gt;
                  &lt;groupId&gt;org.eclipse.m2e&lt;/groupId&gt;
                  &lt;artifactId&gt;lifecycle-mapping&lt;/artifactId&gt;
                  &lt;version&gt;1.0.0&lt;/version&gt;
                  &lt;configuration&gt;
                      &lt;lifecycleMappingMetadata&gt;
                          &lt;pluginExecutions&gt;
                              &lt;pluginExecution&gt;
                                  &lt;pluginExecutionFilter&gt;
                                      &lt;groupId&gt;
                                          org.jvnet.jaxb2.maven2
                                      &lt;/groupId&gt;
                                      &lt;artifactId&gt;
                                          maven-jaxb2-plugin
                                      &lt;/artifactId&gt;
                                      &lt;versionRange&gt;
                                          [0.8.0,)
                                      &lt;/versionRange&gt;
                                      &lt;goals&gt;
                                          &lt;goal&gt;generate&lt;/goal&gt;
                                      &lt;/goals&gt;
                                  &lt;/pluginExecutionFilter&gt;
                                  &lt;action&gt;
                                      &lt;ignore&gt;&lt;/ignore&gt;
                                  &lt;/action&gt;
                              &lt;/pluginExecution&gt;
                          &lt;/pluginExecutions&gt;
                      &lt;/lifecycleMappingMetadata&gt;
                  &lt;/configuration&gt;
              &lt;/plugin&gt;
          &lt;/plugins&gt;
      &lt;/pluginManagement&gt;
  &lt;/build&gt;
  
  &lt;repositories&gt;
      &lt;repository&gt;
          &lt;id&gt;spring-releases&lt;/id&gt;
          &lt;name&gt;Spring Releases&lt;/name&gt;
          &lt;url&gt;https://repo.spring.io/libs-release&lt;/url&gt;
      &lt;/repository&gt;
  &lt;/repositories&gt;
  &lt;pluginRepositories&gt;
      &lt;pluginRepository&gt;
          &lt;id&gt;spring-releases&lt;/id&gt;
          &lt;url&gt;https://repo.spring.io/libs-release&lt;/url&gt;
      &lt;/pluginRepository&gt;
  &lt;/pluginRepositories&gt;
  
  &lt;/project&gt;
  </code></pre>
  
  <p>I resolved all the errors that occured in the POM.xml file and jaxb2 is recognized. When i run "maven generate-sources" i get the following output:</p>
  
  <blockquote>
    <p>[WARNING] The URI [wsf.cdyne.com/WeatherWS/Weather.asmx?wsdl] seems to represent an absolute HTTP or HTTPS URL. Getting the last modification timestamp is only possible if the URL is accessible and if the server returns the [Last-Modified] header correctly. This method is not reliable and is likely to fail. In this case the last modification timestamp will be assumed to be unknown.
    [ERROR] Could not retrieve the last modification timestamp for the URI [wsf.cdyne.com/WeatherWS/Weather.asmx?wsdl] from the HTTP URL connection. The [Last-Modified] header was probably not set correctly.
    [WARNING] Last modification of the URI [<a href="http://wsf.cdyne.com/WeatherWS/Weather.asmx?wsdl]" rel="nofollow noreferrer">http://wsf.cdyne.com/WeatherWS/Weather.asmx?wsdl]</a> is not known.</p>
  </blockquote>
  
  <p>But i have no clue how to solve this. The same soap service is used in this <a href="https://spring.io/guides/gs/consuming-web-service/" rel="nofollow noreferrer">Spring Guide</a></p>
  
  <p>(I had to change the url in error message because i can't post more than 2 links)</p>