You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-commits@axis.apache.org by ve...@apache.org on 2016/03/18 19:57:16 UTC

svn commit: r1735661 - /axis/axis2/java/core/trunk/modules/tool/axis2-wsdl2code-maven-plugin/src/main/java/org/apache/axis2/maven2/wsdl2code/AbstractWSDL2CodeMojo.java

Author: veithen
Date: Fri Mar 18 18:57:16 2016
New Revision: 1735661

URL: http://svn.apache.org/viewvc?rev=1735661&view=rev
Log:
AXIS2-5283: Revert r1325737. Reasons:
- Two of the options (user and password) actually don't have any effect because CodeGenConfigLoader doesn't interpret them (there are only interpreted by the WSDL2Code command line util).
- Changing system properties during a Mojo execution is evil because it may have unexpected side effects on other Mojos.
- Proxy settings should be obtained from settings.xml via the appropriate Maven APIs.
- Downloading files from the Internet during a Maven build (except of course for dependencies downloaded by Maven itself) is a very bad practice and should not be encouraged.

Modified:
    axis/axis2/java/core/trunk/modules/tool/axis2-wsdl2code-maven-plugin/src/main/java/org/apache/axis2/maven2/wsdl2code/AbstractWSDL2CodeMojo.java

Modified: axis/axis2/java/core/trunk/modules/tool/axis2-wsdl2code-maven-plugin/src/main/java/org/apache/axis2/maven2/wsdl2code/AbstractWSDL2CodeMojo.java
URL: http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/tool/axis2-wsdl2code-maven-plugin/src/main/java/org/apache/axis2/maven2/wsdl2code/AbstractWSDL2CodeMojo.java?rev=1735661&r1=1735660&r2=1735661&view=diff
==============================================================================
--- axis/axis2/java/core/trunk/modules/tool/axis2-wsdl2code-maven-plugin/src/main/java/org/apache/axis2/maven2/wsdl2code/AbstractWSDL2CodeMojo.java (original)
+++ axis/axis2/java/core/trunk/modules/tool/axis2-wsdl2code-maven-plugin/src/main/java/org/apache/axis2/maven2/wsdl2code/AbstractWSDL2CodeMojo.java Fri Mar 18 18:57:16 2016
@@ -254,26 +254,6 @@ public abstract class AbstractWSDL2CodeM
      */
     private NamespaceURIMapping[] namespaceURIs = null;
     
-    /**
-     * @parameter expression="${axis2.wsdl2code.http-proxy-host}"
-     */
-    private String httpProxyHost = null;
-
-    /**
-     * @parameter expression="${axis2.wsdl2code.http-proxy-port}"
-     */
-    private String httpProxyPort = null;
-
-    /**
-     * @parameter expression="${axis2.wsdl2code.http-proxy-user}"
-     */
-    private String httpProxyUser = null;
-
-    /**
-     * @parameter expression="${axis2.wsdl2code.http-proxy-password}"
-     */
-    private String httpProxyPassword = null;
-
     /** Fills the option map. This map is passed onto the code generation API to generate the code. */
     private Map<String,CommandLineOption> fillOptionMap() throws MojoFailureException {
         Map<String,CommandLineOption> optionMap = new HashMap<String,CommandLineOption>();
@@ -548,38 +528,6 @@ public abstract class AbstractWSDL2CodeM
                             new String[] { getNamespaceToPackagesMap() }));
         }
         
-        if (httpProxyHost != null) {
-            optionMap
-                    .put(CommandLineOptionConstants.WSDL2JavaConstants.HTTP_PROXY_HOST_OPTION_LONG,
-                            new CommandLineOption(
-                                    CommandLineOptionConstants.WSDL2JavaConstants.HTTP_PROXY_HOST_OPTION_LONG,
-                                    new String[] { httpProxyHost }));
-        }
-
-        if (httpProxyPort != null) {
-            optionMap
-                    .put(CommandLineOptionConstants.WSDL2JavaConstants.HTTP_PROXY_PORT_OPTION_LONG,
-                            new CommandLineOption(
-                                    CommandLineOptionConstants.WSDL2JavaConstants.HTTP_PROXY_PORT_OPTION_LONG,
-                                    new String[] { httpProxyPort }));
-        }
-
-        if (httpProxyUser != null) {
-            optionMap
-                    .put(CommandLineOptionConstants.WSDL2JavaConstants.HTTP_PROXY_USER_OPTION_LONG,
-                            new CommandLineOption(
-                                    CommandLineOptionConstants.WSDL2JavaConstants.HTTP_PROXY_USER_OPTION_LONG,
-                                    new String[] { httpProxyUser }));
-        }
-
-        if (httpProxyPassword != null) {
-            optionMap
-                    .put(CommandLineOptionConstants.WSDL2JavaConstants.HTTP_PROXY_PASSWORD_OPTION_LONG,
-                            new CommandLineOption(
-                                    CommandLineOptionConstants.WSDL2JavaConstants.HTTP_PROXY_PASSWORD_OPTION_LONG,
-                                    new String[] { httpProxyPassword }));
-        }
-        
         return optionMap;
     }