[teiid-commits] teiid SVN: r3714 - in trunk: admin and 19 other directories.

teiid-commits at lists.jboss.org teiid-commits at lists.jboss.org
Thu Dec 1 13:19:12 EST 2011


Author: rareddy
Date: 2011-12-01 13:19:11 -0500 (Thu, 01 Dec 2011)
New Revision: 3714

Added:
   trunk/jboss-integration/src/main/java/org/teiid/jboss/CacheService.java
Modified:
   trunk/admin/pom.xml
   trunk/admin/src/main/java/org/teiid/adminapi/impl/VDBMetadataMapper.java
   trunk/admin/src/main/resources/org/teiid/adminapi/i18n.properties
   trunk/admin/src/test/java/org/teiid/adminapi/impl/TestRequestMetadata.java
   trunk/admin/src/test/java/org/teiid/adminapi/impl/TestSessionMetadata.java
   trunk/admin/src/test/java/org/teiid/adminapi/impl/TestTransactionMetadata.java
   trunk/admin/src/test/resources/vdb-describe.txt
   trunk/build/assembly/jboss-as7/dist.xml
   trunk/build/kits/jboss-as7/domain/configuration/domain-teiid.xml
   trunk/build/kits/jboss-as7/domain/configuration/host-teiid.xml
   trunk/build/kits/jboss-as7/modules/org/jboss/teiid/client/main/module.xml
   trunk/build/kits/jboss-as7/standalone/configuration/standalone-teiid.xml
   trunk/client/pom.xml
   trunk/client/src/main/java/org/teiid/jdbc/EmbeddedProfile.java
   trunk/connectors/translator-hive/pom.xml
   trunk/jboss-integration/pom.xml
   trunk/jboss-integration/src/main/java/org/teiid/jboss/BaseOperationHandler.java
   trunk/jboss-integration/src/main/java/org/teiid/jboss/BufferManagerService.java
   trunk/jboss-integration/src/main/java/org/teiid/jboss/Element.java
   trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidAdd.java
   trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidExtension.java
   trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidOperationHandler.java
   trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidSubsystemDescribe.java
   trunk/jboss-integration/src/main/java/org/teiid/jboss/TranslatorAdd.java
   trunk/jboss-integration/src/main/java/org/teiid/jboss/TransportAdd.java
   trunk/jboss-integration/src/main/java/org/teiid/jboss/deployers/RuntimeEngineDeployer.java
   trunk/jboss-integration/src/main/resources/org/teiid/jboss/i18n.properties
   trunk/jboss-integration/src/test/resources/teiid-model-config.txt
   trunk/jboss-integration/src/test/resources/teiid-transport-config.txt
   trunk/pom.xml
   trunk/runtime/src/main/java/org/teiid/services/SessionServiceImpl.java
   trunk/runtime/src/main/java/org/teiid/transport/ServerWorkItem.java
   trunk/runtime/src/main/resources/org/teiid/runtime/i18n.properties
Log:
TEIID-1720: Updating the code base to use Jboss-as-7.1.0.Beta1

Modified: trunk/admin/pom.xml
===================================================================
--- trunk/admin/pom.xml	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/admin/pom.xml	2011-12-01 18:19:11 UTC (rev 3714)
@@ -27,7 +27,7 @@
 		</dependency>
         <dependency>
             <groupId>org.jboss</groupId>
-            <artifactId>jboss-dmr</artifactId>                
+            <artifactId>jboss-dmr</artifactId>    
         </dependency>    
         <dependency>
             <groupId>org.jboss.as</groupId>

Modified: trunk/admin/src/main/java/org/teiid/adminapi/impl/VDBMetadataMapper.java
===================================================================
--- trunk/admin/src/main/java/org/teiid/adminapi/impl/VDBMetadataMapper.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/admin/src/main/java/org/teiid/adminapi/impl/VDBMetadataMapper.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -29,9 +29,9 @@
 import org.teiid.adminapi.AdminPlugin;
 import org.teiid.adminapi.DataPolicy;
 import org.teiid.adminapi.Model;
-import org.teiid.adminapi.Translator;
 import org.teiid.adminapi.Request.ProcessingState;
 import org.teiid.adminapi.Request.ThreadState;
+import org.teiid.adminapi.Translator;
 import org.teiid.adminapi.VDB.ConnectionType;
 import org.teiid.adminapi.VDB.Status;
 import org.teiid.adminapi.impl.DataPolicyMetadata.PermissionMetaData;
@@ -45,10 +45,11 @@
 	private static final String URL = "url"; //$NON-NLS-1$
 	private static final String MODELS = "models"; //$NON-NLS-1$
 	private static final String OVERRIDE_TRANSLATORS = "override-translators"; //$NON-NLS-1$
-	private static final String DESCRIPTION = "description"; //$NON-NLS-1$
+	private static final String VDB_DESCRIPTION = "vdb-description"; //$NON-NLS-1$
 	private static final String PROPERTIES = "properties"; //$NON-NLS-1$
 	private static final String DYNAMIC = "dynamic"; //$NON-NLS-1$
 	private static final String DATA_POLICIES = "data-policies"; //$NON-NLS-1$
+	private static final String DESCRIPTION = "description"; //$NON-NLS-1$
 	
 	public static VDBMetadataMapper INSTANCE = new VDBMetadataMapper();
 	
@@ -56,7 +57,7 @@
 		if (vdb == null) {
 			return null;
 		}
-			
+		node.get(TYPE).set(ModelType.OBJECT);
 		node.get(VDBNAME).set(vdb.getName());
 		node.get(CONNECTIONTYPE).set(vdb.getConnectionType().toString());
 		node.get(STATUS).set(vdb.getStatus().toString());
@@ -64,14 +65,14 @@
 		if (vdb.getUrl() != null) {
 		}
 		if (vdb.getDescription() != null) {
-			node.get(DESCRIPTION).set(vdb.getDescription());
+			node.get(VDB_DESCRIPTION).set(vdb.getDescription());
 		}
 		node.get(DYNAMIC).set(vdb.isDynamic());
 		
 		//PROPERTIES
 		List<PropertyMetadata> properties = vdb.getJAXBProperties();
 		if (properties!= null && !properties.isEmpty()) {
-			ModelNode propsNode = node.get(CHILDREN, PROPERTIES); 
+			ModelNode propsNode = node.get(PROPERTIES); 
 			for (PropertyMetadata prop:properties) {
 				propsNode.add(PropertyMetaDataMapper.INSTANCE.wrap(prop, new ModelNode()));
 			}
@@ -80,7 +81,7 @@
 		// MODELS
 		Map<String, ModelMetaData> models = vdb.getModelMetaDatas();
 		if (models != null && !models.isEmpty()) {
-			ModelNode modelNodes = node.get(CHILDREN, MODELS);		
+			ModelNode modelNodes = node.get(MODELS);		
 			for(ModelMetaData model:models.values()) {
 				modelNodes.add(ModelMetadataMapper.INSTANCE.wrap(model, new ModelNode()));
 			}
@@ -89,7 +90,7 @@
 		// OVERRIDE_TRANSLATORS
 		List<Translator> translators = vdb.getOverrideTranslators();
 		if (translators != null && !translators.isEmpty()) {
-			ModelNode translatorNodes = node.get(CHILDREN, OVERRIDE_TRANSLATORS);
+			ModelNode translatorNodes = node.get(OVERRIDE_TRANSLATORS);
 			for (Translator translator:translators) {
 				translatorNodes.add(VDBTranslatorMetaDataMapper.INSTANCE.wrap((VDBTranslatorMetaData)translator,  new ModelNode()));
 			}
@@ -98,7 +99,7 @@
 		// DATA_POLICIES
 		List<DataPolicy> policies = vdb.getDataPolicies();
 		if (policies != null && !policies.isEmpty()) {
-			ModelNode dataPoliciesNodes = node.get(CHILDREN, DATA_POLICIES);
+			ModelNode dataPoliciesNodes = node.get(DATA_POLICIES);
 			for (DataPolicy policy:policies) {
 				dataPoliciesNodes.add(DataPolicyMetadataMapper.INSTANCE.wrap((DataPolicyMetadata)policy,  new ModelNode()));
 			}
@@ -126,16 +127,16 @@
 		if (node.has(URL)) {
 			vdb.setUrl(node.get(URL).asString());
 		}
-		if(node.has(DESCRIPTION)) {
-			vdb.setDescription(node.get(DESCRIPTION).asString());
+		if(node.has(VDB_DESCRIPTION)) {
+			vdb.setDescription(node.get(VDB_DESCRIPTION).asString());
 		}
 		if (node.has(DYNAMIC)) {
 			vdb.setDynamic(node.get(DYNAMIC).asBoolean());
 		}
 
 		//PROPERTIES
-		if (node.get(CHILDREN, PROPERTIES).isDefined()) {
-			List<ModelNode> propNodes = node.get(CHILDREN, PROPERTIES).asList();
+		if (node.get(PROPERTIES).isDefined()) {
+			List<ModelNode> propNodes = node.get(PROPERTIES).asList();
 			for (ModelNode propNode:propNodes) {
 				PropertyMetadata prop = PropertyMetaDataMapper.INSTANCE.unwrap(propNode);
 				if (prop != null) {
@@ -145,8 +146,8 @@
 		}
 		
 		// MODELS
-		if (node.get(CHILDREN, MODELS).isDefined()) {
-			List<ModelNode> modelNodes = node.get(CHILDREN, MODELS).asList();
+		if (node.get(MODELS).isDefined()) {
+			List<ModelNode> modelNodes = node.get(MODELS).asList();
 			for(ModelNode modelNode:modelNodes) {
 				ModelMetaData model = ModelMetadataMapper.INSTANCE.unwrap(modelNode);
 				if (model != null) {
@@ -156,8 +157,8 @@
 		}
 		
 		// OVERRIDE_TRANSLATORS
-		if (node.get(CHILDREN, OVERRIDE_TRANSLATORS).isDefined()) {
-			List<ModelNode> translatorNodes = node.get(CHILDREN, OVERRIDE_TRANSLATORS).asList();
+		if (node.get(OVERRIDE_TRANSLATORS).isDefined()) {
+			List<ModelNode> translatorNodes = node.get(OVERRIDE_TRANSLATORS).asList();
 			for (ModelNode translatorNode:translatorNodes) {
 				VDBTranslatorMetaData translator = VDBTranslatorMetaDataMapper.INSTANCE.unwrap(translatorNode);
 				if (translator != null) {
@@ -167,8 +168,8 @@
 		}
 		
 		// DATA_POLICIES
-		if (node.get(CHILDREN, DATA_POLICIES).isDefined()) {
-			List<ModelNode> policiesNodes = node.get(CHILDREN, DATA_POLICIES).asList();
+		if (node.get(DATA_POLICIES).isDefined()) {
+			List<ModelNode> policiesNodes = node.get(DATA_POLICIES).asList();
 			for (ModelNode policyNode:policiesNodes) {
 				DataPolicyMetadata policy = DataPolicyMetadataMapper.INSTANCE.unwrap(policyNode);
 				if (policy != null) {
@@ -187,34 +188,39 @@
 		connectionsAllowed.add(ConnectionType.NONE.toString());
 		connectionsAllowed.add(ConnectionType.ANY.toString());
 		connectionsAllowed.add(ConnectionType.BY_VERSION.toString());
-		addAttribute(node, CONNECTIONTYPE, ModelType.STRING, false).get(ALLOWED).set(connectionsAllowed);
+		addAttribute(node, CONNECTIONTYPE, ModelType.STRING, false);
+		node.get(CONNECTIONTYPE).get(ALLOWED).set(connectionsAllowed);
 		
 		ModelNode statusAllowed = new ModelNode();
 		statusAllowed.add(Status.ACTIVE.toString());
 		statusAllowed.add(Status.INACTIVE.toString());
-		addAttribute(node, STATUS, ModelType.STRING, true).get(ALLOWED).set(statusAllowed);
+		addAttribute(node, STATUS, ModelType.STRING, true);
+		node.get(STATUS).get(ALLOWED).set(statusAllowed);
 		
 		addAttribute(node, VERSION, ModelType.INT, true);
 		addAttribute(node, URL, ModelType.STRING, false);
-		addAttribute(node, DESCRIPTION, ModelType.STRING, false);
+		addAttribute(node, VDB_DESCRIPTION, ModelType.STRING, false);
 		addAttribute(node, DYNAMIC, ModelType.BOOLEAN, false);
 		
-		ModelNode props = node.get(CHILDREN, PROPERTIES);
+		ModelNode props = node.get(PROPERTIES);
+		props.get(TYPE).set(ModelType.LIST);
 		props.get(DESCRIPTION).set(AdminPlugin.Util.getString(PROPERTIES+DOT_DESC));
-		PropertyMetaDataMapper.INSTANCE.describe(props);
+		PropertyMetaDataMapper.INSTANCE.describe(props.get(VALUE_TYPE));
 
-		ModelNode models = node.get(CHILDREN, MODELS);		
-		ModelMetadataMapper.INSTANCE.describe(models);
+		ModelNode models = node.get( MODELS);	
+		models.get(TYPE).set(ModelType.LIST);
+		ModelMetadataMapper.INSTANCE.describe(models.get(VALUE_TYPE));
 		models.get(DESCRIPTION).set(AdminPlugin.Util.getString(MODELS+DOT_DESC));
-		models.get(MIN_OCCURS).set(1);
 		
-		ModelNode translators = node.get(CHILDREN, OVERRIDE_TRANSLATORS);
+		ModelNode translators = node.get(OVERRIDE_TRANSLATORS);
+		translators.get(TYPE).set(ModelType.LIST);
 		translators.get(DESCRIPTION).set(AdminPlugin.Util.getString(OVERRIDE_TRANSLATORS+DOT_DESC));
-		VDBTranslatorMetaDataMapper.INSTANCE.describe(translators);
+		VDBTranslatorMetaDataMapper.INSTANCE.describe(translators.get(VALUE_TYPE));
 		
-		ModelNode dataPolicies = node.get(CHILDREN, DATA_POLICIES);
+		ModelNode dataPolicies = node.get(DATA_POLICIES);
+		dataPolicies.get(TYPE).set(ModelType.LIST);
 		dataPolicies.get(DESCRIPTION).set(AdminPlugin.Util.getString(DATA_POLICIES+DOT_DESC));
-		DataPolicyMetadataMapper.INSTANCE.describe(dataPolicies);
+		DataPolicyMetadataMapper.INSTANCE.describe(dataPolicies.get(VALUE_TYPE));
 		return node;
 	}
 	
@@ -250,7 +256,7 @@
 
 			List<PropertyMetadata> properties = model.getJAXBProperties();
 			if (properties!= null && !properties.isEmpty()) {
-				ModelNode propsNode = node.get(CHILDREN, PROPERTIES); 
+				ModelNode propsNode = node.get(PROPERTIES); 
 				for (PropertyMetadata prop:properties) {
 					propsNode.add(PropertyMetaDataMapper.INSTANCE.wrap(prop,  new ModelNode()));
 				}
@@ -258,7 +264,7 @@
 			
 			List<SourceMappingMetadata> sources = model.getSourceMappings();
 			if (sources != null && !sources.isEmpty()) {
-				ModelNode sourceMappingNode = node.get(CHILDREN, SOURCE_MAPPINGS);
+				ModelNode sourceMappingNode = node.get(SOURCE_MAPPINGS);
 				for(SourceMappingMetadata source:sources) {
 					sourceMappingNode.add(SourceMappingMetadataMapper.INSTANCE.wrap(source,  new ModelNode()));
 				}
@@ -266,7 +272,7 @@
 			
 			List<ValidationError> errors = model.getErrors();
 			if (errors != null && !errors.isEmpty()) {
-				ModelNode errorsNode = node.get(CHILDREN, VALIDITY_ERRORS);
+				ModelNode errorsNode = node.get(VALIDITY_ERRORS);
 				for (ValidationError error:errors) {
 					errorsNode.add(ValidationErrorMapper.INSTANCE.wrap(error, new ModelNode()));
 				}
@@ -296,8 +302,8 @@
 				model.setPath(node.get(MODELPATH).asString());
 			}
 
-			if (node.get(CHILDREN, PROPERTIES).isDefined()) {
-				List<ModelNode> propNodes = node.get(CHILDREN, PROPERTIES).asList();
+			if (node.get(PROPERTIES).isDefined()) {
+				List<ModelNode> propNodes = node.get(PROPERTIES).asList();
 				for (ModelNode propNode:propNodes) {
 					PropertyMetadata prop = PropertyMetaDataMapper.INSTANCE.unwrap(propNode);
 					if (prop != null) {
@@ -306,8 +312,8 @@
 				}
 			}
 		
-			if (node.get(CHILDREN, SOURCE_MAPPINGS).isDefined()) {
-				List<ModelNode> sourceMappingNodes = node.get(CHILDREN, SOURCE_MAPPINGS).asList();
+			if (node.get(SOURCE_MAPPINGS).isDefined()) {
+				List<ModelNode> sourceMappingNodes = node.get(SOURCE_MAPPINGS).asList();
 				for (ModelNode sourceMapping:sourceMappingNodes) {
 					SourceMappingMetadata source = SourceMappingMetadataMapper.INSTANCE.unwrap(sourceMapping);
 					if (source != null) {
@@ -316,8 +322,8 @@
 				}
 			}
 			
-			if (node.get(CHILDREN, VALIDITY_ERRORS).isDefined()) {
-				List<ModelNode> errorNodes = node.get(CHILDREN, VALIDITY_ERRORS).asList();
+			if (node.get(VALIDITY_ERRORS).isDefined()) {
+				List<ModelNode> errorNodes = node.get(VALIDITY_ERRORS).asList();
 				for(ModelNode errorNode:errorNodes) {
 					ValidationError error = ValidationErrorMapper.INSTANCE.unwrap(errorNode);
 					if (error != null) {
@@ -334,24 +340,28 @@
 			modelTypes.add(Model.Type.VIRTUAL.toString());
 			modelTypes.add(Model.Type.FUNCTION.toString());
 			modelTypes.add(Model.Type.OTHER.toString());
-			addAttribute(node, MODEL_NAME, ModelType.STRING, true).get(ALLOWED).set(modelTypes);
+			addAttribute(node, MODEL_NAME, ModelType.STRING, true);
+			node.get(MODEL_NAME).get(ALLOWED).set(modelTypes);
 			
 			addAttribute(node, DESCRIPTION, ModelType.STRING, false);
 			addAttribute(node, VISIBLE, ModelType.BOOLEAN, false);
 			addAttribute(node, MODEL_TYPE, ModelType.STRING, true);
 			addAttribute(node, MODELPATH, ModelType.STRING, false);
 			
-			ModelNode props = node.get(CHILDREN, PROPERTIES);
+			ModelNode props = node.get(PROPERTIES);
+			props.get(TYPE).set(ModelType.LIST);
 			props.get(DESCRIPTION).set(AdminPlugin.Util.getString(PROPERTIES+DOT_DESC));
-			PropertyMetaDataMapper.INSTANCE.describe(props);
+			PropertyMetaDataMapper.INSTANCE.describe(props.get(VALUE_TYPE));
 
-			ModelNode source = node.get(CHILDREN, SOURCE_MAPPINGS);
+			ModelNode source = node.get(SOURCE_MAPPINGS);
+			source.get(TYPE).set(ModelType.LIST);
 			source.get(DESCRIPTION).set(AdminPlugin.Util.getString(SOURCE_MAPPINGS+DOT_DESC));
-			SourceMappingMetadataMapper.INSTANCE.describe(source);
+			SourceMappingMetadataMapper.INSTANCE.describe(source.get(VALUE_TYPE));
 
-			ModelNode errors = node.get(CHILDREN, VALIDITY_ERRORS);
+			ModelNode errors = node.get(VALIDITY_ERRORS);
+			errors.get(TYPE).set(ModelType.LIST);
 			errors.get(DESCRIPTION).set(AdminPlugin.Util.getString(VALIDITY_ERRORS+DOT_DESC));
-			ValidationErrorMapper.INSTANCE.describe(errors);
+			ValidationErrorMapper.INSTANCE.describe(errors.get(VALUE_TYPE));
 			
 			return node; 
 		}
@@ -460,7 +470,7 @@
 	public static class VDBTranslatorMetaDataMapper implements MetadataMapper<VDBTranslatorMetaData>{
 		private static final String TRANSLATOR_NAME = "translator-name"; //$NON-NLS-1$
 		private static final String BASETYPE = "base-type"; //$NON-NLS-1$
-		private static final String DESCRIPTION = "description"; //$NON-NLS-1$
+		private static final String TRANSLATOR_DESCRIPTION = "translator-description"; //$NON-NLS-1$
 		private static final String PROPERTIES = "properties"; //$NON-NLS-1$
 		private static final String MODULE_NAME = "module-name"; //$NON-NLS-1$
 		
@@ -477,7 +487,7 @@
 				node.get(BASETYPE).set(translator.getType());
 			}
 			if (translator.getDescription() != null) {
-				node.get(DESCRIPTION).set(translator.getDescription());
+				node.get(TRANSLATOR_DESCRIPTION).set(translator.getDescription());
 			}
 			
 			if (translator.getModuleName() != null) {
@@ -486,7 +496,7 @@
 
 			List<PropertyMetadata> properties = translator.getJAXBProperties();
 			if (properties!= null && !properties.isEmpty()) {
-				ModelNode propsNode = node.get(CHILDREN, PROPERTIES); 
+				ModelNode propsNode = node.get(PROPERTIES); 
 				for (PropertyMetadata prop:properties) {
 					propsNode.add(PropertyMetaDataMapper.INSTANCE.wrap(prop, new ModelNode()));
 				}
@@ -505,15 +515,15 @@
 			if (node.has(BASETYPE)) {
 				translator.setType(node.get(BASETYPE).asString());
 			}
-			if (node.has(DESCRIPTION)) {
-				translator.setDescription(node.get(DESCRIPTION).asString());
+			if (node.has(TRANSLATOR_DESCRIPTION)) {
+				translator.setDescription(node.get(TRANSLATOR_DESCRIPTION).asString());
 			}
 			if (node.has(MODULE_NAME)) {
 				translator.setModuleName(node.get(MODULE_NAME).asString());
 			}
 			
-			if (node.get(CHILDREN,PROPERTIES).isDefined()) {
-				List<ModelNode> propNodes = node.get(CHILDREN, PROPERTIES).asList();
+			if (node.get(PROPERTIES).isDefined()) {
+				List<ModelNode> propNodes = node.get(PROPERTIES).asList();
 				for (ModelNode propNode:propNodes) {
 					PropertyMetadata prop = PropertyMetaDataMapper.INSTANCE.unwrap(propNode);
 					if (prop != null) {
@@ -527,12 +537,13 @@
 		public ModelNode describe(ModelNode node) {
 			addAttribute(node, TRANSLATOR_NAME, ModelType.STRING, true); 
 			addAttribute(node, BASETYPE, ModelType.STRING, true);
-			addAttribute(node, DESCRIPTION, ModelType.STRING, false);
+			addAttribute(node, TRANSLATOR_DESCRIPTION, ModelType.STRING, false);
 			addAttribute(node, MODULE_NAME, ModelType.STRING, false);
 			
-			ModelNode props = node.get(CHILDREN, PROPERTIES);
+			ModelNode props = node.get(PROPERTIES);
+			props.get(TYPE).set(ModelType.LIST);
 			props.get(DESCRIPTION).set(AdminPlugin.Util.getString(PROPERTIES+DOT_DESC));
-			PropertyMetaDataMapper.INSTANCE.describe(props);
+			PropertyMetaDataMapper.INSTANCE.describe(props.get(VALUE_TYPE));
 			return node; 
 		}		
 	}	
@@ -593,6 +604,7 @@
 		private static final String ALLOW_DELETE = "allow-delete"; //$NON-NLS-1$
 		private static final String ALLOW_EXECUTE = "allow-execute"; //$NON-NLS-1$
 		private static final String ALLOW_ALTER= "allow-alter"; //$NON-NLS-1$
+		private static final String POLICY_DESCRIPTION = "policy-description"; //$NON-NLS-1$
 		
 		public static DataPolicyMetadataMapper INSTANCE = new DataPolicyMetadataMapper();
 		
@@ -603,7 +615,7 @@
 
 			node.get(POLICY_NAME).set(policy.getName());
 			if (policy.getDescription() != null) {
-				node.get(DESCRIPTION).set(policy.getDescription());
+				node.get(POLICY_DESCRIPTION).set(policy.getDescription());
 			}
 			if (policy.isAllowCreateTemporaryTables() != null) {
 				node.get(ALLOW_CREATE_TEMP_TABLES).set(policy.isAllowCreateTemporaryTables());
@@ -613,7 +625,7 @@
 			//DATA_PERMISSIONS
 			List<DataPolicy.DataPermission> permissions = policy.getPermissions();
 			if (permissions != null && !permissions.isEmpty()) {
-				ModelNode permissionNodes = node.get(CHILDREN, DATA_PERMISSIONS); 
+				ModelNode permissionNodes = node.get(DATA_PERMISSIONS); 
 				for (DataPolicy.DataPermission dataPermission:permissions) {
 					permissionNodes.add(PermissionMetaDataMapper.INSTANCE.wrap((PermissionMetaData)dataPermission,  new ModelNode()));
 				}			
@@ -621,7 +633,7 @@
 			
 			//MAPPED_ROLE_NAMES
 			if (policy.getMappedRoleNames() != null && !policy.getMappedRoleNames().isEmpty()) {
-				ModelNode mappedRoleNodes = node.get(CHILDREN, MAPPED_ROLE_NAMES);
+				ModelNode mappedRoleNodes = node.get(MAPPED_ROLE_NAMES);
 				for (String role:policy.getMappedRoleNames()) {
 					mappedRoleNodes.add(role);
 				}
@@ -637,8 +649,8 @@
 			if (node.has(POLICY_NAME)) {
 				policy.setName(node.get(POLICY_NAME).asString());
 			}
-			if (node.has(DESCRIPTION)) {
-				policy.setDescription(node.get(DESCRIPTION).asString());
+			if (node.has(POLICY_DESCRIPTION)) {
+				policy.setDescription(node.get(POLICY_DESCRIPTION).asString());
 			}
 			if (node.has(ALLOW_CREATE_TEMP_TABLES)) {
 				policy.setAllowCreateTemporaryTables(node.get(ALLOW_CREATE_TEMP_TABLES).asBoolean());
@@ -648,8 +660,8 @@
 			}
 			
 			//DATA_PERMISSIONS
-			if (node.get(CHILDREN, DATA_PERMISSIONS).isDefined()) {
-				List<ModelNode> permissionNodes = node.get(CHILDREN, DATA_PERMISSIONS).asList();
+			if (node.get(DATA_PERMISSIONS).isDefined()) {
+				List<ModelNode> permissionNodes = node.get(DATA_PERMISSIONS).asList();
 				for (ModelNode permissionNode:permissionNodes) {
 					PermissionMetaData permission = PermissionMetaDataMapper.INSTANCE.unwrap(permissionNode);
 					if (permission != null) {
@@ -659,8 +671,8 @@
 			}
 
 			//MAPPED_ROLE_NAMES
-			if (node.get(CHILDREN, MAPPED_ROLE_NAMES).isDefined()) {
-				List<ModelNode> roleNameNodes = node.get(CHILDREN, MAPPED_ROLE_NAMES).asList();
+			if (node.get(MAPPED_ROLE_NAMES).isDefined()) {
+				List<ModelNode> roleNameNodes = node.get(MAPPED_ROLE_NAMES).asList();
 				for (ModelNode roleNameNode:roleNameNodes) {
 					policy.addMappedRoleName(roleNameNode.asString());
 				}			
@@ -670,36 +682,42 @@
 		
 		public ModelNode describe(ModelNode node) {
 			addAttribute(node, POLICY_NAME, ModelType.STRING, true);
-			addAttribute(node, DESCRIPTION, ModelType.STRING, false);
+			addAttribute(node, POLICY_DESCRIPTION, ModelType.STRING, false);
 			addAttribute(node, ALLOW_CREATE_TEMP_TABLES, ModelType.BOOLEAN, false);
 			addAttribute(node, ANY_AUTHENTICATED, ModelType.BOOLEAN, false);
 			
-			ModelNode permissions = node.get(CHILDREN, DATA_PERMISSIONS);
+			ModelNode permissions = node.get(DATA_PERMISSIONS);
+			permissions.get(TYPE).set(ModelType.LIST);
 			permissions.get(DESCRIPTION).set(AdminPlugin.Util.getString(DATA_PERMISSIONS+DOT_DESC));
-			permissions.get(MIN_OCCURS).set(1);
 			
-			ModelNode create = permissions.get(CHILDREN, ALLOW_CREATE);
+			ModelNode create = permissions.get(VALUE_TYPE, ALLOW_CREATE);
 			create.get(DESCRIPTION).set(AdminPlugin.Util.getString(ALLOW_CREATE+DOT_DESC));
+			create.get(TYPE).set(ModelType.STRING);
 			
-			ModelNode read = permissions.get(CHILDREN, ALLOW_READ);
+			ModelNode read = permissions.get(VALUE_TYPE, ALLOW_READ);
 			read.get(DESCRIPTION).set(AdminPlugin.Util.getString(ALLOW_READ+DOT_DESC));
+			read.get(TYPE).set(ModelType.STRING);
 
-			ModelNode update = permissions.get(CHILDREN, ALLOW_UPDATE);
+			ModelNode update = permissions.get(VALUE_TYPE, ALLOW_UPDATE);
 			update.get(DESCRIPTION).set(AdminPlugin.Util.getString(ALLOW_UPDATE+DOT_DESC));
+			update.get(TYPE).set(ModelType.STRING);
 
-			ModelNode delete = permissions.get(CHILDREN, ALLOW_DELETE);
+			ModelNode delete = permissions.get(VALUE_TYPE, ALLOW_DELETE);
 			delete.get(DESCRIPTION).set(AdminPlugin.Util.getString(ALLOW_DELETE+DOT_DESC));
+			delete.get(TYPE).set(ModelType.STRING);
 
-			ModelNode execute = permissions.get(CHILDREN, ALLOW_EXECUTE);
+			ModelNode execute = permissions.get(VALUE_TYPE, ALLOW_EXECUTE);
 			execute.get(DESCRIPTION).set(AdminPlugin.Util.getString(ALLOW_EXECUTE+DOT_DESC));
+			execute.get(TYPE).set(ModelType.STRING);
 
-			ModelNode alter = permissions.get(CHILDREN, ALLOW_ALTER);
+			ModelNode alter = permissions.get(VALUE_TYPE, ALLOW_ALTER);
 			alter.get(DESCRIPTION).set(AdminPlugin.Util.getString(ALLOW_ALTER+DOT_DESC));
+			alter.get(TYPE).set(ModelType.STRING);
 			
-			ModelNode roleNames = node.get(CHILDREN, MAPPED_ROLE_NAMES);
+			ModelNode roleNames = node.get(MAPPED_ROLE_NAMES);
 			roleNames.get(TYPE).set(ModelType.LIST);
 			roleNames.get(DESCRIPTION).set(AdminPlugin.Util.getString(MAPPED_ROLE_NAMES+DOT_DESC));
-			roleNames.get("value-type").set(ModelType.STRING); //$NON-NLS-1$
+			roleNames.get(VALUE_TYPE).set(ModelType.STRING);
 			return node; 
 		}
 	}	
@@ -1025,7 +1043,7 @@
 		public ModelNode wrap(WorkerPoolStatisticsMetadata stats, ModelNode node) {
 			if (stats == null)
 				return null;
-			
+			node.get(TYPE).set(ModelType.OBJECT);
 			node.get(ACTIVE_THREADS).set(stats.getActiveThreads());
 			node.get(HIGHEST_ACTIVE_THREADS).set(stats.getHighestActiveThreads());
 			node.get(TOTAL_COMPLETED).set(stats.getTotalCompleted());
@@ -1067,17 +1085,15 @@
 		}
 	}	
 	
-	private static final String CHILDREN = "children"; //$NON-NLS-1$
-	private static final String ATTRIBUTES = "attributes"; //$NON-NLS-1$
 	private static final String DOT_DESC = ".describe"; //$NON-NLS-1$
 	private static final String TYPE = "type"; //$NON-NLS-1$
-	private static final String MIN_OCCURS = "min-occurs"; //$NON-NLS-1$
 	private static final String REQUIRED = "required"; //$NON-NLS-1$
 	private static final String ALLOWED = "allowed"; //$NON-NLS-1$
+	private static final String VALUE_TYPE = "value-type"; //$NON-NLS-1$
 	static ModelNode addAttribute(ModelNode node, String name, ModelType dataType, boolean required) {
-		node.get(ATTRIBUTES, name, TYPE).set(dataType);
-        node.get(ATTRIBUTES, name, DESCRIPTION).set(AdminPlugin.Util.getString(name+DOT_DESC));
-        node.get(ATTRIBUTES, name, REQUIRED).set(required);
+		node.get(name, TYPE).set(dataType);
+        node.get(name, DESCRIPTION).set(AdminPlugin.Util.getString(name+DOT_DESC));
+        node.get(name, REQUIRED).set(required);
         return node;
     }
 }

Modified: trunk/admin/src/main/resources/org/teiid/adminapi/i18n.properties
===================================================================
--- trunk/admin/src/main/resources/org/teiid/adminapi/i18n.properties	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/admin/src/main/resources/org/teiid/adminapi/i18n.properties	2011-12-01 18:19:11 UTC (rev 3714)
@@ -15,6 +15,7 @@
 source-name.describe=Source name for this model
 jndi-name.describe=Connection JNDI Name
 translator-name.describe=Name of the translator
+translator-description.describe=Translator description
 error-path.describe=Path to the error in the Virtual Database
 severity.describe=Severity
 message.describe=Error message

Modified: trunk/admin/src/test/java/org/teiid/adminapi/impl/TestRequestMetadata.java
===================================================================
--- trunk/admin/src/test/java/org/teiid/adminapi/impl/TestRequestMetadata.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/admin/src/test/java/org/teiid/adminapi/impl/TestRequestMetadata.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -57,7 +57,7 @@
 		return request;
 	}
 	
-	public static final String desc = "{\"attributes\" : {\n" + 
+	public static final String desc = "{\n" + 
 			"    \"execution-id\" : {\n" + 
 			"        \"type\" : {\n" + 
 			"            \"TYPE_MODEL_VALUE\" : \"LONG\"\n" + 
@@ -121,7 +121,7 @@
 			"        \"description\" : \"Thread state\",\n" + 
 			"        \"required\" : true\n" + 
 			"    }\n" + 
-			"}}";
+			"}";
 	@Test public void testDescribe() {
 		assertEquals(desc, VDBMetadataMapper.RequestMetadataMapper.INSTANCE.describe(new ModelNode()).toJSONString(false));
 	}

Modified: trunk/admin/src/test/java/org/teiid/adminapi/impl/TestSessionMetadata.java
===================================================================
--- trunk/admin/src/test/java/org/teiid/adminapi/impl/TestSessionMetadata.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/admin/src/test/java/org/teiid/adminapi/impl/TestSessionMetadata.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -51,7 +51,7 @@
 		
 	}
 	
-	private static final String describe = "{\"attributes\" : {\n" + 
+	private static final String describe = "{\n" + 
 			"    \"application-name\" : {\n" + 
 			"        \"type\" : {\n" + 
 			"            \"TYPE_MODEL_VALUE\" : \"STRING\"\n" + 
@@ -122,7 +122,7 @@
 			"        \"description\" : \"Security domain that session used for login\",\n" + 
 			"        \"required\" : false\n" + 
 			"    }\n" + 
-			"}}"; 
+			"}"; 
 	
 	@Test public void testDescribe() {
 		ModelNode n = VDBMetadataMapper.SessionMetadataMapper.INSTANCE.describe(new ModelNode());

Modified: trunk/admin/src/test/java/org/teiid/adminapi/impl/TestTransactionMetadata.java
===================================================================
--- trunk/admin/src/test/java/org/teiid/adminapi/impl/TestTransactionMetadata.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/admin/src/test/java/org/teiid/adminapi/impl/TestTransactionMetadata.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -48,7 +48,7 @@
 		assertEquals(tm.getScope(), tm1.getScope());
 	}
 
-	private static final String describe = "{\"attributes\" : {\n" + 
+	private static final String describe = "{\n" + 
 			"    \"session-id\" : {\n" + 
 			"        \"type\" : {\n" + 
 			"            \"TYPE_MODEL_VALUE\" : \"STRING\"\n" + 
@@ -77,7 +77,7 @@
 			"        \"description\" : \"Transaction Identifier (XID)\",\n" + 
 			"        \"required\" : true\n" + 
 			"    }\n" + 
-			"}}";
+			"}";
 	@Test
 	public void testDescribe() {
 		ModelNode n = VDBMetadataMapper.TransactionMetadataMapper.INSTANCE.describe(new ModelNode());

Modified: trunk/admin/src/test/resources/vdb-describe.txt
===================================================================
--- trunk/admin/src/test/resources/vdb-describe.txt	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/admin/src/test/resources/vdb-describe.txt	2011-12-01 18:19:11 UTC (rev 3714)
@@ -1,234 +1,253 @@
 {
-    "attributes" : {
-        "vdb-name" : {
-            "type" : {
-                "TYPE_MODEL_VALUE" : "STRING"
-            },
-            "description" : "The Virtual Database Name",
-            "required" : true
+    "vdb-name" : {
+        "type" : {
+            "TYPE_MODEL_VALUE" : "STRING"
         },
-        "connection-type" : {
-            "type" : {
-                "TYPE_MODEL_VALUE" : "STRING"
-            },
-            "description" : "Allowable Connections: 1) NONE - disallow new connections 2) BY VERSION - allow connections only if the version is specified or if this is the earliest 'BY VERSION' vdb and there are no vdbs marked as 'ANY' 3) ANY - allow connections with or without a version specified. If multiple versions of same VDB are deployed, connect to one specified with ANY, or if there are multiple VDBs with ANY then connect to the latest version with ANY ",
-            "required" : false
+        "description" : "The Virtual Database Name",
+        "required" : true
+    },
+    "connection-type" : {
+        "type" : {
+            "TYPE_MODEL_VALUE" : "STRING"
         },
-        "status" : {
-            "type" : {
-                "TYPE_MODEL_VALUE" : "STRING"
-            },
-            "description" : "The Virtual Database Status",
-            "required" : true
+        "description" : "Allowable Connections: 1) NONE - disallow new connections 2) BY VERSION - allow connections only if the version is specified or if this is the earliest 'BY VERSION' vdb and there are no vdbs marked as 'ANY' 3) ANY - allow connections with or without a version specified. If multiple versions of same VDB are deployed, connect to one specified with ANY, or if there are multiple VDBs with ANY then connect to the latest version with ANY ",
+        "required" : false,
+        "allowed" : [
+            "NONE",
+            "ANY",
+            "BY_VERSION"
+        ]
+    },
+    "status" : {
+        "type" : {
+            "TYPE_MODEL_VALUE" : "STRING"
         },
-        "vdb-version" : {
-            "type" : {
-                "TYPE_MODEL_VALUE" : "INT"
-            },
-            "description" : "The Virtual Database Version",
-            "required" : true
+        "description" : "The Virtual Database Status",
+        "required" : true,
+        "allowed" : [
+            "ACTIVE",
+            "INACTIVE"
+        ]
+    },
+    "vdb-version" : {
+        "type" : {
+            "TYPE_MODEL_VALUE" : "INT"
         },
-        "url" : {
-            "type" : {
-                "TYPE_MODEL_VALUE" : "STRING"
-            },
-            "description" : "The Virtual Database URL",
-            "required" : false
+        "description" : "The Virtual Database Version",
+        "required" : true
+    },
+    "url" : {
+        "type" : {
+            "TYPE_MODEL_VALUE" : "STRING"
         },
-        "description" : {
-            "type" : {
-                "TYPE_MODEL_VALUE" : "STRING"
-            },
-            "description" : "Description",
-            "required" : false
+        "description" : "The Virtual Database URL",
+        "required" : false
+    },
+    "vdb-description" : {
+        "type" : {
+            "TYPE_MODEL_VALUE" : "STRING"
         },
-        "dynamic" : {
-            "type" : {
-                "TYPE_MODEL_VALUE" : "BOOLEAN"
+        "description" : "<Missing message for key \"vdb-description.describe\" in: org.teiid.adminapi.i18n>",
+        "required" : false
+    },
+    "dynamic" : {
+        "type" : {
+            "TYPE_MODEL_VALUE" : "BOOLEAN"
+        },
+        "description" : "Dynamic Virtual Database",
+        "required" : false
+    },
+    "properties" : {
+        "type" : {
+            "TYPE_MODEL_VALUE" : "LIST"
+        },
+        "description" : "properties",
+        "value-type" : {
+            "property-name" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "STRING"
+                },
+                "description" : "Name",
+                "required" : true
             },
-            "description" : "Dynamic Virtual Database",
-            "required" : false
+            "property-value" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "STRING"
+                },
+                "description" : "Property value",
+                "required" : true
+            }
         }
     },
-    "allowed" : [
-        "ACTIVE",
-        "INACTIVE"
-    ],
-    "children" : {
-        "properties" : {
-            "description" : "properties",
-            "attributes" : {
-                "property-name" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "STRING"
-                    },
-                    "description" : "Name",
-                    "required" : true
-                },
-                "property-value" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "STRING"
-                    },
-                    "description" : "Property value",
-                    "required" : true
-                }
-            }
+    "models" : {
+        "type" : {
+            "TYPE_MODEL_VALUE" : "LIST"
         },
-        "models" : {
-            "attributes" : {
-                "model-name" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "STRING"
-                    },
-                    "description" : "Name of the model",
-                    "required" : true
+        "value-type" : {
+            "model-name" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "STRING"
                 },
-                "description" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "STRING"
-                    },
-                    "description" : "Description",
-                    "required" : false
+                "description" : "Name of the model",
+                "required" : true,
+                "allowed" : [
+                    "PHYSICAL",
+                    "VIRTUAL",
+                    "FUNCTION",
+                    "OTHER"
+                ]
+            },
+            "description" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "STRING"
                 },
-                "visible" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "BOOLEAN"
-                    },
-                    "description" : "Visibility of the model",
-                    "required" : false
+                "description" : "Description",
+                "required" : false
+            },
+            "visible" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "BOOLEAN"
                 },
-                "model-type" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "STRING"
-                    },
-                    "description" : "Type of the Model(PHYSICAL, VIRTUAL, FUNCTION, OTHER)",
-                    "required" : true
+                "description" : "Visibility of the model",
+                "required" : false
+            },
+            "model-type" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "STRING"
                 },
-                "model-path" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "STRING"
+                "description" : "Type of the Model(PHYSICAL, VIRTUAL, FUNCTION, OTHER)",
+                "required" : true
+            },
+            "model-path" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "STRING"
+                },
+                "description" : "Path to model file inside the archive",
+                "required" : false
+            },
+            "properties" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "LIST"
+                },
+                "description" : "properties",
+                "value-type" : {
+                    "property-name" : {
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
+                        },
+                        "description" : "Name",
+                        "required" : true
                     },
-                    "description" : "Path to model file inside the archive",
-                    "required" : false
+                    "property-value" : {
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
+                        },
+                        "description" : "Property value",
+                        "required" : true
+                    }
                 }
             },
-            "allowed" : [
-                "PHYSICAL",
-                "VIRTUAL",
-                "FUNCTION",
-                "OTHER"
-            ],
-            "children" : {
-                "properties" : {
-                    "description" : "properties",
-                    "attributes" : {
-                        "property-name" : {
-                            "type" : {
-                                "TYPE_MODEL_VALUE" : "STRING"
-                            },
-                            "description" : "Name",
-                            "required" : true
-                        },
-                        "property-value" : {
-                            "type" : {
-                                "TYPE_MODEL_VALUE" : "STRING"
-                            },
-                            "description" : "Property value",
-                            "required" : true
-                        }
-                    }
+            "source-mappings" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "LIST"
                 },
-                "source-mappings" : {
-                    "description" : "Model to source mapping",
-                    "attributes" : {
-                        "source-name" : {
-                            "type" : {
-                                "TYPE_MODEL_VALUE" : "STRING"
-                            },
-                            "description" : "Source name for this model",
-                            "required" : true
+                "description" : "Model to source mapping",
+                "value-type" : {
+                    "source-name" : {
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
                         },
-                        "jndi-name" : {
-                            "type" : {
-                                "TYPE_MODEL_VALUE" : "STRING"
-                            },
-                            "description" : "Connection JNDI Name",
-                            "required" : true
+                        "description" : "Source name for this model",
+                        "required" : true
+                    },
+                    "jndi-name" : {
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
                         },
-                        "translator-name" : {
-                            "type" : {
-                                "TYPE_MODEL_VALUE" : "STRING"
-                            },
-                            "description" : "Name of the translator",
-                            "required" : true
-                        }
+                        "description" : "Connection JNDI Name",
+                        "required" : true
+                    },
+                    "translator-name" : {
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
+                        },
+                        "description" : "Name of the translator",
+                        "required" : true
                     }
+                }
+            },
+            "validity-errors" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "LIST"
                 },
-                "validity-errors" : {
-                    "description" : "Model validation errors",
-                    "attributes" : {
-                        "error-path" : {
-                            "type" : {
-                                "TYPE_MODEL_VALUE" : "STRING"
-                            },
-                            "description" : "Path to the error in the Virtual Database",
-                            "required" : false
+                "description" : "Model validation errors",
+                "value-type" : {
+                    "error-path" : {
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
                         },
-                        "severity" : {
-                            "type" : {
-                                "TYPE_MODEL_VALUE" : "STRING"
-                            },
-                            "description" : "Severity",
-                            "required" : true
+                        "description" : "Path to the error in the Virtual Database",
+                        "required" : false
+                    },
+                    "severity" : {
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
                         },
-                        "message" : {
-                            "type" : {
-                                "TYPE_MODEL_VALUE" : "STRING"
-                            },
-                            "description" : "Error message",
-                            "required" : true
-                        }
+                        "description" : "Severity",
+                        "required" : true
+                    },
+                    "message" : {
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
+                        },
+                        "description" : "Error message",
+                        "required" : true
                     }
                 }
-            },
-            "description" : "Models inside a virtual database",
-            "min-occurs" : 1
+            }
         },
-        "override-translators" : {
-            "description" : "Overridden translators for the Virtual Database",
-            "attributes" : {
-                "translator-name" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "STRING"
-                    },
-                    "description" : "Name of the translator",
-                    "required" : true
+        "description" : "Models inside a virtual database"
+    },
+    "override-translators" : {
+        "type" : {
+            "TYPE_MODEL_VALUE" : "LIST"
+        },
+        "description" : "Overridden translators for the Virtual Database",
+        "value-type" : {
+            "translator-name" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "STRING"
                 },
-                "base-type" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "STRING"
-                    },
-                    "description" : "Translator Base Type",
-                    "required" : true
+                "description" : "Name of the translator",
+                "required" : true
+            },
+            "base-type" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "STRING"
                 },
-                "description" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "STRING"
-                    },
-                    "description" : "Description",
-                    "required" : false
+                "description" : "Translator Base Type",
+                "required" : true
+            },
+            "translator-description" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "STRING"
                 },
-                "module-name" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "STRING"
-                    },
-                    "description" : "Translator's Module name",
-                    "required" : false
-                }
+                "description" : "Translator description",
+                "required" : false
             },
-            "children" : {"properties" : {
+            "module-name" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "STRING"
+                },
+                "description" : "Translator's Module name",
+                "required" : false
+            },
+            "properties" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "LIST"
+                },
                 "description" : "properties",
-                "attributes" : {
+                "value-type" : {
                     "property-name" : {
                         "type" : {
                             "TYPE_MODEL_VALUE" : "STRING"
@@ -244,62 +263,95 @@
                         "required" : true
                     }
                 }
-            }}
+            }
+        }
+    },
+    "data-policies" : {
+        "type" : {
+            "TYPE_MODEL_VALUE" : "LIST"
         },
-        "data-policies" : {
-            "description" : "Data access policies defined for the Virtual Database",
-            "attributes" : {
-                "policy-name" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "STRING"
-                    },
-                    "description" : "Resource Name, for which permission defined",
-                    "required" : true
+        "description" : "Data access policies defined for the Virtual Database",
+        "value-type" : {
+            "policy-name" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "STRING"
                 },
-                "description" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "STRING"
-                    },
-                    "description" : "Description",
-                    "required" : false
+                "description" : "Resource Name, for which permission defined",
+                "required" : true
+            },
+            "policy-description" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "STRING"
                 },
-                "allow-create-temp-tables" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "BOOLEAN"
-                    },
-                    "description" : "Allows create of temporary table",
-                    "required" : false
+                "description" : "<Missing message for key \"policy-description.describe\" in: org.teiid.adminapi.i18n>",
+                "required" : false
+            },
+            "allow-create-temp-tables" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "BOOLEAN"
                 },
-                "any-authenticated" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "BOOLEAN"
-                    },
-                    "description" : "Indicates if the role is mapped to any authenticated user",
-                    "required" : false
-                }
+                "description" : "Allows create of temporary table",
+                "required" : false
             },
-            "children" : {
-                "data-permissions" : {
-                    "description" : "Permissions defined for data access",
-                    "min-occurs" : 1,
-                    "children" : {
-                        "allow-create" : {"description" : "create allowed"},
-                        "allow-read" : {"description" : "read allowed"},
-                        "allow-update" : {"description" : "update allowed"},
-                        "allow-delete" : {"description" : "delete allowed"},
-                        "allow-execute" : {"description" : "execute allowed"},
-                        "allow-alter" : {"description" : "alter allowed"}
-                    }
+            "any-authenticated" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "BOOLEAN"
                 },
-                "mapped-role-names" : {
-                    "type" : {
-                        "TYPE_MODEL_VALUE" : "LIST"
+                "description" : "Indicates if the role is mapped to any authenticated user",
+                "required" : false
+            },
+            "data-permissions" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "LIST"
+                },
+                "description" : "Permissions defined for data access",
+                "value-type" : {
+                    "allow-create" : {
+                        "description" : "create allowed",
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
+                        }
                     },
-                    "description" : "Policy name to role name mapping",
-                    "value-type" : {
-                        "TYPE_MODEL_VALUE" : "STRING"
+                    "allow-read" : {
+                        "description" : "read allowed",
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
+                        }
+                    },
+                    "allow-update" : {
+                        "description" : "update allowed",
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
+                        }
+                    },
+                    "allow-delete" : {
+                        "description" : "delete allowed",
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
+                        }
+                    },
+                    "allow-execute" : {
+                        "description" : "execute allowed",
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
+                        }
+                    },
+                    "allow-alter" : {
+                        "description" : "alter allowed",
+                        "type" : {
+                            "TYPE_MODEL_VALUE" : "STRING"
+                        }
                     }
                 }
+            },
+            "mapped-role-names" : {
+                "type" : {
+                    "TYPE_MODEL_VALUE" : "LIST"
+                },
+                "description" : "Policy name to role name mapping",
+                "value-type" : {
+                    "TYPE_MODEL_VALUE" : "STRING"
+                }
             }
         }
     }

Modified: trunk/build/assembly/jboss-as7/dist.xml
===================================================================
--- trunk/build/assembly/jboss-as7/dist.xml	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/build/assembly/jboss-as7/dist.xml	2011-12-01 18:19:11 UTC (rev 3714)
@@ -41,20 +41,7 @@
         <fileMode>0644</fileMode>
         <directoryMode>0755</directoryMode>        
     </fileSet>
-    
-	<!-- We may want to do this if including multiple doc types or languages
-	     as the parent directory structure will be copied.  However the parent
-	     directory permissions still seem wrong.
-	<fileSet>
-	  	<directory>target/distribution/teiid-${version}-docs</directory>
-	  	<includes>
-	  		<include>**/*.pdf</include>
-	  	</includes>
-	    <outputDirectory>teiid-docs</outputDirectory>
-	    <fileMode>0644</fileMode>
-	    <directoryMode>0755</directoryMode>
-	</fileSet> -->
-	
+    	
   </fileSets>
   
     <files>
@@ -167,6 +154,19 @@
         </binaries>
     </moduleSet>
     
+    <!-- This is separated out so that we can avoid dragging in transitive dependencies, using pom build the adminshell correctly -->
+    <moduleSet>
+      <useAllReactorProjects>true</useAllReactorProjects>
+      <includes>
+        <include>org.jboss.teiid:teiid-admin</include>   
+      </includes>
+      <binaries>
+        <includeDependencies>false</includeDependencies>
+        <unpack>false</unpack>
+        <outputDirectory>modules/org/jboss/teiid/main</outputDirectory>
+      </binaries>
+    </moduleSet>    
+    
     <!-- These are built in connectors  -->
     <moduleSet>
         <includeSubModules>true</includeSubModules>

Modified: trunk/build/kits/jboss-as7/domain/configuration/domain-teiid.xml
===================================================================
--- trunk/build/kits/jboss-as7/domain/configuration/domain-teiid.xml	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/build/kits/jboss-as7/domain/configuration/domain-teiid.xml	2011-12-01 18:19:11 UTC (rev 3714)
@@ -1,30 +1,11 @@
-<!--
-  ~ JBoss, Home of Professional Open Source.
-  ~ Copyright 2010, Red Hat, Inc., and individual contributors
-  ~ as indicated by the @author tags. See the copyright.txt file in the
-  ~ distribution for a full listing of individual contributors.
-  ~
-  ~ This is free software; you can redistribute it and/or modify it
-  ~ under the terms of the GNU Lesser General Public License as
-  ~ published by the Free Software Foundation; either version 2.1 of
-  ~ the License, or (at your option) any later version.
-  ~
-  ~ This software 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
-  ~ Lesser General Public License for more details.
-  ~
-  ~ You should have received a copy of the GNU Lesser General Public
-  ~ License along with this software; if not, write to the Free
-  ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  -->
+<?xml version='1.0' encoding='UTF-8'?>
 
 <domain xmlns="urn:jboss:domain:1.1">
 
     <extensions>
         <extension module="org.jboss.as.clustering.infinispan"/>
         <extension module="org.jboss.as.clustering.jgroups"/>
+        <extension module="org.jboss.as.cmp"/>
         <extension module="org.jboss.as.connector"/>
         <extension module="org.jboss.as.ee"/>
         <extension module="org.jboss.as.ejb3"/>
@@ -34,6 +15,7 @@
         <extension module="org.jboss.as.jmx"/>
         <extension module="org.jboss.as.jpa"/>
         <extension module="org.jboss.as.logging"/>
+        <extension module="org.jboss.as.mail"/>
         <extension module="org.jboss.as.messaging"/>
         <extension module="org.jboss.as.modcluster"/>
         <extension module="org.jboss.as.naming"/>
@@ -45,7 +27,7 @@
         <extension module="org.jboss.as.threads"/>
         <extension module="org.jboss.as.transactions"/>
         <extension module="org.jboss.as.web"/>
-        <extension module="org.jboss.as.webservices" />
+        <extension module="org.jboss.as.webservices"/>
         <extension module="org.jboss.as.weld"/>
     </extensions>
 
@@ -63,7 +45,6 @@
                         <pattern-formatter pattern="%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%n"/>
                     </formatter>
                 </console-handler>
-
                 <periodic-rotating-file-handler name="FILE">
                     <formatter>
                         <pattern-formatter pattern="%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%n"/>
@@ -71,7 +52,6 @@
                     <file relative-to="jboss.server.log.dir" path="server.log"/>
                     <suffix value=".yyyy-MM-dd"/>
                 </periodic-rotating-file-handler>
-
                 <logger category="com.arjuna">
                     <level name="WARN"/>
                 </logger>
@@ -84,11 +64,9 @@
                 <logger category="jacorb">
                     <level name="WARN"/>
                 </logger>
-                <!-- set jacorb.config to ERROR to avoid the "jacorb.properties not found" messages during startup -->
                 <logger category="jacorb.config">
                     <level name="ERROR"/>
                 </logger>
-
                 <root-logger>
                     <level name="INFO"/>
                     <handlers>
@@ -116,33 +94,7 @@
                 </datasources>
             </subsystem>
             <subsystem xmlns="urn:jboss:domain:ee:1.0"/>
-            <subsystem xmlns="urn:jboss:domain:ejb3:1.2" >
-
-                <remote connector-ref="remoting-connector" thread-pool-name="default" />
-                <async thread-pool-name="default" />
-
-                <timer-service thread-pool-name="default" >
-                    <data-store path="timer-service-data" relative-to="jboss.server.data.dir"/>
-                </timer-service>
-
-                <!-- EJB3 pools -->
-                <pools>
-                    <bean-instance-pools>
-                        <strict-max-pool name="slsb-strict-max-pool" max-pool-size="20" instance-acquisition-timeout="5"
-                                         instance-acquisition-timeout-unit="MINUTES"/>
-
-                        <strict-max-pool name="mdb-strict-max-pool" max-pool-size="20" instance-acquisition-timeout="5"
-                                         instance-acquisition-timeout-unit="MINUTES"/>
-                    </bean-instance-pools>
-                </pools>
-
-                <!-- Default MDB configurations -->
-                <mdb>
-                    <resource-adapter-ref resource-adapter-name="hornetq-ra"/>
-                    <bean-instance-pool-ref pool-name="mdb-strict-max-pool"/>
-                </mdb>
-
-                <!-- Session bean configurations -->
+            <subsystem xmlns="urn:jboss:domain:ejb3:1.2">
                 <session-bean>
                     <stateless>
                         <bean-instance-pool-ref pool-name="slsb-strict-max-pool"/>
@@ -150,12 +102,26 @@
                     <stateful default-access-timeout="5000"/>
                     <singleton default-access-timeout="5000"/>
                 </session-bean>
-
+                <mdb>
+                    <resource-adapter-ref resource-adapter-name="hornetq-ra"/>
+                    <bean-instance-pool-ref pool-name="mdb-strict-max-pool"/>
+                </mdb>
+                <pools>
+                    <bean-instance-pools>
+                        <strict-max-pool name="slsb-strict-max-pool" max-pool-size="20" instance-acquisition-timeout="5" instance-acquisition-timeout-unit="MINUTES"/>
+                        <strict-max-pool name="mdb-strict-max-pool" max-pool-size="20" instance-acquisition-timeout="5" instance-acquisition-timeout-unit="MINUTES"/>
+                    </bean-instance-pools>
+                </pools>
+                <async thread-pool-name="default"/>
+                <timer-service thread-pool-name="default">
+                    <data-store path="timer-service-data" relative-to="jboss.server.data.dir"/>
+                </timer-service>
+                <remote connector-ref="remoting-connector" thread-pool-name="default"/>
                 <thread-pools>
-                    <thread-pool name="default" max-threads="10" keepalive-time="100" />
+                    <thread-pool name="default" max-threads="10" keepalive-time="100"/>
                 </thread-pools>
             </subsystem>
-            <subsystem xmlns="urn:jboss:domain:infinispan:1.0" default-cache-container="cluster">
+            <subsystem xmlns="urn:jboss:domain:infinispan:1.1" default-cache-container="cluster">
                 <cache-container name="cluster" default-cache="default">
                     <alias>ha-partition</alias>
                     <replicated-cache name="default" mode="SYNC" batching="true">
@@ -203,7 +169,7 @@
             </subsystem>
             <subsystem xmlns="urn:jboss:domain:jacorb:1.1"/>
             <subsystem xmlns="urn:jboss:domain:jaxrs:1.0"/>
-            <subsystem xmlns="urn:jboss:domain:jca:1.0">
+            <subsystem xmlns="urn:jboss:domain:jca:1.1">
                 <archive-validation enabled="true"/>
                 <bean-validation enabled="true"/>
                 <default-workmanager>
@@ -260,20 +226,22 @@
                     <protocol type="pbcast.FLUSH"/>
                 </stack>
             </subsystem>
-            <subsystem xmlns="urn:jboss:domain:jmx:1.1" show-model="true">
-                 <jmx-connector registry-binding="jmx-connector-registry" server-binding="jmx-connector-server" />
-            </subsystem>
+            <subsystem xmlns="urn:jboss:domain:jmx:1.1" show-model="true"/>
             <subsystem xmlns="urn:jboss:domain:jpa:1.0">
                  <jpa default-datasource=""/>
             </subsystem>
+            <subsystem xmlns="urn:jboss:domain:mail:1.0">
+                <mail-session jndi-name="java:jboss/mail/Default">
+                    <smtp-server outbound-socket-binding-ref="mail-smtp"/>
+                </mail-session>
+            </subsystem>
             <subsystem xmlns="urn:jboss:domain:messaging:1.1">
                 <hornetq-server>
+                    <!-- disable messaging persistence -->
+                    <persistence-enabled>false</persistence-enabled>
                     <!-- Default journal file size is 10Mb, reduced here to 100k for faster first boot -->
                     <journal-file-size>102400</journal-file-size>
                     <journal-min-files>2</journal-min-files>
-                    <journal-type>NIO</journal-type>
-                    <!-- disable messaging persistence -->
-                    <persistence-enabled>false</persistence-enabled>
 
                     <connectors>
                         <netty-connector name="netty" socket-binding="messaging"/>
@@ -294,10 +262,10 @@
 
                     <security-settings>
                         <security-setting match="#">
+                            <permission type="send" roles="guest"/>
+                            <permission type="consume" roles="guest"/>
                             <permission type="createNonDurableQueue" roles="guest"/>
                             <permission type="deleteNonDurableQueue" roles="guest"/>
-                            <permission type="consume" roles="guest"/>
-                            <permission type="send" roles="guest"/>
                         </security-setting>
                     </security-settings>
 
@@ -313,7 +281,6 @@
                         </address-setting>
                     </address-settings>
 
-                    <!--JMS Stuff-->
                     <jms-connection-factories>
                         <connection-factory name="InVmConnectionFactory">
                             <connectors>
@@ -355,7 +322,7 @@
             <subsystem xmlns="urn:jboss:domain:modcluster:1.0">
                 <mod-cluster-config advertise-socket="modcluster"/>
             </subsystem>
-            <subsystem xmlns="urn:jboss:domain:naming:1.0"/>
+            <subsystem xmlns="urn:jboss:domain:naming:1.1"/>
             <subsystem xmlns="urn:jboss:domain:osgi:1.1" activation="lazy">
                 <configuration pid="org.apache.felix.webconsole.internal.servlet.OsgiManager">
                     <property name="manager.root" value="jboss-osgi"/>
@@ -394,12 +361,12 @@
                     <capability name="org.jboss.osgi.xerces" startlevel="3"/>
                 </capabilities>
             </subsystem>
-            <subsystem xmlns="urn:jboss:domain:remoting:1.0">
+            <subsystem xmlns="urn:jboss:domain:remoting:1.1">
                 <connector name="remoting-connector" socket-binding="remoting"/>
             </subsystem>
             <subsystem xmlns="urn:jboss:domain:resource-adapters:1.0"/>
             <subsystem xmlns="urn:jboss:domain:sar:1.0"/>
-            <subsystem xmlns="urn:jboss:domain:security:1.0">
+            <subsystem xmlns="urn:jboss:domain:security:1.1">
                 <security-domains>
                     <security-domain name="other">
                         <authentication>
@@ -457,33 +424,47 @@
                     <max-threads count="2" per-cpu="2" />
                 </queueless-thread-pool>
             </subsystem>
-            <subsystem xmlns="urn:jboss:domain:transactions:1.0">
-                <recovery-environment socket-binding="txn-recovery-environment" status-socket-binding="txn-status-manager"/>
+            <subsystem xmlns="urn:jboss:domain:transactions:1.1">
                 <core-environment>
                     <process-id>
                         <uuid />
                     </process-id>
                 </core-environment>
+                <recovery-environment socket-binding="txn-recovery-environment" status-socket-binding="txn-status-manager"/>
                 <coordinator-environment default-timeout="300"/>
             </subsystem>
             <subsystem xmlns="urn:jboss:domain:web:1.0" default-virtual-server="default-host">
-                <connector name="http" scheme="http" protocol="HTTP/1.1" socket-binding="http"/>
+                <connector name="http" protocol="HTTP/1.1" scheme="http" socket-binding="http"/>
                 <virtual-server name="default-host" enable-welcome-root="true">
-                    <alias name="localhost" />
-                    <alias name="example.com" />
+                    <alias name="localhost"/>
+                    <alias name="example.com"/>
                 </virtual-server>
             </subsystem>
-            <subsystem xmlns="urn:jboss:domain:webservices:1.0">
+            <subsystem xmlns="urn:jboss:domain:webservices:1.0" xmlns:javaee="http://java.sun.com/xml/ns/javaee" xmlns:jaxwsconfig="urn:jboss:jbossws-jaxws-config:4.0">
                 <modify-wsdl-address>true</modify-wsdl-address>
                 <wsdl-host>${jboss.bind.address:127.0.0.1}</wsdl-host>
                 <!--
                 <wsdl-port>8080</wsdl-port>
                 <wsdl-secure-port>8443</wsdl-secure-port>
                 -->
+                <endpoint-config>
+                    <jaxwsconfig:config-name>Standard-Endpoint-Config</jaxwsconfig:config-name>
+                </endpoint-config>
+                <endpoint-config>
+                    <jaxwsconfig:config-name>Recording-Endpoint-Config</jaxwsconfig:config-name>
+                    <jaxwsconfig:pre-handler-chains>
+                        <javaee:handler-chain xmlns="http://java.sun.com/xml/ns/javaee">
+                            <javaee:protocol-bindings>##SOAP11_HTTP ##SOAP11_HTTP_MTOM ##SOAP12_HTTP ##SOAP12_HTTP_MTOM</javaee:protocol-bindings>
+                            <javaee:handler>
+                                <javaee:handler-name>RecordingHandler</javaee:handler-name>
+                                <javaee:handler-class>org.jboss.ws.common.invocation.RecordingServerHandler</javaee:handler-class>
+                            </javaee:handler>
+                        </javaee:handler-chain>
+                    </jaxwsconfig:pre-handler-chains>
+                </endpoint-config>
             </subsystem>
             <subsystem xmlns="urn:jboss:domain:weld:1.0"/>
         </profile>
-
     </profiles>
 
     <!--
@@ -506,12 +487,15 @@
             <socket-binding name="jacorb-ssl" port="3529"/>
             <socket-binding name="jmx-connector-registry" interface="management" port="1090"/>
             <socket-binding name="jmx-connector-server" interface="management" port="1091"/>
-            <socket-binding name="messaging" port="5445" />
+            <socket-binding name="messaging" port="5445"/>
             <socket-binding name="messaging-throughput" port="5455"/>
             <socket-binding name="osgi-http" interface="management" port="8090"/>
             <socket-binding name="remoting" port="4447"/>
             <socket-binding name="txn-recovery-environment" port="4712"/>
             <socket-binding name="txn-status-manager" port="4713"/>
+            <outbound-socket-binding name="mail-smtp">
+                <remote-destination host="localhost" port="25"/>
+            </outbound-socket-binding>
         </socket-binding-group>
         <socket-binding-group name="ha-sockets" default-interface="public">
             <socket-binding name="http" port="8080"/>
@@ -526,7 +510,7 @@
             <socket-binding name="jgroups-udp-fd" port="54200"/>
             <socket-binding name="jmx-connector-registry" interface="management" port="1090"/>
             <socket-binding name="jmx-connector-server" interface="management" port="1091"/>
-            <socket-binding name="messaging" port="5445" />
+            <socket-binding name="messaging" port="5445"/>
             <socket-binding name="messaging-throughput" port="5455"/>
             <socket-binding name="modcluster" port="0"  multicast-address="224.0.1.105" multicast-port="23364"/>
             <socket-binding name="osgi-http" interface="management" port="8090"/>
@@ -535,6 +519,9 @@
             <socket-binding name="txn-status-manager" port="4713"/>
             <socket-binding name="teiid-jdbc" port="31000"/>
             <socket-binding name="teiid-odbc" port="35432"/>             
+            <outbound-socket-binding name="mail-smtp">
+                <remote-destination host="localhost" port="25"/>
+            </outbound-socket-binding>
         </socket-binding-group>
     </socket-binding-groups>
 

Modified: trunk/build/kits/jboss-as7/domain/configuration/host-teiid.xml
===================================================================
--- trunk/build/kits/jboss-as7/domain/configuration/host-teiid.xml	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/build/kits/jboss-as7/domain/configuration/host-teiid.xml	2011-12-01 18:19:11 UTC (rev 3714)
@@ -1,27 +1,6 @@
-<!--
-  ~ JBoss, Home of Professional Open Source.
-  ~ Copyright 2010, Red Hat, Inc., and individual contributors
-  ~ as indicated by the @author tags. See the copyright.txt file in the
-  ~ distribution for a full listing of individual contributors.
-  ~
-  ~ This is free software; you can redistribute it and/or modify it
-  ~ under the terms of the GNU Lesser General Public License as
-  ~ published by the Free Software Foundation; either version 2.1 of
-  ~ the License, or (at your option) any later version.
-  ~
-  ~ This software 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
-  ~ Lesser General Public License for more details.
-  ~
-  ~ You should have received a copy of the GNU Lesser General Public
-  ~ License along with this software; if not, write to the Free
-  ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  -->
+<?xml version='1.0' encoding='UTF-8'?>
 
-<host xmlns="urn:jboss:domain:1.1"
-      name="master">
+<host name="master" xmlns="urn:jboss:domain:1.1">
 
     <management>
         <security-realms>
@@ -73,16 +52,14 @@
               -->
            </jvm>
         </server>
-
         <server name="server-two" group="main-server-group" auto-start="true">
             <!-- server-two avoids port conflicts by incrementing the ports in
                  the default socket-group declared in the server-group -->
             <socket-binding-group ref="ha-sockets" port-offset="150"/>
             <jvm name="default">
-                <heap size="512m" max-size="1024m"/>
+                <heap size="64m" max-size="256m"/>
             </jvm>
         </server>
-
         <server name="server-three" group="main-server-group" auto-start="false">
             <!-- server-three avoids port conflicts by incrementing the ports in
                  the default socket-group declared in the server-group -->

Modified: trunk/build/kits/jboss-as7/modules/org/jboss/teiid/client/main/module.xml
===================================================================
--- trunk/build/kits/jboss-as7/modules/org/jboss/teiid/client/main/module.xml	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/build/kits/jboss-as7/modules/org/jboss/teiid/client/main/module.xml	2011-12-01 18:19:11 UTC (rev 3714)
@@ -10,5 +10,7 @@
         <module name="org.jboss.teiid.common-core" />
         <module name="javax.transaction.api"/>
         <module name="javax.api"/>
+        <module name="sun.jdk"/>
+        <module name="org.jboss.modules"/>
     </dependencies>
 </module>
\ No newline at end of file

Modified: trunk/build/kits/jboss-as7/standalone/configuration/standalone-teiid.xml
===================================================================
--- trunk/build/kits/jboss-as7/standalone/configuration/standalone-teiid.xml	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/build/kits/jboss-as7/standalone/configuration/standalone-teiid.xml	2011-12-01 18:19:11 UTC (rev 3714)
@@ -1,43 +1,19 @@
-<!--
-  ~ JBoss, Home of Professional Open Source.
-  ~ Copyright 2011, Red Hat, Inc., and individual contributors
-  ~ as indicated by the @author tags. See the copyright.txt file in the
-  ~ distribution for a full listing of individual contributors.
-  ~
-  ~ This is free software; you can redistribute it and/or modify it
-  ~ under the terms of the GNU Lesser General Public License as
-  ~ published by the Free Software Foundation; either version 2.1 of
-  ~ the License, or (at your option) any later version.
-  ~
-  ~ This software 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
-  ~ Lesser General Public License for more details.
-  ~
-  ~ You should have received a copy of the GNU Lesser General Public
-  ~ License along with this software; if not, write to the Free
-  ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-  ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-  -->
+<?xml version='1.0' encoding='UTF-8'?>
 
 <server xmlns="urn:jboss:domain:1.1">
 
     <extensions>
         <extension module="org.jboss.as.clustering.infinispan"/>
-        <extension module="org.jboss.as.cmp"/>
         <extension module="org.jboss.as.connector"/>
         <extension module="org.jboss.as.deployment-scanner"/>
         <extension module="org.jboss.as.ee"/>
         <extension module="org.jboss.as.ejb3"/>
-        <extension module="org.jboss.as.jacorb"/>
-        <extension module="org.jboss.as.jaxr"/>
         <extension module="org.jboss.as.jaxrs"/>
         <extension module="org.jboss.as.jdr"/>
         <extension module="org.jboss.as.jmx"/>
         <extension module="org.jboss.as.jpa"/>
         <extension module="org.jboss.as.logging"/>
         <extension module="org.jboss.as.mail"/>
-        <extension module="org.jboss.as.messaging"/>
         <extension module="org.jboss.as.naming"/>
         <extension module="org.jboss.as.osgi"/>
         <extension module="org.jboss.as.pojo"/>
@@ -78,7 +54,6 @@
                     <pattern-formatter pattern="%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%n"/>
                 </formatter>
             </console-handler>
-
             <periodic-rotating-file-handler name="FILE">
                 <formatter>
                     <pattern-formatter pattern="%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%n"/>
@@ -87,7 +62,6 @@
                 <suffix value=".yyyy-MM-dd"/>
                 <append value="true"/>
             </periodic-rotating-file-handler>
-
             <logger category="com.arjuna">
                 <level name="WARN"/>
             </logger>
@@ -100,11 +74,9 @@
             <logger category="jacorb">
                 <level name="WARN"/>
             </logger>
-            <!-- set jacorb.config to ERROR to avoid the "jacorb.properties not found" messages during startup -->
             <logger category="jacorb.config">
                 <level name="ERROR"/>
             </logger>
-
             <root-logger>
                 <level name="INFO"/>
                 <handlers>
@@ -113,7 +85,6 @@
                 </handlers>
             </root-logger>
         </subsystem>
-        <subsystem xmlns="urn:jboss:domain:cmp:1.0"/>
         <subsystem xmlns="urn:jboss:domain:datasources:1.0">
             <datasources>
                 <datasource jndi-name="java:jboss/datasources/ExampleDS" enabled="true" use-java-context="true"
@@ -126,78 +97,18 @@
                         <password>sa</password>
                     </security>
                 </datasource>
-                <datasource jndi-name="java:/postgres-ds" pool-name="PostgreDS">
-                    <connection-url>jdbc:postgresql://127.0.0.1:5432/txns</connection-url>
-                    <driver>postgresql</driver>
-                    <pool>
-                        <prefill>false</prefill>
-                        <use-strict-min>false</use-strict-min>
-                        <flush-strategy>FailingConnectionOnly</flush-strategy>
-                    </pool>
-                    <security>
-                        <user-name>rareddy</user-name>
-                        <password>mm</password>
-                    </security>
-                </datasource>  
-                <datasource jndi-name="java:/mysql-ds" pool-name="mysqlDS">
-                    <connection-url>jdbc:mysql://localhost:3306/txns</connection-url>
-                    <driver>mysql</driver>
-                    <pool>
-                        <prefill>false</prefill>
-                        <use-strict-min>false</use-strict-min>
-                        <flush-strategy>FailingConnectionOnly</flush-strategy>
-                    </pool>
-                    <security>
-                        <user-name>rareddy</user-name>
-                        <password>mm</password>
-                    </security>
-                </datasource>                               
                 <drivers>
                     <driver name="h2" module="com.h2database.h2">
                         <xa-datasource-class>org.h2.jdbcx.JdbcDataSource</xa-datasource-class>
                     </driver>
-                    <driver name="mysql" module="com.mysql">
-                        <xa-datasource-class>com.mysql.jdbc.jdbc2.optional.MysqlXADataSource</xa-datasource-class>
-                    </driver>                    
-                    <driver name="oracle" module="com.oracle">
-                        <xa-datasource-class>oracle.jdbc.xa.client.OracleXADataSource</xa-datasource-class>
-                    </driver>    
-                    <driver name="com.mysql" module="com.mysql"/>
-                    <driver name="postgresql" module="com.mysql"/>                    
                 </drivers>
             </datasources>
         </subsystem>
         <subsystem xmlns="urn:jboss:domain:deployment-scanner:1.0">
             <deployment-scanner scan-interval="5000" relative-to="jboss.server.base.dir" path="deployments"/>
         </subsystem>
-        <subsystem xmlns="urn:jboss:domain:ee:1.0" />
-        <subsystem xmlns="urn:jboss:domain:ejb3:1.2" >
-
-            <remote connector-ref="remoting-connector" thread-pool-name="default" />
-            <async thread-pool-name="default" />
-
-            <timer-service thread-pool-name="default" >
-                <data-store path="timer-service-data" relative-to="jboss.server.data.dir"/>
-            </timer-service>
-
-            <!-- EJB3 pools -->
-            <pools>
-                <bean-instance-pools>
-                    <strict-max-pool name="slsb-strict-max-pool" max-pool-size="20" instance-acquisition-timeout="5"
-                                     instance-acquisition-timeout-unit="MINUTES"/>
-
-                    <strict-max-pool name="mdb-strict-max-pool" max-pool-size="20" instance-acquisition-timeout="5"
-                                     instance-acquisition-timeout-unit="MINUTES"/>
-                </bean-instance-pools>
-            </pools>
-
-            <!-- Default MDB configurations -->
-            <mdb>
-                <resource-adapter-ref resource-adapter-name="hornetq-ra"/>
-                <bean-instance-pool-ref pool-name="mdb-strict-max-pool"/>
-            </mdb>
-
-            <!-- Session bean configurations -->
+        <subsystem xmlns="urn:jboss:domain:ee:1.0"/>
+        <subsystem xmlns="urn:jboss:domain:ejb3:1.2">
             <session-bean>
                 <stateless>
                     <bean-instance-pool-ref pool-name="slsb-strict-max-pool"/>
@@ -205,12 +116,26 @@
                 <stateful default-access-timeout="5000"/>
                 <singleton default-access-timeout="5000"/>
             </session-bean>
-
+            <mdb>
+                <resource-adapter-ref resource-adapter-name="hornetq-ra"/>
+                <bean-instance-pool-ref pool-name="mdb-strict-max-pool"/>
+            </mdb>
+            <pools>
+                <bean-instance-pools>
+                    <strict-max-pool name="slsb-strict-max-pool" max-pool-size="20" instance-acquisition-timeout="5" instance-acquisition-timeout-unit="MINUTES"/>
+                    <strict-max-pool name="mdb-strict-max-pool" max-pool-size="20" instance-acquisition-timeout="5" instance-acquisition-timeout-unit="MINUTES"/>
+                </bean-instance-pools>
+            </pools>
+            <async thread-pool-name="default"/>
+            <timer-service thread-pool-name="default">
+                <data-store path="timer-service-data" relative-to="jboss.server.data.dir"/>
+            </timer-service>
+            <remote connector-ref="remoting-connector" thread-pool-name="default"/>
             <thread-pools>
-                <thread-pool name="default" max-threads="10" keepalive-time="100" />
+                <thread-pool name="default" max-threads="10" keepalive-time="100"/>
             </thread-pools>
         </subsystem>
-        <subsystem xmlns="urn:jboss:domain:infinispan:1.0" default-cache-container="hibernate">
+        <subsystem xmlns="urn:jboss:domain:infinispan:1.1" default-cache-container="hibernate">
             <cache-container name="hibernate" default-cache="local-query">
                 <local-cache name="entity">
                     <eviction strategy="LRU" max-entries="10000"/>
@@ -231,12 +156,8 @@
                 </local-cache>
             </cache-container>            
         </subsystem>
-        <subsystem xmlns="urn:jboss:domain:jacorb:1.1"/>
-        <subsystem xmlns="urn:jboss:domain:jaxr:1.0">
-            <datasource jndi-name="java:jboss/datasources/ExampleDS"/>
-        </subsystem>
         <subsystem xmlns="urn:jboss:domain:jaxrs:1.0"/>
-        <subsystem xmlns="urn:jboss:domain:jca:1.0">
+        <subsystem xmlns="urn:jboss:domain:jca:1.1">
             <archive-validation enabled="false"/>
             <bean-validation enabled="false"/>
             <default-workmanager>
@@ -255,103 +176,16 @@
             </default-workmanager>
         </subsystem>
         <subsystem xmlns="urn:jboss:domain:jdr:1.0"/>
-        <subsystem xmlns="urn:jboss:domain:jmx:1.1" show-model="true">
-            <jmx-connector registry-binding="jmx-connector-registry" server-binding="jmx-connector-server" />
-        </subsystem>
+        <subsystem xmlns="urn:jboss:domain:jmx:1.1" show-model="true"/>
         <subsystem xmlns="urn:jboss:domain:jpa:1.0">
             <jpa default-datasource=""/>
         </subsystem>
         <subsystem xmlns="urn:jboss:domain:mail:1.0">
             <mail-session jndi-name="java:jboss/mail/Default">
-                <smtp-server address="localhost" port="25"/>
+                <smtp-server outbound-socket-binding-ref="mail-smtp"/>
             </mail-session>
         </subsystem>
-        <subsystem xmlns="urn:jboss:domain:messaging:1.1">
-            <hornetq-server>
-                <!-- Default journal file size is 10Mb, reduced here to 100k for faster first boot -->
-                <journal-file-size>102400</journal-file-size>
-                <journal-min-files>2</journal-min-files>
-                <!-- disable messaging persistence -->
-                <persistence-enabled>false</persistence-enabled>
-
-                <connectors>
-                    <netty-connector name="netty" socket-binding="messaging-client"/>
-                    <netty-connector name="netty-throughput" socket-binding="messaging-throughput-client">
-                        <param key="batch-delay" value="50"/>
-                    </netty-connector>
-                    <in-vm-connector name="in-vm" server-id="0"/>
-                </connectors>
-
-                <acceptors>
-                    <netty-acceptor name="netty" socket-binding="messaging"/>
-                    <netty-acceptor name="netty-throughput" socket-binding="messaging-throughput">
-                        <param key="batch-delay" value="50"/>
-                        <param key="direct-deliver" value="false"/>
-                    </netty-acceptor>
-                    <in-vm-acceptor name="in-vm" server-id="0"/>
-                </acceptors>
-
-                <security-settings>
-                    <security-setting match="#">
-                        <permission type="createNonDurableQueue" roles="guest"/>
-                        <permission type="deleteNonDurableQueue" roles="guest"/>
-                        <permission type="consume" roles="guest"/>
-                        <permission type="send" roles="guest"/>
-                    </security-setting>
-                </security-settings>
-
-                <address-settings>
-                    <!--default for catch all-->
-                    <address-setting match="#">
-                        <dead-letter-address>jms.queue.DLQ</dead-letter-address>
-                        <expiry-address>jms.queue.ExpiryQueue</expiry-address>
-                        <redelivery-delay>0</redelivery-delay>
-                        <max-size-bytes>10485760</max-size-bytes>
-                        <message-counter-history-day-limit>10</message-counter-history-day-limit>
-                        <address-full-policy>BLOCK</address-full-policy>
-                    </address-setting>
-                </address-settings>
-
-                <!--JMS Stuff-->
-                <jms-connection-factories>
-                    <connection-factory name="InVmConnectionFactory">
-                        <connectors>
-                            <connector-ref connector-name="in-vm"/>
-                        </connectors>
-                        <entries>
-                            <entry name="java:/ConnectionFactory"/>
-                        </entries>
-                    </connection-factory>
-                    <connection-factory name="RemoteConnectionFactory">
-                        <connectors>
-                            <connector-ref connector-name="netty"/>
-                        </connectors>
-                        <entries>
-                            <entry name="RemoteConnectionFactory"/>
-                        </entries>
-                    </connection-factory>
-                    <pooled-connection-factory name="hornetq-ra">
-                        <transaction mode="xa"/>
-                        <connectors>
-                            <connector-ref connector-name="in-vm"/>
-                        </connectors>
-                        <entries>
-                            <entry name="java:/JmsXA"/>
-                        </entries>
-                    </pooled-connection-factory>
-                </jms-connection-factories>
-
-                <jms-destinations>
-                    <jms-queue name="testQueue">
-                        <entry name="queue/test"/>
-                    </jms-queue>
-                    <jms-topic name="testTopic">
-                        <entry name="topic/test"/>
-                    </jms-topic>
-                </jms-destinations>
-            </hornetq-server>
-        </subsystem>
-        <subsystem xmlns="urn:jboss:domain:naming:1.0"/>
+        <subsystem xmlns="urn:jboss:domain:naming:1.1"/>
         <subsystem xmlns="urn:jboss:domain:osgi:1.1" activation="lazy">
             <configuration pid="org.apache.felix.webconsole.internal.servlet.OsgiManager">
                 <property name="manager.root" value="jboss-osgi"/>
@@ -390,30 +224,13 @@
                 <capability name="org.jboss.osgi.xerces" startlevel="3"/>
             </capabilities>
         </subsystem>
-        <subsystem xmlns="urn:jboss:domain:pojo:1.0" />
-        <subsystem xmlns="urn:jboss:domain:remoting:1.0">
+        <subsystem xmlns="urn:jboss:domain:pojo:1.0"/>
+        <subsystem xmlns="urn:jboss:domain:remoting:1.1">
             <connector name="remoting-connector" socket-binding="remoting"/>
         </subsystem>
-        <subsystem xmlns="urn:jboss:domain:resource-adapters:1.0">
-            <resource-adapters>
-                <resource-adapter>
-                    <archive>teiid-connector-file.rar</archive>
-                    <transaction-support>NoTransaction</transaction-support>
-                    <connection-definitions>
-                        <connection-definition class-name="org.teiid.resource.adapter.file.FileManagedConnectionFactory" 
-                                jndi-name="java:/fileDS" 
-                                enabled="true" 
-                                use-java-context="true" 
-                                pool-name="teiid-file-ds">
-                              <config-property name="ParentDirectory">/home/rareddy/testing/</config-property>
-                              <config-property name="AllowParentPaths">true</config-property>
-                        </connection-definition>
-                    </connection-definitions>
-                </resource-adapter>
-            </resource-adapters>
-        </subsystem>
+        <subsystem xmlns="urn:jboss:domain:resource-adapters:1.0"/>
         <subsystem xmlns="urn:jboss:domain:sar:1.0"/>
-        <subsystem xmlns="urn:jboss:domain:security:1.0">
+        <subsystem xmlns="urn:jboss:domain:security:1.1">
             <security-domains>
                 <security-domain name="other" cache-type="default">
                     <authentication>
@@ -490,43 +307,42 @@
             </queueless-thread-pool>
         </subsystem>
         <subsystem xmlns="urn:jboss:domain:transactions:1.1">
-            <recovery-environment socket-binding="txn-recovery-environment" status-socket-binding="txn-status-manager"/>
             <core-environment>
                 <process-id>
                     <uuid/>
                 </process-id>
             </core-environment>
+            <recovery-environment socket-binding="txn-recovery-environment" status-socket-binding="txn-status-manager"/>
             <coordinator-environment default-timeout="300"/>
         </subsystem>
-        <subsystem xmlns="urn:jboss:domain:web:1.0" default-virtual-server="default-host">
-            <connector name="http" scheme="http" protocol="HTTP/1.1" socket-binding="http"/>
+        <subsystem xmlns="urn:jboss:domain:web:1.1" default-virtual-server="default-host">
+            <connector name="http" protocol="HTTP/1.1" scheme="http" socket-binding="http"/>
             <virtual-server name="default-host" enable-welcome-root="true">
                 <alias name="localhost"/>
                 <alias name="example.com"/>
             </virtual-server>
         </subsystem>
-        <subsystem xmlns="urn:jboss:domain:webservices:1.0">
+        <subsystem xmlns="urn:jboss:domain:webservices:1.0" xmlns:javaee="http://java.sun.com/xml/ns/javaee" xmlns:jaxwsconfig="urn:jboss:jbossws-jaxws-config:4.0">
             <modify-wsdl-address>true</modify-wsdl-address>
             <wsdl-host>${jboss.bind.address:127.0.0.1}</wsdl-host>
             <!--
             <wsdl-port>8080</wsdl-port>
             <wsdl-secure-port>8443</wsdl-secure-port>
             -->
-            <endpoint-config xmlns:ws="urn:jboss:jbossws-jaxws-config:4.0">
-                <ws:config-name>Standard-Endpoint-Config</ws:config-name>
+            <endpoint-config>
+                <jaxwsconfig:config-name>Standard-Endpoint-Config</jaxwsconfig:config-name>
             </endpoint-config>
-            <endpoint-config xmlns:ws="urn:jboss:jbossws-jaxws-config:4.0">
-                <ws:config-name>Recording-Endpoint-Config</ws:config-name>
-                <ws:pre-handler-chains>
-                    <handler-chain xmlns="http://java.sun.com/xml/ns/javaee">
-                        <protocol-bindings>##SOAP11_HTTP ##SOAP11_HTTP_MTOM ##SOAP12_HTTP ##SOAP12_HTTP_MTOM
-                        </protocol-bindings>
-                        <handler>
-                            <handler-name>RecordingHandler</handler-name>
-                            <handler-class>org.jboss.ws.common.invocation.RecordingServerHandler</handler-class>
-                        </handler>
-                    </handler-chain>
-                </ws:pre-handler-chains>
+            <endpoint-config>
+                <jaxwsconfig:config-name>Recording-Endpoint-Config</jaxwsconfig:config-name>
+                <jaxwsconfig:pre-handler-chains>
+                    <javaee:handler-chain xmlns="http://java.sun.com/xml/ns/javaee">
+                            <javaee:protocol-bindings>##SOAP11_HTTP ##SOAP11_HTTP_MTOM ##SOAP12_HTTP ##SOAP12_HTTP_MTOM</javaee:protocol-bindings>
+                        <javaee:handler>
+                            <javaee:handler-name>RecordingHandler</javaee:handler-name>
+                            <javaee:handler-class>org.jboss.ws.common.invocation.RecordingServerHandler</javaee:handler-class>
+                        </javaee:handler>
+                    </javaee:handler-chain>
+                </jaxwsconfig:pre-handler-chains>
             </endpoint-config>
         </subsystem>
         <subsystem xmlns="urn:jboss:domain:weld:1.0"/>
@@ -537,7 +353,7 @@
             <inet-address value="${jboss.bind.address.management:127.0.0.1}"/>
         </interface>
         <interface name="public">
-           <inet-address value="${jboss.bind.address:127.0.0.1}"/>
+            <inet-address value="${jboss.bind.address:127.0.0.1}"/>
         </interface>
     </interfaces>
 
@@ -557,13 +373,10 @@
         <socket-binding name="txn-recovery-environment" port="4712"/>
         <socket-binding name="txn-status-manager" port="4713"/>
         <socket-binding name="teiid-jdbc" port="31000"/>
-        <socket-binding name="teiid-odbc" port="35432"/>         
-        <outbound-socket-binding name="messaging-client">
-            <local-destination socket-binding-ref="messaging"/>
+        <socket-binding name="teiid-odbc" port="35432"/>        
+        <outbound-socket-binding name="mail-smtp">
+            <remote-destination host="localhost" port="25"/>
         </outbound-socket-binding>
-        <outbound-socket-binding name="messaging-throughput-client">
-            <local-destination socket-binding-ref="messaging-throughput"/>
-        </outbound-socket-binding>
     </socket-binding-group>
 
 </server>

Modified: trunk/client/pom.xml
===================================================================
--- trunk/client/pom.xml	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/client/pom.xml	2011-12-01 18:19:11 UTC (rev 3714)
@@ -20,5 +20,10 @@
 			<artifactId>teiid-common-core</artifactId>
 			<type>test-jar</type>
 		</dependency>
+        <dependency>
+            <groupId>org.jboss.modules</groupId>
+            <artifactId>jboss-modules</artifactId>
+            <scope>provided</scope>
+        </dependency>         
 	</dependencies>
 </project>
\ No newline at end of file

Modified: trunk/client/src/main/java/org/teiid/jdbc/EmbeddedProfile.java
===================================================================
--- trunk/client/src/main/java/org/teiid/jdbc/EmbeddedProfile.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/client/src/main/java/org/teiid/jdbc/EmbeddedProfile.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -26,6 +26,9 @@
 import java.util.Arrays;
 import java.util.Properties;
 
+import org.jboss.modules.Module;
+import org.jboss.modules.ModuleIdentifier;
+import org.jboss.modules.ModuleLoadException;
 import org.teiid.core.TeiidException;
 import org.teiid.core.TeiidRuntimeException;
 import org.teiid.core.util.PropertiesUtils;
@@ -62,9 +65,19 @@
 		}
     }
 
-	protected ServerConnection createServerConnection(Properties info)
-			throws TeiidException {
-		return (ServerConnection)ReflectionHelper.create("org.teiid.transport.LocalServerConnection", Arrays.asList(info, PropertiesUtils.getBooleanProperty(info, USE_CALLING_THREAD, true)), Thread.currentThread().getContextClassLoader()); //$NON-NLS-1$
+	protected ServerConnection createServerConnection(Properties info) throws TeiidException {
+		ClassLoader tccl = Thread.currentThread().getContextClassLoader();
+		try {
+	        try {
+	        	final Module module = Module.getCallerModuleLoader().loadModule(ModuleIdentifier.create("org.jboss.teiid")); //$NON-NLS-1$
+	        	Thread.currentThread().setContextClassLoader(module.getClassLoader());
+	        } catch (ModuleLoadException e) {
+	        	Thread.currentThread().setContextClassLoader(this.getClass().getClassLoader());
+	        } 
+	        return (ServerConnection)ReflectionHelper.create("org.teiid.transport.LocalServerConnection", Arrays.asList(info, PropertiesUtils.getBooleanProperty(info, USE_CALLING_THREAD, true)), Thread.currentThread().getContextClassLoader()); //$NON-NLS-1$
+		} finally {
+        	Thread.currentThread().setContextClassLoader(tccl);
+        }
 	}
     
 }


Property changes on: trunk/client/src/main/java/org/teiid/jdbc/EmbeddedProfile.java
___________________________________________________________________
Modified: svn:mergeinfo
   - /branches/7.4.x/client/src/main/java/org/teiid/jdbc/EmbeddedProfile.java:3149-3217,3535-3555
/branches/7.6.x/client/src/main/java/org/teiid/jdbc/EmbeddedProfile.java:3673-3711
/trunk/client/src/main/java/org/teiid/jdbc/EmbeddedProfile.java:3188-3450,3452-3666
   + /branches/7.4.x/client/src/main/java/org/teiid/jdbc/EmbeddedProfile.java:3149-3217,3535-3555
/trunk/client/src/main/java/org/teiid/jdbc/EmbeddedProfile.java:3188-3450,3452-3666

Modified: trunk/connectors/translator-hive/pom.xml
===================================================================
--- trunk/connectors/translator-hive/pom.xml	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/connectors/translator-hive/pom.xml	2011-12-01 18:19:11 UTC (rev 3714)
@@ -25,13 +25,13 @@
         <dependency>
             <groupId>org.jboss.teiid.connectors</groupId>
             <artifactId>translator-jdbc</artifactId>
-            <version>${version}</version>
+            <version>${project.version}</version>
             <scope>provided</scope>
         </dependency>   
         <dependency>
             <groupId>org.jboss.teiid.connectors</groupId>
             <artifactId>translator-jdbc</artifactId>
-            <version>${version}</version>        
+            <version>${project.version}</version>        
             <type>test-jar</type>
             <scope>test</scope>
         </dependency>

Modified: trunk/jboss-integration/pom.xml
===================================================================
--- trunk/jboss-integration/pom.xml	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/pom.xml	2011-12-01 18:19:11 UTC (rev 3714)
@@ -37,6 +37,7 @@
     <dependency>
       <groupId>org.jboss.teiid</groupId>
       <artifactId>teiid-admin</artifactId>
+      <scope>provided</scope>
     </dependency>    
     
     <dependency>
@@ -62,22 +63,34 @@
         <artifactId>jta</artifactId>
         <scope>provided</scope>
     </dependency>
-    
+
     <dependency>
         <groupId>org.jboss.as</groupId>
         <artifactId>jboss-as-security</artifactId>
-        <scope>provided</scope>
+        <scope>provided</scope>        
     </dependency>    
     
     <!-- This dependency is to read the ra.xml file details -->
     <dependency>
         <groupId>org.jboss.as</groupId>
         <artifactId>jboss-as-connector</artifactId>
-        <scope>provided</scope>
+        <scope>provided</scope>        
     </dependency>    
     
     <dependency>
         <groupId>org.jboss.as</groupId>
+        <artifactId>jboss-as-server</artifactId>
+        <scope>provided</scope>
+    </dependency> 
+    
+    <dependency>
+        <groupId>org.picketbox</groupId>
+        <artifactId>jbosssx-client</artifactId>
+        <scope>provided</scope>
+    </dependency>
+
+    <dependency>
+        <groupId>org.jboss.as</groupId>
         <artifactId>jboss-as-security</artifactId>
         <scope>provided</scope>
     </dependency> 
@@ -108,12 +121,6 @@
       <scope>test</scope>
     </dependency>    
 
-    <dependency>
-        <groupId>org.jboss.logging</groupId>
-        <artifactId>jboss-logging-spi</artifactId>
-        <scope>test</scope>
-    </dependency>     
-    
   </dependencies>
   
 </project>

Modified: trunk/jboss-integration/src/main/java/org/teiid/jboss/BaseOperationHandler.java
===================================================================
--- trunk/jboss-integration/src/main/java/org/teiid/jboss/BaseOperationHandler.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/src/main/java/org/teiid/jboss/BaseOperationHandler.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -24,6 +24,7 @@
 import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.DESCRIPTION;
 import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.OPERATION_NAME;
 import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.OP_ADDR;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.REPLY_PROPERTIES;
 
 import java.util.Locale;
 import java.util.ResourceBundle;
@@ -38,6 +39,7 @@
 
 public abstract class BaseOperationHandler<T> implements DescriptionProvider, OperationStepHandler {
 	private static final String DESCRIBE = ".describe"; //$NON-NLS-1$
+	private static final String REPLY = ".reply"; //$NON-NLS-1$
 	protected static final String MISSING = ".missing"; //$NON-NLS-1$
 	
 	private String operationName; 
@@ -86,14 +88,14 @@
         final ModelNode operation = new ModelNode();
         operation.get(OPERATION_NAME).set(this.operationName);
         operation.get(DESCRIPTION).set(bundle.getString(name()+DESCRIBE));
+		
+        ModelNode reply = operation.get(REPLY_PROPERTIES);
+		reply.get(DESCRIPTION).set(bundle.getString(name()+REPLY));
+		
         describeParameters(operation, bundle);
         return operation;
     }	
     
-//    protected String getReplyName() {
-//    	return name()+".reply"+DESCRIBE; //$NON-NLS-1$
-//    }
-    
     protected String getParameterDescription(ResourceBundle bundle, String paramName) {
     	return bundle.getString(name()+"."+paramName+DESCRIBE); //$NON-NLS-1$ 
     }    

Modified: trunk/jboss-integration/src/main/java/org/teiid/jboss/BufferManagerService.java
===================================================================
--- trunk/jboss-integration/src/main/java/org/teiid/jboss/BufferManagerService.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/src/main/java/org/teiid/jboss/BufferManagerService.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -33,25 +33,24 @@
 
 class BufferManagerService implements Service<BufferService>, BufferService {
 
-	private BufferServiceImpl bufferMgr;
-	private ObjectReplicator replicator;
+	private BufferServiceImpl bufferService;
 	public final InjectedValue<String> pathInjector = new InjectedValue<String>();
+	public final InjectedValue<ObjectReplicator> replicatorInjector = new InjectedValue<ObjectReplicator>();
 	private BufferManager manager;
 	
-	public BufferManagerService(BufferServiceImpl buffer, ObjectReplicator replicator) {
-		this.bufferMgr = buffer;
-		this.replicator = replicator;
+	public BufferManagerService(BufferServiceImpl buffer) {
+		this.bufferService = buffer;
 	}
 	
 	@Override
 	public void start(StartContext context) throws StartException {
-		bufferMgr.setDiskDirectory(pathInjector.getValue());
-		bufferMgr.start();
-		manager = bufferMgr.getBufferManager();
-		if (replicator != null) {
+		bufferService.setDiskDirectory(pathInjector.getValue());
+		bufferService.start();
+		manager = bufferService.getBufferManager();
+		if (replicatorInjector.getValue() != null) {
 			try {
 				//use a mux name that will not conflict with any vdb
-				manager = this.replicator.replicate("$BM$", BufferManager.class, this.manager, 0); //$NON-NLS-1$
+				manager = this.replicatorInjector.getValue().replicate("$BM$", BufferManager.class, this.manager, 0); //$NON-NLS-1$
 			} catch (Exception e) {
 				throw new StartException(e);
 			}
@@ -60,9 +59,9 @@
 
 	@Override
 	public void stop(StopContext context) {
-		bufferMgr.stop();
-		if (this.replicator != null) {
-			this.replicator.stop(bufferMgr);
+		bufferService.stop();
+		if (this.replicatorInjector.getValue() != null) {
+			this.replicatorInjector.getValue().stop(bufferService);
 		}
 	}
 	
@@ -73,7 +72,7 @@
 
 	@Override
 	public BufferService getValue() throws IllegalStateException,IllegalArgumentException {
-		return this.bufferMgr;
+		return this.bufferService;
 	}
 
 }

Added: trunk/jboss-integration/src/main/java/org/teiid/jboss/CacheService.java
===================================================================
--- trunk/jboss-integration/src/main/java/org/teiid/jboss/CacheService.java	                        (rev 0)
+++ trunk/jboss-integration/src/main/java/org/teiid/jboss/CacheService.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -0,0 +1,53 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * See the COPYRIGHT.txt file distributed with this work for information
+ * regarding copyright ownership.  Some portions may be licensed
+ * to Red Hat, Inc. under one or more contributor license agreements.
+ * 
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ * 
+ * This library 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
+ * Lesser General Public License for more details.
+ * 
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+ * 02110-1301 USA.
+ */
+package org.teiid.jboss;
+
+import org.jboss.msc.service.Service;
+import org.jboss.msc.service.StartContext;
+import org.jboss.msc.service.StartException;
+import org.jboss.msc.service.StopContext;
+import org.jboss.msc.value.InjectedValue;
+import org.teiid.dqp.internal.process.SessionAwareCache;
+import org.teiid.dqp.service.BufferService;
+
+class CacheService<T> implements Service<SessionAwareCache<T>> {
+	private SessionAwareCache<T> cache;
+	public final InjectedValue<BufferService> bufferMgrInjector = new InjectedValue<BufferService>();
+	
+	public CacheService(SessionAwareCache<T> t){
+		this.cache = t;
+	}
+	
+	@Override
+	public void start(StartContext context) throws StartException {
+		this.cache.setBufferManager(this.bufferMgrInjector.getValue().getBufferManager());
+	}
+
+	@Override
+	public void stop(StopContext context) {
+	}
+
+	@Override
+	public SessionAwareCache<T> getValue() throws IllegalStateException, IllegalArgumentException {
+		return this.cache;
+	}
+}


Property changes on: trunk/jboss-integration/src/main/java/org/teiid/jboss/CacheService.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Modified: trunk/jboss-integration/src/main/java/org/teiid/jboss/Element.java
===================================================================
--- trunk/jboss-integration/src/main/java/org/teiid/jboss/Element.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/src/main/java/org/teiid/jboss/Element.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -196,7 +196,7 @@
 		node.get(type, name, TYPE).set(this.modelType);
         node.get(type, name, DESCRIPTION).set(getDescription(bundle));
         node.get(type, name, REQUIRED).set(this.required);
-        node.get(type, name, MAX_OCCURS).set(1);
+        //node.get(type, name, MAX_OCCURS).set(1);
         
         if (this.defaultValue != null) {
         	if (ModelType.INT == this.modelType) {

Modified: trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidAdd.java
===================================================================
--- trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidAdd.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidAdd.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -22,7 +22,10 @@
 
 package org.teiid.jboss;
 
-import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.*;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.ADD;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.DESCRIPTION;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.OPERATION_NAME;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.REQUEST_PROPERTIES;
 
 import java.util.List;
 import java.util.Locale;
@@ -49,19 +52,18 @@
 import org.jboss.modules.ModuleIdentifier;
 import org.jboss.modules.ModuleLoadException;
 import org.jboss.msc.service.ServiceBuilder;
+import org.jboss.msc.service.ServiceBuilder.DependencyType;
 import org.jboss.msc.service.ServiceContainer;
 import org.jboss.msc.service.ServiceController;
 import org.jboss.msc.service.ServiceName;
 import org.jboss.msc.service.ServiceTarget;
 import org.jboss.msc.service.ValueService;
-import org.jboss.msc.service.ServiceBuilder.DependencyType;
 import org.jboss.msc.value.InjectedValue;
 import org.teiid.PolicyDecider;
 import org.teiid.cache.CacheConfiguration;
-import org.teiid.cache.DefaultCacheFactory;
 import org.teiid.cache.CacheConfiguration.Policy;
+import org.teiid.cache.DefaultCacheFactory;
 import org.teiid.cache.jboss.ClusterableCacheFactory;
-import org.teiid.common.buffer.BufferManager;
 import org.teiid.deployers.SystemVDBDeployer;
 import org.teiid.deployers.VDBRepository;
 import org.teiid.deployers.VDBStatusChecker;
@@ -164,7 +166,12 @@
             final ServiceVerificationHandler verificationHandler, final List<ServiceController<?>> newControllers) throws OperationFailedException {
 		ClassLoader classloader = Thread.currentThread().getContextClassLoader();
 		try {
-			Thread.currentThread().setContextClassLoader(Module.getCallerModule().getClassLoader());
+			try {
+				classloader = Module.getCallerModule().getClassLoader();
+			} catch(Throwable t) {
+				//ignore..
+			}
+			Thread.currentThread().setContextClassLoader(classloader);
 			initilaizeTeiidEngine(context, operation, newControllers);
 		} finally {
 			Thread.currentThread().setContextClassLoader(classloader);
@@ -198,7 +205,7 @@
 		else {
 			systemFunctionManager.setAllowEnvFunction(false);
 		}
-		systemFunctionManager.setClassloader(Module.getCallerModule().getClassLoader()); 
+		systemFunctionManager.setClassloader(Thread.currentThread().getContextClassLoader()); 
     	
     	// VDB repository
     	final VDBRepository vdbRepository = new VDBRepository();
@@ -232,7 +239,6 @@
     	newControllers.add(objectSerializerService.install());
     	
     	// Object Replicator
-    	JGroupsObjectReplicatorService replicatorService = null;
     	if (Element.OR_STACK_ATTRIBUTE.isDefined(operation)) {
     		String stack = Element.OR_STACK_ATTRIBUTE.asString(operation);
     		
@@ -241,7 +247,7 @@
     			clusterName = Element.OR_CLUSTER_NAME_ATTRIBUTE.asString(operation);
     		}
     		
-    		replicatorService = new JGroupsObjectReplicatorService(clusterName);
+    		JGroupsObjectReplicatorService replicatorService = new JGroupsObjectReplicatorService(clusterName);
 			ServiceBuilder<JGroupsObjectReplicator> serviceBuilder = target.addService(TeiidServiceNames.OBJECT_REPLICATOR, replicatorService);
 			serviceBuilder.addDependency(ServiceName.JBOSS.append("jgroups", "stack", stack), ChannelFactory.class, replicatorService.channelFactoryInjector); //$NON-NLS-1$ //$NON-NLS-2$
 			newControllers.add(serviceBuilder.install());
@@ -249,10 +255,10 @@
 
     	// TODO: remove verbose service by moving the buffer service from runtime project
     	newControllers.add(RelativePathService.addService(TeiidServiceNames.BUFFER_DIR, "teiid-buffer", "jboss.server.temp.dir", target)); //$NON-NLS-1$ //$NON-NLS-2$
-    	BufferManagerService bufferService = new BufferManagerService(buildBufferManager(operation), replicatorService.getValue());
+    	BufferManagerService bufferService = new BufferManagerService(buildBufferManager(operation));
     	ServiceBuilder<BufferService> bufferServiceBuilder = target.addService(TeiidServiceNames.BUFFER_MGR, bufferService);
     	bufferServiceBuilder.addDependency(TeiidServiceNames.BUFFER_DIR, String.class, bufferService.pathInjector);
-    	bufferServiceBuilder.addDependency(TeiidServiceNames.BUFFER_DIR, String.class, bufferService.pathInjector);
+    	bufferServiceBuilder.addDependency(DependencyType.OPTIONAL, TeiidServiceNames.OBJECT_REPLICATOR, ObjectReplicator.class, bufferService.replicatorInjector);
     	newControllers.add(bufferServiceBuilder.install());
     	
     	PolicyDecider policyDecider;
@@ -287,24 +293,18 @@
     	newControllers.add(target.addService(TeiidServiceNames.AUTHORIZATION_VALIDATOR, authValidatorService).install());
     	
     	// resultset cache
-    	final SessionAwareCache<CachedResults> resultsetCache = buildResultsetCache(operation, bufferService.getValue().getBufferManager());
-    	ValueService<SessionAwareCache<CachedResults>> resultSetService = new ValueService<SessionAwareCache<CachedResults>>(new org.jboss.msc.value.Value<SessionAwareCache<CachedResults>>() {
-			@Override
-			public SessionAwareCache<CachedResults> getValue() throws IllegalStateException, IllegalArgumentException {
-				return resultsetCache;
-			}
-    	});
-    	newControllers.add(target.addService(TeiidServiceNames.CACHE_RESULTSET, resultSetService).install());
+    	final SessionAwareCache<CachedResults> resultsetCache = buildResultsetCache(operation);
+    	CacheService<CachedResults> resultSetService = new CacheService<CachedResults>(resultsetCache);
+    	ServiceBuilder<SessionAwareCache<CachedResults>> resultsCacheBuilder = target.addService(TeiidServiceNames.CACHE_RESULTSET, resultSetService);
+    	resultsCacheBuilder.addDependency(TeiidServiceNames.BUFFER_MGR, BufferService.class, resultSetService.bufferMgrInjector);
+    	newControllers.add(resultsCacheBuilder.install());
     	
     	// prepared-plan cache
-    	final SessionAwareCache<PreparedPlan> preparedPlanCache = buildPreparedPlanCache(operation, bufferService.getValue().getBufferManager());
-    	ValueService<SessionAwareCache<PreparedPlan>> preparedPlanService = new ValueService<SessionAwareCache<PreparedPlan>>(new org.jboss.msc.value.Value<SessionAwareCache<PreparedPlan>>() {
-			@Override
-			public SessionAwareCache<PreparedPlan> getValue() throws IllegalStateException, IllegalArgumentException {
-				return preparedPlanCache;
-			}
-    	});
-    	newControllers.add(target.addService(TeiidServiceNames.CACHE_PREPAREDPLAN, preparedPlanService).install());
+    	final SessionAwareCache<PreparedPlan> preparedPlanCache = buildPreparedPlanCache(operation);
+    	CacheService<PreparedPlan> preparedPlanService = new CacheService<PreparedPlan>(preparedPlanCache);
+    	ServiceBuilder<SessionAwareCache<PreparedPlan>> preparedPlanCacheBuilder = target.addService(TeiidServiceNames.CACHE_PREPAREDPLAN, preparedPlanService);
+    	preparedPlanCacheBuilder.addDependency(TeiidServiceNames.BUFFER_MGR, BufferService.class, preparedPlanService.bufferMgrInjector);
+    	newControllers.add(preparedPlanCacheBuilder.install());
     	
     	// Query Engine
     	final RuntimeEngineDeployer engine = buildQueryEngine(operation);
@@ -413,7 +413,7 @@
     	return bufferManger;
     }	
 
-    private SessionAwareCache<CachedResults> buildResultsetCache(ModelNode node, BufferManager bufferManager) {
+    private SessionAwareCache<CachedResults> buildResultsetCache(ModelNode node) {
 
     	CacheConfiguration cacheConfig = new CacheConfiguration();
     	cacheConfig.setMaxEntries(1024);
@@ -436,7 +436,6 @@
     	}
     	else {
     		SessionAwareCache<CachedResults> resultsetCache = new SessionAwareCache<CachedResults>(new DefaultCacheFactory(), SessionAwareCache.Type.RESULTSET, cacheConfig);
-        	resultsetCache.setBufferManager(bufferManager);
         	return resultsetCache;    		
     	}
     	
@@ -452,12 +451,11 @@
     	}
 
    		SessionAwareCache<CachedResults> resultsetCache = new SessionAwareCache<CachedResults>(cacheFactory, SessionAwareCache.Type.RESULTSET, cacheConfig);
-    	resultsetCache.setBufferManager(bufferManager);
     	return resultsetCache;
 	}	      
     
     
-    private SessionAwareCache<PreparedPlan> buildPreparedPlanCache(ModelNode node, BufferManager bufferManager) {
+    private SessionAwareCache<PreparedPlan> buildPreparedPlanCache(ModelNode node) {
     	CacheConfiguration cacheConfig = new CacheConfiguration();
     	if (Element.PPC_MAX_ENTRIES_ATTRIBUTE.isDefined(node)) {
     		cacheConfig.setMaxEntries(Element.PPC_MAX_ENTRIES_ATTRIBUTE.asInt(node));
@@ -477,7 +475,6 @@
     	
     	cacheConfig.setLocation("prepared"); //$NON-NLS-1$
     	SessionAwareCache<PreparedPlan> cache = new SessionAwareCache<PreparedPlan>(new DefaultCacheFactory(), SessionAwareCache.Type.PREPAREDPLAN, cacheConfig);
-    	cache.setBufferManager(bufferManager);
     	
     	return cache;
 	}	    

Modified: trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidExtension.java
===================================================================
--- trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidExtension.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidExtension.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -23,11 +23,10 @@
 
 import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.ADD;
 import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.ATTRIBUTES;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.CHILDREN;
 import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.DESCRIBE;
 import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.DESCRIPTION;
-import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.HEAD_COMMENT_ALLOWED;
 import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.REMOVE;
-import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.TAIL_COMMENT_ALLOWED;
 
 import java.util.Locale;
 import java.util.ResourceBundle;
@@ -37,6 +36,7 @@
 import org.jboss.as.controller.PathElement;
 import org.jboss.as.controller.SubsystemRegistration;
 import org.jboss.as.controller.descriptions.DescriptionProvider;
+import org.jboss.as.controller.descriptions.ModelDescriptionConstants;
 import org.jboss.as.controller.parsing.ExtensionParsingContext;
 import org.jboss.as.controller.registry.AttributeAccess.Storage;
 import org.jboss.as.controller.registry.ManagementResourceRegistration;
@@ -67,7 +67,19 @@
 
 		// Main Teiid system, with children query engine and translators.
 		
-		final ManagementResourceRegistration teiidSubsystem = registration.registerSubsystemModel(TEIID_DESCRIBE);
+		final ManagementResourceRegistration teiidSubsystem = registration.registerSubsystemModel(new DescriptionProvider() {
+			@Override
+			public ModelNode getModelDescription(Locale locale) {
+				final ResourceBundle bundle = IntegrationPlugin.getResourceBundle(locale);
+		        ModelNode node = new ModelNode();
+		        node.get(ModelDescriptionConstants.DESCRIPTION).set("teiid subsystem"); //$NON-NLS-1$
+		        
+		        TeiidAdd.describeTeiid(node, ATTRIBUTES, bundle);
+		        node.get(CHILDREN, Element.TRANSPORT_ELEMENT.getLocalName(), DESCRIPTION).set(Element.TRANSPORT_ELEMENT.getDescription(bundle)); 
+		        node.get(CHILDREN, Element.TRANSLATOR_ELEMENT.getLocalName(), DESCRIPTION).set(Element.TRANSLATOR_ELEMENT.getDescription(bundle));
+		        return node;
+			}
+		});
 		teiidSubsystem.registerOperationHandler(ADD, TEIID_BOOT_ADD, TEIID_BOOT_ADD, false);
 		teiidSubsystem.registerOperationHandler(DESCRIBE, TEIID_DESCRIBE, TEIID_DESCRIBE, false);     
 				
@@ -79,8 +91,6 @@
 
 				final ModelNode node = new ModelNode();
 	            node.get(DESCRIPTION).set(Element.TRANSLATOR_ELEMENT.getDescription(bundle));
-	            node.get(HEAD_COMMENT_ALLOWED).set(true);
-	            node.get(TAIL_COMMENT_ALLOWED).set(true);
 	            Element.TRANSLATOR_MODULE_ATTRIBUTE.describe(node, ATTRIBUTES, bundle);
 	            return node;
 			}
@@ -97,11 +107,7 @@
 				
 				final ModelNode node = new ModelNode();
 	            node.get(DESCRIPTION).set(Element.TRANSPORT_ELEMENT.getDescription(bundle));
-	            node.get(HEAD_COMMENT_ALLOWED).set(true);
-	            node.get(TAIL_COMMENT_ALLOWED).set(true);
-	            
 	            TransportAdd.transportDescribe(node, ATTRIBUTES, bundle);
-	            
 	            return node;
 			}
 		});

Modified: trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidOperationHandler.java
===================================================================
--- trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidOperationHandler.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidOperationHandler.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -21,7 +21,15 @@
  */
 package org.teiid.jboss;
 
-import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.*;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.ALLOWED;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.DEFAULT;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.DESCRIPTION;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.READ_ONLY;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.REPLY_PROPERTIES;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.REQUEST_PROPERTIES;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.REQUIRED;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.TYPE;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.VALUE_TYPE;
 
 import java.io.IOException;
 import java.math.BigDecimal;
@@ -130,7 +138,8 @@
 		context.getResult().set(engine.getRuntimeVersion());
 	}
 	protected void describeParameters(ModelNode operationNode, ResourceBundle bundle) {
-		operationNode.get(REPLY_PROPERTIES).set(ModelType.STRING);
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.STRING);		
 	}	
 }
 
@@ -145,13 +154,14 @@
 			for (Transport t: this.transports) {
 				count += t.getActiveSessionsCount();
 			}
-			context.getResult().set(String.valueOf(count));
+			context.getResult().set(count);
 		} catch (AdminException e) {
 			throw new OperationFailedException(new ModelNode().set(e.getMessage()));
 		}
 	}
 	protected void describeParameters(ModelNode operationNode, ResourceBundle bundle) {
-		operationNode.get(REPLY_PROPERTIES).set(ModelType.INT);
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.INT);		
 	}		
 }
 
@@ -171,7 +181,9 @@
 	}
 	
 	protected void describeParameters(ModelNode operationNode, ResourceBundle bundle) {
-		operationNode.get(REPLY_PROPERTIES).add(VDBMetadataMapper.SessionMetadataMapper.INSTANCE.describe(new ModelNode()));
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.LIST);		
+		VDBMetadataMapper.SessionMetadataMapper.INSTANCE.describe(reply.get(VALUE_TYPE));
 	}	
 }
 
@@ -196,7 +208,9 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.SESSION, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.SESSION, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.SESSION));
 		
-		operationNode.get(REPLY_PROPERTIES).add(VDBMetadataMapper.RequestMetadataMapper.INSTANCE.describe(new ModelNode()));
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.LIST);		
+		VDBMetadataMapper.RequestMetadataMapper.INSTANCE.describe(reply.get(VALUE_TYPE));
 	}	
 }
 
@@ -213,7 +227,9 @@
 		}
 	}
 	protected void describeParameters(ModelNode operationNode, ResourceBundle bundle) {
-		operationNode.get(REPLY_PROPERTIES).add(VDBMetadataMapper.RequestMetadataMapper.INSTANCE.describe(new ModelNode()));
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.LIST);		
+		VDBMetadataMapper.RequestMetadataMapper.INSTANCE.describe(reply.get(VALUE_TYPE));
 	}	
 }
 
@@ -250,7 +266,9 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.VDB_VERSION, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.VDB_VERSION, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.VDB_VERSION)); 
 		
-		operationNode.get(REPLY_PROPERTIES).add(VDBMetadataMapper.RequestMetadataMapper.INSTANCE.describe(new ModelNode()));
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.LIST);		
+		VDBMetadataMapper.RequestMetadataMapper.INSTANCE.describe(reply.get(VALUE_TYPE));
 	}	
 }
 
@@ -267,7 +285,9 @@
 		}
 	}
 	protected void describeParameters(ModelNode operationNode, ResourceBundle bundle) {
-		operationNode.get(REPLY_PROPERTIES).add(VDBMetadataMapper.RequestMetadataMapper.INSTANCE.describe(new ModelNode()));
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.LIST);		
+		VDBMetadataMapper.RequestMetadataMapper.INSTANCE.describe(reply.get(VALUE_TYPE));
 	}	
 }
 
@@ -289,6 +309,7 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.SESSION, TYPE).set(ModelType.STRING);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.SESSION, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.SESSION, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.SESSION));
+		operationNode.get(REPLY_PROPERTIES).setEmptyObject();
 	}		
 }
 
@@ -307,6 +328,7 @@
 			}			
 			boolean pass = engine.cancelRequest(operation.get(OperationsConstants.SESSION).asString(), operation.get(OperationsConstants.EXECUTION_ID).asLong());
 			ModelNode result = context.getResult();
+			
 			result.set(pass);
 		} catch (TeiidComponentException e) {
 			throw new OperationFailedException(e, new ModelNode().set(e.getMessage()));
@@ -322,7 +344,7 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.EXECUTION_ID, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.EXECUTION_ID, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.EXECUTION_ID));
 		
-		operationNode.get(REPLY_PROPERTIES).set(ModelType.BOOLEAN);
+		operationNode.get(REPLY_PROPERTIES).get(TYPE).set(ModelType.BOOLEAN);
 	}		
 }
 
@@ -368,11 +390,12 @@
 	}
 	
 	protected void describeParameters(ModelNode operationNode, ResourceBundle bundle) {
-		ModelNode node = new ModelNode();
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.LIST);		
+		
+		ModelNode node = reply.get(VALUE_TYPE);
 		node.get(OperationsConstants.CACHE_TYPE, TYPE).set(ModelType.STRING);
-		node.get(OperationsConstants.CACHE_TYPE, REQUIRED).set(true);
 		node.get(OperationsConstants.CACHE_TYPE, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.CACHE_TYPE));
-		operationNode.get(REPLY_PROPERTIES).add(node);
 	}	
 }
 
@@ -413,7 +436,7 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.VDB_VERSION, TYPE).set(ModelType.INT);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.VDB_VERSION, REQUIRED).set(false);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.VDB_VERSION, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.VDB_VERSION)); 
-		
+		operationNode.get(REPLY_PROPERTIES).setEmptyObject();
 	}	
 }
 
@@ -448,8 +471,9 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.CACHE_TYPE, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.CACHE_TYPE, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.CACHE_TYPE));
 		
-		ModelNode node = new ModelNode();
-		operationNode.get(REPLY_PROPERTIES).add(VDBMetadataMapper.CacheStatisticsMetadataMapper.INSTANCE.describe(node));
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.OBJECT);		
+		VDBMetadataMapper.CacheStatisticsMetadataMapper.INSTANCE.describe(reply.get(VALUE_TYPE));
 	}	
 }
 
@@ -473,6 +497,7 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.DS_NAME, TYPE).set(ModelType.STRING);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.DS_NAME, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.DS_NAME, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.DS_NAME));
+		operationNode.get(REPLY_PROPERTIES).setEmptyObject();
 	}	
 }
 
@@ -488,7 +513,9 @@
 		VDBMetadataMapper.WorkerPoolStatisticsMetadataMapper.INSTANCE.wrap(stats, result);
 	}
 	protected void describeParameters(ModelNode operationNode, ResourceBundle bundle) {
-		operationNode.get(REPLY_PROPERTIES).add(VDBMetadataMapper.WorkerPoolStatisticsMetadataMapper.INSTANCE.describe(new ModelNode()));
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.OBJECT);		
+		VDBMetadataMapper.WorkerPoolStatisticsMetadataMapper.INSTANCE.describe(reply.get(VALUE_TYPE));
 	}		
 }
 
@@ -506,8 +533,9 @@
 		}
 	}
 	protected void describeParameters(ModelNode operationNode, ResourceBundle bundle) {
-		ModelNode node = new ModelNode();
-		operationNode.get(REPLY_PROPERTIES).add(TransactionMetadataMapper.INSTANCE.describe(node));
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.LIST);		
+		TransactionMetadataMapper.INSTANCE.describe(reply.get(VALUE_TYPE));
 	}	
 }
 
@@ -535,6 +563,7 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.XID, TYPE).set(ModelType.STRING);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.XID, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.XID, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.XID));
+		operationNode.get(REPLY_PROPERTIES).setEmptyObject();
 	}	
 }
 
@@ -593,6 +622,7 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.TARGET_VDBVERSION, TYPE).set(ModelType.STRING);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.TARGET_VDBVERSION, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.TARGET_VDBVERSION, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.TARGET_VDBVERSION));
+		operationNode.get(REPLY_PROPERTIES).setEmptyObject();
 	}	
 }
 
@@ -643,7 +673,8 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.TIMEOUT_IN_MILLI, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.TIMEOUT_IN_MILLI, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.TIMEOUT_IN_MILLI));
 		
-		operationNode.get(REPLY_PROPERTIES).set(ModelType.LIST);
+		operationNode.get(REPLY_PROPERTIES).get(TYPE).set(ModelType.LIST);
+		operationNode.get(REPLY_PROPERTIES).get(VALUE_TYPE).set(ModelType.STRING);
 	}	
 	
 	public ModelNode executeQuery(final String vdbName, final int version, final String command, final long timoutInMilli, final ModelNode resultsNode) throws OperationFailedException {
@@ -812,7 +843,9 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.VDB_VERSION, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.VDB_VERSION, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.VDB_VERSION));
 
-		operationNode.get(REPLY_PROPERTIES).set(VDBMetadataMapper.INSTANCE.describe(new ModelNode()));
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.OBJECT);		
+		VDBMetadataMapper.INSTANCE.describe(reply.get(VALUE_TYPE));
 	}	
 }
 
@@ -837,7 +870,9 @@
 		}
 	}
 	protected void describeParameters(ModelNode operationNode, ResourceBundle bundle) {
-		operationNode.get(REPLY_PROPERTIES).add(VDBMetadataMapper.INSTANCE.describe(new ModelNode()));
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.LIST);		
+		VDBMetadataMapper.INSTANCE.describe(reply.get(VALUE_TYPE));
 	}	
 }
 
@@ -857,7 +892,9 @@
 	}
 	
 	protected void describeParameters(ModelNode operationNode, ResourceBundle bundle) {
-		operationNode.get(REPLY_PROPERTIES).add(VDBMetadataMapper.VDBTranslatorMetaDataMapper.INSTANCE.describe(new ModelNode()));
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.LIST);		
+		VDBMetadataMapper.VDBTranslatorMetaDataMapper.INSTANCE.describe(reply.get(VALUE_TYPE));
 	}	
 }
 
@@ -885,7 +922,9 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.TRANSLATOR_NAME, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.TRANSLATOR_NAME, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.TRANSLATOR_NAME));
 		
-		operationNode.get(REPLY_PROPERTIES).set(VDBTranslatorMetaDataMapper.INSTANCE.describe(new ModelNode()));
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.OBJECT);		
+		VDBTranslatorMetaDataMapper.INSTANCE.describe(reply.get(VALUE_TYPE));
 	}	
 }
 
@@ -981,6 +1020,7 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.MAPPED_ROLE, TYPE).set(ModelType.STRING);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.MAPPED_ROLE, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.MAPPED_ROLE, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.MAPPED_ROLE));
+		operationNode.get(REPLY_PROPERTIES).setEmptyObject();
 	}		
 }
 
@@ -1028,6 +1068,7 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.MAPPED_ROLE, TYPE).set(ModelType.STRING);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.MAPPED_ROLE, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.MAPPED_ROLE, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.MAPPED_ROLE));
+		operationNode.get(REPLY_PROPERTIES).setEmptyObject();
 	}		
 }
 
@@ -1066,6 +1107,7 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.DATA_ROLE, TYPE).set(ModelType.STRING);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.DATA_ROLE, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.DATA_ROLE, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.DATA_ROLE));
+		operationNode.get(REPLY_PROPERTIES).setEmptyObject();
 	}		
 	
 }
@@ -1105,6 +1147,7 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.DATA_ROLE, TYPE).set(ModelType.STRING);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.DATA_ROLE, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.DATA_ROLE, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.DATA_ROLE));
+		operationNode.get(REPLY_PROPERTIES).setEmptyObject();
 	}			
 }
 
@@ -1136,6 +1179,7 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.CONNECTION_TYPE, TYPE).set(ModelType.STRING);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.CONNECTION_TYPE, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.CONNECTION_TYPE, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.CONNECTION_TYPE));
+		operationNode.get(REPLY_PROPERTIES).setEmptyObject();
 	}		
 }
 
@@ -1211,7 +1255,7 @@
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.DS_NAME, TYPE).set(ModelType.STRING);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.DS_NAME, REQUIRED).set(true);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.DS_NAME, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.DS_NAME));
-		
+		operationNode.get(REPLY_PROPERTIES).setEmptyObject();
 	}		
 }
 
@@ -1301,6 +1345,11 @@
 	protected void describeParameters(ModelNode operationNode, ResourceBundle bundle) {
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.RAR_NAME, TYPE).set(ModelType.STRING);
 		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.RAR_NAME, REQUIRED).set(true);
-		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.RAR_NAME, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.RAR_NAME));		
+		operationNode.get(REQUEST_PROPERTIES, OperationsConstants.RAR_NAME, DESCRIPTION).set(getParameterDescription(bundle, OperationsConstants.RAR_NAME));
+		
+		ModelNode reply = operationNode.get(REPLY_PROPERTIES);
+		reply.get(TYPE).set(ModelType.LIST);	
+		// this is incomplete
+		reply.get(VALUE_TYPE).set(ModelType.STRING);		
 	}		
 }
\ No newline at end of file

Modified: trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidSubsystemDescribe.java
===================================================================
--- trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidSubsystemDescribe.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/src/main/java/org/teiid/jboss/TeiidSubsystemDescribe.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -22,7 +22,14 @@
 
 package org.teiid.jboss;
 
-import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.*;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.ADD;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.DESCRIBE;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.OP;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.OPERATION_NAME;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.OP_ADDR;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.REPLY_PROPERTIES;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.TYPE;
+import static org.jboss.as.controller.descriptions.ModelDescriptionConstants.VALUE_TYPE;
 
 import java.util.Locale;
 import java.util.ResourceBundle;
@@ -35,8 +42,12 @@
 import org.jboss.as.controller.descriptions.ModelDescriptionConstants;
 import org.jboss.as.controller.registry.Resource;
 import org.jboss.dmr.ModelNode;
+import org.jboss.dmr.ModelType;
 import org.jboss.dmr.Property;
 
+/**
+ * This is class that satisfies "describe" operation.
+ */
 public class TeiidSubsystemDescribe implements OperationStepHandler, DescriptionProvider {
 
 	@Override
@@ -44,18 +55,10 @@
 		final ResourceBundle bundle = IntegrationPlugin.getResourceBundle(locale);
 		
         ModelNode node = new ModelNode();
-        node.get(ModelDescriptionConstants.DESCRIPTION).set("teiid subsystem"); //$NON-NLS-1$
-        node.get(ModelDescriptionConstants.HEAD_COMMENT_ALLOWED).set(true);
-        node.get(ModelDescriptionConstants.TAIL_COMMENT_ALLOWED).set(true);
-        node.get(ModelDescriptionConstants.NAMESPACE).set(Namespace.CURRENT.getUri());
-        
-        TeiidAdd.describeTeiid(node, ATTRIBUTES, bundle);
-        node.get(CHILDREN, Element.TRANSPORT_ELEMENT.getLocalName(), DESCRIPTION).set(Element.TRANSPORT_ELEMENT.getDescription(bundle)); 
-        node.get(CHILDREN, Element.TRANSPORT_ELEMENT.getLocalName(), REQUIRED).set(true);
-        
-        node.get(CHILDREN, Element.TRANSLATOR_ELEMENT.getLocalName(), DESCRIPTION).set(Element.TRANSLATOR_ELEMENT.getDescription(bundle));
-        node.get(CHILDREN, Element.TRANSLATOR_ELEMENT.getLocalName(), REQUIRED).set(true);
-
+        node.get(OPERATION_NAME).set(DESCRIBE);
+        node.get(ModelDescriptionConstants.DESCRIPTION).set(bundle.getString("teiid_subsystem.describe")); //$NON-NLS-1$
+        node.get(REPLY_PROPERTIES).get(TYPE).set(ModelType.LIST);
+        TeiidAdd.describeTeiid(node.get(REPLY_PROPERTIES), VALUE_TYPE, bundle);
         return node;
     }
 

Modified: trunk/jboss-integration/src/main/java/org/teiid/jboss/TranslatorAdd.java
===================================================================
--- trunk/jboss-integration/src/main/java/org/teiid/jboss/TranslatorAdd.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/src/main/java/org/teiid/jboss/TranslatorAdd.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -42,6 +42,7 @@
 import org.jboss.modules.Module;
 import org.jboss.modules.ModuleIdentifier;
 import org.jboss.modules.ModuleLoadException;
+import org.jboss.modules.ModuleLoader;
 import org.jboss.msc.service.ServiceBuilder;
 import org.jboss.msc.service.ServiceController;
 import org.jboss.msc.service.ServiceTarget;
@@ -93,10 +94,11 @@
 
         final Module module;
         ClassLoader translatorLoader = this.getClass().getClassLoader();
-        if (moduleName != null) {
+        ModuleLoader ml = Module.getCallerModuleLoader();
+        if (moduleName != null && ml != null) {
 	        try {
-	            module = Module.getCallerModuleLoader().loadModule(ModuleIdentifier.create(moduleName));
-	            translatorLoader = module.getClassLoader();
+            	module = ml.loadModule(ModuleIdentifier.create(moduleName));
+            	translatorLoader = module.getClassLoader();
 	        } catch (ModuleLoadException e) {
 	            throw new OperationFailedException(e, new ModelNode().set(IntegrationPlugin.Util.getString("failed_load_module", moduleName, translatorName))); //$NON-NLS-1$
 	        }

Modified: trunk/jboss-integration/src/main/java/org/teiid/jboss/TransportAdd.java
===================================================================
--- trunk/jboss-integration/src/main/java/org/teiid/jboss/TransportAdd.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/src/main/java/org/teiid/jboss/TransportAdd.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -65,7 +65,7 @@
 import org.teiid.transport.SSLConfiguration;
 import org.teiid.transport.SocketConfiguration;
 
-public class TransportAdd extends AbstractAddStepHandler implements DescriptionProvider {
+class TransportAdd extends AbstractAddStepHandler implements DescriptionProvider {
 
 	private static Element[] attributes = {
 		Element.TRANSPORT_PROTOCOL_ATTRIBUTE,
@@ -189,7 +189,7 @@
     	
         // add security domains
         for (String domain:domainList) {
-        	LogManager.logInfo(LogConstants.CTX_SECURITY, IntegrationPlugin.Util.getString("security_enabled", domain)); //$NON-NLS-1$
+        	LogManager.logInfo(LogConstants.CTX_SECURITY, IntegrationPlugin.Util.getString("security_enabled", domain, transportName)); //$NON-NLS-1$
         	transportBuilder.addDependency(ServiceName.JBOSS.append("security", "security-domain", domain), SecurityDomainContext.class, new ConcurrentMapInjector<String,SecurityDomainContext>(transport.securityDomains, domain)); //$NON-NLS-1$ //$NON-NLS-2$
         }
         

Modified: trunk/jboss-integration/src/main/java/org/teiid/jboss/deployers/RuntimeEngineDeployer.java
===================================================================
--- trunk/jboss-integration/src/main/java/org/teiid/jboss/deployers/RuntimeEngineDeployer.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/src/main/java/org/teiid/jboss/deployers/RuntimeEngineDeployer.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -35,7 +35,6 @@
 import javax.resource.spi.work.WorkManager;
 import javax.transaction.TransactionManager;
 
-import org.jboss.modules.Module;
 import org.jboss.msc.service.Service;
 import org.jboss.msc.service.ServiceController;
 import org.jboss.msc.service.ServiceName;
@@ -114,7 +113,7 @@
 		
 		setBufferService(bufferServiceInjector.getValue());
 		
-		dqpCore.setTransactionService((TransactionService)LogManager.createLoggingProxy(LogConstants.CTX_TXN_LOG, transactionServerImpl, new Class[] {TransactionService.class}, MessageLevel.DETAIL, Module.getCallerModule().getClassLoader()));
+		dqpCore.setTransactionService((TransactionService)LogManager.createLoggingProxy(LogConstants.CTX_TXN_LOG, transactionServerImpl, new Class[] {TransactionService.class}, MessageLevel.DETAIL, Thread.currentThread().getContextClassLoader()));
 
 		if (getObjectReplicatorInjector().getValue() != null) {
 			try {
@@ -132,7 +131,7 @@
 		this.dqpCore.setResultsetCache(getResultSetCacheInjector().getValue());
 		this.dqpCore.setPreparedPlanCache(getPreparedPlanCacheInjector().getValue());
 		this.dqpCore.start(this);
-		this.eventDistributorProxy = (EventDistributor)Proxy.newProxyInstance(Module.getCallerModule().getClassLoader(), new Class[] {EventDistributor.class}, new InvocationHandler() {
+		this.eventDistributorProxy = (EventDistributor)Proxy.newProxyInstance(Thread.currentThread().getContextClassLoader(), new Class[] {EventDistributor.class}, new InvocationHandler() {
 			
 			@Override
 			public Object invoke(Object proxy, Method method, Object[] args)

Modified: trunk/jboss-integration/src/main/resources/org/teiid/jboss/i18n.properties
===================================================================
--- trunk/jboss-integration/src/main/resources/org/teiid/jboss/i18n.properties	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/src/main/resources/org/teiid/jboss/i18n.properties	2011-12-01 18:19:11 UTC (rev 3714)
@@ -58,7 +58,7 @@
 translator.add=Add Translator
 translator.remove=Remove Translator
 protocol_not_found=protocol is not defined for the transport configuration.
-security_enabled=Security Enabled: {0}
+security_enabled=Security enabled for transport "{1}" with security-domain set to {0}
 DQPCore.unable_to_process_event=Unable to process event.
 translator.added = Teiid translator "{0}" added.
 wrong_protocol=Wrong type of protocol supplied
@@ -204,19 +204,22 @@
 model-name.missing=Parameter "model-name" is required
 connection-type.missing = Parameter "connection-type" is required. Must be one of [NONE, BY_VERSION, ANY]
 rar-name.missing=Parameter "rar-name" is is required.
+vdb-description.describe=vdb description
+teiid_subsystem.describe=describe the teiid subsystem
 
-
 # Operation descriptions (alpha layout)
 add-anyauthenticated-role.describe=Mark any authenticated to the datarole
 add-anyauthenticated-role.vdb-name.describe=VDB Name
 add-anyauthenticated-role.vdb-version.describe=VDB Version
 add-anyauthenticated-role.data-role.describe=VDB Defined Data Role Name
+add-anyauthenticated-role.reply=void
 
 add-data-role.describe= Map a JAAS based role to the VDB data role, for granting permission
 add-data-role.vdb-name.describe=VDB Name
 add-data-role.vdb-version.describe=VDB Version
 add-data-role.data-role.describe=VDB Defined Data Role Name
 add-data-role.mapped-role.describe=Security domain defined role name
+add-data-role.reply=void
 
 assign-datasource.describe=Assign a data source or translator names to a given model in the VDB
 assign-datasource.vdb-name.describe=VDB Name
@@ -225,91 +228,119 @@
 assign-datasource.ds-name.describe=Data source name
 assign-datasource.translator-name.describe=translator name
 assign-datasource.model-name.describe=Model Name
+assign-datasource.reply=void
 
 cache-statistics.describe=Get the cache statistics for the given cache type
 cache-statistics.cache-type.describe=cache type (PREPARED_PLAN_CACHE, QUERY_SERVICE_RESULT_SET_CACHE)
+cache-statistics.reply=cache statistics
 
 cache-types.describe=List the available cache types
+cache-types.cache-type.describe=Cache type
+cache-types.reply=list of cache types
 
 cancel-request.describe=Cancel the execution of the actively running query
 cancel-request.session.describe=The session Identifier of the user
 cancel-request.execution-id.describe=The Execution Identifier of the query
-cancel-request.reply.describe=True if successful; false otherwise.
+cancel-request.reply=True if successful; false otherwise.
 
 change-vdb-connection-type.describe=Change the default VDB version selection 
 change-vdb-connection-type.vdb-name.describe=VDB Name
 change-vdb-connection-type.vdb-version.describe=VDB Version
 change-vdb-connection-type.connection-type.describe=VDB Connection Type
+change-vdb-connection-type.reply=void
 
 clear-cache.describe=Clear the caches in the system of the given type
 clear-cache.cache-type.describe=cache type to be cleared. (PREPARED_PLAN_CACHE, QUERY_SERVICE_RESULT_SET_CACHE)
 clear-cache.vdb-name.describe=VDB name
 clear-cache.vdb-version.describe=VDB version
+clear-cache.reply=void
 
 execute-query.describe=Execute a sql query
 execute-query.vdb-name.describe=vdb name
 execute-query.vdb-version.describe=vdb version
 execute-query.sql-query.describe=sql query to execute
 execute-query.timeout-in-milli.describe=timeout
+execute-query.reply=list of rows
 
 active-session-count.describe=Number of active sessions
-active-session-count.reply.describe=Returns the count of active sessions
+active-session-count.reply=Returns the count of active sessions
 
 long-running-queries.describe=Long running queries that exceeded the threshold set by the 'query-threshold-in-seconds' configuration property.
+long-running-queries.reply=long running queries
 
 runtime-version.describe = Runtime version of the Teiid subsystem
-runtime-version.reply.describe=Teiid runtime version
+runtime-version.reply=Teiid runtime version
 
 get-translator.describe=retrieve translator
 get-translator.translator-name.describe=translator name
 get-translator.reply.describe=Returns translator if found with given name
+get-translator.reply=translator
 
 get-vdb.describe=Get the VDB with the given name and version
 get-vdb.vdb-name.describe=name of the vdb
 get-vdb.vdb-version.describe=vdb version
+get-vdb.reply=vdb
 
 list-requests.describe=List of active requests
+list-requests.reply=list of requests
 
 list-sessions.describe=List of all the current active sessions in the Teiid subsystem.
+list-sessions.reply=list of sessions
 
 list-transactions.describe=Active Transactions in the Query Engine
+list-transactions.reply=list of transactions
 
 list-translators.describe=List of translators registered in the teiid container
 list-translators.reply.describe=List of translators registered in the teiid container
+list-translators.reply=list of translators
 
 list-vdbs.describe=List the available virtual databases in the system
+list-vdbs.reply=list of vdbs
 
 merge-vdbs.describe=Merge Two VDBs
 merge-vdbs.source-vdb-name.describe=Source VDB name
 merge-vdbs.source-vdb-version.describe=Source VDB version number
 merge-vdbs.target-vdb-name.describe=Target VDB name
 merge-vdbs.target-vdb-version.describe=Target VDB version number
+merge-vdbs.reply=void
 
 remove-anyauthenticated-role.describe=remove any authenticated from the data role provided
 remove-anyauthenticated-role.vdb-name.describe=VDB Name
 remove-anyauthenticated-role.vdb-version.describe=VDB Version
 remove-anyauthenticated-role.data-role.describe=VDB Defined Data Role Name
+remove-anyauthenticated-role.reply=void
 
 remove-data-role.describe=remove the JAAS based role mapping from VDB data role
 remove-data-role.vdb-name.describe=VDB Name
 remove-data-role.vdb-version.describe=VDB Version
 remove-data-role.data-role.describe=VDB Defined Data Role Name
 remove-data-role.mapped-role.describe=Security domain defined role name
+remove-data-role.reply=void
 
 requests-per-session.describe=Current active requests in progress in the query engine for a given session identifier
 requests-per-session.session.describe=The session Identifier
+requests-per-session.reply=requests for given session
 
 requests-per-vdb.describe=Current active requests in progress in the query engine for a given VDB name and its version.
 requests-per-vdb.vdb-name.describe=VDB Name
 requests-per-vdb.vdb-version.describe=VDB Version
+requests-per-vdb.reply=list of requests on the given vdb
 
 terminate-session.describe=Terminate the session
 terminate-session.session.describe=The session Identifier of session to be terminated
+terminate-session.reply=void
 
 terminate-transaction.describe=Terminate the XA transaction
 terminate-transaction.xid.describe=xid identifier of the XA transaction
+terminate-transaction.reply=void
 
 workerpool-statistics.describe=Get thread statistics worker pool
+workerpool-statistics.reply=Returns the worker pool statistics
 
 read-rar-description.describe=Describe the properties of the Resource Adapter
-read-rar-description.rar-name.describe=resource adapter name
\ No newline at end of file
+read-rar-description.rar-name.describe=resource adapter name
+read-rar-description.reply=returns all the attribute names and their properties
+
+mark-datasource-available.describe=Notify that the defined data source is now available
+mark-datasource-available.ds-name.describe=Data Source name
+mark-datasource-available.reply=void
\ No newline at end of file

Modified: trunk/jboss-integration/src/test/resources/teiid-model-config.txt
===================================================================
--- trunk/jboss-integration/src/test/resources/teiid-model-config.txt	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/src/test/resources/teiid-model-config.txt	2011-12-01 18:19:11 UTC (rev 3714)
@@ -3,245 +3,209 @@
         "type" => BOOLEAN,
         "description" => "Allow the execution of ENV function. (default false)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => false
     },
     "async-thread-pool" => {
         "type" => STRING,
         "description" => "Thread Pool to be used with Asynchronous operations in Teiid",
-        "required" => true,
-        "max-occurs" => 1
+        "required" => true
     },
     "max-threads" => {
         "type" => INT,
         "description" => "Process pool maximum thread count. (default 64)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 64
     },
     "max-active-plans" => {
         "type" => INT,
         "description" => "Max active plans (default 20).  Increase this value on highly concurrent systems - but ensure that the underlying pools can handle the increased load without timeouts.",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 20
     },
     "thread-count-for-source-concurrency" => {
         "type" => INT,
         "description" => "Max source query concurrency per user request (default 0).  0 indicates use the default calculated value based on max active plans and max threads - approximately 2*(max threads)/(max active plans).   ",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 0
     },
     "time-slice-in-millseconds" => {
         "type" => INT,
         "description" => "Query processor time slice, in milliseconds. (default 2000)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 2000
     },
     "max-row-fetch-size" => {
         "type" => INT,
         "description" => "Maximum allowed fetch size, set via JDBC. User requested value ignored above this value. (default 20480)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 20480
     },
     "lob-chunk-size-in-kb" => {
         "type" => INT,
         "description" => "The max lob chunk size in KB transferred each time when processing blobs, clobs (100KB default)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 100
     },
     "query-threshold-in-seconds" => {
         "type" => INT,
         "description" => "Long running query threshold, after which a alert can be generated by tooling if configured",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 600
     },
     "max-source-rows-allowed" => {
         "type" => INT,
         "description" => "Maximum rows allowed from a source query. -1 indicates no limit. (default -1)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => -1
     },
     "exception-on-max-source-rows" => {
         "type" => BOOLEAN,
         "description" => "Indicates if an exception should be thrown if the specified value for Maximum Source Rows is exceeded; only up to the maximum rows will be consumed. (default true)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => true
     },
     "detect-change-events" => {
         "type" => BOOLEAN,
         "description" => "Set to true for the engine to detect local change events. Should be disabled if using external change data capture tools. (default true)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => true
     },
     "query-timeout" => {
         "type" => LONG,
         "description" => "Set the default query timeout for all queries in milliseconds. 0 indicates no timeout.  Lesser timeout values may be set per VDB or by clients. (default 0)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 0L
     },
     "workmanager" => {
         "type" => STRING,
         "description" => "WorkManager name to use in processing. (default name is \"default\")",
         "required" => false,
-        "max-occurs" => 1,
         "default" => "default"
     },
     "authorization-validator-module" => {
         "type" => STRING,
         "description" => "Authorization Module; Implementation of org.teiid.dqp.internal.process.AuthorizationValidator class.",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     },
     "policy-decider-module" => {
         "type" => STRING,
         "description" => "Policy Module; Implementation of org.teiid.PolicyDecider class ",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     },
     "object-replicator-stack" => {
         "type" => STRING,
         "description" => "JGroups stack name for cache replication channel",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     },
     "object-replicator-cluster-name" => {
         "type" => STRING,
         "description" => "cache channel cluster name for cache replication",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     },
     "buffer-service-use-disk" => {
         "type" => BOOLEAN,
         "description" => "Use disk for buffer management",
         "required" => false,
-        "max-occurs" => 1,
         "default" => true
     },
     "buffer-service-inline-lobs" => {
         "type" => BOOLEAN,
         "description" => "Set to true to allow inlining of memory based and small lobs into results. However inline lob values are not supported by pre-7.6 clients, so disable this property if using older clients utilizing lobs. (default true)	",
         "required" => false,
-        "max-occurs" => 1,
         "default" => true
     },
     "buffer-service-processor-batch-size" => {
         "type" => INT,
         "description" => "The max row count of a batch sent internally within the query processor. Should be <= the 'connector-batch-size'. (default 256)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 256
     },
     "buffer-service-connector-batch-size" => {
         "type" => INT,
         "description" => "The max row count of a batch from a connector. Should be even multiple of 'processor-batch-size'. (default 512)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 512
     },
     "buffer-service-max-processing-kb" => {
         "type" => INT,
         "description" => "The approximate amount of buffer memory in kilobytes allowable for a single processing operation (sort, grouping, etc.) regardless of existing memory commitments. -1 means to automatically calculate a value (default -1)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => -1
     },
     "buffer-service-max-reserve-kb" => {
         "type" => INT,
         "description" => "The approximate amount of memory in kilobytes allowed to be held by the buffer manager. -1 means to automatically calculate a value (default -1)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => -1
     },
     "buffer-service-max-file-size" => {
         "type" => LONG,
         "description" => "Max File size in MB (default 2GB)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 2048L
     },
     "buffer-service-max-buffer-space" => {
         "type" => LONG,
         "description" => "Max storage space, in MB, to be used for buffer files (default 50G)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 51200L
     },
     "buffer-service-max-open-files" => {
         "type" => INT,
         "description" => "Max open buffer files (default 64)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 64
     },
     "buffer-service-memory-buffer-space" => {
         "type" => INT,
         "description" => "Memory buffer space used by the buffer manager in MB.  -1 determines the setting automatically from the max-reserve-kb (default -1). This value cannot be smaller than max-storage-object-size",
         "required" => false,
-        "max-occurs" => 1,
         "default" => -1
     },
     "buffer-service-memory-buffer-off-heap" => {
         "type" => BOOLEAN,
         "description" => "Set to true to hold the memory buffer off-heap. If true you must ensure that the VM can allocate that much direct memory (default false).",
         "required" => false,
-        "max-occurs" => 1,
         "default" => false
     },
     "buffer-service-max-storage-object-size" => {
         "type" => INT,
         "description" => "The maximum size of a buffer managed object (typically a table page or a results batch) in bytes (default 8388608 or 8MB). Setting this value too high will reduce the effectiveness of the memory buffer.",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 8388608
     },
     "preparedplan-cache-max-entries" => {
         "type" => INT,
         "description" => "Max Entries allowed",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 512
     },
     "preparedplan-cache-max-age-in-seconds" => {
         "type" => INT,
         "description" => "Max age in seconds",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 28800
     },
     "resultset-cache-name" => {
         "type" => STRING,
         "description" => "Infinispan cache name for resultset",
         "required" => false,
-        "max-occurs" => 1,
         "default" => "resultset"
     },
     "resultset-cache-container-name" => {
         "type" => STRING,
         "description" => "Infinispan cache container name",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     },
     "resultset-cache-max-staleness" => {
         "type" => INT,
         "description" => "Max staleness in seconds.  Modifications are based upon data updates -1 indicates no max. (default 60 - 1 minute)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 60
     },
     "resultset-cache-enable" => {
         "type" => BOOLEAN,
         "description" => "Resultset cache enabled",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     }
 }}
\ No newline at end of file

Modified: trunk/jboss-integration/src/test/resources/teiid-transport-config.txt
===================================================================
--- trunk/jboss-integration/src/test/resources/teiid-transport-config.txt	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/jboss-integration/src/test/resources/teiid-transport-config.txt	2011-12-01 18:19:11 UTC (rev 3714)
@@ -3,131 +3,111 @@
         "type" => STRING,
         "description" => "Transport protocol (allowed=teiid, pg) ",
         "required" => false,
-        "max-occurs" => 1,
         "default" => "teiid"
     },
     "socket-binding" => {
         "type" => STRING,
         "description" => "Socket binding to be used for the transport",
-        "required" => true,
-        "max-occurs" => 1
+        "required" => true
     },
     "max-socket-threads" => {
         "type" => INT,
         "description" => "Max number of threads dedicated to initial request processing. Zero indicates the system default of max available processors. (default 0)  Setting this value above the max available processors is not recommended.",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 0
     },
     "input-buffer-size" => {
         "type" => INT,
         "description" => "SO_RCVBUF size, 0 indicates that system default should be used (default 0)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 0
     },
     "output-buffer-size" => {
         "type" => INT,
         "description" => "SO_SNDBUF size, 0 indicates that system default should be used (default 0)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 0
     },
     "authentication-security-domain" => {
         "type" => STRING,
         "description" => "Security domain to be enforced with the transport",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     },
     "authentication-max-sessions-allowed" => {
         "type" => INT,
         "description" => "Maximum number of sessions allowed by the system (default 5000)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 5000
     },
     "authentication-sessions-expiration-timelimit" => {
         "type" => INT,
         "description" => "Max allowed time before the session is terminated by the system, 0 indicates unlimited (default 0)",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 0
     },
     "authentication-krb5-domain" => {
         "type" => STRING,
         "description" => "KRB5 security domain name, if GSS API based single-sign-on is being used. Note security-domain still needed to define the roles for users.  ",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     },
     "pg-max-lob-size-in-bytes" => {
         "type" => INT,
         "description" => "Max LOB size in Postgres protocol, as streaming is not supported",
         "required" => false,
-        "max-occurs" => 1,
         "default" => 5242880
     },
     "ssl-mode" => {
         "type" => STRING,
         "description" => "can be one of disabled, login, or enabled disabled = no transport or message level security will be used; login = only the login traffic will be encrypted at a message level using 128 bit AES with an ephemerial DH key exchange. No other config values are needed in this mode; enabled = traffic will be secured using this configuration,if the client supports SSL",
         "required" => false,
-        "max-occurs" => 1,
         "default" => "login"
     },
     "ssl-authentication-mode" => {
         "type" => STRING,
         "description" => "Authentication Mode (1-way, 2-way, anonymous)             ",
         "required" => false,
-        "max-occurs" => 1,
         "default" => "anonymous"
     },
     "ssl-ssl-protocol" => {
         "type" => STRING,
         "description" => "SSL protocol used",
         "required" => false,
-        "max-occurs" => 1,
         "default" => "SSLv3"
     },
     "ssl-keymanagement-algorithm" => {
         "type" => STRING,
         "description" => "Use key management algorithm",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     },
     "enabled-cipher-suites" => {
         "type" => STRING,
         "description" => "Cipher suites that are allowed to be used for SSL. Use to restrict encryption strength(128 bit, 256 bit). Only provide encryption suites that are supported by both client and server JVM. ex:SSL_RSA_WITH_RC4_128_MD5,SSL_RSA_WITH_RC4_128_SHA,SSL_RSA_WITH_3DES_EDE_CBC_SHA,SSL_DHE_DSS_WITH_3DES_EDE_CBC_SHA,SSL_DHE_RSA_WITH_3DES_EDE_CBC_SHA,TLS_DHE_RSA_WITH_AES_128_CBC_SHA,TLS_DHE_DSS_WITH_AES_128_CBC_SHA,TLS_KRB5_WITH_RC4_128_MD5,TLS_KRB5_WITH_RC4_128_SHA,TLS_RSA_WITH_AES_128_CBC_SHA,TLS_KRB5_WITH_3DES_EDE_CBC_MD5,TLS_KRB5_WITH_3DES_EDE_CBC_SHA,TLS_DHE_RSA_WITH_AES_256_CBC_SHA,TLS_DHE_DSS_WITH_AES_256_CBC_SHA,TLS_RSA_WITH_AES_256_CBC_SHA",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     },
     "keystore-name" => {
         "type" => STRING,
         "description" => "Keystore File Name",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     },
     "keystore-password" => {
         "type" => STRING,
         "description" => "Keystore password",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     },
     "keystore-type" => {
         "type" => STRING,
         "description" => "Keystore type",
         "required" => false,
-        "max-occurs" => 1,
         "default" => "JKS"
     },
     "truststore-name" => {
         "type" => STRING,
         "description" => "Truststore Name",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     },
     "truststore-password" => {
         "type" => STRING,
         "description" => "Truststore Password",
-        "required" => false,
-        "max-occurs" => 1
+        "required" => false
     }
 }}
\ No newline at end of file

Modified: trunk/pom.xml
===================================================================
--- trunk/pom.xml	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/pom.xml	2011-12-01 18:19:11 UTC (rev 3714)
@@ -10,7 +10,17 @@
 	<properties>
 		<ant.version>1.7.0</ant.version>
 		<site.url>http://www.jboss.org/teiid</site.url>
-        <jbossas-version>7.1.0.Alpha2-SNAPSHOT</jbossas-version>
+        <jbossas-version>7.1.0.Beta1</jbossas-version>
+        <version.org.jboss.jboss-common-core>2.2.17.GA</version.org.jboss.jboss-common-core>
+        <version.org.jboss.staxmapper>1.0.0.Final</version.org.jboss.staxmapper>
+        <version.org.jboss.jboss-dmr>1.0.0.Final</version.org.jboss.jboss-dmr>
+        <version.org.jboss.msc.jboss-msc>1.0.1.GA</version.org.jboss.msc.jboss-msc>
+        <version.org.jboss.modules.jboss-modules>1.1.0.CR3</version.org.jboss.modules.jboss-modules>
+        <version.org.jboss.jboss-vfs>3.1.0.CR1</version.org.jboss.jboss-vfs>
+        <version.org.picketbox>4.0.6.Beta1</version.org.picketbox>
+        <version.org.jboss.logging.jboss-logging>3.1.0.CR1</version.org.jboss.logging.jboss-logging>
+        <version.org.jboss.logging.jboss-logging-tools>1.0.0.CR4</version.org.jboss.logging.jboss-logging-tools>
+        <version.org.picketbox.jbosssx-client>3.0.0.CR2</version.org.picketbox.jbosssx-client>
 	</properties>
 	<scm>
         <connection>scm:svn:https://anonsvn.jboss.org/repos/teiid/trunk</connection>
@@ -375,7 +385,7 @@
             <dependency>
                 <groupId>org.jboss</groupId>
                 <artifactId>jboss-common-core</artifactId>
-                <version>2.2.17.GA</version>
+                <version>${version.org.jboss.jboss-common-core}</version>
                 <exclusions>
                     <exclusion>
                         <groupId>org.jboss.logging</groupId>
@@ -396,29 +406,34 @@
             <dependency>
                 <groupId>org.jboss</groupId>
                 <artifactId>staxmapper</artifactId>
-                <version>1.0.0.Final</version>
+                <version>${version.org.jboss.staxmapper}</version>
             </dependency>
+            <dependency>
+                <groupId>org.picketbox</groupId>
+                <artifactId>jbosssx-client</artifactId>
+                <version>${version.org.picketbox.jbosssx-client}</version>
+            </dependency>
     
             <dependency>
                 <groupId>org.jboss</groupId>
                 <artifactId>jboss-dmr</artifactId>
-                <version>1.0.0.Final</version>
+                <version>${version.org.jboss.jboss-dmr}</version>
             </dependency>
             
             <dependency>
                 <groupId>org.jboss.msc</groupId>
                 <artifactId>jboss-msc</artifactId>
-                <version>1.0.0.GA</version>
+                <version>${version.org.jboss.msc.jboss-msc}</version>
             </dependency> 
             <dependency>
                 <groupId>org.jboss.modules</groupId>
                 <artifactId>jboss-modules</artifactId>
-                <version>1.0.3.GA</version>
+                <version>${version.org.jboss.modules.jboss-modules}</version>
             </dependency>             
             <dependency>
                 <groupId>org.jboss</groupId>
                 <artifactId>jboss-vfs</artifactId>
-                <version>3.0.1.GA</version>
+                <version>${version.org.jboss.jboss-vfs}</version>
                 <exclusions>
                     <exclusion>
                         <groupId>org.jboss.logging</groupId>
@@ -433,22 +448,48 @@
             <dependency>
                 <groupId>org.picketbox</groupId>
                 <artifactId>picketbox</artifactId>
-                <version>4.0.1</version>
+                <version>${version.org.picketbox}</version>
             </dependency>           
             <dependency>
                 <groupId>org.jboss.as</groupId>
                 <artifactId>jboss-as-server</artifactId>
                 <version>${jbossas-version}</version>
+                <exclusions>
+                    <exclusion>
+                        <groupId>org.jboss.as</groupId>
+                        <artifactId>jboss-as-transactions</artifactId>
+                    </exclusion>
+                </exclusions>
             </dependency>
             <dependency>
                 <groupId>org.jboss.as</groupId>
                 <artifactId>jboss-as-connector</artifactId>
                 <version>${jbossas-version}</version>
+                <exclusions>
+                    <exclusion>
+                        <groupId>org.jboss.as</groupId>
+                        <artifactId>jboss-as-server</artifactId>
+                    </exclusion>
+                    <exclusion>
+                        <groupId>org.jboss.as</groupId>
+                        <artifactId>jboss-as-transactions</artifactId>
+                    </exclusion>                    
+                </exclusions>                  
             </dependency>   
             <dependency>
                 <groupId>org.jboss.as</groupId>
                 <artifactId>jboss-as-security</artifactId>
                 <version>${jbossas-version}</version>
+                <exclusions>
+                    <exclusion>
+                        <groupId>org.jboss.as</groupId>
+                        <artifactId>jboss-as-server</artifactId>
+                    </exclusion>
+                    <exclusion>
+                        <groupId>org.jboss.as</groupId>
+                        <artifactId>jboss-as-transactions</artifactId>
+                    </exclusion>                    
+                </exclusions>                                                
             </dependency>  
             <dependency>
                 <groupId>org.jboss.as</groupId>
@@ -463,17 +504,23 @@
             <dependency>
                 <groupId>org.jboss.logging</groupId>
                 <artifactId>jboss-logging</artifactId>
-                <version>3.0.0.GA</version>
+                <version>${version.org.jboss.logging.jboss-logging}</version>
             </dependency>   
             <dependency>
                 <groupId>org.jboss.logging</groupId>
                 <artifactId>jboss-logging-generator</artifactId>
-                <version>1.0.0.CR1</version>            
+                <version>${version.org.jboss.logging.jboss-logging-tools}</version>            
             </dependency>   
             <dependency>
               <groupId>org.jboss.as</groupId>
               <artifactId>jboss-as-clustering-infinispan</artifactId>
               <version>${jbossas-version}</version>
+              <exclusions>
+                    <exclusion>
+                        <groupId>org.jboss.logging</groupId>
+                        <artifactId>jboss-logging-processor</artifactId>
+                    </exclusion>
+             </exclusions>              
             </dependency>            
             <dependency>
                 <groupId>org.jboss.logging</groupId>

Modified: trunk/runtime/src/main/java/org/teiid/services/SessionServiceImpl.java
===================================================================
--- trunk/runtime/src/main/java/org/teiid/services/SessionServiceImpl.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/runtime/src/main/java/org/teiid/services/SessionServiceImpl.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -357,11 +357,11 @@
 	}
 	
 	public void setAuthenticationType(AuthenticationType flag) {
-		this.authenticationType = flag;
-		LogManager.logInfo(LogConstants.CTX_SECURITY, "Authentication Type set to: "+flag); //$NON-NLS-1$
+		this.authenticationType = flag;		
 	}
 	
 	public void start() {
+		LogManager.logInfo(LogConstants.CTX_SECURITY, RuntimePlugin.Util.getString("auth_type", authenticationType, securityDomainNames)); //$NON-NLS-1$
         this.sessionMonitor.schedule(new TimerTask() {
         	@Override
         	public void run() {

Modified: trunk/runtime/src/main/java/org/teiid/transport/ServerWorkItem.java
===================================================================
--- trunk/runtime/src/main/java/org/teiid/transport/ServerWorkItem.java	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/runtime/src/main/java/org/teiid/transport/ServerWorkItem.java	2011-12-01 18:19:11 UTC (rev 3714)
@@ -70,7 +70,11 @@
 		final boolean encrypt = message.getContents() instanceof SealedObject;
 		ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
         try {
-        	Thread.currentThread().setContextClassLoader(Module.getCallerModule().getClassLoader());
+        	try {
+        		Thread.currentThread().setContextClassLoader(Module.getCallerModule().getClassLoader());
+        	} catch(Throwable t) {
+        		// ignore
+        	}
             message.setContents(this.socketClientInstance.getCryptor().unsealObject(message.getContents()));
 			if (!(message.getContents() instanceof ServiceInvocationStruct)) {
 				throw new AssertionError("unknown message contents"); //$NON-NLS-1$

Modified: trunk/runtime/src/main/resources/org/teiid/runtime/i18n.properties
===================================================================
--- trunk/runtime/src/main/resources/org/teiid/runtime/i18n.properties	2011-12-01 17:33:11 UTC (rev 3713)
+++ trunk/runtime/src/main/resources/org/teiid/runtime/i18n.properties	2011-12-01 18:19:11 UTC (rev 3714)
@@ -100,3 +100,4 @@
 krb5_login_failed=Kerberos context login failed
 no_security_domains=No security domain configured for Kerberos authentication. Can not authenticate.
 krb5_user_not_found=GSS authentication is in use, however authenticated user not found in the context to proceed.
+auth_type=Authentication Type set to {0} for security-domains {1}



More information about the teiid-commits mailing list