diff --git a/base/src/org/compiere/db/CConnection.java b/base/src/org/compiere/db/CConnection.java index 932924f6b8..2fce4ebecd 100644 --- a/base/src/org/compiere/db/CConnection.java +++ b/base/src/org/compiere/db/CConnection.java @@ -195,8 +195,6 @@ public class CConnection implements Serializable, Cloneable /** Application Host */ private String m_apps_host = "MyAppsServer"; - /** Application Port */ - private int m_apps_port = 0; /** Database Type */ private String m_type = ""; @@ -296,44 +294,6 @@ public class CConnection implements Serializable, Cloneable m_okApps = false; } - /** - * Get Apps Port - * @return port - */ - public int getAppsPort () - { - return m_apps_port; - } - - /** - * Set Apps Port - * @param apps_port apps port - */ - public void setAppsPort (int apps_port) - { - m_apps_port = apps_port; - m_okApps = false; - } - - /** - * Set Apps Port - * @param apps_portString appd port as String - */ - public void setAppsPort (String apps_portString) - { - try - { - if (apps_portString == null || apps_portString.length() == 0) - ; - else - setAppsPort (Integer.parseInt (apps_portString)); - } - catch (Exception e) - { - log.severe(e.toString ()); - } - } // setAppsPort - /** * Is Application Server OK * @param tryContactAgain try to contact again @@ -1009,7 +969,6 @@ public class CConnection implements Serializable, Cloneable StringBuffer sb = new StringBuffer ("CConnection["); sb.append ("name=").append (m_name) .append (",AppsHost=").append (m_apps_host) - .append (",AppsPort=").append (m_apps_port) .append (",type=").append (m_type) .append (",DBhost=").append (m_db_host) .append (",DBport=").append (m_db_port) @@ -1035,8 +994,6 @@ public class CConnection implements Serializable, Cloneable { setName (attributes.substring (attributes.indexOf ("name=") + 5, attributes.indexOf (",AppsHost="))); setAppsHost (attributes.substring (attributes.indexOf ("AppsHost=") + 9, attributes.indexOf (",AppsPort="))); - int index = attributes.indexOf("AppsPort="); - setAppsPort (attributes.substring (index + 9, attributes.indexOf (",", index))); // setType (attributes.substring (attributes.indexOf ("type=")+5, attributes.indexOf (",DBhost="))); setDbHost (attributes.substring (attributes.indexOf ("DBhost=") + 7, attributes.indexOf (",DBport="))); @@ -1069,7 +1026,6 @@ public class CConnection implements Serializable, Cloneable { CConnection cc = (CConnection)o; if (cc.getAppsHost().equals (m_apps_host) - && cc.getAppsPort() == m_apps_port && cc.getDbHost().equals (m_db_host) && cc.getDbPort() == m_db_port && cc.getDbName().equals(m_db_name) diff --git a/base/src/org/compiere/db/CConnectionDialog.java b/base/src/org/compiere/db/CConnectionDialog.java index ca09be8701..4bf1ffc0af 100644 --- a/base/src/org/compiere/db/CConnectionDialog.java +++ b/base/src/org/compiere/db/CConnectionDialog.java @@ -101,13 +101,10 @@ public class CConnectionDialog extends CDialog implements ActionListener /** Default HTTP Port */ public static final String APPS_PORT_HTTP = "80"; - /** Default RMI Port */ - public static final String APPS_PORT_JNP = "1099"; /** Connection */ private CConnection m_cc = null; private CConnection m_ccResult = null; private boolean m_updating = false; - private boolean m_saved = false; /** Logger */ private static CLogger log = CLogger.getCLogger (CConnectionDialog.class); @@ -139,8 +136,6 @@ public class CConnectionDialog extends CDialog implements ActionListener private CCheckBox cbBequeath = new CCheckBox(); private CLabel appsHostLabel = new CLabel(); private CTextField appsHostField = new CTextField(); - private CLabel appsPortLabel = new CLabel(); - private CTextField appsPortField = new CTextField(); private CButton bTestApps = new CButton(); //private CCheckBox cbOverwrite = new CCheckBox(); private CLabel dbUidLabel = new CLabel(); @@ -181,8 +176,6 @@ public class CConnectionDialog extends CDialog implements ActionListener cbBequeath.setText(res.getString("BequeathConnection")); appsHostLabel.setText(res.getString("AppsHost")); appsHostField.setColumns(30); - appsPortLabel.setText(res.getString("AppsPort")); - appsPortField.setColumns(10); bTestApps.setText(res.getString("TestApps")); bTestApps.setHorizontalAlignment(JLabel.LEFT); //cbOverwrite.setText(res.getString("Overwrite")); @@ -203,10 +196,6 @@ public class CConnectionDialog extends CDialog implements ActionListener centerPanel.add(appsHostField, new GridBagConstraints(1, 1, 2, 1, 0.0, 0.0 ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 12), 0, 0)); - centerPanel.add(appsPortLabel, new GridBagConstraints(0, 2, 1, 1, 0.0, 0.0 - ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(0, 12, 5, 5), 0, 0)); - centerPanel.add(appsPortField, new GridBagConstraints(1, 2, 1, 1, 0.0, 0.0 - ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(0, 0, 0, 0), 0, 0)); // centerPanel.add(bTestApps, new GridBagConstraints(1, 3, 1, 1, 0.0, 0.0 ,GridBagConstraints.SOUTHWEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 12, 0), 0, 0)); @@ -252,7 +241,6 @@ public class CConnectionDialog extends CDialog implements ActionListener // nameField.addActionListener(this); appsHostField.addActionListener(this); - appsPortField.addActionListener(this); //cbOverwrite.addActionListener(this); bTestApps.addActionListener(this); // @@ -273,8 +261,6 @@ public class CConnectionDialog extends CDialog implements ActionListener { appsHostLabel.setVisible(false); appsHostField.setVisible(false); - appsPortLabel.setVisible(false); - appsPortField.setVisible(false); bTestApps.setVisible(false); } else // Client @@ -393,8 +379,6 @@ public class CConnectionDialog extends CDialog implements ActionListener //hengsin: avoid unnecessary requery of application server status if (!appsHostField.getText().equals(m_cc.getAppsHost())) m_cc.setAppsHost(appsHostField.getText()); - if (!appsPortField.getText().equals(Integer.toString(m_cc.getAppsPort()))) - m_cc.setAppsPort(appsPortField.getText()); } else m_cc.setAppsHost("localhost"); @@ -419,7 +403,6 @@ public class CConnectionDialog extends CDialog implements ActionListener m_updating = true; nameField.setText(m_cc.getName()); appsHostField.setText(m_cc.getAppsHost()); - appsPortField.setText(String.valueOf(m_cc.getAppsPort())); // bTestApps.setIcon(getStatusIcon(m_cc.isAppsServerOK(false))); // bTestApps.setToolTipText(m_cc.getRmiUri()); diff --git a/base/src/org/compiere/process/ReplicationLocal.java b/base/src/org/compiere/process/ReplicationLocal.java index d48d1f6d06..354ff03e28 100644 --- a/base/src/org/compiere/process/ReplicationLocal.java +++ b/base/src/org/compiere/process/ReplicationLocal.java @@ -137,7 +137,6 @@ public class ReplicationLocal extends SvrProcess int AppsPort = m_replication.getHostPort(); CConnection connection = new CConnection(AppsHost); - connection.setAppsPort(AppsPort); log.info (AppsHost + ":" + AppsPort); try { diff --git a/base/src/org/compiere/util/CLogMgt.java b/base/src/org/compiere/util/CLogMgt.java index a1988acce5..93bd91c5aa 100644 --- a/base/src/org/compiere/util/CLogMgt.java +++ b/base/src/org/compiere/util/CLogMgt.java @@ -624,9 +624,7 @@ public class CLogMgt StringBuffer sb = new StringBuffer(); CConnection cc = CConnection.get(); // Host - sb.append(cc.getAppsHost()).append(" : ") - .append(cc.getAppsPort()) - .append(" ("); + sb.append(cc.getAppsHost()).append(" ("); // Server if (cc.isAppsServerOK(false)) diff --git a/plugins/pluginUtils/src/org/adempiere/plugin/utils/AdempiereActivator.java b/plugins/pluginUtils/src/org/adempiere/plugin/utils/AdempiereActivator.java index 33cacb20a4..9396d622df 100644 --- a/plugins/pluginUtils/src/org/adempiere/plugin/utils/AdempiereActivator.java +++ b/plugins/pluginUtils/src/org/adempiere/plugin/utils/AdempiereActivator.java @@ -8,7 +8,6 @@ import org.adempiere.base.IDictionaryService; import org.adempiere.base.Service; import org.compiere.model.Query; import org.compiere.model.X_AD_Package_Imp; -import org.compiere.model.X_AD_Package_Imp_Inst; import org.compiere.util.Env; import org.compiere.util.Trx; import org.osgi.framework.BundleActivator;