Index: ../web/admin/src/main/java/org/glassfish/web/admin/cli/CreateNetworkListener.java =================================================================== --- ../web/admin/src/main/java/org/glassfish/web/admin/cli/CreateNetworkListener.java (revision 40201) +++ ../web/admin/src/main/java/org/glassfish/web/admin/cli/CreateNetworkListener.java (revision ) @@ -43,10 +43,8 @@ import java.beans.PropertyVetoException; import java.util.List; -import org.glassfish.internal.api.Target; import com.sun.enterprise.config.serverbeans.Config; import com.sun.enterprise.config.serverbeans.Domain; -import com.sun.enterprise.config.serverbeans.Server; import com.sun.enterprise.config.serverbeans.VirtualServer; import com.sun.enterprise.util.LocalStringManagerImpl; import com.sun.enterprise.util.SystemPropertyConstants; @@ -62,10 +60,11 @@ import org.glassfish.api.admin.AdminCommand; import org.glassfish.api.admin.AdminCommandContext; import org.glassfish.api.admin.ExecuteOn; -import org.glassfish.api.admin.ServerEnvironment; import org.glassfish.api.admin.RuntimeType; +import org.glassfish.api.admin.ServerEnvironment; import org.glassfish.config.support.CommandTarget; import org.glassfish.config.support.TargetType; +import org.glassfish.internal.api.Target; import org.jvnet.hk2.annotations.Inject; import org.jvnet.hk2.annotations.Scoped; import org.jvnet.hk2.annotations.Service; @@ -91,7 +90,7 @@ String address; @Param(name = "listenerport", optional = false, alias="Port") String port; - @Param(name = "threadpool", optional = true, defaultValue = "http-thread-pool") + @Param(name = "threadpool", optional = true, defaultValue = "http-thread-pool", alias="threadPool") String threadPool; @Param(name = "protocol", optional = false) String protocol; @@ -101,9 +100,9 @@ String transport; @Param(name = "enabled", optional = true, defaultValue = "true") Boolean enabled; - @Param(name = "jkenabled", optional = true, defaultValue = "false") + @Param(name = "jkenabled", optional = true, defaultValue = "false", alias = "jkEnabled") Boolean jkEnabled; - @Param(name = "target", optional = true, defaultValue = SystemPropertyConstants.DEFAULT_SERVER_INSTANCE_NAME) + @Param(name = "target", optional = true, defaultValue = SystemPropertyConstants.DAS_SERVER_NAME) String target; @Inject(name = ServerEnvironment.DEFAULT_INSTANCE_NAME) Config config; @@ -187,7 +186,7 @@ report.setActionExitCode(ActionReport.ExitCode.SUCCESS); } - private VirtualServer findVirtualServer(final Protocol protocol) { + private VirtualServer findVirtualServer(Protocol protocol) { String name = null; final Http http = protocol.getHttp(); if (http != null) { Index: ../web/admin/src/main/java/org/glassfish/web/admin/cli/CreateHttp.java =================================================================== --- ../web/admin/src/main/java/org/glassfish/web/admin/cli/CreateHttp.java (revision 40201) +++ ../web/admin/src/main/java/org/glassfish/web/admin/cli/CreateHttp.java (revision ) @@ -89,21 +89,21 @@ new LocalStringManagerImpl(CreateHttp.class); @Param(name = "protocolname", primary = true) String protocolName; - @Param(name = "request-timeout-seconds", optional = true) + @Param(name = "request-timeout-seconds", optional = true, alias="requestTimeoutSeconds") String requestTimeoutSeconds; - @Param(name = "timeout-seconds", defaultValue = "30", optional = true) + @Param(name = "timeout-seconds", defaultValue = "30", optional = true, alias="timeoutSeconds") String timeoutSeconds; - @Param(name = "max-connection", defaultValue = "256", optional = true) + @Param(name = "max-connection", defaultValue = "256", optional = true, alias="maxConnections") String maxConnections; - @Param(name = "default-virtual-server", alias="DefaultVirtualServer") + @Param(name = "default-virtual-server", alias="defaultVirtualServer") String defaultVirtualServer; - @Param(name = "dns-lookup-enabled", defaultValue = "false", optional = true) + @Param(name = "dns-lookup-enabled", defaultValue = "false", optional = true, alias="dnsLookupEnabled") Boolean dnsLookupEnabled = false; - @Param(name = "servername", optional = true) + @Param(name = "servername", optional = true, alias="serverName") String serverName; - @Param(name = "xpowered", optional = true, defaultValue = "true") + @Param(name = "xpowered", optional = true, defaultValue = "true", alias="xpoweredBy") Boolean xPoweredBy = false; - @Param(name = "target", optional = true, defaultValue = SystemPropertyConstants.DEFAULT_SERVER_INSTANCE_NAME) + @Param(name = "target", optional = true, defaultValue = SystemPropertyConstants.DAS_SERVER_NAME) String target; @Inject(name = ServerEnvironment.DEFAULT_INSTANCE_NAME) Config config; @@ -167,9 +167,8 @@ }, protocol); } catch (TransactionFailure e) { report.setMessage(localStrings.getLocalString("create.http.redirect.fail", - "Failed to create http-redirect for {0}: {1}", - protocolName, - (e.getMessage() == null ? "No reason given." : e.getMessage()))); + "Failed to create http-redirect for {0}: {1}", protocolName, + e.getMessage() == null ? "No reason given." : e.getMessage())); report.setActionExitCode(ActionReport.ExitCode.FAILURE); report.setFailureCause(e); return;