title: How to exclude maven plugin configuration (unrecognized parameter -encoding)
body: <p>I am using <code>jaxws-maven-plugin</code> to generate some JAX-WS clients based on WSDL files.</p>
  
  <p>I need to use JDK 1.6 so I am executing with JAX-WS Tools 2.1.7</p>
  
  <pre><code>&lt;dependency&gt;
      &lt;groupId&gt;com.sun.xml.ws&lt;/groupId&gt;
      &lt;artifactId&gt;jaxws-tools&lt;/artifactId&gt;
      &lt;version&gt;2.1.7&lt;/version&gt;
  &lt;/dependency&gt;
  </code></pre>
  
  <p>If I use recent versions of <code>jaxws-maven-plugin</code> <code>2.2.1</code> or <code>2.3</code> over the 2.1.7 jaxws-tools my build doesn't work because an invalid -encoding parameter is added to the command line.</p>
  
  <pre><code>unrecognized parameter -encoding
  </code></pre>
  
  <p>Full command is</p>
  
  <pre><code>[DEBUG] cmd.exe /X /C ""C:\Program Files\Java\jdk1.6.0_45\jre\bin\java.exe" -Xbootclasspath/p:.m2\repository\javax\xml\bind\jaxb-api\2.1\jaxb-api-2.1.jar;.m2\repository\javax\xml\soap\saaj-api\1.3\saaj-api-1.3.jar;.m2\repository\javax\xml\ws\jaxws-api\2.1\jaxws-api-2.1.jar org.jvnet.jax_ws_commons.jaxws.Invoker com.sun.tools.ws.wscompile.WsimportTool -keep -s &lt;some dir&gt; -d &lt;some dir&gt; -encoding UTF-8 -p &lt;some package&gt; file:&lt;some wsdl file&gt;"
  </code></pre>
  
  <p>The following pom.xml is working fine, I use 2.2 which does not send the encoding parameter.</p>
  
  <pre><code>&lt;build&gt;
      &lt;plugins&gt;
          &lt;plugin&gt;
              &lt;groupId&gt;org.jvnet.jax-ws-commons&lt;/groupId&gt;
              &lt;artifactId&gt;jaxws-maven-plugin&lt;/artifactId&gt;
              &lt;version&gt;2.2&lt;/version&gt; &lt;!-- This version works fine --&gt;
              &lt;executions&gt;
                  &lt;execution&gt;
                      &lt;goals&gt;
                          &lt;goal&gt;wsimport&lt;/goal&gt;
                      &lt;/goals&gt;
                  &lt;/execution&gt;
              &lt;/executions&gt;
              &lt;configuration&gt;
                  &lt;wsdlDirectory&gt;src/wsdl&lt;/wsdlDirectory&gt;
                  &lt;sourceDestDir&gt;src/main/java&lt;/sourceDestDir&gt;
                  &lt;wsdlFiles&gt;
                      &lt;wsdlFile&gt;ConsultarStatusNfe.wsdl&lt;/wsdlFile&gt;
                  &lt;/wsdlFiles&gt;
                  &lt;!-- for JDK 6 compilation compatibility --&gt;
                  &lt;xnocompile&gt;false&lt;/xnocompile&gt;
              &lt;/configuration&gt;
              &lt;dependencies&gt;
                  &lt;dependency&gt;
                      &lt;groupId&gt;com.sun.xml.ws&lt;/groupId&gt;
                      &lt;artifactId&gt;jaxws-tools&lt;/artifactId&gt;
                      &lt;version&gt;2.1.7&lt;/version&gt;
                  &lt;/dependency&gt;
              &lt;/dependencies&gt;
          &lt;/plugin&gt;
      &lt;/plugins&gt;
  &lt;/build&gt;
  </code></pre>