[rhq] Branch 'rhq-on-as7' - modules/core modules/enterprise
by Jay Shaughnessy
modules/core/domain/pom.xml | 2 +-
modules/enterprise/server/itests-2/pom.xml | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
New commits:
commit 99518d2194a05ded091b5e8ac1bfe456e180fdfe
Author: Jay Shaughnessy <jshaughn(a)jshaughn.csb>
Date: Mon Nov 26 09:39:14 2012 -0500
We can't use the SecureidentityLoginModule in our tests because
we need to use the values set for rhq.test.ds.*, and the password
will likely not be encrypted. For example, the Jenkins settings.xml
files will not have encrypted DB passwords. Trying IdentityLoginModule
in the hopes that that is same as SecureIdentityLoginModule but
skipping the encryption step.
diff --git a/modules/core/domain/pom.xml b/modules/core/domain/pom.xml
index 71fbdbe..68af11c 100644
--- a/modules/core/domain/pom.xml
+++ b/modules/core/domain/pom.xml
@@ -272,7 +272,7 @@
<!-- FOR RHQ TESTING -->
<security-domain name="RHQDSSecurityDomain" cache-type="default">
<authentication>
- <login-module code="SecureIdentity" flag="required">
+ <login-module code="Identity" flag="required">
<module-option name="username" value="${rhq.test.ds.user-name}"/>
<module-option name="password" value="${rhq.test.ds.password}"/>
</login-module>
diff --git a/modules/enterprise/server/itests-2/pom.xml b/modules/enterprise/server/itests-2/pom.xml
index a86cfd3..6ff8fb5 100644
--- a/modules/enterprise/server/itests-2/pom.xml
+++ b/modules/enterprise/server/itests-2/pom.xml
@@ -250,7 +250,7 @@
<!-- FOR RHQ TESTING -->
<security-domain name="RHQDSSecurityDomain" cache-type="default">
<authentication>
- <login-module code="SecureIdentity" flag="required">
+ <login-module code="Identity" flag="required">
<module-option name="username" value="${rhq.test.ds.user-name}"/>
<module-option name="password" value="${rhq.test.ds.password}"/>
</login-module>
11 years, 5 months
[rhq] modules/integration-tests modules/test-utils
by lkrejci
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java | 1
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/PortScout.java | 69 ----------
modules/integration-tests/jndi-access/jndi-access-test/pom.xml | 4
modules/integration-tests/jndi-access/jndi-access-test/src/test/java/org/rhq/jndi/test/JndiAccessTest.java | 25 ++-
modules/integration-tests/jndi-access/jndi-access-test/src/test/resources/log4j.xml | 12 +
modules/test-utils/src/main/java/org/rhq/test/PortScout.java | 69 ++++++++++
6 files changed, 99 insertions(+), 81 deletions(-)
New commits:
commit 0a57f672d2993dd95244f5d38d0c95ddb876caf1
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Mon Nov 26 12:18:17 2012 +0100
Randomizing ports in the JNDI access test. Maybe this will help the test
failures in the integration-tests Jenkins job.
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java
index 02be42c..d5a7e45 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java
@@ -43,6 +43,7 @@ import org.unitils.thirdparty.org.apache.commons.io.FileUtils;
import org.rhq.core.util.file.FileUtil;
import org.rhq.core.util.stream.StreamUtil;
import org.rhq.plugins.apache.util.HttpdAddressUtility.Address;
+import org.rhq.test.PortScout;
import org.rhq.test.TokenReplacingProperties;
import org.rhq.test.TokenReplacingReader;
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/PortScout.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/PortScout.java
deleted file mode 100644
index 3a33f09..0000000
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/PortScout.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * RHQ Management Platform
- * Copyright 2012, Red Hat Middleware LLC, and individual contributors
- * as indicated by the @author tags. See the copyright.txt file in the
- * distribution for a full listing of individual contributors.
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- */
-
-package org.rhq.plugins.apache.util;
-
-import java.io.Closeable;
-import java.io.IOException;
-import java.net.ServerSocket;
-import java.net.SocketAddress;
-import java.util.HashSet;
-import java.util.Set;
-
-/**
- * Tries to find a series of free ports.
- *
- * The ports remain open until the {@link #close()} method is called.
- *
- * @author Lukas Krejci
- */
-public class PortScout implements Closeable {
-
- private Set<ServerSocket> activeSockets = new HashSet<ServerSocket>();
-
- public int getNextFreePort() throws IOException {
- ServerSocket s = new ServerSocket(0);
- activeSockets.add(s);
- return s.getLocalPort();
- }
-
- @Override
- public void close() throws IOException {
- String message = null;
- for(ServerSocket s : activeSockets) {
- SocketAddress addr = s.getLocalSocketAddress();
- try {
- s.close();
- } catch (IOException e) {
- if (message == null) {
- message = "The following test sockets failed to close while looking for free ports:\n";
- }
-
- message += addr.toString() + ": " + e.getMessage() + ",\n";
- }
- }
-
- if (message != null) {
- message = message.substring(0, message.length() - 2);
-
- throw new IOException(message);
- }
- }
-}
diff --git a/modules/integration-tests/jndi-access/jndi-access-test/pom.xml b/modules/integration-tests/jndi-access/jndi-access-test/pom.xml
index aed285e..36da98a 100644
--- a/modules/integration-tests/jndi-access/jndi-access-test/pom.xml
+++ b/modules/integration-tests/jndi-access/jndi-access-test/pom.xml
@@ -18,8 +18,6 @@
<rhq.server.datasource>java:/RHQDS</rhq.server.datasource>
<rhq.server.ds-mapping>PostgreSQL</rhq.server.ds-mapping>
<jboss-embeddable-ejb3.version>1.0.0.Alpha9</jboss-embeddable-ejb3.version>
- <jnp.port>54987</jnp.port>
- <jnp.rmiPort>54988</jnp.rmiPort>
</properties>
<dependencies>
@@ -323,8 +321,6 @@
<hibernate.dialect>${rhq.test.ds.hibernate-dialect}</hibernate.dialect>
<clean.db>${clean.db}</clean.db>
<test.server.jar.path>${settings.localRepository}/org/rhq/jndi-access-remote-server/${project.version}/jndi-access-remote-server-${project.version}.jar</test.server.jar.path>
- <jnp.port>${jnp.port}</jnp.port>
- <jnp.rmiPort>${jnp.rmiPort}</jnp.rmiPort>
</systemPropertyVariables>
<argLine>${jacoco.unit-test.args} -Djava.security.manager -Djava.security.policy==${basedir}/target/test-classes/security.policy</argLine>
<additionalClasspathElements>
diff --git a/modules/integration-tests/jndi-access/jndi-access-test/src/test/java/org/rhq/jndi/test/JndiAccessTest.java b/modules/integration-tests/jndi-access/jndi-access-test/src/test/java/org/rhq/jndi/test/JndiAccessTest.java
index e161230..abfd376 100644
--- a/modules/integration-tests/jndi-access/jndi-access-test/src/test/java/org/rhq/jndi/test/JndiAccessTest.java
+++ b/modules/integration-tests/jndi-access/jndi-access-test/src/test/java/org/rhq/jndi/test/JndiAccessTest.java
@@ -48,6 +48,7 @@ import org.rhq.enterprise.client.LocalClient;
import org.rhq.enterprise.server.test.AbstractEJB3Test;
import org.rhq.enterprise.server.util.LookupUtil;
import org.rhq.jndi.AllowRhqServerInternalsAccessPermission;
+import org.rhq.test.PortScout;
/**
*
@@ -57,14 +58,28 @@ import org.rhq.jndi.AllowRhqServerInternalsAccessPermission;
@Test
public class JndiAccessTest extends AbstractEJB3Test {
private static final Log JNP_SERVER_LOG = LogFactory.getLog("Test JNP Server");
+ private static final Log LOG = LogFactory.getLog(JndiAccessTest.class);
private Process testServerProcess;
private Thread testServerStdErrReader;
private Thread testServerStdOutReader;
+ int jnpPort;
+
@BeforeClass
- @Parameters({"test.server.jar.path", "jnp.port", "jnp.rmiPort"})
- public void startTestJnpServer(String testServerJar, int jnpPort, int rmiPort) throws Exception {
+ @Parameters({ "test.server.jar.path" })
+ public void startTestJnpServer(String testServerJar) throws Exception {
+ int rmiPort = 0;
+ PortScout scout = new PortScout();
+
+ try {
+ jnpPort = scout.getNextFreePort();
+ rmiPort = scout.getNextFreePort();
+ } finally {
+ scout.close();
+ }
+
+ LOG.info("Starting the remote JNP server on jnpPort=" + jnpPort + ", rmiPort=" + rmiPort);
ProcessBuilder bld = new ProcessBuilder("java", "-Djnp.port=" + jnpPort, "-Djnp.rmiPort=" + rmiPort, "-jar", testServerJar);
testServerProcess = bld.start();
@@ -124,8 +139,7 @@ public class JndiAccessTest extends AbstractEJB3Test {
testServerStdOutReader.join();
}
- @Parameters("jnp.port")
- public void testRemoteConnectionWorkingFromJava(int jnpPort) throws Exception {
+ public void testRemoteConnectionWorkingFromJava() throws Exception {
Properties env = new Properties();
env.put("java.naming.factory.initial", "org.jboss.naming.NamingContextFactory");
env.put("java.naming.provider.url", "jnp://localhost:" + jnpPort);
@@ -153,8 +167,7 @@ public class JndiAccessTest extends AbstractEJB3Test {
}
}
- @Parameters("jnp.port")
- public void testRemoteJNDILookupWorksFromScripts(int jnpPort) throws Exception {
+ public void testRemoteJNDILookupWorksFromScripts() throws Exception {
Subject overlord = LookupUtil.getSubjectManager().getOverlord();
ScriptEngine engine = getEngine(overlord);
diff --git a/modules/integration-tests/jndi-access/jndi-access-test/src/test/resources/log4j.xml b/modules/integration-tests/jndi-access/jndi-access-test/src/test/resources/log4j.xml
index ec09ed7..fd832e0 100644
--- a/modules/integration-tests/jndi-access/jndi-access-test/src/test/resources/log4j.xml
+++ b/modules/integration-tests/jndi-access/jndi-access-test/src/test/resources/log4j.xml
@@ -19,7 +19,7 @@
<appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
<errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
<param name="Target" value="System.out"/>
- <param name="Threshold" value="WARN"/>
+ <param name="Threshold" value="INFO"/>
<layout class="org.apache.log4j.PatternLayout">
<!-- The default pattern: Date Priority [Category] Messagen -->
@@ -32,7 +32,7 @@
<appender name="FILE" class="org.apache.log4j.RollingFileAppender">
<param name="File" value="target/server-jar-test.log"/>
- <param name="Threshold" value="WARN"/>
+ <param name="Threshold" value="DEBUG"/>
<param name="Append" value="false"/>
<layout class="org.apache.log4j.PatternLayout">
@@ -48,6 +48,14 @@
<priority value="DEBUG"/>
</category>
+ <category name="org.jboss">
+ <priority value="WARN"/>
+ </category>
+
+ <category name="org.hibernate">
+ <priority value="WARN"/>
+ </category>
+
<!-- Hibernate logs WARNINGS frequent from this class, in test envs. -->
<category name="org.hibernate.hql.ast.QueryTranslatorImpl">
<priority value="ERROR"/>
diff --git a/modules/test-utils/src/main/java/org/rhq/test/PortScout.java b/modules/test-utils/src/main/java/org/rhq/test/PortScout.java
new file mode 100644
index 0000000..0c54cbd
--- /dev/null
+++ b/modules/test-utils/src/main/java/org/rhq/test/PortScout.java
@@ -0,0 +1,69 @@
+/*
+ * RHQ Management Platform
+ * Copyright 2012, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
+package org.rhq.test;
+
+import java.io.Closeable;
+import java.io.IOException;
+import java.net.ServerSocket;
+import java.net.SocketAddress;
+import java.util.HashSet;
+import java.util.Set;
+
+/**
+ * Tries to find a series of free ports.
+ *
+ * The ports remain open until the {@link #close()} method is called.
+ *
+ * @author Lukas Krejci
+ */
+public class PortScout implements Closeable {
+
+ private Set<ServerSocket> activeSockets = new HashSet<ServerSocket>();
+
+ public int getNextFreePort() throws IOException {
+ ServerSocket s = new ServerSocket(0);
+ activeSockets.add(s);
+ return s.getLocalPort();
+ }
+
+ @Override
+ public void close() throws IOException {
+ String message = null;
+ for(ServerSocket s : activeSockets) {
+ SocketAddress addr = s.getLocalSocketAddress();
+ try {
+ s.close();
+ } catch (IOException e) {
+ if (message == null) {
+ message = "The following test sockets failed to close while looking for free ports:\n";
+ }
+
+ message += addr.toString() + ": " + e.getMessage() + ",\n";
+ }
+ }
+
+ if (message != null) {
+ message = message.substring(0, message.length() - 2);
+
+ throw new IOException(message);
+ }
+ }
+}
11 years, 5 months
[rhq] modules/plugins
by Heiko W. Rupp
modules/plugins/jboss-as-5/src/main/resources/META-INF/rhq-plugin.xml | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
New commits:
commit e6be4a4ef2a098c61e0629593a64d08a9e575a10
Author: Heiko W. Rupp <hwr(a)redhat.com>
Date: Mon Nov 26 11:46:54 2012 +0100
BZ 880136 - disable the Connections available trait by default.
(cherry-picked from c38b8eb, BZ 859417)
diff --git a/modules/plugins/jboss-as-5/src/main/resources/META-INF/rhq-plugin.xml b/modules/plugins/jboss-as-5/src/main/resources/META-INF/rhq-plugin.xml
index 92370cb..2b14f5b 100644
--- a/modules/plugins/jboss-as-5/src/main/resources/META-INF/rhq-plugin.xml
+++ b/modules/plugins/jboss-as-5/src/main/resources/META-INF/rhq-plugin.xml
@@ -9,9 +9,9 @@
<!ENTITY datasourceAndConnectionFactoryMetrics '
<!-- Traits -->
- <metric property="custom.connectionAvailable" displayType="summary" displayName="Connection Available?"
- dataType="trait" category="availability" defaultInterval="900000"
- description="could a connection to the underlying data provider be obtained?"/>
+ <metric property="custom.connectionAvailable" displayType="detail" displayName="Connection Available?"
+ dataType="trait" category="availability" defaultInterval="900000" defaultOn="false"
+ description="could a connection to the underlying data provider be obtained? Please see the documentation before enabling this metric"/>
'>
<!ENTITY datasourceAndConnectionFactoryOperations '
11 years, 5 months
[rhq] Branch 'release/jon3.1.x' - modules/plugins
by Heiko W. Rupp
modules/plugins/jboss-as-5/src/main/resources/META-INF/rhq-plugin.xml | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
New commits:
commit c38b8eb1fd584a8412d6c7d3213d1c3a036c1d7d
Author: Heiko W. Rupp <hwr(a)pilhuhn.de>
Date: Mon Nov 26 11:41:38 2012 +0100
BZ 859417 - disable the Connections available trait by default.
diff --git a/modules/plugins/jboss-as-5/src/main/resources/META-INF/rhq-plugin.xml b/modules/plugins/jboss-as-5/src/main/resources/META-INF/rhq-plugin.xml
index 43216bd..654261b 100644
--- a/modules/plugins/jboss-as-5/src/main/resources/META-INF/rhq-plugin.xml
+++ b/modules/plugins/jboss-as-5/src/main/resources/META-INF/rhq-plugin.xml
@@ -9,9 +9,9 @@
<!ENTITY datasourceAndConnectionFactoryMetrics '
<!-- Traits -->
- <metric property="custom.connectionAvailable" displayType="summary" displayName="Connection Available?"
- dataType="trait" category="availability" defaultInterval="900000"
- description="could a connection to the underlying data provider be obtained?"/>
+ <metric property="custom.connectionAvailable" displayType="detail" displayName="Connection Available?"
+ dataType="trait" category="availability" defaultInterval="900000" defaultOn="false"
+ description="could a connection to the underlying data provider be obtained? Please see the documentation before enabling this metric"/>
'>
<!ENTITY datasourceAndConnectionFactoryOperations '
11 years, 5 months
[rhq] modules/plugins
by Thomas Segismont
modules/plugins/platform/src/main/java/org/rhq/plugins/platform/ProcessComponent.java | 8 ++++++++
1 file changed, 8 insertions(+)
New commits:
commit 5c4217effa33ffd892f55005b09f7ed7201125f6
Author: Thomas SEGISMONT <tsegismo(a)redhat.com>
Date: Mon Nov 26 10:55:04 2012 +0100
[BZ-879583] Monitoring : process availability gives wrong status (SIGAR)
ProcessInfo instance needs to be refreshed on every avail check
diff --git a/modules/plugins/platform/src/main/java/org/rhq/plugins/platform/ProcessComponent.java b/modules/plugins/platform/src/main/java/org/rhq/plugins/platform/ProcessComponent.java
index 8281f70..9e9b95f 100644
--- a/modules/plugins/platform/src/main/java/org/rhq/plugins/platform/ProcessComponent.java
+++ b/modules/plugins/platform/src/main/java/org/rhq/plugins/platform/ProcessComponent.java
@@ -67,6 +67,7 @@ public class ProcessComponent implements ResourceComponent, MeasurementFacet {
private String piql;
private boolean fullProcessTree;
+ @Override
public void start(ResourceContext resourceContext) throws InvalidPluginConfigurationException, Exception {
this.resourceContext = resourceContext;
@@ -89,9 +90,11 @@ public class ProcessComponent implements ResourceComponent, MeasurementFacet {
}
}
+ @Override
public void stop() {
}
+ @Override
public AvailabilityType getAvailability() {
try {
return getProcess().isRunning() ? AvailabilityType.UP : AvailabilityType.DOWN;
@@ -106,6 +109,10 @@ public class ProcessComponent implements ResourceComponent, MeasurementFacet {
private ProcessInfo getProcess() throws Exception {
if (this.process == null || !this.process.isRunning()) {
this.process = getProcessForConfiguration();
+ } else {
+ // Refresh previously existing ProcessInfo as it may hold stale data.
+ // SIGAR objects do not get updated when, for example, a process goes down.
+ process.refresh();
}
return this.process;
}
@@ -168,6 +175,7 @@ public class ProcessComponent implements ResourceComponent, MeasurementFacet {
return processInfo;
}
+ @Override
public void getValues(MeasurementReport report, Set<MeasurementScheduleRequest> metrics) {
if (this.process != null) {
this.process.refresh();
11 years, 5 months
[rhq] Branch 'mtho11/d3-charts2' - 21 commits - .classpath etc/greasemonkey modules/core modules/enterprise modules/helpers modules/integration-tests modules/plugins modules/test-utils pom.xml
by mike thompson
.classpath | 5
etc/greasemonkey/RHQ_login_monkey.user.js | 31 ++
modules/core/domain/src/main/java/org/rhq/core/domain/cloud/Server.java | 3
modules/core/domain/src/test/java/org/rhq/core/domain/test/AbstractEJB3Test.java | 9
modules/core/plugin-container/src/main/java/org/rhq/core/pc/inventory/InventoryManager.java | 7
modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/alert/definitions/CliNotificationSenderForm.java | 42 ++-
modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/dashboard/portlets/resource/ResourceMetricsPortlet.java | 12
modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/inventory/resource/detail/monitoring/D3GraphListView.java | 31 +-
modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/inventory/resource/detail/monitoring/table/MeasurementTableView.java | 14 -
modules/enterprise/remoting/client-api/src/test/java/org/rhq/enterprise/clienapi/RhqDownloadsScriptSourceProviderTest.java | 3
modules/enterprise/scripting/javascript/pom.xml | 6
modules/enterprise/scripting/python/pom.xml | 6
modules/enterprise/server/jar/pom.xml | 6
modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/cloud/StatusManagerBean.java | 1
modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerBean.java | 19 -
modules/helpers/pom.xml | 10
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/augeas/AugeasReferenceLeakingTest.java | 7
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/setup/ApacheTestSetup.java | 52 +++
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java | 20 +
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq1_3_x/UpgradeNestedConfigurationFromRHQ1_3Test.java | 8
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq1_3_x/UpgradeSimpleConfigurationFromRHQ1_3Test.java | 11
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_0/UpgradeNestedConfigurationFromRHQ3_0_0Test.java | 20 -
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_0/UpgradeSimpleConfigurationFromRHQ3_0_0Test.java | 20 -
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_1/UpgradeNestedConfigurationFromRHQ3_0_1Test.java | 22 -
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_1/UpgradeSimpleConfigurationFromRHQ3_0_1Test.java | 22 -
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_2/UpgradeNestedConfigurationFromRHQ3_0_2Test.java | 10
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_2/UpgradeSimpleConfigurationFromRHQ3_0_2Test.java | 10
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java | 137 +++++++---
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheExecutionUtil.java | 8
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/PortScout.java | 69 +++++
modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml | 4
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/includes/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/mess/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/nested/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/simple/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/includes/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/mess/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/nested/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/simple/inventory-without-snmp.xml | 2
modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java | 22 +
modules/plugins/jboss-as-5/src/test/java/org/rhq/plugins/jbossas5/itest/ApplicationServerComponentTest.java | 6
modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/GenericJBossAS7PluginTest.java | 8
modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/nonpc/AbstractIntegrationTest.java | 2
modules/test-utils/pom.xml | 11
pom.xml | 51 +--
45 files changed, 526 insertions(+), 215 deletions(-)
New commits:
commit d885d28fd8b658ea4cacc0abd2812510504689fe
Merge: f013199 844f016
Author: Mike Thompson <mithomps(a)redhat.com>
Date: Sun Nov 25 17:33:40 2012 -0800
Merge branch 'master' into d3-charts2
commit f013199a26910a0a264171a661f707924356c6e9
Author: Mike Thompson <mithomps(a)redhat.com>
Date: Sun Nov 25 16:08:23 2012 -0800
Fixing date selection for graphing on dialog boxes.
diff --git a/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/dashboard/portlets/resource/ResourceMetricsPortlet.java b/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/dashboard/portlets/resource/ResourceMetricsPortlet.java
index 368e6a5..9066002 100644
--- a/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/dashboard/portlets/resource/ResourceMetricsPortlet.java
+++ b/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/dashboard/portlets/resource/ResourceMetricsPortlet.java
@@ -23,7 +23,6 @@ import java.util.EnumSet;
import java.util.HashMap;
import java.util.List;
import java.util.Set;
-import java.util.TreeSet;
import com.google.gwt.user.client.rpc.AsyncCallback;
import com.smartgwt.client.types.Alignment;
@@ -278,8 +277,17 @@ public class ResourceMetricsPortlet extends GroupMetricsPortlet {
ChartViewWindow window = new ChartViewWindow(
recentMeasurementsContent
.extendLocatorId("ChartWindow"), title);
- D3GraphListView graphView = D3GraphListView.createSingleGraph(extendLocatorId("D3Graphs"),
+ final D3GraphListView graphView = D3GraphListView.createSingleGraph(extendLocatorId("D3Graphs"),
resourceComposite.getResource(), md.getId());
+ graphView.addSetButtonClickHandler(new ClickHandler()
+ {
+ @Override
+ public void onClick(ClickEvent event)
+ {
+ graphView.redrawGraphs();
+
+ }
+ });
window.addItem(graphView);
window.show();
draw();
diff --git a/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/inventory/resource/detail/monitoring/D3GraphListView.java b/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/inventory/resource/detail/monitoring/D3GraphListView.java
index 5e6bd96..a0ce76e 100644
--- a/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/inventory/resource/detail/monitoring/D3GraphListView.java
+++ b/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/inventory/resource/detail/monitoring/D3GraphListView.java
@@ -29,6 +29,7 @@ import java.util.TreeSet;
import com.google.gwt.user.client.rpc.AsyncCallback;
import com.smartgwt.client.types.Overflow;
import com.smartgwt.client.widgets.Label;
+import com.smartgwt.client.widgets.events.ClickEvent;
import com.smartgwt.client.widgets.form.fields.events.ClickHandler;
import org.rhq.core.domain.measurement.DataType;
@@ -47,7 +48,7 @@ import org.rhq.enterprise.gui.coregui.client.util.selenium.LocatableVLayout;
/**
* Build the View that shows the individual graph views for multi-graph
* views if just a resource is provided and single graph view if resource
- * and definitionId are provided.
+ * and measurement definitionId are provided.
*
* @author Mike Thompson
*/
@@ -69,34 +70,39 @@ public class D3GraphListView extends LocatableVLayout {
}
public static D3GraphListView createSingleGraph(String locatorId, Resource resource, Integer measurementId) {
- TreeSet<Integer> defintionIds = new TreeSet<Integer>();
- defintionIds.add(measurementId);
- return new D3GraphListView(locatorId, resource, defintionIds);
+ TreeSet<Integer> definitionIds = new TreeSet<Integer>();
+ definitionIds.add(measurementId);
+ return new D3GraphListView(locatorId, resource, definitionIds);
}
private D3GraphListView(String locatorId, Resource resource, Set<Integer> definitionIds) {
super(locatorId);
- measurementRangeEditor = new UserPreferencesMeasurementRangeEditor(this.getLocatorId());
this.resource = resource;
- setOverflow(Overflow.AUTO);
+ commonConstructorSettings();
this.definitionIds = definitionIds;
}
private D3GraphListView(String locatorId, Resource resource) {
super(locatorId);
- measurementRangeEditor = new UserPreferencesMeasurementRangeEditor(this.getLocatorId());
this.resource = resource;
- setOverflow(Overflow.AUTO);
+ commonConstructorSettings();
useSummaryData = true;
}
+ private void commonConstructorSettings(){
+ measurementRangeEditor = new UserPreferencesMeasurementRangeEditor(this.getLocatorId());
+ setOverflow(Overflow.AUTO);
+ }
+
public void addSetButtonClickHandler(ClickHandler clickHandler) {
+ Log.debug("measurementRangeEditor "+measurementRangeEditor);
measurementRangeEditor.getSetButton().addClickHandler(clickHandler);
}
@Override
protected void onDraw() {
super.onDraw();
+ //Log.debug(" *** Invoking onDraw()");
destroyMembers();
@@ -107,10 +113,15 @@ public class D3GraphListView extends LocatableVLayout {
}
}
+
+ public void redrawGraphs(){
+ this.onDraw();
+ }
+
/**
* Build whatever graph metrics (MeasurementDefinitions) are defined for the resource.
*/
- private void buildGraphs() {
+ public void buildGraphs() {
List<Long> startEndList = measurementRangeEditor.getBeginEndTimes();
final long startTime = startEndList.get(0);
final long endTime = startEndList.get(1);
@@ -206,7 +217,7 @@ public class D3GraphListView extends LocatableVLayout {
if (null != selectedDefinitionId) {
// single graph case
if (measurementId == selectedDefinitionId) {
- buildIndividualGraph(measurementDefinition, measurement, 250);
+ buildIndividualGraph(measurementDefinition, measurement, 160);
}
} else {
// multiple graph case
diff --git a/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/inventory/resource/detail/monitoring/table/MeasurementTableView.java b/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/inventory/resource/detail/monitoring/table/MeasurementTableView.java
index e4a722d..5c20886 100644
--- a/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/inventory/resource/detail/monitoring/table/MeasurementTableView.java
+++ b/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/inventory/resource/detail/monitoring/table/MeasurementTableView.java
@@ -31,6 +31,8 @@ import com.google.gwt.user.client.rpc.AsyncCallback;
import com.smartgwt.client.types.SelectionStyle;
import com.smartgwt.client.widgets.events.CloseClickEvent;
import com.smartgwt.client.widgets.events.CloseClickHandler;
+import com.smartgwt.client.widgets.form.fields.events.ClickEvent;
+import com.smartgwt.client.widgets.form.fields.events.ClickHandler;
import com.smartgwt.client.widgets.grid.ListGridField;
import com.smartgwt.client.widgets.grid.ListGridRecord;
@@ -236,8 +238,16 @@ public class MeasurementTableView extends Table<MeasurementTableDataSource> {
final ResourceComposite resourceComposite = result.get(0);
ChartViewWindow window = new ChartViewWindow(extendLocatorId("ChartWindow"), "");
- window.addItem(D3GraphListView.createMultipleGraphs(extendLocatorId("D3Graphs"),
- resourceComposite.getResource(), definitionIds));
+ final D3GraphListView graphListView = D3GraphListView.createMultipleGraphs(extendLocatorId("D3Graphs"), resourceComposite.getResource(), definitionIds);
+ graphListView.addSetButtonClickHandler(new ClickHandler()
+ {
+ @Override
+ public void onClick(ClickEvent event)
+ {
+ graphListView.redrawGraphs();
+ }
+ });
+ window.addItem(graphListView);
window.show();
refreshTableInfo();
commit 844f016ee8b2608496d063c94f38461e997bcabe
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Fri Nov 23 17:18:35 2012 +0100
[BZ 879655] - Properly deactivate the resource instead of just calling the
component's stop() method when forcing reactivation of a started component.
This will ensure the PC can't enter an inconsistent state in the case the
stop() method fails.
diff --git a/modules/core/plugin-container/src/main/java/org/rhq/core/pc/inventory/InventoryManager.java b/modules/core/plugin-container/src/main/java/org/rhq/core/pc/inventory/InventoryManager.java
index b3f7fa9..473b0d0 100644
--- a/modules/core/plugin-container/src/main/java/org/rhq/core/pc/inventory/InventoryManager.java
+++ b/modules/core/plugin-container/src/main/java/org/rhq/core/pc/inventory/InventoryManager.java
@@ -1614,7 +1614,10 @@ public class InventoryManager extends AgentService implements ContainerService,
if (forceReinitialization) {
switch (state) {
case STARTED:
- component.stop();
+ if (log.isDebugEnabled()) {
+ log.debug("Forcing re-initialization of an already started resource: " + resource);
+ }
+ deactivateResource(resource);
break;
case STARTING:
log.warn("Could not force initialization of component for resource [" + resource.getId()
@@ -2037,7 +2040,7 @@ public class InventoryManager extends AgentService implements ContainerService,
log.debug("Successfully deactivated resource with id [" + resource.getId() + "].");
}
} catch (Throwable t) {
- log.warn("Plugin Error: Failed to stop component for [" + resource + "].");
+ log.warn("Plugin Error: Failed to stop component for [" + resource + "].", t);
}
container.setResourceComponentState(ResourceComponentState.STOPPED);
commit 16f04c50bd9cffaed77c73338d5f31ffb0f9c451
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Fri Nov 23 17:12:43 2012 +0100
Improvements in Apache integration tests:
* improved logging
* randomization of used ports
* *WithoutSNMP tests don't use SNMP even after upgrade (makes the behavior more understandable)
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
index 8f8cdb6..aebea53 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
@@ -102,9 +102,6 @@ public class UpgradeTestBase extends PluginContainerTest {
boolean testFailed = false;
try {
- LOG.debug("---------------------------------------------------------- Starting the upgrade test for: "
- + testId);
-
String[] configFiles = Arrays.copyOf(testConfiguration.apacheConfigurationFiles, testConfiguration.apacheConfigurationFiles.length + 1);
configFiles[testConfiguration.apacheConfigurationFiles.length] = "/snmpd.conf";
@@ -114,7 +111,11 @@ public class UpgradeTestBase extends PluginContainerTest {
.withServerRoot(testConfiguration.serverRoot).withExePath(testConfiguration.binPath);
testConfiguration.beforeTestSetup(setup);
-
+
+ LOG.debug("---------------------------------------------------------- Starting the upgrade test for: "
+ + testId);
+ LOG.debug("Deployment configuration: " + setup.getDeploymentConfig());
+
setup.setup();
testConfiguration.beforePluginContainerStart(setup);
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java
index bc80898..02be42c 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java
@@ -19,7 +19,6 @@
package org.rhq.plugins.apache.util;
-import java.io.BufferedReader;
import java.io.File;
import java.io.FileReader;
import java.io.FileWriter;
@@ -33,7 +32,6 @@ import java.net.UnknownHostException;
import java.util.ArrayList;
import java.util.Collection;
import java.util.HashMap;
-import java.util.Iterator;
import java.util.List;
import java.util.ListIterator;
import java.util.Map;
@@ -198,10 +196,40 @@ public class ApacheDeploymentUtil {
tokenReplacements.put(LISTEN4, address4 == null ? "" : address4.toString(false, false));
}
}
+
+ @Override
+ public String toString() {
+ StringBuilder bld = new StringBuilder("VHost[");
+ if (address1 != null) {
+ bld.append(address1.toString()).append(", ");
+ }
+ if (address2 != null) {
+ bld.append(address2.toString()).append(", ");
+ }
+ if (address3 != null) {
+ bld.append(address3.toString()).append(", ");
+ }
+ if (address4 != null) {
+ bld.append(address4.toString()).append(", ");
+ }
+
+ String serverName = getServerName();
+ if (serverName != null) {
+ bld.append("serverName=").append(serverName).append(", ");
+ }
+
+ if (additionalDirectives != null) {
+ bld.append("with additional directives, ");
+ }
+
+ bld.replace(bld.length() - 2, bld.length(), "]");
+
+ return bld.toString();
+ }
}
public String serverRoot = null;
- public String documentRoot = "hdocs";
+ public String documentRoot = "htdocs";
public String snmpHost = "localhost";
public int snmpPort = 1610;
public final VHost mainServer = new VHost();
@@ -242,48 +270,69 @@ public class ApacheDeploymentUtil {
default: throw new IllegalArgumentException();
}
}
+
+ @Override
+ public String toString() {
+ return new StringBuilder("DeploymentConfig[").append("mainServer=").append(mainServer).append(", vhost1=")
+ .append(vhost1).append(", vhost2=").append(vhost2).append(", vhost3=").append(vhost3)
+ .append(", vhost4=").append(vhost4).append(", serverRoot=").append(serverRoot)
+ .append(", documentRoot=").append(documentRoot).append(", snmpHost=").append(snmpHost)
+ .append(", snmpPort=").append(snmpPort).append("]").toString();
+ }
}
public static void addDefaultVariables(Map<String, String> variables, String prefix) {
InetAddress localhost = determineLocalhost();
- checkOrAddDefault(variables, "localhost", localhost.getHostName());
- checkOrAddDefault(variables, "localhost.ip", localhost.getHostAddress());
- checkOrAddDefault(variables, "unresolvable.host", "unreachable.host.com");
- checkOrAddDefault(variables, "port1", "11675");
- checkOrAddDefault(variables, "port2", "11676");
- checkOrAddDefault(variables, "port3", "11677");
- checkOrAddDefault(variables, "port4", "11678");
-
- if (prefix != null && !prefix.trim().isEmpty()) {
- prefix += ".";
- } else {
- prefix = "";
+ PortScout portScout = new PortScout();
+ try {
+ checkOrAddDefault(variables, "localhost", localhost.getHostName());
+ checkOrAddDefault(variables, "localhost.ip", localhost.getHostAddress());
+ checkOrAddDefault(variables, "unresolvable.host", "unreachable.host.com");
+
+ checkOrAddDefault(variables, "port1", getRandomFreePort(portScout));
+ checkOrAddDefault(variables, "port2", getRandomFreePort(portScout));
+ checkOrAddDefault(variables, "port3", getRandomFreePort(portScout));
+ checkOrAddDefault(variables, "port4", getRandomFreePort(portScout));
+
+ if (prefix != null && !prefix.trim().isEmpty()) {
+ prefix += ".";
+ } else {
+ prefix = "";
+ }
+
+ checkOrAddDefault(variables, prefix + "snmp.port", getRandomFreePort(portScout));
+
+ checkOrAddDefault(variables, prefix + "listen1", "${port1}");
+ checkOrAddDefault(variables, prefix + "listen2", "${port2}");
+ checkOrAddDefault(variables, prefix + "listen3", "${port3}");
+ checkOrAddDefault(variables, prefix + "listen4", "${port4}");
+
+ checkOrAddDefault(variables, prefix + "vhost1.servername", "${localhost}:${port1}");
+ checkOrAddDefault(variables, prefix + "vhost1.urls", "${" + prefix + "vhost1.servername}");
+ checkOrAddDefault(variables, prefix + "vhost1.servername.directive", "ServerName ${" + prefix
+ + "vhost1.servername}");
+
+ checkOrAddDefault(variables, prefix + "vhost2.servername", "${localhost}:${port2}");
+ checkOrAddDefault(variables, prefix + "vhost2.urls", "${" + prefix + "vhost2.servername}");
+ checkOrAddDefault(variables, prefix + "vhost2.servername.directive", "ServerName ${" + prefix
+ + "vhost2.servername}");
+
+ checkOrAddDefault(variables, prefix + "vhost3.servername", "${localhost}:${port3}");
+ checkOrAddDefault(variables, prefix + "vhost3.urls", "${" + prefix + "vhost3.servername}");
+ checkOrAddDefault(variables, prefix + "vhost3.servername.directive", "ServerName ${" + prefix
+ + "vhost3.servername}");
+
+ checkOrAddDefault(variables, prefix + "vhost4.servername", "${localhost}:${port4}");
+ checkOrAddDefault(variables, prefix + "vhost4.urls", "${" + prefix + "vhost4.servername}");
+ checkOrAddDefault(variables, prefix + "vhost4.servername.directive", "ServerName ${" + prefix
+ + "vhost4.servername}");
+ } finally {
+ try {
+ portScout.close();
+ } catch (IOException e) {
+ throw new IllegalStateException(e);
+ }
}
-
- checkOrAddDefault(variables, prefix + "listen1", "${port1}");
- checkOrAddDefault(variables, prefix + "listen2", "${port2}");
- checkOrAddDefault(variables, prefix + "listen3", "${port3}");
- checkOrAddDefault(variables, prefix + "listen4", "${port4}");
-
- checkOrAddDefault(variables, prefix + "vhost1.servername", "${localhost}:${port1}");
- checkOrAddDefault(variables, prefix + "vhost1.urls", "${" + prefix + "vhost1.servername}");
- checkOrAddDefault(variables, prefix + "vhost1.servername.directive", "ServerName ${" + prefix
- + "vhost1.servername}");
-
- checkOrAddDefault(variables, prefix + "vhost2.servername", "${localhost}:${port2}");
- checkOrAddDefault(variables, prefix + "vhost2.urls", "${" + prefix + "vhost2.servername}");
- checkOrAddDefault(variables, prefix + "vhost2.servername.directive", "ServerName ${" + prefix
- + "vhost2.servername}");
-
- checkOrAddDefault(variables, prefix + "vhost3.servername", "${localhost}:${port3}");
- checkOrAddDefault(variables, prefix + "vhost3.urls", "${" + prefix + "vhost3.servername}");
- checkOrAddDefault(variables, prefix + "vhost3.servername.directive", "ServerName ${" + prefix
- + "vhost3.servername}");
-
- checkOrAddDefault(variables, prefix + "vhost4.servername", "${localhost}:${port4}");
- checkOrAddDefault(variables, prefix + "vhost4.urls", "${" + prefix + "vhost4.servername}");
- checkOrAddDefault(variables, prefix + "vhost4.servername.directive", "ServerName ${" + prefix
- + "vhost4.servername}");
}
private static void checkOrAddDefault(Map<String, String> map, String key, String value) {
@@ -433,4 +482,12 @@ public class ApacheDeploymentUtil {
}
}
};
+
+ private static String getRandomFreePort(PortScout scout) throws IllegalStateException {
+ try {
+ return Integer.toString(scout.getNextFreePort());
+ } catch (IOException e) {
+ throw new IllegalStateException("Failed to find a free port.", e);
+ }
+ }
}
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/PortScout.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/PortScout.java
new file mode 100644
index 0000000..3a33f09
--- /dev/null
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/PortScout.java
@@ -0,0 +1,69 @@
+/*
+ * RHQ Management Platform
+ * Copyright 2012, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
+package org.rhq.plugins.apache.util;
+
+import java.io.Closeable;
+import java.io.IOException;
+import java.net.ServerSocket;
+import java.net.SocketAddress;
+import java.util.HashSet;
+import java.util.Set;
+
+/**
+ * Tries to find a series of free ports.
+ *
+ * The ports remain open until the {@link #close()} method is called.
+ *
+ * @author Lukas Krejci
+ */
+public class PortScout implements Closeable {
+
+ private Set<ServerSocket> activeSockets = new HashSet<ServerSocket>();
+
+ public int getNextFreePort() throws IOException {
+ ServerSocket s = new ServerSocket(0);
+ activeSockets.add(s);
+ return s.getLocalPort();
+ }
+
+ @Override
+ public void close() throws IOException {
+ String message = null;
+ for(ServerSocket s : activeSockets) {
+ SocketAddress addr = s.getLocalSocketAddress();
+ try {
+ s.close();
+ } catch (IOException e) {
+ if (message == null) {
+ message = "The following test sockets failed to close while looking for free ports:\n";
+ }
+
+ message += addr.toString() + ": " + e.getMessage() + ",\n";
+ }
+ }
+
+ if (message != null) {
+ message = message.substring(0, message.length() - 2);
+
+ throw new IOException(message);
+ }
+ }
+}
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml
index 008588f..70151b7 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml
@@ -19,7 +19,7 @@
<param name="MaxBackupIndex" value="1000" />
<param name="MaxFileSize" value="50MB" />
<layout class="org.apache.log4j.PatternLayout">
- <param name="ConversionPattern" value="%-5p %d{dd-MM HH:mm:ss,SSS} (%F:%M:%L) -%m%n"/>
+ <param name="ConversionPattern" value="%-5p %d{dd-MM HH:mm:ss,SSS} [%t] (%F:%M:%L) -%m%n"/>
</layout>
</appender>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/includes/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/includes/inventory-without-snmp.xml
index 32f6477..10530b5 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/includes/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/includes/inventory-without-snmp.xml
@@ -512,7 +512,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/mess/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/mess/inventory-without-snmp.xml
index d0dd8ac..cbb9d66 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/mess/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/mess/inventory-without-snmp.xml
@@ -284,7 +284,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue><!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/nested/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/nested/inventory-without-snmp.xml
index d0dd8ac..1f97d99 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/nested/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/nested/inventory-without-snmp.xml
@@ -284,7 +284,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/simple/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/simple/inventory-without-snmp.xml
index 32f6477..10530b5 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/simple/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/simple/inventory-without-snmp.xml
@@ -512,7 +512,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/includes/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/includes/inventory-without-snmp.xml
index c3906be..987a9a0 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/includes/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/includes/inventory-without-snmp.xml
@@ -512,7 +512,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/mess/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/mess/inventory-without-snmp.xml
index 716773a..8557de3 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/mess/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/mess/inventory-without-snmp.xml
@@ -284,7 +284,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/nested/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/nested/inventory-without-snmp.xml
index 716773a..8557de3 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/nested/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/nested/inventory-without-snmp.xml
@@ -284,7 +284,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/simple/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/simple/inventory-without-snmp.xml
index c3906be..987a9a0 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/simple/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/simple/inventory-without-snmp.xml
@@ -512,7 +512,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java b/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java
index a07438d..2a2b839 100644
--- a/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java
+++ b/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java
@@ -292,7 +292,8 @@ public class ApacheServerComponent implements AugeasRHQComponent, ResourceCompon
availPingTime = System.currentTimeMillis() - t1;
} else {
if (log.isDebugEnabled()) {
- log.debug("Trying to ping the server for availability through SNMP.");
+ log.debug("Trying to ping the server for availability through SNMP "
+ + getSNMPAddressString(resourceContext.getPluginConfiguration()));
}
available = getSNMPSession().ping();
availPingTime = -1;
@@ -633,6 +634,14 @@ public class ApacheServerComponent implements AugeasRHQComponent, ResourceCompon
return snmpSession;
}
+ private static String getSNMPAddressString(Configuration pluginConfig) {
+ String host = pluginConfig.getSimple(PLUGIN_CONFIG_PROP_SNMP_AGENT_HOST).getStringValue();
+ String portString = pluginConfig.getSimple(PLUGIN_CONFIG_PROP_SNMP_AGENT_PORT).getStringValue();
+ String community = pluginConfig.getSimple(PLUGIN_CONFIG_PROP_SNMP_AGENT_COMMUNITY).getStringValue();
+
+ return host + ":" + portString + "/" + community;
+ }
+
/**
* Return the absolute path of this Apache server's server root (e.g. "C:\Program Files\Apache Group\Apache2").
*
commit 8b0919aceedac820bcbd2beb9408b1795cc32c8d
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Wed Nov 21 17:00:07 2012 +0100
stuff to help debug the apache integration test failures.
diff --git a/modules/enterprise/scripting/javascript/pom.xml b/modules/enterprise/scripting/javascript/pom.xml
index ab35acb..ee5e4ba 100644
--- a/modules/enterprise/scripting/javascript/pom.xml
+++ b/modules/enterprise/scripting/javascript/pom.xml
@@ -27,6 +27,10 @@
</dependency>
</dependencies>
+ <properties>
+ <failIfNoTests>true</failIfNoTests>
+ </properties>
+
<build>
<plugins>
<plugin>
@@ -61,7 +65,7 @@
-Djava.security.policy==${project.build.testOutputDirectory}/allow-all.policy</argLine>
<!-- This is important, because some of the tests try to exit
the JVM. -->
- <failIfNoTests>true</failIfNoTests>
+ <failIfNoTests>${failIfNoTests}</failIfNoTests>
</configuration>
</plugin>
</plugins>
diff --git a/modules/enterprise/scripting/python/pom.xml b/modules/enterprise/scripting/python/pom.xml
index e4b3cfb..fc64086 100644
--- a/modules/enterprise/scripting/python/pom.xml
+++ b/modules/enterprise/scripting/python/pom.xml
@@ -10,6 +10,10 @@
<name>RHQ Python support</name>
<description>Provides RHQ scripting in Python using Jython</description>
+ <properties>
+ <failIfNoTests>true</failIfNoTests>
+ </properties>
+
<dependencies>
<dependency>
<groupId>${project.groupId}</groupId>
@@ -60,7 +64,7 @@
-Djava.security.policy==${project.build.testOutputDirectory}/allow-all.policy</argLine>
<!-- This is important, because some of the tests try to exit
the JVM. -->
- <failIfNoTests>true</failIfNoTests>
+ <failIfNoTests>${failIfNoTests}</failIfNoTests>
</configuration>
</plugin>
</plugins>
diff --git a/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java b/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java
index 8ccef7f..a07438d 100644
--- a/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java
+++ b/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java
@@ -283,18 +283,31 @@ public class ApacheServerComponent implements AugeasRHQComponent, ResourceCompon
boolean available;
try {
if (this.url != null) {
+ if (log.isDebugEnabled()) {
+ log.debug("Trying to ping the server for availability: " + this.url);
+ }
long t1 = System.currentTimeMillis();
int timeout = PluginUtility.getAvailabilityFacetTimeout();
available = WWWUtils.isAvailable(this.url, timeout);
availPingTime = System.currentTimeMillis() - t1;
} else {
+ if (log.isDebugEnabled()) {
+ log.debug("Trying to ping the server for availability through SNMP.");
+ }
available = getSNMPSession().ping();
availPingTime = -1;
}
} catch (Exception e) {
+ if (log.isDebugEnabled()) {
+ log.debug("Exception while checking availability.", e);
+ }
available = false;
}
+ if (log.isDebugEnabled()) {
+ log.debug("Availability determined: " + (available ? AvailabilityType.UP : AvailabilityType.DOWN));
+ }
+
return (available) ? AvailabilityType.UP : AvailabilityType.DOWN;
}
commit bed7fb96f03e50db87a8b9699846e6f51b24584a
Author: Thomas SEGISMONT <tsegismo(a)redhat.com>
Date: Fri Nov 23 11:37:42 2012 +0100
Fix Eclipse classpath file
GWT -> 2.5.0
joda-time was missing
diff --git a/.classpath b/.classpath
index e452825..e2d8841 100644
--- a/.classpath
+++ b/.classpath
@@ -269,8 +269,8 @@
<classpathentry exported="true" kind="var" path="M2_REPO/jboss/web/jbossweb/2.0.1.GA/jbossweb-2.0.1.GA.jar"/>
<classpathentry exported="true" kind="var" path="M2_REPO/org/libvirt/libvirt/0.4.1/libvirt-0.4.1.jar"/>
<classpathentry exported="true" kind="var" path="M2_REPO/org/fedorahosted/cobbler/cobbler4j/0.1/cobbler4j-0.1.jar"/>
- <classpathentry exported="true" kind="var" path="M2_REPO/com/google/gwt/gwt-user/2.4.0/gwt-user-2.4.0.jar"/>
- <classpathentry exported="true" kind="var" path="M2_REPO/com/google/gwt/gwt-dev/2.4.0/gwt-dev-2.4.0.jar"/>
+ <classpathentry exported="true" kind="var" path="M2_REPO/com/google/gwt/gwt-user/2.5.0/gwt-user-2.5.0.jar"/>
+ <classpathentry exported="true" kind="var" path="M2_REPO/com/google/gwt/gwt-dev/2.5.0/gwt-dev-2.5.0.jar"/>
<classpathentry exported="true" kind="var" path="M2_REPO/com/smartgwt/smartgwt/3.0/smartgwt-3.0.jar"/>
<classpathentry exported="true" kind="var" path="M2_REPO/com/googlecode/gflot/gflot/2.4.2/gflot-2.4.2.jar"/>
<classpathentry exported="true" kind="var" path="M2_REPO/com/jcraft/jsch/0.1.29/jsch-0.1.29.jar"/>
@@ -316,5 +316,6 @@
<classpathentry exported="true" kind="var" path="M2_REPO/com/wordnik/swagger-annotations_2.9.1/1.1-SNAPSHOT/swagger-annotations_2.9.1-1.1-20120531.064118-1.jar"/>
<classpathentry exported="true" kind="var" path="M2_REPO/org/jboss/byteman/byteman/1.2.1/byteman-1.2.1.jar"/>
<classpathentry kind="var" path="M2_REPO/com/wordnik/swagger-annotations_2.9.1/1.1.1-SNAPSHOT/swagger-annotations_2.9.1-1.1.1-20121031.024335-6.jar"/>
+ <classpathentry exported="true" kind="var" path="M2_REPO/joda-time/joda-time/2.1/joda-time-2.1.jar"/>
<classpathentry kind="output" path="eclipse-classes"/>
</classpath>
commit a819562f809b7ca59c4f9b39c779df7abdb84704
Author: Heiko W. Rupp <hwr(a)redhat.com>
Date: Thu Nov 22 13:14:48 2012 +0100
Add more excludes for the mem pools
diff --git a/modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/GenericJBossAS7PluginTest.java b/modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/GenericJBossAS7PluginTest.java
index 0bf2796..374748d 100644
--- a/modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/GenericJBossAS7PluginTest.java
+++ b/modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/GenericJBossAS7PluginTest.java
@@ -58,7 +58,9 @@ public class GenericJBossAS7PluginTest extends AbstractJBossAS7PluginTest {
// are not exposed, it is normal that the server returns 'undefined' for the value
// Note that those
excludedMetricNamesByType.put(new ResourceType("Memory Pool Resource",PLUGIN_NAME, ResourceCategory.SERVICE,null),
- new String[] {"collection-usage-threshold-count","collection-usage-threshold","collection-usage"});
+ new String[] {"collection-usage-threshold-count","collection-usage-threshold","collection-usage",
+ "collection-usage-threshold-exceeded","collection-usage:committed","collection-usage:init",
+ "collection-usage:max","collection-usage:used","usage-threshold-count","usage-threshold-exceeded"});
assertAllNumericMetricsAndTraitsHaveNonNullValues(excludedMetricNamesByType);
}
commit 22e30a3ff434e1193ef84ce6fa0ae7eb0dc2cbec
Author: Heiko W. Rupp <hwr(a)redhat.com>
Date: Thu Nov 22 11:41:25 2012 +0100
Make message more clear in case of failure.
diff --git a/modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/nonpc/AbstractIntegrationTest.java b/modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/nonpc/AbstractIntegrationTest.java
index bb1eca2..130f7f3 100644
--- a/modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/nonpc/AbstractIntegrationTest.java
+++ b/modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/nonpc/AbstractIntegrationTest.java
@@ -100,7 +100,7 @@ public abstract class AbstractIntegrationTest {
assert node != null : "No result from upload - node was null";
assert node.has("outcome") : "No outcome from upload";
String outcome = node.get("outcome").getTextValue();
- assert outcome.equals("success") : "Upload was no success" + outcome;
+ assert outcome.equals("success") : "Upload was no success, but: [" + outcome + "]";
JsonNode resultNode = node.get("result");
return resultNode.get("BYTES_VALUE").getTextValue();
commit c9d13f6b1cc8745c11e047be4c55786a8b9ca16c
Author: Heiko W. Rupp <hwr(a)redhat.com>
Date: Thu Nov 22 09:10:41 2012 +0100
Add some excluded metrics, as they may indeed return null.
diff --git a/modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/GenericJBossAS7PluginTest.java b/modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/GenericJBossAS7PluginTest.java
index 2b7ec7a..0bf2796 100644
--- a/modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/GenericJBossAS7PluginTest.java
+++ b/modules/plugins/jboss-as-7/src/test/java/org/rhq/modules/plugins/jbossas7/itest/GenericJBossAS7PluginTest.java
@@ -23,6 +23,7 @@ import java.util.Map;
import org.testng.annotations.Test;
+import org.rhq.core.domain.resource.ResourceCategory;
import org.rhq.core.domain.resource.ResourceType;
import org.rhq.core.plugin.testutil.AbstractAgentPluginTest;
import org.rhq.modules.plugins.jbossas7.itest.domain.ManagedServerTest;
@@ -53,6 +54,11 @@ public class GenericJBossAS7PluginTest extends AbstractJBossAS7PluginTest {
// It's normal for the "startTime" trait to be null for a Managed Server that is down/disabled.
// It's normal for the "multicastAddress" trait to be null for a Managed Server that is not configured for JGroups HA.
excludedMetricNamesByType.put(ManagedServerTest.RESOURCE_TYPE, new String[] {"startTime", "multicastAddress"});
+ // Some memory pools do not expose those statistics (by default), so in case they
+ // are not exposed, it is normal that the server returns 'undefined' for the value
+ // Note that those
+ excludedMetricNamesByType.put(new ResourceType("Memory Pool Resource",PLUGIN_NAME, ResourceCategory.SERVICE,null),
+ new String[] {"collection-usage-threshold-count","collection-usage-threshold","collection-usage"});
assertAllNumericMetricsAndTraitsHaveNonNullValues(excludedMetricNamesByType);
}
commit 94e78de367b5472188fcad8425b0e057f8d602af
Author: Heiko W. Rupp <hwr(a)redhat.com>
Date: Tue Nov 20 10:31:32 2012 +0100
Print the DB-url and user that is used to run the tests to make debugging easier.
diff --git a/modules/core/domain/src/test/java/org/rhq/core/domain/test/AbstractEJB3Test.java b/modules/core/domain/src/test/java/org/rhq/core/domain/test/AbstractEJB3Test.java
index 82af5e0..b57f661 100644
--- a/modules/core/domain/src/test/java/org/rhq/core/domain/test/AbstractEJB3Test.java
+++ b/modules/core/domain/src/test/java/org/rhq/core/domain/test/AbstractEJB3Test.java
@@ -24,6 +24,7 @@ package org.rhq.core.domain.test;
import java.io.File;
import java.net.URL;
+import java.sql.DatabaseMetaData;
import java.util.Date;
import java.util.Hashtable;
@@ -79,6 +80,7 @@ public abstract class AbstractEJB3Test extends AssertJUnit {
deployer.start();
System.err.println("...... deployer started....");
+ printDbVersion();
} catch (Throwable t) {
// Catch RuntimeExceptions and Errors and dump their stack trace, because Surefire will completely swallow them
// and throw a cryptic NPE (see http://jira.codehaus.org/browse/SUREFIRE-157)!
@@ -100,6 +102,13 @@ public abstract class AbstractEJB3Test extends AssertJUnit {
return lookupEntityManager();
}
+ private static void printDbVersion() throws Exception {
+ EntityManager em = lookupEntityManager();
+ DatabaseMetaData md = ((org.hibernate.ejb.EntityManagerImpl) em).getSession().connection().getMetaData();
+ System.err.println(">>> Database url for testing is [" + md.getURL() + "] with user [" + md.getUserName() + "] <<<");
+
+ }
+
public boolean isPostgres(EntityManager em) throws Exception {
return ((org.hibernate.ejb.EntityManagerImpl) em).getSession().connection().getMetaData()
.getDatabaseProductName().toLowerCase().indexOf("postgres") > -1;
commit fa0629bd6c85ddea66f782772a9e4b11fbdc78a0
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Wed Nov 21 18:41:14 2012 +0100
Recovering from the loss of ant as a transitive dep of cobertura in tests.
diff --git a/modules/enterprise/remoting/client-api/src/test/java/org/rhq/enterprise/clienapi/RhqDownloadsScriptSourceProviderTest.java b/modules/enterprise/remoting/client-api/src/test/java/org/rhq/enterprise/clienapi/RhqDownloadsScriptSourceProviderTest.java
index 01a38e6..b651629 100644
--- a/modules/enterprise/remoting/client-api/src/test/java/org/rhq/enterprise/clienapi/RhqDownloadsScriptSourceProviderTest.java
+++ b/modules/enterprise/remoting/client-api/src/test/java/org/rhq/enterprise/clienapi/RhqDownloadsScriptSourceProviderTest.java
@@ -22,13 +22,10 @@ package org.rhq.enterprise.clienapi;
import static org.testng.Assert.assertEquals;
import java.io.File;
-import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.Reader;
import java.net.URI;
-import java.net.URL;
-import org.apache.tools.ant.filters.StringInputStream;
import org.mockito.Mockito;
import org.powermock.api.mockito.PowerMockito;
import org.powermock.core.classloader.annotations.PrepareForTest;
diff --git a/modules/enterprise/server/jar/pom.xml b/modules/enterprise/server/jar/pom.xml
index 06a6e69..18ff9d4 100644
--- a/modules/enterprise/server/jar/pom.xml
+++ b/modules/enterprise/server/jar/pom.xml
@@ -571,6 +571,12 @@
<scope>test</scope>
</dependency>
+ <dependency>
+ <groupId>ant</groupId>
+ <artifactId>ant</artifactId>
+ <version>1.6.5</version>
+ <scope>test</scope>
+ </dependency>
</dependencies>
<build>
commit 5d2732fd7f4b2c11e81962dc95584a3f0801fab1
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Wed Nov 21 17:26:11 2012 +0100
Removing last remnants of cobertura from the poms.
diff --git a/modules/helpers/pom.xml b/modules/helpers/pom.xml
index e036910..20f1f76 100644
--- a/modules/helpers/pom.xml
+++ b/modules/helpers/pom.xml
@@ -16,16 +16,6 @@
<name>RHQ Helpers</name>
<description>parent POM for all RHQ helpers</description>
- <dependencies>
- <dependency>
- <groupId>net.sourceforge.cobertura</groupId>
- <artifactId>cobertura</artifactId>
- <version>${cobertura.version}</version>
- <scope>test</scope>
- </dependency>
- </dependencies>
-
-
<modules>
<module>rtfilter</module>
diff --git a/modules/test-utils/pom.xml b/modules/test-utils/pom.xml
index 2525960..a04cf92 100644
--- a/modules/test-utils/pom.xml
+++ b/modules/test-utils/pom.xml
@@ -40,12 +40,6 @@
<artifactId>commons-beanutils</artifactId>
<version>1.8.2</version>
</dependency>
- <dependency>
- <groupId>net.sourceforge.cobertura</groupId>
- <artifactId>cobertura</artifactId>
- <version>${cobertura.version}</version>
- <scope>test</scope>
- </dependency>
<dependency>
<groupId>org.unitils</groupId>
<artifactId>unitils-dbunit</artifactId>
@@ -70,6 +64,11 @@
using the version that we use else where.
jsanda 10/20/2010
+
+ Cobertura is not used anymore so no ASM clashes should
+ be present. We still maintain this exclusion though
+ to force the usage of "our" version of Hibernate.
+ lkrejci 2012-11-21
-->
<exclusion>
<groupId>org.hibernate</groupId>
diff --git a/pom.xml b/pom.xml
index cefbe69..f8b3811 100644
--- a/pom.xml
+++ b/pom.xml
@@ -100,7 +100,6 @@
<twitter4j.version>2.2.4</twitter4j.version>
<commons-codec.version>1.4</commons-codec.version>
<testng.version>6.5.2</testng.version>
- <cobertura.version>1.9.4.1</cobertura.version>
<augeas.version>0.9.0</augeas.version>
<augeas.classifier>el5</augeas.classifier>
<augeas.zip.version>0.9.0</augeas.zip.version>
@@ -567,13 +566,6 @@
</dependency>
<!-- end of workaround -->
- <dependency>
- <groupId>net.sourceforge.cobertura</groupId>
- <artifactId>cobertura</artifactId>
- <version>${cobertura.version}</version>
- <scope>test</scope>
- </dependency>
-
</dependencies>
commit e2b304be7cc59a0e4cf331b1f8506bf8d2f9eb56
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Wed Nov 21 16:07:30 2012 +0100
Fixing the incorrect assertions in the ApplicationServerComponentTest in AS5 integration tests.
diff --git a/modules/plugins/jboss-as-5/src/test/java/org/rhq/plugins/jbossas5/itest/ApplicationServerComponentTest.java b/modules/plugins/jboss-as-5/src/test/java/org/rhq/plugins/jbossas5/itest/ApplicationServerComponentTest.java
index 6d60b85..effc856 100644
--- a/modules/plugins/jboss-as-5/src/test/java/org/rhq/plugins/jbossas5/itest/ApplicationServerComponentTest.java
+++ b/modules/plugins/jboss-as-5/src/test/java/org/rhq/plugins/jbossas5/itest/ApplicationServerComponentTest.java
@@ -23,9 +23,9 @@
package org.rhq.plugins.jbossas5.itest;
import static org.testng.Assert.assertEquals;
-import static org.testng.Assert.assertTrue;
import static org.testng.Assert.assertNotNull;
import static org.testng.Assert.assertNull;
+import static org.testng.Assert.assertTrue;
import java.io.File;
import java.util.Arrays;
@@ -220,8 +220,8 @@ public class ApplicationServerComponentTest extends AbstractJBossAS5PluginTest {
operationResult = invokeOperation(getServerResource(), SHUTDOWN_OPERATION_NAME, null);
avail = getAvailability(getServerResource());
assertEquals(avail, AvailabilityType.DOWN);
- assertNull(operationResult.getErrorMessage());
- assertEquals(operationResult.getSimpleResult(), "The server has been shut down.");
+ assertNotNull(operationResult.getErrorMessage());
+ assertNull(operationResult.getSimpleResult());
// Before restarting it, add some stuff to the 'startScriptEnv' and 'startScriptArgs' props so we can verify
// they are used correctly by the Start op.
commit 2ae8bc1158dcae4457a738a7414e3c71fd898ed0
Author: Jirka Kremser <jkremser(a)redhat.com>
Date: Tue Nov 20 15:17:34 2012 +0100
[BZ 850818 - Globally uncaught exception on clicking OK button while adding CLI Script alert notification to the alert definition] Another possible scenario where NPE was thrown was fixed by this commit.
diff --git a/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/alert/definitions/CliNotificationSenderForm.java b/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/alert/definitions/CliNotificationSenderForm.java
index b212043..1d55350 100644
--- a/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/alert/definitions/CliNotificationSenderForm.java
+++ b/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/alert/definitions/CliNotificationSenderForm.java
@@ -140,8 +140,8 @@ public class CliNotificationSenderForm extends AbstractNotificationSenderForm {
protected List<FormItem> getOnDrawItems() {
List<FormItem> items = super.getOnDrawItems();
- TextItem version = new TextItem("editableVersion", MSG
- .view_alert_definition_notification_cliScript_editor_newScriptVersion());
+ TextItem version = new TextItem("editableVersion",
+ MSG.view_alert_definition_notification_cliScript_editor_newScriptVersion());
version.setColSpan(getNumCols());
version.addChangedHandler(new ChangedHandler() {
public void onChanged(ChangedEvent event) {
@@ -179,8 +179,9 @@ public class CliNotificationSenderForm extends AbstractNotificationSenderForm {
}
};
- private boolean formBuilt;
+ private static String FAILED_LAST_TIME = "failed";
+ private boolean formBuilt;
private SelectItem repoSelector;
private RadioGroupWithComponentsItem packageSelector;
private SelectItem existingPackageSelector;
@@ -227,8 +228,8 @@ public class CliNotificationSenderForm extends AbstractNotificationSenderForm {
SectionItem userSection = new SectionItem("userSection");
userSection.setDefaultValue(MSG.view_alert_definition_notification_cliScript_editor_whichUser());
- repoSelector = new SortedSelectItem(extendLocatorId("repoSelector"), MSG
- .view_alert_definition_notification_cliScript_editor_selectRepo());
+ repoSelector = new SortedSelectItem(extendLocatorId("repoSelector"),
+ MSG.view_alert_definition_notification_cliScript_editor_selectRepo());
repoSelector.setDefaultToFirstOption(true);
repoSelector.setWrapTitle(false);
repoSelector.setWidth(400);
@@ -404,10 +405,19 @@ public class CliNotificationSenderForm extends AbstractNotificationSenderForm {
private void validatePackage(final AsyncCallback<Void> callback) {
if (config.selectedRepo == null) {
- repoSelector.setIcons(failureIcon);
+ setFailed(repoSelector);
callback.onFailure(null);
return;
}
+ setOk(repoSelector);
+ if (!existingPackageSelector.isDisabled()) {
+ if (config.selectedPackage == null) {
+ setFailed(existingPackageSelector);
+ callback.onFailure(null);
+ return;
+ }
+ setOk(existingPackageSelector);
+ }
getConfiguration().put(new PropertySimple(PROP_REPO_ID, config.selectedRepo.getId()));
if (packageSelector.getSelectedIndex() == 0) {
@@ -418,7 +428,8 @@ public class CliNotificationSenderForm extends AbstractNotificationSenderForm {
if (cliScriptPackageType.getVersionFormat() != null) {
String versionRegex = cliScriptPackageType.getVersionFormat().getFullFormatRegex();
if (versionRegex != null) {
- if (!matches(uploadForm.getField("version").getValue().toString(), versionRegex)) {
+ Object version = uploadForm.getField("version").getValue();
+ if (version == null ||!matches(version.toString(), versionRegex)) {
uploadForm.getItem("editableVersion").setIcons(failureIcon);
callback.onFailure(null);
return;
@@ -530,8 +541,8 @@ public class CliNotificationSenderForm extends AbstractNotificationSenderForm {
form.setTitleOrientation(TitleOrientation.TOP);
anotherUserName = new TextItem("userName", MSG.dataSource_users_field_name());
anotherUserPassword = new PasswordItem("password", MSG.common_title_password());
- verifyUserButton = new ButtonItem("verify", MSG
- .view_alert_definition_notification_cliScript_editor_verifyAuthentication());
+ verifyUserButton = new ButtonItem("verify",
+ MSG.view_alert_definition_notification_cliScript_editor_verifyAuthentication());
successIcon = new FormItemIcon();
successIcon.setSrc(ImageManager.getAvailabilityIcon(Boolean.TRUE));
@@ -680,6 +691,19 @@ public class CliNotificationSenderForm extends AbstractNotificationSenderForm {
GWTServiceLookup.getContentService().findPackageType(null, PACKAGE_TYPE_NAME, handler);
}
+ private void setFailed(FormItem item) {
+ item.setIcons(failureIcon);
+ item.setAttribute(FAILED_LAST_TIME, true);
+ }
+
+ private void setOk(FormItem item) {
+ Boolean lastTimeFail = item.getAttributeAsBoolean(FAILED_LAST_TIME);
+ if (lastTimeFail != null && lastTimeFail) {
+ item.setIcons(successIcon);
+ item.setAttribute(FAILED_LAST_TIME, false);
+ }
+ }
+
private void checkAuthenticationAndDo(final AsyncCallback<Void> action) {
String username = anotherUserName.getEnteredValue();
String password = anotherUserPassword.getEnteredValue();
commit 5028943b4989adb7fa0af99396bd604b6db889c5
Author: Jirka Kremser <jkremser(a)redhat.com>
Date: Tue Nov 20 13:38:45 2012 +0100
Greasemonkey script for FF for typing in the default credentials after pressing Alt + C (can be used also in Chrome with Tampermonkey extension)
diff --git a/etc/greasemonkey/RHQ_login_monkey.user.js b/etc/greasemonkey/RHQ_login_monkey.user.js
new file mode 100644
index 0000000..5c67125
--- /dev/null
+++ b/etc/greasemonkey/RHQ_login_monkey.user.js
@@ -0,0 +1,31 @@
+// ==UserScript==
+// @name RHQ login monkey
+// @namespace org.rhq.enterprise.gui.coregui
+// @description Types in the credentials
+// @include *:7080/coregui/*
+// @include *:7080/coregui/#LogOut
+// @grant none
+// @version 1
+// ==/UserScript==
+
+//GM_registerMenuCommand("Fill the credentials", function(e) {
+// fillTheCredentials();
+//}, "c", "alt", "c" );
+
+
+(function(){
+document.addEventListener('keydown', function(e) {
+ // pressed alt+c
+ if (e.keyCode == 67 && !e.shiftKey && !e.ctrlKey && e.altKey && !e.metaKey) {
+ fillTheCredentials();
+ }
+}, false);
+})();
+
+
+function fillTheCredentials() {
+ document.getElementsByName("user")[0].value="rhqadmin"
+ document.getElementsByName("password")[0].value="rhqadmin"
+ //document.forms[0].submit() don't work, SmartGWT uses internal logic
+ document.getElementsByName("password")[0].focus()
+}
commit 8ab939690aefbb6316aca6336c41804f728d290e
Author: Jay Shaughnessy <jshaughn(a)redhat.com>
Date: Mon Nov 19 17:49:07 2012 -0500
[Bug 878224 -Updated alert defs may not fire in an HA environment]
When setting the server status dirty to notify the need for global condition cache
refresh, update *all* servers. The global condition cache is supposed to be
replicated across HA servers. Otherwise, different servers will have different
condition sets generating unexpected results.
diff --git a/modules/core/domain/src/main/java/org/rhq/core/domain/cloud/Server.java b/modules/core/domain/src/main/java/org/rhq/core/domain/cloud/Server.java
index 09d5332..0ba8683 100644
--- a/modules/core/domain/src/main/java/org/rhq/core/domain/cloud/Server.java
+++ b/modules/core/domain/src/main/java/org/rhq/core/domain/cloud/Server.java
@@ -89,8 +89,7 @@ import org.rhq.core.domain.resource.Agent;
@NamedQuery(name = Server.QUERY_UPDATE_STATUS_BY_NAME, query = "" //
+ " UPDATE Server s " //
+ " SET s.status = -1 " // negative numbers so that bitmask strat does not conflict with this one
- + " WHERE s.status = 0 " // we only need the first guy to set it
- + " AND s.name = :identity ") })
+ + " WHERE s.status = 0 ") })
@SequenceGenerator(name = "id", sequenceName = "RHQ_SERVER_ID_SEQ")
@Table(name = "RHQ_SERVER")
public class Server implements Serializable {
diff --git a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/cloud/StatusManagerBean.java b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/cloud/StatusManagerBean.java
index 9658dd1..e84c979 100644
--- a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/cloud/StatusManagerBean.java
+++ b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/cloud/StatusManagerBean.java
@@ -188,7 +188,6 @@ public class StatusManagerBean implements StatusManagerLocal {
@TransactionAttribute(TransactionAttributeType.REQUIRES_NEW)
public void markGlobalCache() {
Query updateServerQuery = entityManager.createNamedQuery(Server.QUERY_UPDATE_STATUS_BY_NAME);
- updateServerQuery.setParameter("identity", serverManager.getIdentity());
int serversUpdated = updateServerQuery.executeUpdate();
/*
commit 6c27b0e3a978a7642b9bcead40cb2eee0cec7265
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Mon Nov 19 17:07:28 2012 +0100
Make the copied error logs really reflect the test they were collected for.
Also bumped up the number and size of the retained logs greatly, because
we collect A LOT of data in the debug mode, which is needed until we fix
the failures in the CI environment.
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/augeas/AugeasReferenceLeakingTest.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/augeas/AugeasReferenceLeakingTest.java
index 4a0f7b7..b1c8a24 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/augeas/AugeasReferenceLeakingTest.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/augeas/AugeasReferenceLeakingTest.java
@@ -168,7 +168,8 @@ public class AugeasReferenceLeakingTest extends BMNGRunner {
}
};
- setup = new ApacheTestSetup(this.getClass(), apacheConfig.configurationName,
+ setup = new ApacheTestSetup(this.getClass().getSimpleName()
+ + "#testReadingConfigurationsDoesNotLeakAugeasReferences", apacheConfig.configurationName,
PluginContainerTest.getCurrentMockContext(),
new ResourceTypes(PluginLocation.APACHE_PLUGIN));
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/setup/ApacheTestSetup.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/setup/ApacheTestSetup.java
index 430f00a..9f12166 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/setup/ApacheTestSetup.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/setup/ApacheTestSetup.java
@@ -73,7 +73,7 @@ public class ApacheTestSetup {
private Map<String, String> inventoryFileReplacements;
private Mockery context;
private ResourceTypes apacheResourceTypes;
- private Class<?> testClass;
+ private String testId;
public class ApacheSetup {
private String serverRoot;
@@ -133,7 +133,7 @@ public class ApacheTestSetup {
File errorLog = new File(new File(new File(serverRoot), "logs"), "error_log");
if (errorLog.exists() && errorLog.canRead()) {
- String copyName = testClass.getSimpleName() + "-" + configurationName + ".httpd.error_log";
+ String copyName = testId + ".httpd.error_log";
FileUtil.copyFile(errorLog, new File(new File("target"), copyName));
}
@@ -214,9 +214,9 @@ public class ApacheTestSetup {
}
}
- public ApacheTestSetup(Class<?> testClass, String configurationName, Mockery context,
+ public ApacheTestSetup(String testId, String configurationName, Mockery context,
ResourceTypes apacheResourceTypes) {
- this.testClass = testClass;
+ this.testId = testId;
this.configurationName = configurationName;
this.context = context;
this.apacheResourceTypes = apacheResourceTypes;
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
index 9180f2c..8f8cdb6 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
@@ -95,14 +95,15 @@ public class UpgradeTestBase extends PluginContainerTest {
platform = discoverPlatform();
}
- protected void testUpgrade(ApacheTestConfiguration testConfiguration) throws Throwable {
- final ApacheTestSetup setup = new ApacheTestSetup(this.getClass(), testConfiguration.configurationName,
- context, apacheResourceTypes);
+ protected void testUpgrade(String testMethod, ApacheTestConfiguration testConfiguration) throws Throwable {
+ String testId = this.getClass().getSimpleName() + "#" + testMethod;
+ final ApacheTestSetup setup = new ApacheTestSetup(testId, testConfiguration.configurationName, context,
+ apacheResourceTypes);
boolean testFailed = false;
try {
LOG.debug("---------------------------------------------------------- Starting the upgrade test for: "
- + this.getClass().getSimpleName() + ": " + testConfiguration.configurationName);
+ + testId);
String[] configFiles = Arrays.copyOf(testConfiguration.apacheConfigurationFiles, testConfiguration.apacheConfigurationFiles.length + 1);
configFiles[testConfiguration.apacheConfigurationFiles.length] = "/snmpd.conf";
@@ -203,7 +204,7 @@ public class UpgradeTestBase extends PluginContainerTest {
}
LOG.debug("---------------------------------------------------------- Finished the upgrade test for: "
- + this.getClass().getSimpleName() + ": " + testConfiguration.configurationName);
+ + testId);
}
}
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq1_3_x/UpgradeNestedConfigurationFromRHQ1_3Test.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq1_3_x/UpgradeNestedConfigurationFromRHQ1_3Test.java
index 80efc67..9c1c921 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq1_3_x/UpgradeNestedConfigurationFromRHQ1_3Test.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq1_3_x/UpgradeNestedConfigurationFromRHQ1_3Test.java
@@ -58,7 +58,7 @@ public class UpgradeNestedConfigurationFromRHQ1_3Test extends UpgradeTestBase {
public void testWithResolvableServerNames(final String installPath, final String exePath)
throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithResolvableServerNames", new ApacheTestConfiguration() {
{
serverRoot = installPath;
binPath = exePath;
@@ -94,7 +94,7 @@ public class UpgradeNestedConfigurationFromRHQ1_3Test extends UpgradeTestBase {
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN }, numberOfInitialDiscoveries = 2)
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithNonUniqueServerNames(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithNonUniqueServerNames", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_UNRESOLVABLE_SERVER_NAMES;
apacheConfigurationFiles = configuredApacheConfigurationFiles;
@@ -120,7 +120,7 @@ public class UpgradeNestedConfigurationFromRHQ1_3Test extends UpgradeTestBase {
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN}, numberOfInitialDiscoveries = 2)
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithAnyAddress(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithAnyAddress", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -148,7 +148,7 @@ public class UpgradeNestedConfigurationFromRHQ1_3Test extends UpgradeTestBase {
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithWildcardAddress(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithWildcardAddress", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq1_3_x/UpgradeSimpleConfigurationFromRHQ1_3Test.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq1_3_x/UpgradeSimpleConfigurationFromRHQ1_3Test.java
index 8788287..dfb78d1 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq1_3_x/UpgradeSimpleConfigurationFromRHQ1_3Test.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq1_3_x/UpgradeSimpleConfigurationFromRHQ1_3Test.java
@@ -59,7 +59,7 @@ public class UpgradeSimpleConfigurationFromRHQ1_3Test extends UpgradeTestBase {
public void testWithResolvableServerNames_Apache2(final String installPath, final String exePath)
throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithResolvableServerNames_Apache2", new ApacheTestConfiguration() {
{
serverRoot = installPath;
binPath = exePath;
@@ -77,7 +77,8 @@ public class UpgradeSimpleConfigurationFromRHQ1_3Test extends UpgradeTestBase {
public void testWithResolvableServerNames_Apache1(final String installPath, final String exePath)
throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {{
+ testUpgrade("testWithResolvableServerNames_Apache1", new ApacheTestConfiguration() {
+ {
serverRoot = installPath;
binPath = exePath;
configurationName = DEPLOYMENT_SIMPLE_WITH_RESOLVABLE_SERVERNAMES;
@@ -90,7 +91,7 @@ public class UpgradeSimpleConfigurationFromRHQ1_3Test extends UpgradeTestBase {
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithNonUniqueServerNames_Apache2(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithNonUniqueServerNames_Apache2", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_UNRESOLVABLE_SERVER_NAMES;
apacheConfigurationFiles = configuredApacheConfigurationFiles;
@@ -113,7 +114,7 @@ public class UpgradeSimpleConfigurationFromRHQ1_3Test extends UpgradeTestBase {
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithAnyAddress(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithAnyAddress", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -135,7 +136,7 @@ public class UpgradeSimpleConfigurationFromRHQ1_3Test extends UpgradeTestBase {
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithWildcardAddress(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithWildcardAddress", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_0/UpgradeNestedConfigurationFromRHQ3_0_0Test.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_0/UpgradeNestedConfigurationFromRHQ3_0_0Test.java
index 3600fcd..99bea6e 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_0/UpgradeNestedConfigurationFromRHQ3_0_0Test.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_0/UpgradeNestedConfigurationFromRHQ3_0_0Test.java
@@ -66,7 +66,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN }, numberOfInitialDiscoveries = 2)
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithResolvableNamesWithoutSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithResolvableNamesWithoutSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithoutSNMP;
@@ -91,7 +91,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN }, numberOfInitialDiscoveries = 2)
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithUnresolvableNamesWithoutSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithUnresolvableNamesWithoutSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithoutSNMP;
@@ -124,7 +124,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN }, numberOfInitialDiscoveries = 2)
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithNonUniqueNamesWithoutSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithNonUniqueNamesWithoutSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithoutSNMP;
@@ -168,7 +168,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithResolvableNamesWithSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithResolvableNamesWithSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSNMP;
@@ -193,7 +193,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithUnresolvableNamesWithSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithUnresolvableNamesWithSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSNMP;
@@ -229,7 +229,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithNonUniqueNamesWithSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithNonUniqueNamesWithSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSNMP;
@@ -265,7 +265,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithAnyAddressWithoutSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithAnyAddressWithoutSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -296,7 +296,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithAnyAddressWithSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithAnyAddressWithSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -328,7 +328,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithWildcardAddressWithoutSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithWildcardAddressWithoutSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -359,7 +359,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithWildcardAddressWithSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithWildcardAddressWithSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_0/UpgradeSimpleConfigurationFromRHQ3_0_0Test.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_0/UpgradeSimpleConfigurationFromRHQ3_0_0Test.java
index 9fceb54..916ed0f 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_0/UpgradeSimpleConfigurationFromRHQ3_0_0Test.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_0/UpgradeSimpleConfigurationFromRHQ3_0_0Test.java
@@ -73,7 +73,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN}, numberOfInitialDiscoveries = 2)
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithResolvableNamesWithoutSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithResolvableNamesWithoutSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithoutSNMP;
@@ -93,7 +93,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN}, numberOfInitialDiscoveries = 2)
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithUnresolvableNamesWithoutSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithUnresolvableNamesWithoutSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithoutSNMP;
@@ -114,7 +114,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN}, numberOfInitialDiscoveries = 2)
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithNonUniqueNamesWithoutSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithNonUniqueNamesWithoutSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithoutSNMP;
@@ -146,7 +146,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithResolvableNamesWithSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithResolvableNamesWithSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSNMP;
@@ -166,7 +166,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithUnresolvableNamesWithSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithUnresolvableNamesWithSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSNMP;
@@ -192,7 +192,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithNonUniqueNamesWithSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithNonUniqueNamesWithSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSNMP;
@@ -218,7 +218,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithAnyAddressWithoutSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithAnyAddressWithoutSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -257,7 +257,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithAnyAddressWithSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithAnyAddressWithSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -284,7 +284,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithWildcardAddressWithoutSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithWildcardAddressWithoutSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -310,7 +310,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_0Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithWildcardAddressWithSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithWildcardAddressWithSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_1/UpgradeNestedConfigurationFromRHQ3_0_1Test.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_1/UpgradeNestedConfigurationFromRHQ3_0_1Test.java
index 97c1c35..5b5fddc 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_1/UpgradeNestedConfigurationFromRHQ3_0_1Test.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_1/UpgradeNestedConfigurationFromRHQ3_0_1Test.java
@@ -74,7 +74,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithResolvableNamesWithSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithResolvableNamesWithSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSNMP;
@@ -99,7 +99,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithResolvableNamesWithoutSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithResolvableNamesWithoutSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithoutSNMP;
@@ -129,7 +129,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithUnresolvableNamesWithSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithUnresolvableNamesWithSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSNMP;
@@ -160,7 +160,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithUnresolvableNamesWithoutSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithUnresolvableNamesWithoutSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithoutSNMP;
@@ -199,7 +199,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithNonUniqueNamesWithSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithNonUniqueNamesWithSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSNMP;
@@ -230,7 +230,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithNonUniqueNamesWithoutSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithNonUniqueNamesWithoutSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithoutSNMP;
@@ -287,7 +287,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testDuplicateMainVhostsMarkedAsFailedUpgrade(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testDuplicateMainVhostsMarkedAsFailedUpgrade", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithDuplicateMain;
@@ -332,7 +332,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithAnyAddressWithoutSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithAnyAddressWithoutSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -383,7 +383,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithAnyAddressWithSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithAnyAddressWithSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -415,7 +415,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithWildcardAddressWithoutSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithWildcardAddressWithoutSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -452,7 +452,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithWildcardAddressWithSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithWildcardAddressWithSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_1/UpgradeSimpleConfigurationFromRHQ3_0_1Test.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_1/UpgradeSimpleConfigurationFromRHQ3_0_1Test.java
index ffdc62d..16de715 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_1/UpgradeSimpleConfigurationFromRHQ3_0_1Test.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_1/UpgradeSimpleConfigurationFromRHQ3_0_1Test.java
@@ -74,7 +74,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithResolvableNamesWithSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithResolvableNamesWithSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSNMP;
@@ -94,7 +94,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithResolvableNamesWithoutSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithResolvableNamesWithoutSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithoutSNMP;
@@ -139,7 +139,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithUnresolvableNamesWithSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithUnresolvableNamesWithSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSNMP;
@@ -165,7 +165,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithUnresolvableNamesWithoutSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithUnresolvableNamesWithoutSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithoutSNMP;
@@ -194,7 +194,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithNonUniqueNamesWithSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithNonUniqueNamesWithSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSNMP;
@@ -220,7 +220,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testWithNonUniqueNamesWithoutSNMP(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithNonUniqueNamesWithoutSNMP", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithoutSNMP;
@@ -272,7 +272,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path"})
public void testDuplicateMainVhostsMarkedAsFailedUpgrade(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testDuplicateMainVhostsMarkedAsFailedUpgrade", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithDuplicateMain;
@@ -317,7 +317,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithAnyAddressWithoutSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithAnyAddressWithoutSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -363,7 +363,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithAnyAddressWithSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithAnyAddressWithSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -394,7 +394,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithWildcardAddressWithoutSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithWildcardAddressWithoutSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -445,7 +445,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_1Test extends UpgradeTestBase
@PluginContainerSetup(plugins = {PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN})
@Parameters({"apache2.install.dir", "apache2.exe.path" })
public void testWithWildcardAddressWithSNMP(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithWildcardAddressWithSNMP", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_2/UpgradeNestedConfigurationFromRHQ3_0_2Test.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_2/UpgradeNestedConfigurationFromRHQ3_0_2Test.java
index e911667..9539bd2 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_2/UpgradeNestedConfigurationFromRHQ3_0_2Test.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_2/UpgradeNestedConfigurationFromRHQ3_0_2Test.java
@@ -62,7 +62,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_2Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithResolvableNames(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithResolvableNames", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFile;
@@ -82,7 +82,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_2Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithUnresolvableNames(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithUnresolvableNames", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFile;
@@ -113,7 +113,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_2Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithNonUniqueNames(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithNonUniqueNames", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSingleVHost;
@@ -144,7 +144,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_2Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithAnyAddress(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithAnyAddress", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -179,7 +179,7 @@ public class UpgradeNestedConfigurationFromRHQ3_0_2Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithWildcardAddress(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithWildcardAddress", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_2/UpgradeSimpleConfigurationFromRHQ3_0_2Test.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_2/UpgradeSimpleConfigurationFromRHQ3_0_2Test.java
index 3882f8f..0b1e7ac 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_2/UpgradeSimpleConfigurationFromRHQ3_0_2Test.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/rhq3_0_2/UpgradeSimpleConfigurationFromRHQ3_0_2Test.java
@@ -61,7 +61,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_2Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithResolvableNames(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithResolvableNames", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFile;
@@ -76,7 +76,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_2Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithUnresolvableNames(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithUnresolvableNames", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFile;
@@ -102,7 +102,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_2Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithNonUniqueNames(final String installDir, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithNonUniqueNames", new ApacheTestConfiguration() {
{
apacheConfigurationFiles = configuredApacheConfigurationFiles;
inventoryFile = configuredInventoryFileWithSingleVhost;
@@ -128,7 +128,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_2Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithAnyAddress(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithAnyAddress", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
@@ -158,7 +158,7 @@ public class UpgradeSimpleConfigurationFromRHQ3_0_2Test extends UpgradeTestBase
@PluginContainerSetup(plugins = { PluginLocation.PLATFORM_PLUGIN, PluginLocation.AUGEAS_PLUGIN, PluginLocation.APACHE_PLUGIN })
@Parameters({ "apache2.install.dir", "apache2.exe.path" })
public void testWithWildcardAddress(final String installPath, final String exePath) throws Throwable {
- testUpgrade(new ApacheTestConfiguration() {
+ testUpgrade("testWithWildcardAddress", new ApacheTestConfiguration() {
{
configurationName = DEPLOYMENT_SIMPLE_WITH_WILDCARD_LISTENS;
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml
index 56284ce..008588f 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml
@@ -16,6 +16,8 @@
<param name="File" value="target/test.log"/>
<param name="Threshold" value="DEBUG"/>
<param name="Append" value="false"/>
+ <param name="MaxBackupIndex" value="1000" />
+ <param name="MaxFileSize" value="50MB" />
<layout class="org.apache.log4j.PatternLayout">
<param name="ConversionPattern" value="%-5p %d{dd-MM HH:mm:ss,SSS} (%F:%M:%L) -%m%n"/>
</layout>
commit 43724fc53d9c440a4ee9d86ea10d8146f95149fc
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Mon Nov 19 13:33:12 2012 +0100
Backup the apache error logs on per-test-method basis.
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/augeas/AugeasReferenceLeakingTest.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/augeas/AugeasReferenceLeakingTest.java
index 58ac1fc..4a0f7b7 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/augeas/AugeasReferenceLeakingTest.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/augeas/AugeasReferenceLeakingTest.java
@@ -53,7 +53,6 @@ import org.rhq.plugins.apache.PluginLocation;
import org.rhq.plugins.apache.setup.ApacheTestConfiguration;
import org.rhq.plugins.apache.setup.ApacheTestSetup;
import org.rhq.plugins.apache.upgrade.UpgradeTestBase;
-import org.rhq.plugins.apache.util.ApacheExecutionUtil.ExpectedApacheState;
import org.rhq.plugins.apache.util.ResourceTypes;
import org.rhq.test.pc.PluginContainerSetup;
import org.rhq.test.pc.PluginContainerTest;
@@ -169,7 +168,8 @@ public class AugeasReferenceLeakingTest extends BMNGRunner {
}
};
- setup = new ApacheTestSetup(apacheConfig.configurationName, PluginContainerTest.getCurrentMockContext(),
+ setup = new ApacheTestSetup(this.getClass(), apacheConfig.configurationName,
+ PluginContainerTest.getCurrentMockContext(),
new ResourceTypes(PluginLocation.APACHE_PLUGIN));
Resource platform = UpgradeTestBase.discoverPlatform();
@@ -186,7 +186,7 @@ public class AugeasReferenceLeakingTest extends BMNGRunner {
private void stopApache() throws Exception {
if (setup != null) {
- setup.withApacheSetup().getExecutionUtil().invokeOperation(ExpectedApacheState.STOPPED, "stop");
+ setup.withApacheSetup().stopApache();
setup = null;
}
}
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/setup/ApacheTestSetup.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/setup/ApacheTestSetup.java
index e27c394..430f00a 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/setup/ApacheTestSetup.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/setup/ApacheTestSetup.java
@@ -44,6 +44,8 @@ import org.rhq.core.domain.resource.ResourceError;
import org.rhq.core.pc.ServerServices;
import org.rhq.core.pc.upgrade.FakeServerInventory;
import org.rhq.core.system.SystemInfoFactory;
+import org.rhq.core.util.file.FileUtil;
+import org.rhq.plugins.apache.ApacheServerComponent;
import org.rhq.plugins.apache.ApacheServerDiscoveryComponent;
import org.rhq.plugins.apache.ApacheVirtualHostServiceComponent;
import org.rhq.plugins.apache.ApacheVirtualHostServiceDiscoveryComponent;
@@ -71,6 +73,7 @@ public class ApacheTestSetup {
private Map<String, String> inventoryFileReplacements;
private Mockery context;
private ResourceTypes apacheResourceTypes;
+ private Class<?> testClass;
public class ApacheSetup {
private String serverRoot;
@@ -115,6 +118,39 @@ public class ApacheTestSetup {
return this;
}
+ public void startApache() throws Exception {
+ //clear the error log
+ File errorLog = new File(new File(new File(serverRoot), "logs"), "error_log");
+ errorLog.delete();
+
+ getExecutionUtil().invokeOperation(ExpectedApacheState.RUNNING, "start");
+ }
+
+ public void stopApache() throws Exception {
+ getExecutionUtil().invokeOperation(ExpectedApacheState.STOPPED, "stop");
+
+ //save a copy of the error log
+ File errorLog = new File(new File(new File(serverRoot), "logs"), "error_log");
+
+ if (errorLog.exists() && errorLog.canRead()) {
+ String copyName = testClass.getSimpleName() + "-" + configurationName + ".httpd.error_log";
+
+ FileUtil.copyFile(errorLog, new File(new File("target"), copyName));
+ }
+ }
+
+ public void reloadApache() {
+
+ }
+
+ public ApacheServerComponent getServerComponent() {
+ return getExecutionUtil().getServerComponent();
+ }
+
+ public ApacheDirectiveTree getRuntimeConfiguration() {
+ return getExecutionUtil().getRuntimeConfiguration();
+ }
+
public ApacheExecutionUtil getExecutionUtil() {
return execution;
}
@@ -125,11 +161,15 @@ public class ApacheTestSetup {
assertTrue(serverRootDir.exists(), "The configured server root denotes a non-existant directory: '"
+ serverRootDir + "'.");
+ File logsDir = new File(serverRootDir, "logs");
+
+ assertTrue(logsDir.exists(), "The configured server root denotes a directory that doesn't have a 'logs' subdirectory. This is unexpected.");
+
File confDir = new File(serverRootDir, "conf");
assertTrue(confDir.exists(),
"The configured server root denotes a directory that doesn't have a 'conf' subdirectory. This is unexpected.");
-
+
String confFilePath = confDir.getAbsolutePath() + File.separatorChar + "httpd.conf";
String snmpHost = null;
@@ -166,7 +206,7 @@ public class ApacheTestSetup {
private void doSetup() throws Exception {
init();
- execution.invokeOperation(ExpectedApacheState.RUNNING, "start");
+ startApache();
}
public ApacheTestSetup setup() throws Exception {
@@ -174,7 +214,9 @@ public class ApacheTestSetup {
}
}
- public ApacheTestSetup(String configurationName, Mockery context, ResourceTypes apacheResourceTypes) {
+ public ApacheTestSetup(Class<?> testClass, String configurationName, Mockery context,
+ ResourceTypes apacheResourceTypes) {
+ this.testClass = testClass;
this.configurationName = configurationName;
this.context = context;
this.apacheResourceTypes = apacheResourceTypes;
@@ -275,9 +317,9 @@ public class ApacheTestSetup {
ApacheDeploymentUtil.addDefaultVariables(replacements, null);
- HttpdAddressUtility addressUtility = apacheSetup.getExecutionUtil().getServerComponent()
+ HttpdAddressUtility addressUtility = apacheSetup.getServerComponent()
.getAddressUtility();
- ApacheDirectiveTree runtimeConfig = apacheSetup.getExecutionUtil().getRuntimeConfiguration();
+ ApacheDirectiveTree runtimeConfig = apacheSetup.getRuntimeConfiguration();
replacements.put("snmp.identifier",
addressUtility.getHttpdInternalMainServerAddressRepresentation(runtimeConfig).toString(false, false));
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
index 8c0d2eb..9180f2c 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
@@ -62,7 +62,6 @@ import org.rhq.plugins.apache.parser.ApacheDirectiveTree;
import org.rhq.plugins.apache.setup.ApacheTestConfiguration;
import org.rhq.plugins.apache.setup.ApacheTestSetup;
import org.rhq.plugins.apache.util.ApacheDeploymentUtil.DeploymentConfig;
-import org.rhq.plugins.apache.util.ApacheExecutionUtil.ExpectedApacheState;
import org.rhq.plugins.apache.util.ResourceTypes;
import org.rhq.plugins.apache.util.VHostSpec;
import org.rhq.plugins.apache.util.VirtualHostLegacyResourceKeyUtil;
@@ -97,7 +96,8 @@ public class UpgradeTestBase extends PluginContainerTest {
}
protected void testUpgrade(ApacheTestConfiguration testConfiguration) throws Throwable {
- final ApacheTestSetup setup = new ApacheTestSetup(testConfiguration.configurationName, context, apacheResourceTypes);
+ final ApacheTestSetup setup = new ApacheTestSetup(this.getClass(), testConfiguration.configurationName,
+ context, apacheResourceTypes);
boolean testFailed = false;
try {
@@ -193,7 +193,7 @@ public class UpgradeTestBase extends PluginContainerTest {
throw t;
} finally {
try {
- setup.withApacheSetup().getExecutionUtil().invokeOperation(ExpectedApacheState.STOPPED, "stop");
+ setup.withApacheSetup().stopApache();
} catch (Exception e) {
if (testFailed) {
LOG.error("Failed to stop apache.", e);
@@ -209,7 +209,7 @@ public class UpgradeTestBase extends PluginContainerTest {
protected void defineRHQ3ResourceKeys(ApacheTestConfiguration testConfig, ApacheTestSetup setup) throws Exception {
setup.withApacheSetup().init();
- ApacheServerComponent component = setup.withApacheSetup().getExecutionUtil().getServerComponent();
+ ApacheServerComponent component = setup.withApacheSetup().getServerComponent();
ApacheDirectiveTree config = component.parseRuntimeConfiguration(false);
DeploymentConfig deployConfig = setup.getDeploymentConfig();
commit 7f44776f62d66f19332b6f9608ff93a8f8fddd7c
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Mon Nov 19 12:52:42 2012 +0100
Slightly improving logging on apache upgrade tests.
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
index 62efbbe..8c0d2eb 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
@@ -101,6 +101,9 @@ public class UpgradeTestBase extends PluginContainerTest {
boolean testFailed = false;
try {
+ LOG.debug("---------------------------------------------------------- Starting the upgrade test for: "
+ + this.getClass().getSimpleName() + ": " + testConfiguration.configurationName);
+
String[] configFiles = Arrays.copyOf(testConfiguration.apacheConfigurationFiles, testConfiguration.apacheConfigurationFiles.length + 1);
configFiles[testConfiguration.apacheConfigurationFiles.length] = "/snmpd.conf";
@@ -198,6 +201,9 @@ public class UpgradeTestBase extends PluginContainerTest {
throw e;
}
}
+
+ LOG.debug("---------------------------------------------------------- Finished the upgrade test for: "
+ + this.getClass().getSimpleName() + ": " + testConfiguration.configurationName);
}
}
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheExecutionUtil.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheExecutionUtil.java
index ba6df54..64ab1c0 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheExecutionUtil.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheExecutionUtil.java
@@ -46,6 +46,7 @@ import org.rhq.core.pluginapi.inventory.PluginContainerDeployment;
import org.rhq.core.pluginapi.inventory.ProcessScanResult;
import org.rhq.core.pluginapi.inventory.ResourceContext;
import org.rhq.core.pluginapi.inventory.ResourceDiscoveryContext;
+import org.rhq.core.pluginapi.operation.OperationResult;
import org.rhq.core.system.ProcessInfo;
import org.rhq.core.system.SystemInfo;
import org.rhq.core.system.SystemInfoFactory;
@@ -179,8 +180,13 @@ public class ApacheExecutionUtil {
public void invokeOperation(ExpectedApacheState desiredState, String operation) throws Exception {
int i = 0;
+
while (i < 10) {
- serverComponent.invokeOperation(operation, new Configuration());
+ OperationResult res = serverComponent.invokeOperation(operation, new Configuration());
+
+ LOG.debug("Invoked operation '" + operation + "' on " + resourceContext.getResourceKey() + " (waiting for "
+ + desiredState + "), attempt " + i + ": "
+ + res.getComplexResults().getMap().toString());
//wait for max 30s for the operation to "express" itself
int w = 0;
commit 23be83c54ea7c50393c99834bdb0a22136ecb42e
Author: Heiko W. Rupp <hwr(a)redhat.com>
Date: Mon Nov 19 12:01:12 2012 +0100
BZ 861239 - add a flush() so that getting the live availability works.
diff --git a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerBean.java b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerBean.java
index a016f8e..053d5c9 100644
--- a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerBean.java
+++ b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerBean.java
@@ -276,7 +276,7 @@ public class ResourceManagerBean implements ResourceManagerLocal, ResourceManage
// make sure the user is authorized to delete this resource (which implies you can delete all its children)
// TODO: There is a pretty good argument for this being replaced with MANAGE_INVENTORY. It takes an
// inventory manager to import resources, so why not to remove them? But, since no one has complained
- // we're timid about making a change that may hamstring existing setups.
+ // we're timid about making a change that may hamstring existing setups.
if (!authorizationManager.hasResourcePermission(user, Permission.DELETE_RESOURCE, resourceId)) {
throw new PermissionException("You do not have permission to uninventory resource [" + resourceId + "]");
}
@@ -371,8 +371,8 @@ public class ResourceManagerBean implements ResourceManagerLocal, ResourceManage
}
}
- // now remove the dommed agent. Call flush() to force out any problems with agent removal
- // so that we can catch them and report a better exception.
+ // now remove the doomed agent. Call flush() to force out any problems with agent removal
+ // so that we can catch them and report a better exception.
if (doomedAgent != null) {
agentManager.deleteAgent(doomedAgent);
entityManager.flush();
@@ -517,7 +517,7 @@ public class ResourceManagerBean implements ResourceManagerLocal, ResourceManage
PluginConfigurationUpdate.QUERY_DELETE_BY_RESOURCES_2, // then delete the config objects
PluginConfigurationUpdate.QUERY_DELETE_BY_RESOURCES_3, // then the history objects wrapping those configs
AlertConditionLog.QUERY_DELETE_BY_RESOURCES, // Don't
- AlertConditionLog.QUERY_DELETE_BY_RESOURCES_BULK_DELETE, // alter
+ AlertConditionLog.QUERY_DELETE_BY_RESOURCES_BULK_DELETE, // alter
AlertNotificationLog.QUERY_DELETE_BY_RESOURCES, // the
Alert.QUERY_DELETE_BY_RESOURCES, // order
AlertCondition.QUERY_DELETE_BY_RESOURCES, // of
@@ -885,7 +885,7 @@ public class ResourceManagerBean implements ResourceManagerLocal, ResourceManage
/**
* Get the complete set of resource type Ids in the ancestries provided. This is useful for
* being able to load all the types in advance of generating decoded values.
- *
+ *
* @return
*/
private HashSet<Integer> getAncestryTypeIds(Collection<String> ancestries) {
@@ -2353,6 +2353,7 @@ public class ResourceManagerBean implements ResourceManagerLocal, ResourceManage
if (avail != null) {
results.setAvailabilityType(avail.getAvailabilityType());
}
+ entityManager.flush();
}
} catch (Throwable ignore) {
}
@@ -2637,7 +2638,7 @@ public class ResourceManagerBean implements ResourceManagerLocal, ResourceManage
// make sure the user is authorized to disable this resource (which implies you can disable all its children)
// TODO: this may require its own permission, but until someone needs it we'll piggyback on DELETE, at least
- // that gives a resource-level permission option.
+ // that gives a resource-level permission option.
if (!authorizationManager.hasResourcePermission(subject, Permission.DELETE_RESOURCE, resourceId)) {
throw new PermissionException("You do not have permission to disable resource [" + resourceId + "]");
}
@@ -2680,7 +2681,7 @@ public class ResourceManagerBean implements ResourceManagerLocal, ResourceManage
// Set the resources disabled via the standard mergeInventoryReport mechanism, from the server service
// level. We do this for a few reasons:
// - The server service uses locking to ensure we don't conflict with an actual report from the agent
- // - It ensure all necessary db modications take place, like avail history and current avail
+ // - It ensure all necessary db modifications take place, like avail history and current avail
// - It ensures that all ancillary avail change logic, like alerting, still happens.
DiscoveryServerServiceImpl service = new DiscoveryServerServiceImpl();
for (AvailabilityReport report : reports.values()) {
@@ -2715,7 +2716,7 @@ public class ResourceManagerBean implements ResourceManagerLocal, ResourceManage
// make sure the user is authorized to enable this resource (which implies you can enable all its children)
// TODO: this may require its own permission, but until someone needs it we'll piggyback on DELETE, at least
- // that gives a resource-level permission option.
+ // that gives a resource-level permission option.
if (!authorizationManager.hasResourcePermission(subject, Permission.DELETE_RESOURCE, resourceId)) {
throw new PermissionException("You do not have permission to enable resource [" + resourceId + "]");
}
@@ -2757,7 +2758,7 @@ public class ResourceManagerBean implements ResourceManagerLocal, ResourceManage
// Set the resources disabled via the standard mergeInventoryReport mechanism, from the server service
// level. We do this for a few reasons:
// - The server service uses locking to ensure we don't conflict with an actual report from the agent
- // - It ensure all necessary db modications take place, like avail history and current avail
+ // - It ensure all necessary db modifications take place, like avail history and current avail
// - It ensures that all ancillary avail change logic, like alerting, still happens.
DiscoveryServerServiceImpl service = new DiscoveryServerServiceImpl();
for (AvailabilityReport report : reports.values()) {
commit 4a93caa8696e880fb0ce8c961cf98402b4a2827b
Author: Heiko W. Rupp <hwr(a)redhat.com>
Date: Mon Nov 19 10:43:39 2012 +0100
Add Thomas as developer and mark Ian as retired
diff --git a/pom.xml b/pom.xml
index eeaac9c..cefbe69 100644
--- a/pom.xml
+++ b/pom.xml
@@ -72,7 +72,7 @@
<jboss-javassist.version>3.9.0.GA</jboss-javassist.version>
<jbossws-native-dist.version>3.1.1.GA</jbossws-native-dist.version>
<!-- End: JBoss AS Dependency Versions -->
-
+
<commons-logging.version>1.1.0.jboss</commons-logging.version>
<concurrent.version>1.3.4-jboss-update1</concurrent.version> <!-- oswego-concurrent compatible with 4.2.3.GA -->
<findbugs.version>2.3.2</findbugs.version>
@@ -118,7 +118,7 @@
Arquillian integration, and works with jacoco (as opposed to javassist 3.9.0,
which doesn't in some cases.) -->
<javassist.version>3.16.1-GA</javassist.version>
-
+
<rhq.db.admin.username>rhqadmin</rhq.db.admin.username>
<rhq.db.admin.password>rhqadmin</rhq.db.admin.password>
@@ -608,7 +608,7 @@
</exclusions>
</dependency>
</dependencies>
-
+
<executions>
<execution>
<id>pre-create target/classes</id>
@@ -774,7 +774,7 @@
</exclusions>
</configuration>
</plugin>
-
+
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>clirr-maven-plugin</artifactId>
@@ -786,7 +786,7 @@
<artifactId>jacoco-maven-plugin</artifactId>
<version>${jacoco.version}</version>
</plugin>
- </plugins>
+ </plugins>
</pluginManagement>
@@ -1135,7 +1135,7 @@
</plugin>
</plugins>
- </build>
+ </build>
<repositories>
@@ -1234,7 +1234,7 @@
<jacoco.integration-test.args></jacoco.integration-test.args>
</properties>
</profile>
-
+
<profile>
<id>code-coverage</id>
<activation>
@@ -1263,7 +1263,7 @@
<include>org.rhq.*</include>
</includes>
</configuration>
- </execution>
+ </execution>
<execution>
<id>prepare-agent-for-integration-tests</id>
<phase>pre-integration-test</phase>
@@ -1399,7 +1399,7 @@
</plugins>
</build>
</profile>
-
+
<!-- NOTE: This profile is extended upon in several other submodules.
If you need to change its activation policy, make sure to do that in
*ALL* the modules that define this profile. -->
@@ -1409,16 +1409,16 @@
<property>
<!-- we want this always active but activeByDefault doesn't work -->
<!-- see http://maven.apache.org/guides/introduction/introduction-to-profiles.html -->
- <name>java.home</name>
+ <name>java.home</name>
</property>
</activation>
-
+
<!-- Can be used to pass a flag down to deployment composing ANT scripts and somesuch -->
<properties>
<rhq.bundle-additional-script-languages>true</rhq.bundle-additional-script-languages>
- </properties>
+ </properties>
</profile>
-
+
<profile>
<id>ojdbc-driver</id>
<activation>
@@ -1617,7 +1617,7 @@
</configuration>
</plugin>
</plugins>
- </reporting>
+ </reporting>
</profile>
<profile>
@@ -1625,7 +1625,7 @@
<property>
<name>generate-dependency-graph</name>
<value>true</value>
- </property>
+ </property>
</activation>
<reporting>
@@ -1638,7 +1638,7 @@
</configuration>
</plugin>
</plugins>
- </reporting>
+ </reporting>
</profile>
</profiles>
@@ -1652,8 +1652,8 @@
<reportSet>
</reportSet>
</reportSets>
- </plugin>
-
+ </plugin>
+
<!--
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
@@ -1850,6 +1850,10 @@
</roles>
</developer>
<developer>
+ <name>Thomas Segismont</name>
+ <timezone>+1</timezone>
+ </developer>
+ <developer>
<name>Jay Shaughnessy</name>
<timezone>-5</timezone>
</developer>
@@ -1857,6 +1861,9 @@
<name>Ian Springer</name>
<timezone>-5</timezone>
<url>http://freshjava.blogspot.com/</url>
+ <roles>
+ <role>retired</role>
+ </roles>
</developer>
<developer>
<name>Mike Thompson</name>
11 years, 5 months
[rhq] Branch 'rhq-on-as7' - modules/enterprise
by Jay Shaughnessy
modules/enterprise/pom.xml | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
New commits:
commit f2656e519f786e28ae4c6075210f0f62bbb261e6
Author: Jay Shaughnessy <jshaughn(a)jshaughn.csb>
Date: Sat Nov 24 15:56:44 2012 -0500
replace server/itests with server/itests-2 in server modules
diff --git a/modules/enterprise/pom.xml b/modules/enterprise/pom.xml
index 6f85add..4e935ec 100644
--- a/modules/enterprise/pom.xml
+++ b/modules/enterprise/pom.xml
@@ -41,7 +41,7 @@
<module>binding</module>
<module>scripting</module>
<module>server/client-api</module>
- <module>server/itests</module>
+ <module>server/itests-2</module>
</modules>
</profile>
@@ -70,7 +70,7 @@
<module>server/startup-subsystem</module>
<module>server/appserver</module>
<module>server/client-api</module>
- <module>server/itests</module>
+ <module>server/itests-2</module>
</modules>
</profile>
11 years, 5 months
[rhq] Branch 'rhq-on-as7' - 3 commits - modules/core modules/enterprise modules/helpers modules/plugins pom.xml
by Jay Shaughnessy
dev/null |binary
modules/core/domain/pom.xml | 4
modules/enterprise/comm/pom.xml | 1
modules/enterprise/server/itests-2/pom.xml | 4
modules/enterprise/server/itests/pom.xml | 384 ----------
modules/enterprise/server/itests/src/test/resources/META-INF/ejb-jar.xml | 28
modules/enterprise/server/itests/src/test/resources/default.persistence.properties | 22
modules/enterprise/server/itests/src/test/resources/ejb3-interceptors-aop.xml | 360 ---------
modules/enterprise/server/itests/src/test/resources/embedded-jboss-beans.xml | 168 ----
modules/enterprise/server/itests/src/test/resources/jboss-jms-beans.xml | 132 ---
modules/enterprise/server/itests/src/test/resources/jndi.properties | 2
modules/enterprise/server/itests/src/test/resources/log4j.xml | 74 -
modules/enterprise/server/itests/src/test/resources/login-config.xml | 72 -
modules/enterprise/server/itests/src/test/resources/rhq-mdb-beans.xml | 25
modules/enterprise/server/itests/src/test/resources/security-beans.xml | 13
modules/enterprise/server/itests/src/test/resources/security.policy | 10
modules/enterprise/server/itests/src/test/resources/test-alert-sender-serverplugin.xml | 23
modules/enterprise/server/itests/src/test/resources/test-assist-color-number.txt | 46 -
modules/enterprise/server/itests/src/test/resources/test-ldap.properties | 2
modules/enterprise/server/itests/src/test/resources/test-scheduler.properties | 29
modules/enterprise/server/itests/src/test/resources/testng.xml | 12
modules/enterprise/server/jar/pom.xml | 3
modules/enterprise/server/plugins/alert-operations/pom.xml | 1
modules/helpers/rtfilter-subsystem/pom.xml | 2
modules/helpers/rtfilter/pom.xml | 2
modules/plugins/rhq-server/pom.xml | 2
pom.xml | 21
27 files changed, 23 insertions(+), 1419 deletions(-)
New commits:
commit 9c0be7ffa255126f90321417ac11fd74fa237a1f
Author: Jay Shaughnessy <jshaughn(a)jshaughn.csb>
Date: Sat Nov 24 15:42:48 2012 -0500
remove the obsolete enterprise/server/itests module
diff --git a/modules/enterprise/server/itests/pom.xml b/modules/enterprise/server/itests/pom.xml
deleted file mode 100644
index c0585f8..0000000
--- a/modules/enterprise/server/itests/pom.xml
+++ /dev/null
@@ -1,384 +0,0 @@
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
-
- <modelVersion>4.0.0</modelVersion>
-
- <parent>
- <groupId>org.rhq</groupId>
- <artifactId>rhq-parent</artifactId>
- <version>4.6.0-SNAPSHOT</version>
- <relativePath>../../../../pom.xml</relativePath>
- </parent>
-
- <artifactId>rhq-server-itests</artifactId>
-
- <name>RHQ Server Integration Tests</name>
- <description>RHQ enterprise server integration tests</description>
-
- <scm>
- <connection>scm:git:ssh://git.fedorahosted.org/git/rhq.git/modules/enterprise/server/...</connection>
- <developerConnection>scm:git:ssh://git.fedorahosted.org/git/rhq.git/modules/enterprise/server/...</developerConnection>
- </scm>
-
- <properties>
- <rhq.server.datasource>java:/RHQDS</rhq.server.datasource>
- <rhq.server.ds-mapping>PostgreSQL</rhq.server.ds-mapping>
- <!-- <jboss-embeddable-ejb3.version>1.0.0.Alpha9</jboss-embeddable-ejb3.version> -->
- </properties>
-
- <dependencies>
- <!--================ Test Deps ================-->
-
- <!-- Note, the test deps are intentionally placed above the other scoped deps because of classpath
- reasons. Maven orders the [test] classpath in the order listed in the pom. We specifically
- need the embeddable-ejb3 jar above the standard ejb3 jars because we need the embeddble packages
- loaded when testing. -->
-
- <dependency>
- <groupId>org.jboss.spec</groupId>
- <artifactId>jboss-javaee-6.0</artifactId>
- <version>${jboss.javaee6.spec.version}</version>
- <scope>provided</scope>
- <type>pom</type>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.as</groupId>
- <artifactId>jboss-as-arquillian-container-managed</artifactId>
- <version>${jboss.version}</version>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.arquillian.testng</groupId>
- <artifactId>arquillian-testng-container</artifactId>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.shrinkwrap</groupId>
- <artifactId>shrinkwrap-impl-base</artifactId>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.shrinkwrap.resolver</groupId>
- <artifactId>shrinkwrap-resolver-api</artifactId>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.shrinkwrap.resolver</groupId>
- <artifactId>shrinkwrap-resolver-api-maven</artifactId>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.shrinkwrap.resolver</groupId>
- <artifactId>shrinkwrap-resolver-impl-maven</artifactId>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.arquillian.protocol</groupId>
- <artifactId>arquillian-protocol-servlet</artifactId>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.rhq</groupId>
- <artifactId>test-utils</artifactId>
- <version>${project.version}</version>
- <scope>test</scope>
- <exclusions>
- <exclusion>
- <groupId>org.testng</groupId>
- <artifactId>testng</artifactId>
- </exclusion>
- </exclusions>
- </dependency>
-
- <dependency>
- <groupId>org.rhq</groupId>
- <artifactId>rhq-core-domain</artifactId>
- <version>${project.version}</version>
- <type>test-jar</type>
- <scope>test</scope>
- </dependency>
-
-<!--
- <dependency>
- <groupId>org.rhq</groupId>
- <artifactId>rhq-container-lib</artifactId>
- <version>${project.version}</version>
- <scope>test</scope>
- </dependency>
- -->
- <dependency>
- <groupId>org.rhq</groupId>
- <artifactId>rhq-enterprise-server</artifactId>
- <version>${project.version}</version>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.rhq</groupId>
- <artifactId>rhq-enterprise-server</artifactId>
- <version>${project.version}</version>
- <type>test-jar</type>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>${project.groupId}</groupId>
- <artifactId>rhq-core-client-api</artifactId>
- <version>${project.version}</version>
- <type>test-jar</type>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.rhq</groupId>
- <artifactId>rhq-script-bindings</artifactId>
- <version>${project.version}</version>
- <scope>test</scope>
- <exclusions>
- <exclusion>
- <groupId>org.rhq</groupId>
- <artifactId>rhq-enterprise-server</artifactId>
- </exclusion>
- </exclusions>
- </dependency>
-
- <dependency>
- <groupId>org.rhq</groupId>
- <artifactId>rhq-scripting-javascript</artifactId>
- <version>${project.version}</version>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.rhq</groupId>
- <artifactId>rhq-server-client-api</artifactId>
- <version>${project.version}</version>
- <scope>test</scope>
- <exclusions>
- <exclusion>
- <groupId>org.rhq</groupId>
- <artifactId>rhq-enterprise-server</artifactId>
- </exclusion>
- </exclusions>
- </dependency>
-
- <dependency>
- <groupId>org.rhq.helpers</groupId>
- <artifactId>perftest-support</artifactId>
- <version>${project.version}</version>
- <scope>test</scope>
- <exclusions>
- <exclusion>
- <groupId>ant</groupId>
- <artifactId>ant</artifactId>
- </exclusion>
- <exclusion>
- <groupId>ant</groupId>
- <artifactId>ant-launcher</artifactId>
- </exclusion>
- </exclusions>
- </dependency>
-
-<!--
- <dependency>
- <groupId>jboss.jboss-embeddable-ejb3</groupId>
- <artifactId>jboss-ejb3-all</artifactId>
- <version>${jboss-embeddable-ejb3.version}</version>
- <scope>test</scope>
- </dependency>
- -->
-
- <!-- Shrinkwrap to build up test plugins etc. -->
- <dependency>
- <groupId>org.jboss.shrinkwrap</groupId>
- <artifactId>shrinkwrap-api</artifactId>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.shrinkwrap</groupId>
- <artifactId>shrinkwrap-impl-base</artifactId>
- <scope>compile</scope>
- </dependency>
-
- <!-- NOTE: The remaining test deps correspond to the classes contained in hibernate-all.jar and thirdparty-all.jar. -->
-
- <dependency>
- <groupId>org.javassist</groupId>
- <artifactId>javassist</artifactId>
- <scope>test</scope>
- </dependency>
-
- <!-- needed by embedded ejb container -->
- <dependency>
- <groupId>trove</groupId>
- <artifactId>trove</artifactId>
- <version>1.0.2</version>
- <scope>test</scope>
- </dependency>
-
- <!-- needed by embedded ejb container -->
- <dependency>
- <groupId>xerces</groupId>
- <artifactId>xercesImpl</artifactId>
- <version>${xercesImpl.version}</version>
- <scope>test</scope>
- </dependency>
-
- <!-- 3rd Party Deps -->
-
- <!-- required by RHQ server classes, as well as EJB3 Embedded -->
- <dependency>
- <groupId>dom4j</groupId>
- <artifactId>dom4j</artifactId>
- <version>1.6.1-jboss</version>
- <scope>runtime</scope>
- </dependency>
-
- <dependency>
- <groupId>javax.mail</groupId>
- <artifactId>mail</artifactId>
- <version>1.4</version>
- </dependency>
-
- <dependency>
- <groupId>javax.servlet</groupId>
- <artifactId>servlet-api</artifactId>
- <version>2.4</version>
- <scope>provided</scope> <!-- by JBossAS -->
- </dependency>
-
- <dependency>
- <groupId>org.opensymphony.quartz</groupId>
- <artifactId>quartz</artifactId>
- <!-- NOTE: The version is defined in the root POM's dependencyManagement section. -->
- <scope>provided</scope> <!-- by JBossAS itself, which the container build has packaged with 1.6.5 -->
- </dependency>
-
- <dependency>
- <groupId>org.opensymphony.quartz</groupId>
- <artifactId>quartz-oracle</artifactId>
- <!-- NOTE: The version is defined in the root POM's dependencyManagement section. -->
- <scope>provided</scope> <!-- by JBossAS itself, which the container build has packaged with 1.6.5 -->
- </dependency>
-
- <!-- This is needed cglib which is in turn needed by hibernate -->
- <dependency>
- <groupId>org.easymock</groupId>
- <artifactId>easymockclassextension</artifactId>
- <version>2.2</version>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.freemarker</groupId>
- <artifactId>freemarker</artifactId>
- <version>2.3.18</version>
- <scope>provided</scope>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.resteasy</groupId>
- <artifactId>resteasy-jaxrs</artifactId>
- <version>${resteasy.version}</version>
- </dependency>
-
- <!-- Dependencies for RHQ components needed for integration tests -->
- <dependency>
- <groupId>${project.groupId}</groupId>
- <artifactId>rhq-serverplugin-drift</artifactId>
- <version>${project.version}</version>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.powermock</groupId>
- <artifactId>powermock-module-testng</artifactId>
- <version>${powermock.version}</version>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.powermock</groupId>
- <artifactId>powermock-api-mockito</artifactId>
- <version>${powermock.version}</version>
- <scope>test</scope>
- </dependency>
- </dependencies>
-
-
- <build>
- <testResources>
- <testResource>
- <directory>src/test/resources</directory>
- <filtering>true</filtering>
- </testResource>
- </testResources>
-
- <plugins>
- <plugin>
- <artifactId>maven-antrun-plugin</artifactId>
- <executions>
- <!-- in order to get JMS to work properly in embedded test container, extract jms-rs.rar classes -->
- <execution>
- <id>Extract JMS classes from RAR needed for JMS tests</id>
- <phase>process-classes</phase>
- <configuration>
- <target>
- <unzip src="src/test/resources/jms-ra.rar" dest="target">
- <patternset>
- <include name="jms-ra.jar"/>
- </patternset>
- </unzip>
- <unzip src="target/jms-ra.jar" dest="target/test-classes">
- <patternset>
- <include name="org/**"/>
- </patternset>
- </unzip>
- </target>
- </configuration>
- <goals>
- <goal>run</goal>
- </goals>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <artifactId>maven-surefire-plugin</artifactId>
- <!-- Everything but the web service tests, this is the standard test execution -->
- <configuration>
- <excludedGroups>${rhq.testng.excludedGroups}</excludedGroups>
- <groups>${rhq.testng.includedGroups}</groups>
- <properties>
- <property>
- <name>listener</name>
- <value>org.rhq.test.testng.StdoutReporter</value>
- </property>
- </properties>
- <systemPropertyVariables>
- <embeddedDeployment>true</embeddedDeployment>
- <deploymentDirectory>target/test-classes</deploymentDirectory>
- <hibernate.dialect>${rhq.test.ds.hibernate-dialect}</hibernate.dialect>
- </systemPropertyVariables>
- <systemProperties>
- <property>
- <name>projectVersion</name>
- <value>${project.version}</value>
- </property>
- </systemProperties>
- <argLine>${jacoco.unit-test.args} -Djava.security.manager -Djava.security.policy==${basedir}/target/test-classes/security.policy</argLine>
- <additionalClasspathElements>
- <!-- The below is required for tests to run against Oracle. -->
- <additionalClasspathElement>${settings.localRepository}/com/oracle/ojdbc6/${ojdbc6.version}/ojdbc6-${ojdbc6.version}.jar</additionalClasspathElement>
- </additionalClasspathElements>
- </configuration>
- </plugin>
- </plugins>
- </build>
-</project>
diff --git a/modules/enterprise/server/itests/src/test/resources/META-INF/ejb-jar.xml b/modules/enterprise/server/itests/src/test/resources/META-INF/ejb-jar.xml
deleted file mode 100644
index 8222948..0000000
--- a/modules/enterprise/server/itests/src/test/resources/META-INF/ejb-jar.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<ejb-jar xmlns="http://java.sun.com/xml/ns/javaee"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
- version="3.0">
-
- <description>RHQ</description>
- <display-name>RHQ</display-name>
-
- <assembly-descriptor>
-
- <!-- all our EJB3 SLSBs can define custom @RequiredPermissions annotations for authorization checks-->
- <interceptor-binding>
- <ejb-name>*</ejb-name>
- <interceptor-class>org.rhq.enterprise.server.authz.RequiredPermissionsInterceptor</interceptor-class>
- </interceptor-binding>
- <interceptor-binding>
- <ejb-name>*</ejb-name>
- <interceptor-class>org.rhq.enterprise.server.common.TransactionInterruptInterceptor</interceptor-class>
- </interceptor-binding>
- <interceptor-binding>
- <ejb-name>*</ejb-name>
- <interceptor-class>org.rhq.enterprise.server.common.PerformanceMonitorInterceptor</interceptor-class>
- </interceptor-binding>
-
- </assembly-descriptor>
-
-</ejb-jar>
diff --git a/modules/enterprise/server/itests/src/test/resources/binary-blob-sample.jar b/modules/enterprise/server/itests/src/test/resources/binary-blob-sample.jar
deleted file mode 100644
index 0a629ec..0000000
Binary files a/modules/enterprise/server/itests/src/test/resources/binary-blob-sample.jar and /dev/null differ
diff --git a/modules/enterprise/server/itests/src/test/resources/default.persistence.properties b/modules/enterprise/server/itests/src/test/resources/default.persistence.properties
deleted file mode 100644
index 8e4f317..0000000
--- a/modules/enterprise/server/itests/src/test/resources/default.persistence.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-hibernate.transaction.manager_lookup_class=org.hibernate.transaction.JBossTransactionManagerLookup
-#hibernate.connection.release_mode=after_statement
-#hibernate.transaction.flush_before_completion=false
-#hibernate.transaction.auto_close_session=false
-#hibernate.query.factory_class=org.hibernate.hql.ast.ASTQueryTranslatorFactory
-#hibernate.hbm2ddl.auto=create-drop
-#hibernate.hbm2ddl.auto=create
-hibernate.cache.provider_class=org.hibernate.cache.HashtableCacheProvider
-# Clustered cache with TreeCache
-#hibernate.cache.provider_class=org.jboss.ejb3.entity.TreeCacheProviderHook
-#hibernate.treecache.mbean.object_name=jboss.cache:service=EJB3EntityTreeCache
-#hibernate.dialect=org.hibernate.dialect.HSQLDialect
-hibernate.jndi.java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
-hibernate.jndi.java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces
-hibernate.bytecode.use_reflection_optimizer=false
-# I don't think this is honored, but EJB3Deployer uses it
-hibernate.bytecode.provider=javassist
-hibernate.jdbc.use_streams_for_binary=true
-hibernate.show_sql=false
-hibernate.format_sql=true
-hibernate.default_batch_fetch_size=16
-hibernate.jdbc.batch_size=20
diff --git a/modules/enterprise/server/itests/src/test/resources/ejb3-interceptors-aop.xml b/modules/enterprise/server/itests/src/test/resources/ejb3-interceptors-aop.xml
deleted file mode 100644
index f30aa70..0000000
--- a/modules/enterprise/server/itests/src/test/resources/ejb3-interceptors-aop.xml
+++ /dev/null
@@ -1,360 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE aop PUBLIC
- "-//JBoss//DTD JBOSS AOP 1.0//EN"
- "http://www.jboss.org/aop/dtd/jboss-aop_1_0.dtd">
-
-<aop>
- <interceptor class="org.jboss.aspects.remoting.InvokeRemoteInterceptor" scope="PER_VM"/>
- <interceptor class="org.jboss.aspects.security.SecurityClientInterceptor" scope="PER_VM"/>
- <interceptor class="org.jboss.aspects.tx.ClientTxPropagationInterceptor" scope="PER_VM"/>
- <interceptor class="org.jboss.ejb3.remoting.IsLocalInterceptor" scope="PER_VM"/>
- <interceptor class="org.jboss.aspects.remoting.ClusterChooserInterceptor" scope="PER_VM"/>
-
- <interceptor class="org.jboss.aspects.tx.TxPropagationInterceptor" scope="PER_VM"/>
-
- <stack name="ServiceClientInterceptors">
- <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
- </stack>
-
- <stack name="AsynchronousStatelessSessionClientInterceptors">
- <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
- </stack>
-
- <stack name="AsynchronousStatefulSessionClientInterceptors">
- <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
- </stack>
-
- <stack name="StatelessSessionClientInterceptors">
- <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
- </stack>
-
- <stack name="StatefulSessionClientInterceptors">
- <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
- </stack>
-
- <stack name="ClusteredStatelessSessionClientInterceptors">
- <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.remoting.ClusterChooserInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
- </stack>
-
- <stack name="ClusteredStatefulSessionClientInterceptors">
- <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.remoting.ClusterChooserInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
- </stack>
-
- <interceptor class="org.jboss.ejb3.asynchronous.AsynchronousInterceptor" scope="PER_CLASS"/>
- <interceptor class="org.jboss.ejb3.ENCPropagationInterceptor" scope="PER_VM"/>
- <interceptor name="Basic Authorization" factory="org.jboss.ejb3.security.RoleBasedAuthorizationInterceptorFactory" scope="PER_CLASS"/>
- <interceptor name="JACC Authorization" factory="org.jboss.ejb3.security.JaccAuthorizationInterceptorFactory" scope="PER_CLASS"/>
- <interceptor factory="org.jboss.ejb3.security.AuthenticationInterceptorFactory" scope="PER_CLASS"/>
- <interceptor factory="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory" scope="PER_CLASS"/>
- <interceptor class="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor" scope="PER_VM"/>
- <interceptor class="org.jboss.ejb3.stateless.StatelessInstanceInterceptor" scope="PER_VM"/>
- <interceptor class="org.jboss.ejb3.stateful.StatefulInstanceInterceptor" scope="PER_VM"/>
- <interceptor class="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor" scope="PER_VM"/>
- <interceptor class="org.jboss.ejb3.service.ServiceSingletonInterceptor" scope="PER_VM"/>
- <interceptor class="org.jboss.ejb3.cache.StatefulReplicationInterceptor" scope="PER_VM"/>
- <interceptor factory="org.jboss.ejb3.stateful.StatefulRemoveFactory" scope="PER_CLASS_JOINPOINT"/>
- <interceptor factory="org.jboss.ejb3.tx.TxInterceptorFactory" scope="PER_CLASS_JOINPOINT"/>
- <interceptor factory="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory" scope="PER_CLASS_JOINPOINT"/>
- <interceptor factory="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory" scope="PER_CLASS"/>
- <interceptor class="org.jboss.ejb3.AllowedOperationsInterceptor" scope="PER_VM"/>
- <interceptor factory="org.jboss.ejb3.mdb.CurrentMessageInjectorInterceptorFactory" scope="PER_CLASS"/>
- <interceptor class="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor" scope="PER_VM"/>
-
- <domain name="Stateless Bean">
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
- <interceptor-ref name="Basic Authorization"/>
- </bind>
- <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
- <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
- <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
- <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
- </bind>
- <annotation expr="!class((a)org.jboss.annotation.ejb.PoolClass)">
- @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
- </annotation>
- </domain>
-
- <domain name="JACC Stateless Bean">
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
- <interceptor-ref name="JACC Authorization"/>
- </bind>
- <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
- <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
- <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
- <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
- </bind>
- <annotation expr="!class((a)org.jboss.annotation.ejb.PoolClass)">
- @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
- </annotation>
- </domain>
-
- <domain name="Base Stateful Bean">
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
- <interceptor-ref name="Basic Authorization"/>
- </bind>
- <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
- <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
- <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * *->@javax.ejb.Remove(..))">
- <interceptor-ref name="org.jboss.ejb3.stateful.StatefulRemoveFactory"/>
- </bind>
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.stateful.StatefulInstanceInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
- <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
- </bind>
- <bind pointcut="execution(public * $instanceof{javax.ejb.SessionSynchronization}->*(..))">
- <interceptor-ref name="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor"/>
- </bind>
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
- </bind>
-
- <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..)) AND !execution(public * *->@javax.ejb.Remove(..))">
- <interceptor-ref name="org.jboss.ejb3.cache.StatefulReplicationInterceptor"/>
- </bind>
- <annotation expr="!class((a)org.jboss.annotation.ejb.PoolClass)">
- @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
- </annotation>
- </domain>
-
- <domain name="Stateful Bean" extends="Base Stateful Bean" inheritBindings="true">
- <!-- NON Clustered cache configuration -->
- <annotation expr="!class((a)org.jboss.annotation.ejb.cache.Cache) AND !class((a)org.jboss.annotation.ejb.Clustered)">
- @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.simple.SimpleStatefulCache.class)
- </annotation>
- <annotation expr="!class((a)org.jboss.annotation.ejb.cache.simple.PersistenceManager) AND !class((a)org.jboss.annotation.ejb.Clustered)">
- @org.jboss.annotation.ejb.cache.simple.PersistenceManager (org.jboss.ejb3.cache.simple.StatefulSessionFilePersistenceManager.class)
- </annotation>
- <annotation expr="!class((a)org.jboss.annotation.ejb.cache.simple.CacheConfig) AND !class((a)org.jboss.annotation.ejb.Clustered)">
- @org.jboss.annotation.ejb.cache.simple.CacheConfig (maxSize=100000, idleTimeoutSeconds=300)
- </annotation>
-
- <!-- Clustered cache configuration -->
- <annotation expr="!class((a)org.jboss.annotation.ejb.cache.Cache) AND class((a)org.jboss.annotation.ejb.Clustered)">
- @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.tree.StatefulTreeCache.class)
- </annotation>
- <annotation expr="!class((a)org.jboss.annotation.ejb.cache.tree.CacheConfig) AND class((a)org.jboss.annotation.ejb.Clustered)">
- @org.jboss.annotation.ejb.cache.tree.CacheConfig (name="jboss.cache:service=EJB3SFSBClusteredCache", maxSize=100000, idleTimeoutSeconds=300)
- </annotation>
- </domain>
-
- <domain name="JACC Stateful Bean">
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
- <interceptor-ref name="JACC Authorization"/>
- </bind>
- <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
- <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
- <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * *->@javax.ejb.Remove(..))">
- <interceptor-ref name="org.jboss.ejb3.stateful.StatefulRemoveFactory"/>
- </bind>
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.stateful.StatefulInstanceInterceptor"/>
- <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
- <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
- </bind>
- <bind pointcut="execution(public * $instanceof{javax.ejb.SessionSynchronization}->*(..))">
- <interceptor-ref name="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor"/>
- </bind>
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
- </bind>
-
- <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..)) AND !execution(public * *->@javax.ejb.Remove(..))">
- <interceptor-ref name="org.jboss.ejb3.cache.StatefulReplicationInterceptor"/>
- </bind>
- <annotation expr="!class((a)org.jboss.annotation.ejb.PoolClass)">
- @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
- </annotation>
-
- <!-- NON Clustered cache configuration -->
- <annotation expr="!class((a)org.jboss.annotation.ejb.cache.Cache) AND !class((a)org.jboss.annotation.ejb.Clustered)">
- @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.simple.SimpleStatefulCache.class)
- </annotation>
- <annotation expr="!class((a)org.jboss.annotation.ejb.cache.simple.PersistenceManager) AND !class((a)org.jboss.annotation.ejb.Clustered)">
- @org.jboss.annotation.ejb.cache.simple.PersistenceManager (org.jboss.ejb3.cache.simple.StatefulSessionFilePersistenceManager.class)
- </annotation>
- <annotation expr="!class((a)org.jboss.annotation.ejb.cache.simple.CacheConfig) AND !class((a)org.jboss.annotation.ejb.Clustered)">
- @org.jboss.annotation.ejb.cache.simple.CacheConfig (maxSize=100000, idleTimeoutSeconds=300)
- </annotation>
-
- <!-- Clustered cache configuration -->
- <annotation expr="!class((a)org.jboss.annotation.ejb.cache.Cache) AND class((a)org.jboss.annotation.ejb.Clustered)">
- @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.tree.StatefulTreeCache.class)
- </annotation>
- <annotation expr="!class((a)org.jboss.annotation.ejb.cache.tree.CacheConfig) AND class((a)org.jboss.annotation.ejb.Clustered)">
- @org.jboss.annotation.ejb.cache.tree.CacheConfig (name="jboss.cache:service=EJB3SFSBClusteredCache", maxSize=100000, idleTimeoutSeconds=300)
- </annotation>
- </domain>
-
- <domain name="Embedded Stateful Bean" extends="Base Stateful Bean" inheritBindings="true">
- <!-- NON Clustered cache configuration -->
- <annotation expr="!class((a)org.jboss.annotation.ejb.cache.Cache)">
- @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.NoPassivationCache.class)
- </annotation>
-
- </domain>
-
- <domain name="Message Driven Bean">
- <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
- <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
- <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
- </bind>
- <annotation expr="!class((a)org.jboss.annotation.ejb.PoolClass)">
- @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.StrictMaxPool.class, maxSize=30, timeout=10000)
- </annotation>
- </domain>
-
- <domain name="Consumer Bean">
- <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
- <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
- <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
- </bind>
- <bind pointcut="execution(public * *->*(..)) AND (has(* *->@org.jboss.annotation.ejb.CurrentMessage(..)) OR hasfield(* *->@org.jboss.annotation.ejb.CurrentMessage))">
- <interceptor-ref name="org.jboss.ejb3.mdb.CurrentMessageInjectorInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
- </bind>
- <annotation expr="!class((a)org.jboss.annotation.ejb.PoolClass)">
- @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.StrictMaxPool.class, maxSize=30, timeout=10000)
- </annotation>
- </domain>
-
- <domain name="Service Bean">
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
- </bind>
- <bind pointcut="!execution(* *->create()) AND !execution(* *->start()) AND !execution(*->new(..))">
- <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
- <interceptor-ref name="Basic Authorization"/>
- </bind>
- <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
- <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
- <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
- </bind>
- <bind pointcut="execution(public * *->*(..)) AND !execution(* *->create()) AND !execution(* *->start())">
- <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
- </bind>
- </domain>
-
- <domain name="JACC Service Bean">
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
- </bind>
- <bind pointcut="!execution(* *->create()) AND !execution(* *->start()) AND !execution(*->new(..))">
- <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
- <interceptor-ref name="Basic Authorization"/>
- </bind>
- <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
- <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
- </bind>
- <bind pointcut="execution(public * *->*(..))">
- <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
- <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
- <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
- </bind>
- <bind pointcut="execution(public * *->*(..)) AND !execution(* *->create()) AND !execution(* *->start())">
- <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
- </bind>
- </domain>
-
-
-</aop>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests/src/test/resources/embedded-jboss-beans.xml b/modules/enterprise/server/itests/src/test/resources/embedded-jboss-beans.xml
deleted file mode 100644
index 85e2fb3..0000000
--- a/modules/enterprise/server/itests/src/test/resources/embedded-jboss-beans.xml
+++ /dev/null
@@ -1,168 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<deployment xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="urn:jboss:bean-deployer:2.0 bean-deployer_2_0.xsd"
- xmlns="urn:jboss:bean-deployer:2.0">
-
- <!-- This installs a custom initial context factory builder into the JVM
- that will ensure that all the default InitialContexts are going to check
- for the permission to access the RHQ internals. -->
- <bean class="org.rhq.jndi.mbean.AccessCheckingInitialContextFactoryBuilderInstaller"
- name="AccessCheckingInitialContextFactoryBuilderInstaller">
- </bean>
-
-
- <bean name="Naming" class="org.jnp.server.SingletonNamingServer"/>
-
- <bean name="InitialContextProperties" class="java.util.Hashtable">
- <constructor>
- <parameter class="java.util.Map">
- <map keyClass="java.lang.String" valueClass="java.lang.String">
- <entry>
- <key>java.naming.factory.initial</key>
- <value>org.jnp.interfaces.LocalOnlyContextFactory</value>
- </entry>
- <entry>
- <key>java.naming.factory.url.pkgs</key>
- <value>org.jboss.naming:org.jnp.interfaces</value>
- </entry>
- </map>
- </parameter>
- </constructor>
- </bean>
-
- <bean name="java:comp/Initializer" class="org.jboss.ejb3.embedded.JavaCompInitializer">
- <property name="jndiProperties">
- <inject bean="InitialContextProperties"/>
- </property>
- </bean>
-
- <bean name="XidFactory" class="org.jboss.tm.XidFactoryImpl"/>
-
- <bean name="XidFactoryMBean" class="org.jboss.ejb3.embedded.XidFactoryMBean">
- <constructor>
- <parameter class="org.jboss.tm.XidFactoryBase">
- <inject bean="XidFactory"/>
- </parameter>
- </constructor>
- </bean>
-
- <bean name="TransactionManagerInitializer" class="org.jboss.tm.TransactionManagerInitializer">
- <property name="xidFactory">
- <inject bean="XidFactory"/>
- </property>
- <property name="initialContextProperties">
- <inject bean="InitialContextProperties"/>
- </property>
- </bean>
-
- <bean name="UserTransaction" class="org.jboss.ejb3.embedded.UserTransactionImpl">
- <demand>TransactionManagerInitializer</demand>
- </bean>
-
- <bean name="UserTransactionBinding" class="org.jboss.ejb3.embedded.JndiBinder">
- <property name="jndiProperties">
- <inject bean="InitialContextProperties"/>
- </property>
- <property name="target">
- <inject bean="UserTransaction"/>
- </property>
- <property name="bindTo">UserTransaction</property>
- <property name="serializable">false</property>
- </bean>
-
-
- <bean name="TransactionManager" class="java.lang.Object">
- <constructor factoryMethod="getTransactionManager">
- <factory bean="TransactionManagerInitializer"/>
- </constructor>
- </bean>
- <bean name="CachedConnectionManager" class="org.jboss.resource.connectionmanager.CachedConnectionManagerReference">
- <property name="transactionManager">
- <inject bean="TransactionManager"/>
- </property>
- </bean>
-
- <bean name="RHQDSBootstrap" class="org.jboss.resource.adapter.jdbc.local.LocalTxDataSource">
- <property name="driverClass">${rhq.test.ds.driver-class}</property>
- <property name="connectionURL">${rhq.test.ds.connection-url}</property>
- <property name="userName">${rhq.test.ds.user-name}</property>
- <property name="password">${rhq.test.ds.password}</property>
- <property name="jndiName">java:/RHQDS</property>
- <property name="minSize">0</property>
- <property name="maxSize">20</property>
- <property name="blockingTimeout">3000</property>
- <property name="idleTimeout">100000</property>
- <property name="transactionManager">
- <inject bean="TransactionManager"/>
- </property>
- <property name="cachedConnectionManager">
- <inject bean="CachedConnectionManager"/>
- </property>
- <property name="initialContextProperties">
- <inject bean="InitialContextProperties"/>
- </property>
- </bean>
-
- <bean name="RHQDS" class="java.lang.Object">
- <constructor factoryMethod="getDatasource">
- <factory bean="RHQDSBootstrap"/>
- </constructor>
- </bean>
-
- <!-- needed for Quartz' no-TX data source (even though this is a local-tx, seems like Quartz is still working) -->
- <bean name="NoTxRHQDSBootstrap" class="org.jboss.resource.adapter.jdbc.local.LocalTxDataSource">
- <property name="driverClass">${rhq.test.ds.driver-class}</property>
- <property name="connectionURL">${rhq.test.ds.connection-url}</property>
- <property name="userName">${rhq.test.ds.user-name}</property>
- <property name="password">${rhq.test.ds.password}</property>
- <property name="jndiName">java:/NoTxRHQDS</property>
- <property name="minSize">0</property>
- <property name="maxSize">10</property>
- <property name="blockingTimeout">1000</property>
- <property name="idleTimeout">100000</property>
- <property name="transactionManager">
- <inject bean="TransactionManager"/>
- </property>
- <property name="cachedConnectionManager">
- <inject bean="CachedConnectionManager"/>
- </property>
- <property name="initialContextProperties">
- <inject bean="InitialContextProperties"/>
- </property>
- </bean>
-
- <bean name="NoTxRHQDS" class="java.lang.Object">
- <constructor factoryMethod="getDatasource">
- <factory bean="NoTxRHQDSBootstrap"/>
- </constructor>
- </bean>
-
- <bean name="DefaultDSBootstrap" class="org.jboss.resource.adapter.jdbc.local.LocalTxDataSource">
- <property name="driverClass">org.hsqldb.jdbcDriver</property>
- <property name="connectionURL">jdbc:hsqldb:.</property>
- <!-- <property name="connectionURL">jdbc:hsqldb:./hypersonic/localDB</property> -->
- <property name="userName">sa</property>
- <property name="jndiName">java:/DefaultDS</property>
- <property name="minSize">0</property>
- <property name="maxSize">10</property>
- <property name="blockingTimeout">1000</property>
- <property name="idleTimeout">100000</property>
- <property name="transactionManager">
- <inject bean="TransactionManager"/>
- </property>
- <property name="cachedConnectionManager">
- <inject bean="CachedConnectionManager"/>
- </property>
- <property name="initialContextProperties">
- <inject bean="InitialContextProperties"/>
- </property>
- </bean>
-
- <bean name="DefaultDS" class="java.lang.Object">
- <constructor factoryMethod="getDatasource">
- <factory bean="DefaultDSBootstrap"/>
- </constructor>
- </bean>
-
-</deployment>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests/src/test/resources/jboss-jms-beans.xml b/modules/enterprise/server/itests/src/test/resources/jboss-jms-beans.xml
deleted file mode 100644
index 287cffc..0000000
--- a/modules/enterprise/server/itests/src/test/resources/jboss-jms-beans.xml
+++ /dev/null
@@ -1,132 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<deployment xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="urn:jboss:bean-deployer:2.0 bean-deployer_2_0.xsd"
- xmlns="urn:jboss:bean-deployer:2.0">
- <bean name="jboss.mq:service=JMSProviderLoader,name=JMSProvider" class="org.jboss.jms.jndi.JNDIProviderAdapter">
- <property name="factoryRef">java:/JmsXA</property>
- <property name="queueFactoryRef">java:/JmsXA</property>
- <property name="topicFactoryRef">java:/JmsXA</property>
- <property name="properties" class="java.util.Properties">
- <map keyClass="java.lang.String" valueClass="java.lang.String">
- <entry>
- <key>java.naming.factory.initial</key>
- <value>org.jnp.interfaces.LocalOnlyContextFactory</value>
- </entry>
- <entry>
- <key>java.naming.factory.url.pkgs</key>
- <value>org.jboss.naming:org.jnp.interfaces</value>
- </entry>
- </map>
- </property>
- </bean>
-
- <bean name="b1" class="org.jboss.ejb3.embedded.JndiBinder">
- <property name="jndiProperties"><inject bean="InitialContextProperties"/></property>
- <property name="target"><inject bean="jboss.mq:service=JMSProviderLoader,name=JMSProvider"/></property>
- <property name="bindTo">java:/DefaultJMSProvider</property>
- <property name="serializable">true</property>
- </bean>
-
- <bean name="jboss.mq:service=ServerSessionPoolMBean,name=StdJMSPool" class="org.jboss.jms.asf.StdServerSessionPoolFactory">
- <property name="name">StdJMSPool</property>
- <property name="xidFactory"><inject bean="XidFactoryMBean"/></property>
- <property name="transactionManager"><inject bean="TransactionManager"/></property>
- </bean>
-
- <bean name="b2" class="org.jboss.ejb3.embedded.JndiBinder">
- <property name="jndiProperties"><inject bean="InitialContextProperties"/></property>
- <property name="target"><inject bean="jboss.mq:service=ServerSessionPoolMBean,name=StdJMSPool"/></property>
- <property name="bindTo">java:/StdJMSPool</property>
- <property name="serializable">false</property>
- </bean>
-
-
- <bean name="jboss.mq:service=PersistenceManager" class="org.jboss.mq.pm.none.PersistenceManager">
- </bean>
-
- <bean name="jboss.mq:service=MessageCache" class="org.jboss.mq.kernel.MessageCache">
- <property name="persistenceManager"><inject bean="jboss.mq:service=PersistenceManager"/></property>
- <property name="highMemoryMark">50</property>
- <property name="maxMemoryMark">60</property>
- </bean>
-
- <bean name="jms-rar-WorkManager" class="org.jboss.ejb3.embedded.resource.JBossWorkManager">
- </bean>
-
- <bean name="jms-rar-DeploymentInfo" class="org.jboss.ejb3.embedded.resource.Ejb3DeploymentInfo">
- <constructor>
- <parameter class="java.lang.String">jms-ra.rar</parameter>
- <parameter class="java.lang.String">javax.jms.MessageListener</parameter>
- <parameter class="java.lang.String">org.jboss.resource.adapter.jms.inflow.JmsActivationSpec</parameter>
- </constructor>
- </bean>
-
- <bean name="jboss.jca:name='jms-ra.rar',service=RARDeployment" class="org.jboss.ejb3.embedded.resource.RARDeployment">
- <constructor>
- <parameter class="org.jboss.deployment.DeploymentInfo">
- <inject bean="jms-rar-DeploymentInfo"/>
- </parameter>
- </constructor>
- <property name="workManager"><inject bean="jms-rar-WorkManager"/></property>
- </bean>
-
- <bean name="jboss.mq:service=StateManager" class="org.jboss.mq.sm.none.NullStateManager">
- </bean>
-
- <bean name="BasicQueueParameters" class="org.jboss.mq.server.BasicQueueParameters"/>
-
- <bean name="jboss.mq:service=ThreadPool" class="org.jboss.util.threadpool.BasicThreadPool">
- <property name="name">JMSThread</property>
- <property name="threadGroupName">JBossMQ Server Threads</property>
- <!-- The max number of threads in the pool -->
- <property name="maximumPoolSize">10</property>
- <!-- The max number of tasks before the queue is full -->
- <property name="maximumQueueSize">1000</property>
- <!-- The behavior of the pool when a task is added and the queue is full.
- abort - a RuntimeException is thrown
- run - the calling thread executes the task
- wait - the calling thread blocks until the queue has room
- discard - the task is silently discarded without being run
- discardOldest - check to see if a task is about to complete and enque
- the new task if possible, else run the task in the calling thread
- -->
- <property name="blockingMode">run</property>
- </bean>
-
- <bean name="jboss.mq:service=DestinationManager" class="org.jboss.mq.server.JMSDestinationManager">
- <constructor>
- <parameter class="org.jboss.mq.server.BasicQueueParameters">
- <inject bean="BasicQueueParameters"/>
- </parameter>
- </constructor>
- <property name="persistenceManager"><inject bean="jboss.mq:service=PersistenceManager"/></property>
- <property name="messageCache"><inject bean="jboss.mq:service=MessageCache"/></property>
- <property name="stateManager"><inject bean="jboss.mq:service=StateManager"/></property>
- <property name="threadPool"><inject bean="jboss.mq:service=ThreadPool"/></property>
- <property name="threadGroup"><inject bean="jboss.mq:service=ThreadPool" property="threadGroup"/></property>
- <start method="startServer"/>
- <stop method="stopServer"/>
- </bean>
-
- <bean name="jboss.mq.destination:service=Queue,name=DLQ" class="org.jboss.mq.kernel.Queue">
- <property name="destinationManagerPojo"><inject bean="jboss.mq:service=DestinationManager"/></property>
- <property name="initialContextProperties"><inject bean="InitialContextProperties"/></property>
- <property name="destinationName">DLQ</property>
- </bean>
-
- <bean name="jboss.mq:service=Invoker" class="org.jboss.mq.server.JMSServerInvoker">
- <property name="next"><inject bean="jboss.mq:service=DestinationManager"/></property>
- </bean>
-
- <bean name="jboss.mq:service=invocationlayer,type=JVM" class="org.jboss.mq.kernel.JVMIL">
- <property name="jmsInvoker"><inject bean="jboss.mq:service=Invoker"/></property>
- <!-- notice we actually switched - the non-xa connection factory JNDI Ref is the JNDI name our EJBs use -->
- <!-- the embedded EJB container doesn't support XA, so the connection factory our JmsXA JNDI lookup will return will be a non-XA factory -->
- <property name="connectionFactoryJNDIRef">java:/JmsXA</property>
- <property name="XAConnectionFactoryJNDIRef">java:/ConnectionFactory</property>
- <property name="pingPeriod">0</property>
- <property name="initialContextProperties"><inject bean="InitialContextProperties"/></property>
- </bean>
-
-</deployment>
diff --git a/modules/enterprise/server/itests/src/test/resources/jms-ra.rar b/modules/enterprise/server/itests/src/test/resources/jms-ra.rar
deleted file mode 100644
index c4807c6..0000000
Binary files a/modules/enterprise/server/itests/src/test/resources/jms-ra.rar and /dev/null differ
diff --git a/modules/enterprise/server/itests/src/test/resources/jndi.properties b/modules/enterprise/server/itests/src/test/resources/jndi.properties
deleted file mode 100644
index 9225cef..0000000
--- a/modules/enterprise/server/itests/src/test/resources/jndi.properties
+++ /dev/null
@@ -1,2 +0,0 @@
-java.naming.factory.initial=org.jnp.interfaces.LocalOnlyContextFactory
-java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces
\ No newline at end of file
diff --git a/modules/enterprise/server/itests/src/test/resources/log4j.xml b/modules/enterprise/server/itests/src/test/resources/log4j.xml
deleted file mode 100644
index ca0936f..0000000
--- a/modules/enterprise/server/itests/src/test/resources/log4j.xml
+++ /dev/null
@@ -1,74 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
-
-<!-- ===================================================================== -->
-<!-- -->
-<!-- Log4j Configuration -->
-<!-- -->
-<!-- ===================================================================== -->
-
-<!-- $Id: log4j.xml 39945 2006-01-12 02:44:07Z bill $ -->
-
-<!--
- | For more configuration infromation and examples see the Jakarta Log4j
- | owebsite: http://jakarta.apache.org/log4j
- -->
-
-<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="true">
-
- <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
- <!-- <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/> -->
- <param name="Target" value="System.out"/>
- <param name="Threshold" value="WARN"/>
-
- <layout class="org.apache.log4j.PatternLayout">
- <!-- The default pattern: Date Priority [Category] Messagen -->
- <!--
- <param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%c{1}] %m%n"/>
- -->
- <param name="ConversionPattern" value="%-5p %d{dd-MM HH:mm:ss,SSS} [%c] (%F:%M:%L) -%m%n"/>
- </layout>
- </appender>
-
- <appender name="FILE" class="org.apache.log4j.RollingFileAppender">
- <param name="File" value="target/server-jar-test.log"/>
- <param name="Threshold" value="WARN"/>
- <param name="Append" value="false"/>
-
- <layout class="org.apache.log4j.PatternLayout">
- <!-- The default pattern: Date Priority [Category] Messagen -->
- <!--
- <param name="ConversionPattern" value="%d{ABSOLUTE} %-5p [%c{1}] %m%n"/>
- -->
- <param name="ConversionPattern" value="%-5p %d{dd-MM HH:mm:ss,SSS} [%c] (%F:%M:%L) -%m%n"/>
- </layout>
- </appender>
-
- <!-- Hibernate logs WARNINGS frequent from this class, in test envs. -->
- <category name="org.hibernate.hql.ast.QueryTranslatorImpl">
- <priority value="ERROR"/>
- </category>
-
- <!-- hides the TIMER SERVICE IS NOT INSTALLED warning - we know embedded EJB3 container doesn't support timers -->
- <category name="org.jboss.ejb3.timerservice.jboss.JBossTimerServiceFactory">
- <priority value="ERROR"/>
- </category>
-
- <!-- hides the shutdown warnings - for some reason, the container spits out some warnings when shutting down -->
- <category name="org.jboss.kernel.plugins.dependency.StartStopLifecycleAction">
- <priority value="ERROR"/>
- </category>
-
- <!-- Hibernate SQL logs -->
- <!--
- <category name="org.hibernate.SQL">
- <priority value="DEBUG"/>
- </category>
- -->
-
- <root>
- <appender-ref ref="CONSOLE"/>
- <appender-ref ref="FILE"/>
- </root>
-
-</log4j:configuration>
diff --git a/modules/enterprise/server/itests/src/test/resources/login-config.xml b/modules/enterprise/server/itests/src/test/resources/login-config.xml
deleted file mode 100644
index 645294d..0000000
--- a/modules/enterprise/server/itests/src/test/resources/login-config.xml
+++ /dev/null
@@ -1,72 +0,0 @@
-<?xml version='1.0'?>
-
-<!DOCTYPE policy PUBLIC
- "-//JBoss//DTD JBOSS Security Config 3.0//EN"
- "http://www.jboss.org/j2ee/dtd/security_config.dtd">
-
-<!-- The XML based JAAS login configuration read by the
-org.jboss.security.auth.login.XMLLoginConfig mbean. Add
-an application-policy element for each security domain.
-
-The outline of the application-policy is:
-<application-policy name="security-domain-name">
- <authentication>
- <login-module code="login.module1.class.name" flag="control_flag">
- <module-option name = "option1-name">option1-value</module-option>
- <module-option name = "option2-name">option2-value</module-option>
- ...
- </login-module>
-
- <login-module code="login.module2.class.name" flag="control_flag">
- ...
- </login-module>
- ...
- </authentication>
-</application-policy>
-
-$Revision: 42748 $
--->
-
-<policy>
- <!-- Used by clients within the application server VM such as
- mbeans and servlets that access EJBs.
- -->
- <application-policy name="client-login">
- <authentication>
- <login-module code="org.jboss.security.ClientLoginModule"
- flag="required">
- <!-- Any existing security context will be restored on logout -->
- <module-option name="restore-login-identity">true</module-option>
- </login-module>
- </authentication>
- </application-policy>
-
- <application-policy name = "jbossmq">
- <authentication>
- <login-module code = "org.jboss.mq.sm.file.DynamicLoginModule" flag = "required">
- <module-option name = "unauthenticatedIdentity">guest</module-option>
- <module-option name = "sm.objectname">jboss.mq:service=StateManager</module-option>
- </login-module>
- </authentication>
- </application-policy>
-
- <application-policy name="other">
- <!-- A simple server login module, which can be used when the number
- of users is relatively small. It uses two properties files:
- users.properties, which holds users (key) and their password (value).
- roles.properties, which holds users (key) and a comma-separated list of
- their roles (value).
- The unauthenticatedIdentity property defines the name of the principal
- that will be used when a null username and password are presented as is
- the case for an unuathenticated web client or MDB. If you want to
- allow such users to be authenticated add the property, e.g.,
- unauthenticatedIdentity="nobody"
- -->
- <authentication>
- <login-module code="org.jboss.security.auth.spi.UsersRolesLoginModule"
- flag="required"/>
- </authentication>
- </application-policy>
-
-</policy>
-
diff --git a/modules/enterprise/server/itests/src/test/resources/rhq-mdb-beans.xml b/modules/enterprise/server/itests/src/test/resources/rhq-mdb-beans.xml
deleted file mode 100644
index ad05b5e..0000000
--- a/modules/enterprise/server/itests/src/test/resources/rhq-mdb-beans.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<deployment xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="urn:jboss:bean-deployer:2.0 bean-deployer_2_0.xsd"
- xmlns="urn:jboss:bean-deployer:2.0">
-
- <bean name="jboss.mq.destination:service=Queue,name=AlertConditionQueue" class="org.jboss.mq.kernel.Queue">
- <property name="destinationManagerPojo"><inject bean="jboss.mq:service=DestinationManager"/></property>
- <property name="initialContextProperties"><inject bean="InitialContextProperties"/></property>
- <property name="destinationName">AlertConditionQueue</property>
- </bean>
-
- <bean name="jboss.mq.destination:service=Queue,name=DriftChangesetQueue" class="org.jboss.mq.kernel.Queue">
- <property name="destinationManagerPojo"><inject bean="jboss.mq:service=DestinationManager"/></property>
- <property name="initialContextProperties"><inject bean="InitialContextProperties"/></property>
- <property name="destinationName">DriftChangesetQueue</property>
- </bean>
-
- <bean name="jboss.mq.destination:service=Queue,name=DriftFileQueue" class="org.jboss.mq.kernel.Queue">
- <property name="destinationManagerPojo"><inject bean="jboss.mq:service=DestinationManager"/></property>
- <property name="initialContextProperties"><inject bean="InitialContextProperties"/></property>
- <property name="destinationName">DriftFileQueue</property>
- </bean>
-
-</deployment>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests/src/test/resources/security-beans.xml b/modules/enterprise/server/itests/src/test/resources/security-beans.xml
deleted file mode 100644
index 84fa819..0000000
--- a/modules/enterprise/server/itests/src/test/resources/security-beans.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<deployment xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="urn:jboss:bean-deployer bean-deployer_1_0.xsd"
- xmlns="urn:jboss:bean-deployer">
-
- <bean class="org.jboss.ejb3.embedded.JaasSecurityManagerService"
- name="jboss.security:service=JaasSecurityManager">
- <property name="initialContextProperties">
- <inject bean="InitialContextProperties"/>
- </property>
- </bean>
-</deployment>
diff --git a/modules/enterprise/server/itests/src/test/resources/security.policy b/modules/enterprise/server/itests/src/test/resources/security.policy
deleted file mode 100644
index 8860b47..0000000
--- a/modules/enterprise/server/itests/src/test/resources/security.policy
+++ /dev/null
@@ -1,10 +0,0 @@
-// We need the SecurityManager installed to enable sandboxing of CLI scripts
-// but we don't define any other security measures on the RHQ server itself.
-//
-// Granting all permissions allows us to run the RHQ server as if no security
-// manager was in place (which is assumed by default by JBoss AS) but be able
-// to use it when we need it for our own purposes.
-
-grant {
- permission java.security.AllPermission;
-};
diff --git a/modules/enterprise/server/itests/src/test/resources/test-alert-sender-serverplugin.xml b/modules/enterprise/server/itests/src/test/resources/test-alert-sender-serverplugin.xml
deleted file mode 100644
index f6bf879..0000000
--- a/modules/enterprise/server/itests/src/test/resources/test-alert-sender-serverplugin.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-
-<alert-plugin
- name="alert-complex-test"
- displayName="Alert:ComplexTest"
- xmlns="urn:xmlns:rhq-serverplugin.alert"
- xmlns:c="urn:xmlns:rhq-configuration"
- xmlns:serverplugin="urn:xmlns:rhq-serverplugin"
- package="org.rhq.enterprise.server.alert"
- description="Alert sender plugin for testing the complex validation behavior."
- >
-
- <!-- How does this sender show up in drop downs etc -->
- <short-name>Test Alert Sender</short-name>
-
- <!-- Class that does the actual sending -->
- <plugin-class>TestAlertSender</plugin-class>
-
- <alert-configuration>
- <c:simple-property name="persistent" type="string" required="true" description="The property that is persisted into the database."/>
- <c:simple-property name="ephemeral" type="string" required="true" description="The property used only at creation/update time. It is not stored into the datbase because the plugin actually removes it from the configuration." />
- </alert-configuration>
-</alert-plugin>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests/src/test/resources/test-assist-color-number.txt b/modules/enterprise/server/itests/src/test/resources/test-assist-color-number.txt
deleted file mode 100644
index 6ad90cc..0000000
--- a/modules/enterprise/server/itests/src/test/resources/test-assist-color-number.txt
+++ /dev/null
@@ -1,46 +0,0 @@
-
-color[ number
-c
-color[
-n
-number
-r
-color[ number
-lo
-color[
-number
-number!= number!== number= number==
-be
-number
-number==
-number=="two" number=="four" number=="twenty-two" number=="twenty-four" number=="forty-two"
-number==t
-number=="two" number=="twenty-two" number=="twenty-four" number=="forty-two"
-number==fo
-number=="four" number=="twenty-four" number=="forty-two"
-color
-color[
-color[
-color[primary] color[other]
-color[p
-color[primary]
-color[o
-color[other]
-color[r
-color[primary] color[other]
-color[primary
-color[primary]
-color[primary]
-color[primary]!= color[primary]!== color[primary]= color[primary]==
-color[primary]=
-color[primary]="red" color[primary]="green" color[primary]="blue"
-color[primary]=e
-color[primary]="red" color[primary]="green" color[primary]="blue"
-color[primary]=d
-color[primary]="red"
-color[primary]=g
-color[primary]="green"
-color[primary]=b
-color[primary]="blue"
-color[primary]=r
-color[primary]="red" color[primary]="green"
\ No newline at end of file
diff --git a/modules/enterprise/server/itests/src/test/resources/test-ldap.properties b/modules/enterprise/server/itests/src/test/resources/test-ldap.properties
deleted file mode 100644
index 3316083..0000000
--- a/modules/enterprise/server/itests/src/test/resources/test-ldap.properties
+++ /dev/null
@@ -1,2 +0,0 @@
-rhq.test.ldap.url=${rhq.test.ldap.url}
-rhq.test.ldap.LDAPFactory=${rhq.test.ldap.LDAPFactory}
\ No newline at end of file
diff --git a/modules/enterprise/server/itests/src/test/resources/test-scheduler.properties b/modules/enterprise/server/itests/src/test/resources/test-scheduler.properties
deleted file mode 100644
index 804639a..0000000
--- a/modules/enterprise/server/itests/src/test/resources/test-scheduler.properties
+++ /dev/null
@@ -1,29 +0,0 @@
-# QUARTZ CONFIGURATION FOR OUR UNIT TESTS
-# our test timeout will be fast, 5 seconds
-rhq.server.operation-timeout = 5
-
-# scheduler factory config
-org.quartz.scheduler.instanceName = RHQScheduler
-org.quartz.scheduler.instanceId = AUTO
-
-# thread pool config
-org.quartz.threadPool.class = org.quartz.simpl.SimpleThreadPool
-org.quartz.threadPool.threadCount = 25
-org.quartz.threadPool.threadPriority = 5
-
-# database config - note the use of POSTGRES for tests
-org.quartz.jobStore.class = org.quartz.impl.jdbcjobstore.JobStoreCMT
-org.quartz.jobStore.driverDelegateClass = org.quartz.impl.jdbcjobstore.PostgreSQLDelegate
-# tests don't need this
-org.quartz.jobStore.isClustered = false
-org.quartz.jobStore.clusterCheckinInterval = 600000
-# make this a small non-zero time (in ms) so the scheduler (almost) never sleeps for more predictable test timing
-org.quartz.scheduler.idleWaitTime = 10
-org.quartz.jobStore.tablePrefix = RHQ_QRTZ_
-org.quartz.jobStore.useProperties = true
-org.quartz.jobStore.dataSource = RHQDS
-org.quartz.dataSource.RHQDS.jndiURL = java:/RHQDS
-org.quartz.dataSource.RHQDS.maxConnections = 10
-org.quartz.jobStore.nonManagedTXDataSource = NoTxRHQDS
-org.quartz.dataSource.NoTxRHQDS.jndiURL = java:/NoTxRHQDS
-org.quartz.dataSource.NoTxRHQDS.maxConnections = 10
\ No newline at end of file
diff --git a/modules/enterprise/server/itests/src/test/resources/testng.xml b/modules/enterprise/server/itests/src/test/resources/testng.xml
deleted file mode 100644
index 1452edb..0000000
--- a/modules/enterprise/server/itests/src/test/resources/testng.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-<!DOCTYPE suite SYSTEM "http://beust.com/testng/testng-1.0.dtd" >
-
-<suite name="EJB3 Testsuite" >
- <test name="EJB3 tests" >
- <groups>
- <run>
- <include name="integration.ejb3"/>
- </run>
- </groups>
-
- </test>
-</suite>
commit c5877685b4c127ea7db125bcbb77e141bb78b7b0
Author: Jay Shaughnessy <jshaughn(a)jshaughn.csb>
Date: Sat Nov 24 15:42:11 2012 -0500
Fix various pom warnings that maven was complaining about
diff --git a/modules/enterprise/comm/pom.xml b/modules/enterprise/comm/pom.xml
index ed128ff..eb56bfb 100644
--- a/modules/enterprise/comm/pom.xml
+++ b/modules/enterprise/comm/pom.xml
@@ -157,6 +157,7 @@
<plugins>
<plugin>
<artifactId>maven-surefire-report-plugin</artifactId>
+ <version>2.6</version>
</plugin>
</plugins>
</reporting>
diff --git a/modules/enterprise/server/jar/pom.xml b/modules/enterprise/server/jar/pom.xml
index 4421b61..dae3778 100644
--- a/modules/enterprise/server/jar/pom.xml
+++ b/modules/enterprise/server/jar/pom.xml
@@ -135,7 +135,7 @@
<groupId>org.rhq</groupId>
<artifactId>test-utils</artifactId>
<version>${project.version}</version>
- <scope>test-compile</scope>
+ <scope>test</scope>
<exclusions>
<exclusion>
<groupId>org.testng</groupId>
@@ -1134,6 +1134,7 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>clirr-maven-plugin</artifactId>
+ <version>${clirr.version}</version>
<configuration>
<includes>
<include>**/*Remote</include>
diff --git a/modules/enterprise/server/plugins/alert-operations/pom.xml b/modules/enterprise/server/plugins/alert-operations/pom.xml
index 492149c..8566724 100644
--- a/modules/enterprise/server/plugins/alert-operations/pom.xml
+++ b/modules/enterprise/server/plugins/alert-operations/pom.xml
@@ -55,7 +55,6 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>xml-maven-plugin</artifactId>
- <version>1.0-beta-3</version>
<executions>
<execution>
<!-- translate the tokens.xml file to confluence markup -->
diff --git a/modules/helpers/rtfilter-subsystem/pom.xml b/modules/helpers/rtfilter-subsystem/pom.xml
index b037aed..d08c7c6 100644
--- a/modules/helpers/rtfilter-subsystem/pom.xml
+++ b/modules/helpers/rtfilter-subsystem/pom.xml
@@ -20,7 +20,7 @@
<properties>
<version.jboss.as>7.1.1.Final</version.jboss.as>
<version.junit>4.8.2</version.junit>
- <moduleName>${groupId}.${artifactId}</moduleName>
+ <moduleName>${project.groupId}.${project.artifactId}</moduleName>
</properties>
diff --git a/modules/helpers/rtfilter/pom.xml b/modules/helpers/rtfilter/pom.xml
index fa76ec6..466208f 100644
--- a/modules/helpers/rtfilter/pom.xml
+++ b/modules/helpers/rtfilter/pom.xml
@@ -17,7 +17,7 @@
<description>a servlet filter that logs response times for HTTP requests to JEE web applications</description>
<properties>
- <moduleName>${groupId}.${artifactId}</moduleName>
+ <moduleName>${project.groupId}.${project.artifactId}</moduleName>
</properties>
<dependencies>
diff --git a/modules/plugins/rhq-server/pom.xml b/modules/plugins/rhq-server/pom.xml
index 744c3ed..0599f90 100644
--- a/modules/plugins/rhq-server/pom.xml
+++ b/modules/plugins/rhq-server/pom.xml
@@ -8,7 +8,7 @@
<version>4.6.0-SNAPSHOT</version>
</parent>
- <groupId>${rhq.groupId}</groupId>
+ <groupId>org.rhq</groupId>
<artifactId>rhq-rhqserver-plugin</artifactId>
<packaging>jar</packaging>
diff --git a/pom.xml b/pom.xml
index 0e29f7e..2d9ee76 100644
--- a/pom.xml
+++ b/pom.xml
@@ -800,7 +800,7 @@
<plugin>
<artifactId>maven-war-plugin</artifactId>
<version>2.1</version>
- </plugin>
+ </plugin>
<!-- === Codehaus Mojo Plugins === -->
<plugin>
@@ -835,6 +835,17 @@
<artifactId>animal-sniffer-maven-plugin</artifactId>
<version>${animal.sniffer.version}</version>
</plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>clirr-maven-plugin</artifactId>
+ <version>${clirr.version}</version>
+ </plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>xml-maven-plugin</artifactId>
+ <version>1.0</version>
+ </plugin>
+
<plugin>
<groupId>com.googlecode.maven-overview-plugin</groupId>
<artifactId>maven-overview-plugin</artifactId>
@@ -857,17 +868,11 @@
</plugin>
<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>clirr-maven-plugin</artifactId>
- <version>${clirr.version}</version>
- </plugin>
-
- <plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>${jacoco.version}</version>
</plugin>
- </plugins>
+ </plugins>
</pluginManagement>
commit 4e8d80763973c00178e1ba600e0a33a60023c720
Author: Jay Shaughnessy <jshaughn(a)jshaughn.csb>
Date: Sat Nov 24 15:40:41 2012 -0500
Replace hardcoded DS creads with our standard datasource
property values.
diff --git a/modules/core/domain/pom.xml b/modules/core/domain/pom.xml
index 2fcd357..71fbdbe 100644
--- a/modules/core/domain/pom.xml
+++ b/modules/core/domain/pom.xml
@@ -273,8 +273,8 @@
<security-domain name="RHQDSSecurityDomain" cache-type="default">
<authentication>
<login-module code="SecureIdentity" flag="required">
- <module-option name="username" value="rhqadmin"/>
- <module-option name="password" value="1eeb2f255e832171df8592078de921bc"/>
+ <module-option name="username" value="${rhq.test.ds.user-name}"/>
+ <module-option name="password" value="${rhq.test.ds.password}"/>
</login-module>
</authentication>
</security-domain>
diff --git a/modules/enterprise/server/itests-2/pom.xml b/modules/enterprise/server/itests-2/pom.xml
index 7c1e91c..a86cfd3 100644
--- a/modules/enterprise/server/itests-2/pom.xml
+++ b/modules/enterprise/server/itests-2/pom.xml
@@ -251,8 +251,8 @@
<security-domain name="RHQDSSecurityDomain" cache-type="default">
<authentication>
<login-module code="SecureIdentity" flag="required">
- <module-option name="username" value="rhqadmin"/>
- <module-option name="password" value="1eeb2f255e832171df8592078de921bc"/>
+ <module-option name="username" value="${rhq.test.ds.user-name}"/>
+ <module-option name="password" value="${rhq.test.ds.password}"/>
</login-module>
</authentication>
</security-domain>
11 years, 5 months
[rhq] 3 commits - modules/core modules/enterprise modules/integration-tests modules/plugins
by lkrejci
modules/core/plugin-container/src/main/java/org/rhq/core/pc/inventory/InventoryManager.java | 7
modules/enterprise/scripting/javascript/pom.xml | 6
modules/enterprise/scripting/python/pom.xml | 6
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java | 9
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java | 137 +++++++---
modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/PortScout.java | 69 +++++
modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/includes/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/mess/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/nested/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/simple/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/includes/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/mess/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/nested/inventory-without-snmp.xml | 2
modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/simple/inventory-without-snmp.xml | 2
modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java | 22 +
16 files changed, 217 insertions(+), 57 deletions(-)
New commits:
commit 844f016ee8b2608496d063c94f38461e997bcabe
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Fri Nov 23 17:18:35 2012 +0100
[BZ 879655] - Properly deactivate the resource instead of just calling the
component's stop() method when forcing reactivation of a started component.
This will ensure the PC can't enter an inconsistent state in the case the
stop() method fails.
diff --git a/modules/core/plugin-container/src/main/java/org/rhq/core/pc/inventory/InventoryManager.java b/modules/core/plugin-container/src/main/java/org/rhq/core/pc/inventory/InventoryManager.java
index b3f7fa9..473b0d0 100644
--- a/modules/core/plugin-container/src/main/java/org/rhq/core/pc/inventory/InventoryManager.java
+++ b/modules/core/plugin-container/src/main/java/org/rhq/core/pc/inventory/InventoryManager.java
@@ -1614,7 +1614,10 @@ public class InventoryManager extends AgentService implements ContainerService,
if (forceReinitialization) {
switch (state) {
case STARTED:
- component.stop();
+ if (log.isDebugEnabled()) {
+ log.debug("Forcing re-initialization of an already started resource: " + resource);
+ }
+ deactivateResource(resource);
break;
case STARTING:
log.warn("Could not force initialization of component for resource [" + resource.getId()
@@ -2037,7 +2040,7 @@ public class InventoryManager extends AgentService implements ContainerService,
log.debug("Successfully deactivated resource with id [" + resource.getId() + "].");
}
} catch (Throwable t) {
- log.warn("Plugin Error: Failed to stop component for [" + resource + "].");
+ log.warn("Plugin Error: Failed to stop component for [" + resource + "].", t);
}
container.setResourceComponentState(ResourceComponentState.STOPPED);
commit 16f04c50bd9cffaed77c73338d5f31ffb0f9c451
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Fri Nov 23 17:12:43 2012 +0100
Improvements in Apache integration tests:
* improved logging
* randomization of used ports
* *WithoutSNMP tests don't use SNMP even after upgrade (makes the behavior more understandable)
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
index 8f8cdb6..aebea53 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/upgrade/UpgradeTestBase.java
@@ -102,9 +102,6 @@ public class UpgradeTestBase extends PluginContainerTest {
boolean testFailed = false;
try {
- LOG.debug("---------------------------------------------------------- Starting the upgrade test for: "
- + testId);
-
String[] configFiles = Arrays.copyOf(testConfiguration.apacheConfigurationFiles, testConfiguration.apacheConfigurationFiles.length + 1);
configFiles[testConfiguration.apacheConfigurationFiles.length] = "/snmpd.conf";
@@ -114,7 +111,11 @@ public class UpgradeTestBase extends PluginContainerTest {
.withServerRoot(testConfiguration.serverRoot).withExePath(testConfiguration.binPath);
testConfiguration.beforeTestSetup(setup);
-
+
+ LOG.debug("---------------------------------------------------------- Starting the upgrade test for: "
+ + testId);
+ LOG.debug("Deployment configuration: " + setup.getDeploymentConfig());
+
setup.setup();
testConfiguration.beforePluginContainerStart(setup);
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java
index bc80898..02be42c 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/ApacheDeploymentUtil.java
@@ -19,7 +19,6 @@
package org.rhq.plugins.apache.util;
-import java.io.BufferedReader;
import java.io.File;
import java.io.FileReader;
import java.io.FileWriter;
@@ -33,7 +32,6 @@ import java.net.UnknownHostException;
import java.util.ArrayList;
import java.util.Collection;
import java.util.HashMap;
-import java.util.Iterator;
import java.util.List;
import java.util.ListIterator;
import java.util.Map;
@@ -198,10 +196,40 @@ public class ApacheDeploymentUtil {
tokenReplacements.put(LISTEN4, address4 == null ? "" : address4.toString(false, false));
}
}
+
+ @Override
+ public String toString() {
+ StringBuilder bld = new StringBuilder("VHost[");
+ if (address1 != null) {
+ bld.append(address1.toString()).append(", ");
+ }
+ if (address2 != null) {
+ bld.append(address2.toString()).append(", ");
+ }
+ if (address3 != null) {
+ bld.append(address3.toString()).append(", ");
+ }
+ if (address4 != null) {
+ bld.append(address4.toString()).append(", ");
+ }
+
+ String serverName = getServerName();
+ if (serverName != null) {
+ bld.append("serverName=").append(serverName).append(", ");
+ }
+
+ if (additionalDirectives != null) {
+ bld.append("with additional directives, ");
+ }
+
+ bld.replace(bld.length() - 2, bld.length(), "]");
+
+ return bld.toString();
+ }
}
public String serverRoot = null;
- public String documentRoot = "hdocs";
+ public String documentRoot = "htdocs";
public String snmpHost = "localhost";
public int snmpPort = 1610;
public final VHost mainServer = new VHost();
@@ -242,48 +270,69 @@ public class ApacheDeploymentUtil {
default: throw new IllegalArgumentException();
}
}
+
+ @Override
+ public String toString() {
+ return new StringBuilder("DeploymentConfig[").append("mainServer=").append(mainServer).append(", vhost1=")
+ .append(vhost1).append(", vhost2=").append(vhost2).append(", vhost3=").append(vhost3)
+ .append(", vhost4=").append(vhost4).append(", serverRoot=").append(serverRoot)
+ .append(", documentRoot=").append(documentRoot).append(", snmpHost=").append(snmpHost)
+ .append(", snmpPort=").append(snmpPort).append("]").toString();
+ }
}
public static void addDefaultVariables(Map<String, String> variables, String prefix) {
InetAddress localhost = determineLocalhost();
- checkOrAddDefault(variables, "localhost", localhost.getHostName());
- checkOrAddDefault(variables, "localhost.ip", localhost.getHostAddress());
- checkOrAddDefault(variables, "unresolvable.host", "unreachable.host.com");
- checkOrAddDefault(variables, "port1", "11675");
- checkOrAddDefault(variables, "port2", "11676");
- checkOrAddDefault(variables, "port3", "11677");
- checkOrAddDefault(variables, "port4", "11678");
-
- if (prefix != null && !prefix.trim().isEmpty()) {
- prefix += ".";
- } else {
- prefix = "";
+ PortScout portScout = new PortScout();
+ try {
+ checkOrAddDefault(variables, "localhost", localhost.getHostName());
+ checkOrAddDefault(variables, "localhost.ip", localhost.getHostAddress());
+ checkOrAddDefault(variables, "unresolvable.host", "unreachable.host.com");
+
+ checkOrAddDefault(variables, "port1", getRandomFreePort(portScout));
+ checkOrAddDefault(variables, "port2", getRandomFreePort(portScout));
+ checkOrAddDefault(variables, "port3", getRandomFreePort(portScout));
+ checkOrAddDefault(variables, "port4", getRandomFreePort(portScout));
+
+ if (prefix != null && !prefix.trim().isEmpty()) {
+ prefix += ".";
+ } else {
+ prefix = "";
+ }
+
+ checkOrAddDefault(variables, prefix + "snmp.port", getRandomFreePort(portScout));
+
+ checkOrAddDefault(variables, prefix + "listen1", "${port1}");
+ checkOrAddDefault(variables, prefix + "listen2", "${port2}");
+ checkOrAddDefault(variables, prefix + "listen3", "${port3}");
+ checkOrAddDefault(variables, prefix + "listen4", "${port4}");
+
+ checkOrAddDefault(variables, prefix + "vhost1.servername", "${localhost}:${port1}");
+ checkOrAddDefault(variables, prefix + "vhost1.urls", "${" + prefix + "vhost1.servername}");
+ checkOrAddDefault(variables, prefix + "vhost1.servername.directive", "ServerName ${" + prefix
+ + "vhost1.servername}");
+
+ checkOrAddDefault(variables, prefix + "vhost2.servername", "${localhost}:${port2}");
+ checkOrAddDefault(variables, prefix + "vhost2.urls", "${" + prefix + "vhost2.servername}");
+ checkOrAddDefault(variables, prefix + "vhost2.servername.directive", "ServerName ${" + prefix
+ + "vhost2.servername}");
+
+ checkOrAddDefault(variables, prefix + "vhost3.servername", "${localhost}:${port3}");
+ checkOrAddDefault(variables, prefix + "vhost3.urls", "${" + prefix + "vhost3.servername}");
+ checkOrAddDefault(variables, prefix + "vhost3.servername.directive", "ServerName ${" + prefix
+ + "vhost3.servername}");
+
+ checkOrAddDefault(variables, prefix + "vhost4.servername", "${localhost}:${port4}");
+ checkOrAddDefault(variables, prefix + "vhost4.urls", "${" + prefix + "vhost4.servername}");
+ checkOrAddDefault(variables, prefix + "vhost4.servername.directive", "ServerName ${" + prefix
+ + "vhost4.servername}");
+ } finally {
+ try {
+ portScout.close();
+ } catch (IOException e) {
+ throw new IllegalStateException(e);
+ }
}
-
- checkOrAddDefault(variables, prefix + "listen1", "${port1}");
- checkOrAddDefault(variables, prefix + "listen2", "${port2}");
- checkOrAddDefault(variables, prefix + "listen3", "${port3}");
- checkOrAddDefault(variables, prefix + "listen4", "${port4}");
-
- checkOrAddDefault(variables, prefix + "vhost1.servername", "${localhost}:${port1}");
- checkOrAddDefault(variables, prefix + "vhost1.urls", "${" + prefix + "vhost1.servername}");
- checkOrAddDefault(variables, prefix + "vhost1.servername.directive", "ServerName ${" + prefix
- + "vhost1.servername}");
-
- checkOrAddDefault(variables, prefix + "vhost2.servername", "${localhost}:${port2}");
- checkOrAddDefault(variables, prefix + "vhost2.urls", "${" + prefix + "vhost2.servername}");
- checkOrAddDefault(variables, prefix + "vhost2.servername.directive", "ServerName ${" + prefix
- + "vhost2.servername}");
-
- checkOrAddDefault(variables, prefix + "vhost3.servername", "${localhost}:${port3}");
- checkOrAddDefault(variables, prefix + "vhost3.urls", "${" + prefix + "vhost3.servername}");
- checkOrAddDefault(variables, prefix + "vhost3.servername.directive", "ServerName ${" + prefix
- + "vhost3.servername}");
-
- checkOrAddDefault(variables, prefix + "vhost4.servername", "${localhost}:${port4}");
- checkOrAddDefault(variables, prefix + "vhost4.urls", "${" + prefix + "vhost4.servername}");
- checkOrAddDefault(variables, prefix + "vhost4.servername.directive", "ServerName ${" + prefix
- + "vhost4.servername}");
}
private static void checkOrAddDefault(Map<String, String> map, String key, String value) {
@@ -433,4 +482,12 @@ public class ApacheDeploymentUtil {
}
}
};
+
+ private static String getRandomFreePort(PortScout scout) throws IllegalStateException {
+ try {
+ return Integer.toString(scout.getNextFreePort());
+ } catch (IOException e) {
+ throw new IllegalStateException("Failed to find a free port.", e);
+ }
+ }
}
diff --git a/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/PortScout.java b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/PortScout.java
new file mode 100644
index 0000000..3a33f09
--- /dev/null
+++ b/modules/integration-tests/apache-plugin-test/src/test/java/org/rhq/plugins/apache/util/PortScout.java
@@ -0,0 +1,69 @@
+/*
+ * RHQ Management Platform
+ * Copyright 2012, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
+package org.rhq.plugins.apache.util;
+
+import java.io.Closeable;
+import java.io.IOException;
+import java.net.ServerSocket;
+import java.net.SocketAddress;
+import java.util.HashSet;
+import java.util.Set;
+
+/**
+ * Tries to find a series of free ports.
+ *
+ * The ports remain open until the {@link #close()} method is called.
+ *
+ * @author Lukas Krejci
+ */
+public class PortScout implements Closeable {
+
+ private Set<ServerSocket> activeSockets = new HashSet<ServerSocket>();
+
+ public int getNextFreePort() throws IOException {
+ ServerSocket s = new ServerSocket(0);
+ activeSockets.add(s);
+ return s.getLocalPort();
+ }
+
+ @Override
+ public void close() throws IOException {
+ String message = null;
+ for(ServerSocket s : activeSockets) {
+ SocketAddress addr = s.getLocalSocketAddress();
+ try {
+ s.close();
+ } catch (IOException e) {
+ if (message == null) {
+ message = "The following test sockets failed to close while looking for free ports:\n";
+ }
+
+ message += addr.toString() + ": " + e.getMessage() + ",\n";
+ }
+ }
+
+ if (message != null) {
+ message = message.substring(0, message.length() - 2);
+
+ throw new IOException(message);
+ }
+ }
+}
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml
index 008588f..70151b7 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/log4j.xml
@@ -19,7 +19,7 @@
<param name="MaxBackupIndex" value="1000" />
<param name="MaxFileSize" value="50MB" />
<layout class="org.apache.log4j.PatternLayout">
- <param name="ConversionPattern" value="%-5p %d{dd-MM HH:mm:ss,SSS} (%F:%M:%L) -%m%n"/>
+ <param name="ConversionPattern" value="%-5p %d{dd-MM HH:mm:ss,SSS} [%t] (%F:%M:%L) -%m%n"/>
</layout>
</appender>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/includes/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/includes/inventory-without-snmp.xml
index 32f6477..10530b5 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/includes/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/includes/inventory-without-snmp.xml
@@ -512,7 +512,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/mess/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/mess/inventory-without-snmp.xml
index d0dd8ac..cbb9d66 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/mess/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/mess/inventory-without-snmp.xml
@@ -284,7 +284,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue><!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/nested/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/nested/inventory-without-snmp.xml
index d0dd8ac..1f97d99 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/nested/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/nested/inventory-without-snmp.xml
@@ -284,7 +284,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/simple/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/simple/inventory-without-snmp.xml
index 32f6477..10530b5 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/simple/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.0/simple/inventory-without-snmp.xml
@@ -512,7 +512,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/includes/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/includes/inventory-without-snmp.xml
index c3906be..987a9a0 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/includes/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/includes/inventory-without-snmp.xml
@@ -512,7 +512,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/mess/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/mess/inventory-without-snmp.xml
index 716773a..8557de3 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/mess/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/mess/inventory-without-snmp.xml
@@ -284,7 +284,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/nested/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/nested/inventory-without-snmp.xml
index 716773a..8557de3 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/nested/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/nested/inventory-without-snmp.xml
@@ -284,7 +284,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/simple/inventory-without-snmp.xml b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/simple/inventory-without-snmp.xml
index c3906be..987a9a0 100644
--- a/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/simple/inventory-without-snmp.xml
+++ b/modules/integration-tests/apache-plugin-test/src/test/resources/mocked-inventories/rhq-3.0.1/simple/inventory-without-snmp.xml
@@ -512,7 +512,7 @@
<propertySimple>
<id>10876</id>
<name>snmpAgentPort</name>
- <stringValue>1610</stringValue>
+ <stringValue>${port1}</stringValue> <!-- intentionally wrong -->
</propertySimple>
<propertySimple>
<id>10877</id>
diff --git a/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java b/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java
index a07438d..2a2b839 100644
--- a/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java
+++ b/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java
@@ -292,7 +292,8 @@ public class ApacheServerComponent implements AugeasRHQComponent, ResourceCompon
availPingTime = System.currentTimeMillis() - t1;
} else {
if (log.isDebugEnabled()) {
- log.debug("Trying to ping the server for availability through SNMP.");
+ log.debug("Trying to ping the server for availability through SNMP "
+ + getSNMPAddressString(resourceContext.getPluginConfiguration()));
}
available = getSNMPSession().ping();
availPingTime = -1;
@@ -633,6 +634,14 @@ public class ApacheServerComponent implements AugeasRHQComponent, ResourceCompon
return snmpSession;
}
+ private static String getSNMPAddressString(Configuration pluginConfig) {
+ String host = pluginConfig.getSimple(PLUGIN_CONFIG_PROP_SNMP_AGENT_HOST).getStringValue();
+ String portString = pluginConfig.getSimple(PLUGIN_CONFIG_PROP_SNMP_AGENT_PORT).getStringValue();
+ String community = pluginConfig.getSimple(PLUGIN_CONFIG_PROP_SNMP_AGENT_COMMUNITY).getStringValue();
+
+ return host + ":" + portString + "/" + community;
+ }
+
/**
* Return the absolute path of this Apache server's server root (e.g. "C:\Program Files\Apache Group\Apache2").
*
commit 8b0919aceedac820bcbd2beb9408b1795cc32c8d
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Wed Nov 21 17:00:07 2012 +0100
stuff to help debug the apache integration test failures.
diff --git a/modules/enterprise/scripting/javascript/pom.xml b/modules/enterprise/scripting/javascript/pom.xml
index ab35acb..ee5e4ba 100644
--- a/modules/enterprise/scripting/javascript/pom.xml
+++ b/modules/enterprise/scripting/javascript/pom.xml
@@ -27,6 +27,10 @@
</dependency>
</dependencies>
+ <properties>
+ <failIfNoTests>true</failIfNoTests>
+ </properties>
+
<build>
<plugins>
<plugin>
@@ -61,7 +65,7 @@
-Djava.security.policy==${project.build.testOutputDirectory}/allow-all.policy</argLine>
<!-- This is important, because some of the tests try to exit
the JVM. -->
- <failIfNoTests>true</failIfNoTests>
+ <failIfNoTests>${failIfNoTests}</failIfNoTests>
</configuration>
</plugin>
</plugins>
diff --git a/modules/enterprise/scripting/python/pom.xml b/modules/enterprise/scripting/python/pom.xml
index e4b3cfb..fc64086 100644
--- a/modules/enterprise/scripting/python/pom.xml
+++ b/modules/enterprise/scripting/python/pom.xml
@@ -10,6 +10,10 @@
<name>RHQ Python support</name>
<description>Provides RHQ scripting in Python using Jython</description>
+ <properties>
+ <failIfNoTests>true</failIfNoTests>
+ </properties>
+
<dependencies>
<dependency>
<groupId>${project.groupId}</groupId>
@@ -60,7 +64,7 @@
-Djava.security.policy==${project.build.testOutputDirectory}/allow-all.policy</argLine>
<!-- This is important, because some of the tests try to exit
the JVM. -->
- <failIfNoTests>true</failIfNoTests>
+ <failIfNoTests>${failIfNoTests}</failIfNoTests>
</configuration>
</plugin>
</plugins>
diff --git a/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java b/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java
index 8ccef7f..a07438d 100644
--- a/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java
+++ b/modules/plugins/apache/src/main/java/org/rhq/plugins/apache/ApacheServerComponent.java
@@ -283,18 +283,31 @@ public class ApacheServerComponent implements AugeasRHQComponent, ResourceCompon
boolean available;
try {
if (this.url != null) {
+ if (log.isDebugEnabled()) {
+ log.debug("Trying to ping the server for availability: " + this.url);
+ }
long t1 = System.currentTimeMillis();
int timeout = PluginUtility.getAvailabilityFacetTimeout();
available = WWWUtils.isAvailable(this.url, timeout);
availPingTime = System.currentTimeMillis() - t1;
} else {
+ if (log.isDebugEnabled()) {
+ log.debug("Trying to ping the server for availability through SNMP.");
+ }
available = getSNMPSession().ping();
availPingTime = -1;
}
} catch (Exception e) {
+ if (log.isDebugEnabled()) {
+ log.debug("Exception while checking availability.", e);
+ }
available = false;
}
+ if (log.isDebugEnabled()) {
+ log.debug("Availability determined: " + (available ? AvailabilityType.UP : AvailabilityType.DOWN));
+ }
+
return (available) ? AvailabilityType.UP : AvailabilityType.DOWN;
}
11 years, 5 months
[rhq] .classpath
by Thomas Segismont
.classpath | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
New commits:
commit bed7fb96f03e50db87a8b9699846e6f51b24584a
Author: Thomas SEGISMONT <tsegismo(a)redhat.com>
Date: Fri Nov 23 11:37:42 2012 +0100
Fix Eclipse classpath file
GWT -> 2.5.0
joda-time was missing
diff --git a/.classpath b/.classpath
index e452825..e2d8841 100644
--- a/.classpath
+++ b/.classpath
@@ -269,8 +269,8 @@
<classpathentry exported="true" kind="var" path="M2_REPO/jboss/web/jbossweb/2.0.1.GA/jbossweb-2.0.1.GA.jar"/>
<classpathentry exported="true" kind="var" path="M2_REPO/org/libvirt/libvirt/0.4.1/libvirt-0.4.1.jar"/>
<classpathentry exported="true" kind="var" path="M2_REPO/org/fedorahosted/cobbler/cobbler4j/0.1/cobbler4j-0.1.jar"/>
- <classpathentry exported="true" kind="var" path="M2_REPO/com/google/gwt/gwt-user/2.4.0/gwt-user-2.4.0.jar"/>
- <classpathentry exported="true" kind="var" path="M2_REPO/com/google/gwt/gwt-dev/2.4.0/gwt-dev-2.4.0.jar"/>
+ <classpathentry exported="true" kind="var" path="M2_REPO/com/google/gwt/gwt-user/2.5.0/gwt-user-2.5.0.jar"/>
+ <classpathentry exported="true" kind="var" path="M2_REPO/com/google/gwt/gwt-dev/2.5.0/gwt-dev-2.5.0.jar"/>
<classpathentry exported="true" kind="var" path="M2_REPO/com/smartgwt/smartgwt/3.0/smartgwt-3.0.jar"/>
<classpathentry exported="true" kind="var" path="M2_REPO/com/googlecode/gflot/gflot/2.4.2/gflot-2.4.2.jar"/>
<classpathentry exported="true" kind="var" path="M2_REPO/com/jcraft/jsch/0.1.29/jsch-0.1.29.jar"/>
@@ -316,5 +316,6 @@
<classpathentry exported="true" kind="var" path="M2_REPO/com/wordnik/swagger-annotations_2.9.1/1.1-SNAPSHOT/swagger-annotations_2.9.1-1.1-20120531.064118-1.jar"/>
<classpathentry exported="true" kind="var" path="M2_REPO/org/jboss/byteman/byteman/1.2.1/byteman-1.2.1.jar"/>
<classpathentry kind="var" path="M2_REPO/com/wordnik/swagger-annotations_2.9.1/1.1.1-SNAPSHOT/swagger-annotations_2.9.1-1.1.1-20121031.024335-6.jar"/>
+ <classpathentry exported="true" kind="var" path="M2_REPO/joda-time/joda-time/2.1/joda-time-2.1.jar"/>
<classpathentry kind="output" path="eclipse-classes"/>
</classpath>
11 years, 5 months