diff -r 44c8fd88cd59 j2ee.sun.appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/AddDomainPortsDefPanel.java --- a/j2ee.sun.appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/AddDomainPortsDefPanel.java Tue Mar 18 16:56:20 2008 -0700 +++ b/j2ee.sun.appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/AddDomainPortsDefPanel.java Wed Mar 19 12:49:04 2008 -0700 @@ -1,7 +1,7 @@ /* * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. * - * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved. + * Copyright 1997-2008 Sun Microsystems, Inc. All rights reserved. * * The contents of this file are subject to the terms of either the GNU * General Public License Version 2 only ("GPL") or the Common @@ -48,6 +48,7 @@ import javax.swing.event.ChangeEvent; import javax.swing.event.ChangeEvent; import javax.swing.event.ChangeListener; +import org.netbeans.modules.j2ee.sun.ide.j2ee.PlatformValidator; import org.openide.WizardDescriptor; import org.openide.util.HelpCtx; import org.openide.util.NbBundle; @@ -66,6 +67,8 @@ public class AddDomainPortsDefPanel impl */ private CreateServerVisualPanel component; private WizardDescriptor wiz; + private PlatformValidator pv; + private String serverVersion; // private TargetServerData targetData; /** Create the wizard panel descriptor. */ @@ -96,28 +99,36 @@ public class AddDomainPortsDefPanel impl Set portsUsed = new HashSet(7); portsUsed.add(component.getAdminPort()); - if (isPortReused(portsUsed, component.getAdminJmxPort(), "ERR_AdminJmxPort")) + if (isPortReused(portsUsed, component.getAdminJmxPort(), "ERR_AdminJmxPort")) // NOI18N return false; - if (isPortReused(portsUsed, component.getInstanceHttpPort(), "ERR_InstancePort")) + if (isPortReused(portsUsed, component.getInstanceHttpPort(), "ERR_InstancePort")) // NOI18N return false; - if (isPortReused(portsUsed, component.getJmsPort(), "ERR_JmsPort")) + if (isPortReused(portsUsed, component.getJmsPort(), "ERR_JmsPort")) // NOI18N return false; - if (isPortReused(portsUsed,component.getOrbPort(), "ERR_OrbListenerPort")) + if (isPortReused(portsUsed,component.getOrbPort(), "ERR_OrbListenerPort")) // NOI18N return false; - if (isPortReused(portsUsed,component.getHttpSslPort(), "ERR_HttpSslPort")) + if (isPortReused(portsUsed,component.getHttpSslPort(), "ERR_HttpSslPort")) // NOI18N return false; - if (isPortReused(portsUsed,component.getOrbSslPort(), "ERR_OrbSslPort")) + if (isPortReused(portsUsed,component.getOrbSslPort(), "ERR_OrbSslPort")) // NOI18N return false; - if (isPortReused(portsUsed,component.getOrbMutualAuthPort(), "ERR_OrbMutualAutPort")) + if (isPortReused(portsUsed,component.getOrbMutualAuthPort(), "ERR_OrbMutualAutPort")) // NOI18N return false; + if (PlatformValidator.SAILFIN_V1.equals(serverVersion)) { + if (isPortReused(portsUsed,component.getSipPort(), "ERR_SipPort")) // NOI18N + return false; + + if (isPortReused(portsUsed,component.getSipSslPort(), "ERR_SipSslPort")) // NOI18N + return false; + } + wiz.putProperty(AddDomainWizardIterator.ADMIN_JMX_PORT, component.getAdminJmxPort().toString()); wiz.putProperty(AddDomainWizardIterator.HTTP_SSL_PORT, @@ -135,11 +146,21 @@ public class AddDomainPortsDefPanel impl wiz.putProperty(AddDomainWizardIterator.PORT, component.getAdminPort().toString()); + // these values are ignored for non-sailfin platforms... + wiz.putProperty(AddDomainWizardIterator.SIP_PORT, + component.getSipPort().toString()); + wiz.putProperty(AddDomainWizardIterator.SIP_SSL_PORT, + component.getSipSslPort().toString()); + wiz.putProperty(AddDomainWizardIterator.PROP_ERROR_MESSAGE,null); wiz.putProperty(AddDomainWizardIterator.HOST,"localhost"); //NOI18N return true; } + void setPlatformValidator(PlatformValidator pv, String serverVersion) { + this.pv = pv; + this.serverVersion = serverVersion; + } private boolean isPortReused(Set portsUsed, Object newVal, String id) { if (portsUsed.contains(newVal)) { @@ -184,6 +205,9 @@ public class AddDomainPortsDefPanel impl // to store information entered by the user. public void readSettings(Object settings) { wiz = (WizardDescriptor) settings; + // todo : correct this after late change is approved... + //component.includeSip(PlatformValidator.SAILFIN_V1.equals(serverVersion)); + component.includeSip(false); } public void storeSettings(Object settings) { } diff -r 44c8fd88cd59 j2ee.sun.appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/AddDomainWizardIterator.java --- a/j2ee.sun.appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/AddDomainWizardIterator.java Tue Mar 18 16:56:20 2008 -0700 +++ b/j2ee.sun.appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/AddDomainWizardIterator.java Wed Mar 19 12:49:04 2008 -0700 @@ -1,7 +1,7 @@ /* * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. * - * Copyright 1997-2007 Sun Microsystems, Inc. All rights reserved. + * Copyright 1997-2008 Sun Microsystems, Inc. All rights reserved. * * The contents of this file are subject to the terms of either the GNU * General Public License Version 2 only ("GPL") or the Common @@ -105,6 +105,8 @@ public class AddDomainWizardIterator imp final static String HTTP_SSL_PORT = "http_ssl_port"; //NOI18N final static String ORB_MUTUAL_AUTH_PORT = "orb_mutual_auth_port"; //NOI18N final static String ADMIN_JMX_PORT = "admin_jmx_port"; //NOI18N + final static String SIP_PORT = "sip_port"; //NOI18N + final static String SIP_SSL_PORT = "sip_ssl_port"; //NOI18N final static String PROP_ERROR_MESSAGE = "WizardPanel_errorMessage"; // NOI18N final static String TYPE = "type"; //NOI18N final static String PROP_DISPLAY_NAME = "ServInstWizard_displayName"; // NOI18N @@ -145,6 +147,7 @@ public class AddDomainWizardIterator imp public AddDomainWizardIterator(PlatformValidator pv, String serverVersion) { platformPanel.setPlatformValidator(pv, serverVersion); + portsPanel.setPlatformValidator(pv,serverVersion); } /** @@ -423,6 +426,7 @@ public class AddDomainWizardIterator imp this.pword = pword; } + @Override public void run() { Process process = null; // attempt to do the domian/instance create HERE @@ -468,7 +472,11 @@ public class AddDomainWizardIterator imp ":orb.mutualauth.port="+ //NOI18N ((String)wizard.getProperty(ORB_MUTUAL_AUTH_PORT)).trim()+ ":domain.jmxPort="+ //NOI18N - ((String)wizard.getProperty(ADMIN_JMX_PORT)).trim(), + ((String)wizard.getProperty(ADMIN_JMX_PORT)).trim()+ + ":sip.port="+ //NOI18N + ((String)wizard.getProperty(SIP_PORT)).trim()+ + ":sip.ssl.port="+ //NOI18N + ((String)wizard.getProperty(SIP_SSL_PORT)).trim(), domain }; Integer detectedVersion = @@ -600,6 +608,7 @@ public class AddDomainWizardIterator imp passwordField.getAccessibleContext().setAccessibleDescription(NbBundle.getBundle(AdminAuthenticator.class).getString("ACSD_PasswordField")); } + @Override public java.awt.Dimension getPreferredSize() { java.awt.Dimension sup = super.getPreferredSize(); return new java.awt.Dimension( Math.max(sup.width, DEFAULT_WIDTH), Math.max(sup.height, DEFAULT_HEIGHT )); diff -r 44c8fd88cd59 j2ee.sun.appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/Bundle.properties --- a/j2ee.sun.appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/Bundle.properties Tue Mar 18 16:56:20 2008 -0700 +++ b/j2ee.sun.appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/Bundle.properties Wed Mar 19 12:49:04 2008 -0700 @@ -194,6 +194,8 @@ ERR_HttpSslPort=HTTPS Port has duplicate ERR_HttpSslPort=HTTPS Port has duplicate value ERR_OrbSslPort=ORB SSL Port has duplicate value ERR_OrbMutualAutPort=ORB MutualAuth Port has duplicate value +ERR_SipPort=SIP Port has duplicate value +ERR_SipSslPort=SIP SSL Port has duplicate value MNEM_AdminJmxPort= LBL_AdminJmxPort_Mnemonic=A @@ -488,3 +490,5 @@ Msg_Utf8Required=Cannot create a domain Msg_Utf8Required=Cannot create a domain that includes multibyte characters in its name MSG_COULD_NOT_CREATE_INSTANCE=Could not create instance. +LBL_SipPort=SIP Po&rt: +LBL_SipSslPort=SIP SS&L Port: diff -r 44c8fd88cd59 j2ee.sun.appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/CreateServerVisualPanel.form --- a/j2ee.sun.appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/CreateServerVisualPanel.form Tue Mar 18 16:56:20 2008 -0700 +++ b/j2ee.sun.appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/ui/CreateServerVisualPanel.form Wed Mar 19 12:49:04 2008 -0700 @@ -1,6 +1,6 @@ -