[rhq] 2 commits - modules/core modules/enterprise
by Jay Shaughnessy
modules/core/domain/src/main/java/org/rhq/core/domain/criteria/AlertCriteria.java | 2
modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/AgentRequestFullAvailabilityJob.java | 117 ++++++++++
modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerBean.java | 74 ++++--
modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerLocal.java | 80 +-----
modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerRemote.java | 4
5 files changed, 191 insertions(+), 86 deletions(-)
New commits:
commit a7310e6262f142eeb6af1c84651f761826d3e6ce
Author: Jay Shaughnessy <jshaughn(a)redhat.com>
Date: Thu Jan 9 17:33:00 2014 -0500
[1033858] ResourceManagerBean.enableResources blocks indefinitely while holding database transaction open
I don't think this code held a DB transaction given the NEVER transaction
attribute on the SLSB method. But, it could still hang a thread while trying
to contact agents in-band to request full avail checks. Move the agent
requests out of band to assure a faster return and better scalability.
Also:
- take this opportunity to clean up ResourceManagerLocal, having it now extend
ResourceManagerRemote. And fix a little jdoc in the remote.
diff --git a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/AgentRequestFullAvailabilityJob.java b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/AgentRequestFullAvailabilityJob.java
new file mode 100644
index 0000000..d8913f6
--- /dev/null
+++ b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/AgentRequestFullAvailabilityJob.java
@@ -0,0 +1,117 @@
+/*
+ * RHQ Management Platform
+ * Copyright (C) 2014 Red Hat, Inc.
+ * All rights reserved.
+ *
+ * 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.enterprise.server.resource;
+
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.quartz.Job;
+import org.quartz.JobDataMap;
+import org.quartz.JobExecutionContext;
+import org.quartz.JobExecutionException;
+import org.quartz.SchedulerException;
+
+import org.rhq.core.domain.auth.Subject;
+import org.rhq.core.domain.criteria.AgentCriteria;
+import org.rhq.core.domain.resource.Agent;
+import org.rhq.enterprise.server.agentclient.AgentClient;
+import org.rhq.enterprise.server.core.AgentManagerLocal;
+import org.rhq.enterprise.server.scheduler.SchedulerLocal;
+import org.rhq.enterprise.server.util.LookupUtil;
+
+/**
+ * Quartz job that requests a Collection of agents send a full avail report.
+ *
+ * @author Jay Shaughnessy
+ * @author Robert Buck
+ */
+public class AgentRequestFullAvailabilityJob implements Job {
+
+ public static final String AGENTS = "Agents";
+ public static final String KEY_TRIGGER_NAME = "TriggerName";
+ public static final String KEY_TRIGGER_GROUP_NAME = "TriggerGroupName";
+
+ private final Log log = LogFactory.getLog(AgentRequestFullAvailabilityJob.class);
+
+ public static void externalizeJobValues(JobDataMap jobDataMap, String key, Collection<Agent> agents) {
+ if (agents != null && agents.size() > 0) {
+ StringBuilder valuesCommaSeparated = new StringBuilder();
+ String comma = "";
+ for (Agent agent : agents) {
+ valuesCommaSeparated.append(comma).append(agent.getId());
+ comma = ",";
+ }
+ jobDataMap.put(key, valuesCommaSeparated.toString());
+ }
+ }
+
+ public static List<Agent> internalizeJobValues(String valuesCsvList) {
+ if (valuesCsvList == null)
+ return Collections.EMPTY_LIST;
+
+ final String[] resourceIdStrings = valuesCsvList.split(",");
+ final Integer[] resourceIds = new Integer[resourceIdStrings.length];
+ AgentCriteria c = new AgentCriteria();
+ for (int i = 0, len = resourceIdStrings.length; (i < len); ++i) {
+ resourceIds[i] = Integer.parseInt(resourceIdStrings[i]);
+ }
+ c.addFilterIds(resourceIds);
+ Subject overlord = LookupUtil.getSubjectManager().getOverlord();
+ List<Agent> result = LookupUtil.getAgentManager().findAgentsByCriteria(overlord, c);
+ return result;
+ }
+
+ private void unscheduleJob(JobDataMap jobDataMap) {
+ final String triggerName = (String) jobDataMap.get(KEY_TRIGGER_NAME);
+ final String triggerGroupName = (String) jobDataMap.get(KEY_TRIGGER_GROUP_NAME);
+ SchedulerLocal scheduler = LookupUtil.getSchedulerBean();
+ try {
+ scheduler.unscheduleJob(triggerName, triggerGroupName);
+ } catch (SchedulerException e) {
+ log.error("Failed to unschedule Quartz trigger [" + triggerName + "].", e);
+ }
+ }
+
+ @Override
+ public void execute(JobExecutionContext context) throws JobExecutionException {
+ final JobDataMap jobDataMap = context.getMergedJobDataMap();
+
+ unscheduleJob(jobDataMap);
+
+ // On a best effort basic, ask the relevant agents that their next avail report be full, so that we get
+ // the current avail type for the newly enabled resources. If we can't contact the agent don't worry about
+ // it; if it's down we'll get a full report when it comes up.
+ AgentManagerLocal agentManager = LookupUtil.getAgentManager();
+ for (Agent agent : internalizeJobValues((String) jobDataMap.get(AGENTS))) {
+ try {
+ AgentClient agentClient = agentManager.getAgentClient(agent);
+ agentClient.getDiscoveryAgentService().requestFullAvailabilityReport();
+ } catch (Throwable t) {
+ if (log.isDebugEnabled()) {
+ log.debug("Failed to notify Agent ["
+ + agent
+ + "] of enabled resources. The agent is likely down. This is ok, the avails will be updated when the agent is restarted or prompt command 'avail --force is executed'.");
+ }
+ }
+ }
+ }
+}
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 2351f08..53fb93b 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
@@ -26,6 +26,7 @@ import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collection;
import java.util.Collections;
+import java.util.Date;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
@@ -35,6 +36,7 @@ import java.util.List;
import java.util.ListIterator;
import java.util.Map;
import java.util.Set;
+import java.util.UUID;
import javax.ejb.EJB;
import javax.ejb.Stateless;
@@ -49,6 +51,11 @@ import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
+import org.quartz.JobDataMap;
+import org.quartz.JobDetail;
+import org.quartz.Scheduler;
+import org.quartz.SchedulerException;
+import org.quartz.SimpleTrigger;
import org.rhq.core.db.DatabaseType;
import org.rhq.core.db.DatabaseTypeFactory;
@@ -81,7 +88,6 @@ import org.rhq.core.domain.event.EventSource;
import org.rhq.core.domain.measurement.Availability;
import org.rhq.core.domain.measurement.AvailabilityType;
import org.rhq.core.domain.measurement.MeasurementBaseline;
-import org.rhq.core.domain.measurement.MeasurementData;
import org.rhq.core.domain.measurement.MeasurementDataTrait;
import org.rhq.core.domain.measurement.MeasurementOOB;
import org.rhq.core.domain.measurement.MeasurementSchedule;
@@ -138,6 +144,7 @@ import org.rhq.enterprise.server.resource.group.ResourceGroupManagerLocal;
import org.rhq.enterprise.server.rest.ResourceHandlerBean;
import org.rhq.enterprise.server.util.CriteriaQueryGenerator;
import org.rhq.enterprise.server.util.CriteriaQueryRunner;
+import org.rhq.enterprise.server.util.LookupUtil;
import org.rhq.enterprise.server.util.QueryUtility;
/**
@@ -2887,24 +2894,59 @@ public class ResourceManagerBean implements ResourceManagerLocal, ResourceManage
service.mergeAvailabilityReport(report);
}
- // On a best effort basic, ask the relevant agents that their next avail report be full, so that we get
- // the current avail type for the newly enabled resources. If we can't contact the agent don't worry about
- // it; if it's down we'll get a full report when it comes up.
- // TODO: This may need to be made out of band if perf becomes an issue.
- for (Agent agent : reports.keySet()) {
- try {
- AgentClient agentClient = agentManager.getAgentClient(agent);
- agentClient.getDiscoveryAgentService().requestFullAvailabilityReport();
- } catch (Throwable t) {
- if (log.isDebugEnabled()) {
- log.debug("Failed to notify Agent ["
- + agent
- + "] of enabled resources. The agent is likely down. This is ok, the avails will be updated when the agent is restarted or prompt command 'avail --force is executed'.");
- }
+ // Ask the relevant agents to send a full availability check so that the newly enabled resources get
+ // current availability as soon as possible. Do this async (via Quartz) so we don't hang waiting for
+ // Agent connections.
+ scheduleAgentRequestFullAvailabilityJob(reports.keySet());
+
+ return enableResourceIds;
+ }
+
+ private void scheduleAgentRequestFullAvailabilityJob(Collection<Agent> agents) {
+ Scheduler scheduler = LookupUtil.getSchedulerBean();
+ try {
+ final String DEFAULT_JOB_NAME = "AgentRequestFullAvailabilityJob";
+ final String DEFAULT_JOB_GROUP = "AgentRequestFullAvailabilityGroup";
+ final String TRIGGER_PREFIX = "AgentRequestFullAvailabilityTrigger";
+
+ final String randomSuffix = UUID.randomUUID().toString();
+
+ final String triggerName = TRIGGER_PREFIX + " - " + randomSuffix;
+ SimpleTrigger trigger = new SimpleTrigger(triggerName, DEFAULT_JOB_GROUP, new Date());
+
+ JobDataMap jobDataMap = new JobDataMap();
+ jobDataMap.put(AgentRequestFullAvailabilityJob.KEY_TRIGGER_NAME, triggerName);
+ jobDataMap.put(AgentRequestFullAvailabilityJob.KEY_TRIGGER_GROUP_NAME, DEFAULT_JOB_GROUP);
+ AgentRequestFullAvailabilityJob.externalizeJobValues(jobDataMap, AgentRequestFullAvailabilityJob.AGENTS,
+ agents);
+
+ trigger.setJobName(DEFAULT_JOB_NAME);
+ trigger.setJobGroup(DEFAULT_JOB_GROUP);
+ trigger.setJobDataMap(jobDataMap);
+
+ if (isJobScheduled(scheduler, DEFAULT_JOB_NAME, DEFAULT_JOB_GROUP)) {
+ scheduler.scheduleJob(trigger);
+ } else {
+ JobDetail jobDetail = new JobDetail(DEFAULT_JOB_NAME, DEFAULT_JOB_GROUP,
+ AgentRequestFullAvailabilityJob.class);
+ scheduler.scheduleJob(jobDetail, trigger);
}
+ } catch (SchedulerException e) {
+ log.error("Failed to schedule AgentRequestFullAvailabilityJob.", e);
}
+ }
- return enableResourceIds;
+ private boolean isJobScheduled(Scheduler scheduler, String name, String group) {
+ boolean isScheduled = false;
+ try {
+ JobDetail jobDetail = scheduler.getJobDetail(name, group);
+ if (jobDetail != null) {
+ isScheduled = true;
+ }
+ } catch (SchedulerException se) {
+ log.error("Error getting job detail", se);
+ }
+ return isScheduled;
}
@Override
diff --git a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerLocal.java b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerLocal.java
index b6db0fd..408d388 100644
--- a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerLocal.java
+++ b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerLocal.java
@@ -29,7 +29,6 @@ import org.jetbrains.annotations.Nullable;
import org.rhq.core.domain.auth.Subject;
import org.rhq.core.domain.criteria.ResourceCriteria;
import org.rhq.core.domain.discovery.AvailabilityReport;
-import org.rhq.core.domain.measurement.ResourceAvailability;
import org.rhq.core.domain.resource.Agent;
import org.rhq.core.domain.resource.InventoryStatus;
import org.rhq.core.domain.resource.Resource;
@@ -40,7 +39,6 @@ import org.rhq.core.domain.resource.ResourceErrorType;
import org.rhq.core.domain.resource.ResourceType;
import org.rhq.core.domain.resource.composite.DisambiguationReport;
import org.rhq.core.domain.resource.composite.RecentlyAddedResourceComposite;
-import org.rhq.core.domain.resource.composite.ResourceAvailabilitySummary;
import org.rhq.core.domain.resource.composite.ResourceComposite;
import org.rhq.core.domain.resource.composite.ResourceHealthComposite;
import org.rhq.core.domain.resource.composite.ResourceIdFlyWeight;
@@ -63,7 +61,7 @@ import org.rhq.enterprise.server.resource.group.ResourceGroupNotFoundException;
* @author Ian Springer
*/
@Local
-public interface ResourceManagerLocal {
+public interface ResourceManagerLocal extends ResourceManagerRemote {
/**
* Create a new Resource. This method creates only the supplied Resource, it will *NOT* create
* the parent or any childResources.
@@ -98,7 +96,7 @@ public interface ResourceManagerLocal {
List<Integer> uninventoryResource(Subject user, int resourceId);
/**
- * Internal use only. use with care, avoids authz checking overhead.
+ * Internal use only. use with care, avoids authz checking overhead.
*
* @param resourceId
* @return
@@ -173,7 +171,7 @@ public interface ResourceManagerLocal {
/**
* Returns the direct lineage of a resource up to the top most resource in the hierarchy.
* Composites are returned that indicate whether the resource is viewable or not by the user.
- *
+ *
* @param resourceId id of resource
* @return resource lineage
*/
@@ -183,7 +181,7 @@ public interface ResourceManagerLocal {
* Returns the lineage of a resource plus all the siblings of the resources in the lineage. This is
* useful for prepopulating all the resources visible in an expanded tree. Composites are returned
* that indicate whether the resource is viewable or should be locked in the tree.
- *
+ *
* @param resourceId id of resource
* @return resource lineage and siblings
*/
@@ -227,8 +225,8 @@ public interface ResourceManagerLocal {
PageControl pageControl);
/**
- * Get a summary of counts, by category, of the user's viewable resources having the provided inventory status.
- *
+ * Get a summary of counts, by category, of the user's viewable resources having the provided inventory status.
+ *
* @param user
* @param status
* @return A 3 element int array with counts for platform, service, service as a[0], a[1], a[2], respectively.
@@ -414,7 +412,7 @@ public interface ResourceManagerLocal {
* Returns the platform Resource associated with the specified Agent.
*
* @param agent an Agent
- *
+ *
* @return the platform Resource associated with the specified Agent or null if the platform for the agent is not known yet.
*/
Resource getPlatform(Agent agent);
@@ -442,11 +440,11 @@ public interface ResourceManagerLocal {
* Update the ancestry for the specified resource and its child lineage.
* <pre>
* The ancestry is recursively defined as:
- *
+ *
* resourceAncestry=parentResourceResourceTypeId_:_parentResourceId_:_parentResourceName_::_parentResourceAncestry
- *
+ *
* * note that platform resources have no parent and therefore have a null ancestry
- *
+ *
* </pre>
* @param subject
* @param resourceId
@@ -456,14 +454,14 @@ public interface ResourceManagerLocal {
/**
* This method exists to support the GUI resource tree, by not returning an unlimited number of resources
* but instead bounding the returned size. Note, this routine does not offer paging and any PageControl set in
- * the Criteria is ignored. This is for use when paging is not required or possible, such as in a tree.
- *
+ * the Criteria is ignored. This is for use when paging is not required or possible, such as in a tree.
+ *
* @param subject
* @param criteria
* @param maxResources Will not return more than this number of resources. If the original fetch exceeds maxResources
* then maxResourcesByType will be enforced. If, after trimming by type, maxResources is still exceeded, then the least
* significant resources (the tail, assuming a sorted set) will be removed to enforce the limit. If <=0 the default
- * will be used.
+ * will be used.
* @param maxResourcesByType If maxResources is exceeded by the initial result set then members of each type will be
* trimmed down to meet this limit. If <=0 the default will be used.
* @return The resulting resources, trimmed if necessary to meet the specify sizing bounds.
@@ -477,62 +475,14 @@ public interface ResourceManagerLocal {
Map<Agent, AvailabilityReport> getEnableResourcesReportInNewTransaction(Subject subject, int[] resourceIds,
List<Integer> enableResourceIds);
- // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
- //
- // The following are shared with the Remote Interface
- //
- // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-
- ResourceAvailabilitySummary getAvailabilitySummary(Subject user, int resourceId);
-
- /**
- * #see {@link ResourceManagerRemote#getLiveResourceAvailability(Subject, int)
- */
- ResourceAvailability getLiveResourceAvailability(Subject subject, int resourceId);
-
- /**
- * #see {@link ResourceManagerRemote#getResource(Subject, int)
- */
- Resource getResource(Subject subject, int resourceId);
-
- /**
- * #see {@link ResourceManagerRemote#findResourceLineage(Subject, int)
- */
- List<Resource> findResourceLineage(Subject subject, int resourceId);
-
- void uninventoryAllResourcesByAgent(Subject user, Agent doomedAgent);
-
- void uninventoryResourcesOfResourceType(Subject subject, int resourceTypeId);
-
- /**
- * This will uninventory the resources with the given ID along with all of their child resources. This method will not
- * create its own transaction; each individual child resource as well as the top level resources identified with the
- * given IDs will be uninventoried in their own transaction. This will ensure that resources are uninventoried in the proper
- * order (for example, if a given resource is actually a child of one of the other given resources, this method
- * ensures the uninventory occurs properly).
- *
- * @param subject the user performing the uninventory action
- * @param resourceIds the ID of the resource to be deleted
- *
- * @return the list of all resources that were deleted - in effect, this will contain <code>resourceIds</code> and
- * their childrens' IDs
- */
- List<Integer> uninventoryResources(Subject subject, int[] resourceIds);
-
List<ResourceInstallCount> findResourceComplianceCounts(Subject subject);
List<ResourceInstallCount> findResourceInstallCounts(Subject subject, boolean groupByVersions);
PageList<ResourceComposite> findResourceCompositesByCriteria(Subject subject, ResourceCriteria criteria);
- PageList<Resource> findResourcesByCriteria(Subject subject, ResourceCriteria criteria);
-
- PageList<Resource> findChildResources(Subject subject, int resourceId, PageControl pageControl);
-
Resource getPlaformOfResource(Subject subject, int resourceId);
- Resource getParentResource(Subject subject, int resourceId);
-
/**
* @return the disambiguation result or null on error
*/
@@ -545,10 +495,6 @@ public interface ResourceManagerLocal {
Map<Integer, String> getResourcesAncestry(Subject subject, Integer[] resourceIds, ResourceAncestryFormat format);
- List<Integer> disableResources(Subject subject, int[] resourceIds);
-
- List<Integer> enableResources(Subject subject, int[] resourceIds);
-
PageList<Resource> findGroupMemberCandidateResources(Subject subject, ResourceCriteria criteria,
int[] alreadySelectedResourceIds);
}
diff --git a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerRemote.java b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerRemote.java
index 58c2d14..f40e6d6 100644
--- a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerRemote.java
+++ b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/resource/ResourceManagerRemote.java
@@ -180,7 +180,7 @@ public interface ResourceManagerRemote {
* Resources already disabled are ignored.
*
* @param subject The logged in user's subject.
- * @param resourceIds The resources to uninventory.
+ * @param resourceIds The resources to disable.
* @return the disabled resource ids, not null
*
* @see #enableResources(Subject, int[])
@@ -195,7 +195,7 @@ public interface ResourceManagerRemote {
* The calling user must possess {@link Permission#DELETE_RESOURCE} permission on all of the provided resources.
*
* @param subject The logged in user's subject.
- * @param resourceIds The resources to uninventory.
+ * @param resourceIds The resources to enable.
* @return the enable resource ids, not null
*
* @see #disableResources(Subject, int[])
commit 40e51e0945b3ef4d9061b1d1bb219f78bb135e73
Author: Jay Shaughnessy <jshaughn(a)redhat.com>
Date: Thu Jan 9 17:27:55 2014 -0500
[1050686] RFE: Add to AlertCriteria way to query for unacknowledged alerts
bump up Serialization ID given addition of new filter
diff --git a/modules/core/domain/src/main/java/org/rhq/core/domain/criteria/AlertCriteria.java b/modules/core/domain/src/main/java/org/rhq/core/domain/criteria/AlertCriteria.java
index 54b6220..3bd12bb 100644
--- a/modules/core/domain/src/main/java/org/rhq/core/domain/criteria/AlertCriteria.java
+++ b/modules/core/domain/src/main/java/org/rhq/core/domain/criteria/AlertCriteria.java
@@ -41,7 +41,7 @@ import org.rhq.core.domain.util.PageOrdering;
@XmlAccessorType(XmlAccessType.FIELD)
@SuppressWarnings({ "unused", "FieldCanBeLocal" })
public class AlertCriteria extends Criteria {
- private static final long serialVersionUID = 2L;
+ private static final long serialVersionUID = 3L;
// sort fields from the Alert itself
public static final String SORT_FIELD_CTIME = "ctime";
10 years, 5 months
[rhq] 2 commits - modules/core modules/enterprise
by Jay Shaughnessy
modules/core/domain/src/main/java/org/rhq/core/domain/criteria/AlertCriteria.java | 18 ++-
modules/enterprise/server/itests-2/src/test/java/org/rhq/enterprise/server/alert/test/AlertManagerTest.java | 60 ++++++++++
modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/rest/AlertHandlerBean.java | 12 +-
3 files changed, 88 insertions(+), 2 deletions(-)
New commits:
commit e740f07f6cb3905e71837caf2e36e03000df75c1
Author: Jay Shaughnessy <jshaughn(a)redhat.com>
Date: Thu Jan 9 11:58:59 2014 -0500
[1050686] RFE: Add to AlertCriteria way to query for unacknowledged alerts
Add new filter to REST API as well
diff --git a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/rest/AlertHandlerBean.java b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/rest/AlertHandlerBean.java
index b66de1a..3ba7710 100644
--- a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/rest/AlertHandlerBean.java
+++ b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/rest/AlertHandlerBean.java
@@ -65,7 +65,12 @@ import org.rhq.core.domain.util.PageControl;
import org.rhq.core.domain.util.PageList;
import org.rhq.core.domain.util.PageOrdering;
import org.rhq.enterprise.server.alert.AlertManagerLocal;
-import org.rhq.enterprise.server.rest.domain.*;
+import org.rhq.enterprise.server.rest.domain.AlertDefinitionRest;
+import org.rhq.enterprise.server.rest.domain.AlertRest;
+import org.rhq.enterprise.server.rest.domain.IntegerValue;
+import org.rhq.enterprise.server.rest.domain.Link;
+import org.rhq.enterprise.server.rest.domain.ResourceWithType;
+import org.rhq.enterprise.server.rest.domain.StringValue;
/**
* Deal with alert related stuff
@@ -98,6 +103,7 @@ public class AlertHandlerBean extends AbstractRestBean {
@ApiParam(value = "If non-null only send alerts that have fired after this time, time is millisecond since epoch") @QueryParam("since") Long since,
@ApiParam(value = "Id of a resource to limit search for") @QueryParam("resourceId") Integer resourceId,
@ApiParam(value = "If of an alert definition to search for") @QueryParam("definitionId") Integer definitionId,
+ @ApiParam(value = "Should only unacknowledged alerts be sent") @QueryParam("unacknowledgedOnly") @DefaultValue("false") boolean unacknowledgedOnly,
@Context UriInfo uriInfo, @Context HttpHeaders headers) {
if (resourceId!=null && definitionId!=null) {
@@ -136,6 +142,10 @@ public class AlertHandlerBean extends AbstractRestBean {
AlertPriority alertPriority = AlertPriority.valueOf(prio.toUpperCase());
criteria.addFilterPriorities(alertPriority);
}
+
+ if (unacknowledgedOnly) {
+ criteria.addFilterUnacknowledgedOnly(Boolean.TRUE);
+ }
criteria.addSortCtime(PageOrdering.DESC);
PageList<Alert> alerts = alertManager.findAlertsByCriteria(caller,criteria);
commit 6f206d4ddac3e6a5a3eb44d2d557c5ff41efd362
Author: Jay Shaughnessy <jshaughn(a)redhat.com>
Date: Thu Jan 9 11:47:35 2014 -0500
[1050686] RFE: Add to AlertCriteria way to query for unacknowledged alerts
New filter: addFilterUnacknowledgedOnly(Boolean filterUnacknowledgedOnly)
diff --git a/modules/core/domain/src/main/java/org/rhq/core/domain/criteria/AlertCriteria.java b/modules/core/domain/src/main/java/org/rhq/core/domain/criteria/AlertCriteria.java
index fb4c4df..54b6220 100644
--- a/modules/core/domain/src/main/java/org/rhq/core/domain/criteria/AlertCriteria.java
+++ b/modules/core/domain/src/main/java/org/rhq/core/domain/criteria/AlertCriteria.java
@@ -39,7 +39,7 @@ import org.rhq.core.domain.util.PageOrdering;
*/
@XmlRootElement
@XmlAccessorType(XmlAccessType.FIELD)
-@SuppressWarnings({"unused", "FieldCanBeLocal"})
+@SuppressWarnings({ "unused", "FieldCanBeLocal" })
public class AlertCriteria extends Criteria {
private static final long serialVersionUID = 2L;
@@ -65,6 +65,7 @@ public class AlertCriteria extends Criteria {
private List<Integer> filterAlertDefinitionIds; // requires overrides
private List<Integer> filterGroupAlertDefinitionIds; // requires overrides
private String filterAcknowledgingSubject;
+ private NonBindingOverrideFilter filterUnacknowledgedOnly; // requires overrides
private boolean fetchAlertDefinition;
private boolean fetchConditionLogs;
@@ -95,6 +96,7 @@ public class AlertCriteria extends Criteria {
+ " WHERE rg.id = ? )");
filterOverrides.put("alertDefinitionIds", "alertDefinition.id IN ( ? )");
filterOverrides.put("groupAlertDefinitionIds", "alertDefinition.groupAlertDefinition.id IN ( ? )");
+ filterOverrides.put("unacknowledgedOnly", "acknowledgingSubject IS NULL");
sortOverrides.put(SORT_FIELD_NAME, "alertDefinition.name");
sortOverrides.put(SORT_FIELD_PRIORITY, "alertDefinition.priority");
@@ -167,10 +169,24 @@ public class AlertCriteria extends Criteria {
this.filterGroupAlertDefinitionIds = CriteriaUtils.getListIgnoringNulls(filterGroupAlertDefinitionIds);
}
+ /**
+ * Note that by default this is a substring search. Use {@link Criteria#setStrict(boolean)} to perform an
+ * exact string match.
+ *
+ * @param acknowledgingSubject The subject or subject substring. Set to empty string to match all acknowledged alerts.
+ */
public void addFilterAcknowledgingSubject(String acknowledgingSubject) {
this.filterAcknowledgingSubject = acknowledgingSubject;
}
+ /**
+ * @param unacknowledged If TRUE limit to only unacknowledged alerts.
+ */
+ public void addFilterUnacknowledgedOnly(Boolean filterUnacknowledgedOnly) {
+ this.filterUnacknowledgedOnly = (Boolean.TRUE.equals(filterUnacknowledgedOnly) ? NonBindingOverrideFilter.ON
+ : NonBindingOverrideFilter.OFF);
+ }
+
public void fetchAlertDefinition(boolean fetchAlertDefinition) {
this.fetchAlertDefinition = fetchAlertDefinition;
}
diff --git a/modules/enterprise/server/itests-2/src/test/java/org/rhq/enterprise/server/alert/test/AlertManagerTest.java b/modules/enterprise/server/itests-2/src/test/java/org/rhq/enterprise/server/alert/test/AlertManagerTest.java
index 146ee20..5a50825 100644
--- a/modules/enterprise/server/itests-2/src/test/java/org/rhq/enterprise/server/alert/test/AlertManagerTest.java
+++ b/modules/enterprise/server/itests-2/src/test/java/org/rhq/enterprise/server/alert/test/AlertManagerTest.java
@@ -20,6 +20,8 @@
package org.rhq.enterprise.server.alert.test;
+import java.util.List;
+
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.testng.annotations.Test;
@@ -196,6 +198,64 @@ public class AlertManagerTest extends AbstractEJB3Test {
}
@Test
+ public void testAcknowledgeAlertCriteria() {
+ executeInTransaction(new TransactionCallback() {
+ @Override
+ public void execute() throws Exception {
+ int resourceAlertDefinitionId = createResourceAlertDefinitionAndGetId("fake resource alertdef");
+ alertManager.fireAlert(resourceAlertDefinitionId);
+
+ // find the unacked alert
+ AlertCriteria c = new AlertCriteria();
+ c.addFilterAlertDefinitionIds(resourceAlertDefinitionId);
+ c.addFilterUnacknowledgedOnly(Boolean.TRUE);
+ List<Alert> result = alertManager.findAlertsByCriteria(testData.getSubject(), c);
+ assertEquals(1, result.size());
+
+ // fail to find any acked alert
+ c.addFilterUnacknowledgedOnly(Boolean.FALSE);
+ c.addFilterAcknowledgingSubject(""); // should match anything acknowledged
+ result = alertManager.findAlertsByCriteria(testData.getSubject(), c);
+ assertTrue(result.isEmpty());
+
+ // ack the alert
+ long testStartTimeStamp = System.currentTimeMillis();
+ int count = alertManager.acknowledgeAlertsByContext(testData.getSubject(),
+ EntityContext.forResource(testData.getResource().getId()));
+ assertEquals(1, count);
+
+ // find any acked alert
+ result = alertManager.findAlertsByCriteria(testData.getSubject(), c);
+ assertEquals(1, result.size());
+ Alert alert = result.get(0);
+ em.refresh(alert);
+ assertNotNull(alert.getAcknowledgingSubject());
+ assertNotNull(alert.getAcknowledgeTime());
+ assertEquals(testData.getSubject().getName(), alert.getAcknowledgingSubject());
+ assertTrue("Alert should just have been acknowledged", alert.getAcknowledgeTime() >= testStartTimeStamp);
+
+ // find the acked alert by subject
+ c.addFilterAcknowledgingSubject(testData.getSubject().getName());
+ c.setStrict(true);
+ result = alertManager.findAlertsByCriteria(testData.getSubject(), c);
+ assertEquals(1, result.size());
+ alert = result.get(0);
+ em.refresh(alert);
+ assertNotNull(alert.getAcknowledgingSubject());
+ assertNotNull(alert.getAcknowledgeTime());
+ assertEquals(testData.getSubject().getName(), alert.getAcknowledgingSubject());
+ assertTrue("Alert should just have been acknowledged", alert.getAcknowledgeTime() >= testStartTimeStamp);
+
+ // fail to find the acked alert
+ c.addFilterUnacknowledgedOnly(Boolean.TRUE);
+ c.addFilterAcknowledgingSubject(null);
+ result = alertManager.findAlertsByCriteria(testData.getSubject(), c);
+ assertTrue(result.isEmpty());
+ }
+ });
+ }
+
+ @Test
public void testAcknowledgeAlertsByTemplateContext() {
executeInTransaction(new TransactionCallback() {
@Override
10 years, 5 months
[rhq] modules/enterprise
by Jiri Kremser
modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/client/dashboard/DashboardView.java | 32 ++++++----
modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages.properties | 3
modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_cs.properties | 3
modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_de.properties | 3
modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ja.properties | 3
modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ko.properties | 3
modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_pt.properties | 3
modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ru.properties | 3
modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_zh.properties | 3
9 files changed, 46 insertions(+), 10 deletions(-)
New commits:
commit 1e2f74e4ad545ad92ad39fdca6f691fd85608d2c
Author: Jirka Kremser <jkremser(a)redhat.com>
Date: Thu Jan 9 16:39:37 2014 +0100
[BZ 846819] - Broken dashboard portlets or portlets with invalid configuration SHOULD NOT prevent the entire dashboard from working - surrounding the risky interaction with particular portlets into try-catch block to make the logic little bit more robust. Now, exception thrown from a portlet doesn't affect other portlets, so the portlets are more autonomous so to speak.
diff --git a/modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/client/dashboard/DashboardView.java b/modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/client/dashboard/DashboardView.java
index d32373e..d9437ae 100644
--- a/modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/client/dashboard/DashboardView.java
+++ b/modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/client/dashboard/DashboardView.java
@@ -338,7 +338,11 @@ public class DashboardView extends EnhancedVLayout {
public void onItemClick(ItemClickEvent itemClickEvent) {
String key = itemClickEvent.getItem().getAttribute("portletKey");
String name = itemClickEvent.getItem().getTitle();
- addPortlet(key, name);
+ try {
+ addPortlet(key, name);
+ } catch (Exception ex) {
+ CoreGUI.getErrorHandler().handleError(MSG.view_dashboardsManager_error3(), ex);
+ }
}
});
@@ -543,14 +547,18 @@ public class DashboardView extends EnhancedVLayout {
private void loadPortletWindows() {
for (int i = 0; i < storedDashboard.getColumns(); i++) {
for (DashboardPortlet storedPortlet : storedDashboard.getPortlets(i)) {
-
- PortletWindow portletWindow = new PortletWindow(this, storedPortlet, context);
- portletWindow.setTitle(storedPortlet.getName());
- portletWindow.setHeight(storedPortlet.getHeight());
- portletWindow.setVisible(true);
-
- portletWindows.add(portletWindow);
- portalLayout.addPortletWindow(portletWindow, i);
+ try {
+ PortletWindow portletWindow = new PortletWindow(this, storedPortlet, context);
+ portletWindow.setTitle(storedPortlet.getName());
+ portletWindow.setHeight(storedPortlet.getHeight());
+ portletWindow.setVisible(true);
+
+ portletWindows.add(portletWindow);
+ portalLayout.addPortletWindow(portletWindow, i);
+ } catch (Exception ex) {
+ CoreGUI.getErrorHandler().handleError(MSG.view_dashboardsManager_error2(), ex);
+ continue;
+ }
}
}
}
@@ -926,7 +934,11 @@ public class DashboardView extends EnhancedVLayout {
for (PortletWindow pw : portletWindows) {
// I think this should work with markForRedraw but for some reason it does not
- ((Canvas) pw.getView()).redraw();
+ try {
+ ((Canvas) pw.getView()).redraw();
+ } catch (Exception ex) {
+ CoreGUI.getErrorHandler().handleError(MSG.view_dashboardsManager_error4(), ex);
+ }
}
}
}
diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages.properties
index fce30c3..e39b205 100644
--- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages.properties
+++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages.properties
@@ -1587,6 +1587,9 @@ view_dashboardManager_saved = Saved dashboard {0} to server
view_dashboardManager_success = Saved dashboard
view_dashboard_favorites_error1 = Failed to load favorite Resources.
view_dashboardsManager_error1 = Failed to add new dashboard
+view_dashboardsManager_error2 = Failed to load dashboard portlet.
+view_dashboardsManager_error3 = Failed to add portlet to dashboard.
+view_dashboardsManager_error4 = Failed to draw dashboard portlet.
view_dashboardsManager_message_title_details = <h1>Welcome to {0}</h1>\n<p>This dashboard can be edited by clicking the (Edit Mode) button above.</p>\n<p>What would you like to do?</p>\n<p> <a href=\"{1}\">Import newly discovered resources.</a></p>\n<p> <a href=\"{2}\">Search for resources.</a></p>\n<p> <a href=\"{3}\">See help and documentation.</a></p>
view_dashboards_confirm1 = Are you sure you want to delete
view_dashboards_portlets_refresh_fail1 = Failed to update auto-refresh interval
diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_cs.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_cs.properties
index bf31a7c..a117828 100644
--- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_cs.properties
+++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_cs.properties
@@ -1604,6 +1604,9 @@ view_dashboardManager_saved = Dashboard {0} byl uložen na server
view_dashboardManager_success = Dashboard uložen
view_dashboard_favorites_error1 = Nepodařilo se načíst oblíbené zdroje.
view_dashboardsManager_error1 = Nepodařilo se přidat nový dashboard
+view_dashboardsManager_error2 = Nepodařilo se načíst portlet.
+view_dashboardsManager_error3 = Nepodařilo se přidat portlet na dashboard.
+view_dashboardsManager_error4 = Nepodařilo se vykreslit portlet.
##view_dashboardsManager_message_title_details = <h1>Welcome to {0}</h1>\n<p>This dashboard can be edited by clicking the (Edit Mode) button above.</p>\n<p>What would you like to do?</p>\n<p> <a href=\"{1}\">Import newly discovered resources.</a></p>\n<p> <a href=\"{2}\">Search for resources.</a></p>\n<p> <a href=\"{3}\">See help and documentation.</a></p>
view_dashboards_confirm1 = Jste si jisti, že to chcete smazat
##view_dashboards_portlets_refresh_fail1 = Nepodařilo se změnit interval auto aktualizace pro portlety
diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_de.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_de.properties
index 2670220..d6d22bf 100644
--- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_de.properties
+++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_de.properties
@@ -1865,6 +1865,9 @@ view_dashboardManager_saved=Das Dashboard {0} wurde auf dem Server gesichert
view_dashboardManager_success=Dashboard gespeichert
view_dashboard_favorites_error1=Konnte die Ressoucen-Lesezeichen nicht laden
view_dashboardsManager_error1=Konnte das neue Dashboard nicht hinzufügen
+##view_dashboardsManager_error2 = Failed to load dashboard portlet.
+##view_dashboardsManager_error3 = Failed to add portlet to dashboard.
+##view_dashboardsManager_error4 = Failed to draw dashboard portlet.
view_dashboardsManager_message_title_details=<h1>Willkommen bei {0}</h1>\n<p>Dieses Dashboard kan durch Betätigen des Bearbeitungsmodus-Knopfes verändert werden.</p>\n<p>Was möchten Sie tun?</p>\n<p> <a href\="{1}">Neu gefundene Ressourcen importieren.</a></p>\n<p> <a href\="{2}">Ressourcen suchen.</a></p>\n<p> <a href\="{3}">Hilfe und Dokumentation ansehen.</a></p>
view_dashboards_confirm1=Sind Sie sicher, dass Sie löschen möchten
view_dashboards_portlets_refresh_fail1=Aktualisierung von Auto-refresh Intervall fehlgeschlagen
diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ja.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ja.properties
index aa366a0..c1917f0 100644
--- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ja.properties
+++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ja.properties
@@ -1769,6 +1769,9 @@ view_dashboardManager_saved=ダッシュボード {0} をサーバーへ保存
view_dashboardManager_success=ダッシュボードを保存しました
view_dashboard_favorites_error1=好みのリソースをロードするのに失敗しました
view_dashboardsManager_error1=新しいダッシュボードを追加するのに失敗しました
+##view_dashboardsManager_error2 = Failed to load dashboard portlet.
+##view_dashboardsManager_error3 = Failed to add portlet to dashboard.
+##view_dashboardsManager_error4 = Failed to draw dashboard portlet.
view_dashboardsManager_message_title_details=<h1>{0} をご使用いただきありがとうございます。</h1>\n<p>このダッシュボードは、上記の (編集モード) ボタンをクリックすると編集できます。</p>\n<p>以下の操作の 1 つを選択してください。</p>\n<p> <a href\="{1}">新たに見つかったリソースをインポートする</a></p>\n<p> <a href\="{2}">リソースを検索する</a></p>\n<p> <a href\="{3}">ヘルプおよびドキュメントを確認する</a></p>
# #view_dashboardsManager_message_title_details = <h1>Welcome to {0}</h1>\n<p>This dashboard can be edited by clicking the (Edit Mode) button above.</p>\n<p>What would you like to do?</p>\n<p> <a href=\"{1}\">Import newly discovered resources.</a></p>\n<p> <a href=\"{2}\">Search for resources.</a></p>\n<p> <a href=\"{3}\">See help and documentation.</a></p>
view_dashboards_confirm1=削除してもよろしいですか
diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ko.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ko.properties
index 6385c5c..9096b87 100644
--- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ko.properties
+++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ko.properties
@@ -1429,6 +1429,9 @@ view_dashboardManager_saved = 서버에 대시 보드 {0}을 저장했습니다
view_dashboardManager_success = 대시 보드를 저장했습니다
view_dashboard_favorites_error1 = 즐겨찾기 리소스를 로드하는데 실패했습니다.
view_dashboardsManager_error1 = 새로운 대시 보드 추가에 실패했습니다
+##view_dashboardsManager_error2 = Failed to load dashboard portlet.
+##view_dashboardsManager_error3 = Failed to add portlet to dashboard.
+##view_dashboardsManager_error4 = Failed to draw dashboard portlet.
##view_dashboardsManager_message_title_details = <h1>Welcome to {0}</h1>\n<p>This dashboard can be edited by clicking the (Edit Mode) button above.</p>\n<p>What would you like to do?</p>\n<p> <a href=\"{1}\">Import newly discovered resources.</a></p>\n<p> <a href=\"{2}\">Search for resources.</a></p>\n<p> <a href=\"{3}\">See help and documentation.</a></p>
view_dashboards_confirm1 = 삭제하시겠습니까
view_dashboards_portlets_refresh_fail2 = 자동 새로고침 포틀릿에 대한 리로드 비활성화에 실패했습니다
diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_pt.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_pt.properties
index e3e8e1f..d4b811b 100644
--- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_pt.properties
+++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_pt.properties
@@ -1595,6 +1595,9 @@ view_dashboardManager_saved = Dashboard {0} salvo no servidor
view_dashboardManager_success = Dashboard salvo
view_dashboard_favorites_error1 = Falha ao carregar recursos favoritos.
view_dashboardsManager_error1 = Falha ao adicionar novo dashboad
+##view_dashboardsManager_error2 = Failed to load dashboard portlet.
+##view_dashboardsManager_error3 = Failed to add portlet to dashboard.
+##view_dashboardsManager_error4 = Failed to draw dashboard portlet.
view_dashboardsManager_inventory_title = Sum\u00E1rio do Invent\u00E1rio
view_dashboardsManager_mashup_title = Novidades do RHQ
view_dashboardsManager_message_title = Bem vindo ao RHQ
diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ru.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ru.properties
index 0c6c6dd..53706d4 100644
--- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ru.properties
+++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ru.properties
@@ -1479,6 +1479,9 @@
#view_dashboardManager_success = Saved dashboard
#view_dashboard_favorites_error1 = Failed to load favorite Resources.
#view_dashboardsManager_error1 = Failed to add new dashboard
+##view_dashboardsManager_error2 = Failed to load dashboard portlet.
+##view_dashboardsManager_error3 = Failed to add portlet to dashboard.
+##view_dashboardsManager_error4 = Failed to draw dashboard portlet.
#view_dashboardsManager_message_title_details = <h1>Welcome to {0}</h1>\n<p>The RHQ project is an abstraction and plug-in based systems management suite that provides extensible and integrated systems management for multiple products and platforms across a set of core features. The project is designed with layered modules that provide a flexible architecture for deployment. It delivers a core user interface that delivers audited and historical management across an entire enterprise. A Server/Agent architecture provides remote management and plugins implement all specific support for managed products.</p>\n <p>This default dashboard can be edited by clicking the (edit mode) button above.</p>
#view_dashboards_confirm1 = Are you sure you want to delete
#view_dashboards_portlets_refresh_fail1 = Failed to update interval for portlets that auto-refresh
diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_zh.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_zh.properties
index 2e67a61..aa41bf4 100644
--- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_zh.properties
+++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_zh.properties
@@ -1580,6 +1580,9 @@ view_dashboardManager_saved = \u4fdd\u5b58\u7edf\u8ba1\u8868\u76d8{0}
view_dashboardManager_success = \u6210\u529f\u4fdd\u5b58\u7edf\u8ba1\u8868\u76d8
view_dashboard_favorites_error1 = \u52a0\u8f7d\u5e38\u7528\u8d44\u6e90\u5931\u8d25.
view_dashboardsManager_error1 = \u6dfb\u52a0\u65b0\u7edf\u8ba1\u8868\u76d8\u5931\u8d25
+##view_dashboardsManager_error2 = Failed to load dashboard portlet.
+##view_dashboardsManager_error3 = Failed to add portlet to dashboard.
+##view_dashboardsManager_error4 = Failed to draw dashboard portlet.
##view_dashboardsManager_message_title_details = <h1>Welcome to {0}</h1>\n<p>This dashboard can be edited by clicking the (Edit Mode) button above.</p>\n<p>What would you like to do?</p>\n<p> <a href=\"{1}\">Import newly discovered resources.</a></p>\n<p> <a href=\"{2}\">Search for resources.</a></p>\n<p> <a href=\"{3}\">See help and documentation.</a></p>
view_dashboards_confirm1 = \u60a8\u786e\u5b9a\u8981\u5220\u9664\uff1f
##view_dashboards_portlets_refresh_fail1 = \u4fee\u6539portlets\u81ea\u52a8\u5237\u65b0\u7684\u95f4\u9694\u65f6\u95f4\u5931\u8d25
10 years, 5 months
[rhq] modules/enterprise
by Jay Shaughnessy
modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/client/menu/MenuBarView.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit 16adc9f87e8090781ea444c5080d9428d1b4427d
Author: Jay Shaughnessy <jshaughn(a)redhat.com>
Date: Thu Jan 9 09:35:21 2014 -0500
[1038293] About box empty on second viewing
Fixed.
diff --git a/modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/client/menu/MenuBarView.java b/modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/client/menu/MenuBarView.java
index 93263d8..0cd0178 100644
--- a/modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/client/menu/MenuBarView.java
+++ b/modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/client/menu/MenuBarView.java
@@ -101,7 +101,6 @@ public class MenuBarView extends EnhancedVLayout {
private Canvas getLogoSection() {
final ProductInfo productInfo = CoreGUI.get().getProductInfo();
- final AboutModalWindow aboutModalWindow = new AboutModalWindow(productInfo);
HLayout logoSection = new HLayout();
logoSection.setOverflow(Overflow.VISIBLE);
@@ -109,6 +108,7 @@ public class MenuBarView extends EnhancedVLayout {
Img logo = new Img("header/rhq_logo_28px.png", 80, 28);
logo.addClickHandler(new ClickHandler() {
public void onClick(ClickEvent event) {
+ final AboutModalWindow aboutModalWindow = new AboutModalWindow(productInfo);
aboutModalWindow.show();
}
});
10 years, 5 months
[rhq] modules/enterprise
by John Sanda
modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/MetricsServer.java | 8 ++++----
modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregator.java | 4 ++++
2 files changed, 8 insertions(+), 4 deletions(-)
New commits:
commit 27e749353a4c7680445de3e5a296d07a1e022fec
Author: John Sanda <jsanda(a)redhat.com>
Date: Thu Jan 9 08:29:24 2014 -0500
[BZ 1009945] do not run callback on driver I/O thread and decrease throttling
The previous throttling defaults actually put too much throttling in place to
the point where it led to timeouts. There are two writes for raw data - one for
the actual value and one for the index update. The index update is done in a
future callback. The callback was running in one of the driver's I/O threads.
Because of the increased throttling, driver threads were getting tied up and
eventually timing out. Moving the callback to a separate thread pool resolves
the issue. I am also increasing the default throttling since it was way too
low.
diff --git a/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/MetricsServer.java b/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/MetricsServer.java
index d319146..1b43dc7 100644
--- a/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/MetricsServer.java
+++ b/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/MetricsServer.java
@@ -75,11 +75,11 @@ public class MetricsServer {
private MetricsConfiguration configuration;
- private RateLimiter readPermits = RateLimiter.create(Integer.parseInt(
+ private RateLimiter readPermits = RateLimiter.create(Double.parseDouble(
System.getProperty("rhq.storage.read-limit", "1000")), 3, TimeUnit.MINUTES);
- private RateLimiter writePermits = RateLimiter.create(Integer.parseInt(
- System.getProperty("rhq.storage.write-limit", "2500")), 3, TimeUnit.MINUTES);
+ private RateLimiter writePermits = RateLimiter.create(Double.parseDouble(
+ System.getProperty("rhq.storage.write-limit", "6000")), 3, TimeUnit.MINUTES);
private boolean pastAggregationMissed;
@@ -430,7 +430,7 @@ public class MetricsServer {
}
callback.onFailure(throwable);
}
- });
+ }, aggregationWorkers);
}
} catch (Exception e) {
log.error("An error occurred while inserting raw numeric data ", e);
diff --git a/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregator.java b/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregator.java
index a0b9cce..23b7751 100644
--- a/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregator.java
+++ b/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregator.java
@@ -207,6 +207,7 @@ public class Aggregator {
if (state.is6HourTimeSliceFinished()) {
log.debug("Fetching 1 hour index entries");
Stopwatch stopwatch = new Stopwatch().start();
+ readPermits.acquire();
StorageResultSetFuture oneHourFuture = dao.findMetricsIndexEntriesAsync(MetricsTable.SIX_HOUR,
state.getSixHourTimeSlice().getMillis());
Futures.addCallback(oneHourFuture, new AggregateIndexEntriesHandler(state.getOneHourIndexEntries(),
@@ -217,6 +218,7 @@ public class Aggregator {
if (state.is24HourTimeSliceFinished()) {
log.debug("Fetching 6 hour index entries");
Stopwatch stopwatch = new Stopwatch().start();
+ readPermits.acquire();
StorageResultSetFuture sixHourFuture = dao.findMetricsIndexEntriesAsync(MetricsTable.TWENTY_FOUR_HOUR,
state.getTwentyFourHourTimeSlice().getMillis());
Futures.addCallback(sixHourFuture, new AggregateIndexEntriesHandler(state.getSixHourIndexEntries(),
@@ -243,6 +245,7 @@ public class Aggregator {
log.debug("Preparing to submit 1 hour data aggregation tasks for " +
state.getOneHourIndexEntries().size() + " schedules");
for (Integer scheduleId : state.getOneHourIndexEntries()) {
+ readPermits.acquire();
queryFutures.add(dao.findOneHourMetricsAsync(scheduleId, state.getSixHourTimeSlice().getMillis(),
state.getSixHourTimeSliceEnd().getMillis()));
scheduleIds.add(scheduleId);
@@ -284,6 +287,7 @@ public class Aggregator {
log.debug("Preparing to submit 6 hour data aggregation tasks for " +
state.getSixHourIndexEntries().size() + " schedules");
for (Integer scheduleId : state.getSixHourIndexEntries()) {
+ readPermits.acquire();
queryFutures.add(dao.findSixHourMetricsAsync(scheduleId, state.getTwentyFourHourTimeSlice().getMillis(),
state.getTwentyFourHourTimeSliceEnd().getMillis()));
scheduleIds.add(scheduleId);
10 years, 5 months
[rhq] modules/enterprise
by John Sanda
modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregate1HourData.java | 7 ++++++-
modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/AggregateRawData.java | 9 +++++++--
modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregator.java | 8 ++++----
3 files changed, 17 insertions(+), 7 deletions(-)
New commits:
commit e41f54a089c8864576abc846ec60e481f7d3da0e
Author: John Sanda <jsanda(a)redhat.com>
Date: Wed Jan 8 14:39:04 2014 -0500
[BZ BZ 1009945] missed a couple RateLimiter.acquire() calls
diff --git a/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregate1HourData.java b/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregate1HourData.java
index 1698b28..1548865 100644
--- a/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregate1HourData.java
+++ b/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregate1HourData.java
@@ -11,6 +11,7 @@ import com.google.common.util.concurrent.FutureCallback;
import com.google.common.util.concurrent.FutureFallback;
import com.google.common.util.concurrent.Futures;
import com.google.common.util.concurrent.ListenableFuture;
+import com.google.common.util.concurrent.RateLimiter;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
@@ -39,12 +40,15 @@ class Aggregate1HourData implements Runnable {
private List<StorageResultSetFuture> queryFutures;
+ private RateLimiter readPermits;
+
public Aggregate1HourData(MetricsDAO dao, AggregationState state, Set<Integer> scheduleIds,
- List<StorageResultSetFuture> queryFutures) {
+ List<StorageResultSetFuture> queryFutures, RateLimiter readPermits) {
this.dao = dao;
this.state = state;
this.scheduleIds = scheduleIds;
this.queryFutures = queryFutures;
+ this.readPermits = readPermits;
}
@Override
@@ -90,6 +94,7 @@ class Aggregate1HourData implements Runnable {
update6HourIndexEntries();
List<StorageResultSetFuture> queryFutures = new ArrayList<StorageResultSetFuture>(scheduleIds.size());
for (Integer scheduleId : scheduleIds) {
+ readPermits.acquire();
queryFutures.add(dao.findSixHourMetricsAsync(scheduleId, state.getTwentyFourHourTimeSlice().getMillis(),
state.getTwentyFourHourTimeSliceEnd().getMillis()));
}
diff --git a/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/AggregateRawData.java b/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/AggregateRawData.java
index 87a7266..80682ff 100644
--- a/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/AggregateRawData.java
+++ b/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/AggregateRawData.java
@@ -11,6 +11,7 @@ import com.google.common.util.concurrent.FutureCallback;
import com.google.common.util.concurrent.FutureFallback;
import com.google.common.util.concurrent.Futures;
import com.google.common.util.concurrent.ListenableFuture;
+import com.google.common.util.concurrent.RateLimiter;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
@@ -39,12 +40,15 @@ class AggregateRawData implements Runnable {
private List<StorageResultSetFuture> queryFutures;
+ private RateLimiter readPermits;
+
public AggregateRawData(MetricsDAO dao, AggregationState state, Set<Integer> scheduleIds,
- List<StorageResultSetFuture> queryFutures) {
+ List<StorageResultSetFuture> queryFutures, RateLimiter readPermits) {
this.dao = dao;
this.state = state;
this.scheduleIds = scheduleIds;
this.queryFutures = queryFutures;
+ this.readPermits = readPermits;
}
@Override
@@ -92,11 +96,12 @@ class AggregateRawData implements Runnable {
List<StorageResultSetFuture> oneHourDataQueryFutures = new ArrayList<StorageResultSetFuture>(
scheduleIds.size());
for (Integer scheduleId : scheduleIds) {
+ readPermits.acquire();
oneHourDataQueryFutures.add(dao.findOneHourMetricsAsync(scheduleId,
state.getSixHourTimeSlice().getMillis(), state.getSixHourTimeSliceEnd().getMillis()));
}
state.getAggregationTasks().submit(new Aggregate1HourData(dao, state, scheduleIds,
- oneHourDataQueryFutures));
+ oneHourDataQueryFutures, readPermits));
}
} catch (InterruptedException e) {
if (log.isDebugEnabled()) {
diff --git a/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregator.java b/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregator.java
index bf0bc1a..a0b9cce 100644
--- a/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregator.java
+++ b/modules/enterprise/server/server-metrics/src/main/java/org/rhq/server/metrics/aggregation/Aggregator.java
@@ -172,14 +172,14 @@ public class Aggregator {
endTime.getMillis()));
if (rawDataFutures.size() == batchSize) {
state.getAggregationTasks().submit(new AggregateRawData(dao, state, scheduleIds,
- rawDataFutures));
+ rawDataFutures, readPermits));
rawDataFutures = new ArrayList<StorageResultSetFuture>();
scheduleIds = new TreeSet<Integer>();
}
}
if (!rawDataFutures.isEmpty()) {
state.getAggregationTasks().submit(new AggregateRawData(dao, state, scheduleIds,
- rawDataFutures));
+ rawDataFutures, readPermits));
}
if (log.isDebugEnabled()) {
@@ -248,14 +248,14 @@ public class Aggregator {
scheduleIds.add(scheduleId);
if (queryFutures.size() == batchSize) {
state.getAggregationTasks().submit(new Aggregate1HourData(dao, state, scheduleIds,
- queryFutures));
+ queryFutures, readPermits));
queryFutures = new ArrayList<StorageResultSetFuture>(batchSize);
scheduleIds = new TreeSet<Integer>();
}
}
if (!queryFutures.isEmpty()) {
state.getAggregationTasks().submit(new Aggregate1HourData(dao, state, scheduleIds,
- queryFutures));
+ queryFutures, readPermits));
queryFutures = null;
scheduleIds = null;
}
10 years, 5 months
[rhq] 2 commits - modules/core modules/enterprise
by Jay Shaughnessy
dev/null |binary
modules/core/domain/intentional-api-changes-since-4.9.0.xml | 10
modules/enterprise/server/itests-2/src/test/resources/obsolete/README.txt | 3
modules/enterprise/server/itests-2/src/test/resources/obsolete/default.persistence.properties | 22
modules/enterprise/server/itests-2/src/test/resources/obsolete/ejb-jar.xml | 41
modules/enterprise/server/itests-2/src/test/resources/obsolete/ejb3-interceptors-aop.xml | 360 -------
modules/enterprise/server/itests-2/src/test/resources/obsolete/embedded-jboss-beans.xml | 168 ---
modules/enterprise/server/itests-2/src/test/resources/obsolete/jboss-jms-beans.xml | 132 --
modules/enterprise/server/itests-2/src/test/resources/obsolete/log4j.xml | 99 -
modules/enterprise/server/itests-2/src/test/resources/obsolete/logging/log4j.properties | 17
modules/enterprise/server/itests-2/src/test/resources/obsolete/login-config.xml | 72 -
modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/alert/test/AlertManagerBeanTest.xml | 84 -
modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-1.txt | 5
modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-2.txt | 5
modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_plugin_v1.xml | 59 -
modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_plugin_v2.xml | 73 -
modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_remove_types_v1.xml | 54 -
modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_remove_types_v2.xml | 8
modules/enterprise/server/itests-2/src/test/resources/obsolete/persistence.xml | 53 -
modules/enterprise/server/itests-2/src/test/resources/obsolete/rhq-mdb-beans.xml | 25
modules/enterprise/server/itests-2/src/test/resources/obsolete/security-beans.xml | 13
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/all_no_tx_ds.xml | 97 -
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/app_auth_type_ds.xml | 32
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/bad.xsl | 6
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/container_and_app_auth_type_ds.xml | 32
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/container_auth_type_ds.xml | 32
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/generic_ds.xml | 66 -
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/hsqldb_ds.xml | 106 --
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/hsqldb_encrypted_ds.xml | 125 --
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/informix_ds.xml | 34
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/minimal_hsqldb_ds.xml | 24
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/msaccess_ds.xml | 32
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/no_auth_type_ds.xml | 32
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_2_ds.xml | 44
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_3_ds.xml | 43
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_4_ds.xml | 42
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_5_ds.xml | 40
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_ds.xml | 44
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/too_many_ds.xml | 106 --
modules/enterprise/server/itests-2/src/test/resources/obsolete/test/xpath_processor_test.xml | 42
modules/enterprise/server/itests-2/src/test/resources/obsolete/testng.bak.xml | 12
modules/enterprise/server/itests-2/src/test/resources/obsolete/transform/template_ds.xml | 6
modules/enterprise/server/itests-2/src/test/resources/obsolete/transform/transform.xsl | 514 ----------
modules/enterprise/server/itests-2/src/test/resources/obsolete/validation/datasourceResources.properties | 142 --
modules/enterprise/server/itests-2/src/test/resources/obsolete/validation/datasource_validation.xml | 159 ---
modules/enterprise/server/itests-2/src/test/resources/obsolete/validation/default_validator_rules.xml | 47
modules/enterprise/server/itests-2/src/test/resources/obsolete/velocity/local-datasource.vm | 8
47 files changed, 5 insertions(+), 3165 deletions(-)
New commits:
commit 654de81e06a660bec3446eb2a1ba2498f5b50564
Author: Jay Shaughnessy <jshaughn(a)redhat.com>
Date: Wed Jan 8 10:43:02 2014 -0500
After quite some time it seems proven that these files are not used to
support any server jar i-tests. Removing...
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/README.txt b/modules/enterprise/server/itests-2/src/test/resources/obsolete/README.txt
deleted file mode 100644
index 9eac50a..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/README.txt
+++ /dev/null
@@ -1,3 +0,0 @@
-The obsolete subdirectory holds all test resources that existed under server jar but have
-have not yet shown to be needed to run the actual set of current container-based tests. They
-may be obsolete. As needed we can move files out of here and directly under resources.
\ No newline at end of file
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/default.persistence.properties b/modules/enterprise/server/itests-2/src/test/resources/obsolete/default.persistence.properties
deleted file mode 100644
index 8e4f317..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/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-2/src/test/resources/obsolete/ejb-jar.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/ejb-jar.xml
deleted file mode 100644
index b3deb45..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/ejb-jar.xml
+++ /dev/null
@@ -1,41 +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_1.xsd"
- version="3.1">
-
- <description>RHQ</description>
- <display-name>RHQ</display-name>
-
- <interceptors>
- <interceptor>
- <interceptor-class>org.rhq.enterprise.server.authz.RequiredPermissionsInterceptor</interceptor-class>
- </interceptor>
- <interceptor>
- <interceptor-class>org.rhq.enterprise.server.common.TransactionInterruptInterceptor</interceptor-class>
- </interceptor>
- <interceptor>
- <interceptor-class>org.rhq.enterprise.server.common.PerformanceMonitorInterceptor</interceptor-class>
- </interceptor>
- </interceptors>
-
- <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-2/src/test/resources/obsolete/ejb3-interceptors-aop.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/ejb3-interceptors-aop.xml
deleted file mode 100644
index f30aa70..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/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-2/src/test/resources/obsolete/embedded-jboss-beans.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/embedded-jboss-beans.xml
deleted file mode 100644
index 85e2fb3..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/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-2/src/test/resources/obsolete/jboss-jms-beans.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/jboss-jms-beans.xml
deleted file mode 100644
index 287cffc..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/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-2/src/test/resources/obsolete/log4j.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/log4j.xml
deleted file mode 100644
index e65d303..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/log4j.xml
+++ /dev/null
@@ -1,99 +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 information and examples see the Jakarta Log4j
- | website: 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="ERROR"/>
-
- <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>
-
- <category name="STDOUT" additivity="false">
- <priority value="INFO"/>
- </category>
-
- <category name="STDERR" additivity="false">
- <priority value="ERROR"/>
- </category>
-
- <category name="org">
- <priority value="WARN"/>
- </category>
-
- <category name="org.rhq">
- <priority value="DEBUG"/>
- </category>
-
- <category name="org.rhq.enterprise.server.scheduler.SchedulerService">
- <priority value="WARN"/>
- </category>
-
- <category name="org.rhq.enterprise.server.configuration.ConfigurationManagerBean">
- <priority value="WARN"/>
- </category>
-
- <!-- 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-2/src/test/resources/obsolete/logging/log4j.properties b/modules/enterprise/server/itests-2/src/test/resources/obsolete/logging/log4j.properties
deleted file mode 100644
index 4e7a50d..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/logging/log4j.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-log4j.rootCategory=INFO, FILE
-
-log4j.appender.FILE=org.apache.log4j.DailyRollingFileAppender
-log4j.appender.FILE.DatePattern='.'yyyy-MM-dd
-log4j.appender.FILE.File=./target/unit-test.log
-log4j.appender.FILE.layout=org.apache.log4j.PatternLayout
-log4j.appender.FILE.layout.ConversionPattern=%d{ABSOLUTE} %-5p %c %m%n
-#log4j.appender.A1.layout.ConversionPattern=%d [%t] %-5p %c - %m%n
-log4j.appender.FILE.Append=false
-
-# turn the following on...
-#log4j.logger.com.jboss=INFO
-#log4j.logger.org.jbpm=TRACE
-
-# and the following off...
-# without turning this down you get a spurious "couldn't set xml parser property" warning.
-#log4j.logger.org.jbpm.jpdl.xml.JpdlParser=ERROR
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/login-config.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/login-config.xml
deleted file mode 100644
index 645294d..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/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-2/src/test/resources/obsolete/org/rhq/enterprise/server/alert/test/AlertManagerBeanTest.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/alert/test/AlertManagerBeanTest.xml
deleted file mode 100644
index 475cd0a..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/alert/test/AlertManagerBeanTest.xml
+++ /dev/null
@@ -1,84 +0,0 @@
-<dataset>
- <rhq_resource_type id="1"
- name="AlertManagerBeanTest_Platform"
- plugin="AlertManagerBeanTest_Plugin"
- category="PLATFORM"
- creation_data_type="CONFIGURATION"
- create_delete_policy="BOTH"
- singleton="false"
- supports_manual_add="false"
- deleted="false"/>
-
- <rhq_resource id="1"
- resource_key="1"
- name="test1"
- resource_type_id="1"
- uuid="-10000000000000000000000000000000000"
- inventory_status="COMMITTED"
- connected="false"/>
-
- <rhq_alert_definition id="1"
- name="alerttest"
- enabled="true"
- priority="HIGH"
- resource_id="1"
- dampening_category="0"
- dampening_value="0"
- dampening_period="0"
- required="1"
- recovery_id="0"
- ctime="12345"
- mtime="12345"/>
- <rhq_alert_definition id="2"
- name="delete_by_type_def"
- enabled="true"
- priority="HIGH"
- resource_type_id="1"
- dampening_category="0"
- dampening_value="0"
- dampening_period="0"
- required="1"
- recovery_id="0"
- ctime="12345"
- mtime="12345"/>
-
- <rhq_alert_condition id="1"
- alert_definition_id="1"
- type="AVAILABILITY"
- comparator="=="/>
- <rhq_alert_condition id="2"
- alert_definition_id="2"
- type="AVAILABILITY"
- comparator="=="/>
-
- <rhq_alert id="1"
- alert_definition_id="1"
- ctime="12345"
- recovery_id="0"/>
- <rhq_alert id="2"
- alert_definition_id="2"
- ctime="12345"
- recovery_id="0"/>
-
- <rhq_alert_condition_log id="1"
- ctime="12345"
- condition_id="1"
- value="dummy value"
- alert_id="1"/>
- <rhq_alert_condition_log id="2"
- ctime="12345"
- condition_id="2"
- value="dummy value"
- alert_id="2"/>
-
- <rhq_alert_notif_log id="1"
- alert_id="1"
- sender="dummy"
- result_state="SUCCESS"
- message="message"/>
- <rhq_alert_notif_log id="2"
- alert_id="2"
- sender="dummy"
- result_state="SUCCESS"
- message="message"/>
-</dataset>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-1.txt b/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-1.txt
deleted file mode 100644
index fec744d..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-1.txt
+++ /dev/null
@@ -1,5 +0,0 @@
-test-1
-/test
-C
-dir 1
-aaaaa 0 filename.ext A
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-1.zip b/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-1.zip
deleted file mode 100644
index 6dd62f5..0000000
Binary files a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-1.zip and /dev/null differ
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-2.txt b/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-2.txt
deleted file mode 100644
index af59629..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-2.txt
+++ /dev/null
@@ -1,5 +0,0 @@
-test-1
-/test
-D
-dir 1
-bbbbb aaaaa filename.ext C
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-2.zip b/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-2.zip
deleted file mode 100644
index 95e7a76..0000000
Binary files a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/drift/changeset-2.zip and /dev/null differ
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_plugin_v1.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_plugin_v1.xml
deleted file mode 100644
index 944bd20..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_plugin_v1.xml
+++ /dev/null
@@ -1,59 +0,0 @@
-<plugin name="TestPlugin" displayName="Test Plugin" package="org.rhq.plugins.test"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns="urn:xmlns:rhq-plugin"
- xmlns:c="urn:xmlns:rhq-configuration">
- <server name="ServerA" description="Server A description">
- <subcategories>
- <subcategory name="Resources" description="Resources subcategory"/>
- <subcategory name="Applications" description="Applications subcategory"/>
- </subcategories>
-
- <plugin-configuration>
- <c:simple-property name="connectionPropertyX" default="x"/>
- <c:simple-property name="connectionPropertyY" default="y"/>
- </plugin-configuration>
-
- <process-scan name="serverA" query="process|basename|match=^java.*,arg|org.jboss.Main|match=.*"/>
-
- <operation name="start">
- <parameters>
- <c:simple-property name="immediate" type="boolean"/>
- </parameters>
- <results>
- <c:simple-property name="exitCode" type="integer"/>
- </results>
- </operation>
-
- <operation name="stop">
- <parameters>
- <c:simple-property name="immediate" type="boolean"/>
- </parameters>
- <results>
- <c:simple-property name="exitCode" type="integer"/>
- </results>
- </operation>
-
- <metric displayName="Metric 1" property="metric1" displayType="summary" defaultInterval="300000"/>
- <metric displayName="Metric 2" property="metric2" displayType="summary" defaultInterval="300000"/>
-
- <event name="logAEntry" description="an entry was appended to a log file"/>
- <event name="logBEntry" description="an entry was appended to a log file"/>
-
- <content name="ServerA.Content.1" category="deployable">
- <configuration>
- <c:simple-property name="ServerA.Content.1.version"/>
- </configuration>
- </content>
-
- <content name="ServerA.Content.2" category="deployable">
- <configuration>
- <c:simple-property name="ServerA.Content.2.version"/>
- </configuration>
- </content>
-
- <service name="Child1" description="Child 1 description"/>
- <service name="Child2" description="Child 2 description"/>
- </server>
-
- <server name="ServerB" description="Server B description"/>
-</plugin>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_plugin_v2.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_plugin_v2.xml
deleted file mode 100644
index ca79943..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_plugin_v2.xml
+++ /dev/null
@@ -1,73 +0,0 @@
-<plugin name="TestPlugin" displayName="Test Plugin" package="org.rhq.plugins.test"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns="urn:xmlns:rhq-plugin"
- xmlns:c="urn:xmlns:rhq-configuration">
- <server name="ServerA" description="Server A description">
-
- <subcategories>
- <subcategory name="Resources" description="Resources subcategory"/>
- <subcategory name="Applications" description="Applications subcategory"/>
- </subcategories>
-
- <plugin-configuration>
- <c:simple-property name="connectionPropertyX" default="x"/>
- <c:simple-property name="connectionPropertyY" default="y"/>
- </plugin-configuration>
-
- <process-scan name="processA" query="process|basename|match=^java.*,arg|org.jboss.MainA|match=.*"/>
- <process-scan name="processB" query="process|basename|match=^java.*,arg|org.jboss.MainB|match=.*"/>
-
- <operation name="start">
- <parameters>
- <c:simple-property name="immediate" type="boolean"/>
- </parameters>
- <results>
- <c:simple-property name="exitCode" type="integer"/>
- </results>
- </operation>
-
- <operation name="shutdown">
- <parameters>
- <c:simple-property name="immediate" type="boolean"/>
- </parameters>
- <results>
- <c:simple-property name="exitCode" type="integer"/>
- </results>
- </operation>
-
- <operation name="restart">
- <parameters>
- <c:simple-property name="immediate" type="boolean"/>
- </parameters>
- <results>
- <c:simple-property name="exitCode" type="integer"/>
- </results>
- </operation>
-
- <metric displayName="Metric 1" property="metric1" displayType="summary" defaultInterval="300000"/>
- <metric displayName="Metric 2" property="metric2" displayType="summary" defaultInterval="300000"/>
-
- <event name="logAEntry" description="an entry was appended to a log file"/>
- <event name="logCEntry" description="an entry was appended to a log file"/>
-
- <content name="ServerA.Content.1" category="configuration">
- <configuration>
- <c:simple-property name="ServerA.Content.1.property1"/>
- <c:simple-property name="ServerA.Content.1.property2"/>
- </configuration>
- </content>
-
- <content name="ServerA.Content.3" category="deployable">
- <configuration>
- <c:simple-property name="ServerA.Content.3.version"/>
- </configuration>
- </content>
-
- <service name="Child1"/>
- <service name="Child3"/>
- </server>
-
- <server name="ServerB" description="Server B description">
- <service name="Child2"/>
- </server>
-</plugin>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_remove_types_v1.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_remove_types_v1.xml
deleted file mode 100644
index 60a9f93..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_remove_types_v1.xml
+++ /dev/null
@@ -1,54 +0,0 @@
-<plugin name="RemoveTypesPlugin" displayName="Remove Types Plugin" package="org.rhq.plugins.test"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns="urn:xmlns:rhq-plugin"
- xmlns:c="urn:xmlns:rhq-configuration">
- <server name="ServerC" description="Server C description">
-
- <subcategories>
- <subcategory name="ServerC.Category1">
- <subcategory name="ServerC.NestedCategory1"/>
- </subcategory>
- <subcategory name="ServerC.Category2"/>
- </subcategories>
-
- <bundle type="Test Bundle"/>
-
- <process-scan name="scan1" query="process|basename|match=^java.*,arg|org.rhq.serverC1|match=.*"/>
- <process-scan name="scan2" query="process|basename|match=^java.*,arg|org.rhq.serverC2|match=.*"/>
-
- <operation name="run">
- <parameters>
- <c:simple-property name="script"/>
- </parameters>
- <results>
- <c:simple-property name="errors"/>
- </results>
- </operation>
-
- <metric displayName="Metric 1" property="ServerC::metric1" displayType="summary" defaultInterval="300000"/>
-
- <event name="serverCEvent" description="an entry was appended to a log file"/>
-
- <content name="ServerC.Content" category="deployable">
- <configuration>
- <c:simple-property name="ServerC.Content.version"/>
- </configuration>
- </content>
- </server>
-
- <server name="ServerD">
- <service name="ServerD.Child1">
- <service name="ServerD.GrandChild1"/>
- </service>
- </server>
-
- <server name="ServerE">
- <service name="ServiceE1">
- <service name="ServiceE2">
- <service name="ServiceE3">
- <service name="serviceE4"/>
- </service>
- </service>
- </service>
- </server>
-</plugin>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_remove_types_v2.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_remove_types_v2.xml
deleted file mode 100644
index 6b0cdb0..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/org/rhq/enterprise/server/resource/metadata/ResourceMetadataManagerBeanTest_remove_types_v2.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-<plugin name="RemoveTypesPlugin" displayName="Remove Types Plugin" package="org.rhq.plugins.test"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns="urn:xmlns:rhq-plugin"
- xmlns:c="urn:xmlns:rhq-configuration">
- <server name="ServerD">
- <service name="ServerD.GrandChild1"/>
- </server>
-</plugin>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/persistence.jar b/modules/enterprise/server/itests-2/src/test/resources/obsolete/persistence.jar
deleted file mode 100644
index fe807c8..0000000
Binary files a/modules/enterprise/server/itests-2/src/test/resources/obsolete/persistence.jar and /dev/null differ
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/persistence.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/persistence.xml
deleted file mode 100644
index 0785870..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/persistence.xml
+++ /dev/null
@@ -1,53 +0,0 @@
-<!--
- ~ RHQ Management Platform
- ~ Copyright (C) 2005-2012 Red Hat, Inc.
- ~ All rights reserved.
- ~
- ~ 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.
--->
-
-<persistence
- version="2.0"
- xmlns="http://java.sun.com/xml/ns/persistence"
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="
- http://java.sun.com/xml/ns/persistence
- http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd">
- <persistence-unit name="rhqpu">
- <jta-data-source>java:jboss/datasources/RHQDS</jta-data-source>
-
- <properties>
- <!-- This allows us to lookup the EMF by name prior to when Arquillian injects it, which is currently only in the @Test,
- and not the @BeforeMethod (1.0.1.Final) -->
- <property
- name="jboss.entity.manager.factory.jndi.name"
- value="java:jboss/RHQEntityManagerFactory" />
-
-
- <!--
- <property name="hibernate.show_sql" value="true" />
- <property name="hibernate.format_sql" value="true" />
- <property name="hibernate.use_sql_comments" value="true" />
- -->
-
- <property
- name="hibernate.jdbc.batch_size"
- value="30" />
- <property
- name="hibernate.cache.use_second_level_cache"
- value="false" />
-
- </properties>
- </persistence-unit>
-</persistence>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/rhq-mdb-beans.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/rhq-mdb-beans.xml
deleted file mode 100644
index ad05b5e..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/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-2/src/test/resources/obsolete/security-beans.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/security-beans.xml
deleted file mode 100644
index 84fa819..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/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-2/src/test/resources/obsolete/test/all_no_tx_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/all_no_tx_ds.xml
deleted file mode 100644
index 34a3977..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/all_no_tx_ds.xml
+++ /dev/null
@@ -1,97 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<datasources>
- <no-tx-datasource>
- <jndi-name>jndiName</jndi-name>
- <use-java-context/>
- <connection-url>jdbc:hsqldb:hsql://localhost:1701</connection-url>
-
- <!-- The driver class -->
- <driver-class>org.hsqldb.jdbcDriver</driver-class>
-
- <!-- The login and password -->
- <user-name>sa</user-name>
- <password>bob</password>
-
- <!--example of how to specify class that determines if exception means connection should be destroyed-->
- <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.DummyExceptionSorter</exception-sorter-class-name>
-
-
- <application-managed-security/>
- <security-domain>domain</security-domain>
- <security-domain-and-application>domain2</security-domain-and-application>
-
- <!-- this will be run before a managed connection is removed from the pool for use by a client-->
- <check-valid-connection-sql>select * from something</check-valid-connection-sql>
-
- <!-- The minimum connections in a pool/sub-pool. Pools are lazily constructed on first use -->
- <min-pool-size>5</min-pool-size>
-
- <!-- The maximum connections in a pool/sub-pool -->
- <max-pool-size>20</max-pool-size>
-
- <connection-property name="test">testvalue</connection-property>
- <connection-property name="test2">testvalue2</connection-property>
-
- <!-- The time before an unused connection is destroyed -->
- <!-- NOTE: This is the check period. It will be destroyed somewhere between 1x and 2x this timeout after last use -->
- <!-- TEMPORARY FIX! - Disable idle connection removal, HSQLDB has a problem with not reaping threads on closed connections -->
- <idle-timeout-minutes>0</idle-timeout-minutes>
-
- <!-- sql to call when connection is created -->
- <new-connection-sql>some arbitrary sql</new-connection-sql>
-
- <blocking-timeout-millis>5000</blocking-timeout-millis>
- <!-- sql to call on an existing pooled connection when it is obtained from pool -->
- <check-valid-connection-sql>some arbitrary sql</check-valid-connection-sql>
- -->
-
- <!-- example of how to specify a class that determines a connection is valid before it is handed out from the pool-->
- <valid-connection-checker-class-name>org.jboss.resource.adapter.jdbc.vendor.DummyValidConnectionChecker</valid-connection-checker-class-name>
-
-
- <!-- Whether to check all statements are closed when the connection is returned to the pool,
- this is a debugging feature that should be turned off in production -->
- <track-statements/>
-
- <prepared-statement-cache-size>15</prepared-statement-cache-size>
-
- <!-- Use the getConnection(user, pw) for logins
- <application-managed-security/>
- -->
-
- <!-- Use the security domain defined in conf/login-config.xml
- <security-domain>HsqlDbRealm</security-domain>
- -->
-
- <!-- Use the security domain defined in conf/login-config.xml or the
- getConnection(user, pw) for logins. The security domain takes precedence.
- <security-domain-and-application>HsqlDbRealm</security-domain-and-application>
- -->
-
- <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
- <metadata>
- <type-mapping>Hypersonic SQL</type-mapping>
- </metadata>
-
- <!-- This mbean can be used when using in process persistent hypersonic -->
- <depends>jboss:service=Hypersonic,database=localDB</depends>
- </no-tx-datasource>
-
- <mbean code="org.jboss.jdbc.HypersonicDatabase"
- name="jboss:service=Hypersonic">
- <attribute name="Port">1701</attribute>
- <attribute name="Silent">true</attribute>
- <attribute name="Database">default</attribute>
- <attribute name="Trace">false</attribute>
- <attribute name="No_system_exit">true</attribute>
- </mbean>
-
-
-
- <mbean code="org.jboss.jdbc.HypersonicDatabase"
- name="jboss:service=Hypersonic,database=localDB">
- <attribute name="Database">localDB</attribute>
- <attribute name="InProcessMode">true</attribute>
- </mbean>
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/app_auth_type_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/app_auth_type_ds.xml
deleted file mode 100644
index d9fa3f0..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/app_auth_type_ds.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<datasources>
- <no-tx-datasource>
- <jndi-name>jndiName</jndi-name>
- <application-managed-security/>
- <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
- <metadata>
- <type-mapping>Hypersonic SQL</type-mapping>
- </metadata>
-
- <!-- This mbean can be used when using in process persistent hypersonic -->
- <depends>jboss:service=Hypersonic,database=localDB</depends>
- </no-tx-datasource>
-
- <mbean code="org.jboss.jdbc.HypersonicDatabase"
- name="jboss:service=Hypersonic">
- <attribute name="Port">1701</attribute>
- <attribute name="Silent">true</attribute>
- <attribute name="Database">default</attribute>
- <attribute name="Trace">false</attribute>
- <attribute name="No_system_exit">true</attribute>
- </mbean>
-
-
-
- <mbean code="org.jboss.jdbc.HypersonicDatabase"
- name="jboss:service=Hypersonic,database=localDB">
- <attribute name="Database">localDB</attribute>
- <attribute name="InProcessMode">true</attribute>
- </mbean>
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/bad.xsl b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/bad.xsl
deleted file mode 100644
index 2aac602..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/bad.xsl
+++ /dev/null
@@ -1,6 +0,0 @@
-<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
-
-can't have this here
-
-
-</xsl:stylesheet>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/container_and_app_auth_type_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/container_and_app_auth_type_ds.xml
deleted file mode 100644
index b85e14c..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/container_and_app_auth_type_ds.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<datasources>
- <no-tx-datasource>
- <jndi-name>jndiName</jndi-name>
- <security-domain-and-application>domain2</security-domain-and-application>
- <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
- <metadata>
- <type-mapping>Hypersonic SQL</type-mapping>
- </metadata>
-
- <!-- This mbean can be used when using in process persistent hypersonic -->
- <depends>jboss:service=Hypersonic,database=localDB</depends>
- </no-tx-datasource>
-
- <mbean code="org.jboss.jdbc.HypersonicDatabase"
- name="jboss:service=Hypersonic">
- <attribute name="Port">1701</attribute>
- <attribute name="Silent">true</attribute>
- <attribute name="Database">default</attribute>
- <attribute name="Trace">false</attribute>
- <attribute name="No_system_exit">true</attribute>
- </mbean>
-
-
-
- <mbean code="org.jboss.jdbc.HypersonicDatabase"
- name="jboss:service=Hypersonic,database=localDB">
- <attribute name="Database">localDB</attribute>
- <attribute name="InProcessMode">true</attribute>
- </mbean>
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/container_auth_type_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/container_auth_type_ds.xml
deleted file mode 100644
index a16b7d0..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/container_auth_type_ds.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<datasources>
- <no-tx-datasource>
- <jndi-name>jndiName</jndi-name>
- <security-domain>domain</security-domain>
- <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
- <metadata>
- <type-mapping>Hypersonic SQL</type-mapping>
- </metadata>
-
- <!-- This mbean can be used when using in process persistent hypersonic -->
- <depends>jboss:service=Hypersonic,database=localDB</depends>
- </no-tx-datasource>
-
- <mbean code="org.jboss.jdbc.HypersonicDatabase"
- name="jboss:service=Hypersonic">
- <attribute name="Port">1701</attribute>
- <attribute name="Silent">true</attribute>
- <attribute name="Database">default</attribute>
- <attribute name="Trace">false</attribute>
- <attribute name="No_system_exit">true</attribute>
- </mbean>
-
-
-
- <mbean code="org.jboss.jdbc.HypersonicDatabase"
- name="jboss:service=Hypersonic,database=localDB">
- <attribute name="Database">localDB</attribute>
- <attribute name="InProcessMode">true</attribute>
- </mbean>
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/generic_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/generic_ds.xml
deleted file mode 100644
index b6dd079..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/generic_ds.xml
+++ /dev/null
@@ -1,66 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- ===================================================================== -->
-<!-- -->
-<!-- Generic datasource configuration showing all possibilities -->
-<!-- -->
-<!-- ===================================================================== -->
-
-<!-- $Id: generic_ds.xml 695 2005-09-17 00:43:05Z ccrouch $ -->
-
-
-<datasources>
- <local-tx-datasource>
- <jndi-name>GenericDS</jndi-name>
- <connection-url>[jdbc: url for use with Driver class]</connection-url>
- <driver-class>[fully qualified class name of java.sql.Driver implementation]</driver-class>
- <user-name>x</user-name>
- <password>y</password>
- <!-- you can include connection properties that will get passed in
- the DriverManager.getConnection(props) call-->
- <!-- look at your Driver docs to see what these might be -->
- <connection-property name="char.encoding">UTF-8</connection-property>
- <transaction-isolation>TRANSACTION_SERIALIZABLE</transaction-isolation>
-
- <!--pooling parameters-->
- <min-pool-size>5</min-pool-size>
- <max-pool-size>100</max-pool-size>
- <blocking-timeout-millis>5000</blocking-timeout-millis>
- <idle-timeout-minutes>15</idle-timeout-minutes>
- <!-- sql to call when connection is created -->
- <new-connection-sql>select * from user where name=$</new-connection-sql>
-
-
- <!-- sql to call on an existing pooled connection when it is obtained from pool -->
- <check-valid-connection-sql>some arbitrary sql</check-valid-connection-sql>
-
-
-
- <!-- pooling criteria. USE AT MOST ONE-->
- <!-- If you don't use JAAS login modules or explicit login
- getConnection(usr,pw) but rely on user/pw specified above,
- don't specify anything here -->
-
- <!-- If you supply the usr/pw from a JAAS login module
- <security-domain>MyRealm</security-domain>
--->
-
- <!-- if your app supplies the usr/pw explicitly getConnection(usr, pw) -->
- <application-managed-security/>
-
- <!--Anonymous depends elements are copied verbatim into the ConnectionManager mbean config-->
- <depends>myapp.service:service=DoSomethingService</depends>
-
- </local-tx-datasource>
-
- <!-- you can include regular mbean configurations like this one -->
- <mbean code="org.jboss.tm.XidFactory"
- name="jboss:service=XidFactory">
- <attribute name="Pad">true</attribute>
- </mbean>
-
-
-
-
-
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/hsqldb_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/hsqldb_ds.xml
deleted file mode 100644
index d96a740..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/hsqldb_ds.xml
+++ /dev/null
@@ -1,106 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- The Hypersonic embedded database JCA connection factory config
-$Id: hsqldb_ds.xml 695 2005-09-17 00:43:05Z ccrouch $ -->
-
-
-<datasources>
- <local-tx-datasource>
-
- <!-- The jndi name of the DataSource, it is prefixed with java:/ -->
- <!-- Datasources are not available outside the virtual machine -->
- <jndi-name>DefaultDS</jndi-name>
- <use-java-context/>
- <!-- for tcp connection, allowing other processes to use the hsqldb
- database. This requires the org.jboss.jdbc.HypersonicDatabase mbean.
- <connection-url>jdbc:hsqldb:hsql://localhost:1701</connection-url>
--->
- <!-- for totally in-memory db, not saved when jboss stops.
- The org.jboss.jdbc.HypersonicDatabase mbean necessary
- <connection-url>jdbc:hsqldb:.</connection-url>
--->
- <!-- for in-process persistent db, saved when jboss stops. The
- org.jboss.jdbc.HypersonicDatabase mbean is necessary for properly db shutdown
--->
- <connection-url>jdbc:hsqldb:${jboss.server.data.dir}${/}hypersonic${/}localDB</connection-url>
-
- <!-- The driver class -->
- <driver-class>org.hsqldb.jdbcDriver</driver-class>
-
- <!-- The login and password -->
- <user-name>sa</user-name>
- <password></password>
-
- <!--example of how to specify class that determines if exception means connection should be destroyed-->
- <!--exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.DummyExceptionSorter</exception-sorter-class-name-->
-
- <!-- this will be run before a managed connection is removed from the pool for use by a client-->
- <!--<check-valid-connection-sql>select * from something</check-valid-connection-sql> -->
-
- <!-- The minimum connections in a pool/sub-pool. Pools are lazily constructed on first use -->
- <min-pool-size>5</min-pool-size>
-
- <!-- The maximum connections in a pool/sub-pool -->
- <max-pool-size>20</max-pool-size>
-
- <!-- The time before an unused connection is destroyed -->
- <!-- NOTE: This is the check period. It will be destroyed somewhere between 1x and 2x this timeout after last use -->
- <!-- TEMPORARY FIX! - Disable idle connection removal, HSQLDB has a problem with not reaping threads on closed connections -->
- <idle-timeout-minutes>0</idle-timeout-minutes>
-
- <!-- sql to call when connection is created
- <new-connection-sql>some arbitrary sql</new-connection-sql>
- -->
-
- <!-- sql to call on an existing pooled connection when it is obtained from pool
- <check-valid-connection-sql>some arbitrary sql</check-valid-connection-sql>
- -->
-
- <!-- example of how to specify a class that determines a connection is valid before it is handed out from the pool
- <valid-connection-checker-class-name>org.jboss.resource.adapter.jdbc.vendor.DummyValidConnectionChecker</valid-connection-checker-class-name>
- -->
-
- <!-- Whether to check all statements are closed when the connection is returned to the pool,
- this is a debugging feature that should be turned off in production -->
- <track-statements/>
-
- <!-- Use the getConnection(user, pw) for logins
- <application-managed-security/>
- -->
-
- <!-- Use the security domain defined in conf/login-config.xml -->
- <security-domain>HsqlDbRealm</security-domain>
-
- <!-- Use the security domain defined in conf/login-config.xml or the
- getConnection(user, pw) for logins. The security domain takes precedence.
- <security-domain-and-application>HsqlDbRealm</security-domain-and-application>
- -->
-
- <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
- <metadata>
- <type-mapping>Hypersonic SQL</type-mapping>
- </metadata>
-
- <!-- This mbean can be used when using in process persistent hypersonic -->
- <depends>jboss:service=Hypersonic,database=localDB</depends>
- </local-tx-datasource>
-
- <!-- This mbean should be used only when using tcp connections. Uncomment
- when the tcp based connection-url is used.
- <mbean code="org.jboss.jdbc.HypersonicDatabase"
- name="jboss:service=Hypersonic">
- <attribute name="Port">1701</attribute>
- <attribute name="Silent">true</attribute>
- <attribute name="Database">default</attribute>
- <attribute name="Trace">false</attribute>
- <attribute name="No_system_exit">true</attribute>
- </mbean>
- -->
-
- <!-- This mbean can be used when using in process persistent db -->
- <mbean code="org.jboss.jdbc.HypersonicDatabase"
- name="jboss:service=Hypersonic,database=localDB">
- <attribute name="Database">localDB</attribute>
- <attribute name="InProcessMode">true</attribute>
- </mbean>
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/hsqldb_encrypted_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/hsqldb_encrypted_ds.xml
deleted file mode 100644
index 9a2e38d..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/hsqldb_encrypted_ds.xml
+++ /dev/null
@@ -1,125 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- The Hypersonic embedded database JCA connection factory config
-that illustrates the use of the JaasSecurityDomainIdentityLoginModule
-to use encrypted password in the data source configuration.
-
-$Id: hsqldb_encrypted_ds.xml 695 2005-09-17 00:43:05Z ccrouch $ -->
-
-
-<datasources>
- <local-tx-datasource>
-
- <!-- The jndi name of the DataSource, it is prefixed with java:/ -->
- <!-- Datasources are not available outside the virtual machine -->
- <jndi-name>DefaultDS</jndi-name>
-
- <!-- for tcp connection, allowing other processes to use the hsqldb
- database. This requires the org.jboss.jdbc.HypersonicDatabase mbean.
- <connection-url>jdbc:hsqldb:hsql://localhost:1701</connection-url>
- -->
- <!-- for totally in-memory db, not saved when jboss stops.
- The org.jboss.jdbc.HypersonicDatabase mbean necessary
- <connection-url>jdbc:hsqldb:.</connection-url>
- -->
- <!-- for in-process persistent db, saved when jboss stops. The
- org.jboss.jdbc.HypersonicDatabase mbean is necessary for properly db shutdown
- -->
- <connection-url>jdbc:hsqldb:${jboss.server.data.dir}${/}hypersonic${/}localDB</connection-url>
-
- <!-- The driver class -->
- <driver-class>org.hsqldb.jdbcDriver</driver-class>
-
- <!--example of how to specify class that determines if exception means connection should be destroyed-->
- <!--exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.DummyExceptionSorter</exception-sorter-class-name-->
-
- <!-- this will be run before a managed connection is removed from the pool for use by a client-->
- <!--<check-valid-connection-sql>select * from something</check-valid-connection-sql> -->
-
- <!-- The minimum connections in a pool/sub-pool. Pools are lazily constructed on first use -->
- <min-pool-size>5</min-pool-size>
-
- <!-- The maximum connections in a pool/sub-pool -->
- <max-pool-size>20</max-pool-size>
-
- <!-- The time before an unused connection is destroyed -->
- <!-- NOTE: This is the check period. It will be destroyed somewhere between 1x and 2x this timeout after last use -->
- <!-- TEMPORARY FIX! - Disable idle connection removal, HSQLDB has a problem with not reaping threads on closed connections -->
- <idle-timeout-minutes>0</idle-timeout-minutes>
-
- <!-- sql to call when connection is created
- <new-connection-sql>some arbitrary sql</new-connection-sql>
- -->
-
- <!-- sql to call on an existing pooled connection when it is obtained from pool
- <check-valid-connection-sql>some arbitrary sql</check-valid-connection-sql>
- -->
-
- <!-- example of how to specify a class that determines a connection is valid before it is handed out from the pool -->
- <valid-connection-checker-class-name>org.jboss.resource.adapter.jdbc.vendor.DummyValidConnectionChecker</valid-connection-checker-class-name>
-
-
- <!-- Whether to check all statements are closed when the connection is returned to the pool,
- this is a debugging feature that should be turned off in production -->
- <track-statements/>
-
- <!-- Use the getConnection(user, pw) for logins
- <application-managed-security/>
- -->
-
- <!-- Use the security domain defined in conf/login-config.xml -->
- <security-domain>EncryptedHsqlDbRealm</security-domain>
-
- <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
- <metadata>
- <type-mapping>Hypersonic SQL</type-mapping>
- </metadata>
-
- <!-- This mbean can be used when using in process persistent hypersonic -->
- <depends>jboss:service=Hypersonic,database=localDB</depends>
- </local-tx-datasource>
-
- <!-- The JaasSecurityDomain used for encryption. Use the name
- "jboss.security:service=JaasSecurityDomain,domain=ServerMasterPassword"
- as the value of the JaasSecurityDomainIdentityLoginModule
- jaasSecurityDomain login module option in the EncryptedHsqlDbRealm
- login-config.xml section. Typically this service config should be in
- the conf/jboss-service.xml descriptor.
- The opaque master.password file could be created using:
- java -cp jbosssx.jar org.jboss.security.plugins.FilePassword 12345678 17 master server.password
-
- The corresponding login-config.xml would look like:
- <application-policy name = "EncryptedHsqlDbRealm">
- <authentication>
- <login-module code = "org.jboss.resource.security.JaasSecurityDomainIdentityLoginModule"
- flag = "required">
- <module-option name = "username">sa</module-option>
- <module-option name = "password">E5gtGMKcXPP</module-option>
- <module-option name = "managedConnectionFactoryName">jboss.jca:service=LocalTxCM,name=DefaultDS</module-option>
- <module-option name = "jaasSecurityDomain">jboss.security:service=JaasSecurityDomain,domain=ServerMasterPassword</module-option>
- </login-module>
- </authentication>
- </application-policy>
- where the encrypted password was generated using:
- java -cp jbosssx.jar org.jboss.security.plugins.PBEUtils abcdefgh 13 master ''
- Encoded password: E5gtGMKcXPP
- -->
- <mbean code="org.jboss.security.plugins.JaasSecurityDomain"
- name="jboss.security:service=JaasSecurityDomain,domain=ServerMasterPassword">
- <constructor>
- <arg type="java.lang.String" value="ServerMasterPassword"/>
- </constructor>
- <!-- The opaque master password file used to decrypt the encrypted
- database password key -->
- <attribute name="KeyStorePass">{CLASS}org.jboss.security.plugins.FilePassword:${jboss.server.home.dir}/conf/server.password</attribute>
- <attribute name="Salt">abcdefgh</attribute>
- <attribute name="IterationCount">13</attribute>
- </mbean>
-
- <!-- This mbean can be used when using in process persistent db -->
- <mbean code="org.jboss.jdbc.HypersonicDatabase"
- name="jboss:service=Hypersonic,database=localDB">
- <attribute name="Database">localDB</attribute>
- <attribute name="InProcessMode">true</attribute>
- </mbean>
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/informix_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/informix_ds.xml
deleted file mode 100644
index 95e314a..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/informix_ds.xml
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- ===================================================================== -->
-<!-- -->
-<!-- JBoss Server Configuration -->
-<!-- -->
-<!-- ===================================================================== -->
-
-<!-- $Id: informix_ds.xml 954 2005-11-02 21:56:42Z ccrouch $ -->
-
-
-<datasources>
- <local-tx-datasource>
- <jndi-name>InformixDS</jndi-name>
- <use-java-context>true</use-java-context>
- <connection-url>jdbc:informix-sqli://myhost.mydomain.com:1557/mydb:INFORMIXSERVER=myserver</connection-url>
- <driver-class>com.informix.jdbc.IfxDriver</driver-class>
- <user-name>x</user-name>
- <password>y</password>
- <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.InformixExceptionSorter</exception-sorter-class-name>
- <!-- sql to call when connection is created
- <new-connection-sql>some arbitrary sql</new-connection-sql>
- -->
- <!-- sql to call on an existing pooled connection when it is obtained from pool
- <check-valid-connection-sql>some arbitrary sql</check-valid-connection-sql>
- -->
- <transaction-isolation/>
-
- <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
- <metadata>
- <type-mapping>InformixDB</type-mapping>
- </metadata>
- </local-tx-datasource>
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/minimal_hsqldb_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/minimal_hsqldb_ds.xml
deleted file mode 100644
index 4fb62d9..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/minimal_hsqldb_ds.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- The Hypersonic embedded database JCA connection factory config
-$Id: minimal_hsqldb_ds.xml 680 2005-09-14 01:52:58Z ccrouch $ -->
-
-
-<datasources>
- <local-tx-datasource>
-
- <!-- The jndi name of the DataSource, it is prefixed with java:/ -->
- <!-- Datasources are not available outside the virtual machine -->
- <jndi-name>DefaultDS</jndi-name>
-
- <connection-url attrib="a" >jdbc:hsqldb:${jboss.server.data.dir}${/}hypersonic${/}localDB</connection-url>
- <connection-property name="111">aaa</connection-property>
- <connection-property name="222">bbb</connection-property>
- <connection-property name="444">ddd</connection-property>
- <user-name>jones</user-name>
- </local-tx-datasource>
-
- <mbean name="test">
- <arg>addd</arg>
- </mbean>
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/msaccess_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/msaccess_ds.xml
deleted file mode 100644
index 5f03e7d..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/msaccess_ds.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- ===================================================================== -->
-<!-- -->
-<!-- JBoss Server Configuration -->
-<!-- -->
-<!-- ===================================================================== -->
-
-<!-- $Id: msaccess_ds.xml 695 2005-09-17 00:43:05Z ccrouch $ -->
-<!-- ==================================================================== -->
-<!-- This uses the sun jdbc-odbc driver, so don't expect miracles -->
-<!-- Thanks to Alan Moor, who warns... -->
-<!-- Remember, though, never trust critical data, or data that you can't -->
-<!-- afford to lose, or data that you need quick access to, or data that -->
-<!-- needs to be secure, to Microsoft Access. -->
-<!-- ===================================================================== -->
-
-
-<datasources>
- <no-tx-datasource>
- <jndi-name>MSAccessDS</jndi-name>
- <use-java-context>false</use-java-context>
- <!-- format of URL is "jdbc:odbc:DSNNAME" -->
- <connection-url>jdbc:odbc:INsightDSN</connection-url>
- <driver-class>sun.jdbc.odbc.JdbcOdbcDriver</driver-class>
- <user-name>x</user-name>
- <password>y</password>
- <security-domain-and-application>DbRealm</security-domain-and-application>
- <prepared-statement-cache-size>10</prepared-statement-cache-size>
- </no-tx-datasource>
-
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/no_auth_type_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/no_auth_type_ds.xml
deleted file mode 100644
index 3437a97..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/no_auth_type_ds.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<datasources>
- <no-tx-datasource>
- <jndi-name>jndiName</jndi-name>
-
- <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
- <metadata>
- <type-mapping>Hypersonic SQL</type-mapping>
- </metadata>
-
- <!-- This mbean can be used when using in process persistent hypersonic -->
- <depends>jboss:service=Hypersonic,database=localDB</depends>
- </no-tx-datasource>
-
- <mbean code="org.jboss.jdbc.HypersonicDatabase"
- name="jboss:service=Hypersonic">
- <attribute name="Port">1701</attribute>
- <attribute name="Silent">true</attribute>
- <attribute name="Database">default</attribute>
- <attribute name="Trace">false</attribute>
- <attribute name="No_system_exit">true</attribute>
- </mbean>
-
-
-
- <mbean code="org.jboss.jdbc.HypersonicDatabase"
- name="jboss:service=Hypersonic,database=localDB">
- <attribute name="Database">localDB</attribute>
- <attribute name="InProcessMode">true</attribute>
- </mbean>
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_2_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_2_ds.xml
deleted file mode 100644
index 8ec633a..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_2_ds.xml
+++ /dev/null
@@ -1,44 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- ===================================================================== -->
-<!-- -->
-<!-- JBoss Server Configuration -->
-<!-- -->
-<!-- ===================================================================== -->
-
-<!-- $Id: oracle_xa_2_ds.xml 954 2005-11-02 21:56:42Z ccrouch $ -->
-
-<!-- ===================================================================== -->
-<!-- ATTENTION: DO NOT FORGET TO SET Pad=true IN transaction-service.xml -->
-<!-- ===================================================================== -->
-
-<datasources>
- <xa-datasource>
- <jndi-name>XAOracleDS2</jndi-name>
- <isSameRM-override-value/>
- <xa-datasource-class>oracle.jdbc.xa.client.OracleXADataSource</xa-datasource-class>
- <xa-datasource-property name="URL">
- jdbc:oracle:oci8:@tc</xa-datasource-property>
- <xa-datasource-property name="User">scott</xa-datasource-property>
- <xa-datasource-property name="Password">tiger</xa-datasource-property>
- <!-- Uses the pingDatabase method to check a connection is still valid before handing it out from the pool -->
- <!--valid-connection-checker-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleValidConnectionChecker</valid-connection-checker-class-name-->
- <!-- Checks the Oracle error codes and messages for fatal errors -->
- <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter</exception-sorter-class-name>
- <!-- Oracles XA datasource cannot reuse a connection outside a transaction once enlisted in a global transaction and vice-versa -->
- <no-tx-separate-pools/>
- <track-statements>false</track-statements>
- <track-connection-by-tx>true</track-connection-by-tx>
-
- <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
- <metadata>
- <type-mapping>Oracle9i</type-mapping>
- </metadata>
- </xa-datasource>
-
- <mbean code="org.jboss.resource.adapter.jdbc.vendor.OracleXAExceptionFormatter"
- name="jboss.jca:service=OracleXAExceptionFormatter">
- <depends optional-attribute-name="TransactionManagerService">jboss:service=TransactionManager</depends>
- </mbean>
-
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_3_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_3_ds.xml
deleted file mode 100644
index 7a3d90d..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_3_ds.xml
+++ /dev/null
@@ -1,43 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- ===================================================================== -->
-<!-- -->
-<!-- JBoss Server Configuration -->
-<!-- -->
-<!-- ===================================================================== -->
-
-<!-- $Id: oracle_xa_3_ds.xml 942 2005-11-02 05:46:41Z ccrouch $ -->
-
-<!-- ===================================================================== -->
-<!-- ATTENTION: DO NOT FORGET TO SET Pad=true IN transaction-service.xml -->
-<!-- ===================================================================== -->
-
-<datasources>
- <xa-datasource>
- <jndi-name>XAOracleDS3</jndi-name>
- <xa-datasource-class>oracle.jdbc.xa.client.OracleXADataSource</xa-datasource-class>
- <xa-datasource-property name="URL">
- jdbc:oracle:oci8:@tc</xa-datasource-property>
- <xa-datasource-property name="User">scott</xa-datasource-property>
- <xa-datasource-property name="Password">tiger</xa-datasource-property>
- <!-- Uses the pingDatabase method to check a connection is still valid before handing it out from the pool -->
- <!--valid-connection-checker-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleValidConnectionChecker</valid-connection-checker-class-name-->
- <!-- Checks the Oracle error codes and messages for fatal errors -->
- <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter</exception-sorter-class-name>
- <!-- Oracles XA datasource cannot reuse a connection outside a transaction once enlisted in a global transaction and vice-versa -->
- <no-tx-separate-pools>false</no-tx-separate-pools>
- <track-statements>nowarn</track-statements>
- <track-connection-by-tx>false</track-connection-by-tx>
-
- <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
- <metadata>
- <type-mapping>Oracle9i</type-mapping>
- </metadata>
- </xa-datasource>
-
- <mbean code="org.jboss.resource.adapter.jdbc.vendor.OracleXAExceptionFormatter"
- name="jboss.jca:service=OracleXAExceptionFormatter">
- <depends optional-attribute-name="TransactionManagerService">jboss:service=TransactionManager</depends>
- </mbean>
-
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_4_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_4_ds.xml
deleted file mode 100644
index c83ecf7..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_4_ds.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- ===================================================================== -->
-<!-- -->
-<!-- JBoss Server Configuration -->
-<!-- -->
-<!-- ===================================================================== -->
-
-<!-- $Id: oracle_xa_4_ds.xml 942 2005-11-02 05:46:41Z ccrouch $ -->
-
-<!-- ===================================================================== -->
-<!-- ATTENTION: DO NOT FORGET TO SET Pad=true IN transaction-service.xml -->
-<!-- ===================================================================== -->
-
-<datasources>
- <xa-datasource>
- <jndi-name>XAOracleDS4</jndi-name>
- <isSameRM-override-value>false</isSameRM-override-value>
- <xa-datasource-class>oracle.jdbc.xa.client.OracleXADataSource</xa-datasource-class>
- <xa-datasource-property name="URL">
- jdbc:oracle:oci8:@tc</xa-datasource-property>
- <xa-datasource-property name="User">scott</xa-datasource-property>
- <xa-datasource-property name="Password">tiger</xa-datasource-property>
- <!-- Uses the pingDatabase method to check a connection is still valid before handing it out from the pool -->
- <!--valid-connection-checker-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleValidConnectionChecker</valid-connection-checker-class-name-->
- <!-- Checks the Oracle error codes and messages for fatal errors -->
- <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter</exception-sorter-class-name>
-
-
-
- <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
- <metadata>
- <type-mapping>Oracle9i</type-mapping>
- </metadata>
- </xa-datasource>
-
- <mbean code="org.jboss.resource.adapter.jdbc.vendor.OracleXAExceptionFormatter"
- name="jboss.jca:service=OracleXAExceptionFormatter">
- <depends optional-attribute-name="TransactionManagerService">jboss:service=TransactionManager</depends>
- </mbean>
-
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_5_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_5_ds.xml
deleted file mode 100644
index 12c1970..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_5_ds.xml
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- ===================================================================== -->
-<!-- -->
-<!-- JBoss Server Configuration -->
-<!-- -->
-<!-- ===================================================================== -->
-
-<!-- $Id: oracle_xa_5_ds.xml 1151 2006-01-18 02:54:28Z ccrouch $ -->
-
-<!-- ===================================================================== -->
-<!-- ATTENTION: DO NOT FORGET TO SET Pad=true IN transaction-service.xml -->
-<!-- ===================================================================== -->
-
-<datasources>
- <xa-datasource>
- <jndi-name>XAOracleDS</jndi-name>
- <isSameRM-override-value>false</isSameRM-override-value>
- <xa-datasource-class>oracle.jdbc.xa.client.OracleXADataSource</xa-datasource-class>
- <!-- Uses the pingDatabase method to check a connection is still valid before handing it out from the pool -->
- <!--valid-connection-checker-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleValidConnectionChecker</valid-connection-checker-class-name-->
- <!-- Checks the Oracle error codes and messages for fatal errors -->
- <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter</exception-sorter-class-name>
- <!-- Oracles XA datasource cannot reuse a connection outside a transaction once enlisted in a global transaction and vice-versa -->
- <no-tx-separate-pools/>
-
- <track-connection-by-tx/>
-
- <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
- <metadata>
- <type-mapping>Oracle9i</type-mapping>
- </metadata>
- </xa-datasource>
-
- <mbean code="org.jboss.resource.adapter.jdbc.vendor.OracleXAExceptionFormatter"
- name="jboss.jca:service=OracleXAExceptionFormatter">
- <depends optional-attribute-name="TransactionManagerService">jboss:service=TransactionManager</depends>
- </mbean>
-
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_ds.xml
deleted file mode 100644
index 3a755fa..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/oracle_xa_ds.xml
+++ /dev/null
@@ -1,44 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- ===================================================================== -->
-<!-- -->
-<!-- JBoss Server Configuration -->
-<!-- -->
-<!-- ===================================================================== -->
-
-<!-- $Id: oracle_xa_ds.xml 942 2005-11-02 05:46:41Z ccrouch $ -->
-
-<!-- ===================================================================== -->
-<!-- ATTENTION: DO NOT FORGET TO SET Pad=true IN transaction-service.xml -->
-<!-- ===================================================================== -->
-
-<datasources>
- <xa-datasource>
- <jndi-name>XAOracleDS</jndi-name>
- <isSameRM-override-value>false</isSameRM-override-value>
- <xa-datasource-class>oracle.jdbc.xa.client.OracleXADataSource</xa-datasource-class>
- <xa-datasource-property name="URL">
- jdbc:oracle:oci8:@tc</xa-datasource-property>
- <xa-datasource-property name="User">scott</xa-datasource-property>
- <xa-datasource-property name="Password">tiger</xa-datasource-property>
- <!-- Uses the pingDatabase method to check a connection is still valid before handing it out from the pool -->
- <!--valid-connection-checker-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleValidConnectionChecker</valid-connection-checker-class-name-->
- <!-- Checks the Oracle error codes and messages for fatal errors -->
- <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter</exception-sorter-class-name>
- <!-- Oracles XA datasource cannot reuse a connection outside a transaction once enlisted in a global transaction and vice-versa -->
- <no-tx-separate-pools/>
-
- <track-connection-by-tx/>
-
- <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
- <metadata>
- <type-mapping>Oracle9i</type-mapping>
- </metadata>
- </xa-datasource>
-
- <mbean code="org.jboss.resource.adapter.jdbc.vendor.OracleXAExceptionFormatter"
- name="jboss.jca:service=OracleXAExceptionFormatter">
- <depends optional-attribute-name="TransactionManagerService">jboss:service=TransactionManager</depends>
- </mbean>
-
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/too_many_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/too_many_ds.xml
deleted file mode 100644
index aa1ee56..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/too_many_ds.xml
+++ /dev/null
@@ -1,106 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- ===================================================================== -->
-<!-- -->
-<!-- Generic datasource configuration showing all possibilities -->
-<!-- -->
-<!-- ===================================================================== -->
-
-<!-- $Id: too_many_ds.xml 695 2005-09-17 00:43:05Z ccrouch $ -->
-
-
-<datasources>
- <local-tx-datasource>
- <jndi-name>GenericDS</jndi-name>
- <connection-url>[jdbc: url for use with Driver class]</connection-url>
- <driver-class>[fully qualified class name of java.sql.Driver implementation]</driver-class>
- <user-name>x</user-name>
- <password>y</password>
- <!-- you can include connection properties that will get passed in
- the DriverManager.getConnection(props) call-->
- <!-- look at your Driver docs to see what these might be -->
- <connection-property name="char.encoding">UTF-8</connection-property>
- <transaction-isolation>TRANSACTION_SERIALIZABLE</transaction-isolation>
-
- <!--pooling parameters-->
- <min-pool-size>5</min-pool-size>
- <max-pool-size>100</max-pool-size>
- <blocking-timeout-millis>5000</blocking-timeout-millis>
- <idle-timeout-minutes>15</idle-timeout-minutes>
- <!-- sql to call when connection is created -->
- <new-connection-sql>select * from user where name=$</new-connection-sql>
-
-
- <!-- sql to call on an existing pooled connection when it is obtained from pool -->
- <check-valid-connection-sql>some arbitrary sql</check-valid-connection-sql>
-
-
-
- <!-- pooling criteria. USE AT MOST ONE-->
- <!-- If you don't use JAAS login modules or explicit login
- getConnection(usr,pw) but rely on user/pw specified above,
- don't specify anything here -->
-
- <!-- If you supply the usr/pw from a JAAS login module
- <security-domain>MyRealm</security-domain>
--->
-
- <!-- if your app supplies the usr/pw explicitly getConnection(usr, pw) -->
- <application-managed-security/>
-
- <!--Anonymous depends elements are copied verbatim into the ConnectionManager mbean config-->
- <depends>myapp.service:service=DoSomethingService</depends>
-
- </local-tx-datasource>
-
- <!-- you can include regular mbean configurations like this one -->
- <mbean code="org.jboss.tm.XidFactory"
- name="jboss:service=XidFactory">
- <attribute name="Pad">true</attribute>
- </mbean>
-
-
- <!-- Here's an xa example -->
- <xa-datasource>
- <jndi-name>GenericXADS</jndi-name>
- <xa-datasource-class>[fully qualified name of class implementing javax.sql.XADataSource goes here]</xa-datasource-class>
- <xa-datasource-property name="SomeProperty">SomePropertyValue</xa-datasource-property>
- <xa-datasource-property name="SomeOtherProperty">SomeOtherValue</xa-datasource-property>
-
- <user-name>x</user-name>
- <password>y</password>
- <transaction-isolation>TRANSACTION_SERIALIZABLE</transaction-isolation>
-
-
-
- <!--pooling parameters-->
- <min-pool-size>5</min-pool-size>
- <max-pool-size>100</max-pool-size>
- <blocking-timeout-millis>5000</blocking-timeout-millis>
- <idle-timeout-minutes>15</idle-timeout-minutes>
- <!-- sql to call when connection is created
- <new-connection-sql>some arbitrary sql</new-connection-sql>
- -->
-
- <!-- sql to call on an existing pooled connection when it is obtained from pool
- <check-valid-connection-sql>some arbitrary sql</check-valid-connection-sql>
- -->
-
-
- <!-- pooling criteria. USE AT MOST ONE-->
- <!-- If you don't use JAAS login modules or explicit login
- getConnection(usr,pw) but rely on user/pw specified above,
- don't specify anything here -->
-
- <!-- If you supply the usr/pw from a JAAS login module -->
- <security-domain/>
-
- <!-- if your app supplies the usr/pw explicitly getConnection(usr, pw) -->
- <application-managed-security/>
-
- </xa-datasource>
-
-
-
-
-</datasources>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/xpath_processor_test.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/xpath_processor_test.xml
deleted file mode 100644
index 0b23849..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/test/xpath_processor_test.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<xpathproc>
- <test1></test1>
- <test2/>
- <!-- <test3/> -->
- <test4>4</test4>
- <test5>
- 5
- </test5>
- <test6><!-- test -->6</test6>
- <test7>
- YYY
- <!-- test -->
- 7
- </test7>
-
- <test8>
- 8
- <!-- test -->
- ZZZ
- </test8>
-
- <test9>
-
- <!-- test -->
- 9
- </test9>
-
- <test10 name="test10">10</test10>
-
- <test11 name="test11">
- 11</test11>
-
- <test12 name="test12"><!-- test -->12</test12>
-
- <test13 name="test13
- ">13</test13>
-
- <test14> </test14>
-
-</xpathproc>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/testng.bak.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/testng.bak.xml
deleted file mode 100644
index 1452edb..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/testng.bak.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>
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/transform/template_ds.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/transform/template_ds.xml
deleted file mode 100644
index 5b35f56..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/transform/template_ds.xml
+++ /dev/null
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- DataSource configuration file created by JBoss Operations Network-->
-<datasources>
-<dummy/>
-</datasources>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/transform/transform.xsl b/modules/enterprise/server/itests-2/src/test/resources/obsolete/transform/transform.xsl
deleted file mode 100644
index fb9cc79..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/transform/transform.xsl
+++ /dev/null
@@ -1,514 +0,0 @@
-<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:str="http://exslt.org/strings"
- extension-element-prefixes="str" >
-
- <xsl:output
- method="xml"
- indent="yes"
- encoding="UTF-8"
- />
-
- <!-- if a parameter is not passed in, then it will be set to the
- value of the variable UNCHANGED -->
- <xsl:variable name="UNCHANGED" select="'~UNCHANGED~'"/>
-
- <xsl:param name="jndiName" select="$UNCHANGED"/>
- <xsl:param name="userName" select="$UNCHANGED"/>
- <xsl:param name="connectionProperty" select="$UNCHANGED"/>
- <xsl:param name="XADataSourceProperty" select="$UNCHANGED"/>
- <xsl:param name="connectionUrl" select="$UNCHANGED"/>
- <xsl:param name="minPoolSize" select="$UNCHANGED"/>
- <xsl:param name="maxPoolSize" select="$UNCHANGED"/>
- <xsl:param name="transactionIsolation" select="$UNCHANGED"/>
- <xsl:param name="validConnectionChecker" select="$UNCHANGED"/>
- <xsl:param name="useJavaContext" select="$UNCHANGED"/>
- <xsl:param name="domainAndApplicationSecurity" select="$UNCHANGED"/>
- <xsl:param name="applicationManagedSecurity" select="$UNCHANGED"/>
- <xsl:param name="securityDomain" select="$UNCHANGED"/>
- <xsl:param name="newConnectionSQL" select="$UNCHANGED"/>
- <xsl:param name="exceptionSorter" select="$UNCHANGED"/>
- <xsl:param name="password" select="$UNCHANGED"/>
- <xsl:param name="trackStatements" select="$UNCHANGED"/>
- <xsl:param name="checkValidConnectionSQL" select="$UNCHANGED"/>
- <xsl:param name="driverClass" select="$UNCHANGED"/>
- <xsl:param name="XADataSourceClass" select="$UNCHANGED"/>
- <xsl:param name="blockingTimeout" select="$UNCHANGED"/>
- <xsl:param name="preparedStatementCacheSize" select="$UNCHANGED"/>
- <xsl:param name="idleTimeout" select="$UNCHANGED"/>
- <xsl:param name="noTxSeparatePools" select="$UNCHANGED"/>
- <xsl:param name="isSameRMOverrideValue" select="$UNCHANGED"/>
- <xsl:param name="trackConnectionByTx" select="$UNCHANGED"/>
-
- <!-- supply defaults for testing -->
- <xsl:param name="datasourceType">test-type</xsl:param>
- <xsl:param name="nameValueSeparator">||</xsl:param>
- <xsl:param name="elementSeparator">|^|</xsl:param>
-
- <!-- TODO support multiple datasources inside a file -->
-
- <xsl:template match="/datasources">
- <datasources>
- <xsl:apply-templates />
- </datasources>
- </xsl:template>
-
-
- <xsl:template match="local-tx-datasource|xa-datasource|no-tx-datasource|dummy">
- <xsl:element name="{$datasourceType}">
-
- <!-- These should be ordered as specified in the DTD -->
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="jndi-name"/>
- <xsl:with-param name="elementName" select="'jndi-name'"/>
- <xsl:with-param name="parameterValue" select="$jndiName"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="connection-url"/>
- <xsl:with-param name="elementName" select="'connection-url'"/>
- <xsl:with-param name="parameterValue" select="$connectionUrl"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="min-pool-size"/>
- <xsl:with-param name="elementName" select="'min-pool-size'"/>
- <xsl:with-param name="parameterValue" select="$minPoolSize"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="max-pool-size"/>
- <xsl:with-param name="elementName" select="'max-pool-size'"/>
- <xsl:with-param name="parameterValue" select="$maxPoolSize"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="user-name"/>
- <xsl:with-param name="elementName" select="'user-name'"/>
- <xsl:with-param name="parameterValue" select="$userName"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="transaction-isolation"/>
- <xsl:with-param name="elementName" select="'transaction-isolation'"/>
- <xsl:with-param name="parameterValue" select="$transactionIsolation"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="valid-connection-checker-class-name"/>
- <xsl:with-param name="elementName" select="'valid-connection-checker-class-name'"/>
- <xsl:with-param name="parameterValue" select="$validConnectionChecker"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="use-java-context"/>
- <xsl:with-param name="elementName" select="'use-java-context'"/>
- <xsl:with-param name="parameterValue" select="$useJavaContext"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="security-domain-and-application"/>
- <xsl:with-param name="elementName" select="'security-domain-and-application'"/>
- <xsl:with-param name="parameterValue" select="$domainAndApplicationSecurity"/>
- </xsl:call-template>
-
- <xsl:call-template name="addEmptyElementIfSpecifiedTrueAndNotPresent">
- <xsl:with-param name="element" select="application-managed-security"/>
- <xsl:with-param name="elementName" select="'application-managed-security'"/>
- <xsl:with-param name="parameterValue" select="$applicationManagedSecurity"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="security-domain"/>
- <xsl:with-param name="elementName" select="'security-domain'"/>
- <xsl:with-param name="parameterValue" select="$securityDomain"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="new-connection-sql"/>
- <xsl:with-param name="elementName" select="'new-connection-sql'"/>
- <xsl:with-param name="parameterValue" select="$newConnectionSQL"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="exception-sorter-class-name"/>
- <xsl:with-param name="elementName" select="'exception-sorter-class-name'"/>
- <xsl:with-param name="parameterValue" select="$exceptionSorter"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="password"/>
- <xsl:with-param name="elementName" select="'password'"/>
- <xsl:with-param name="parameterValue" select="$password"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="track-statements"/>
- <xsl:with-param name="elementName" select="'track-statements'"/>
- <xsl:with-param name="parameterValue" select="$trackStatements"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="check-valid-connection-sql"/>
- <xsl:with-param name="elementName" select="'check-valid-connection-sql'"/>
- <xsl:with-param name="parameterValue" select="$checkValidConnectionSQL"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="driver-class"/>
- <xsl:with-param name="elementName" select="'driver-class'"/>
- <xsl:with-param name="parameterValue" select="$driverClass"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="xa-datasource-class"/>
- <xsl:with-param name="elementName" select="'xa-datasource-class'"/>
- <xsl:with-param name="parameterValue" select="$XADataSourceClass"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="blocking-timeout-millis"/>
- <xsl:with-param name="elementName" select="'blocking-timeout-millis'"/>
- <xsl:with-param name="parameterValue" select="$blockingTimeout"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="prepared-statement-cache-size"/>
- <xsl:with-param name="elementName" select="'prepared-statement-cache-size'"/>
- <xsl:with-param name="parameterValue" select="$preparedStatementCacheSize"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="idle-timeout-minutes"/>
- <xsl:with-param name="elementName" select="'idle-timeout-minutes'"/>
- <xsl:with-param name="parameterValue" select="$idleTimeout"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="no-tx-separate-pools"/>
- <xsl:with-param name="elementName" select="'no-tx-separate-pools'"/>
- <xsl:with-param name="parameterValue" select="$noTxSeparatePools"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="isSameRM-override-value"/>
- <xsl:with-param name="elementName" select="'isSameRM-override-value'"/>
- <xsl:with-param name="parameterValue" select="$isSameRMOverrideValue"/>
- </xsl:call-template>
-
- <xsl:call-template name="addElementIfSpecifiedAndNotPresent">
- <xsl:with-param name="element" select="track-connection-by-tx"/>
- <xsl:with-param name="elementName" select="'track-connection-by-tx'"/>
- <xsl:with-param name="parameterValue" select="$trackConnectionByTx"/>
- </xsl:call-template>
-
- <!-- don't attempt to add elements if this property hasn't changed -->
- <xsl:if test="$connectionProperty != $UNCHANGED">
- <xsl:variable name="currentConnectionProperties" select="connection-property" />
- <xsl:for-each select="str:split($connectionProperty, $elementSeparator)">
- <xsl:variable name="newNameAttribute" select="substring-before(., $nameValueSeparator)" />
- <!-- if there isn't an existing connection-property element with the
- specified name attribute then go ahead and add one
- -->
- <xsl:if test="not($currentConnectionProperties[@name = $newNameAttribute])">
- <xsl:call-template name="outputPropertyTemplate">
- <xsl:with-param name="nameAttribute" select="$newNameAttribute"/>
- <xsl:with-param name="elementName" select="'connection-property'"/>
- <xsl:with-param name="propertyParameter" select="$connectionProperty"/>
- </xsl:call-template>
- </xsl:if>
- </xsl:for-each>
- </xsl:if>
-
- <!-- don't attempt to add elements if this property hasn't changed -->
- <xsl:if test="$XADataSourceProperty != $UNCHANGED">
- <xsl:variable name="currentXADataSourceProperties" select="xa-datasource-property" />
- <xsl:for-each select="str:split($XADataSourceProperty, $elementSeparator)">
- <xsl:variable name="newNameAttribute" select="substring-before(., $nameValueSeparator)" />
- <!-- if there isn't an existing xa-datasource-property element with the
- specified name attribute then go ahead and add one
- -->
- <xsl:if test="not($currentXADataSourceProperties[@name = $newNameAttribute])">
- <xsl:call-template name="outputPropertyTemplate">
- <xsl:with-param name="nameAttribute" select="$newNameAttribute"/>
- <xsl:with-param name="elementName" select="'xa-datasource-property'"/>
- <xsl:with-param name="propertyParameter" select="$XADataSourceProperty"/>
- </xsl:call-template>
- </xsl:if>
- </xsl:for-each>
- </xsl:if>
-
- <xsl:apply-templates />
-
- </xsl:element>
- </xsl:template>
-
-
- <xsl:template match="jndi-name">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$jndiName"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="user-name">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$userName"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="connection-url">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$connectionUrl"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="min-pool-size">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$minPoolSize"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="max-pool-size">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$maxPoolSize"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="transaction-isolation">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$transactionIsolation"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="valid-connection-checker-class-name">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$validConnectionChecker"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="use-java-context">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$useJavaContext"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="security-domain-and-application">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$domainAndApplicationSecurity"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="application-managed-security">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$applicationManagedSecurity"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="security-domain">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$securityDomain"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="new-connection-sql">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$newConnectionSQL"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="exception-sorter-class-name">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$exceptionSorter"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="password">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$password"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="track-statements">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$trackStatements"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="check-valid-connection-sql">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$checkValidConnectionSQL"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="driver-class">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$driverClass"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="xa-datasource-class">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$XADataSourceClass"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="blocking-timeout-millis">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$blockingTimeout"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="prepared-statement-cache-size">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$preparedStatementCacheSize"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="idle-timeout-minutes">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$idleTimeout"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="no-tx-separate-pools">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$noTxSeparatePools"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="isSameRM-override-value">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$isSameRMOverrideValue"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="track-connection-by-tx">
- <xsl:call-template name="addElementIfSpecified">
- <xsl:with-param name="parameterValue" select="$trackConnectionByTx"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="connection-property">
- <xsl:call-template name="updatePropertyMapTemplate">
- <xsl:with-param name="propertyParameter" select="$connectionProperty"/>
- <xsl:with-param name="elementName" select="'connection-property'"/>
- </xsl:call-template>
- </xsl:template>
-
- <xsl:template match="xa-datasource-property">
- <xsl:call-template name="updatePropertyMapTemplate">
- <xsl:with-param name="propertyParameter" select="$XADataSourceProperty"/>
- <xsl:with-param name="elementName" select="'xa-datasource-property'"/>
- </xsl:call-template>
- </xsl:template>
-
-
- <!-- OUTPUT TEMPLATES -->
-
- <!-- if this property is one we want to set, via the specified parameter,
- then update it, i.e. output the new element, otherwise delete it, i.e. don't output anything.
- If the parameter is unchanged then just output the original property unchanged
- -->
- <xsl:template name="updatePropertyMapTemplate">
- <xsl:param name="propertyParameter"/>
- <xsl:param name="elementName"/>
- <xsl:choose>
- <xsl:when test="$propertyParameter = $UNCHANGED">
- <xsl:copy>
- <xsl:apply-templates select="@*|node()"/>
- </xsl:copy>
- </xsl:when>
- <xsl:when test="contains($propertyParameter, concat(@name,$nameValueSeparator))">
- <xsl:call-template name="outputPropertyTemplate">
- <xsl:with-param name="nameAttribute" select="@name"/>
- <xsl:with-param name="elementName" select="$elementName"/>
- <xsl:with-param name="propertyParameter" select="$propertyParameter"/>
- </xsl:call-template>
- </xsl:when>
- <!-- otherwise don't output anything -->
- </xsl:choose>
- </xsl:template>
-
- <!-- add a new property element -->
- <xsl:template name="outputPropertyTemplate">
- <xsl:param name="nameAttribute"/>
- <xsl:param name="elementName"/>
- <xsl:param name="propertyParameter"/>
- <xsl:element name="{$elementName}">
- <xsl:attribute name="name">
- <xsl:value-of select="$nameAttribute" />
- </xsl:attribute>
- <xsl:value-of select="substring-before(
- substring-after($propertyParameter, concat($nameAttribute, $nameValueSeparator)),
- $elementSeparator)"/>
- </xsl:element>
- </xsl:template>
-
-
- <!-- if the specified 'element' is not present and the 'parameterValue' isn't
- empty then output an element called 'elementName' with the value of
- 'parameterValue' -->
- <xsl:template name="addElementIfSpecifiedAndNotPresent">
- <xsl:param name="element"/>
- <xsl:param name="elementName"/>
- <xsl:param name="parameterValue"/>
- <xsl:if test="not($element) and $parameterValue and $parameterValue != $UNCHANGED">
- <xsl:call-template name="outputElement">
- <xsl:with-param name="elementName" select="$elementName"/>
- <xsl:with-param name="elementValue" select="$parameterValue"/>
- </xsl:call-template>
- </xsl:if>
- </xsl:template>
-
- <!-- this template exists to support generating empty elements.
- The parameterValue must be set to 'true' for the corresponding
- empty element to be created
- -->
- <xsl:template name="addEmptyElementIfSpecifiedTrueAndNotPresent">
- <xsl:param name="element"/>
- <xsl:param name="elementName"/>
- <xsl:param name="parameterValue"/>
- <xsl:if test="not($element) and $parameterValue = 'true'">
- <xsl:call-template name="outputElement">
- <xsl:with-param name="elementName" select="$elementName"/>
- </xsl:call-template>
- </xsl:if>
- </xsl:template>
-
- <!-- if the parameter passed in hasn't been changed then output
- the original elements, else if the parameter isn't empty then output
- an element using it as the value -->
- <xsl:template name="addElementIfSpecified">
- <xsl:param name="parameterValue"/>
- <xsl:choose>
- <xsl:when test="$parameterValue = $UNCHANGED">
- <xsl:copy>
- <xsl:apply-templates select="@*|node()"/>
- </xsl:copy>
- </xsl:when>
- <xsl:when test="$parameterValue">
- <xsl:call-template name="outputElement">
- <xsl:with-param name="elementValue" select="$parameterValue"/>
- </xsl:call-template>
- </xsl:when>
- <!-- otherwise don't output anything -->
- </xsl:choose>
- </xsl:template>
-
- <!-- output an element with the specified name and value -->
- <xsl:template name="outputElement">
- <xsl:param name="elementName" select="name()"/>
- <xsl:param name="elementValue"/>
- <xsl:element name="{$elementName}">
- <xsl:value-of select="$elementValue"/>
- </xsl:element>
- </xsl:template>
-
-
- <!-- let everything we don't care about go through -->
- <xsl:template match="@*|node()" >
- <xsl:copy>
- <xsl:apply-templates select="@*|node()"/>
- </xsl:copy>
- </xsl:template>
-
-</xsl:stylesheet>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/validation/datasourceResources.properties b/modules/enterprise/server/itests-2/src/test/resources/obsolete/validation/datasourceResources.properties
deleted file mode 100644
index 36464c4..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/validation/datasourceResources.properties
+++ /dev/null
@@ -1,142 +0,0 @@
-# The error messages for the Validation Actions
-errors.required=The {0} field is required.
-errors.int=The {0} field should be an integer.
-errors.maxLength=The {0} fields is too long. Should only be {1} characters long.
-
-# The formatted names of the properties
-#datasource.jndiName.displayname=JNDI Name
-
-action.label.CreateDataSourceTemplate=Create a DataSource
-action.label.ReadDataSource=View this DataSource
-action.label.UpdateDataSource=Edit this DataSource
-action.label.CreateNoTxDataSource=Create No-Tx DataSource
-action.label.CreateLocalTxDataSource=Create Local-Tx DataSource
-action.label.CreateXADataSource=Create XA DataSource
-action.label.DeleteDataSource=Delete this DataSource
-action.label.CreateOracleLocalTxDataSource=Create Oracle Local-Tx DataSource
-action.label.CreateOracleXADataSource=Create Oracle XA DataSource
-action.label.CreateMySQLLocalTxDataSource=Create MySQL Local-Tx DataSource
-
-jndiName.label=JNDI Name
-jndiName.desc=The JNDI name under which the DataSource wrapper will be bound.
-
-connectionUrl.label=Connection URL
-connectionUrl.desc=The JDBC driver connection URL string
-
-driverClass.label=Driver Class
-driverClass.desc=The fully qualified name of the JDBC driver class.
-
-XADataSourceClass.label=XA DataSource Class
-XADataSourceClass.desc=The fully qualified name of the JDBC XA datasource class.
-
-userName.label=User Name
-userName.desc=The default username used when creating a new connection.
-
-password.label=Password
-password.desc=The default password used when creating a new connection.
-
-connectionProperty.label=Connection Properties
-connectionProperty.desc=Properties that will get passed in the DriverManager.getConnection(props) call. Look at your Driver docs to see what these might be. Each property should be on a separate line, with the name separated from the value by an equals sign (=).
-
-XADataSourceProperty.label=XA DataSource properties
-XADataSourceProperty.desc=Properties used to configure the XADataSource. Each property should be on a separate line, with the name separated from the value by an equals sign (=).
-
-minPoolSize.label=Minimum Pool Size
-minPoolSize.desc=Indicates the minimum number of connections a pool should hold. These are not created until a Subject is known from a request for a connection. If nothing is specified the default of 0 is used.
-
-maxPoolSize.label=Maximum Pool Size
-maxPoolSize.desc=Indicates the maximum number of connections for a pool. No more than this number of connections will be created in each sub-pool. If nothing is specified the default of 20 is used.
-
-
-# TODO need to consider adding action specification validation
-# so as to support the more complicated validation needed to check this stuff
-
-securityDomain.label=Security Domain
-securityDomain.desc=Indicates Subjects(from security domain) are used to distinguish connections in the pool. The content of the security domain is the name of the JAAS security manager that will handle authentication. This name correlates to the JAAS login-config.xml descriptor application-policy/name attribute. Must be specified if either Container Based or Container and Applicatin Based authentication types are specified.
-
-authenticationType.label=JCA Pool Type
-authenticationType.desc=JBossJCA uses a ManagedConnectionPool to perform the pooling. The ManagedConnectionPool is made up of subpools depending upon the strategy chosen and other pooling parameters. 'Container Based' means a pool per Subject, e.g. preconfigured or EJB/Web login subjects. 'Application Based' means use the connection properties from allocateConnection(). 'Container And Application Based' means a per Subject and connection property combination. The default is just to use a single pool of equivalent connections.
-authenticationType.options.label.0=Default
-authenticationType.options.label.1=Container Based
-authenticationType.options.label.2=Application Based
-authenticationType.options.label.3=Container and Application Based
-
-#applicationManagedSecurity.label=Application Managed Security
-#applicationManagedSecurity.desc=Application Managed Security
-
-#domainAndApplicationSecurity.label=Domain And Application Security
-#domainAndApplicationSecurity.desc=Domain And Application Security
-
-
-
-trackStatements.label=Track Statements
-trackStatements.desc=Whether to check for unclosed statements when a connection is returned to the pool and result sets are closed when a statement is closed/returned to the prepared statement cache. The default is Yes, but no warnings.
-trackStatements.options.label.0=Default
-trackStatements.options.label.1=No
-trackStatements.options.label.2=Yes
-trackStatements.options.label.3=Yes, but no warnings
-
-blockingTimeout.label=Blocking Timeout
-blockingTimeout.desc=Indicates the maximum time in milliseconds to block while waiting for a connection before throwing an exception. Note that this blocks only while waiting for a permit for a connection, and will never throw an exception if creating a new connection takes an inordinately long time. If nothing is specified the default of 30000 milliseconds is used.
-
-idleTimeout.label=Idle Timeout
-idleTimeout.desc=Indicates the maximum time in minutes a connection may be idle before being closed. The actual maximum time depends also on the IdleRemover scan time, which is 1/2 the smallest idle-timeout-minutes of any pool. If nothing is specified the default of 15 minutes is used.
-
-newConnectionSQL.label=New Connection SQL
-newConnectionSQL.desc=Specify an SQL statement to execute whenever a connection is added to the connection pool.
-
-checkValidConnectionSQL.label=Check Valid Connection SQL
-checkValidConnectionSQL.desc=Specify an SQL statement to check validity of a pool connection. This may be called when managed connection is taken from pool for use.
-
-validConnectionChecker.label=Valid Connection Checker
-validConnectionChecker.desc=An org.jboss.resource.adapter.jdbc.ValidConnectionChecker that provides a SQLException isValidConnection(Connection e) method to validate is a connection is valid. An exception means the connection is destroyed. This overrides the check-valid-connection-sql when present.
-
-exceptionSorter.label=Exception Sorter
-exceptionSorter.desc=An org.jboss.resource.adapter.jdbc.ExceptionSorter that provides a boolean isExceptionFatal(SQLException e) method to validate is an exception should be broadcast to all javax.resource.spi.ConnectionEventListener as a connectionErrorOccurred message.
-
-preparedStatementCacheSize.label=Prepared Statement Cache Size
-preparedStatementCacheSize.desc=The number of prepared statements per connection in an LRU cache.
-
-useJavaContext.label=Use Java Context
-useJavaContext.desc=Indicates if the JNDI name should be prefixed with java: which causes the DataSource to only be accessible from within the jboss server vm. The default is Yes.
-useJavaContext.options.label.0=Default
-useJavaContext.options.label.1=Yes
-useJavaContext.options.label.2=No
-
-transactionIsolation.label=Transaction Isolation
-transactionIsolation.desc=The Transaction Isolation level. The default setting is to use whichever isolation level is provided by default by the database.
-transactionIsolation.options.label.0=Default
-transactionIsolation.options.label.1=TRANSACTION NONE
-transactionIsolation.options.label.2=TRANSACTION READ COMMITTED
-transactionIsolation.options.label.3=TRANSACTION READ UNCOMMITTED
-transactionIsolation.options.label.4=TRANSACTION REPEATABLE READ
-transactionIsolation.options.label.5=TRANSACTION SERIALIZABLE
-
-noTxSeparatePools.label=No Tx Separate Pools
-noTxSeparatePools.desc=Whether to use separate pools for connections retrieved in a transaction and those retrieved outside a transaction. The default is Yes.
-noTxSeparatePools.options.label.0=Default
-noTxSeparatePools.options.label.1=Yes
-noTxSeparatePools.options.label.2=No
-
-
-trackConnectionByTx.label=Track Connection By Tx
-trackConnectionByTx.desc=Whether the connection should be "locked" to the transaction, returning it to the pool at the end of the transaction. The default is No.
-trackConnectionByTx.options.label.0=Default
-trackConnectionByTx.options.label.1=Yes
-trackConnectionByTx.options.label.2=No
-
-
-isSameRMOverrideValue.label=isSameRM Override Value
-isSameRMOverrideValue.desc=Allows one to unconditionally set whether the javax.transaction.xa.XAResource.isSameRM(XAResource) returns true or false. The default is not to override the return value.
-isSameRMOverrideValue.options.label.0=Default
-isSameRMOverrideValue.options.label.1=true
-isSameRMOverrideValue.options.label.2=false
-
-dataSourceTemplates.label=DataSource Templates
-dataSourceTemplates.desc=The DataSource types for which Create/Read templates are available
-dataSourceTemplates.options.label.0=Generic XA DataSource
-dataSourceTemplates.options.label.1=Generic Local Tx DataSource
-dataSourceTemplates.options.label.2=Generic No Tx DataSource
-dataSourceTemplates.options.label.3=MySQL Local Tx DataSource
-dataSourceTemplates.options.label.4=Oracle XA DataSource
-dataSourceTemplates.options.label.5=Oracle Local Tx DataSource
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/validation/datasource_validation.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/validation/datasource_validation.xml
deleted file mode 100644
index 3214c1a..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/validation/datasource_validation.xml
+++ /dev/null
@@ -1,159 +0,0 @@
-<!DOCTYPE form-validation PUBLIC
- "-//Apache Software Foundation//DTD Commons Validator Rules Configuration 1.1.3//EN"
- "http://jakarta.apache.org/commons/dtds/validator_1_1_3.dtd">
-
-<form-validation>
-
- <formset>
- <form name="SaveNoTxDataSource">
- <field property="jndiName" depends="required">
- <arg position="0" key="jndiName.label"/>
- </field>
- <field property="connectionUrl" depends="required">
- <arg position="0" key="connectionUrl.label"/>
- </field>
- <field property="driverClass" depends="required">
- <arg position="0" key="driverClass.label"/>
- </field>
- <field property="minPoolSize" depends="optionalInt">
- <arg position="0" key="minPoolSize.label"/>
- </field>
- <field property="maxPoolSize" depends="optionalInt">
- <arg position="0" key="maxPoolSize.label"/>
- </field>
- <field property="blockingTimeout" depends="optionalInt">
- <arg position="0" key="blockingTimeout.label"/>
- </field>
- <field property="idleTimeout" depends="optionalInt">
- <arg position="0" key="idleTimeout.label"/>
- </field>
- <field property="preparedStatementCacheSize" depends="optionalInt">
- <arg position="0" key="preparedStatementCacheSize.label"/>
- </field>
- </form>
- <form name="SaveLocalTxDataSource">
- <field property="jndiName" depends="required">
- <arg position="0" key="jndiName.label"/>
- </field>
- <field property="connectionUrl" depends="required">
- <arg position="0" key="connectionUrl.label"/>
- </field>
- <field property="driverClass" depends="required">
- <arg position="0" key="driverClass.label"/>
- </field>
- <field property="minPoolSize" depends="optionalInt">
- <arg position="0" key="minPoolSize.label"/>
- </field>
- <field property="maxPoolSize" depends="optionalInt">
- <arg position="0" key="maxPoolSize.label"/>
- </field>
- <field property="blockingTimeout" depends="optionalInt">
- <arg position="0" key="blockingTimeout.label"/>
- </field>
- <field property="idleTimeout" depends="optionalInt">
- <arg position="0" key="idleTimeout.label"/>
- </field>
- <field property="preparedStatementCacheSize" depends="optionalInt">
- <arg position="0" key="preparedStatementCacheSize.label"/>
- </field>
- </form>
- <form name="SaveXADataSource">
- <field property="jndiName" depends="required">
- <arg position="0" key="jndiName.label"/>
- </field>
- <field property="XADataSourceClass" depends="required">
- <arg position="0" key="XADataSourceClass.label"/>
- </field>
- <field property="minPoolSize" depends="optionalInt">
- <arg position="0" key="minPoolSize.label"/>
- </field>
- <field property="maxPoolSize" depends="optionalInt">
- <arg position="0" key="maxPoolSize.label"/>
- </field>
- <field property="blockingTimeout" depends="optionalInt">
- <arg position="0" key="blockingTimeout.label"/>
- </field>
- <field property="idleTimeout" depends="optionalInt">
- <arg position="0" key="idleTimeout.label"/>
- </field>
- <field property="preparedStatementCacheSize" depends="optionalInt">
- <arg position="0" key="preparedStatementCacheSize.label"/>
- </field>
- </form>
- <form name="SaveNoTxDataSourceThenScan">
- <field property="jndiName" depends="required">
- <arg position="0" key="jndiName.label"/>
- </field>
- <field property="connectionUrl" depends="required">
- <arg position="0" key="connectionUrl.label"/>
- </field>
- <field property="driverClass" depends="required">
- <arg position="0" key="driverClass.label"/>
- </field>
- <field property="minPoolSize" depends="optionalInt">
- <arg position="0" key="minPoolSize.label"/>
- </field>
- <field property="maxPoolSize" depends="optionalInt">
- <arg position="0" key="maxPoolSize.label"/>
- </field>
- <field property="blockingTimeout" depends="optionalInt">
- <arg position="0" key="blockingTimeout.label"/>
- </field>
- <field property="idleTimeout" depends="optionalInt">
- <arg position="0" key="idleTimeout.label"/>
- </field>
- <field property="preparedStatementCacheSize" depends="optionalInt">
- <arg position="0" key="preparedStatementCacheSize.label"/>
- </field>
- </form>
- <form name="SaveLocalTxDataSourceThenScan">
- <field property="jndiName" depends="required">
- <arg position="0" key="jndiName.label"/>
- </field>
- <field property="connectionUrl" depends="required">
- <arg position="0" key="connectionUrl.label"/>
- </field>
- <field property="driverClass" depends="required">
- <arg position="0" key="driverClass.label"/>
- </field>
- <field property="minPoolSize" depends="optionalInt">
- <arg position="0" key="minPoolSize.label"/>
- </field>
- <field property="maxPoolSize" depends="optionalInt">
- <arg position="0" key="maxPoolSize.label"/>
- </field>
- <field property="blockingTimeout" depends="optionalInt">
- <arg position="0" key="blockingTimeout.label"/>
- </field>
- <field property="idleTimeout" depends="optionalInt">
- <arg position="0" key="idleTimeout.label"/>
- </field>
- <field property="preparedStatementCacheSize" depends="optionalInt">
- <arg position="0" key="preparedStatementCacheSize.label"/>
- </field>
- </form>
- <form name="SaveXADataSourceThenScan">
- <field property="jndiName" depends="required">
- <arg position="0" key="jndiName.label"/>
- </field>
- <field property="XADataSourceClass" depends="required">
- <arg position="0" key="XADataSourceClass.label"/>
- </field>
- <field property="minPoolSize" depends="optionalInt">
- <arg position="0" key="minPoolSize.label"/>
- </field>
- <field property="maxPoolSize" depends="optionalInt">
- <arg position="0" key="maxPoolSize.label"/>
- </field>
- <field property="blockingTimeout" depends="optionalInt">
- <arg position="0" key="blockingTimeout.label"/>
- </field>
- <field property="idleTimeout" depends="optionalInt">
- <arg position="0" key="idleTimeout.label"/>
- </field>
- <field property="preparedStatementCacheSize" depends="optionalInt">
- <arg position="0" key="preparedStatementCacheSize.label"/>
- </field>
- </form>
- </formset>
-</form-validation>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/validation/default_validator_rules.xml b/modules/enterprise/server/itests-2/src/test/resources/obsolete/validation/default_validator_rules.xml
deleted file mode 100644
index 9992659..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/validation/default_validator_rules.xml
+++ /dev/null
@@ -1,47 +0,0 @@
-<!DOCTYPE form-validation PUBLIC
- "-//Apache Software Foundation//DTD Commons Validator Rules Configuration 1.1.3//EN"
- "http://jakarta.apache.org/commons/dtds/validator_1_1_3.dtd">
-
-<form-validation>
- <global>
- <validator name="required"
- classname="com.jboss.jbossnetwork.apl.validation.ActionArgumentsValidator"
- method="validateRequired"
- methodParams="java.lang.Object, org.apache.commons.validator.Field"
- msg="errors.required"/>
-
-<!--
- <validator name="maxLength"
- classname="org.apache.commons.validator.GenericValidator"
- method="maxLength"
- methodParams="java.lang.String, int"
- msg="errors.maxLength"/>
--->
- <validator name="optionalInt"
- classname="com.jboss.jbossnetwork.apl.validation.ActionArgumentsValidator"
- method="validateOptionalInt"
- methodParams="java.lang.Object, org.apache.commons.validator.Field"
- msg="errors.int"/>
-
-<!--
- <validator name="int2"
- classname="com.jboss.jbossnetwork.apl.validation.ActionArgumentsTypeValidator"
- method="validateInt"
- methodParams="java.lang.Object,org.apache.commons.validator.Field"
- msg="errors.int"/>
-
- THIS VALIDATOR STILL NEEDS MORE WORK TO BE REALLY USEFUL
- <validator name="matchesTypeDefinition"
- classname="com.jboss.jbossnetwork.apl.validation.ActionAttributeDefinitionValidator"
- method="matchesTypeDefinition"
- methodParams="java.lang.Object,org.apache.commons.validator.Field"
- msg="errors.type"/>
--->
-
- <validator name="mapValue"
- classname="com.jboss.jbossnetwork.apl.validation.ActionArgumentsValidator"
- method="validateMapParameter"
- methodParams="java.lang.Object, org.apache.commons.validator.Field"
- msg="errors.mapValue"/>
- </global>
-</form-validation>
\ No newline at end of file
diff --git a/modules/enterprise/server/itests-2/src/test/resources/obsolete/velocity/local-datasource.vm b/modules/enterprise/server/itests-2/src/test/resources/obsolete/velocity/local-datasource.vm
deleted file mode 100644
index 2f902a6..0000000
--- a/modules/enterprise/server/itests-2/src/test/resources/obsolete/velocity/local-datasource.vm
+++ /dev/null
@@ -1,8 +0,0 @@
-This is a test DataSource
-
-#if ($jndi-name)
-<jndi-name>$jndi-name<jndi-name>
-#end
-#foreach( $key in $connection-properties.keySet() )
-<connection-property name="$key">$connection-properties.get($key)</connection-property>
-#end
commit dbc2dc61f744ac4d3d82b473aab177619f340fd1
Author: Jay Shaughnessy <jshaughn(a)redhat.com>
Date: Tue Jan 7 09:43:54 2014 -0500
Fixes to intentional API decls
diff --git a/modules/core/domain/intentional-api-changes-since-4.9.0.xml b/modules/core/domain/intentional-api-changes-since-4.9.0.xml
index d520d25..1e41bb4 100644
--- a/modules/core/domain/intentional-api-changes-since-4.9.0.xml
+++ b/modules/core/domain/intentional-api-changes-since-4.9.0.xml
@@ -3,22 +3,22 @@
<difference>
<className>org/rhq/core/domain/discovery/MergeInventoryReportResults</className>
<differenceType>7005</differenceType> <!-- parameter type changed -->
- <method>public MergeInventoryReportResults(org.rhq.core.domain.discovery.ResourceSyncInfo, java.util.Collection)</method>
- <to>public MergeInventoryReportResults(org.rhq.core.domain.discovery.PlatformSyncInfo, java.util.Collection)</to>
+ <method>MergeInventoryReportResults(org.rhq.core.domain.discovery.ResourceSyncInfo, java.util.Collection)</method>
+ <to>MergeInventoryReportResults(org.rhq.core.domain.discovery.PlatformSyncInfo, java.util.Collection)</to>
<justification>Class only used internally for inventory sync</justification>
</difference>
<difference>
<className>org/rhq/core/domain/discovery/MergeInventoryReportResults</className>
<differenceType>7002</differenceType> <!-- method removed -->
- <method>public org.rhq.core.domain.discovery.ResourceSyncInfo getResourceSyncInfo()</method>
+ <method>org.rhq.core.domain.discovery.ResourceSyncInfo getResourceSyncInfo()</method>
<justification>Class only used internally for inventory sync</justification>
</difference>
<difference>
- <className>org/rhq/core/domain/discovery/MergeInventoryReportResults</className>
+ <className>org/rhq/core/domain/discovery/ResourceSyncInfo</className>
<differenceType>7002</differenceType> <!-- method removed -->
- <method>public java.util.Collection getChildSyncInfos()</method>
+ <method>java.util.Collection getChildSyncInfos()</method>
<justification>Class only used internally for inventory sync</justification>
</difference>
</differences>
10 years, 5 months
[rhq] Branch 'heiko/agentFootprint' - 2 commits - modules/core
by Heiko W. Rupp
modules/core/domain/src/main/java/org/rhq/core/domain/configuration/definition/ConfigurationDefinition.java | 7 ++++++-
modules/core/plugin-container/src/main/java/org/rhq/core/pc/inventory/InventoryManager.java | 6 ++++++
2 files changed, 12 insertions(+), 1 deletion(-)
New commits:
commit 23edc140745e55340fb1da1ca4d094b3b471e6b3
Author: Heiko W. Rupp <hwr(a)redhat.com>
Date: Wed Jan 8 12:52:11 2014 +0100
We need to check for null, as via (de)serialization this may end up as null.
diff --git a/modules/core/domain/src/main/java/org/rhq/core/domain/configuration/definition/ConfigurationDefinition.java b/modules/core/domain/src/main/java/org/rhq/core/domain/configuration/definition/ConfigurationDefinition.java
index 5e7457d..7375619 100644
--- a/modules/core/domain/src/main/java/org/rhq/core/domain/configuration/definition/ConfigurationDefinition.java
+++ b/modules/core/domain/src/main/java/org/rhq/core/domain/configuration/definition/ConfigurationDefinition.java
@@ -136,7 +136,12 @@ public class ConfigurationDefinition implements Serializable {
}
public void setName(@NotNull String name) {
- this.name = name.intern();
+ // Need to protect due to possible deserialization from Coregui.
+ if (name!=null) {
+ this.name = name.intern();
+ } else {
+ this.name = null;
+ }
}
public String getDescription() {
commit 7e865e48163639dafa68dfd880fcf5ea4c9ef72b
Author: Heiko W. Rupp <hwr(a)redhat.com>
Date: Wed Jan 8 10:31:17 2014 +0100
Wait between individual top level servers to give other stuff room for breathing.
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 f4a6ea4..d5a183b 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
@@ -1256,6 +1256,12 @@ public class InventoryManager extends AgentService implements ContainerService,
+ hadSyncedResources + "]");
syncInfos = null; // release to GC
+ try {
+ // Wait a little to get other tasks room for breathing
+ Thread.sleep(800L);
+ } catch (InterruptedException e) {
+ ;
+ }
}
}
}
10 years, 5 months
[rhq] Branch 'release/jon3.2.x' - modules/plugins
by lkrejci
modules/plugins/script/pom.xml | 5
modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptArgumentParser.java | 95 ++++++++++
modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptDiscoveryComponent.java | 40 +++-
modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptServerComponent.java | 4
modules/plugins/script/src/main/resources/META-INF/rhq-plugin.xml | 8
modules/plugins/script/src/test/java/org/rhq/plugins/script/ScriptArgumentParserTest.java | 30 +++
6 files changed, 171 insertions(+), 11 deletions(-)
New commits:
commit 7181e17fdbf05fe9e8de563626c4dae35cd5e093
Author: Lukas Krejci <lkrejci(a)redhat.com>
Date: Tue Jan 7 21:43:42 2014 +0100
[BZ 1049608] Support quotes and escapes in script args in script plugin
diff --git a/modules/plugins/script/pom.xml b/modules/plugins/script/pom.xml
index 732b7ed..01954cb 100644
--- a/modules/plugins/script/pom.xml
+++ b/modules/plugins/script/pom.xml
@@ -76,9 +76,6 @@
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
- <configuration>
- <skip>true</skip>
- </configuration>
<executions>
<execution>
<id>surefire-it</id>
@@ -183,4 +180,4 @@
</build>
</profile>
</profiles>
-</project>
\ No newline at end of file
+</project>
diff --git a/modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptArgumentParser.java b/modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptArgumentParser.java
new file mode 100644
index 0000000..cd12f0d
--- /dev/null
+++ b/modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptArgumentParser.java
@@ -0,0 +1,95 @@
+package org.rhq.plugins.script;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * @author Lukas Krejci
+ * @since 4.10
+ */
+public final class ScriptArgumentParser {
+
+ private enum State {
+ SPACE, ESCAPE, ARG, QUOTE
+ }
+
+ private ScriptArgumentParser() {
+ }
+
+ public static String[] parse(String args, char escape) {
+ State state = State.SPACE;
+ char activeQuote = '\u0000';
+ List<String> parsedArgs = new ArrayList<String>();
+
+ int i = 0;
+ int len = args.length();
+ StringBuilder arg = new StringBuilder();
+ while (i < len) {
+ char c = args.charAt(i++);
+
+ switch (state) {
+ case SPACE:
+ boolean isNotWhitespace = false;
+ if (!Character.isWhitespace(c)) {
+ insertArg(arg, parsedArgs);
+ isNotWhitespace = true;
+ }
+
+ if (c == escape) {
+ state = State.ESCAPE;
+ } else if (isQuote(c)) {
+ activeQuote = c;
+ state = State.QUOTE;
+ } else if (isNotWhitespace) {
+ arg.append(c);
+ state = State.ARG;
+ }
+ break;
+ case ESCAPE:
+ arg.append(c);
+ state = State.ARG;
+ break;
+ case ARG:
+ if (c == escape) {
+ state = State.ESCAPE;
+ } else if (isQuote(c)) {
+ activeQuote = c;
+ state = State.QUOTE;
+ } else if (!Character.isWhitespace(c)) {
+ arg.append(c);
+ } else {
+ state = State.SPACE;
+ }
+ break;
+ case QUOTE:
+ if (c == activeQuote) {
+ state = State.ARG;
+ } else if (c == escape) {
+ state = State.ESCAPE;
+ } else {
+ arg.append(c);
+ }
+ break;
+ }
+ }
+
+ //if we errored out on something, let's just put the result in as an arg. It is the responsibility of the
+ //user to provide well-formed argument string.
+ if (arg.length() > 0) {
+ parsedArgs.add(arg.toString());
+ }
+
+ return parsedArgs.toArray(new String[parsedArgs.size()]);
+ }
+
+ private static void insertArg(StringBuilder bld, List<String> args) {
+ if (bld.length() > 0) {
+ args.add(bld.toString());
+ bld.delete(0, bld.length());
+ }
+ }
+
+ private static boolean isQuote(char c) {
+ return c == '\'' || c == '"';
+ }
+}
diff --git a/modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptDiscoveryComponent.java b/modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptDiscoveryComponent.java
index c685efe..4ee055a 100644
--- a/modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptDiscoveryComponent.java
+++ b/modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptDiscoveryComponent.java
@@ -30,12 +30,16 @@ import org.apache.commons.logging.LogFactory;
import org.rhq.core.domain.configuration.Configuration;
import org.rhq.core.domain.configuration.PropertySimple;
+import org.rhq.core.domain.resource.ResourceUpgradeReport;
import org.rhq.core.pluginapi.inventory.DiscoveredResourceDetails;
import org.rhq.core.pluginapi.inventory.InvalidPluginConfigurationException;
import org.rhq.core.pluginapi.inventory.ManualAddFacet;
import org.rhq.core.pluginapi.inventory.ProcessScanResult;
+import org.rhq.core.pluginapi.inventory.ResourceComponent;
import org.rhq.core.pluginapi.inventory.ResourceDiscoveryComponent;
import org.rhq.core.pluginapi.inventory.ResourceDiscoveryContext;
+import org.rhq.core.pluginapi.upgrade.ResourceUpgradeContext;
+import org.rhq.core.pluginapi.upgrade.ResourceUpgradeFacet;
import org.rhq.core.system.ProcessExecutionResults;
import org.rhq.core.util.exception.ThrowableUtil;
@@ -48,10 +52,16 @@ import org.rhq.core.util.exception.ThrowableUtil;
*
* @author John Mazzitelli
*/
-public class ScriptDiscoveryComponent implements ResourceDiscoveryComponent, ManualAddFacet {
+public class ScriptDiscoveryComponent implements ResourceDiscoveryComponent<ResourceComponent<?>>, ManualAddFacet<ResourceComponent<?>>,
+ ResourceUpgradeFacet<ResourceComponent<?>> {
+
+ public static final String ESCAPE_CHARACTER_PROP_NAME = "escapeCharacter";
+ private static final String ESCAPE_CHARACTER_DEFAULT = "__TO_BE_SET_TO_\\_OR_^__";
+
private final Log log = LogFactory.getLog(ScriptDiscoveryComponent.class);
- public Set<DiscoveredResourceDetails> discoverResources(ResourceDiscoveryContext context) {
+ @Override
+ public Set<DiscoveredResourceDetails> discoverResources(ResourceDiscoveryContext<ResourceComponent<?>> context) {
log.debug("Processing discovered management script resources...");
HashSet<DiscoveredResourceDetails> details = new HashSet<DiscoveredResourceDetails>();
@@ -72,8 +82,9 @@ public class ScriptDiscoveryComponent implements ResourceDiscoveryComponent, Man
return details;
}
+ @Override
public DiscoveredResourceDetails discoverResource(Configuration pluginConfig,
- ResourceDiscoveryContext discoveryContext)
+ ResourceDiscoveryContext<ResourceComponent<?>> discoveryContext)
throws InvalidPluginConfigurationException {
String executable = pluginConfig.getSimple(ScriptServerComponent.PLUGINCONFIG_EXECUTABLE).getStringValue();
String version = determineVersion(discoveryContext, pluginConfig);
@@ -94,7 +105,7 @@ public class ScriptDiscoveryComponent implements ResourceDiscoveryComponent, Man
*
* @return the details object that represents the discovered resource
*/
- protected DiscoveredResourceDetails processAutoDiscoveredResource(ResourceDiscoveryContext context,
+ protected DiscoveredResourceDetails processAutoDiscoveredResource(ResourceDiscoveryContext<ResourceComponent<?>> context,
ProcessScanResult autoDiscoveryResult) {
return null; // this implementation is a no-op - nothing will be discovered
@@ -108,7 +119,7 @@ public class ScriptDiscoveryComponent implements ResourceDiscoveryComponent, Man
*
* @return the description or <code>null</code> if it could not be determined
*/
- protected String determineDescription(ResourceDiscoveryContext context, Configuration pluginConfig) {
+ protected String determineDescription(ResourceDiscoveryContext<ResourceComponent<?>> context, Configuration pluginConfig) {
String description = null;
try {
PropertySimple descriptionProp = pluginConfig.getSimple(ScriptServerComponent.PLUGINCONFIG_FIXED_DESC);
@@ -153,6 +164,23 @@ public class ScriptDiscoveryComponent implements ResourceDiscoveryComponent, Man
return description;
}
+ @Override
+ public ResourceUpgradeReport upgrade(ResourceUpgradeContext<ResourceComponent<?>> inventoriedResource) {
+ PropertySimple escapeCharacter = inventoriedResource.getPluginConfiguration().getSimple(ESCAPE_CHARACTER_PROP_NAME);
+
+ if (escapeCharacter != null && !ESCAPE_CHARACTER_DEFAULT.equals(escapeCharacter.getStringValue())) {
+ return null;
+ }
+
+ char escapeChar = File.separatorChar == '/' ? '\\' : '^';
+
+ ResourceUpgradeReport report = new ResourceUpgradeReport();
+ report.setNewPluginConfiguration(inventoriedResource.getPluginConfiguration().clone());
+ report.getNewPluginConfiguration().put(new PropertySimple(ESCAPE_CHARACTER_PROP_NAME, Character.toString(escapeChar)));
+
+ return report;
+ }
+
/**
* Attempts to determine the version of the resource managed by the CLI.
*
@@ -161,7 +189,7 @@ public class ScriptDiscoveryComponent implements ResourceDiscoveryComponent, Man
*
* @return the version or <code>null</code> if it could not be determined
*/
- protected String determineVersion(ResourceDiscoveryContext context, Configuration pluginConfig) {
+ protected String determineVersion(ResourceDiscoveryContext<ResourceComponent<?>> context, Configuration pluginConfig) {
String version = null;
try {
PropertySimple versionProp = pluginConfig.getSimple(ScriptServerComponent.PLUGINCONFIG_FIXED_VERSION);
diff --git a/modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptServerComponent.java b/modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptServerComponent.java
index c964c69..7a81a6f 100644
--- a/modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptServerComponent.java
+++ b/modules/plugins/script/src/main/java/org/rhq/plugins/script/ScriptServerComponent.java
@@ -403,7 +403,9 @@ public class ScriptServerComponent implements ResourceComponent, MeasurementFace
ProcessExecution processExecution = getProcessExecutionInfo(pluginConfig);
if (args != null) {
- processExecution.setArguments(args.split(" "));
+ char escapeChar = pluginConfig.getSimpleValue(ScriptDiscoveryComponent.ESCAPE_CHARACTER_PROP_NAME, "\\").charAt(
+ 0);
+ processExecution.setArguments(ScriptArgumentParser.parse(args, escapeChar));
}
processExecution.setCaptureOutput(captureOutput);
processExecution.setWaitForCompletion(wait);
diff --git a/modules/plugins/script/src/main/resources/META-INF/rhq-plugin.xml b/modules/plugins/script/src/main/resources/META-INF/rhq-plugin.xml
index 4537bf9..3f63d36 100644
--- a/modules/plugins/script/src/main/resources/META-INF/rhq-plugin.xml
+++ b/modules/plugins/script/src/main/resources/META-INF/rhq-plugin.xml
@@ -42,6 +42,14 @@
<c:simple-property name="descriptionRegex" required="false" description="The regex that can pick out the description from the executable output. If the regex has a captured group, its matched content will be used as the description. If there is no captured group, the entire output will be used as the description."/>
<c:simple-property name="fixedDescription" required="false" description="If specified, this will be the description of the managed resource - the executable will not be invoked to determine it." />
</c:group>
+ <c:group name="advanced" displayName="Advanced">
+ <c:simple-property name="escapeCharacter" required="true" description="The escape character to be used when parsing arguments. By default this is (without quotes) '^' on Windows and '\' everywhere else."
+ default="__TO_BE_SET_TO_\_OR_^__">
+ <c:constraint>
+ <c:regex-constraint expression="." />
+ </c:constraint>
+ </c:simple-property>
+ </c:group>
</plugin-configuration>
<!--
diff --git a/modules/plugins/script/src/test/java/org/rhq/plugins/script/ScriptArgumentParserTest.java b/modules/plugins/script/src/test/java/org/rhq/plugins/script/ScriptArgumentParserTest.java
new file mode 100644
index 0000000..67a88c0
--- /dev/null
+++ b/modules/plugins/script/src/test/java/org/rhq/plugins/script/ScriptArgumentParserTest.java
@@ -0,0 +1,30 @@
+package org.rhq.plugins.script;
+
+import static org.testng.Assert.assertEquals;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import org.testng.annotations.Test;
+
+/**
+ * @author Lukas Krejci
+ * @since 4.10
+ */
+@Test
+public class ScriptArgumentParserTest {
+
+ public void test() {
+ HashMap<String, String[]> testCases = new HashMap<String, String[]>();
+
+ testCases.put("1 2\t3", new String[]{"1", "2", "3"});
+ testCases.put("1 '2 ' \"3'\" '4'abs '5\"'", new String[]{"1", "2 ", "3'", "4abs", "5\""});
+ testCases.put("\\ \\2 '3\\'a'", new String[]{" ", "2", "3'a"});
+
+ for(Map.Entry<String, String[]> testCase : testCases.entrySet()) {
+ String[] result = ScriptArgumentParser.parse(testCase.getKey(), '\\');
+
+ assertEquals(result, testCase.getValue(), "Failed to parse [" + testCase.getKey() + "]");
+ }
+ }
+}
10 years, 5 months
[rhq] Branch 'heiko/agentFootprint' - modules/core modules/enterprise
by Jay Shaughnessy
modules/core/domain/src/main/java/org/rhq/core/domain/configuration/Configuration.java | 9 +++
modules/core/plugin-container/src/main/java/org/rhq/core/pc/inventory/InventoryManager.java | 5 +
modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/server/gwt/SubjectGWTServiceImpl.java | 26 +++++-----
3 files changed, 26 insertions(+), 14 deletions(-)
New commits:
commit 52145f9ef78f4a56446b3e347e3c70b2a0ce0016
Author: Jay Shaughnessy <jshaughn(a)redhat.com>
Date: Tue Jan 7 17:01:29 2014 -0500
Solve some issues:
- remove Configuration.rawConfigurations of the delete_orphan
cascade option. It caused issues in the new scheme and is irrelevant
since rawConfig is not used. We should deprecate all things rawConfig
and probably remove the hibernate annotations from this field
completely.
- related: add some better proxy scrubbing in a gwt service touch-point
- fix a problem with runaway sync that resulted from an invalid container
lookup.
- related: defensively revert a separate container lookup to the way it
was (in getAvailabilityIfKnown). I don't see a reason for the change.
diff --git a/modules/core/domain/src/main/java/org/rhq/core/domain/configuration/Configuration.java b/modules/core/domain/src/main/java/org/rhq/core/domain/configuration/Configuration.java
index 5b4a50c..a7e9887 100644
--- a/modules/core/domain/src/main/java/org/rhq/core/domain/configuration/Configuration.java
+++ b/modules/core/domain/src/main/java/org/rhq/core/domain/configuration/Configuration.java
@@ -515,8 +515,12 @@ public class Configuration implements Serializable, Cloneable, AbstractPropertyM
private transient PropertiesProxy propertiesProxy;
+ // If we don't actually get rid of this soon (say, 4.10) then we may want to make this
+ // lazy, so we don't run around doing a fetch for every config we pull. But that means
+ // we have to protect against the unresolved proxy in various places (scrub the proxies)
+ // which has its own issues. Please let's kill this...
@OneToMany(mappedBy = "configuration", fetch = FetchType.EAGER)
- @Cascade({ CascadeType.PERSIST, CascadeType.MERGE, CascadeType.DELETE_ORPHAN })
+ @Cascade({ CascadeType.PERSIST, CascadeType.MERGE })
private Set<RawConfiguration> rawConfigurations;
@Column(name = "NOTES")
@@ -828,6 +832,9 @@ public class Configuration implements Serializable, Cloneable, AbstractPropertyM
}
public Set<RawConfiguration> getRawConfigurations() {
+ if (rawConfigurations == null) {
+ rawConfigurations = new HashSet<RawConfiguration>(1);
+ }
return rawConfigurations;
}
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 7f30260..f4a6ea4 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
@@ -1047,7 +1047,7 @@ public class InventoryManager extends AgentService implements ContainerService,
*/
@Nullable
public Availability getAvailabilityIfKnown(Resource resource) {
- ResourceContainer resourceContainer = getResourceContainer(resource.getId());
+ ResourceContainer resourceContainer = getResourceContainer(resource);
if (resourceContainer != null) {
if (ResourceComponentState.STARTED == resourceContainer.getResourceComponentState()) {
@@ -3289,7 +3289,8 @@ public class InventoryManager extends AgentService implements ContainerService,
if (parentResourceFromServer != null) {
ResourceContainer parentResourceContainer = getResourceContainer(parentResourceFromServer);
if (parentResourceContainer == null) {
- parentResourceContainer = getResourceContainer(parentResourceFromServer);
+ // must get the resContainer via Id here, the uuid is not necessarily set in the parent
+ parentResourceContainer = getResourceContainer(parentResourceFromServer.getId());
}
if (parentResourceContainer != null) {
parentResource = parentResourceContainer.getResource();
diff --git a/modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/server/gwt/SubjectGWTServiceImpl.java b/modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/server/gwt/SubjectGWTServiceImpl.java
index 9406e87..74ccdd0 100644
--- a/modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/server/gwt/SubjectGWTServiceImpl.java
+++ b/modules/enterprise/gui/coregui/src/main/java/org/rhq/coregui/server/gwt/SubjectGWTServiceImpl.java
@@ -121,7 +121,7 @@ public class SubjectGWTServiceImpl extends AbstractGWTServiceImpl implements Sub
public Subject updateSubjectAndPreferences(Subject subjectToModify, Set<String> changedPrefs) throws RuntimeException {
return updateSubjectAndPreferences(subjectToModify, changedPrefs, true, true);
}
-
+
public Subject processSubjectForLdap(Subject subjectToModify, String password) throws RuntimeException {
//no permissions check as embedded in the SLSB call.
try {
@@ -159,7 +159,7 @@ public class SubjectGWTServiceImpl extends AbstractGWTServiceImpl implements Sub
throw getExceptionToThrowToClient(t);
}
}
-
+
private Subject updateSubjectAndPreferences(Subject subjectToModify, Set<String> changedPrefs, boolean updateSubject, boolean updatePrefs) {
try {
Subject sessionSubject = getSessionSubject();
@@ -167,13 +167,16 @@ public class SubjectGWTServiceImpl extends AbstractGWTServiceImpl implements Sub
synchronized (subjectLock) {
if (!updateSubject) {
//make sure to use the prefs passed to us. getSubjectById() would overwrite them
- Configuration prefs = subjectToModify.getUserConfiguration();
+ Configuration prefs = subjectToModify.getUserConfiguration();
subjectToModify = subjectManager.getSubjectById(subjectToModify.getId());
+ subjectToModify = SerialUtility.prepare(subjectToModify,
+ "SubjectManager.updateSubjectAndPreferences(1)");
subjectToModify.setUserConfiguration(prefs);
}
Configuration persistedPrefs = prefsCache.getPreferences(subjectToModify.getId());
-
+ persistedPrefs = SerialUtility.prepare(persistedPrefs, "SubjectManager.updateSubjectAndPreferences(2)");
+
if (updatePrefs && changedPrefs != null) {
Configuration userPrefs = subjectToModify.getUserConfiguration();
for(String name : changedPrefs) {
@@ -185,20 +188,21 @@ public class SubjectGWTServiceImpl extends AbstractGWTServiceImpl implements Sub
}
}
}
-
+
subjectToModify.setUserConfiguration(persistedPrefs);
-
+
modifiedSubject = subjectManager.updateSubject(sessionSubject, subjectToModify);
-
+ modifiedSubject = SerialUtility.prepare(modifiedSubject,
+ "SubjectManager.updateSubjectAndPreferences(3)");
+
if (updatePrefs) {
//clear the prefs cache so that JSF UI refreshes it
prefsCache.clearConfiguration(subjectToModify.getId());
}
}
-
- Subject subject = SerialUtility.prepare(modifiedSubject, "SubjectManager.updateSubjectPW");
-
- return subject;
+
+ return modifiedSubject;
+
} catch (Throwable t) {
throw getExceptionToThrowToClient(t);
}
10 years, 5 months