[teiid-commits] teiid SVN: r1721 - in branches/JCA: build/kit-jboss-container/deployers and 27 other directories.

teiid-commits at lists.jboss.org teiid-commits at lists.jboss.org
Fri Jan 8 11:42:33 EST 2010


Author: rareddy
Date: 2010-01-08 11:42:28 -0500 (Fri, 08 Jan 2010)
New Revision: 1721

Added:
   branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectionPoolStatistics.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/Logger.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/WorkerPoolStatistics.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/impl/ConnectionPoolStatisticsMetadata.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/impl/PropertyDefinitionMetadata.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/impl/RequestMetadata.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/impl/RequestMetadataMapper.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/impl/TransactionMetadata.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/impl/TransactionMetadataMapper.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/impl/WorkerPoolStatisticsMetadata.java
   branches/JCA/engine/src/main/java/org/teiid/dqp/internal/process/DQPManagementView.java
Removed:
   branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMConnectionPool.java
   branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMConnectorType.java
   branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMExtensionModule.java
   branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMGroup.java
   branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMQueueWorkerPool.java
   branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMRequest.java
   branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMRole.java
   branches/JCA/client/src/main/java/com/metamatrix/admin/objects/TransactionImpl.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/Cache.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/ConfigurationAdmin.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectionPool.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectorType.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/EmbeddedLogger.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/ExtensionModule.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/Group.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/MonitoringAdmin.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/QueueWorkerPool.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/Role.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/RuntimeStateAdmin.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/SecurityAdmin.java
   branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/WorkerPoolStats.java
   branches/JCA/engine/src/main/java/org/teiid/dqp/internal/process/Util.java
   branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/BaseAdmin.java
   branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPConfigAdminImpl.java
   branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPMonitoringAdminImpl.java
   branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPRuntimeStateAdminImpl.java
   branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPSecurityAdminImpl.java
   branches/JCA/runtime/src/test/java/com/metamatrix/dqp/embedded/admin/TestBaseAdmin.java
Modified:
   branches/JCA/build/kit-jboss-container/deploy/teiid-jboss-beans.xml
   branches/JCA/build/kit-jboss-container/deployers/teiid-deployer-jboss-beans.xml
   branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMProcess.java
   branches/JCA/client/src/main/java/com/metamatrix/common/xa/MMXid.java
   branches/JCA/client/src/main/java/com/metamatrix/dqp/client/ClientSideDQP.java
   branches/JCA/client/src/main/java/com/metamatrix/dqp/message/RequestID.java
   branches/JCA/client/src/main/java/com/metamatrix/platform/security/api/ILogon.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/Admin.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/ProcessObject.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/PropertyDefinition.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/Request.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/TeiidAdmin.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/Transaction.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/impl/SessionMetadata.java
   branches/JCA/client/src/main/java/org/teiid/adminapi/impl/SessionMetadataMapper.java
   branches/JCA/client/src/main/resources/com/metamatrix/admin/i18n.properties
   branches/JCA/client/src/test/java/com/metamatrix/common/comm/platform/socket/client/TestSocketServerConnection.java
   branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/StatsCapturingWorkManager.java
   branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/WorkerPool.java
   branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/WorkerPoolFactory.java
   branches/JCA/common-internal/src/test/java/com/metamatrix/common/queue/TestQueueWorkerPool.java
   branches/JCA/engine/src/main/java/com/metamatrix/dqp/service/TransactionService.java
   branches/JCA/engine/src/main/java/org/teiid/dqp/internal/datamgr/impl/ConnectorManager.java
   branches/JCA/engine/src/main/java/org/teiid/dqp/internal/datamgr/impl/ConnectorWorkItem.java
   branches/JCA/engine/src/main/java/org/teiid/dqp/internal/datamgr/impl/SynchConnectorWorkItem.java
   branches/JCA/engine/src/main/java/org/teiid/dqp/internal/process/DQPCore.java
   branches/JCA/engine/src/main/java/org/teiid/dqp/internal/transaction/TransactionServerImpl.java
   branches/JCA/engine/src/test/java/org/teiid/dqp/internal/process/TestDQPCore.java
   branches/JCA/engine/src/test/java/org/teiid/dqp/internal/process/TestDQPCoreRequestHandling.java
   branches/JCA/jboss-integration/src/main/java/org/teiid/adminapi/jboss/Admin.java
   branches/JCA/jboss-integration/src/main/java/org/teiid/adminapi/jboss/ManagedUtil.java
   branches/JCA/jboss-integration/src/main/java/org/teiid/jboss/JBossContainerHelper.java
   branches/JCA/jboss-integration/src/main/java/org/teiid/jboss/deployers/ConnectorBindingDeployer.java
   branches/JCA/jboss-integration/src/main/java/org/teiid/templates/connector/ConnectorTypeTemplateInfo.java
   branches/JCA/jboss-integration/src/test/java/org/teiid/adminapi/jboss/BaseConnection.java
   branches/JCA/jboss-integration/src/test/java/org/teiid/adminapi/jboss/TestConnectorBindings.java
   branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPLogListener.java
   branches/JCA/runtime/src/main/java/com/metamatrix/jdbc/EmbeddedConnectionFactoryImpl.java
   branches/JCA/runtime/src/main/java/com/metamatrix/platform/security/session/service/SessionServiceImpl.java
   branches/JCA/runtime/src/main/java/org/teiid/transport/AdminAuthorizationInterceptor.java
   branches/JCA/runtime/src/main/java/org/teiid/transport/LogonImpl.java
   branches/JCA/runtime/src/main/java/org/teiid/transport/SocketListener.java
   branches/JCA/runtime/src/main/java/org/teiid/transport/SocketTransport.java
   branches/JCA/runtime/src/test/java/org/teiid/transport/TestSocketRemoting.java
Log:
TEIID-833, TEIID-910: Implemented more admin API methods. Added management for requests, transactions, sessions, connector types

Modified: branches/JCA/build/kit-jboss-container/deploy/teiid-jboss-beans.xml
===================================================================
--- branches/JCA/build/kit-jboss-container/deploy/teiid-jboss-beans.xml	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/build/kit-jboss-container/deploy/teiid-jboss-beans.xml	2010-01-08 16:42:28 UTC (rev 1721)
@@ -30,6 +30,7 @@
         <property name="sessionService"><inject bean="SessionService"/></property>
         <property name="bufferService"><inject bean="BufferService"/></property>
         <property name="connectorManagerRepository"><inject bean="ConnectorManagerRepository"/></property>
+        <property name="DQPManager"><inject bean="DQPManager"/></property>
     </bean>
     
     <!-- Teiid Services -->
@@ -67,7 +68,7 @@
     </application-policy>    
     
    <!-- Connector Types -->
-   <bean name="connector-jdbc-template" class="org.teiid.templates.connector.ConnectorTypeTemplate">
+   <bean name="connector-jdbc-7.0.0-SNAPSHOT" class="org.teiid.templates.connector.ConnectorTypeTemplate">
       <property name="info"><inject bean="connector-jdbc-templateinfo"/></property>
       <property name="targetTemplate"><inject bean="NoTxConnectionFactoryTemplate"/></property>
    </bean>
@@ -76,8 +77,64 @@
          <factory bean="DSDeploymentTemplateInfoFactory"/>
          <parameter class="java.lang.Class">org.teiid.templates.connector.ConnectorTypeTemplateInfo</parameter>
          <parameter class="java.lang.Class">org.jboss.resource.metadata.mcf.NoTxConnectionFactoryDeploymentMetaData</parameter>
-         <parameter class="java.lang.String">connector-jdbc-template</parameter>
-         <parameter class="java.lang.String">connector-jdbc-7.0.0-SNAPSHOT.rar</parameter>
+         <parameter class="java.lang.String">connector-jdbc-7.0.0-SNAPSHOT</parameter>
+         <parameter class="java.lang.String">Teiid JDBC Connector</parameter>
       </constructor>
    </bean> 
+   
+   <bean name="connector-ldap-7.0.0-SNAPSHOT" class="org.teiid.templates.connector.ConnectorTypeTemplate">
+      <property name="info"><inject bean="connector-ldap-templateinfo"/></property>
+      <property name="targetTemplate"><inject bean="NoTxConnectionFactoryTemplate"/></property>
+   </bean>
+   <bean name="connector-ldap-templateinfo" class="org.teiid.templates.connector.ConnectorTypeTemplateInfo">
+      <constructor factoryMethod="createTemplateInfo">
+         <factory bean="DSDeploymentTemplateInfoFactory"/>
+         <parameter class="java.lang.Class">org.teiid.templates.connector.ConnectorTypeTemplateInfo</parameter>
+         <parameter class="java.lang.Class">org.jboss.resource.metadata.mcf.NoTxConnectionFactoryDeploymentMetaData</parameter>
+         <parameter class="java.lang.String">connector-ldap-7.0.0-SNAPSHOT</parameter>
+         <parameter class="java.lang.String">Teiid LDAP Connector</parameter>
+      </constructor>
+   </bean>    
+   
+   <bean name="connector-loopback-7.0.0-SNAPSHOT" class="org.teiid.templates.connector.ConnectorTypeTemplate">
+      <property name="info"><inject bean="connector-loopback-templateinfo"/></property>
+      <property name="targetTemplate"><inject bean="NoTxConnectionFactoryTemplate"/></property>
+   </bean>
+   <bean name="connector-loopback-templateinfo" class="org.teiid.templates.connector.ConnectorTypeTemplateInfo">
+      <constructor factoryMethod="createTemplateInfo">
+         <factory bean="DSDeploymentTemplateInfoFactory"/>
+         <parameter class="java.lang.Class">org.teiid.templates.connector.ConnectorTypeTemplateInfo</parameter>
+         <parameter class="java.lang.Class">org.jboss.resource.metadata.mcf.NoTxConnectionFactoryDeploymentMetaData</parameter>
+         <parameter class="java.lang.String">connector-loopback-7.0.0-SNAPSHOT</parameter>
+         <parameter class="java.lang.String">Teiid Loopback Connector</parameter>
+      </constructor>
+   </bean>    
+   
+   <bean name="connector-salesforce-7.0.0-SNAPSHOT" class="org.teiid.templates.connector.ConnectorTypeTemplate">
+      <property name="info"><inject bean="connector-salesforce-templateinfo"/></property>
+      <property name="targetTemplate"><inject bean="NoTxConnectionFactoryTemplate"/></property>
+   </bean>
+   <bean name="connector-salesforce-templateinfo" class="org.teiid.templates.connector.ConnectorTypeTemplateInfo">
+      <constructor factoryMethod="createTemplateInfo">
+         <factory bean="DSDeploymentTemplateInfoFactory"/>
+         <parameter class="java.lang.Class">org.teiid.templates.connector.ConnectorTypeTemplateInfo</parameter>
+         <parameter class="java.lang.Class">org.jboss.resource.metadata.mcf.NoTxConnectionFactoryDeploymentMetaData</parameter>
+         <parameter class="java.lang.String">connector-salesforce-7.0.0-SNAPSHOT</parameter>
+         <parameter class="java.lang.String">Teiid Salesforce Connector</parameter>
+      </constructor>
+   </bean>    
+   
+   <bean name="connector-text-7.0.0-SNAPSHOT" class="org.teiid.templates.connector.ConnectorTypeTemplate">
+      <property name="info"><inject bean="connector-text-templateinfo"/></property>
+      <property name="targetTemplate"><inject bean="NoTxConnectionFactoryTemplate"/></property>
+   </bean>
+   <bean name="connector-text-templateinfo" class="org.teiid.templates.connector.ConnectorTypeTemplateInfo">
+      <constructor factoryMethod="createTemplateInfo">
+         <factory bean="DSDeploymentTemplateInfoFactory"/>
+         <parameter class="java.lang.Class">org.teiid.templates.connector.ConnectorTypeTemplateInfo</parameter>
+         <parameter class="java.lang.Class">org.jboss.resource.metadata.mcf.NoTxConnectionFactoryDeploymentMetaData</parameter>
+         <parameter class="java.lang.String">connector-text-7.0.0-SNAPSHOT</parameter>
+         <parameter class="java.lang.String">Teiid Text Connector</parameter>
+      </constructor>
+   </bean>    
 </deployment>

Modified: branches/JCA/build/kit-jboss-container/deployers/teiid-deployer-jboss-beans.xml
===================================================================
--- branches/JCA/build/kit-jboss-container/deployers/teiid-deployer-jboss-beans.xml	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/build/kit-jboss-container/deployers/teiid-deployer-jboss-beans.xml	2010-01-08 16:42:28 UTC (rev 1721)
@@ -30,8 +30,6 @@
     </bean>       
     
     
-          
-    
     <bean name="SystemVDBDeployer" class="org.teiid.deployers.SystemVDBDeployer">
         <property name="VDBRepository"><inject bean="VDBRepository"/></property>
     </bean>      
@@ -43,9 +41,11 @@
     
     <bean name="VDBRepository" class="org.teiid.deployers.VDBRepository"/>
     <bean name="ConnectorManagerRepository" class="org.teiid.dqp.internal.datamgr.impl.ConnectorManagerRepository"/>
+    <bean name="DQPManager" class="org.teiid.dqp.internal.process.DQPManagementView">
+        <property name="connectorManagerRepository"><inject bean="ConnectorManagerRepository"/></property>
+    </bean>
         
         
-        
    <!--  JBOSS Cache -->
    <!-- Uncomment for JBoss Cache -->
    <!-- 

Deleted: branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMConnectionPool.java
===================================================================
--- branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMConnectionPool.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMConnectionPool.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,115 +0,0 @@
-package com.metamatrix.admin.objects;
-
-import org.teiid.adminapi.ConnectionPool;
-
-public class MMConnectionPool implements ConnectionPool {
-	
-	/**
-	 * @since 6.1
-	 */
-	private static final long serialVersionUID = -2341549955193216875L;
-	
-	private boolean xa;
-	/**
-	 * Number of connections currently in use by a client
-	 */
-	private int connectionInUse;
-	/**
-	 * Number of connections waiting for use by a client
-	 */
-	private int connectionsWaiting;
-	/**
-	 * Total number of connections currently in the pool
-	 */
-	private int totalConnections;
-	
-	/**
-	 * Total number of connections that have been destroyed since the inception of the pool
-	 */
-	private long connectionsDestroyed;
-	/**
-	 * Total number of connections that have been created since the inception of the pool
-	 */
-	private long connectionsCreated;
-	
-	private String connectorBindingIdentifier;
-
-	public boolean isXAPoolType() {
-		return xa;
-	}
-	
-	public void setXa(boolean xa) {
-		this.xa = xa;
-	}
-	
-	@Override
-	public String getConnectorBindingIdentifier() {
-		return connectorBindingIdentifier;
-	}
-	
-	public void setConnectorBindingIdentifier(String connectorBindingIdentifier) {
-		this.connectorBindingIdentifier = connectorBindingIdentifier;
-	}
-	
-	public int getConnectionsInuse() {
-		return this.connectionInUse;
-	}
-
-	public int getConnectionsWaiting() {
-		return this.connectionsWaiting;
-	}
-
-	public long getConnectionsCreated() {
-		return this.connectionsCreated;
-	}
-
-	public long getConnectionsDestroyed() {
-		return this.connectionsDestroyed;
-	}
-
-	public int getTotalConnections() {
-		return this.totalConnections;
-	}
-	
-	public void setConnectionsInUse(int inUseConnections) {
-		this.connectionInUse = inUseConnections;
-	}
-
-	public void setConnectionsWaiting(int waitingConnections) {
-		this.connectionsWaiting = waitingConnections;
-	}
-
-	public void setTotalConnections(int totalConnections) {
-		this.totalConnections = totalConnections;
-	}
-
-	public void setConnectionsDestroyed(long connectionsDestroyed) {
-		this.connectionsDestroyed = connectionsDestroyed;
-	}
-
-	public void setConnectionsCreated(long connectionsCreated) {
-		this.connectionsCreated = connectionsCreated;
-	}
-
-
-	@Override
-    /**
-     * Get string for display purposes 
-     * @see java.lang.Object#toString()
-     * @since 6.1
-     */
-    public String toString() {
-        StringBuffer str = new StringBuffer();
-        
-        str.append(this.connectorBindingIdentifier + " ConnectionPoolStats:\n"); //$NON-NLS-1$
-        str.append("\tisXAPoolType = " + isXAPoolType()); //$NON-NLS-1$
-        str.append("\ttotalConnections = " + this.totalConnections); //$NON-NLS-1$
-        str.append("\tinUseConnections = " + this.connectionInUse); //$NON-NLS-1$
-        str.append("\twaitingConnections = " + connectionsWaiting);     //$NON-NLS-1$
-        str.append("\tconnectionsCreated = " + connectionsCreated);     //$NON-NLS-1$
-        str.append("\tconnectionsDestroyed = " + connectionsDestroyed);     //$NON-NLS-1$
-        return str.toString();
-    }
-
-
-}

Deleted: branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMConnectorType.java
===================================================================
--- branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMConnectorType.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMConnectorType.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,58 +0,0 @@
-/*
- * 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 com.metamatrix.admin.objects;
-
-import org.teiid.adminapi.ConnectorType;
-
-import com.metamatrix.admin.AdminPlugin;
-
-/**
- * Dataholder for a connector type.
- */
-public class MMConnectorType extends MMAdminObject implements ConnectorType {
-	private static final long serialVersionUID = -3029541826277765764L;
-
-	/**
-     * Constructor
-     * @param identifierParts of the Conenctor Type
-     */
-    public MMConnectorType(String[] identifierParts) {
-        super(identifierParts);        
-    }
-    
-    
-	/**
-	 * @see java.lang.Object#toString()
-	 */
-	public String toString() {
-		StringBuffer result = new StringBuffer();
-		result.append(AdminPlugin.Util.getString("MMConnectorType.MMConnectorType")).append(getIdentifier());  //$NON-NLS-1$
-        result.append(AdminPlugin.Util.getString("MMConnectorType.Created")).append(getCreatedDate()); //$NON-NLS-1$
-        result.append(AdminPlugin.Util.getString("MMConnectorType.Created_By")).append(getCreatedBy()); //$NON-NLS-1$
-        result.append(AdminPlugin.Util.getString("MMConnectorType.Updated")).append(getLastChangedDate()); //$NON-NLS-1$
-        result.append(AdminPlugin.Util.getString("MMConnectorType.Updated_By")).append(getLastChangedBy()); //$NON-NLS-1$
-		return result.toString();
-	}
-    
-    
-}

Deleted: branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMExtensionModule.java
===================================================================
--- branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMExtensionModule.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMExtensionModule.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,109 +0,0 @@
-/*
- * 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 com.metamatrix.admin.objects;
-
-import org.teiid.adminapi.ExtensionModule;
-
-import com.metamatrix.admin.AdminPlugin;
-
-/**
- * A simple Extension Modules for the Admin API
- */
-public final class MMExtensionModule extends MMAdminObject implements ExtensionModule {
-	private static final long serialVersionUID = -3250813293338474584L;
-	private String description;
-    private byte[] fileContents;
-    private String moduleType;
-
-    
-   
-    /**
-     * Create a new MMExtensionModule 
-     * @param identifierParts
-     * @since 4.3
-     */
-    public MMExtensionModule(String[] identifierParts) {
-        super(identifierParts);   
-    }
-    
-    
-    
-    /**
-     * @return description
-     */
-    public String getDescription() {
-        return description;
-    }
-    
-    /**
-     * @param description
-     */
-    public void setDescription(String description) {
-        this.description = description;
-    }
-
-    /**
-     * @return byte array of file contents
-     */
-    public byte[] getFileContents() {
-        return fileContents;
-    }
-    
-    /**
-     * @param contents
-     */
-    public void setFileContents(byte[] contents) {
-        this.fileContents = contents;
-    }
-    
-    /**
-     * @return String of the Module Type for this Extension Module
-     */
-    public String getModuleType() {
-        return moduleType;
-    }
-    
-    /**
-     * @param type
-     */
-    public void setModuleType(String type) {
-        this.moduleType = type;
-    }
-
-    
-
-    /**
-     * @return a String of this object for display.
-     */
-    public String toString() {
-        StringBuffer result = new StringBuffer();
-        result.append(AdminPlugin.Util.getString("MMExtensionModule.MMExtensionModule")).append(getIdentifier()); //$NON-NLS-1$
-        result.append(AdminPlugin.Util.getString("MMExtensionModule.moduleType")).append(getModuleType()); //$NON-NLS-1$
-        result.append(AdminPlugin.Util.getString("MMExtensionModule.description")).append(getDescription()); //$NON-NLS-1$
-        return result.toString();
-    }
-    
-    
-    
-
-}
\ No newline at end of file

Deleted: branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMGroup.java
===================================================================
--- branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMGroup.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMGroup.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,51 +0,0 @@
-/*
- * 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 com.metamatrix.admin.objects;
-
-import org.teiid.adminapi.Group;
-
-
-/** 
- * @since 4.3
- */
-public class MMGroup extends MMAdminObject implements Group {
-	private static final long serialVersionUID = 1102507655851078982L;
-
-	/** 
-     * @param groupName
-     * @since 4.3
-     */
-    public MMGroup(String[] groupName) {
-        super(groupName);
-    }
-
-	@Override
-	public String toString() {
-        StringBuffer sb = new StringBuffer();
-        sb.append("[Name=\""); //$NON-NLS-1$
-        sb.append(this.getName());
-        sb.append("\"]"); //$NON-NLS-1$
-        return sb.toString();
-	}
-
-}

Modified: branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMProcess.java
===================================================================
--- branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMProcess.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMProcess.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -27,7 +27,7 @@
 
 import org.teiid.adminapi.AdminObject;
 import org.teiid.adminapi.ProcessObject;
-import org.teiid.adminapi.QueueWorkerPool;
+import org.teiid.adminapi.WorkerPoolStatistics;
 
 import com.metamatrix.admin.AdminPlugin;
 
@@ -52,7 +52,7 @@
     private long objectsWritten = 0;
     private Date startTime;
     
-    private QueueWorkerPool queueWorkerPool = null;
+    private WorkerPoolStatistics queueWorkerPool = null;
     
 
     /**
@@ -296,14 +296,14 @@
      * @return Returns the queueWorkerPool.
      * @since 4.3
      */
-    public QueueWorkerPool getQueueWorkerPool() {
+    public WorkerPoolStatistics getQueueWorkerPool() {
         return this.queueWorkerPool;
     }
     /** 
      * @param queueWorkerPool The queueWorkerPool to set.
      * @since 4.3
      */
-    public void setQueueWorkerPool(QueueWorkerPool queueWorkerPool) {
+    public void setQueueWorkerPool(WorkerPoolStatistics queueWorkerPool) {
         this.queueWorkerPool = queueWorkerPool;
     }
 

Deleted: branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMQueueWorkerPool.java
===================================================================
--- branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMQueueWorkerPool.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMQueueWorkerPool.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,155 +0,0 @@
-/*
- * 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 com.metamatrix.admin.objects;
-
-import org.teiid.adminapi.QueueWorkerPool;
-
-import com.metamatrix.admin.AdminPlugin;
-
-/**
- * Dataholder for all the statistics gathered about a worker pool.
- */
-public class MMQueueWorkerPool extends MMAdminObject implements QueueWorkerPool {
-	private static final long serialVersionUID = 454595217325824487L;
-	// Current state    
-    private int queued = 0;
-    private int threads = 0;
-    
-    // Total counts, never reset
-    private int highestThreads;
-    private int highestQueued = 0;
-    private long totalSubmitted = 0;
-    private long totalCompleted = 0;
-    
-    /**
-     * Construct a new MMQueueWorkerPool 
-     * @param identifierParts
-     * @since 4.3
-     */
-    public MMQueueWorkerPool(String[] identifierParts) {
-        super(identifierParts);
-    }
-   
-    /**
-     * Get string for display purposes 
-     * @see java.lang.Object#toString()
-     * @since 4.3
-     */
-    public String toString() {
-        StringBuffer str = new StringBuffer();
-        
-        str.append(AdminPlugin.Util.getString("MMQueueWorkerPool.MMQueueWorkerPool") + getIdentifier()); //$NON-NLS-1$
-        str.append(AdminPlugin.Util.getString("MMQueueWorkerPool.queued") + queued); //$NON-NLS-1$
-        str.append(AdminPlugin.Util.getString("MMQueueWorkerPool.highestQueued") + highestQueued);  //$NON-NLS-1$
-        str.append(AdminPlugin.Util.getString("MMQueueWorkerPool.totalSubmitted") + totalSubmitted); //$NON-NLS-1$
-        str.append(AdminPlugin.Util.getString("MMQueueWorkerPool.totalCompleted") + totalCompleted); //$NON-NLS-1$
-        str.append(AdminPlugin.Util.getString("MMQueueWorkerPool.threads") + threads);     //$NON-NLS-1$
-        str.append(AdminPlugin.Util.getString("MMQueueWorkerPool.highestThreads") + highestThreads);  //$NON-NLS-1$
-        
-        return str.toString();
-    }
-    
-    /** 
-     * @return Returns the number of requests queued.
-     * @since 4.3
-     */
-    public int getQueued() {
-        return this.queued;
-    }
-    /** 
-     * @param queued The number of requests queued.
-     * @since 4.3
-     */
-    public void setQueued(int queued) {
-        this.queued = queued;
-    }
-    /** 
-     * @return Returns the number of threads.
-     * @since 4.3
-     */
-    public int getThreads() {
-        return this.threads;
-    }
-    /** 
-     * @param threads The number of threads to set.
-     * @since 4.3
-     */
-    public void setThreads(int threads) {
-        this.threads = threads;
-    }
-    /** 
-     * @return Returns the number of totalDequeues.
-     * @since 4.3
-     */
-    public long getTotalDequeues() {
-    	return getTotalCompleted();
-    }
-    /** 
-     * @return Returns the number of totalEnqueues.
-     * @since 4.3
-     */
-    public long getTotalEnqueues() {
-        return getTotalSubmitted();
-    }
-    /** 
-     * @return Returns the totalHighwaterMark.
-     * @since 4.3
-     */
-    public int getTotalHighwaterMark() {
-        return getHighestQueued();
-    }
-
-	public int getHighestThreads() {
-		return highestThreads;
-	}
-
-	public void setHighestThreads(int highestThreads) {
-		this.highestThreads = highestThreads;
-	}
-
-	public int getHighestQueued() {
-		return highestQueued;
-	}
-
-	public void setHighestQueued(int highestQueued) {
-		this.highestQueued = highestQueued;
-	}
-
-	public long getTotalSubmitted() {
-		return totalSubmitted;
-	}
-
-	public void setTotalSubmitted(long totalSubmitted) {
-		this.totalSubmitted = totalSubmitted;
-	}
-
-	public void setTotalCompleted(long totalCompleted) {
-		this.totalCompleted = totalCompleted;
-	}
-
-	public long getTotalCompleted() {
-		return totalCompleted;
-	}
-
-}
-

Deleted: branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMRequest.java
===================================================================
--- branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMRequest.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMRequest.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,274 +0,0 @@
-/*
- * 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 com.metamatrix.admin.objects;
-
-import java.util.Date;
-
-import org.teiid.adminapi.Request;
-
-import com.metamatrix.admin.AdminPlugin;
-import com.metamatrix.core.util.DateUtil;
-
-/**
- * Dataholder for information about Requests.
- */
-public class MMRequest extends MMAdminObject implements Request{
-	
-	private static final long serialVersionUID = -6271863624581160147L;
-	String userName = ""; //$NON-NLS-1$;
-	String sessionID;
-    String requestID;
-	Date created;
-	Date processingDate;
-	String transactionID = ""; //$NON-NLS-1$;
-	String sqlCommand = ""; //$NON-NLS-1$; 
-    String connectorBindingName= ""; //$NON-NLS-1$; 
-    String nodeID=""; //$NON-NLS-1$
-    boolean sourceRequest = false;
-    
-    /**
-     * Construct a new MMRequest 
-     * @param identifierParts
-     * @since 4.3
-     */
-    public MMRequest(String[] identifierParts) {
-        super(identifierParts);
-        
-        this.sessionID = identifierParts[0];
-        this.requestID = identifierParts[1];
-        if (identifierParts.length >= 3) {
-            this.nodeID = identifierParts[2];
-            this.sourceRequest = true;
-        }
-        this.name = requestID;
-    }
-    
-    
-	
-    
-    /**
-     * @return Date the request was created
-     * @since 4.3
-     */
-	public Date getCreated() {
-        return created;
-    }
-    
-    
-    /**
-     * @return Date the request was created, as a String
-     * @since 4.3
-     */
-	public String getCreatedString() {
-        String result = ""; //$NON-NLS-1$;
-        if( created != null ) {
-            result = DateUtil.getDateAsString(created);
-        } 
-        return result;
-	}
-	
-    
-    
-    /**
-     * Get the RequestID for a Request
-     * @return RequestID
-     */
-    public String getRequestID() {
-        return requestID;
-    } 
-    
-	/**
-	 * Get the SessionID for a Request
-	 * 
-	 * @return long SessionID
-	 */
-	public String getSessionID() {
-		return sessionID;
-	}
-
-	/**
-	 * Get the SQL Command sent to the Server for a Request
-	 * 
-	 * @return MetaMatrix SQL Command
-	 */
-	public String getSqlCommand() {
-		return sqlCommand;
-	}
-
-	/**
-	 * Get the Date processing began for the Request
-	 * @return Date processing began for the request
-	 */
-	public Date getProcessingDate() {
-		return processingDate;
-	}
-    
-    /**
-     * Get the Date processing began for the Request, as a String
-     * @return Date processing began for the request
-     */
-    public String getProcessingDateString() {
-        String result = ""; //$NON-NLS-1$;
-        if (processingDate != null) {
-            result = DateUtil.getDateAsString(processingDate);
-        }
-        return result;
-    }
-    
-
-	/**
-	 * Get the TransactionID of the Request
-	 * 
-	 * @return String of TransactionID if in a transaction
-	 */
-	public String getTransactionID() {
-		return transactionID;
-	}
-
-	/**
-	 * Get the UserName of the Request
-	 * 
-	 * @return String username for the Request
-	 */
-	public String getUserName() {
-		return userName;
-	}
-    
-    
-    
-    
-    
-    /** 
-     * @param created The date created.
-     * @since 4.3
-     */
-    public void setCreated(Date created) {
-        this.created = created;
-    }
-    /** 
-     * @param sessionID The sessionID to set.
-     * @since 4.3
-     */
-    public void setSessionID(String sessionID) {
-        this.sessionID = sessionID;
-    }
-    /** 
-     * @param sqlCommand The sqlCommand to set.
-     * @since 4.3
-     */
-    public void setSqlCommand(String sqlCommand) {
-        this.sqlCommand = sqlCommand;
-    }
-    /** 
-     * @param processingDate The date processing began.
-     * @since 4.3
-     */
-    public void setProcessingDate(Date processingDate) {
-        this.processingDate = processingDate;
-    }
-    /** 
-     * @param transactionID The transactionID to set.
-     * @since 4.3
-     */
-    public void setTransactionID(String transactionID) {
-        this.transactionID = transactionID;
-    }
-    /** 
-     * @param userName The userName to set.
-     * @since 4.3
-     */
-    public void setUserName(String userName) {
-        this.userName = userName;
-    }
-    
-    /** 
-     * @return Returns the connectorBindingName.
-     * @since 4.3
-     */
-    public String getConnectorBindingName() {
-        return this.connectorBindingName;
-    }
-    /** 
-     * @param connectorBindingName The connectorBindingName to set.
-     * @since 4.3
-     */
-    public void setConnectorBindingName(String connectorBindingName) {
-        this.connectorBindingName = connectorBindingName;
-    }
-    
-    /** 
-     * @return Returns whether this is a Source Request.
-     * @since 4.3
-     */
-    public boolean isSource() {
-        return sourceRequest;
-    }
-    
-    /**
-     * Set if the request is source request 
-     * @param value
-     * @since 4.3
-     */
-    public void setSource(boolean value) {
-        sourceRequest = value;
-    }
-    
-    /**
-     * If  this is a source request then this represents the node id 
-     * @return Returns the nodeID.
-     * @since 4.3
-     */
-    public String getNodeID() {
-        return this.nodeID;
-    }
-    
-    /** 
-     * If  this is a source request then this represents the node id
-     * @param nodeID The nodeID to set.
-     * @since 4.3
-     */
-    public void setNodeID(String nodeID) {
-        this.nodeID = nodeID;
-    }    
-    
-    
-	/**
-	 * @see java.lang.Object#toString()
-     * @return String for display purposes
-	 */
-	public String toString() {
-		StringBuffer result = new StringBuffer();
-		result.append(AdminPlugin.Util.getString("MMRequest.MMRequest")).append(getIdentifier());  //$NON-NLS-1$
-        if (isSource()) {
-            result.append(AdminPlugin.Util.getString("MMRequest.nodeID")).append(getNodeID());  //$NON-NLS-1$    
-        }
-		result.append(AdminPlugin.Util.getString("MMRequest.requestID")).append(getRequestID()); //$NON-NLS-1$
-		result.append(AdminPlugin.Util.getString("MMRequest.userName")).append(userName); //$NON-NLS-1$
-		result.append(AdminPlugin.Util.getString("MMRequest.sessionID")).append(sessionID); //$NON-NLS-1$
-		result.append(AdminPlugin.Util.getString("MMRequest.created")).append(getCreatedString()); //$NON-NLS-1$
-		result.append(AdminPlugin.Util.getString("MMRequest.processing")).append(getProcessingDateString()); //$NON-NLS-1$
-		result.append(AdminPlugin.Util.getString("MMRequest.transactionID")).append(transactionID); //$NON-NLS-1$
-		result.append(AdminPlugin.Util.getString("MMRequest.command")).append(sqlCommand);  //$NON-NLS-1$
-		return result.toString();
-	}   
-}

Deleted: branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMRole.java
===================================================================
--- branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMRole.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/com/metamatrix/admin/objects/MMRole.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,100 +0,0 @@
-/*
- * 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 com.metamatrix.admin.objects;
-
-import java.util.Properties;
-
-import org.teiid.adminapi.Role;
-
-
-
-/** 
- * @since 4.3
- */
-public class MMRole extends MMAdminObject implements Role {
-
-	private static final long serialVersionUID = -768301010301417417L;
-
-	/** 
-     * Ctor
-     * @param identifier the role identifier should contain the whole
-     * dotted notation in one field of the identifier so that the name
-     * contains all components.
-     * @since 4.3
-     */
-    public MMRole(String[] identifier) {
-        super(identifier);
-    }
-    
-    /**
-     * Get the names of all administrative roles in the system. 
-     * @return the array of all role names suitable for adding to Principals.
-     * @since 4.3
-     */
-    public static String[] getAvailableRoles() {
-        return new String[] {Role.ADMIN_PRODUCT, Role.ADMIN_SYSTEM, Role.ADMIN_READONLY};
-    }
-
-    /** 
-     * @see org.teiid.adminapi.AdminObject#getIdentifier()
-     * @since 4.3
-     */
-    public String getIdentifier() {
-        return super.getIdentifier();
-    }
-
-    /** 
-     * @see org.teiid.adminapi.AdminObject#getName()
-     * @since 4.3
-     */
-    public String getName() {
-        // A Role name should not be broken into components
-        // Role name should have have complete, dotted notation.
-        return super.getIdentifier();
-    }
-
-    /** 
-     * @see org.teiid.adminapi.AdminObject#getProperties()
-     * @since 4.3
-     */
-    public Properties getProperties() {
-        return null;
-    }
-
-    /** 
-     * @see org.teiid.adminapi.AdminObject#getPropertyValue(java.lang.String)
-     * @since 4.3
-     */
-    public String getPropertyValue(String name) {
-        return null;
-    }
-
-    /** 
-     * @see com.metamatrix.admin.objects.MMAdminObject#toString()
-     * @since 4.3
-     */
-    public String toString() {
-        return super.getIdentifier();
-    }
-
-}

Deleted: branches/JCA/client/src/main/java/com/metamatrix/admin/objects/TransactionImpl.java
===================================================================
--- branches/JCA/client/src/main/java/com/metamatrix/admin/objects/TransactionImpl.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/com/metamatrix/admin/objects/TransactionImpl.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,77 +0,0 @@
-/*
- * 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 com.metamatrix.admin.objects;
-
-import javax.transaction.xa.Xid;
-
-import org.teiid.adminapi.Transaction;
-
-import com.metamatrix.admin.AdminPlugin;
-import com.metamatrix.common.xa.MMXid;
-
-public class TransactionImpl extends MMAdminObject implements Transaction {
-
-	private static final long serialVersionUID = -8588785315218789068L;
-	private long associatedSession;
-	private String scope;
-	private MMXid xid;
-	
-	public TransactionImpl(String ... id) {
-		super(id);
-	}
-
-	public long getAssociatedSession() {
-		return associatedSession;
-	}
-
-	public void setAssociatedSession(long associatedSession) {
-		this.associatedSession = associatedSession;
-	}
-
-	public String getScope() {
-		return scope;
-	}
-
-	public void setScope(String scope) {
-		this.scope = scope;
-	}
-
-	public Xid getXid() {
-		return xid;
-	}
-
-	public void setXid(MMXid xid) {
-		this.xid = xid;
-	}
-
-	@Override
-	public String toString() {
-        StringBuffer result = new StringBuffer();
-        result.append(AdminPlugin.Util.getString("TransactionImpl.identifier")).append(getIdentifier());  //$NON-NLS-1$
-        result.append(AdminPlugin.Util.getString("TransactionImpl.associatedSession")).append(associatedSession); //$NON-NLS-1$
-        result.append(AdminPlugin.Util.getString("TransactionImpl.scope")).append(scope); //$NON-NLS-1$
-        result.append(AdminPlugin.Util.getString("TransactionImpl.xid")).append(xid); //$NON-NLS-1$
-        return result.toString();
-	}
-
-}

Modified: branches/JCA/client/src/main/java/com/metamatrix/common/xa/MMXid.java
===================================================================
--- branches/JCA/client/src/main/java/com/metamatrix/common/xa/MMXid.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/com/metamatrix/common/xa/MMXid.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -28,7 +28,7 @@
 import javax.transaction.xa.Xid;
 
 /**
- * MetaMatrix implementation of Xid.
+ * Teiid implementation of Xid.
  */
 public class MMXid implements Xid, Serializable {
     private static final long serialVersionUID = -7078441828703404308L;
@@ -113,7 +113,7 @@
 	    if (toString == null) {
     	    StringBuffer sb = new StringBuffer();
     	    
-    	    sb.append("MMXid global:"); //$NON-NLS-1$
+    	    sb.append("Teiid-Xid global:"); //$NON-NLS-1$
             sb.append(getByteArrayString(globalTransactionId));
             sb.append(" branch:"); //$NON-NLS-1$
             sb.append(getByteArrayString(branchQualifier));

Modified: branches/JCA/client/src/main/java/com/metamatrix/dqp/client/ClientSideDQP.java
===================================================================
--- branches/JCA/client/src/main/java/com/metamatrix/dqp/client/ClientSideDQP.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/com/metamatrix/dqp/client/ClientSideDQP.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -43,7 +43,7 @@
 
 	ResultsFuture<?> closeRequest(long requestID) throws MetaMatrixProcessingException, MetaMatrixComponentException;
 	
-	void cancelRequest(long requestID) throws MetaMatrixProcessingException, MetaMatrixComponentException;
+	boolean cancelRequest(long requestID) throws MetaMatrixProcessingException, MetaMatrixComponentException;
 	
 	ResultsFuture<?> closeLobChunkStream(int lobRequestId, long requestId, String streamId) throws MetaMatrixProcessingException, MetaMatrixComponentException;
 	
@@ -55,7 +55,7 @@
 	
 	MetadataResult getMetadata(long requestID, String preparedSql, boolean allowDoubleQuotedVariable) throws MetaMatrixComponentException, MetaMatrixProcessingException;
 	
-	void terminateConnection(long sessionId) throws MetaMatrixComponentException;
+	void terminateSession() throws MetaMatrixComponentException;
 	
     // local transaction
     void begin() throws XATransactionException;

Modified: branches/JCA/client/src/main/java/com/metamatrix/dqp/message/RequestID.java
===================================================================
--- branches/JCA/client/src/main/java/com/metamatrix/dqp/message/RequestID.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/com/metamatrix/dqp/message/RequestID.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -79,6 +79,14 @@
         computeHashCode();
     }
     
+    public RequestID(long connectionID, long executionID) {
+        this.connectionID = String.valueOf(connectionID);
+        this.executionID = executionID;
+        
+        createCombinedID();
+        computeHashCode();
+    }    
+    
     /**
      * Create a RequestID for an execution where the connection is 
      * not specified.

Modified: branches/JCA/client/src/main/java/com/metamatrix/platform/security/api/ILogon.java
===================================================================
--- branches/JCA/client/src/main/java/com/metamatrix/platform/security/api/ILogon.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/com/metamatrix/platform/security/api/ILogon.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -53,7 +53,4 @@
    ResultsFuture<?> logoff() throws InvalidSessionException;
    
    void assertIdentity(SessionToken sessionId) throws InvalidSessionException, MetaMatrixComponentException;
-   
-   void terminate(SessionToken sessionId);
-
 }

Modified: branches/JCA/client/src/main/java/org/teiid/adminapi/Admin.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/Admin.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/Admin.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -22,5 +22,370 @@
 
 package org.teiid.adminapi;
 
-public interface Admin extends ConfigurationAdmin, MonitoringAdmin, RuntimeStateAdmin, SecurityAdmin {
+import java.net.URL;
+import java.util.Collection;
+import java.util.Properties;
+import java.util.Set;
+
+import com.metamatrix.admin.RolesAllowed;
+
+ at RolesAllowed(value=AdminRoles.RoleName.ADMIN_SYSTEM)
+public interface Admin {
+	
+	public enum Cache {CODE_TABLE_CACHE,PREPARED_PLAN_CACHE, QUERY_SERVICE_RESULT_SET_CACHE, CONNECTOR_RESULT_SET_CACHE};
+    
+    /**
+     * Assign a {@link ConnectorBinding} to a {@link VDB}'s Model
+     *
+     * @param connectorBindingName
+     *            Name of the ConnectorBinding
+     * @param vdbName
+     *            Name of the VDB
+     * @param vdbVersion
+     *            Version of the VDB
+     * @param modelName
+     *            Name of the Model to map Connector Binding
+     * @throws AdminException
+     *             if there's a system error or if there's a user input error.
+     */
+    void assignBindingToModel(String connectorBindingName,
+                              String vdbName,
+                              String vdbVersion,
+                              String modelName) throws AdminException;
+    
+    void assignBindingsToModel(String[] connectorBindingName,
+            String vdbName,
+            String vdbVersion,
+            String modelName) throws AdminException;    
+
+    /**
+     * Set/update the property for the Connector Binding identified by the given deployed name.
+     * @param deployedName
+     * @param propertyName
+     * @param propertyValue
+     * @throws AdminException
+     */
+    void setConnectorBindingProperty(String deployedName, String propertyName, String propertyValue) throws AdminException;
+    
+    /**
+     * Add Connector Type, will import Connector Type from a file
+     *
+     * @param name  of the Connector Type to add
+     * @param URL URL to RAR file
+     * @throws AdminException  if there's a system error.
+     */
+    void addConnectorType(String name, URL rarURL) throws AdminException;
+
+    /**
+     * Delete Connector Type from Next Configuration
+     *
+     * @param name String name of the Connector Type to delete
+     * @throws AdminException
+     *             if there's a system error.
+     */
+    void deleteConnectorType(String name) throws AdminException;
+
+    /**
+     * Deploy a {@link ConnectorBinding} to Configuration
+     *
+     * @param deployedName  Connector Binding name that will be added to Configuration
+     * @param typeName Connector type name. 
+     * @param properties Name & Value pair need to deploy the Connector Binding
+
+     * @throws AdminException if there's a system error.
+     */
+    void addConnectorBinding(String deployedName, String typeName, Properties properties) throws AdminException;
+
+    /**
+     * Delete the {@link ConnectorBinding} from the Configuration
+     *
+     * @param deployedName - deployed name of the connector binding
+     * @throws AdminException  if there's a system error.
+     */
+    void deleteConnectorBinding(String deployedName) throws AdminException;
+
+    /**
+     * Deploy a {@link VDB} file.
+     * @param name  Name of the VDB file to save under
+     * @param URL 	VDB file location.
+     * @throws AdminException
+     *             if there's a system error.
+     * @return the {@link VDB} representing the current property values and runtime state.
+     */
+    public void deployVDB(String fileName, URL vdbURL) throws AdminException;
+    
+    
+    /**
+     * Delete the VDB with the given name and version
+     * @param vdbName
+     * @param version
+     * @throws AdminException
+     */
+    void deleteVDB(String vdbName, int vdbVersion) throws AdminException;
+    
+    /**
+     * Add User Defined Function model to the system. If one is already deployed before this 
+     * will replace the previous, otherwise add this as the new UDF model. Once the UDF is added
+     * the new UDF model is loaded.  
+     * @param modelFileContents - UDF contents
+     * @param classpath - classpath for the UDF
+     * @throws AdminException
+     */
+    void addUDF(byte[] modelFileContents, String classpath) throws AdminException;
+    
+    /**
+     * Delete the User Defined Function model. Note that this will not delete any supporting
+     * extension jar files added, those need to be deleted separately.
+     * @throws AdminException  
+     */
+    void deleteUDF() throws AdminException;
+    
+    
+    /**
+     * Set a process level property. 
+     * @param propertyName - name of the property
+     * @param propertyValue - value of the property
+     */
+    void setRuntimeProperty(String propertyName, String propertyValue) throws AdminException;
+    
+    /**
+     * Import the data Roles for given vdb and version into the connected server
+     * @param vdbName - target name of the VDB, the roles to be imported under
+     * @param vdbVersion - target version of the vdb, the roles to be imported under
+     * @param data - character data array containing the XML file which defines the roles 
+     * @param options - options to overwrite in case the matching roles already exist.
+     * @return a report of the import
+     * @throws AdminException
+     */
+    String importDataRoles(String vdbName, String vdbVersion, char[] data, AdminOptions options)  
+        throws AdminException;	
+    
+    /**
+     * Get the Connector Types available in the configuration.
+     *
+     * @return Set of connector types.
+     * @throws AdminException if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
+    Set<String> getConnectorTypes() throws AdminException;
+
+    /**
+     * Get the VDBs that currently deployed in the system
+     *
+     * @return Collection of {@link VDB}s.  There could be multiple VDBs with the
+     * same name in the Collection but they will differ by VDB version.
+     * @throws AdminException if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ANONYMOUS)
+    Set<VDB> getVDBs() throws AdminException;
+    
+    /**
+     * Get the VDB
+     * @param vdbName
+     * @param vbdVersion
+     * @throws AdminException if there's a system error.
+     * @return
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
+    VDB getVDB(String vdbName, int vbdVersion) throws AdminException;
+
+    /**
+     * Get the Connector Bindings that are available in the configuration
+     *
+     * @return Collection of {@link ConnectorBinding}
+     * @throws AdminException if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
+    Collection<ConnectorBinding> getConnectorBindings() throws AdminException;
+    
+    /**
+     * Get the connector binding by the given the deployed name.
+     * @param deployedName - name of the deployed connector binding
+     * @return null if not found a connector binding by the given name
+     * @throws AdminException if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
+    ConnectorBinding getConnectorBinding(String deployedName) throws AdminException;
+
+    /**
+     * Get all the Connector Bindings for the given VDB identifier pattern
+	 * @param vdbName - Name of the VDB
+	 * @param vdbVersion - version of the VDB
+     * @return Collection of {@link ConnectorBinding}
+     * @throws AdminException if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
+    Collection<ConnectorBinding> getConnectorBindingsInVDB(String vdbName, int vdbVersion) throws AdminException;
+
+    /**
+     * Get the Work Manager stats that correspond to the specified identifier pattern.
+     *
+     * @param identifier - an identifier for the queues {@link QueueWorkerPool}. "runtime" will return the stats for Query 
+     * runtime Worker Pool. Also any Connector Binding name will return the stats for that connector binding.
+     * @return Collection of {@link QueueWorkerPool}
+     * @throws AdminException if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
+    WorkerPoolStatistics getWorkManagerStats(String identifier) throws AdminException;
+    
+    
+    /**
+     * Get the Connection Pool Stats that correspond to the specified identifier pattern.
+     * If the {@link ConnectionPoolStatistics ConnectionPool} represents an XA connection, there
+     * will be 2 {@link ConnectionPoolStatistics ConnectionPool}s.  
+     *
+     * @param deployedName - an identifier that corresponds to the ConnectorBinding Name
+     * @return {@link ConnectionPoolStatistics}
+     * @throws AdminException if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
+    ConnectionPoolStatistics getConnectorConnectionPoolStats(String deployedName) throws AdminException;
+        
+
+    /**
+     * Get the Caches that correspond to the specified identifier pattern
+     * @return Collection of {@link String}
+     * @throws AdminException if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
+    Collection<String> getCacheTypes() throws AdminException;
+
+    /**
+     * Get all the current Sessions.
+     * @return Collection of {@link Session}
+     * @throws AdminException if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
+    Collection<Session> getSessions() throws AdminException;
+
+    /**
+     * Get the all Requests that are currently in process
+     * @return Collection of {@link Request}
+     * @throws AdminException if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
+    Collection<Request> getRequests() throws AdminException;
+    
+    /**
+     * Get the Requests for the given session
+     * @return Collection of {@link Request}
+     * @throws AdminException if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
+    Collection<Request> getRequestsForSession(long sessionId) throws AdminException;
+    
+
+    /**
+     * Get all of the available Configuration Properties for the specified AdminObject, and details about them.
+     * @param connectorTypeIdentifier
+     * @return
+     * @throws AdminException
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
+    Collection<PropertyDefinition> getConnectorTypePropertyDefinitions(String connectorTypeIdentifier) throws AdminException;
+    
+    
+    /**
+     * Get all transaction matching the identifier.
+     * @return
+     * @throws AdminException
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
+    Collection<Transaction> getTransactions() throws AdminException;
+    
+    /**
+     * Get the processes that correspond to the specified identifier pattern.
+     *
+     * @param processIdentifier the unique identifier for for a {@link org.teiid.adminapi.ProcessObject ProcessObject}
+     * in the system or "{@link org.teiid.adminapi.AdminObject#WILDCARD WILDCARD}"
+     * if all Processes are desired.
+     * @return Collection of {@link org.teiid.adminapi.ProcessObject ProcessObject}
+     * @throws AdminException if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ANONYMOUS)
+    Collection<ProcessObject> getProcesses(String processIdentifier) throws AdminException;
+    
+    
+    /**
+     * Start Connector Binding
+     *
+     * @param deployedName 
+     * @throws AdminException  if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_PRODUCT)
+    void startConnectorBinding(ConnectorBinding binding) throws AdminException;
+
+    /**
+     * Stop Connector Binding
+     *
+     * @param deployedName  identifier for {@link org.teiid.adminapi.ConnectorBinding}
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_PRODUCT)
+    void stopConnectorBinding(ConnectorBinding binding) throws AdminException;
+
+    /**
+     * Clear the cache or caches specified by the cacheIdentifier.
+     * @param cacheType Cache Type
+     * No wild cards currently supported, must be explicit
+     * @throws AdminException  if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_PRODUCT)
+    void clearCache(String cacheType) throws AdminException;
+
+    /**
+     * Terminate the Session
+     *
+     * @param identifier  Session Identifier {@link org.teiid.adminapi.Session}.
+     * No wild cards currently supported, must be explicit
+     * @throws AdminException  if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_PRODUCT)
+    void terminateSession(long sessionId) throws AdminException;
+
+    /**
+     * Cancel Request
+     *
+     * @param sessionId session Identifier for the request.
+     * @param requestId request Identifier
+     * 
+     * @throws AdminException  if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_PRODUCT)
+    void cancelRequest(long sessionId, long requestId) throws AdminException;
+
+    /**
+     * Change the status of a Deployed VDB
+     *
+     * @param name  Name of the Virtual Database
+     * @param version  Version of the Virtual Database
+     * @param status  Active, InActive, Delete
+     * @throws AdminException  if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_PRODUCT)
+    public void changeVDBStatus(String name, String version, int status)
+        throws AdminException;
+    
+    /**
+     * Mark the given global transaction as rollback only.
+     * @param transactionId
+     * @throws AdminException
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_PRODUCT)
+    void terminateTransaction(String transactionId) throws AdminException;
+    
+    /**
+     * Stop the Teiid.  If millisToWait is >0, then close to incoming queries, wait the time period
+     * for work to stop, then stop the MM Query.  Otherwise, stop immediately, aborting all running queries.
+     * @param millisToWait Milliseconds to wait (if >0) or <=0 for no wait before stopping
+     * @throws AdminException
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_PRODUCT)
+    void shutdown(int millisToWait) throws AdminException;
+
+    /**
+     * Restart System
+     * @throws AdminException if there's a system error.
+     */
+    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_PRODUCT)
+    void restart() throws AdminException;      
 }

Deleted: branches/JCA/client/src/main/java/org/teiid/adminapi/Cache.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/Cache.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/Cache.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,54 +0,0 @@
-/*
- * 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.adminapi;
-
-
-/**
- * Represents a cache in the MetaMatrix system.
- * 
- * <p>An idetiifer for cache is specifically represented by a name. All the 
- * different kinds of available cache are listed as enumerations on this interface.
- * </p>
- * @since 4.3
- */
-public interface Cache extends
-                      AdminObject {
-    
-    /**
-     * 
-     */
-    public static final String CODE_TABLE_CACHE = "CodeTableCache"; //$NON-NLS-1$
-    /**
-     * 
-     */
-    public static final String PREPARED_PLAN_CACHE = "PreparedPlanCache"; //$NON-NLS-1$
-    /**
-     * 
-     */
-    public static final String QUERY_SERVICE_RESULT_SET_CACHE = "QueryServiceResultSetCache"; //$NON-NLS-1$
-    /**
-     * 
-     */
-    public static final String CONNECTOR_RESULT_SET_CACHE = "ConnectorResultSetCache"; //$NON-NLS-1$
-
-}

Deleted: branches/JCA/client/src/main/java/org/teiid/adminapi/ConfigurationAdmin.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/ConfigurationAdmin.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/ConfigurationAdmin.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,311 +0,0 @@
-/*
- * 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.adminapi;
-
-import java.net.URL;
-import java.util.Properties;
-
-import com.metamatrix.admin.RolesAllowed;
-
-
-/**
- * This interface describes the methods to configure Teiid.
- *
- * @since 4.3
- */
- at RolesAllowed(value=AdminRoles.RoleName.ADMIN_SYSTEM)
-public interface ConfigurationAdmin {
-    
-    /**
-     * Assign a {@link ConnectorBinding} to a {@link VDB}'s Model
-     *
-     * @param connectorBindingName
-     *            Name of the ConnectorBinding
-     * @param vdbName
-     *            Name of the VDB
-     * @param vdbVersion
-     *            Version of the VDB
-     * @param modelName
-     *            Name of the Model to map Connector Binding
-     * @throws AdminException
-     *             if there's a system error or if there's a user input error.
-     * @since 4.3
-     */
-    void assignBindingToModel(String connectorBindingName,
-                              String vdbName,
-                              String vdbVersion,
-                              String modelName) throws AdminException;
-    
-    void assignBindingsToModel(String[] connectorBindingName,
-            String vdbName,
-            String vdbVersion,
-            String modelName) throws AdminException;    
-
-    /**
-     * Set/update the property for the Connector Binding identified by the given deployed name.
-     * @param deployedName
-     * @param propertyName
-     * @param propertyValue
-     * @throws AdminException
-     */
-    void setConnectorBindingProperty(String deployedName, String propertyName, String propertyValue) throws AdminException;
-    
-    /**
-     * Add Connector Type, will import Connector Type from a file
-     *
-     * @param name
-     *            of the Connector Type to add
-     * @param cdkFile
-     *            contents of File from Client
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    void addConnectorType(String name, char[] cdkFile) throws AdminException;
-
-    /**
-     * Add Connector Type and all the required extension modules required by the
-     * this connector type into the system from the given file byte stream which is
-     * encoded inthe Connector Archive format.
-     *
-     * @param archiveContents contents of File 
-     * @param options resolution option in case of conflict in the connector type 
-     * @throws AdminException if there's a system error.
-     * @since 4.3.2
-     */
-    void addConnectorArchive(byte[] archiveContents, AdminOptions options ) throws AdminException;
-    
-    /**
-     * Delete Connector Type from Next Configuration
-     *
-     * @param name String name of the Connector Type to delete
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    void deleteConnectorType(String name) throws AdminException;
-
-    /**
-     * Deploy a {@link ConnectorBinding} to Configuration
-     *
-     * @param deployedName  Connector Binding name that will be added to Configuration
-     * @param typeName Connector type name. 
-     * @param properties Name & Value pair need to deploy the Connector Binding
-
-     * @throws AdminException if there's a system error.
-     */
-    void addConnectorBinding(String deployedName, String typeName, Properties properties) throws AdminException;
-
-    /**
-     * Delete the {@link ConnectorBinding} from the Configuration
-     *
-     * @param deployedName - deployed name of the connector binding
-     * @throws AdminException  if there's a system error.
-     */
-    void deleteConnectorBinding(String deployedName) throws AdminException;
-
-    /**
-     * Deploy a {@link VDB} file.
-     * @param name  Name of the VDB file to save under
-     * @param URL 	VDB file location.
-     * @throws AdminException
-     *             if there's a system error.
-     * @return the {@link VDB} representing the current property values and runtime state.
-     * @since 4.3
-     */
-    public void deployVDB(String fileName, URL vdbURL) throws AdminException;
-    
-    
-    /**
-     * Delete the VDB with the given name and version
-     * @param vdbName
-     * @param version
-     * @throws AdminException
-     */
-    void deleteVDB(String vdbName, int vdbVersion) throws AdminException;
-
-    /**
-     * Get the {@link LogConfiguration}
-     *
-     * @return LogConfiguration object
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
-    LogConfiguration getLogConfiguration() throws AdminException;
-
-    /**
-     * Set the {@link LogConfiguration} in the MetaMatrix Server
-     *
-     * @param config
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    void setLogConfiguration(LogConfiguration config) throws AdminException;
-
-    
-    /**
-     * Set the log listener to install into MM Query.  This log listener will receive all log messages
-     * written by the MM Query at it's current log level and log contexts.
-     * 
-     * Note: Logging changes are not persistent. This will be fixed in future versions. 
-     * 
-     * @param listener The listener component
-     * @throws AdminException if there's a system error.
-     * @since 4.3
-     */
-    void setLogListener(EmbeddedLogger listener) throws AdminException;  
-    
-    /**
-     * Adds an {@link ExtensionModule} to the end of the list of modules.
-     * <br><i>All caches (of Class objects) are cleared.</i></br>
-     *
-     * @param type
-     *            one of the known types of extension file
-     * @param sourceName
-     *            name (e.g. filename) of extension module
-     * @param source
-     *            actual contents of module
-     * @param description
-     *            (optional) description of the extension module - may be null
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    void addExtensionModule(String type,
-                            String sourceName,
-                            byte[] source,
-                            String description) throws AdminException;
-
-    /**
-     * Deletes an {@link ExtensionModule} from the list of modules.
-     * <br><i>All caches (of Class objects) are cleared.</i></br>
-     *
-     * @param sourceName
-     *            name (e.g. filename) of extension module
-     * @throws AdminException
-     *             if there's a system error.
-     */
-    void deleteExtensionModule(String sourceName) throws AdminException;
-
-    /**
-     * Export an {@link ExtensionModule} to byte array
-     *
-     * @param sourceName unique identifier for the {@link ExtensionModule}.
-     * @return byte array of the extension module
-     * @throws AdminException
-     * @since 4.3
-     */
-    byte[] exportExtensionModule(String sourceName) throws AdminException;
-
-    /**
-     * Export Configuration to character Array in XML format
-     *
-     * @return character array of Configuration
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    char[] exportConfiguration() throws AdminException;
-
-    /**
-     * Export a {@link ConnectorBinding} to character Array in XML format
-     *
-     * @param connectorBindingIdentifier the unique identifier for a {@link ConnectorBinding}.
-     * @return character Array in XML format
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    char[] exportConnectorBinding(String connectorBindingIdentifier) throws AdminException;
-
-    /**
-     * Export Connector Type to character array
-     *
-     * @param connectorTypeIdentifier the unique identifier for for a {@link ConnectorType}
-     * @return character Array in XML format
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    char[] exportConnectorType(String connectorTypeIdentifier) throws AdminException;
-
-    /**
-     * Export Connector Archive, which is bundled connector type with its xml
-     * properties file and all the extension modules required by the this connector type
-     * 
-     * @param connectorTypeIdentifier the unique identifier for for a {@link ConnectorType}
-     * @return byte array of the connector archive.
-     * @throws AdminException if there's a system error.
-     * @since 4.3.2
-     */
-    byte[] exportConnectorArchive(String connectorTypeIdentifier) throws AdminException;
-    
-    /**
-     * Export VDB to byte array
-     *
-     * @param name identifier of the {@link VDB}
-     * @param version {@link VDB} version
-     * @return byte array of the MetaMatrix VDB Archive
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    byte[] exportVDB(String name, String version) throws AdminException;
-
-
-    /**
-     * Add User Defined Function model to the system. If one is already deployed before this 
-     * will replace the previous, otherwise add this as the new UDF model. Once the UDF is added
-     * the new UDF model is loaded.  
-     * @param modelFileContents - UDF contents
-     * @param classpath - classpath for the UDF
-     * @throws AdminException
-     */
-    void addUDF(byte[] modelFileContents, String classpath) throws AdminException;
-    
-    /**
-     * Delete the User Defined Function model. Note that this will not delete any supporting
-     * extension jar files added, those need to be deleted separately.
-     * @throws AdminException  
-     */
-    void deleteUDF() throws AdminException;
-    
-    /**
-     * Indicates that an extension module has changed 
-     * @throws AdminException
-     * @since 6.1.0
-     */
-    void extensionModuleModified(String name) throws AdminException;   
-    
-    
-    /**
-     * Set a process level property. 
-     * @param processIdentifier - identifier for the process where the property needs to be set
-     * @param propertyName - name of the property
-     * @param propertyValue - value of the property
-     */
-    void setProcessProperty(String processIdentifier, String propertyName, String propertyValue) throws AdminException;
-}

Deleted: branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectionPool.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectionPool.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectionPool.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,73 +0,0 @@
-/*
- * 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.adminapi;
-
-import java.io.Serializable;
-
-
-/** 
- * This object holds the statistics for a ConnectionPool that is being utilized by a Connector.
- * As per how many available connections
- * processed etc.
- * <p>An identifier for ConnectionPool, is nothing but the modules it self, like "DQP", 
- * "QueryService" or Connector Binding names etc.</p> 
- * 
- * @since 4.3
- */
-public interface ConnectionPool extends Serializable {
-    /** 
-     * @return Returns total number of current connections in the Connection Pool 
-     */
-    int getTotalConnections();
-    
-    /** 
-     * @return Returns the number of connections waiting for use in the connection pool. 
-     */
-    int getConnectionsWaiting();
-    
-    /** 
-     * @return Returns the number of Connections currently in use by clients. 
-     */
-    int getConnectionsInuse();
-    
-    /** 
-     * @return Returns the number of Connections created since the Connection Pool was created. 
-     */
-    long getConnectionsCreated();
-    
-    /**
-     * @return The number of Connections destroyed since the Connection Pool was created. 
-     */
-    long getConnectionsDestroyed();
-
-    /**
-     * @return true if this represents an XA connection pool
-     */
-	boolean isXAPoolType();
-
-	/**
-	 * @return the identifier of the connector binding this pool is used with
-	 */
-	String getConnectorBindingIdentifier();
-
-}

Copied: branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectionPoolStatistics.java (from rev 1684, branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectionPool.java)
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectionPoolStatistics.java	                        (rev 0)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectionPoolStatistics.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -0,0 +1,83 @@
+/*
+ * 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.adminapi;
+
+import java.io.Serializable;
+
+
+/** 
+ * This object holds the statistics for a ConnectionPool that is being utilized by a Connector.
+ * As per how many available connections
+ * processed etc.
+ */
+public interface ConnectionPoolStatistics extends AdminObject, Serializable {
+
+	/**
+	 * The maximum number of connections that are available
+	 * @return
+	 */
+	long getAvailableConnectionCount();
+	
+	/**
+	 * The number of connections that are currently in the pool
+	 * @return
+	 */
+	int getConnectionCount();
+
+	/**
+	 * The number of connections that have been created since the connector was last started
+	 * @return
+	 */
+	int getConnectionCreatedCount();
+	
+	/**
+	 * The number of connections that have been destroyed since the connector was last started
+	 * @return
+	 */
+	int getConnectionDestroyedCount();
+	
+
+	/**
+	 * The number of connections that are currently in use
+	 * @return
+	 */
+	long getInUseConnectionCount();
+	
+	/**
+	 * The most connections that have been simultaneously in use since this connector was started
+	 * @return
+	 */
+	long getMaxConnectionsInUseCount();
+	
+	/**
+	 * Max size
+	 * @return
+	 */
+	int getMaxSize();
+	
+	/**
+	 * Min Size
+	 * @return
+	 */
+	int getMinSize();
+}


Property changes on: branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectionPoolStatistics.java
___________________________________________________________________
Name: svn:mime-type
   + text/plain

Deleted: branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectorType.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectorType.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/ConnectorType.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,40 +0,0 @@
-/*
- * 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.adminapi;
-
-
-/**
- * Represents a connector type in the MetaMatrix system.
- * 
- * <p>{@link ConnectorBinding}s are instances of a connector type.</p>
- * 
- * <p>The identifier pattern for a connector type is simply the name
- * of the connector type. Usally name consistes of multiple words with spaces in between
- * for example: "Loopback Connector"
- * </p>
- * 
- * @since 4.3
- */
-public interface ConnectorType extends AdminObject {
-
-}

Deleted: branches/JCA/client/src/main/java/org/teiid/adminapi/EmbeddedLogger.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/EmbeddedLogger.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/EmbeddedLogger.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,44 +0,0 @@
-/*
- * 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.adminapi;
-
-
-/** 
- * Custom logging interface that provides a hook for custom implementations to log messages
- * produced by MM Query.
- * @since 4.3
- */
-public interface EmbeddedLogger {
-    
-    /**
-     * Logs the given message if the current logging level is &gt;= the logLevel parameter. 
-     * @param logLevel logging level for this message
-     * @param timestamp timestamp at which this log message was generated
-     * @param componentName name of the component that generated this message
-     * @param threadName name of the thread that generated this message
-     * @param message message body. May be null.
-     * @param throwable exception thrown. May be null.
-     * @since 4.3
-     */
-    void log(int logLevel, long timestamp, String componentName, String threadName, String message, Throwable throwable);
-}

Deleted: branches/JCA/client/src/main/java/org/teiid/adminapi/ExtensionModule.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/ExtensionModule.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/ExtensionModule.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,103 +0,0 @@
-/*
- * 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.adminapi;
-
-
-/** 
- * An extension module is a library (usually in jar format) that extends
- * the MetaMatrix system in some way.  Classes of a custom connector can
- * be added as an extension module.
- * 
- * <p> The unique identifier pattern for the extension module is generally 
- * the name of the jar file since it applies system wide. Example: <code>MJjdbc.jar</code>
- * @since 4.3
- */
-public interface ExtensionModule extends AdminObject {
-    
-    /**
-     * The name of the JAR file type of extension
-     * module - this is the only type of
-     * extension module that can be searched
-     * for Class objects
-     */
-    public static final String JAR_FILE_TYPE = "JAR File"; //$NON-NLS-1$
-
-    /**
-     * The name of the Metadata Keyword type of
-     * extension module.
-     */
-    public static final String METADATA_KEYWORD_TYPE = "Metadata Keyword"; //$NON-NLS-1$
-
-    /**
-     * The name of the Metamodel Extension type of
-     * extension module.
-     */
-    public static final String METAMODEL_EXTENSION_TYPE = "Metamodel Extension"; //$NON-NLS-1$
-
-    /**
-     * The name of the Function Definition type of
-     * extension module.
-     */
-    public static final String FUNCTION_DEFINITION_TYPE = "Function Definition"; //$NON-NLS-1$
-    
-    /**
-     * The name of the Configuration Model type of
-     * extension module.
-     */
-    public static final String CONFIGURATION_MODEL_TYPE = "Configuration Model"; //$NON-NLS-1$
-    
-    /**
-     * The name of the VDB File type of extension module.
-     */
-    public static final String VDB_FILE_TYPE = "VDB File"; //$NON-NLS-1$
-    
-    /**
-     * The name of the Keystore File of extension module.
-     */
-    public static final String KEYSTORE_FILE_TYPE = "Keystore File"; //$NON-NLS-1$
-
-    /**
-     * The name of the Miscellaneous File type of extension module.
-     */
-    public static final String MISC_FILE_TYPE = "Miscellaneous Type"; //$NON-NLS-1$
-    
-    
-    /**
-     * @return description
-     */
-    public String getDescription();
-
-    /**
-     * @return byte array of file contents
-     */
-    public byte[] getFileContents();
-    
-    /**
-     * @return String of the Module Type for this Extension Module
-     */
-    public String getModuleType();
-
- 
-    
-
-}

Deleted: branches/JCA/client/src/main/java/org/teiid/adminapi/Group.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/Group.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/Group.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,35 +0,0 @@
-/*
- * 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.adminapi;
-
-
-/** 
- * This interface is used to represent a group of principals.
- */
-public interface Group extends AdminObject {
-    
-    /** 
-     * Optional property for a group; group description
-     */
-    static final String DESCRIPTION = "description"; //$NON-NLS-1$
-}

Copied: branches/JCA/client/src/main/java/org/teiid/adminapi/Logger.java (from rev 1684, branches/JCA/client/src/main/java/org/teiid/adminapi/EmbeddedLogger.java)
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/Logger.java	                        (rev 0)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/Logger.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -0,0 +1,44 @@
+/*
+ * 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.adminapi;
+
+
+/** 
+ * Custom logging interface that provides a hook for custom implementations to log messages
+ * produced by MM Query.
+ * @since 4.3
+ */
+public interface Logger {
+    
+    /**
+     * Logs the given message if the current logging level is &gt;= the logLevel parameter. 
+     * @param logLevel logging level for this message
+     * @param timestamp timestamp at which this log message was generated
+     * @param componentName name of the component that generated this message
+     * @param threadName name of the thread that generated this message
+     * @param message message body. May be null.
+     * @param throwable exception thrown. May be null.
+     * @since 4.3
+     */
+    void log(int logLevel, long timestamp, String componentName, String threadName, String message, Throwable throwable);
+}

Deleted: branches/JCA/client/src/main/java/org/teiid/adminapi/MonitoringAdmin.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/MonitoringAdmin.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/MonitoringAdmin.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,214 +0,0 @@
-/*
- * 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.adminapi;
-
-import java.util.Collection;
-import java.util.Set;
-
-import com.metamatrix.admin.RolesAllowed;
-
-
-/**
- * Used to access the monitorable components of the Teiid system.
- * 
- * <p>See the particular admin object in question for an example of
- * allowed identifier patterns.</p>
- *
- * @since 4.3
- */
- at RolesAllowed(value=AdminRoles.RoleName.ADMIN_READONLY)
-public interface MonitoringAdmin {
-
-    /**
-     * Get the Connector Types available in the configuration.
-     *
-     * @return Set of connector types.
-     * @throws AdminException if there's a system error.
-     */
-    Set<String> getConnectorTypes() throws AdminException;
-
-    /**
-     * Get the VDBs that currently deployed in the system
-     *
-     * @return Collection of {@link VDB}s.  There could be multiple VDBs with the
-     * same name in the Collection but they will differ by VDB version.
-     * @throws AdminException if there's a system error.
-     */
-    @RolesAllowed(value=AdminRoles.RoleName.ANONYMOUS)
-    Set<VDB> getVDBs() throws AdminException;
-    
-    /**
-     * Get the VDB
-     * @param vdbName
-     * @param vbdVersion
-     * @throws AdminException if there's a system error.
-     * @return
-     */
-    VDB getVDB(String vdbName, int vbdVersion) throws AdminException;
-
-    /**
-     * Get the Connector Bindings that are available in the configuration
-     *
-     * @return Collection of {@link ConnectorBinding}
-     * @throws AdminException if there's a system error.
-     */
-    Collection<ConnectorBinding> getConnectorBindings() throws AdminException;
-    
-    /**
-     * Get the connector binding by the given the deployed name.
-     * @param deployedName - name of the deplyed connector binding
-     * @return null if not found a connector binding by the given name
-     * @throws AdminException if there's a system error.
-     */
-    ConnectorBinding getConnectorBinding(String deployedName) throws AdminException;
-
-    /**
-     * Get all the Connector Bindings for the given VDB identifier pattern
-	 * @param vdbName - Name of the VDB
-	 * @param vdbVersion - version of the VDB
-     * @return Collection of {@link ConnectorBinding}
-     * @throws AdminException if there's a system error.
-     * @since 4.3
-     */
-    Collection<ConnectorBinding> getConnectorBindingsInVDB(String vdbName, int vdbVersion) throws AdminException;
-
-    /**
-     * Get the Queue Worker Pools that correspond to the specified identifier pattern.
-     *
-     * @param identifier - an identfier for the queues {@link QueueWorkerPool}
-     * <ul>
-     *      <li> <code>"*"</code> - for all Queue workers in the system
-     *      <li> <code>"name*"</code> - for all the Queue workers in that begin with given name
-     *      <li><code>"name"</code> - for a single queue in the system
-     * </ul>
-     * for example, In MM Query - "dqp" will return the Stats for MM Query Worker Pool. Also any Connector Binding
-     * name will return the stats for that connector binding.
-     * @return Collection of {@link QueueWorkerPool}
-     * @throws AdminException if there's a system error.
-     * @since 4.3
-     */
-    Collection<QueueWorkerPool> getQueueWorkerPools(String identifier) throws AdminException;
-    
-    
-    /**
-     * Get the Connection Pool Stats that correspond to the specified identifier pattern.
-     * If the {@link ConnectionPool ConnectionPool} represents an XA connection, there
-     * will be 2 {@link ConnectionPool ConnectionPool}s.  
-     *
-     * @param identifier - an identfier that corresponds to the ConnectorBinding that is
-     * 		running in a process {@link ConnectionPool}
-     * <ul>
-     *      <li> <code>"*"</code> - for all Connection Pools in the system
-     *      <li> <code>"name*"</code> - for all the Connection Pools that begin with given name
-     *      <li><code>"name"</code> - for a single Connection Pool in the system
-     * </ul>
-      * @return Collection of {@link ConnectionPool}
-     * @throws AdminException if there's a system error.
-     * @since 6.1
-     */
-    Collection<? extends ConnectionPool> getConnectionPoolStats(String identifier) throws AdminException;
-        
-
-    /**
-     * Get the Caches that correspond to the specified identifier pattern
-     * @param identifier - an identifier for the cache in {@link Cache}
-     * <ul>
-     *      <li> <code>"*"</code> - for all different caches in the system
-     *      <li> <code>"name*"</code> - for all the caches that begin with given name
-     *      <li><code>"name"</code> - for a single cache in the system
-     * </ul>
-     * @return Collection of {@link Cache}
-     * @throws AdminException if there's a system error.
-     * @since 4.3
-     */
-    Collection<Cache> getCaches(String identifier) throws AdminException;
-
-    /**
-     * Get all the current Sessions.
-     * @return Collection of {@link Session}
-     * @throws AdminException if there's a system error.
-     */
-    Collection<Session> getSessions() throws AdminException;
-
-    /**
-     * Get the Requests that correspond to the specified identifier pattern
-     * @param identifier - An Identifier for {@link Request}
-     * <ul>
-     *      <li> <code>"*"</code> - for all current in process requests of the system
-     *      <li> <code>"number* or number<{@link AdminObject#DELIMITER_CHAR}>*"</code> - for all the sessions
-     *      that begin with given number, or all the requests for particular session etc.
-     *      <li><code>"number<{@link AdminObject#DELIMITER_CHAR}>number"</code> - for a single request in the system
-     * </ul>
-     * @return Collection of {@link Request}
-     * @throws AdminException if there's a system error.
-     * @since 4.3
-     */
-
-    Collection<Request> getRequests(String identifier) throws AdminException;
-
-    /**
-     * Get the Source Request that correspond to the specified identifier pattern
-     * @param identifier An Identifier for {@link Request}
-     * <ul>
-     *      <li> <code>"*"</code> - for all current in process requests of the system
-     *      <li> <code>"number* or number<{@link AdminObject#DELIMITER_CHAR}>* or number.number.*"</code> - for all the sessions
-     *      that begin with given number, or all the requests for particular session etc.
-     *      <li><code>"number<{@link AdminObject#DELIMITER_CHAR}>number<{@link AdminObject#DELIMITER_CHAR}>number"</code> - for a single source request in the system
-     * </ul>
-     * @return Collection of {@link Request}
-     * @throws AdminException if there's a system error.
-     * @since 4.3
-     */
-    Collection<Request> getSourceRequests(String identifier) throws AdminException;
-    
-
-    /**
-     * Get all of the available Configuration Properties for the specified AdminObject, and details about them.
-     * @param connectorTypeIdentifier
-     * @return
-     * @throws AdminException
-     */
-    Collection<PropertyDefinition> getConnectorTypePropertyDefinitions(String connectorTypeIdentifier) throws AdminException;
-    
-    
-    /**
-     * Get all transaction matching the identifier.
-     * @return
-     * @throws AdminException
-     */
-    Collection<Transaction> getTransactions() throws AdminException;
-    
-    /**
-     * Get the processes that correspond to the specified identifier pattern.
-     *
-     * @param processIdentifier the unique identifier for for a {@link org.teiid.adminapi.ProcessObject ProcessObject}
-     * in the system or "{@link org.teiid.adminapi.AdminObject#WILDCARD WILDCARD}"
-     * if all Processes are desired.
-     * @return Collection of {@link org.teiid.adminapi.ProcessObject ProcessObject}
-     * @throws AdminException if there's a system error.
-     * @since 4.3
-     */
-    @RolesAllowed(value=AdminRoles.RoleName.ANONYMOUS)
-    Collection<ProcessObject> getProcesses(String processIdentifier) throws AdminException;
-
-}

Modified: branches/JCA/client/src/main/java/org/teiid/adminapi/ProcessObject.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/ProcessObject.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/ProcessObject.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -136,5 +136,5 @@
      * @return Returns the queueWorkerPool.
      * @since 4.3
      */
-    public QueueWorkerPool getQueueWorkerPool();
+    public WorkerPoolStatistics getQueueWorkerPool();
 }

Modified: branches/JCA/client/src/main/java/org/teiid/adminapi/PropertyDefinition.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/PropertyDefinition.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/PropertyDefinition.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -42,14 +42,7 @@
     public static final int UNBOUNDED_VALUE = Integer.MAX_VALUE;
     
     
-    
     /**
-     * Get the current value of this property.
-     * @return the current value of this property.
-     */
-    String getValue();
-    
-    /**
      * Get the localized display name of this property.
      * @return the displayable name for this property
      */
@@ -62,15 +55,7 @@
     String getDescription();
     
     
-    
     /**
-     * Get the type for values of this property.
-     * @return the type that best describes the values of this property.
-     */
-    String getPropertyType();
-    
-    
-    /**
      * Get the name of the java class that best represents the property type.
      * @return the name of the java class that best represents the property type.
      */

Deleted: branches/JCA/client/src/main/java/org/teiid/adminapi/QueueWorkerPool.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/QueueWorkerPool.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/QueueWorkerPool.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,88 +0,0 @@
-/*
- * 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.adminapi;
-
-
-/** 
- * All server modules use queue based processing inside them. This
- * object holds the statistics of those queues, as per how many of them queued, dequeued, 
- * processed etc.
- * <p>An identifier for QueueWorkerPool, is nothing but the modules it self, like "DQP", 
- * "QueryService" or Connector Binding names etc.</p> 
- * 
- * @since 4.3
- */
-public interface QueueWorkerPool extends AdminObject {
-    /** 
-     * @return Returns the number of requests queued.
-     * @since 4.3
-     */
-    public int getQueued();
-    
-    /** 
-     * @return Returns the number of threads.
-     * @since 4.3
-     */
-    public int getThreads();
-    
-    /** 
-     * @return Returns the highest number of active threads
-     */
-    public int getHighestThreads();
-    
-    /** 
-     * @return Returns the number of totalDequeues.
-     * @since 4.3
-     * @deprecated see {@link #getTotalCompleted()}
-     */
-    public long getTotalDequeues();
-    
-    /**
-     * @return The number of completed tasks
-     */
-    long getTotalCompleted();
-    
-    /** 
-     * @return Returns the number of totalEnqueues.
-     * @since 4.3
-     * @deprecated see {@link #getTotalSubmitted()}
-     */
-    public long getTotalEnqueues();
-    
-    /**
-     * @return The number of submitted tasks
-     */
-    long getTotalSubmitted();
-    
-    /** 
-     * @return Returns the totalHighwaterMark.
-     * @since 4.3
-     * @deprecated see {@link #getHighestQueued()}
-     */
-    public int getTotalHighwaterMark();
-
-    /** 
-     * @return Returns the highest queue size
-     */
-    public int getHighestQueued();
-}

Modified: branches/JCA/client/src/main/java/org/teiid/adminapi/Request.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/Request.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/Request.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -22,7 +22,6 @@
 
 package org.teiid.adminapi;
 
-import java.util.Date;
 
 
 /** 
@@ -33,73 +32,55 @@
  * 
  *  <p>A request is identified by a numbers separated by '|'. usually in they are arranged 
  *  in the pattern [session]|[request] or [session]|[request]|[source request] </p>
- * @since 4.3
  */
 public interface Request extends AdminObject {
-    /**
-     * @return Date the request was created
-     * @since 4.3
+
+	/**
+     * @return time when the request was created
      */
-    public Date getCreated();
+    public long getCreatedTime();
      
     /**
-     * Get the RequestID for a Request
-     * @return RequestID
+     * Get the ExecutionId for a Request
+     * @return ExecutionId
      */
-    public String getRequestID();
+    public long getExecutionId();
     
     /**
      * Get the SessionID for a Request
      * 
      * @return long SessionID
      */
-    public String getSessionID();
+    public long getSessionId();
 
     /**
      * Get the SQL Command sent to the Server for a Request
      * 
-     * @return MetaMatrix SQL Command
+     * @return SQL Command
      */
-    public String getSqlCommand();
+    public String getCommand();
 
     /**
-     * Get the Date processing began for the Request
+     * Get when the processing began for this Request
      * @return Date processing began
      */
-    public Date getProcessingDate();
+    public long getProcessingTime();
 
     /**
      * Get the TransactionID of the Request
      * 
      * @return String of TransactionID if in a transaction
      */
-    public String getTransactionID();
+    public String getTransactionId();
     
-
-    /**
-     * Get the UserName of the Request
-     * 
-     * @return String username for the Request
-     */
-    public String getUserName();
-    
-    
     /** 
-     * @return Returns the connectorBindingName.
-     * @since 4.3
-     */
-    public String getConnectorBindingName();
-    
-    /** 
      * @return Returns whether this is a Source Request.
-     * @since 4.3
      */
-    public boolean isSource();
+    public boolean sourceRequest();
     
     /**  
      * @return In the case that this is a source request this represents the node id. Otherwise blank
-     * @since 4.3
      */
-    public String getNodeID();
+    public int getNodeId();
     
 }

Deleted: branches/JCA/client/src/main/java/org/teiid/adminapi/Role.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/Role.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/Role.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,39 +0,0 @@
-/*
- * 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.adminapi;
-
-
-
-/** 
- * @since 4.3
- */
-public interface Role extends AdminObject {
-    
-    /** System admin role name */
-    public static final String ADMIN_SYSTEM = AdminRoles.RoleName.ADMIN_SYSTEM;
-    /** Product admin role name */
-    public static final String ADMIN_PRODUCT = AdminRoles.RoleName.ADMIN_PRODUCT;
-    /** Read-only admin role name */
-    public static final String ADMIN_READONLY = AdminRoles.RoleName.ADMIN_READONLY;
-
-}

Deleted: branches/JCA/client/src/main/java/org/teiid/adminapi/RuntimeStateAdmin.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/RuntimeStateAdmin.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/RuntimeStateAdmin.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,138 +0,0 @@
-/*
- * 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.adminapi;
-
-import javax.transaction.xa.Xid;
-
-import com.metamatrix.admin.RolesAllowed;
-
-
-/**
- * This interface defines the methods to interact with the Teiid system
- * during runtime.
- *
- * @since 4.3
- */
- at RolesAllowed(value=AdminRoles.RoleName.ADMIN_PRODUCT)
-public interface RuntimeStateAdmin {
-
-    /**
-     * Start Connector Binding
-     *
-     * @param deployedName 
-     * @throws AdminException  if there's a system error.
-     */
-    void startConnectorBinding(String deployedName) throws AdminException;
-
-    /**
-     * Stop Connector Binding
-     *
-     * @param deployedName  identifier for {@link org.teiid.adminapi.ConnectorBinding}
-     */
-    void stopConnectorBinding(String deployedName, boolean stopNow) throws AdminException;
-
-    /**
-     * Clear the cache or caches specified by the cacheIdentifier.
-     * @param cacheIdentifier  Cache name identifier {@link org.teiid.adminapi.Cache}.
-     * No wild cards currently supported, must be explicit
-     * @throws AdminException  if there's a system error.
-     * @since 4.3
-     */
-    @RolesAllowed(value=AdminRoles.RoleName.ADMIN_SYSTEM)
-    void clearCache(String cacheIdentifier) throws AdminException;
-
-    /**
-     * Terminate the Session
-     *
-     * @param identifier  Session Identifier {@link org.teiid.adminapi.Session}.
-     * No wild cards currently supported, must be explicit
-     * @throws AdminException  if there's a system error.
-     * @since 4.3
-     */
-    void terminateSession(long sessionId) throws AdminException;
-
-    /**
-     * Cancel Request
-     *
-     * @param identifier  The request identifier defined by {@link org.teiid.adminapi.Request}
-     * No wild cards currently supported, must be explicit
-     * @throws AdminException  if there's a system error.
-     * @since 4.3
-     */
-    void cancelRequest(String identifier) throws AdminException;
-
-    /**
-     * Cancel Source Request
-     *
-     * @param identifier  The request identifier defined by {@link org.teiid.adminapi.Request}
-     * No wild cards currently supported, must be explicit
-     * @throws AdminException  if there's a system error.
-     * @since 4.3
-     */
-    void cancelSourceRequest(String identifier) throws AdminException;
-
-    /**
-     * Change the status of a Deployed VDB
-     *
-     * @param name  Name of the Virtual Database
-     * @param version  Version of the Virtual Database
-     * @param status  Active, InActive, Delete
-     * @throws AdminException  if there's a system error.
-     * @since 4.3
-     */
-    public void changeVDBStatus(String name, String version, int status)
-        throws AdminException;
-    
-    /**
-     * Mark the given global transaction as rollback only.
-     * @param transactionId
-     * @throws AdminException
-     */
-    void terminateTransaction(Xid transactionId) throws AdminException;
-    
-    /**
-     * Mark the given transaction as rollback only.
-     * @param identifier
-     * 		The exact identifier of the transaction.  Wild card is not supported.
-     * @param the session the transaction is associated with.
-     * @throws AdminException
-     */
-    void terminateTransaction(String transactionId, String sessionId) throws AdminException;
-      
-    
-    /**
-     * Stop the MM Query.  If millisToWait is >0, then close to incoming queries, wait the time period
-     * for work to stop, then stop the MM Query.  Otherwise, stop immediately, aborting all running queries.
-     * @param millisToWait Milliseconds to wait (if >0) or <=0 for no wait before stopping
-     * @throws AdminException
-     * @since 4.3
-     */
-    void shutdown(int millisToWait) throws AdminException;
-
-    /**
-     * Restart System
-     * @throws AdminException if there's a system error.
-     * @since 4.3
-     */
-    void restart() throws AdminException;    
-}

Deleted: branches/JCA/client/src/main/java/org/teiid/adminapi/SecurityAdmin.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/SecurityAdmin.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/SecurityAdmin.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,144 +0,0 @@
-/*
- * 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.adminapi;
-
-import java.io.Serializable;
-import java.util.Collection;
-import java.util.List;
-
-import com.metamatrix.admin.RolesAllowed;
-
-
-/**
- * This interface defines the methods available for security administration
- * in the Teiid system.
- *
- * @since 4.3
- */
- at RolesAllowed(value=AdminRoles.RoleName.ADMIN_SYSTEM)
-public interface SecurityAdmin {
-    /**
-     * Get the Collection of administrative role names possessed by the given group, if any.
-     *
-     * @param groupIdentifier The unique identifier for the {@link Group}. This is group name. 
-     *             The {@link AdminObject#WILDCARD WILDCARD} cannot be used here.
-     * @return The Collection of {@link Role}s.
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    Collection<Role> getRolesForGroup(String groupIdentifier) throws AdminException;
-    
-    /**
-     * Get the group memberships for the given user. 
-     *
-     * @param userIdentifier
-     *            The unique identifier for the user. This is generally a user name.
-     *             The {@link AdminObject#WILDCARD WILDCARD} cannot be used here.
-     * @return The collection of groups in which the given user has membership.
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    Collection<Group> getGroupsForUser(String userIdentifier) throws AdminException;
-    
-    
-    /**
-     * Get the group denoted by the given <code>groupIdentifier</code>.
-     *
-     * @param groupIdentifier
-     *            The unique identifier for the {@link Group}. This is generally a group name. 
-     *            Note that by supplying the {@link AdminObject#WILDCARD WILDCARD} identifier, all all groups in the system will
-     *            retrieved.</br>
-     * @return The Collection of groups.
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    Collection<Group> getGroups(String groupIdentifier) throws AdminException;
-
-    /**
-     * Assign to the given {@link Group} the given Administrative Role.
-     *
-     * @param roleIdentifier
-     *            one of {@link AdminRoles}.
-     * @param groupIdentifier
-     *            the unique identifier for the Group. The {@link AdminObject#WILDCARD WILDCARD} cannot be used here.
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    void assignRoleToGroup(String roleIdentifier,
-                               String groupIdentifier) throws AdminException;
-
-    /**
-     * Remove an administrative role from the given {@link Group}.
-     *
-     * @param roleIdentifier
-     *            one of {@link AdminRoles}
-     * @param groupIdentifier
-     *            the unique identifier for the group. The {@link AdminObject#WILDCARD WILDCARD} cannot be used here.
-     * @throws AdminException
-     *             if there's a system error.
-     * @since 4.3
-     */
-    void removeRoleFromGroup(String roleIdentifier,
-                                 String groupIdentifier) throws AdminException;
-    
-    /**
-     * Import the data Roles for given vdb and version into the connected server
-     * @param vdbName - target name of the VDB, the roles to be imported under
-     * @param vdbVersion - target version of the vdb, the roles to be imported under
-     * @param data - character data array containing the XML file which defines the roles 
-     * @param options - options to overwrite in case the matching roles already exist.
-     * @return a report of the import
-     * @throws AdminException
-     */
-    String importDataRoles(String vdbName, String vdbVersion, char[] data, AdminOptions options)  
-        throws AdminException;
-    
-    /**
-     * Export the data roles defined for the given vdb from the current system
-     * @param vdbName - Name of the vdb
-     * @param vdbVersion - version of the vdb
-     * @return - char[] stream containing the XML contents of the roles.
-     * @throws AdminException
-     */
-    char[] exportDataRoles(String vdbName, String vdbVersion) throws AdminException;
-    
-    /**
-     * Returns the active authorization provider domain names, in authentication order.
-     * @return List<String>
-     * @throws AdminException
-     */
-	List<String> getDomainNames( ) throws AdminException;
-
-	/**
-	 * Return the {@link Group}s for a given domain.  The domain name must be an specified
-	 * exactly.  See {@link #getActiveDomainNames()} for possible domain names.
-	 * @param domainName
-	 * @return
-	 * @throws AdminException
-	 */
-	Collection<Group> getGroupsForDomain(String domainName) throws AdminException;
-}

Modified: branches/JCA/client/src/main/java/org/teiid/adminapi/TeiidAdmin.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/TeiidAdmin.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/TeiidAdmin.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -22,37 +22,11 @@
 package org.teiid.adminapi;
 
 import java.io.Serializable;
-import java.util.Collection;
-import java.util.List;
 
-import javax.transaction.xa.Xid;
 
-
 public abstract class TeiidAdmin implements TeiidAdminMBean, Serializable {
 
 	@Override
-	public void addConnectorArchive(byte[] archiveContents, AdminOptions options)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-
-	@Override
-	public void addConnectorType(String name, char[] cdkFile)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public void addExtensionModule(String type, String sourceName,
-			byte[] source, String description) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
 	public void addUDF(byte[] modelFileContents, String classpath)
 			throws AdminException {
 		// rameshTODO Auto-generated method stub
@@ -76,176 +50,12 @@
 	}
 
 	@Override
-	public void deleteConnectorBinding(String connectorBindingIdentifier)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public void deleteConnectorType(String name) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public void deleteExtensionModule(String sourceName) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
 	public void deleteUDF() throws AdminException {
 		// rameshTODO Auto-generated method stub
 		
 	}
 
-
-
 	@Override
-	public char[] exportConfiguration() throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public byte[] exportConnectorArchive(String connectorTypeIdentifier)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public char[] exportConnectorBinding(String connectorBindingIdentifier)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public char[] exportConnectorType(String connectorTypeIdentifier)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public byte[] exportExtensionModule(String sourceName)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public byte[] exportVDB(String name, String version) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public void extensionModuleModified(String name) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public LogConfiguration getLogConfiguration() throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public void setConnectorBindingProperty(String deployedName,
-			String propertyName, String propertyValue) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public void setLogConfiguration(LogConfiguration config)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public void setLogListener(EmbeddedLogger listener) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public void setProcessProperty(String processIdentifier,
-			String propertyName, String propertyValue) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public Collection<Cache> getCaches(String identifier) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public Collection<? extends ConnectionPool> getConnectionPoolStats(
-			String identifier) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-
-	@Override
-	public Collection<PropertyDefinition> getConnectorTypePropertyDefinitions(
-			String connectorTypeIdentifier) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-
-	@Override
-	public Collection<QueueWorkerPool> getQueueWorkerPools(String identifier)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public Collection<Request> getRequests(String identifier)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-
-	@Override
-	public Collection<Request> getSourceRequests(String identifier)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public Collection<Transaction> getTransactions() throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-
-
-	@Override
-	public void cancelRequest(String identifier) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public void cancelSourceRequest(String identifier) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
 	public void changeVDBStatus(String name, String version, int status)
 			throws AdminException {
 		// rameshTODO Auto-generated method stub
@@ -253,97 +63,10 @@
 	}
 
 	@Override
-	public void clearCache(String cacheIdentifier) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public void restart() throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public void shutdown(int millisToWait) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-
-	@Override
-	public void terminateTransaction(Xid transactionId) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public void terminateTransaction(String transactionId, String sessionId)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public void assignRoleToGroup(String roleIdentifier, String groupIdentifier)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
-	@Override
-	public char[] exportDataRoles(String vdbName, String vdbVersion)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public List<String> getDomainNames() throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public Collection<Group> getGroups(String groupIdentifier)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public Collection<Group> getGroupsForDomain(String domainName)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public Collection<Group> getGroupsForUser(String userIdentifier)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
-	public Collection<Role> getRolesForGroup(String groupIdentifier)
-			throws AdminException {
-		// rameshTODO Auto-generated method stub
-		return null;
-	}
-
-	@Override
 	public String importDataRoles(String vdbName, String vdbVersion,
 			char[] data, AdminOptions options) throws AdminException {
 		// rameshTODO Auto-generated method stub
 		return null;
 	}
 
-	@Override
-	public void removeRoleFromGroup(String roleIdentifier,
-			String groupIdentifier) throws AdminException {
-		// rameshTODO Auto-generated method stub
-		
-	}
-
 }

Modified: branches/JCA/client/src/main/java/org/teiid/adminapi/Transaction.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/Transaction.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/Transaction.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -22,10 +22,7 @@
 
 package org.teiid.adminapi;
 
-import java.util.Date;
 
-import javax.transaction.xa.Xid;
-
 public interface Transaction extends AdminObject {
 
 	/**
@@ -45,13 +42,13 @@
 	 * Return the Xid of the Global transaction.  Will be null for non-Global transactions.
 	 * @return
 	 */
-	Xid getXid();
+	String getXid();
 	
 	
 	/**
 	 * Get the date the transaction was created.
 	 * @return
 	 */
-	Date getCreated();
+	long getCreatedTime();
 	
 }

Added: branches/JCA/client/src/main/java/org/teiid/adminapi/WorkerPoolStatistics.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/WorkerPoolStatistics.java	                        (rev 0)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/WorkerPoolStatistics.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -0,0 +1,73 @@
+/*
+ * 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.adminapi;
+
+public interface WorkerPoolStatistics extends AdminObject {
+ 
+	/**
+	 * Current active thread count
+	 * @return
+	 */
+	public int getActiveThreads();
+	
+	/**
+	 * Highest Active threads recorded so far
+	 * @return
+	 */
+	public int getHighestActiveThreads();
+	 
+	 
+	 /**
+	  * Queue Name
+	  * @return
+	  */
+	 public String getQueueName();
+	 
+	 
+	 /**
+	  * Max number of active threads allowed
+	  * @return
+	  */
+	 public int getMaxThreads();
+	
+	/** 
+     * @return Returns the number of requests queued.
+     * @since 4.3
+     */
+    public int getQueued();
+    
+    /**
+     * @return The number of completed tasks
+     */
+    long getTotalCompleted();
+    
+   
+    /**
+     * @return The number of submitted tasks
+     */
+    long getTotalSubmitted();
+    
+    /** 
+     * @return Returns the highest queue size
+     */
+    public int getHighestQueued();
+}

Added: branches/JCA/client/src/main/java/org/teiid/adminapi/impl/ConnectionPoolStatisticsMetadata.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/impl/ConnectionPoolStatisticsMetadata.java	                        (rev 0)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/impl/ConnectionPoolStatisticsMetadata.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -0,0 +1,133 @@
+/*
+ * 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.adminapi.impl;
+
+import org.jboss.managed.api.annotation.ManagementProperty;
+import org.teiid.adminapi.ConnectionPoolStatistics;
+
+public class ConnectionPoolStatisticsMetadata extends AdminObjectImpl implements ConnectionPoolStatistics {
+
+	private static final long serialVersionUID = 4420845831075045579L;
+	private long availableConnectionCount;
+	private int connectionCount;
+	private int connectionCreatedCount;
+	private int connectionDestroyedCount;
+	private long inUseConnectionCount;
+	private long maxConnectionsInUseCount;
+	private int maxSize;
+	private int minSize;
+	
+	
+	@Override
+	@ManagementProperty(description="The maximum number of connections that are available", readOnly=true)
+	public long getAvailableConnectionCount() {
+		return availableConnectionCount;
+	}
+
+	@Override
+	@ManagementProperty(description="The number of connections that are currently in the pool", readOnly=true)
+	public int getConnectionCount() {
+		return connectionCount;
+	}
+
+	@Override
+	@ManagementProperty(description="The number of connections that have been created since the connector was last started", readOnly=true)
+	public int getConnectionCreatedCount() {
+		return connectionCreatedCount;
+	}
+
+	@Override
+	@ManagementProperty(description="The number of connections that have been destroyed since the connector was last started", readOnly=true)
+	public int getConnectionDestroyedCount() {
+		return connectionDestroyedCount;
+	}
+
+	@Override
+	@ManagementProperty(description="The number of connections that are currently in use", readOnly=true)
+	public long getInUseConnectionCount() {
+		return inUseConnectionCount;
+	}
+
+	@Override
+	@ManagementProperty(description="The most connections that have been simultaneously in use since this connector was started", readOnly=true)
+	public long getMaxConnectionsInUseCount() {
+		return maxConnectionsInUseCount;
+	}
+
+	@Override
+	@ManagementProperty(description="Max configured size", readOnly=true)
+	public int getMaxSize() {
+		return maxSize;
+	}
+
+	@Override
+	@ManagementProperty(description="Min Configured Size", readOnly=true)
+	public int getMinSize() {
+		return minSize;
+	}
+
+	public void setMaxSize(int maxSize) {
+		this.maxSize = maxSize;
+	}
+
+	public void setAvailableConnectionCount(long availableConnectionCount) {
+		this.availableConnectionCount = availableConnectionCount;
+	}
+
+	public void setConnectionCount(int connectionCount) {
+		this.connectionCount = connectionCount;
+	}
+
+	public void setConnectionCreatedCount(int connectionCreatedCount) {
+		this.connectionCreatedCount = connectionCreatedCount;
+	}
+
+	public void setConnectionDestroyedCount(int connectionDestroyedCount) {
+		this.connectionDestroyedCount = connectionDestroyedCount;
+	}
+
+	public void setInUseConnectionCount(long inUseConnectionCount) {
+		this.inUseConnectionCount = inUseConnectionCount;
+	}
+
+	public void setMaxConnectionsInUseCount(long maxConnectionsInUseCount) {
+		this.maxConnectionsInUseCount = maxConnectionsInUseCount;
+	}
+
+	public void setMinSize(int minSize) {
+		this.minSize = minSize;
+	}
+	
+    public String toString() {
+    	StringBuilder str = new StringBuilder();
+        str.append("ConnectionPoolStatisticsMetadata:"); //$NON-NLS-1$
+        str.append("  availableConnectionCount = " + availableConnectionCount); //$NON-NLS-1$
+        str.append("; connectionCount = " + connectionCount); //$NON-NLS-1$
+        str.append("; connectionCreatedCount = " + connectionCreatedCount); //$NON-NLS-1$
+        str.append("; connectionDestroyedCount = " + connectionDestroyedCount);     //$NON-NLS-1$
+        str.append("; inUseConnectionCount = " + inUseConnectionCount);     //$NON-NLS-1$
+        str.append("; maxConnectionsInUseCount = " + maxConnectionsInUseCount);     //$NON-NLS-1$
+        str.append("; maxSize = " + maxSize);     //$NON-NLS-1$
+        str.append("; minSize = " + minSize);     //$NON-NLS-1$
+        return str.toString();
+    }   	
+}

Added: branches/JCA/client/src/main/java/org/teiid/adminapi/impl/PropertyDefinitionMetadata.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/impl/PropertyDefinitionMetadata.java	                        (rev 0)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/impl/PropertyDefinitionMetadata.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -0,0 +1,215 @@
+/*
+ * 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.adminapi.impl;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Collection;
+
+import org.teiid.adminapi.PropertyDefinition;
+
+import com.metamatrix.admin.AdminPlugin;
+
+
+public class PropertyDefinitionMetadata extends AdminObjectImpl implements PropertyDefinition {
+	private static final long serialVersionUID = 6612838530524627205L;
+    private Collection allowedValues = new ArrayList();
+    private Object defaultValue = null;
+    private String description = null;
+    private String displayName = null;
+    private String propertyTypeClassName = String.class.getName();
+    private RestartType requiresRestart = RestartType.NONE;
+    private boolean expert = false;
+    private boolean masked = false;
+    private boolean modifiable = true;
+    private boolean required = false;
+    
+    
+    /**
+     * @see java.lang.Object#toString()
+     */
+    public String toString() {
+        StringBuffer result = new StringBuffer();
+        result.append(AdminPlugin.Util.getString("MMPropertyDefinition.Display_name")).append(getDisplayName()); //$NON-NLS-1$
+        result.append(AdminPlugin.Util.getString("MMPropertyDefinition.Description")).append(getDescription()); //$NON-NLS-1$
+        result.append(AdminPlugin.Util.getString("MMPropertyDefinition.Property_type_class_name")).append(getPropertyTypeClassName()); //$NON-NLS-1$
+        result.append(AdminPlugin.Util.getString("MMPropertyDefinition.Default_value")).append(getDefaultValue()); //$NON-NLS-1$
+        result.append(AdminPlugin.Util.getString("MMPropertyDefinition.Constrained_to_allow_values")).append(isConstrainedToAllowedValues()); //$NON-NLS-1$
+        result.append(AdminPlugin.Util.getString("MMPropertyDefinition.Allowed_values")).append(getAllowedValues()); //$NON-NLS-1$
+        result.append(AdminPlugin.Util.getString("MMPropertyDefinition.Required")).append(isRequired()); //$NON-NLS-1$
+        result.append(AdminPlugin.Util.getString("MMPropertyDefinition.Expert")).append(isExpert()); //$NON-NLS-1$
+        result.append(AdminPlugin.Util.getString("MMPropertyDefinition.Masked")).append(isMasked()); //$NON-NLS-1$
+        result.append(AdminPlugin.Util.getString("MMPropertyDefinition.Modifiable")).append(isModifiable()); //$NON-NLS-1$
+        result.append(AdminPlugin.Util.getString("MMPropertyDefinition.RequiresRestart")).append(getRequiresRestart()); //$NON-NLS-1$
+        return result.toString();
+    }
+    
+    /** 
+     * @see org.teiid.adminapi.PropertyDefinition#getAllowedValues()
+     */
+    public Collection getAllowedValues() {
+        return allowedValues;
+    }
+    
+    /** 
+     * @see org.teiid.adminapi.PropertyDefinition#getDefaultValue()
+     */
+    public Object getDefaultValue() {
+        return defaultValue;
+    }
+
+    /** 
+     * @see org.teiid.adminapi.PropertyDefinition#getDescription()
+     */
+    public String getDescription() {
+        return description;
+    }
+
+    /** 
+     * @see org.teiid.adminapi.PropertyDefinition#getDisplayName()
+     */
+    public String getDisplayName() {
+        return displayName;
+    }
+
+    /** 
+     * @see org.teiid.adminapi.PropertyDefinition#getPropertyTypeClassName()
+     */
+    public String getPropertyTypeClassName() {
+        return propertyTypeClassName;
+    }
+
+
+    /** 
+     * @see org.teiid.adminapi.PropertyDefinition#getRequiresRestart()
+     */
+    public RestartType getRequiresRestart() {
+        return requiresRestart;
+    }
+
+    /** 
+     * @see org.teiid.adminapi.PropertyDefinition#isExpert()
+     * @since 4.3
+     */
+    public boolean isExpert() {
+        return expert;
+    }
+
+    /** 
+     * @see org.teiid.adminapi.PropertyDefinition#isMasked()
+     */
+    public boolean isMasked() {
+        return masked;
+    }
+
+    /** 
+     * @see org.teiid.adminapi.PropertyDefinition#isModifiable()
+     */
+    public boolean isModifiable() {
+        return modifiable;
+    }
+
+    /** 
+     * @see org.teiid.adminapi.PropertyDefinition#isRequired()
+     */
+    public boolean isRequired() {
+        return required;
+    }
+
+    /** 
+     * @param allowedValues The allowedValues to set.
+     */
+    public void setAllowedValues(Collection allowedValues) {
+        this.allowedValues = allowedValues;
+    }
+
+    /** 
+     * @param defaultValue The defaultValue to set.
+     */
+    public void setDefaultValue(Serializable defaultValue) {
+        this.defaultValue = defaultValue;
+    }
+
+    /** 
+     * @param description The description to set.
+     */
+    public void setDescription(String description) {
+        this.description = description;
+    }
+
+    
+    /** 
+     * @param displayName The displayName to set.
+     */
+    public void setDisplayName(String displayName) {
+        this.displayName = displayName;
+    }
+
+    
+    /** 
+     * @param expert The value of expert to set.
+     */
+    public void setExpert(boolean expert) {
+        this.expert = expert;
+    }
+
+    /** 
+     * @param masked The value of masked to set.
+     */
+    public void setMasked(boolean masked) {
+        this.masked = masked;
+    }
+    /** 
+     * @param modifiable The value of modifiable to set.
+     */
+    public void setModifiable(boolean modifiable) {
+        this.modifiable = modifiable;
+    }
+
+    /** 
+     * @param propertyTypeClassName The propertyTypeName to set.
+     */
+    public void setPropertyTypeClassName(String propertyTypeClassName) {
+        this.propertyTypeClassName = propertyTypeClassName;
+    }
+    
+    
+    /** 
+     * @param required The value of required to set.
+     */
+    public void setRequired(boolean required) {
+        this.required = required;
+    }
+    
+    /** 
+     * @param requiresRestart The value of requiresRestart to set.
+     */
+    public void setRequiresRestart(RestartType requiresRestart) {
+        this.requiresRestart = requiresRestart;
+    }
+
+	@Override
+	public boolean isConstrainedToAllowedValues() {
+		return allowedValues != null && !allowedValues.isEmpty();
+	}
+}

Added: branches/JCA/client/src/main/java/org/teiid/adminapi/impl/RequestMetadata.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/impl/RequestMetadata.java	                        (rev 0)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/impl/RequestMetadata.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -0,0 +1,174 @@
+/*
+ * 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.adminapi.impl;
+
+import java.io.Serializable;
+import java.util.Date;
+
+import org.jboss.managed.api.annotation.ManagementObject;
+import org.jboss.managed.api.annotation.ManagementProperty;
+import org.jboss.metatype.api.annotations.MetaMapping;
+import org.teiid.adminapi.Request;
+
+import com.metamatrix.dqp.message.RequestID;
+
+
+ at ManagementObject
+ at MetaMapping(RequestMetadataMapper.class)
+public class RequestMetadata extends AdminObjectImpl implements Request, Serializable {
+
+	private static final long serialVersionUID = -2779106368517784259L;
+	
+	private long executionId;
+	private long sessionId;
+    private String command;
+    private long createdTime;
+    private long processTime;
+    private boolean sourceRequest;
+	private int nodeID = Integer.MIN_VALUE;
+    private String transactionId;
+    
+    // Derived state
+    private RequestID requestId;
+    
+    @Override
+    @ManagementProperty(description="Unique Identifier for Request", readOnly=true)
+    public long getExecutionId() {
+		return executionId;
+	}
+    
+    public void setExecutionId(long id) {
+		this.executionId = id;
+	}    
+    
+    @Override
+    @ManagementProperty(description="Session ID", readOnly=true)
+    public long getSessionId() {
+        return this.sessionId;
+    }
+    
+    public void setSessionId(long session) {
+        this.sessionId = session;
+    }
+    
+    @Override
+    @ManagementProperty(description="Time when request submitted", readOnly=true)
+    public long getCreatedTime() {
+        return this.createdTime;
+    }
+    
+    public void setCreatedTiime(long time) {
+    	this.createdTime = time;
+    }
+
+    @Override
+    @ManagementProperty(description="Processing time for the request", readOnly=true)
+    public long getProcessingTime() {
+        return this.processTime;
+    }
+    
+    public void setProcessingTime(long time) {
+        this.processTime = time;
+    }    
+
+    @Override
+    @ManagementProperty(description="Executing Command", readOnly=true)
+    public String getCommand() {
+        return this.command;
+    }
+    
+    public void setCommand(String cmd) {
+        this.command = cmd;
+    }    
+    
+    @Override
+    @ManagementProperty(description="Is this Connector level request", readOnly=true)
+    public boolean sourceRequest() {
+		return sourceRequest;
+	}
+
+	public void setSourceRequest(boolean sourceRequest) {
+		this.sourceRequest = sourceRequest;
+	}    
+        
+	@Override
+	@ManagementProperty(description="Node Id", readOnly=true)
+    public int getNodeId() {
+        return this.nodeID;
+    }
+    
+    public void setNodeId(int nodeID) {
+        this.nodeID = nodeID;
+    }
+    
+	@Override
+	@ManagementProperty(description="Get Transaction XID if transaction involved", readOnly=true)
+	public String getTransactionId() {
+		return this.transactionId;
+	}
+
+	public void setTransactionId(String id) {
+		this.transactionId = id;
+	}
+	
+	public RequestID getRequestId() {
+		if (this.requestId == null) {
+			this.requestId = new RequestID(this.sessionId, this.executionId);
+		}
+		return this.requestId;
+	}
+	
+    @Override
+	public boolean equals(Object obj) {
+    	if (!(obj instanceof RequestMetadata)) {
+    		return false;
+    	}
+    	RequestMetadata value = (RequestMetadata)obj;
+    	if (!sourceRequest()) {
+    		return sessionId == value.sessionId && executionId == value.executionId;
+    	}
+		return sessionId == value.sessionId && executionId == value.executionId && nodeID == value.nodeID;
+	}
+    
+    public int hashCode() {
+    	return getRequestId().hashCode();
+    }    
+    
+    public String toString() {
+    	StringBuilder str = new StringBuilder();
+    	str.append("Request: sessionid=").append(sessionId);
+    	str.append("; executionId=").append(executionId);
+    	if (nodeID != Integer.MIN_VALUE) {
+    		str.append("; nodeId=").append(nodeID);
+    	}
+    	if (transactionId != null) {
+    		str.append("; transactionId=").append(transactionId);
+    	}
+    	str.append("; sourceRequest=").append(sourceRequest);
+    	str.append("; createdTime=").append(new Date(createdTime));
+    	str.append("; processingTime=").append(new Date(processTime));
+    	str.append("; command=").append(command); 
+    	
+    	return str.toString();
+    }
+}

Added: branches/JCA/client/src/main/java/org/teiid/adminapi/impl/RequestMetadataMapper.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/impl/RequestMetadataMapper.java	                        (rev 0)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/impl/RequestMetadataMapper.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -0,0 +1,108 @@
+/*
+ * 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.adminapi.impl;
+
+import java.lang.reflect.Type;
+
+import org.jboss.metatype.api.types.CompositeMetaType;
+import org.jboss.metatype.api.types.MetaType;
+import org.jboss.metatype.api.types.SimpleMetaType;
+import org.jboss.metatype.api.values.CompositeValue;
+import org.jboss.metatype.api.values.CompositeValueSupport;
+import org.jboss.metatype.api.values.MetaValue;
+import org.jboss.metatype.api.values.MetaValueFactory;
+import org.jboss.metatype.api.values.SimpleValueSupport;
+import org.jboss.metatype.plugins.types.MutableCompositeMetaType;
+import org.jboss.metatype.spi.values.MetaMapper;
+
+public class RequestMetadataMapper extends MetaMapper<RequestMetadata> {
+	private static final MutableCompositeMetaType metaType;
+	private static final MetaValueFactory metaValueFactory = MetaValueFactory.getInstance();
+	
+	static {
+		metaType = new MutableCompositeMetaType(RequestMetadata.class.getName(), "The Session domain meta data");
+		metaType.addItem("executionId", "executionId", SimpleMetaType.LONG_PRIMITIVE);
+		metaType.addItem("sessionId", "sessionId", SimpleMetaType.LONG_PRIMITIVE);
+		metaType.addItem("createdTime", "createdTime", SimpleMetaType.LONG_PRIMITIVE);
+		metaType.addItem("processingTime", "processingTime", SimpleMetaType.LONG_PRIMITIVE);
+		metaType.addItem("command", "command", SimpleMetaType.STRING);
+		metaType.addItem("sourceRequest", "sourceRequest", SimpleMetaType.BOOLEAN_PRIMITIVE);
+		metaType.addItem("nodeId", "nodeId", SimpleMetaType.INTEGER_PRIMITIVE);
+		metaType.addItem("transactionId", "transactionId", SimpleMetaType.STRING);
+		metaType.freeze();
+	}
+	
+	@Override
+	public Type mapToType() {
+		return RequestMetadata.class;
+	}
+	
+	@Override
+	public MetaType getMetaType() {
+		return metaType;
+	}
+	
+	@Override
+	public MetaValue createMetaValue(MetaType metaType, RequestMetadata object) {
+		if (object == null)
+			return null;
+		if (metaType instanceof CompositeMetaType) {
+			CompositeMetaType composite = (CompositeMetaType) metaType;
+			CompositeValueSupport request = new CompositeValueSupport(composite);
+			
+			request.set("executionId", SimpleValueSupport.wrap(object.getExecutionId()));
+			request.set("sessionId", SimpleValueSupport.wrap(object.getSessionId()));
+			request.set("createdTime", SimpleValueSupport.wrap(object.getCreatedTime()));
+			request.set("processingTime", SimpleValueSupport.wrap(object.getProcessingTime()));
+			request.set("command", SimpleValueSupport.wrap(object.getCommand()));
+			request.set("sourceRequest", SimpleValueSupport.wrap(object.sourceRequest()));
+			request.set("nodeId", SimpleValueSupport.wrap(object.getNodeId()));
+			request.set("transactionId",SimpleValueSupport.wrap(object.getTransactionId()));
+			
+			return request;
+		}
+		throw new IllegalArgumentException("Cannot convert request " + object);
+	}
+
+	@Override
+	public RequestMetadata unwrapMetaValue(MetaValue metaValue) {
+		if (metaValue == null)
+			return null;
+
+		if (metaValue instanceof CompositeValue) {
+			CompositeValue compositeValue = (CompositeValue) metaValue;
+			
+			RequestMetadata request = new RequestMetadata();
+			request.setExecutionId((Long) metaValueFactory.unwrap(compositeValue.get("executionId")));
+			request.setSessionId((Long) metaValueFactory.unwrap(compositeValue.get("sessionId")));
+			request.setCreatedTiime((Long) metaValueFactory.unwrap(compositeValue.get("createdTime")));
+			request.setProcessingTime((Long) metaValueFactory.unwrap(compositeValue.get("processingTime")));
+			request.setCommand((String) metaValueFactory.unwrap(compositeValue.get("command")));
+			request.setSourceRequest((Boolean) metaValueFactory.unwrap(compositeValue.get("sourceRequest")));
+			request.setNodeId((Integer) metaValueFactory.unwrap(compositeValue.get("nodeId")));
+			request.setTransactionId((String) metaValueFactory.unwrap(compositeValue.get("transactionId")));
+			return request;
+		}
+		throw new IllegalStateException("Unable to unwrap request " + metaValue);
+	}
+
+}

Modified: branches/JCA/client/src/main/java/org/teiid/adminapi/impl/SessionMetadata.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/impl/SessionMetadata.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/impl/SessionMetadata.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -21,7 +21,8 @@
  */
 package org.teiid.adminapi.impl;
 
-import org.jboss.managed.api.annotation.ManagementComponent;
+import java.util.Date;
+
 import org.jboss.managed.api.annotation.ManagementObject;
 import org.jboss.managed.api.annotation.ManagementObjectID;
 import org.jboss.managed.api.annotation.ManagementProperty;
@@ -32,7 +33,7 @@
 /**
  * Add and delete properties also in the Mapper class for correct wrapping for profile service.
  */
- at ManagementObject(componentType=@ManagementComponent(type="teiid",subtype="session"))
+ at ManagementObject
 @MetaMapping(SessionMetadataMapper.class)
 public class SessionMetadata extends AdminObjectImpl implements Session {
 
@@ -148,4 +149,19 @@
 	public void setSecurityDomain(String domain) {
 		this.securityDomain = domain;
 	}	
+	
+    public String toString() {
+    	StringBuilder str = new StringBuilder();
+    	str.append("session: sessionid=").append(sessionId);
+    	str.append("; userName=").append(userName);
+    	str.append("; vdbName=").append(vdbName);
+    	str.append("; vdbVersion=").append(vdbVersion);
+    	str.append("; createdTime=").append(new Date(createdTime));
+    	str.append("; applicationName=").append(applicationName);
+    	str.append("; clientHostName=").append(clientHostName);
+    	str.append("; IPAddress=").append(ipAddress);
+    	str.append("; securityDomain=").append(securityDomain); 
+    	str.append("; lastPingTime=").append(new Date(lastPingTime));
+    	return str.toString();
+    }	
 }

Modified: branches/JCA/client/src/main/java/org/teiid/adminapi/impl/SessionMetadataMapper.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/impl/SessionMetadataMapper.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/impl/SessionMetadataMapper.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -33,14 +33,13 @@
 import org.jboss.metatype.api.values.SimpleValueSupport;
 import org.jboss.metatype.plugins.types.MutableCompositeMetaType;
 import org.jboss.metatype.spi.values.MetaMapper;
-import org.teiid.adminapi.VDB;
 
 public class SessionMetadataMapper extends MetaMapper<SessionMetadata> {
 	private static final MutableCompositeMetaType metaType;
 	private static final MetaValueFactory metaValueFactory = MetaValueFactory.getInstance();
 	
 	static {
-		metaType = new MutableCompositeMetaType(VDB.class.getName(), "The Session domain meta data");
+		metaType = new MutableCompositeMetaType(SessionMetadata.class.getName(), "The Session domain meta data");
 		metaType.addItem("applicationName", "applicationName", SimpleMetaType.STRING);
 		metaType.addItem("createdTime", "createdTime", SimpleMetaType.LONG_PRIMITIVE);
 		metaType.addItem("clientHostName", "clientHostName", SimpleMetaType.STRING);

Added: branches/JCA/client/src/main/java/org/teiid/adminapi/impl/TransactionMetadata.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/impl/TransactionMetadata.java	                        (rev 0)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/impl/TransactionMetadata.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -0,0 +1,94 @@
+/*
+ * 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.adminapi.impl;
+
+import java.util.Date;
+
+import org.jboss.managed.api.annotation.ManagementObject;
+import org.jboss.managed.api.annotation.ManagementProperty;
+import org.jboss.metatype.api.annotations.MetaMapping;
+import org.teiid.adminapi.Transaction;
+
+import com.metamatrix.admin.AdminPlugin;
+
+ at ManagementObject
+ at MetaMapping(TransactionMetadataMapper.class)
+public class TransactionMetadata extends AdminObjectImpl implements Transaction {
+
+	private static final long serialVersionUID = -8588785315218789068L;
+	private long associatedSession;
+	private String scope;
+	private String xid;
+	private long createdTime;
+
+	@Override
+	@ManagementProperty(description="Session ID", readOnly=true)
+	public long getAssociatedSession() {
+		return associatedSession;
+	}
+
+	public void setAssociatedSession(long associatedSession) {
+		this.associatedSession = associatedSession;
+	}
+
+	@Override
+	@ManagementProperty(description="Scope", readOnly=true)
+	public String getScope() {
+		return scope;
+	}
+
+	public void setScope(String scope) {
+		this.scope = scope;
+	}
+
+	@Override
+	@ManagementProperty(description="XID", readOnly=true)
+	public String getXid() {
+		return xid;
+	}
+
+	public void setXid(String xid) {
+		this.xid = xid;
+	}
+	
+	@Override
+	@ManagementProperty(description="Transaction created time", readOnly=true)
+	public long getCreatedTime() {
+		return createdTime;
+	}
+	
+	public void setCreatedTime(long time) {
+		this.createdTime = time;
+	}
+
+	@Override
+	public String toString() {
+        StringBuffer result = new StringBuffer();
+        result.append(AdminPlugin.Util.getString("TransactionImpl.associatedSession")).append(associatedSession); //$NON-NLS-1$
+        result.append(AdminPlugin.Util.getString("TransactionImpl.scope")).append(scope); //$NON-NLS-1$
+        result.append(AdminPlugin.Util.getString("TransactionImpl.xid")).append(xid); //$NON-NLS-1$
+        result.append(AdminPlugin.Util.getString("TransactionImpl.createdTime")).append(new Date(createdTime)); //$NON-NLS-1$
+        return result.toString();
+	}
+
+}

Added: branches/JCA/client/src/main/java/org/teiid/adminapi/impl/TransactionMetadataMapper.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/impl/TransactionMetadataMapper.java	                        (rev 0)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/impl/TransactionMetadataMapper.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -0,0 +1,96 @@
+/*
+ * 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.adminapi.impl;
+
+import java.lang.reflect.Type;
+
+import org.jboss.metatype.api.types.CompositeMetaType;
+import org.jboss.metatype.api.types.MetaType;
+import org.jboss.metatype.api.types.SimpleMetaType;
+import org.jboss.metatype.api.values.CompositeValue;
+import org.jboss.metatype.api.values.CompositeValueSupport;
+import org.jboss.metatype.api.values.MetaValue;
+import org.jboss.metatype.api.values.MetaValueFactory;
+import org.jboss.metatype.api.values.SimpleValueSupport;
+import org.jboss.metatype.plugins.types.MutableCompositeMetaType;
+import org.jboss.metatype.spi.values.MetaMapper;
+
+public class TransactionMetadataMapper extends MetaMapper<TransactionMetadata> {
+	private static final MutableCompositeMetaType metaType;
+	private static final MetaValueFactory metaValueFactory = MetaValueFactory.getInstance();
+	
+	static {
+		metaType = new MutableCompositeMetaType(TransactionMetadata.class.getName(), "The Session domain meta data");
+		metaType.addItem("associatedSession", "associatedSession", SimpleMetaType.LONG_PRIMITIVE);
+		metaType.addItem("createdTime", "createdTime", SimpleMetaType.LONG_PRIMITIVE);
+		metaType.addItem("scope", "scope", SimpleMetaType.STRING);
+		metaType.addItem("xid", "xid", SimpleMetaType.STRING);
+		metaType.freeze();
+	}
+	
+	@Override
+	public Type mapToType() {
+		return TransactionMetadata.class;
+	}
+	
+	@Override
+	public MetaType getMetaType() {
+		return metaType;
+	}
+	
+	@Override
+	public MetaValue createMetaValue(MetaType metaType, TransactionMetadata object) {
+		if (object == null)
+			return null;
+		if (metaType instanceof CompositeMetaType) {
+			CompositeMetaType composite = (CompositeMetaType) metaType;
+			CompositeValueSupport transaction = new CompositeValueSupport(composite);
+			
+			transaction.set("associatedSession", SimpleValueSupport.wrap(object.getAssociatedSession()));
+			transaction.set("createdTime", SimpleValueSupport.wrap(object.getCreatedTime()));
+			transaction.set("scope", SimpleValueSupport.wrap(object.getScope()));
+			transaction.set("xid", SimpleValueSupport.wrap(object.getXid()));
+			
+			return transaction;
+		}
+		throw new IllegalArgumentException("Cannot convert session " + object);
+	}
+
+	@Override
+	public TransactionMetadata unwrapMetaValue(MetaValue metaValue) {
+		if (metaValue == null)
+			return null;
+
+		if (metaValue instanceof CompositeValue) {
+			CompositeValue compositeValue = (CompositeValue) metaValue;
+			
+			TransactionMetadata transaction = new TransactionMetadata();
+			transaction.setAssociatedSession((Long) metaValueFactory.unwrap(compositeValue.get("associatedSession")));
+			transaction.setCreatedTime((Long) metaValueFactory.unwrap(compositeValue.get("createdTime")));
+			transaction.setScope((String) metaValueFactory.unwrap(compositeValue.get("scope")));
+			transaction.setXid((String) metaValueFactory.unwrap(compositeValue.get("xid")));
+			return transaction;
+		}
+		throw new IllegalStateException("Unable to unwrap session " + metaValue);
+	}
+}

Added: branches/JCA/client/src/main/java/org/teiid/adminapi/impl/WorkerPoolStatisticsMetadata.java
===================================================================
--- branches/JCA/client/src/main/java/org/teiid/adminapi/impl/WorkerPoolStatisticsMetadata.java	                        (rev 0)
+++ branches/JCA/client/src/main/java/org/teiid/adminapi/impl/WorkerPoolStatisticsMetadata.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -0,0 +1,142 @@
+/*
+ * 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.adminapi.impl;
+
+import org.jboss.managed.api.annotation.ManagementObject;
+import org.jboss.managed.api.annotation.ManagementProperty;
+import org.teiid.adminapi.WorkerPoolStatistics;
+
+/**
+ * This class is a holder for all the statistics gathered about a worker pool.
+ */
+ at ManagementObject
+public class WorkerPoolStatisticsMetadata extends AdminObjectImpl implements WorkerPoolStatistics {
+
+	private static final long serialVersionUID = -4917902925523802295L;
+
+    // Current state    
+    private int queued;
+    private int highestQueued;
+    private int maxThreads;
+    private int activeThreads;
+    private int highestActiveThreads;
+    private long totalSubmitted;
+    private long totalCompleted;
+            
+    @Override
+    @ManagementProperty(description="Number of Active Threads", readOnly=true)
+    public int getActiveThreads() {
+		return activeThreads;
+	}
+    
+    @Override
+    @ManagementProperty(description="Highest active threads", readOnly=true)
+    public int getHighestActiveThreads() {
+		return highestActiveThreads;
+	}
+    
+    @Override
+    @ManagementProperty(description="Total Completed Tasks", readOnly=true)
+    public long getTotalCompleted() {
+		return totalCompleted;
+	}
+    
+    @Override
+    @ManagementProperty(description="Total submitted Tasks", readOnly=true)
+    public long getTotalSubmitted() {
+		return totalSubmitted;
+	}
+    
+    @Override
+    @ManagementProperty(description="Queue Name", readOnly=true)
+    public String getQueueName() {
+		return getName();
+	}
+    
+    @Override
+    @ManagementProperty(description="Currently Queued Tasks", readOnly=true)
+    public int getQueued() {
+		return queued;
+	}
+    
+    @Override
+    @ManagementProperty(description="Highest Queued Tasks", readOnly=true)
+    public int getHighestQueued() {
+		return highestQueued;
+	}
+    
+    @Override
+    @ManagementProperty(description="Max Threads", readOnly=true)
+    public int getMaxThreads() {
+		return maxThreads;
+	}
+
+	public void setQueued(int queued) {
+		this.queued = queued;
+	}
+
+	public void setHighestQueued(int highestQueued) {
+		this.highestQueued = highestQueued;
+	}
+
+	public void setMaxThreads(int maxThreads) {
+		this.maxThreads = maxThreads;
+	}
+
+	public void setActiveThreads(int activeThreads) {
+		this.activeThreads = activeThreads;
+	}
+
+	public void setHighestActiveThreads(int highestActiveThreads) {
+		this.highestActiveThreads = highestActiveThreads;
+	}
+
+	public void setTotalSubmitted(long totalSubmitted) {
+		this.totalSubmitted = totalSubmitted;
+	}
+
+	public void setTotalCompleted(long totalCompleted) {
+		this.totalCompleted = totalCompleted;
+	}
+	
+    public void setQueueName(String name) {
+		setName(name);
+	}	
+    
+    public String toString() {
+    	StringBuilder str = new StringBuilder();
+        
+        str.append("WorkerPoolStats:"); //$NON-NLS-1$
+        str.append("  queue-name = " + getName()); //$NON-NLS-1$
+        str.append("; queued = " + queued); //$NON-NLS-1$
+        str.append("; highestQueued = " + highestQueued); //$NON-NLS-1$
+        str.append("; maxThreads = " + maxThreads);     //$NON-NLS-1$
+        str.append("; activeThreads = " + activeThreads);     //$NON-NLS-1$
+        str.append("; highestActiveThreads = " + highestActiveThreads);     //$NON-NLS-1$
+        str.append("; totalSubmitted = " + totalSubmitted);     //$NON-NLS-1$
+        str.append("; totalCompleted = " + totalCompleted);     //$NON-NLS-1$
+        return str.toString();
+    }    
+
+}
+

Modified: branches/JCA/client/src/main/resources/com/metamatrix/admin/i18n.properties
===================================================================
--- branches/JCA/client/src/main/resources/com/metamatrix/admin/i18n.properties	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/main/resources/com/metamatrix/admin/i18n.properties	2010-01-08 16:42:28 UTC (rev 1721)
@@ -200,6 +200,7 @@
 TransactionImpl.scope=\n\ Scope:\ 
 TransactionImpl.status=\n\ Status:\ 
 TransactionImpl.xid=\n\ Xid:\ 
+TransactionImpl.createdTime=\n\ Created Time:\ 
 
 AdminStatus.CODE_UNKNOWN=Unknown.
 AdminStatus.CODE_SUCCESS=Success.

Modified: branches/JCA/client/src/test/java/com/metamatrix/common/comm/platform/socket/client/TestSocketServerConnection.java
===================================================================
--- branches/JCA/client/src/test/java/com/metamatrix/common/comm/platform/socket/client/TestSocketServerConnection.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/client/src/test/java/com/metamatrix/common/comm/platform/socket/client/TestSocketServerConnection.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -97,12 +97,6 @@
 			}
 			return null;
 		}
-
-		//## JDBC4.0-begin ##
-		@Override
-		//## JDBC4.0-end ##
-		public void terminate(SessionToken sessionId) {
-		}
 	}
 
 	/**

Modified: branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/StatsCapturingWorkManager.java
===================================================================
--- branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/StatsCapturingWorkManager.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/StatsCapturingWorkManager.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -38,6 +38,8 @@
 import javax.resource.spi.work.WorkManager;
 import javax.resource.spi.work.WorkRejectedException;
 
+import org.teiid.adminapi.impl.WorkerPoolStatisticsMetadata;
+
 import com.metamatrix.common.CommonPlugin;
 import com.metamatrix.common.log.LogManager;
 import com.metamatrix.common.util.LogConstants;
@@ -155,17 +157,17 @@
 		}
 	}
 		
-	public WorkerPoolStats getStats() {
-		WorkerPoolStats stats = new WorkerPoolStats();
-		stats.name = poolName;
-		stats.queued = queue.size();
-		stats.highestQueued = highestQueueSize;
-		stats.activeThreads = this.activeCount;
-		stats.maxThreads = this.maximumPoolSize;
-		stats.totalSubmitted = this.submittedCount;
-		stats.highestActiveThreads = this.highestActiveCount;
-		stats.totalCompleted = this.completedCount;
-		return stats;
+	public WorkerPoolStatisticsMetadata getStats() {
+		WorkerPoolStatisticsMetadata stats = new WorkerPoolStatisticsMetadata();
+		stats.setName(poolName);
+		stats.setQueued(queue.size());
+		stats.setHighestQueued(highestQueueSize);
+		stats.setActiveThreads(this.activeCount);
+		stats.setMaxThreads(this.maximumPoolSize);
+		stats.setTotalSubmitted(this.submittedCount);
+		stats.setHighestActiveThreads(this.highestActiveCount);
+		stats.setTotalCompleted(this.completedCount);
+		return stats;		
 	}
 	
 	public void shutdown() {

Modified: branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/WorkerPool.java
===================================================================
--- branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/WorkerPool.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/WorkerPool.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -27,6 +27,8 @@
 import java.util.concurrent.ScheduledFuture;
 import java.util.concurrent.TimeUnit;
 
+import org.teiid.adminapi.impl.WorkerPoolStatisticsMetadata;
+
 public interface WorkerPool extends Executor {
 	
 	void shutdown();
@@ -38,7 +40,7 @@
 
 	boolean isTerminated();
 
-	WorkerPoolStats getStats();
+	WorkerPoolStatisticsMetadata getStats();
 	
 	boolean hasWork();
 	

Modified: branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/WorkerPoolFactory.java
===================================================================
--- branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/WorkerPoolFactory.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/WorkerPoolFactory.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -40,6 +40,8 @@
 import java.util.concurrent.TimeUnit;
 import java.util.concurrent.atomic.AtomicInteger;
 
+import org.teiid.adminapi.impl.WorkerPoolStatisticsMetadata;
+
 import com.metamatrix.common.CommonPlugin;
 import com.metamatrix.common.log.LogManager;
 import com.metamatrix.common.util.LogConstants;
@@ -275,16 +277,16 @@
 		}
 		
 		@Override
-		public WorkerPoolStats getStats() {
-			WorkerPoolStats stats = new WorkerPoolStats();
-			stats.name = poolName;
-			stats.queued = queue.size();
-			stats.highestQueued = highestQueueSize;
-			stats.activeThreads = getActiveCount();
-			stats.maxThreads = this.maximumPoolSize;
-			stats.totalSubmitted = getSubmittedCount();
-			stats.highestActiveThreads = getLargestPoolSize();
-			stats.totalCompleted = getCompletedCount();
+		public WorkerPoolStatisticsMetadata getStats() {
+			WorkerPoolStatisticsMetadata stats = new WorkerPoolStatisticsMetadata();
+			stats.setName(poolName);
+			stats.setQueued(queue.size());
+			stats.setHighestQueued(highestQueueSize);
+			stats.setActiveThreads(getActiveCount());
+			stats.setMaxThreads(this.maximumPoolSize);
+			stats.setTotalSubmitted(getSubmittedCount());
+			stats.setHighestActiveThreads(getLargestPoolSize());
+			stats.setTotalCompleted(getCompletedCount());
 			return stats;
 		}
 		

Deleted: branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/WorkerPoolStats.java
===================================================================
--- branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/WorkerPoolStats.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/common-internal/src/main/java/com/metamatrix/common/queue/WorkerPoolStats.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,90 +0,0 @@
-/*
- * 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 com.metamatrix.common.queue;
-
-import java.io.Serializable;
-
-/**
- * This class is a holder for all the statistics gathered about a worker pool.
- */
-public class WorkerPoolStats implements Serializable {
-
-    public String name;
-
-    // Current state    
-    public int queued;
-    int highestQueued;
-    public int maxThreads;
-    public int activeThreads;
-    public int highestActiveThreads;
-    public long totalSubmitted;
-    public long totalCompleted;
-        
-    public String toString() {
-        StringBuffer str = new StringBuffer();
-        
-        str.append(name + " WorkerPoolStats:\n"); //$NON-NLS-1$
-        str.append("\tqueued = " + queued); //$NON-NLS-1$
-        str.append("\thighestQueued = " + highestQueued); //$NON-NLS-1$
-        str.append("\tmaxThreads = " + maxThreads);     //$NON-NLS-1$
-        str.append("\tactiveThreads = " + activeThreads);     //$NON-NLS-1$
-        str.append("\thighestActiveThreads = " + highestActiveThreads);     //$NON-NLS-1$
-        str.append("\ttotalSubmitted = " + totalSubmitted);     //$NON-NLS-1$
-        str.append("\ttotalCompleted = " + totalCompleted);     //$NON-NLS-1$
-        return str.toString();
-    }
-    
-    public int getActiveThreads() {
-		return activeThreads;
-	}
-    
-    public int getHighestActiveThreads() {
-		return highestActiveThreads;
-	}
-    
-    public long getTotalCompleted() {
-		return totalCompleted;
-	}
-    
-    public long getTotalSubmitted() {
-		return totalSubmitted;
-	}
-    
-    public String getQueueName() {
-		return name;
-	}
-    
-    public int getQueued() {
-		return queued;
-	}
-    
-    public int getHighestQueued() {
-		return highestQueued;
-	}
-    
-    public int getMaxThreads() {
-		return maxThreads;
-	}
-
-}
-

Modified: branches/JCA/common-internal/src/test/java/com/metamatrix/common/queue/TestQueueWorkerPool.java
===================================================================
--- branches/JCA/common-internal/src/test/java/com/metamatrix/common/queue/TestQueueWorkerPool.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/common-internal/src/test/java/com/metamatrix/common/queue/TestQueueWorkerPool.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -22,7 +22,9 @@
 
 package com.metamatrix.common.queue;
 
-import static org.junit.Assert.*;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertTrue;
 
 import java.util.ArrayList;
 import java.util.concurrent.ExecutionException;
@@ -32,6 +34,7 @@
 import java.util.concurrent.atomic.AtomicInteger;
 
 import org.junit.Test;
+import org.teiid.adminapi.impl.WorkerPoolStatisticsMetadata;
 
 /**
  */
@@ -51,9 +54,9 @@
         pool.shutdown();        
         pool.awaitTermination(1000, TimeUnit.MILLISECONDS);
         assertTrue(pool.isTerminated());
-        WorkerPoolStats stats = pool.getStats();
-        assertEquals(10, stats.totalCompleted);
-        assertEquals("Expected threads to be maxed out", MAX_THREADS, stats.highestActiveThreads); //$NON-NLS-1$
+        WorkerPoolStatisticsMetadata stats = pool.getStats();
+        assertEquals(10, stats.getTotalCompleted());
+        assertEquals("Expected threads to be maxed out", MAX_THREADS, stats.getHighestActiveThreads()); //$NON-NLS-1$
     }
 
     @Test public void testThreadReuse() throws Exception {
@@ -73,8 +76,8 @@
         
         pool.shutdown();                
         
-        WorkerPoolStats stats = pool.getStats();
-        assertEquals("Expected 1 thread for serial execution", 1, stats.highestActiveThreads); //$NON-NLS-1$
+        WorkerPoolStatisticsMetadata stats = pool.getStats();
+        assertEquals("Expected 1 thread for serial execution", 1, stats.getHighestActiveThreads()); //$NON-NLS-1$
         
         pool.awaitTermination(1000, TimeUnit.MILLISECONDS);
     }

Modified: branches/JCA/engine/src/main/java/com/metamatrix/dqp/service/TransactionService.java
===================================================================
--- branches/JCA/engine/src/main/java/com/metamatrix/dqp/service/TransactionService.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/engine/src/main/java/com/metamatrix/dqp/service/TransactionService.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -74,5 +74,5 @@
 	// management methods
     Collection<Transaction> getTransactions();
     
-    void terminateTransaction(Xid transactionId) throws AdminException;
+    void terminateTransaction(String transactionId) throws AdminException;
 }

Modified: branches/JCA/engine/src/main/java/org/teiid/dqp/internal/datamgr/impl/ConnectorManager.java
===================================================================
--- branches/JCA/engine/src/main/java/org/teiid/dqp/internal/datamgr/impl/ConnectorManager.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/engine/src/main/java/org/teiid/dqp/internal/datamgr/impl/ConnectorManager.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -26,9 +26,6 @@
  */
 package org.teiid.dqp.internal.datamgr.impl;
 
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.Collections;
 import java.util.Map;
 import java.util.Properties;
 import java.util.concurrent.ConcurrentHashMap;
@@ -39,6 +36,12 @@
 import javax.resource.spi.work.WorkException;
 import javax.resource.spi.work.WorkManager;
 
+import org.jboss.managed.api.annotation.ManagementComponent;
+import org.jboss.managed.api.annotation.ManagementObject;
+import org.jboss.managed.api.annotation.ManagementProperties;
+import org.jboss.managed.api.annotation.ManagementProperty;
+import org.jboss.managed.api.annotation.ViewUse;
+import org.teiid.adminapi.impl.WorkerPoolStatisticsMetadata;
 import org.teiid.connector.api.Connection;
 import org.teiid.connector.api.Connector;
 import org.teiid.connector.api.ConnectorCapabilities;
@@ -58,7 +61,6 @@
 import com.metamatrix.common.comm.api.ResultsReceiver;
 import com.metamatrix.common.log.LogManager;
 import com.metamatrix.common.queue.StatsCapturingWorkManager;
-import com.metamatrix.common.queue.WorkerPoolStats;
 import com.metamatrix.core.log.MessageLevel;
 import com.metamatrix.core.util.Assertion;
 import com.metamatrix.dqp.DQPPlugin;
@@ -78,6 +80,7 @@
  * The <code>ConnectorManager</code> manages a {@link org.teiid.connector.basic.BasicConnector Connector}
  * and its associated workers' state.
  */
+ at ManagementObject(isRuntime=true, componentType=@ManagementComponent(type="teiid",subtype="connectormanager"), properties=ManagementProperties.EXPLICIT)
 public class ConnectorManager  {
 	
 	public static final int DEFAULT_MAX_THREADS = 20;
@@ -338,23 +341,12 @@
      * this service.
      * If there are no queues, an empty Collection is returned.
      */
-    public Collection<WorkerPoolStats> getQueueStatistics() {
-        return Arrays.asList(workManager.getStats());
+    @ManagementProperty(description="Get Runtime workmanager statistics", use={ViewUse.STATISTIC}, readOnly=true)
+    public WorkerPoolStatisticsMetadata getWorkManagerStatistics() {
+        return workManager.getStats();
     }
 
     /**
-     * Returns a QueueStats object that represent the queue in
-     * this service.
-     * If there is no queue with the given name, an empty Collection is returned.
-     */
-    public Collection<WorkerPoolStats> getQueueStatistics(String name) {
-        if (!name.equalsIgnoreCase(this.connectorName)) {
-            return Collections.emptyList();
-        }
-        return Arrays.asList(workManager.getStats());
-    }
-
-    /**
      * Add begin point to transaction monitoring table.
      * @param qr Request that contains the MetaMatrix command information in the transaction.
      */

Modified: branches/JCA/engine/src/main/java/org/teiid/dqp/internal/datamgr/impl/ConnectorWorkItem.java
===================================================================
--- branches/JCA/engine/src/main/java/org/teiid/dqp/internal/datamgr/impl/ConnectorWorkItem.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/engine/src/main/java/org/teiid/dqp/internal/datamgr/impl/ConnectorWorkItem.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -48,7 +48,6 @@
 import org.teiid.dqp.internal.datamgr.metadata.RuntimeMetadataImpl;
 import org.teiid.dqp.internal.process.AbstractWorkItem;
 import org.teiid.dqp.internal.process.DQPWorkContext;
-import org.teiid.metadata.TransformationMetadata;
 
 import com.metamatrix.api.exception.MetaMatrixComponentException;
 import com.metamatrix.api.exception.MetaMatrixProcessingException;

Modified: branches/JCA/engine/src/main/java/org/teiid/dqp/internal/datamgr/impl/SynchConnectorWorkItem.java
===================================================================
--- branches/JCA/engine/src/main/java/org/teiid/dqp/internal/datamgr/impl/SynchConnectorWorkItem.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/engine/src/main/java/org/teiid/dqp/internal/datamgr/impl/SynchConnectorWorkItem.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -106,7 +106,7 @@
 		}
 		existing.lock.acquire();
 		this.lock = existing;
-		System.out.println("got the connector lock on ="+key);
+		LogManager.logTrace("got the connector lock on =", key);
 	}
 
 	private void releaseTxnLock() {
@@ -119,7 +119,7 @@
 			if (lock.pendingCount == 0) {
 				Xid key = tc.getXid();
 				TRANSACTION_LOCKS.remove(key);
-				System.out.println("released the connector lock on ="+key);
+				LogManager.logTrace("released the connector lock on =", key);
 			}
 		}
 		lock.lock.release();

Modified: branches/JCA/engine/src/main/java/org/teiid/dqp/internal/process/DQPCore.java
===================================================================
--- branches/JCA/engine/src/main/java/org/teiid/dqp/internal/process/DQPCore.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/engine/src/main/java/org/teiid/dqp/internal/process/DQPCore.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -23,7 +23,6 @@
 package org.teiid.dqp.internal.process;
 
 import java.util.ArrayList;
-import java.util.Arrays;
 import java.util.Collection;
 import java.util.Collections;
 import java.util.HashMap;
@@ -38,6 +37,12 @@
 import javax.resource.spi.work.WorkManager;
 import javax.transaction.xa.Xid;
 
+
+import org.teiid.adminapi.Admin;
+import org.teiid.adminapi.AdminException;
+import org.teiid.adminapi.impl.RequestMetadata;
+import org.teiid.adminapi.impl.SessionMetadata;
+import org.teiid.adminapi.impl.WorkerPoolStatisticsMetadata;
 import org.teiid.dqp.internal.cache.CacheID;
 import org.teiid.dqp.internal.cache.DQPContextCache;
 import org.teiid.dqp.internal.cache.ResultSetCache;
@@ -47,6 +52,7 @@
 import com.metamatrix.api.exception.MetaMatrixComponentException;
 import com.metamatrix.api.exception.MetaMatrixProcessingException;
 import com.metamatrix.api.exception.query.QueryMetadataException;
+import com.metamatrix.api.exception.security.SessionServiceException;
 import com.metamatrix.cache.CacheFactory;
 import com.metamatrix.common.application.exception.ApplicationLifecycleException;
 import com.metamatrix.common.buffer.BufferManager;
@@ -64,7 +70,6 @@
 import com.metamatrix.dqp.client.MetadataResult;
 import com.metamatrix.dqp.client.ResultsFuture;
 import com.metamatrix.dqp.embedded.DQPEmbeddedProperties;
-import com.metamatrix.dqp.message.AtomicRequestID;
 import com.metamatrix.dqp.message.AtomicRequestMessage;
 import com.metamatrix.dqp.message.RequestID;
 import com.metamatrix.dqp.message.RequestMessage;
@@ -80,7 +85,6 @@
 import com.metamatrix.query.processor.ProcessorDataManager;
 import com.metamatrix.query.sql.lang.Command;
 import com.metamatrix.query.tempdata.TempTableStoreImpl;
-import com.metamatrix.server.serverapi.RequestInfo;
 
 /**
  * Implements the core DQP processing.
@@ -170,10 +174,10 @@
     }
     
     /**
-     * Return a list of {@link RequestInfo} for the given session
+     * Return a list of {@link RequestMetadata} for the given session
      */
-    public List<RequestInfo> getRequestsByClient(String clientConnection) {
-    	ClientState state = getClientState(clientConnection, false);
+    public List<RequestMetadata> getRequestsForSession(long sessionId) {
+    	ClientState state = getClientState(String.valueOf(sessionId), false);
     	if (state == null) {
     		return Collections.emptyList();
     	}
@@ -192,22 +196,29 @@
     }
 
     /**
-     * Return a list of all {@link RequestInfo} 
+     * Return a list of all {@link RequestMetadata} 
      */
-    public List<RequestInfo> getRequests() {
+    public List<RequestMetadata> getRequests() {
 		return buildRequestInfos(requests.keySet());
     } 
 
-    private List<RequestInfo> buildRequestInfos(Collection<RequestID> ids) {
-		List<RequestInfo> results = new ArrayList<RequestInfo>();
-    	for (RequestID requestID : ids) {
+    private List<RequestMetadata> buildRequestInfos(Collection<RequestID> ids) {
+		List<RequestMetadata> results = new ArrayList<RequestMetadata>();
+    	
+		for (RequestID requestID : ids) {
             RequestWorkItem holder = requests.get(requestID);
             
             if(holder != null && !holder.isCanceled()) {
-            	RequestInfo req = new RequestInfo(holder.requestID, holder.requestMsg.getCommandString(), holder.requestMsg.getSubmittedTimestamp(), holder.requestMsg.getProcessingTimestamp());
-            	req.setSessionToken(holder.dqpWorkContext.getSessionToken());
+            	RequestMetadata req = new RequestMetadata();
+            	
+            	req.setExecutionId(holder.requestID.getExecutionID());
+            	req.setSessionId(Long.parseLong(holder.requestID.getConnectionID()));
+            	req.setCommand(holder.requestMsg.getCommandString());
+            	req.setCreatedTiime(holder.requestMsg.getSubmittedTimestamp().getTime());
+            	req.setProcessingTime(holder.requestMsg.getProcessingTimestamp().getTime());
+            	
             	if (holder.getTransactionContext() != null && holder.getTransactionContext().getXid() != null) {
-            		req.setXid(holder.getTransactionContext().getXid());
+            		req.setTransactionId(holder.getTransactionContext().getXid().toString());
             	}
 
                 for (DataTierTupleSource conInfo : holder.getConnectorRequests()) {
@@ -219,11 +230,16 @@
                     // If the request has not yet completed processing, then
                     // add all the subrequest messages
                 	AtomicRequestMessage arm = conInfo.getAtomicRequestMessage();
-                	RequestInfo info = new RequestInfo(arm.getRequestID(), arm.getCommand().toString(), arm.getSubmittedTimestamp(), arm.getProcessingTimestamp());
-                	info.setSessionToken(holder.dqpWorkContext.getSessionToken());
-                	info.setConnectorBindingUUID(arm.getConnectorName());
-        			info.setNodeID(arm.getAtomicRequestID().getNodeID());
-        			info.setExecutionID(arm.getAtomicRequestID().getExecutionId());
+                	RequestMetadata info = new RequestMetadata();
+                	
+                	info.setExecutionId(arm.getRequestID().getExecutionID());
+                	info.setSessionId(Long.parseLong(holder.requestID.getConnectionID()));
+                	info.setCommand(arm.getCommand().toString());
+                	info.setCreatedTiime(arm.getSubmittedTimestamp().getTime());
+                	info.setProcessingTime(arm.getProcessingTimestamp().getTime());
+                	info.setSourceRequest(true);
+                	info.setNodeId(arm.getAtomicRequestID().getNodeID());
+                	
         			results.add(info);
                 }
                 results.add(req);
@@ -232,8 +248,7 @@
     	return results;
 	}    
 
-	public ResultsFuture<ResultsMessage> executeRequest(long reqID,
-			RequestMessage requestMsg) {
+	public ResultsFuture<ResultsMessage> executeRequest(long reqID,RequestMessage requestMsg) {
     	DQPWorkContext workContext = DQPWorkContext.getWorkContext();
 		RequestID requestID = workContext.getRequestID(reqID);
 		requestMsg.markProcessingStart();
@@ -351,20 +366,20 @@
         return resultsFuture;
     }
     
-    /**
-     * Cancels a node in the request. (This request is called by the 
-     * client directly using the admin API), so if this does not support
-     * partial results then remove the original request.
-     * @throws MetaMatrixComponentException 
-     */
-    public void cancelAtomicRequest(AtomicRequestID requestID) throws MetaMatrixComponentException {                    
-        RequestWorkItem workItem = safeGetWorkItem(requestID.getRequestID());
-        if (workItem == null) {
-    		LogManager.logDetail(LogConstants.CTX_DQP, "Could not cancel", requestID, "parent request does not exist"); //$NON-NLS-1$ //$NON-NLS-2$
-        	return;
-        }
-        workItem.requestAtomicRequestCancel(requestID);
-    }
+//    /**
+//     * Cancels a node in the request. (This request is called by the 
+//     * client directly using the admin API), so if this does not support
+//     * partial results then remove the original request.
+//     * @throws MetaMatrixComponentException 
+//     */
+//    public void cancelAtomicRequest(AtomicRequestID requestID) throws MetaMatrixComponentException {                    
+//        RequestWorkItem workItem = safeGetWorkItem(requestID.getRequestID());
+//        if (workItem == null) {
+//    		LogManager.logDetail(LogConstants.CTX_DQP, "Could not cancel", requestID, "parent request does not exist"); //$NON-NLS-1$ //$NON-NLS-2$
+//        	return;
+//        }
+//        workItem.requestAtomicRequestCancel(requestID);
+//    }
     
     RequestWorkItem getRequestWorkItem(RequestID reqID) throws MetaMatrixProcessingException {
     	RequestWorkItem result = this.requests.get(reqID);
@@ -383,24 +398,28 @@
      * this service.
      * If there are no queues, an empty Collection is returned.
      */
-    public Collection getQueueStatistics() {
-        return Arrays.asList(processWorkerPool.getStats());
+    public WorkerPoolStatisticsMetadata getWorkManagerStatistics() {
+        return processWorkerPool.getStats();
     }
-
            
     /**
      * Cancel and close all requests associated with the clientConnection/session. Also runs a final cleanup any caches within
      * the session's scope.
-     * @param clientConnection
-     * @param sendCancellationsToClient Notify the client that each request has been closed.
-     * @throws MetaMatrixComponentException
-     * @since 4.2
      */
     @Override
-    public void terminateConnection(long id) throws MetaMatrixComponentException {
+    public void terminateSession() throws MetaMatrixComponentException {
+    	DQPWorkContext context = DQPWorkContext.getWorkContext();
+    	terminateSession(context.getSessionId());
+    }
+
+    
+    public void terminateSession(long terminateeId) {
     	
-    	String sessionId = String.valueOf(id);
+    	DQPWorkContext context = DQPWorkContext.getWorkContext();
+    	long terminatorId = context.getSessionId(); 
     	
+    	String sessionId = String.valueOf(terminateeId);
+    	
         // sometimes there will not be any atomic requests pending, in that
         // situation we still need to clear the master request from our map
         ClientState state = getClientState(sessionId, false);
@@ -429,11 +448,18 @@
             } 
         }
         contextCache.removeSessionScopedCache(sessionId);
+        
+        if (this.sessionService != null) {
+        	this.sessionService.terminateSession(terminateeId, terminatorId);
+        }
     }
 
-    public boolean cancelRequest(RequestID requestID)
-        throws MetaMatrixComponentException {
-        
+    public boolean cancelRequest(long sessionId, long requestId) throws MetaMatrixComponentException {
+    	RequestID requestID = new RequestID(String.valueOf(sessionId), requestId);
+    	return cancelRequest(requestID);
+    }
+    
+    private boolean cancelRequest(RequestID requestID) throws MetaMatrixComponentException {
         if (LogManager.isMessageToBeRecorded(LogConstants.CTX_DQP, MessageLevel.DETAIL)) {
             LogManager.logDetail(LogConstants.CTX_DQP, "cancelQuery for requestID=" + requestID); //$NON-NLS-1$
         }
@@ -475,23 +501,78 @@
         }
     }
     
-    public void clearPlanCache(){
+    private void clearPlanCache(){
         LogManager.logInfo(LogConstants.CTX_DQP, DQPPlugin.Util.getString("DQPCore.Clearing_prepared_plan_cache")); //$NON-NLS-1$
         this.prepPlanCache.clearAll();
     }
 
-    public void clearCodeTableCache(){
+    private void clearCodeTableCache(){
         LogManager.logInfo(LogConstants.CTX_DQP, DQPPlugin.Util.getString("DQPCore.Clearing_code_table_cache")); //$NON-NLS-1$
         this.dataTierMgr.clearCodeTables();
     }
-
-	public void clearResultSetCache() {
+    
+	private void clearResultSetCache() {
 		//clear cache in server
 		if(rsCache != null){
 			rsCache.clear();
 		}
 	}
+	
+	
+    public Collection<String> getCacheTypes(){
+    	ArrayList<String> caches = new ArrayList<String>();
+    	caches.add(Admin.Cache.CODE_TABLE_CACHE.toString());
+    	caches.add(Admin.Cache.PREPARED_PLAN_CACHE.toString());
+    	caches.add(Admin.Cache.CONNECTOR_RESULT_SET_CACHE.toString());
+    	caches.add(Admin.Cache.QUERY_SERVICE_RESULT_SET_CACHE.toString());
+    	return caches;
+    }	
+	
+	public void clearCache(String cacheType) {
+		Admin.Cache cache = Admin.Cache.valueOf(cacheType);
+		switch (cache) {
+		case CODE_TABLE_CACHE:
+			clearCodeTableCache();
+			break;
+		case PREPARED_PLAN_CACHE:
+			clearPlanCache();
+			break;
+		case CONNECTOR_RESULT_SET_CACHE:
+			clearResultSetCache();
+			break;
+		case QUERY_SERVICE_RESULT_SET_CACHE:
+			break;
+		}
+	}
     
+	public Collection<SessionMetadata> getActiveSessions() throws SessionServiceException {
+		if (this.sessionService == null) {
+			return Collections.EMPTY_LIST;
+		}
+		return this.sessionService.getActiveSessions();
+	}
+	
+	public int getActiveSessionsCount() throws SessionServiceException{
+		if (this.sessionService == null) {
+			return 0;
+		}
+		return this.sessionService.getActiveSessionsCount();
+	}	
+	
+	public Collection<org.teiid.adminapi.Transaction> getTransactions() {
+		if (this.transactionService == null) {
+			return Collections.EMPTY_LIST;
+		}
+		return this.transactionService.getTransactions();
+	}
+	
+	public void terminateTransaction(String xid) throws AdminException {
+		if (this.transactionService == null) {
+			return;
+		}
+		this.transactionService.terminateTransaction(xid);
+	}	
+	
     void logMMCommand(RequestWorkItem workItem, boolean isBegin, boolean isCancel, int rowCount) {
     	if (!LogManager.isMessageToBeRecorded(LogConstants.CTX_COMMANDLOGGING, MessageLevel.INFO)) {
     		return;
@@ -640,10 +721,11 @@
         return metadata.getXMLSchemas(groupID);
 	}
 
-	public void cancelRequest(long requestID)
+	@Override
+	public boolean cancelRequest(long requestID)
 			throws MetaMatrixProcessingException, MetaMatrixComponentException {
 		DQPWorkContext workContext = DQPWorkContext.getWorkContext();
-		this.cancelRequest(workContext.getRequestID(requestID));
+		return this.cancelRequest(workContext.getRequestID(requestID));
 	}
 	
 	// local txn

Added: branches/JCA/engine/src/main/java/org/teiid/dqp/internal/process/DQPManagementView.java
===================================================================
--- branches/JCA/engine/src/main/java/org/teiid/dqp/internal/process/DQPManagementView.java	                        (rev 0)
+++ branches/JCA/engine/src/main/java/org/teiid/dqp/internal/process/DQPManagementView.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -0,0 +1,130 @@
+/*
+ * 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.dqp.internal.process;
+
+import java.util.Collection;
+import java.util.List;
+
+import org.jboss.managed.api.ManagedOperation.Impact;
+import org.jboss.managed.api.annotation.ManagementComponent;
+import org.jboss.managed.api.annotation.ManagementObject;
+import org.jboss.managed.api.annotation.ManagementOperation;
+import org.jboss.managed.api.annotation.ManagementParameter;
+import org.jboss.managed.api.annotation.ManagementProperties;
+import org.jboss.managed.api.annotation.ManagementProperty;
+import org.jboss.managed.api.annotation.ViewUse;
+import org.teiid.adminapi.AdminException;
+import org.teiid.adminapi.impl.RequestMetadata;
+import org.teiid.adminapi.impl.SessionMetadata;
+import org.teiid.adminapi.impl.WorkerPoolStatisticsMetadata;
+import org.teiid.dqp.internal.datamgr.impl.ConnectorManager;
+import org.teiid.dqp.internal.datamgr.impl.ConnectorManagerRepository;
+
+import com.metamatrix.api.exception.MetaMatrixComponentException;
+import com.metamatrix.api.exception.security.SessionServiceException;
+
+/**
+ * Since DQPCore can not be made into a management bean itself as it has life cycle dependencies associated with
+ * runtime connector. Even though we can intercept the deployer for runtime, injection of management bean was not occurring
+ * through "ManagedObjectCreator" interface. This is brute force way to introduce a management bean then this can delegate calls to
+ * what ever objects it has access to.
+ */
+ at ManagementObject(isRuntime=true, componentType=@ManagementComponent(type="teiid",subtype="dqp"), properties=ManagementProperties.EXPLICIT)
+public class DQPManagementView {
+
+	private DQPCore dqp;
+	private ConnectorManagerRepository connectorManagerRepository;
+	
+	public DQPCore getDQP() {
+		return this.dqp;
+	}
+	
+	public void setDQP(DQPCore dqp) {
+		this.dqp = dqp;
+	}
+	
+	public void setConnectorManagerRepository(ConnectorManagerRepository repo) {
+		this.connectorManagerRepository = repo;
+	}	
+	
+    @ManagementOperation(description="Requests for perticular session", impact=Impact.ReadOnly,params={@ManagementParameter(name="sessionId",description="The session Identifier")})
+    public List<RequestMetadata> getRequestsForSession(long sessionId) {
+		return this.dqp.getRequestsForSession(sessionId);
+	}
+    
+    @ManagementOperation(description="Active requests", impact=Impact.ReadOnly)
+    public List<RequestMetadata> getRequests() {
+		return this.dqp.getRequests();
+	}
+	
+	@ManagementOperation(description="Get Runtime workmanager statistics", impact=Impact.ReadOnly,params={@ManagementParameter(name="identifier",description="Use \"runtime\" for engine, or connector name for connector")})
+    public WorkerPoolStatisticsMetadata getWorkManagerStatistics(String identifier) {
+		if ("runtime".equalsIgnoreCase(identifier)) {
+			return this.dqp.getWorkManagerStatistics();
+		}
+		ConnectorManager cm = this.connectorManagerRepository.getConnectorManager(identifier);
+		if (cm != null) {
+			return cm.getWorkManagerStatistics();
+		}
+		return null;
+	}
+	
+    @ManagementOperation(description="Terminate a Session",params={@ManagementParameter(name="terminateeId",description="The session to be terminated")})
+    public void terminateSession(long terminateeId) {
+    	this.dqp.terminateSession(terminateeId);
+    }
+    
+    @ManagementOperation(description="Cancel a Request",params={@ManagementParameter(name="sessionId",description="The session Identifier"), @ManagementParameter(name="requestId",description="The request Identifier")})    
+    public boolean cancelRequest(long sessionId, long requestId) throws MetaMatrixComponentException {
+    	return this.dqp.cancelRequest(sessionId, requestId);
+    }
+    
+    @ManagementOperation(description="Get Cache types in the system", impact=Impact.ReadOnly)
+    public Collection<String> getCacheTypes(){
+		return this.dqp.getCacheTypes();
+	}
+	
+	@ManagementOperation(description="Clear the caches in the system", impact=Impact.ReadOnly)
+	public void clearCache(String cacheType) {
+		this.dqp.clearCache(cacheType);
+	}
+	
+	@ManagementOperation(description="Active sessions", impact=Impact.ReadOnly)
+	public Collection<SessionMetadata> getActiveSessions() throws SessionServiceException {
+		return this.dqp.getActiveSessions();
+	}
+	
+	@ManagementProperty(description="Active session count", use={ViewUse.STATISTIC}, readOnly=true)
+	public int getActiveSessionsCount() throws SessionServiceException{
+		return this.dqp.getActiveSessionsCount();
+	}
+	
+	@ManagementOperation(description="Active Transactions", impact=Impact.ReadOnly)
+	public Collection<org.teiid.adminapi.Transaction> getTransactions() {
+		return this.dqp.getTransactions();
+	}
+	
+	@ManagementOperation(description="Clear the caches in the system", impact=Impact.ReadOnly)
+	public void terminateTransaction(String xid) throws AdminException {
+		this.dqp.terminateTransaction(xid);
+	}
+}

Deleted: branches/JCA/engine/src/main/java/org/teiid/dqp/internal/process/Util.java
===================================================================
--- branches/JCA/engine/src/main/java/org/teiid/dqp/internal/process/Util.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/engine/src/main/java/org/teiid/dqp/internal/process/Util.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,42 +0,0 @@
-/*
- * 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.dqp.internal.process;
-
-import com.metamatrix.admin.objects.MMQueueWorkerPool;
-import com.metamatrix.common.queue.WorkerPoolStats;
-
-public class Util {
-
-	public static MMQueueWorkerPool convertStats(final WorkerPoolStats src, String ... identifier) {        
-	    MMQueueWorkerPool pool = new MMQueueWorkerPool(identifier); 
-	    pool.setRegistered(true);
-	    pool.setQueued(src.getQueued());
-	    pool.setThreads(src.getActiveThreads());
-	    pool.setHighestQueued(src.getHighestQueued());
-	    pool.setHighestThreads(src.getHighestActiveThreads());
-	    pool.setTotalCompleted(src.getTotalCompleted());
-	    pool.setTotalSubmitted(src.getTotalSubmitted());
-	    return pool;
-	}
-
-}

Modified: branches/JCA/engine/src/main/java/org/teiid/dqp/internal/transaction/TransactionServerImpl.java
===================================================================
--- branches/JCA/engine/src/main/java/org/teiid/dqp/internal/transaction/TransactionServerImpl.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/engine/src/main/java/org/teiid/dqp/internal/transaction/TransactionServerImpl.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -25,7 +25,6 @@
 import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Collections;
-import java.util.Date;
 import java.util.HashMap;
 import java.util.IdentityHashMap;
 import java.util.Map;
@@ -39,8 +38,8 @@
 
 import org.teiid.adminapi.AdminException;
 import org.teiid.adminapi.AdminProcessingException;
+import org.teiid.adminapi.impl.TransactionMetadata;
 
-import com.metamatrix.admin.objects.TransactionImpl;
 import com.metamatrix.common.xa.MMXid;
 import com.metamatrix.common.xa.XATransactionException;
 import com.metamatrix.core.util.Assertion;
@@ -54,8 +53,8 @@
 
         // (connection -> transaction for global and local)
         private Map<String, TransactionContext> threadToTransactionContext = new HashMap<String, TransactionContext>();
-        // (MMXid -> global transactions keyed)
-        private Map<Xid, TransactionContext> xidToTransactionContext = new HashMap<Xid, TransactionContext>();
+        // (MMXid -> global transactions keyed) using the XID as string due to management api where XID could not be passed correctly to client
+        private Map<String, TransactionContext> xidToTransactionContext = new HashMap<String, TransactionContext>();
         
         public synchronized TransactionContext getOrCreateTransactionContext(String threadId) {
             TransactionContext tc = threadToTransactionContext.get(threadId);
@@ -76,6 +75,10 @@
         public synchronized TransactionContext getTransactionContext(MMXid xid) {
             return xidToTransactionContext.get(xid);
         }
+        
+        public synchronized TransactionContext getTransactionContextByXid(String xid) {
+            return xidToTransactionContext.get(xid);
+        }        
 
         public synchronized TransactionContext removeTransactionContext(String threadId) {
             return threadToTransactionContext.remove(threadId);
@@ -92,7 +95,7 @@
         
         public synchronized void addTransactionContext(TransactionContext tc) {
             if (tc.getXid() != null) {
-                this.xidToTransactionContext.put(tc.getXid(), tc);
+                this.xidToTransactionContext.put(tc.getXid().toString(), tc);
             }
             if (tc.getThreadId() != null) {
                 this.threadToTransactionContext.put(tc.getThreadId(), tc);
@@ -507,22 +510,22 @@
 			if (TransactionContext.getXid() == null) {
 				continue;
 			}
-			TransactionImpl txnImpl = new TransactionImpl(processName, TransactionContext.getXid().toString());
+			TransactionMetadata txnImpl = new TransactionMetadata();
 			txnImpl.setAssociatedSession(Long.parseLong(TransactionContext.getThreadId()));
-			txnImpl.setCreated(new Date(TransactionContext.getCreationTime()));
+			txnImpl.setCreatedTime(TransactionContext.getCreationTime());
 			txnImpl.setScope(TransactionContext.getTransactionType().toString());
-			txnImpl.setXid((MMXid)TransactionContext.getXid());
+			txnImpl.setXid(TransactionContext.getXid().toString());
 			result.add(txnImpl);
 		}
 		return result;
 	}
 	
 	@Override
-	public void terminateTransaction(Xid xid) throws AdminException {
+	public void terminateTransaction(String xid) throws AdminException {
 		if (xid == null) {
 			return;
 		}
-		TransactionContext context = this.transactions.getTransactionContext(new MMXid(xid));
+		TransactionContext context = this.transactions.getTransactionContextByXid(xid);
 		context.setRollbackOnly();
 		
 		try {

Modified: branches/JCA/engine/src/test/java/org/teiid/dqp/internal/process/TestDQPCore.java
===================================================================
--- branches/JCA/engine/src/test/java/org/teiid/dqp/internal/process/TestDQPCore.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/engine/src/test/java/org/teiid/dqp/internal/process/TestDQPCore.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -191,7 +191,7 @@
 	}
 	
 	@Test public void testCancel() throws Exception {
-		assertFalse(this.core.cancelRequest(new RequestID(1)));
+		assertFalse(this.core.cancelRequest(1L));
 	}
     
 	public void helpTestVisibilityFails(String sql) throws Exception {

Modified: branches/JCA/engine/src/test/java/org/teiid/dqp/internal/process/TestDQPCoreRequestHandling.java
===================================================================
--- branches/JCA/engine/src/test/java/org/teiid/dqp/internal/process/TestDQPCoreRequestHandling.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/engine/src/test/java/org/teiid/dqp/internal/process/TestDQPCoreRequestHandling.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -28,6 +28,7 @@
 
 import junit.framework.TestCase;
 
+import org.teiid.adminapi.impl.RequestMetadata;
 import org.teiid.dqp.internal.datamgr.impl.FakeTransactionService;
 import org.teiid.dqp.internal.process.DQPCore.ClientState;
 
@@ -38,7 +39,6 @@
 import com.metamatrix.dqp.message.RequestMessage;
 import com.metamatrix.platform.security.api.SessionToken;
 import com.metamatrix.query.sql.lang.Command;
-import com.metamatrix.server.serverapi.RequestInfo;
 
 /**
  */
@@ -50,10 +50,10 @@
         super(name);
     }
 
-    private void compareReqInfos(Collection<RequestID> reqs1, Collection<RequestInfo> reqs2) {
+    private void compareReqInfos(Collection<RequestID> reqs1, Collection<RequestMetadata> reqs2) {
         Set reqIDs2 = new HashSet();
-        for (RequestInfo requestInfo : reqs2) {
-            reqIDs2.add(requestInfo.getRequestID());
+        for (RequestMetadata requestInfo : reqs2) {
+            reqIDs2.add(requestInfo.getRequestId());
         }
         
         assertEquals("Collections of request infos are not the same: ", new HashSet(reqs1), reqIDs2); //$NON-NLS-1$
@@ -65,7 +65,7 @@
     public void testGetRequestsSessionToken1() {
         DQPCore rm = new DQPCore();
         Set reqs = new HashSet();                
-        Collection actualReqs = rm.getRequestsByClient("foo");
+        Collection actualReqs = rm.getRequestsForSession(2);
         compareReqInfos(reqs, actualReqs);
     }
 
@@ -79,13 +79,15 @@
         RequestID id = addRequest(rm, SESSION_STRING, 1);
         reqs.add(id);
 
-        Collection<RequestInfo> actualReqs = rm.getRequestsByClient(SESSION_STRING);
+        Collection<RequestMetadata> actualReqs = rm.getRequestsForSession(2);
         compareReqInfos(reqs, actualReqs);
     }
 
 	private RequestID addRequest(DQPCore rm, String sessionId, int executionId) {
 		RequestMessage r0 = new RequestMessage("test command"); //$NON-NLS-1$
         RequestID id = new RequestID(sessionId, executionId);
+        r0.markSubmissionStart();
+        r0.markProcessingStart();
         addRequest(rm, r0, id, null, null);  
 		return id;
 	}
@@ -102,7 +104,7 @@
         reqs.add(addRequest(rm, SESSION_STRING, 1));
         reqs.add(addRequest(rm, SESSION_STRING, 2));
                 
-        Collection actualReqs = rm.getRequestsByClient(SESSION_STRING);
+        Collection actualReqs = rm.getRequestsForSession(2);
         compareReqInfos(reqs, actualReqs);
     }
     

Modified: branches/JCA/jboss-integration/src/main/java/org/teiid/adminapi/jboss/Admin.java
===================================================================
--- branches/JCA/jboss-integration/src/main/java/org/teiid/adminapi/jboss/Admin.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/jboss-integration/src/main/java/org/teiid/adminapi/jboss/Admin.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -37,11 +37,11 @@
 import org.jboss.aop.microcontainer.aspects.jmx.JMX;
 import org.jboss.deployers.spi.management.ManagementView;
 import org.jboss.deployers.spi.management.deploy.DeploymentManager;
+import org.jboss.logging.Logger;
 import org.jboss.managed.api.ComponentType;
 import org.jboss.managed.api.DeploymentTemplateInfo;
 import org.jboss.managed.api.ManagedComponent;
 import org.jboss.managed.api.ManagedDeployment;
-import org.jboss.managed.api.ManagedOperation;
 import org.jboss.managed.api.ManagedProperty;
 import org.jboss.metatype.api.types.MapCompositeMetaType;
 import org.jboss.metatype.api.values.CollectionValueSupport;
@@ -55,30 +55,40 @@
 import org.teiid.adminapi.AdminException;
 import org.teiid.adminapi.AdminObject;
 import org.teiid.adminapi.AdminProcessingException;
+import org.teiid.adminapi.ConnectionPoolStatistics;
 import org.teiid.adminapi.ConnectorBinding;
 import org.teiid.adminapi.Model;
+import org.teiid.adminapi.PropertyDefinition;
+import org.teiid.adminapi.Request;
 import org.teiid.adminapi.Session;
 import org.teiid.adminapi.TeiidAdminMBean;
+import org.teiid.adminapi.Transaction;
 import org.teiid.adminapi.VDB;
 import org.teiid.adminapi.Visibility;
+import org.teiid.adminapi.WorkerPoolStatistics;
 import org.teiid.adminapi.impl.BaseAdmin;
+import org.teiid.adminapi.impl.ConnectionPoolStatisticsMetadata;
 import org.teiid.adminapi.impl.ConnectorBindingMetaData;
 import org.teiid.adminapi.impl.ModelMetaData;
+import org.teiid.adminapi.impl.PropertyDefinitionMetadata;
+import org.teiid.adminapi.impl.RequestMetadata;
 import org.teiid.adminapi.impl.SessionMetadata;
+import org.teiid.adminapi.impl.TransactionMetadata;
 import org.teiid.adminapi.impl.VDBMetaData;
+import org.teiid.dqp.internal.process.DQPManagementView;
 
 import com.metamatrix.core.CoreConstants;
-import com.metamatrix.platform.security.session.service.SessionServiceImpl;
 
 @JMX(name="jboss.teiid:service=teiid-admin", exposedInterface=TeiidAdminMBean.class, registerDirectly=true)		
 public class Admin extends BaseAdmin implements TeiidAdminMBean{
-
+	protected Logger log = Logger.getLogger(getClass());
+	private static final String TEIID_RUNTIME_ENGINE = "teiid/runtime-engine";
 	private static final long serialVersionUID = 7081309086056911304L;
 	private static ComponentType VDBTYPE = new ComponentType("teiid", "vdb");
 	private static ComponentType MODELTYPE = new ComponentType("teiid", "model");
 	private static ComponentType NOTXTYPE = new ComponentType("ConnectionFactory", "NoTx");
 	private static ComponentType TXTYPE = new ComponentType("ConnectionFactory", "Tx");
-	private static ComponentType SESSIONSTYPE = new ComponentType("teiid", "sessions");
+	private static ComponentType DQPTYPE = new ComponentType("teiid", "dqp");
 	
 	private ManagementView getView() throws AdminComponentException {
 		try {
@@ -120,25 +130,22 @@
 	
 	private ManagedComponent getConnectorBindingComponent(String deployedName) throws AdminProcessingException {
 		try {
-			Set<ManagedComponent> components = getView().getComponentsForType(NOTXTYPE);
-			for (ManagedComponent mc: components) {
+			if (deployedName.startsWith("java:")) {
+				deployedName = deployedName.substring(5);
+			}
+			ManagedComponent mc = getView().getComponent(deployedName, NOTXTYPE);
+			if (mc != null) {
 				if (isConnectorBinding(mc)) {
-					String name = ManagedUtil.getSimpleValue(mc, "name", String.class);
-					if (name.equals(deployedName)) {
-						return mc;
-					}
+					return mc;	
 				}
 			}
 	
-			components = getView().getComponentsForType(TXTYPE);
-			for (ManagedComponent mc: components) {
+			mc = getView().getComponent(deployedName, TXTYPE);
+			if (mc != null) {
 				if (isConnectorBinding(mc)) {
-					String name = ManagedUtil.getSimpleValue(mc, "name", String.class);
-					if (name.equals(deployedName)) {
-						return mc;
-					}
+					return mc;	
 				}
-			}
+			}			
 		} catch(Exception e) {
 			throw new AdminProcessingException(e.getMessage(), e);
 		}
@@ -149,6 +156,7 @@
 		ConnectorBindingMetaData connector = new ConnectorBindingMetaData();
 		connector.setName(mc.getName());
 		connector.setComponentType(mc.getType());
+		connector.addProperty("deployer-name", mc.getDeployment().getName());
 		
 		for (String key:mc.getProperties().keySet()) {
 			ManagedProperty property = mc.getProperty(key);
@@ -156,16 +164,21 @@
 			
 			//TODO: All properties need to be added
 			if (value != null) {
-				if(value instanceof SimpleValueSupport) {
+				if(value.getMetaType().isSimple()) {
 					connector.addProperty(key, ManagedUtil.stringValue(value));
 				}
-				else if (value.getMetaType() instanceof MapCompositeValueSupport) {
+				else if (key.equals("config-property")) {
 					MapCompositeValueSupport v1 = (MapCompositeValueSupport)value;
 					MapCompositeMetaType metaType = v1.getMetaType();
 					for (String configProperty:metaType.keySet()) {
-						connector.addProperty(configProperty, ManagedUtil.stringValue(v1.get(configProperty)));
+						if (!configProperty.endsWith(".type")) {
+							connector.addProperty(configProperty, ManagedUtil.stringValue(v1.get(configProperty)));
+						}
 					}
 				}
+				else {
+					log.info(key+" property is not added to connector properties");
+				}
 			}
 		}
 		return connector;
@@ -185,29 +198,7 @@
 			    ManagedProperty mp = mc.getProperty("connection-definition");
 				SimpleValueSupport v = (SimpleValueSupport)mp.getValue();
 				if (v.getValue().equals("org.teiid.connector.api.Connector")){
-					
-					ConnectorBindingMetaData cb = new ConnectorBindingMetaData();
-					cb.setName(mc.getName());
-					cb.setComponentType(type);
-					for (String key:mc.getProperties().keySet()) {
-						ManagedProperty property = mc.getProperty(key);
-						MetaValue value = property.getValue();
-						
-						//TODO: All properties need to be added
-						if (value != null) {
-							if(value instanceof SimpleValueSupport) {
-								cb.addProperty(key, ManagedUtil.stringValue(value));
-							}
-							else if (value.getMetaType() instanceof MapCompositeValueSupport) {
-								MapCompositeValueSupport v1 = (MapCompositeValueSupport)value;
-								MapCompositeMetaType metaType = v1.getMetaType();
-								for (String configProperty:metaType.keySet()) {
-									cb.addProperty(configProperty, ManagedUtil.stringValue(v1.get(configProperty)));
-								}
-							}
-						}
-					}
-					bindings.add(cb);
+					bindings.add(buildConnectorBinding(mc));
 			    }
 			}
 		}catch(Exception e) {
@@ -267,6 +258,29 @@
 	}
 	
 	@Override
+	public void setConnectorBindingProperty(String deployedName, String propertyName, String propertyValue) throws AdminException{
+		ManagedComponent mc = getConnectorBindingComponent(deployedName);
+		if (mc == null) {
+			throw new AdminProcessingException("Connector binding with name "+deployedName+" does not exist.");
+		}
+		if (mc.getProperty(propertyName) != null) {
+			mc.getProperty(propertyName).setValue(SimpleValueSupport.wrap(propertyValue));
+		}
+		else {
+			Map<String, String> configProps = new HashMap<String, String>();
+			configProps.put(propertyName, propertyValue);
+			configProps.put(propertyValue+".type", "java.lang.String");
+			MetaValue metaValue = ManagedUtil.compositeValueMap(configProps);
+			mc.getProperty("config-property").setValue(metaValue);
+		}
+	}
+	
+	@Override
+    public void setRuntimeProperty(String propertyName, String propertyValue) throws AdminException {
+    	setConnectorBindingProperty(TEIID_RUNTIME_ENGINE, propertyName, propertyValue);
+    }
+	
+	@Override
 	public void deleteConnectorBinding(String deployedName) throws AdminException {
 		ManagedComponent mc = getConnectorBindingComponent(deployedName);
 		if (mc != null) {
@@ -275,26 +289,28 @@
 	}
 	
 	@Override
-	public void startConnectorBinding(String deployedName) throws AdminException {
-		ManagedComponent mc = getConnectorBindingComponent(deployedName);
-		if (mc != null) {
-			try {
-				ManagedUtil.execute(getDeploymentManager().start(deployedName), "Failed to start Connector Binding = " + deployedName);
-			} catch (Exception e) {
-				ManagedUtil.handleException(e);
+	public void startConnectorBinding(ConnectorBinding binding) throws AdminException {
+		try {
+			String deployerName = binding.getPropertyValue("deployer-name");
+			if (deployerName == null) {
+				throw new AdminProcessingException("Failed to find deployer name of the connector. Can not start!");
 			}
+			ManagedUtil.execute(getDeploymentManager().start(deployerName), "Failed to start Connector Binding = " + binding.getName());
+		} catch (Exception e) {
+			ManagedUtil.handleException(e);
 		}
 	}
 
 	@Override
-	public void stopConnectorBinding(String deployedName,boolean stopNow) throws AdminException {
-		ManagedComponent mc = getConnectorBindingComponent(deployedName);
-		if (mc != null) {
-			try {
-				ManagedUtil.execute(getDeploymentManager().stop(deployedName), "Failed to Stop Connector Binding = " + deployedName);
-			} catch (Exception e) {
-				ManagedUtil.handleException(e);
-			}
+	public void stopConnectorBinding(ConnectorBinding binding) throws AdminException {
+		try {
+			String deployerName = binding.getPropertyValue("deployer-name");
+			if (deployerName == null) {
+				throw new AdminProcessingException("Failed to find deployer name of the connector. Can not stop!");
+			}			
+			ManagedUtil.execute(getDeploymentManager().stop(deployerName), "Failed to Stop Connector Binding = " + binding.getName());
+		} catch (Exception e) {
+			ManagedUtil.handleException(e);
 		}
 	}	
 	
@@ -314,7 +330,7 @@
 				}
 			}
 		}
-		return bindingMap.values();
+		return new ArrayList(bindingMap.values());
 	}
 	
 	
@@ -364,8 +380,7 @@
 	
 	private ManagedComponent getVDBManagedComponent(String vdbName, int vdbVersion) throws AdminException{
 		try {
-			ComponentType type = new ComponentType("teiid", "vdb");
-			Set<ManagedComponent> vdbComponents = getView().getComponentsForType(type);
+			Set<ManagedComponent> vdbComponents = getView().getComponentsForType(VDBTYPE);
 			for (ManagedComponent mc: vdbComponents) {
 				String name = ManagedUtil.getSimpleValue(mc, "name", String.class);
 			    int version = ManagedUtil.getSimpleValue(mc, "version", Integer.class);
@@ -409,7 +424,7 @@
 		Collection<ManagedComponent> models = deployment.getComponents().values();
 		for (ManagedComponent mm:models) {
 			if (mm.getType().equals(MODELTYPE)) {
-				String modelName = ManagedUtil.getSimpleValue(mc, "name", String.class);
+				String modelName = ManagedUtil.getSimpleValue(mm, "name", String.class);
 				if (!modelName.equals(CoreConstants.SYSTEM_MODEL)) {
 					vdb.addModel(buildModel(mm));
 				}
@@ -421,9 +436,9 @@
 	private ModelMetaData buildModel(ManagedComponent mc) {
 		ModelMetaData model = new ModelMetaData();
 		model.setName(ManagedUtil.getSimpleValue(mc, "name", String.class));
-		model.setModelURI(ManagedUtil.getSimpleValue(mc, "modeluri", String.class));
-		model.setModelType(ManagedUtil.getSimpleValue(mc, "modeltype", String.class));
-		model.setPath(ManagedUtil.getSimpleValue(mc, "modelpath", String.class));
+		model.setModelURI(ManagedUtil.getSimpleValue(mc, "modelURI", String.class));
+		model.setModelType(ManagedUtil.getSimpleValue(mc, "modelType", String.class));
+		model.setPath(ManagedUtil.getSimpleValue(mc, "path", String.class));
 		model.setUuid(ManagedUtil.getSimpleValue(mc, "uuid", String.class));
 		model.setSupportsMultiSourceBindings(ManagedUtil.getSimpleValue(mc, "supportsMultiSourceBindings", Boolean.class));
 		model.setVisibility(Visibility.valueOf(ManagedUtil.getSimpleValue(mc, "visibility", String.class)));
@@ -439,11 +454,11 @@
 	public Collection<Session> getSessions() throws AdminException {
 		try {
 			Collection<Session> sessionList = new ArrayList<Session>();
-			ManagedComponent mc = getView().getComponent(SessionServiceImpl.class.getName(), SESSIONSTYPE);	
-			ManagedProperty mp = mc.getProperty("activeSessions");
-			MetaValue[] sessions = ((CollectionValueSupport)mp.getValue()).getElements();
+			ManagedComponent mc = getView().getComponent(DQPManagementView.class.getName(), DQPTYPE);	
+			MetaValue value = ManagedUtil.executeOperation(mc, "getActiveSessions");
+			MetaValue[] sessions = ((CollectionValueSupport)value).getElements();
 			for (MetaValue mv:sessions) {
-				sessionList.add((SessionMetadata)MetaValueFactory.getInstance().unwrap(mv));
+				sessionList.add((SessionMetadata)MetaValueFactory.getInstance().unwrap(mv, SessionMetadata.class));
 			}
 			return sessionList;
 		} catch (Exception e) {
@@ -454,15 +469,222 @@
 	@Override
 	public void terminateSession(long sessionId) throws AdminException {
 		try {
-			ManagedComponent mc = getView().getComponent(SessionServiceImpl.class.getName(), SESSIONSTYPE);
-			Set<ManagedOperation> operations = mc.getOperations();
-			for (ManagedOperation mo:operations) {
-				mo.getName().equals("terminate");
-				// TODO: Finish this. rareddy
+			ManagedComponent mc = getView().getComponent(DQPManagementView.class.getName(), DQPTYPE);	
+			ManagedUtil.executeOperation(mc, "terminateSession", SimpleValueSupport.wrap(sessionId));
+		} catch (Exception e) {
+			throw new AdminComponentException(e.getMessage(), e);
+		}     	
+	}	
+	
+	@Override
+    public Collection<Request> getRequests() throws AdminException {
+		try {
+			Collection<Request> requestList = new ArrayList<Request>();
+			ManagedComponent mc = getView().getComponent(DQPManagementView.class.getName(), DQPTYPE);	
+			MetaValue value = ManagedUtil.executeOperation(mc, "getRequests");
+			MetaValue[] requests = ((CollectionValueSupport)value).getElements();			
+			for (MetaValue mv:requests) {
+				requestList.add((RequestMetadata)MetaValueFactory.getInstance().unwrap(mv, RequestMetadata.class));
 			}
+			return requestList;
 		} catch (Exception e) {
 			throw new AdminComponentException(e.getMessage(), e);
+		}    	
+    }
+    
+	@Override
+    public Collection<Request> getRequestsForSession(long sessionId) throws AdminException {
+		try {
+			Collection<Request> requestList = new ArrayList<Request>();
+			ManagedComponent mc = getView().getComponent(DQPManagementView.class.getName(), DQPTYPE);	
+			MetaValue value = ManagedUtil.executeOperation(mc, "getRequestsForSession", SimpleValueSupport.wrap(sessionId));
+			MetaValue[] requests = ((CollectionValueSupport)value).getElements();
+			for (MetaValue mv:requests) {
+				requestList.add((RequestMetadata)MetaValueFactory.getInstance().unwrap(mv, RequestMetadata.class));
+			}
+			return requestList;
+		} catch (Exception e) {
+			throw new AdminComponentException(e.getMessage(), e);
+		}     	
+    }
+	
+	@Override
+	public void cancelRequest(long sessionId, long requestId) throws AdminException{
+		try {
+			ManagedComponent mc = getView().getComponent(DQPManagementView.class.getName(), DQPTYPE);	
+			ManagedUtil.executeOperation(mc, "cancelRequest", SimpleValueSupport.wrap(sessionId), SimpleValueSupport.wrap(requestId));
+		} catch (Exception e) {
+			throw new AdminComponentException(e.getMessage(), e);
+		}     	
+	}
+	
+	private String getRarDeployerName(String rarName) throws AdminException{
+		try {
+			Set<String> rarDeployments = getView().getDeploymentNamesForType("JavaEEResourceAdaptor");
+			for (String name: rarDeployments) {
+				if (name.endsWith(rarName)) {
+					return name;
+				}
+			}
+			return null;
+		} catch (Exception e) {
+			throw new AdminComponentException(e.getMessage(), e);
 		}	
+	}	
+	
+	@Override
+	public void addConnectorType(String connectorName, URL rarURL) throws AdminException{
+		if (!connectorName.endsWith(".rar")) {
+			connectorName = connectorName + ".rar";
+		}
+		ManagedUtil.deployArchive(getDeploymentManager(), connectorName, rarURL, false);
 		
+		//TODO: also need to add a template for the properties
+	}
+	
+	@Override
+	public void deleteConnectorType(String connectorName) throws AdminException {
+		if (!connectorName.endsWith(".rar")) {
+			connectorName = connectorName + ".rar";
+		}
+		String deployerName = getRarDeployerName(connectorName);
+		if (deployerName != null) {
+			ManagedUtil.removeArchive(getDeploymentManager(), deployerName);
+		}
+		
+		//TODO: also need to delete template for the properties
+	}
+	
+	@Override
+	public void restart() throws AdminException {
+		ConnectorBinding binding = getConnectorBinding(TEIID_RUNTIME_ENGINE);
+		stopConnectorBinding(binding);
+		startConnectorBinding(binding);
+	}
+
+	@Override
+	public void shutdown(int millisToWait) throws AdminException {
+		// TODO: implement the wait.
+		ConnectorBinding binding = getConnectorBinding(TEIID_RUNTIME_ENGINE);
+		stopConnectorBinding(binding);
+	}
+	
+	@Override
+	public Collection<String> getCacheTypes() throws AdminException {
+		try {
+			Collection<String> requestList = new ArrayList<String>();
+			ManagedComponent mc = getView().getComponent(DQPManagementView.class.getName(), DQPTYPE);	
+			MetaValue value = ManagedUtil.executeOperation(mc, "getCacheTypes");
+			MetaValue[] requests = ((CollectionValueSupport)value).getElements();
+			for (MetaValue mv:requests) {
+				requestList.add(ManagedUtil.stringValue(mv));
+			}
+			return requestList;
+		} catch (Exception e) {
+			throw new AdminComponentException(e.getMessage(), e);
+		} 
 	}	
+	
+	@Override
+	public void clearCache(String cacheType) throws AdminException{
+		try {
+			ManagedComponent mc = getView().getComponent(DQPManagementView.class.getName(), DQPTYPE);	
+			ManagedUtil.executeOperation(mc, "clearCache", SimpleValueSupport.wrap(cacheType));
+		} catch (Exception e) {
+			throw new AdminComponentException(e.getMessage(), e);
+		} 		
+	}
+	
+	@Override
+	public Collection<Transaction> getTransactions() throws AdminException {
+		try {
+			Collection<Transaction> txnList = new ArrayList<Transaction>();
+			ManagedComponent mc = getView().getComponent(DQPManagementView.class.getName(), DQPTYPE);	
+			MetaValue value = ManagedUtil.executeOperation(mc, "getTransactions");
+			MetaValue[] requests = ((CollectionValueSupport)value).getElements();
+			for (MetaValue mv:requests) {
+				txnList.add((TransactionMetadata)MetaValueFactory.getInstance().unwrap(mv, TransactionMetadata.class));
+			}
+			return txnList;
+		} catch (Exception e) {
+			throw new AdminComponentException(e.getMessage(), e);
+		}  
+	}	
+	
+	@Override
+	public void terminateTransaction(String xid) throws AdminException {
+		try {
+			ManagedComponent mc = getView().getComponent(DQPManagementView.class.getName(), DQPTYPE);	
+			ManagedUtil.executeOperation(mc, "terminateTransaction", MetaValueFactory.getInstance().create(xid));
+		} catch (Exception e) {
+			throw new AdminComponentException(e.getMessage(), e);
+		} 	
+	}
+	
+	@Override
+	public WorkerPoolStatistics getWorkManagerStats(String identifier) throws AdminException {
+		try {
+			ManagedComponent mc = getView().getComponent(DQPManagementView.class.getName(), DQPTYPE);
+			MetaValue value = ManagedUtil.executeOperation(mc, "getWorkManagerStatistics", SimpleValueSupport.wrap(identifier));
+			return (WorkerPoolStatistics)MetaValueFactory.getInstance().unwrap(value, WorkerPoolStatistics.class);	
+		} catch (Exception e) {
+			throw new AdminComponentException(e.getMessage(), e);
+		}
+	}	
+	
+	@Override
+	public ConnectionPoolStatistics getConnectorConnectionPoolStats(String deployedName) throws AdminException {
+		ManagedComponent mc = getConnectorBindingComponent(deployedName);
+		if (mc != null) {
+			return buildConnectorConnectionPool(mc);
+		}
+		return null;
+	}
+
+	private ConnectionPoolStatistics buildConnectorConnectionPool(ManagedComponent mc) {
+		ConnectionPoolStatisticsMetadata stats = new ConnectionPoolStatisticsMetadata();
+		stats.setName(mc.getName());
+		stats.setAvailableConnectionCount(ManagedUtil.getSimpleValue(mc, "availableConnectionCount", Long.class));
+		stats.setConnectionCount(ManagedUtil.getSimpleValue(mc, "connectionCount", Integer.class));
+		stats.setConnectionCreatedCount(ManagedUtil.getSimpleValue(mc, "connectionCreatedCount", Integer.class));
+		stats.setConnectionDestroyedCount(ManagedUtil.getSimpleValue(mc, "connectionDestroyedCount", Integer.class));
+		stats.setInUseConnectionCount(ManagedUtil.getSimpleValue(mc, "inUseConnectionCount", Long.class));
+		stats.setMaxConnectionsInUseCount(ManagedUtil.getSimpleValue(mc, "maxConnectionsInUseCount", Long.class));
+		stats.setMaxSize(ManagedUtil.getSimpleValue(mc, "maxSize", Integer.class));
+		stats.setMinSize(ManagedUtil.getSimpleValue(mc, "minSize", Integer.class));
+		return stats;
+	}	
+	
+	@Override
+	public Collection<PropertyDefinition> getConnectorTypePropertyDefinitions(String typeName) throws AdminException {
+		try {
+			DeploymentTemplateInfo info = getView().getTemplate(typeName);
+			if(info == null) {
+				throw new AdminProcessingException("Connector Type template supplied not found in the configuration."+typeName);
+			}
+			
+			ArrayList<PropertyDefinition> props = new ArrayList<PropertyDefinition>();
+			Map<String, ManagedProperty> propertyMap = info.getProperties();
+			
+			for (ManagedProperty mp:propertyMap.values()) {
+					PropertyDefinitionMetadata p = new PropertyDefinitionMetadata();
+					p.setName(mp.getName());
+					p.setDescription(mp.getDescription());
+					p.setDisplayName(mp.getName());
+					if (mp.getDefaultValue() != null) {
+						p.setDefaultValue(((SimpleValueSupport)mp.getDefaultValue()).getValue());
+					}
+					p.setPropertyTypeClassName(mp.getMetaType().getTypeName());
+					p.setModifiable(false);
+					p.setMasked(false);
+					p.setExpert(true);
+					props.add(p);
+			}
+			return props;
+		} catch (NoSuchDeploymentException e) {
+			throw new AdminComponentException(e.getMessage(), e);
+		} catch(Exception e) {
+			throw new AdminComponentException(e.getMessage(), e);
+		}
+	}	
 }

Modified: branches/JCA/jboss-integration/src/main/java/org/teiid/adminapi/jboss/ManagedUtil.java
===================================================================
--- branches/JCA/jboss-integration/src/main/java/org/teiid/adminapi/jboss/ManagedUtil.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/jboss-integration/src/main/java/org/teiid/adminapi/jboss/ManagedUtil.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -35,6 +35,7 @@
 import org.jboss.deployers.spi.management.deploy.DeploymentProgress;
 import org.jboss.deployers.spi.management.deploy.DeploymentStatus;
 import org.jboss.managed.api.ManagedComponent;
+import org.jboss.managed.api.ManagedOperation;
 import org.jboss.managed.api.ManagedProperty;
 import org.jboss.metatype.api.types.MetaType;
 import org.jboss.metatype.api.types.SimpleMetaType;
@@ -45,7 +46,6 @@
 import org.jboss.metatype.api.values.SimpleValue;
 import org.jboss.metatype.api.values.SimpleValueSupport;
 import org.jboss.profileservice.spi.DeploymentOption;
-import org.teiid.adminapi.AdminException;
 import org.teiid.adminapi.AdminProcessingException;
 
 import com.metamatrix.core.MetaMatrixRuntimeException;
@@ -249,4 +249,12 @@
 		}
 	}
 	
+	public static MetaValue executeOperation(ManagedComponent mc, String operation, MetaValue... args) {
+		for (ManagedOperation mo:mc.getOperations()) {
+			if (mo.getName().equals(operation)) {
+				return mo.invoke(args);
+			}
+		}
+		throw new MetaMatrixRuntimeException("No operation found with given name =" + operation); 
+	}
 }

Modified: branches/JCA/jboss-integration/src/main/java/org/teiid/jboss/JBossContainerHelper.java
===================================================================
--- branches/JCA/jboss-integration/src/main/java/org/teiid/jboss/JBossContainerHelper.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/jboss-integration/src/main/java/org/teiid/jboss/JBossContainerHelper.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -33,6 +33,7 @@
 import org.teiid.ContainerHelper;
 import org.teiid.deployers.VDBRepository;
 import org.teiid.dqp.internal.datamgr.impl.ConnectorManagerRepository;
+import org.teiid.dqp.internal.process.DQPManagementView;
 
 import com.metamatrix.dqp.service.AuthorizationService;
 import com.metamatrix.dqp.service.BufferService;
@@ -118,4 +119,8 @@
 	public void setConnectorManagerRepository(ConnectorManagerRepository repo) {
 		addAttchment(ConnectorManagerRepository.class, repo);
 	}
+	
+	public void setDQPManager(DQPManagementView holder) {
+		addAttchment(DQPManagementView.class, holder);
+	}	
 }

Modified: branches/JCA/jboss-integration/src/main/java/org/teiid/jboss/deployers/ConnectorBindingDeployer.java
===================================================================
--- branches/JCA/jboss-integration/src/main/java/org/teiid/jboss/deployers/ConnectorBindingDeployer.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/jboss-integration/src/main/java/org/teiid/jboss/deployers/ConnectorBindingDeployer.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -113,20 +113,19 @@
 	@Override
 	public void build(DeploymentUnit unit, Set<String> attachmentNames, Map<String, ManagedObject> managedObjects)
 			throws DeploymentException {
-		//TODO: Need to link CM--> CB as management objects. rareddy
-		//		ConnectorManagerGroup cmGroup = unit.removeAttachment(ConnectorManagerGroup.class);
-		//		if (cmGroup != null) {
-		//			for (ConnectorManager mgr:cmGroup.getConnectorManagers()) {
-		//				ManagedObject mo = this.mof.initManagedObject(mgr, ConnectorManager.class, mgr.getName(), mgr.getName());
-		//				if (mo == null) {
-		//					throw new DeploymentException("could not create managed object");
-		//				}
-		//				managedObjects.put(mo.getName(), mo);				
-		//			}
-		//		}
+		
+		ConnectorManagerGroup cmGroup = unit.removeAttachment(ConnectorManagerGroup.class);
+		if (cmGroup != null) {
+			for (ConnectorManager mgr:cmGroup.getConnectorManagers()) {
+				ManagedObject mo = this.mof.initManagedObject(mgr, ConnectorManager.class, mgr.getName(), mgr.getName());
+				if (mo == null) {
+					throw new DeploymentException("could not create managed object");
+				}
+				managedObjects.put(mo.getName(), mo);				
+			}
+		}
 	}
 	
-	
 	public void setManagedObjectFactory(ManagedObjectFactory mof) {
 		this.mof = mof;
 	}	

Modified: branches/JCA/jboss-integration/src/main/java/org/teiid/templates/connector/ConnectorTypeTemplateInfo.java
===================================================================
--- branches/JCA/jboss-integration/src/main/java/org/teiid/templates/connector/ConnectorTypeTemplateInfo.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/jboss-integration/src/main/java/org/teiid/templates/connector/ConnectorTypeTemplateInfo.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -42,6 +42,7 @@
 import org.jboss.resource.metadata.ConfigPropertyMetaData;
 import org.jboss.resource.metadata.ConnectionDefinitionMetaData;
 import org.jboss.resource.metadata.ConnectorMetaData;
+import org.jboss.resource.metadata.DescriptionMetaData;
 import org.teiid.adminapi.jboss.ManagedUtil;
 
 /**
@@ -75,12 +76,12 @@
 	private void populate() {
 		try {
 			MBeanServer server = MBeanServerFactory.findMBeanServer(null).get(0);
-			ObjectName on = new ObjectName("jboss.jca:service=RARDeployment,name='"+getDescription()+"'");
+			ObjectName on = new ObjectName("jboss.jca:service=RARDeployment,name='"+getName()+".rar'");
 			ConnectorMetaData obj = (ConnectorMetaData)server.getAttribute(on, "MetaData");
 			ConnectionDefinitionMetaData metadata = obj.getConnectionDefinition("org.teiid.connector.api.Connector");
 			Collection<ConfigPropertyMetaData> props = metadata.getProperties();
 			for (ConfigPropertyMetaData p:props) {
-				addConnectorProperty(p.getName(), p.getType(), p.getDescription().getDescription(), p.getValue(), false);
+				addConnectorProperty(p);
 			}
 		} catch (MalformedObjectNameException e) {
 			//ignore
@@ -95,16 +96,18 @@
 		}		
 	}
 
-	private void addConnectorProperty(String name, String type, String description, String value, boolean readOnly) {
-		SimpleMetaType metaType = SimpleMetaType.resolve(type);
+	private void addConnectorProperty(ConfigPropertyMetaData metadata) {
+		SimpleMetaType metaType = SimpleMetaType.resolve(metadata.getType());
 		
-		DefaultFieldsImpl fields = new DefaultFieldsImpl(name);
-		fields.setDescription(description);		
+		DefaultFieldsImpl fields = new DefaultFieldsImpl(metadata.getName());
+		DescriptionMetaData descMetadata = metadata.getDescription();
+		String description = descMetadata.getDescription();
+		fields.setDescription(description);
 		fields.setMetaType(metaType);		
-		fields.setField(Fields.DEFAULT_VALUE, ManagedUtil.wrap(metaType, value));
-		fields.setField(Fields.READ_ONLY, readOnly);
+		fields.setField(Fields.DEFAULT_VALUE, ManagedUtil.wrap(metaType, metadata.getValue()));
+		fields.setField(Fields.READ_ONLY, false);
 		ManagedPropertyImpl dsTypeMP = new ManagedPropertyImpl(fields);
 		addProperty(dsTypeMP);
 	}
-
+	
 }

Modified: branches/JCA/jboss-integration/src/test/java/org/teiid/adminapi/jboss/BaseConnection.java
===================================================================
--- branches/JCA/jboss-integration/src/test/java/org/teiid/adminapi/jboss/BaseConnection.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/jboss-integration/src/test/java/org/teiid/adminapi/jboss/BaseConnection.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -25,6 +25,7 @@
 			ds.setServerName("localhost");
 			ds.setPortNumber(31000);
 			ds.setDatabaseName(vdbName);
+			ds.setTxnAutoWrap("PESSIMISTIC");
 			return ds.getConnection();
 		}
 	}
@@ -34,21 +35,25 @@
 		try {
 			connection.getMetaData();
 			Statement statement = connection.createStatement();
-			
-			ResultSet results = statement.executeQuery(sql);
-			
-			ResultSetMetaData metadata = results.getMetaData();
-			int columns = metadata.getColumnCount();
-			
-			while(results.next()) {
-				for (int i = 0; i < columns; i++) {
-					System.out.print(results.getString(i+1));
-					System.out.print(",");
+			boolean hasResults = statement.execute(sql);
+			if (hasResults) {
+				ResultSet results = statement.getResultSet();
+				ResultSetMetaData metadata = results.getMetaData();
+				int columns = metadata.getColumnCount();
+				
+				while(results.next()) {
+					for (int i = 0; i < columns; i++) {
+						System.out.print(results.getString(i+1));
+						System.out.print(",");
+					}
+					System.out.println("");
 				}
-				System.out.println("");
+				System.out.println("Done getting results!");
+				results.close();				
 			}
-			System.out.println("Done getting results!");
-			results.close();
+			else {
+				System.out.println("update count is="+statement.getUpdateCount());
+			}
 			statement.close();
 		} catch (SQLException e) {
 			e.printStackTrace();

Modified: branches/JCA/jboss-integration/src/test/java/org/teiid/adminapi/jboss/TestConnectorBindings.java
===================================================================
--- branches/JCA/jboss-integration/src/test/java/org/teiid/adminapi/jboss/TestConnectorBindings.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/jboss-integration/src/test/java/org/teiid/adminapi/jboss/TestConnectorBindings.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,34 +1,50 @@
 package org.teiid.adminapi.jboss;
 
 
+import static junit.framework.Assert.assertEquals;
 import static junit.framework.Assert.assertNotNull;
 import static junit.framework.Assert.assertNull;
 import static junit.framework.Assert.assertTrue;
+import static junit.framework.Assert.fail;
 
 import java.io.File;
+import java.util.Collection;
 import java.util.Properties;
 import java.util.Set;
 
+import org.junit.After;
 import org.junit.Before;
 import org.junit.Test;
 import org.teiid.adminapi.Admin;
+import org.teiid.adminapi.ConnectionPoolStatistics;
 import org.teiid.adminapi.ConnectorBinding;
+import org.teiid.adminapi.PropertyDefinition;
+import org.teiid.adminapi.Request;
+import org.teiid.adminapi.Session;
+import org.teiid.adminapi.Transaction;
 import org.teiid.adminapi.VDB;
+import org.teiid.adminapi.WorkerPoolStatistics;
 
 import com.metamatrix.core.util.UnitTestUtil;
 
 
 public class TestConnectorBindings extends BaseConnection {
 	ServerDatasourceConnection ds;
+	com.metamatrix.jdbc.api.Connection conn;
 	Admin admin;
 	
 	@Before
 	public void setUp() throws Exception {
 		//if (!Bootstrap.getInstance().isStarted()) Bootstrap.getInstance().bootstrap();
 		ds = new ServerDatasourceConnection();
-		com.metamatrix.jdbc.api.Connection conn = (com.metamatrix.jdbc.api.Connection)ds.getConnection("admin");
+		conn = (com.metamatrix.jdbc.api.Connection)ds.getConnection("admin");
 		admin = conn.getAdminAPI();		
 	}
+	
+	@After
+	public void tearDown() throws Exception {
+		this.conn.close();
+	}
 
 	@Test public void testConnectorBinding() throws Exception {
 		ConnectorBinding binding = admin.getConnectorBinding("test-mysql-cb");
@@ -45,8 +61,20 @@
 		
 		binding = admin.getConnectorBinding("test-mysql-cb");
 		
-		assertNotNull(binding);		
+		assertNotNull(binding);	
 		
+		assertEquals("java:DerbyDS", binding.getPropertyValue("SourceJNDIName"));
+		
+		admin.stopConnectorBinding(binding);
+		
+		admin.startConnectorBinding(binding);
+		
+		admin.setConnectorBindingProperty("test-mysql-cb", "SourceJNDIName", "DummyDS");
+		
+		binding = admin.getConnectorBinding("test-mysql-cb");
+		
+		assertEquals("DummyDS", binding.getPropertyValue("SourceJNDIName"));
+		
 		admin.deleteConnectorBinding("test-mysql-cb");
 		
 		binding = admin.getConnectorBinding("test-mysql-cb");
@@ -72,8 +100,146 @@
 		Set<VDB> vdbs = admin.getVDBs();
 		assertTrue(vdbs.size() >= 1);
 		
-//		admin.deleteVDB("TransactionsRevisited", 1);
-//		
-//		assertNull(admin.getVDB("TransactionsRevisited", 1));
+		Collection<ConnectorBinding> bindings = admin.getConnectorBindingsInVDB("TransactionsRevisited",1);
+		assertEquals(2, bindings.size());
+		
+		admin.deleteVDB("TransactionsRevisited", 1);
+		
+		assertNull(admin.getVDB("TransactionsRevisited", 1));
 	}
+	
+	
+	@Test public void testSessions() throws Exception{
+		Collection<Session> sessions = admin.getSessions();
+		assertTrue(sessions.size() >= 1);
+		for (Session s: sessions) {
+			assertEquals("ramesh at teiid-security", s.getUserName());
+		}
+		
+		for (Session s:sessions) {
+			admin.terminateSession(s.getSessionId());
+		}
+		
+		try {
+			sessions = admin.getSessions();
+			fail("Should have terminated this connection");
+		} catch(Exception e) {
+			//ok
+		}
+	}
+	
+	
+	@Test public void testRequests() throws Exception {
+		
+		VDB vdb = admin.getVDB("TransactionsRevisited", 1);
+		if (vdb == null) {
+			File f = UnitTestUtil.getTestDataFile("TransactionsRevisited.vdb");
+			admin.deployVDB(f.getName(), f.toURI().toURL());
+		}
+		
+		Runnable work = new Runnable() {
+			public void run() {
+				for (int i = 0; i < 5; i++) {
+					try {
+						execute(ds, "TransactionsRevisited", "select * from pm1.g1");
+					} catch (Exception e) {
+						e.printStackTrace();
+					}
+				}
+			}
+		};
+		Thread t = new Thread(work);
+		t.start();
+		
+		try {
+			Collection<Request> requests = admin.getRequests();
+			assertTrue(requests.size() > 0);
+		}finally {
+			t.join();
+		}
+		
+		long sessionId = 0;
+		Collection<Session> sessions = admin.getSessions();
+		for (Session s:sessions) {
+			sessionId = s.getSessionId();
+		}		
+		
+		t = new Thread(work);
+		t.start();
+		
+		try {
+			Collection<Request> requests = admin.getRequestsForSession(sessionId);
+			assertTrue(requests.size() >= 0);	
+		} finally {
+			t.join();
+			admin.deleteVDB("TransactionsRevisited", 1);
+		}
+	}
+	
+	@Test
+	public void testCache() throws Exception {
+		Collection<String> caches = admin.getCacheTypes();
+		assertEquals(4, caches.size());
+		
+		admin.clearCache("CODE_TABLE_CACHE");
+	}
+	
+	@Test
+	public void testTransactions() throws Exception {
+		
+		VDB vdb = admin.getVDB("TransactionsRevisited", 1);
+		if (vdb == null) {
+			File f = UnitTestUtil.getTestDataFile("TransactionsRevisited.vdb");
+			admin.deployVDB(f.getName(), f.toURI().toURL());
+		}
+		
+		Runnable work = new Runnable() {
+			public void run() {
+				try {
+					for (int i = 0; i < 10; i++) {
+						int v = i+200;
+						execute(ds, "TransactionsRevisited", "insert into vm.g1 (pm1e1, pm1e2, pm2e1, pm2e2) values("+v+",'"+v+"',"+v+",'"+v+"')");
+					}
+					execute(ds, "TransactionsRevisited", "delete from vm.g1 where pm1e1 >= 200");
+				} catch (Exception e) {
+					e.printStackTrace();
+				}
+			}
+		};
+		
+		Thread t = new Thread(work);
+		t.start();
+		Thread.sleep(2000);
+		try {
+			Collection<Transaction> txns = admin.getTransactions();
+			assertTrue(txns.size() >= 0);
+		} finally {
+			t.join();
+			admin.deleteVDB("TransactionsRevisited", 1);
+		}
+	}
+	
+	@Test
+	public void testWorkmanagerStats() throws Exception {
+		WorkerPoolStatistics stats = admin.getWorkManagerStats("runtime");
+		System.out.println(stats);
+	}
+	
+	@Test
+	public void testConnectionPool() throws Exception {
+		ConnectionPoolStatistics stats = admin.getConnectorConnectionPoolStats("mysql-connector-binding");
+		System.out.println(stats);
+	}
+	
+	@Test
+	public void testConnectorTypeProperties() throws Exception {
+		Collection<PropertyDefinition> defs = admin.getConnectorTypePropertyDefinitions("connector-jdbc-7.0.0-SNAPSHOT");
+		System.out.println(defs);
+	}
+	
+	@Test
+	public void testConnectorTypes() throws Exception {
+		Set<String> defs = admin.getConnectorTypes();
+		System.out.println(defs);
+	}	
 }

Deleted: branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/BaseAdmin.java
===================================================================
--- branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/BaseAdmin.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/BaseAdmin.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,615 +0,0 @@
-/*
- * 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 com.metamatrix.dqp.embedded.admin;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import java.util.Properties;
-
-import org.teiid.adminapi.AdminComponentException;
-import org.teiid.adminapi.AdminException;
-import org.teiid.adminapi.AdminObject;
-import org.teiid.adminapi.AdminProcessingException;
-import org.teiid.adminapi.Cache;
-import org.teiid.adminapi.ExtensionModule;
-import org.teiid.dqp.internal.process.DQPWorkContext;
-import org.teiid.dqp.internal.process.Util;
-
-import com.metamatrix.admin.objects.MMConnectorType;
-import com.metamatrix.admin.objects.MMExtensionModule;
-import com.metamatrix.admin.objects.MMLogConfiguration;
-import com.metamatrix.admin.objects.MMPropertyDefinition;
-import com.metamatrix.admin.objects.MMRequest;
-import com.metamatrix.common.config.api.ComponentType;
-import com.metamatrix.common.config.api.ComponentTypeDefn;
-import com.metamatrix.common.config.api.ConnectorBinding;
-import com.metamatrix.common.log.LogConfigurationImpl;
-import com.metamatrix.common.object.PropertyDefinition;
-import com.metamatrix.common.util.crypto.CryptoException;
-import com.metamatrix.common.util.crypto.CryptoUtil;
-import com.metamatrix.common.vdb.api.VDBArchive;
-import com.metamatrix.dqp.embedded.DQPEmbeddedPlugin;
-import com.metamatrix.jdbc.EmbeddedConnectionFactoryImpl;
-import com.metamatrix.platform.security.api.SessionToken;
-import com.metamatrix.server.serverapi.RequestInfo;
-
-
-/** 
- * @since 4.3
- */
-abstract class BaseAdmin {
-    static final String DOT = "."; //$NON-NLS-1$
-    static final String STAR = "*"; //$NON-NLS-1$
-    static final String FILE_NAME_REGEX="\\w+\\.\\w+"; //$NON-NLS-1$
-    static final String MULTIPLE_WORDS_REGEX = "\\w+([\\s|-]*\\w)*"; //$NON-NLS-1$
-    static final String SINGLE_WORD_REGEX = "\\w+"; //$NON-NLS-1$    
-    static final String MULTIPLE_WORD_WILDCARD_REGEX = "\\w*((\\.)?\\s*\\w)*(\\*)?"; //$NON-NLS-1$
-    static final String SINGLE_WORD_WILDCARD_REGEX = "\\w*(\\*)?"; //$NON-NLS-1$
-    // This should find word.word.* or word.* kind of patterns (ugly, you can rewrite) 
-    static final String WORD_AND_DOT_WILDCARD_REGEX = "\\w+((\\.\\*)|(\\.\\w+)|(\\.\\w*\\*))*|\\w*(\\*){1}"; //$NON-NLS-1$
-    
-    static final String VDB_REGEX = "\\w*(\\*)?(\\.\\d+)?"; //$NON-NLS-1$
-    static final String NUMBER_DOT_REGEX = "\\d+((\\.\\*)|(\\.\\d+)|(\\.\\d*\\*))*|\\d*(\\*){1}"; //$NON-NLS-1$
-    static final String NUMBER_REGEX = "\\d*(\\*)?"; //$NON-NLS-1$
-        
-    static final String[] cacheTypes = {Cache.CODE_TABLE_CACHE, 
-        Cache.CONNECTOR_RESULT_SET_CACHE,
-        Cache.PREPARED_PLAN_CACHE,
-        Cache.QUERY_SERVICE_RESULT_SET_CACHE
-        };    
-    
-    private EmbeddedConnectionFactoryImpl manager = null; 
-    
-    BaseAdmin(EmbeddedConnectionFactoryImpl manager){
-        this.manager = manager;       
-    }
-            
-    protected AdminException accumulateSystemException(AdminException parent, Exception e) {
-        if (parent == null) {
-            return new AdminComponentException(e); 
-        }
-        parent.addChild(new AdminComponentException(e));
-        return parent;
-    }
-    
-    protected AdminException accumulateProcessingException(AdminException parent, Exception e) {
-        if (parent == null) {
-            return new AdminProcessingException(e); 
-        }
-        parent.addChild(new AdminProcessingException(e));
-        return parent;
-    }
-    
-    protected String prettyPrintBindingNames(List bindings) {
-        StringBuffer buffer = new StringBuffer();
-        for (Iterator iter = bindings.iterator(); iter.hasNext();) {
-            ConnectorBinding binding = (ConnectorBinding) iter.next();
-            buffer.append(binding.getDeployedName());
-            if (iter.hasNext()) {
-                buffer.append(", "); //$NON-NLS-1$
-            }
-        }
-        
-        return buffer.toString();
-    }
-    
-    /** 
-     * @return Returns the manager.
-     * @since 4.3
-     */
-    public EmbeddedConnectionFactoryImpl getManager() {
-        return this.manager;
-    }
-    
-    
-    protected Object convertToAdminObjects(Object src) {
-        return convertToAdminObjects(src,null);
-    }
-    
-    protected Object convertToAdminObjects(Object src, Object parent) {
-        if (src == null) {
-            return src;
-        }
-        
-        if (src instanceof List) {
-            List modified = new ArrayList();
-            List list = (List)src;
-            for (final Iterator i = list.iterator(); i.hasNext();) {
-                final Object e = i.next();
-                Object converted = convertToAdminObject(e, parent);
-                modified.add(converted);
-            } 
-            return modified;
-        }
-        else if (src instanceof Collection) {
-            List modified = new ArrayList();
-            for (Iterator i = ((Collection)src).iterator(); i.hasNext();) {
-                final Object e = i.next();
-                Object converted = convertToAdminObject(e, parent);
-                modified.add(converted);
-            } 
-            return modified;
-        }
-        else if (src instanceof Object[] ) {
-            List modified = new ArrayList();
-            Object[] srcArray = (Object[])src;
-            for (int i = 0; i < srcArray.length; i++) {
-                final Object converted = convertToAdminObject(srcArray[i], parent);
-                modified.add(converted);                
-            }
-            return modified;
-        }
-        return convertToAdminObject(src, parent);
-    }    
-        
-    
-    private Object convertToAdminObject(Object src, Object parent) {
-        if (src != null && src instanceof com.metamatrix.common.config.api.ConnectorBinding) {
-            com.metamatrix.common.config.api.ConnectorBinding binding = (com.metamatrix.common.config.api.ConnectorBinding)src;
-            return convertConnectorType(binding, parent);
-        }
-        else if (src != null && src instanceof com.metamatrix.common.config.api.ConnectorBindingType) {
-            com.metamatrix.common.config.api.ConnectorBindingType type = (com.metamatrix.common.config.api.ConnectorBindingType)src;
-            return convertConnectorType(type, parent);
-        }
-        else if (src != null && src instanceof com.metamatrix.common.vdb.api.VDBDefn) {
-            com.metamatrix.common.vdb.api.VDBDefn vdb = (com.metamatrix.common.vdb.api.VDBDefn)src;
-            return convertVDB(vdb, parent);
-        }
-        else if (src != null && src instanceof VDBArchive) {
-        	VDBArchive vdb = (VDBArchive)src;
-            return convertVDB(vdb.getConfigurationDef(), parent);
-        }        
-        else if (src != null && src instanceof com.metamatrix.common.vdb.api.ModelInfo) {
-            com.metamatrix.common.vdb.api.ModelInfo model = (com.metamatrix.common.vdb.api.ModelInfo)src;
-            return convertModel(model, parent);
-        }
-        else if (src != null && src instanceof com.metamatrix.common.log.LogConfiguration) {
-            com.metamatrix.common.log.LogConfiguration config = (com.metamatrix.common.log.LogConfiguration)src;
-            return covertLogConfiguration(config);
-        }
-        else if (src != null && src instanceof com.metamatrix.server.serverapi.RequestInfo) {
-        	com.metamatrix.server.serverapi.RequestInfo request = (com.metamatrix.server.serverapi.RequestInfo)src;
-            return convertRequest(request);
-        }
-        else if (src != null && src instanceof com.metamatrix.common.queue.WorkerPoolStats) {
-            com.metamatrix.common.queue.WorkerPoolStats stats = (com.metamatrix.common.queue.WorkerPoolStats)src;
-            return Util.convertStats(stats, stats.getQueueName());
-        }
-//        else if (src != null && src instanceof MetaMatrixSessionInfo) {
-//        	MetaMatrixSessionInfo conn = (MetaMatrixSessionInfo)src;
-//            return convertConnection(conn);
-//        }
-        else if (src != null && src instanceof com.metamatrix.common.config.api.ExtensionModule) {
-            com.metamatrix.common.config.api.ExtensionModule extModule = (com.metamatrix.common.config.api.ExtensionModule)src;
-            return convertExtensionModule(extModule);
-        }         
-        else {
-        	if (src == null) {
-        		return null;
-        	}
-            throw new UnsupportedOperationException(DQPEmbeddedPlugin.Util.getString("UnSupported_object_conversion"));  //$NON-NLS-1$
-        }
-    }
-
-    Object convertToNativeObjects(Object src) {
-        if (src instanceof org.teiid.adminapi.LogConfiguration) {
-            org.teiid.adminapi.LogConfiguration config = (org.teiid.adminapi.LogConfiguration)src;
-            return covertToNativeLogConfiguration(config);
-        }
-        throw new UnsupportedOperationException(DQPEmbeddedPlugin.Util.getString("UnSupported_object_conversion"));  //$NON-NLS-1$            
-    }
-     
-    
-    private ExtensionModule convertExtensionModule(com.metamatrix.common.config.api.ExtensionModule src) {
-        MMExtensionModule module = new MMExtensionModule(new String[] {src.getFullName()}) ;
-        module.setDescription(src.getDescription());
-        module.setFileContents(src.getFileContents());
-        module.setModuleType(src.getModuleType());
-        return module;
-    }
-    
-//    private Session convertConnection(MetaMatrixSessionInfo src) {
-//        MMSession session = new MMSession(new String[] {src.getSessionID().toString()});
-//        session.setVDBName(src.getProductInfo(MMURL.JDBC.VDB_NAME));
-//        session.setVDBVersion(src.getProductInfo(MMURL.JDBC.VDB_VERSION)); 
-//        session.setApplicationName(src.getApplicationName());
-//        session.setIPAddress(src.getClientIp());
-//        session.setHostName(src.getClientHostname());
-//        session.setUserName(src.getUserName());
-//        session.setLastPingTime(src.getLastPingTime());
-//        session.setCreated(new Date(src.getTimeCreated()));
-//        return session;
-//    }
-    
-    /**
-     * Convert LogConfiguration to Admin Object 
-     */
-    private org.teiid.adminapi.LogConfiguration covertLogConfiguration(final com.metamatrix.common.log.LogConfiguration src) {
-    	Map<String, Integer> contextMap = new HashMap<String, Integer>();
-    	for(String context:src.getContexts()) {
-    		contextMap.put(context, src.getLogLevel(context));
-    	}
-        return new MMLogConfiguration(contextMap);
-    }
-
-    /**
-     * Convert LogConfiguration to Admin Object 
-     */
-    private com.metamatrix.common.log.LogConfiguration covertToNativeLogConfiguration(final org.teiid.adminapi.LogConfiguration src) {
-    	Map<String, Integer> contextMap = new HashMap<String, Integer>();
-    	for(String context:src.getContexts()) {
-    		contextMap.put(context, src.getLogLevel(context));
-    	}
-    	return new LogConfigurationImpl(contextMap);
-    }
-
-    /** 
-     * @param binding
-     * @return
-     * @since 4.3
-     */
-    private org.teiid.adminapi.ConnectorBinding convertConnectorType(final com.metamatrix.common.config.api.ConnectorBinding src, final Object parent) {
-//        MMConnectorBinding binding = new MMConnectorBinding(new String[] {src.getDeployedName()});
-//        
-//        binding.setConnectorTypeName(src.getComponentTypeID().getFullName());
-//        binding.setCreated(src.getCreatedDate());
-//        binding.setCreatedBy(src.getCreatedBy());
-//        binding.setDescription(src.getDescription());
-//        binding.setEnabled(src.isEnabled());
-//        binding.setLastUpdated(src.getLastChangedDate());
-//        binding.setLastUpdatedBy(src.getLastChangedBy());
-//        binding.setProperties(src.getProperties());
-//        binding.setRegistered(true);
-//        binding.setRoutingUUID(src.getRoutingUUID());
-//        binding.setServiceID(0); // TODO:
-        
-        // Binding state needs to be converted into pool state; until then we use
-        // binding state  as pool state.
-//        try {
-//        	ConnectorStatus status = getDataService().getConnectorBindingState(src.getDeployedName());
-//        	switch(status) {
-//        	case OPEN:
-//        		binding.setState(org.teiid.adminapi.ConnectorBinding.STATE_OPEN);
-//        		break;
-//        	case NOT_INITIALIZED:
-//        		binding.setState(org.teiid.adminapi.ConnectorBinding.STATE_NOT_INITIALIZED);
-//        		break;
-//        	case CLOSED:
-//        		binding.setState(org.teiid.adminapi.ConnectorBinding.STATE_CLOSED);
-//        		break;
-//        	case DATA_SOURCE_UNAVAILABLE:
-//        		binding.setState(org.teiid.adminapi.ConnectorBinding.STATE_DATA_SOURCE_UNAVAILABLE);
-//        		break;
-//        	case INIT_FAILED:
-//        		binding.setState(org.teiid.adminapi.ConnectorBinding.STATE_INIT_FAILED);
-//        		break;
-//        	case UNABLE_TO_CHECK:
-//        		binding.setState(org.teiid.adminapi.ConnectorBinding.STATE_FAILED_TO_CHECK);
-//        		break;
-//        	}        	
-//        }catch(MetaMatrixComponentException e) {
-//            binding.setState(org.teiid.adminapi.ConnectorBinding.STATE_NOT_DEPLOYED);            
-//        }
-//        binding.setStateChangedTime(src.getLastChangedDate());
-//        return binding;
-    	return null;
-    }
-
-    /** 
-     * @param type
-     * @return
-     * @since 4.3
-     */
-    private org.teiid.adminapi.ConnectorType convertConnectorType(final com.metamatrix.common.config.api.ConnectorBindingType src, final Object parent) {
-        MMConnectorType type = new MMConnectorType(new String[] {src.getName()});
-        type.setCreated(src.getCreatedDate());
-        type.setCreatedBy(src.getCreatedBy());
-        type.setEnabled(true);
-        type.setLastUpdated(src.getLastChangedDate());
-        type.setRegistered(true);
-        
-        return type;       
-    }
-
-    /** 
-     * @param vdb
-     * @return
-     * @since 4.3
-     */
-    private org.teiid.adminapi.VDB convertVDB(final com.metamatrix.common.vdb.api.VDBDefn src, final Object parent) {
-        
-//        MMVDB vdb = new MMVDB(new String[] {src.getName(), src.getVersion()});
-//        vdb.setCreated(src.getDateCreated());
-//        vdb.setCreatedBy(src.getCreatedBy());
-//        vdb.setEnabled(src.isActiveStatus());
-//        vdb.setLastUpdated(src.getDateCreated());
-//        vdb.setLastUpdatedBy(src.getCreatedBy());
-//        vdb.setMaterializedViews(src.getMatertializationModel() != null);
-//        vdb.setModels((Collection)convertToAdminObjects(src.getModels(), src));
-//        vdb.setProperties(null);
-//        vdb.setRegistered(true);
-//        vdb.setStatus(src.getStatus());
-//        vdb.setUID(0); // TODO: src.getUUID());
-//        vdb.setVersionedBy(src.getCreatedBy());
-//        vdb.setVersionedDate(src.getDateCreated());
-//        vdb.setHasWSDL(src.hasWSDLDefined());
-//        
-//        return vdb;        
-    	return null;
-    }
-    
-    private org.teiid.adminapi.Model convertModel(final com.metamatrix.common.vdb.api.ModelInfo src, final Object parent) {
-//        final com.metamatrix.common.vdb.api.VDBDefn vdb = (com.metamatrix.common.vdb.api.VDBDefn)parent;
-//        MMModel model = new MMModel(new String[] {src.getName()});
-//        model.setCreated(vdb.getDateCreated());
-//        model.setCreatedBy(vdb.getCreatedBy());
-//        model.setEnabled(vdb.isActiveStatus());
-//        model.setLastUpdated(vdb.getDateCreated());
-//        model.setLastUpdatedBy(vdb.getCreatedBy());
-//        model.setModelType(src.getModelTypeName());
-//        model.setModelURI(src.getModelURI());
-//        model.setMaterialization(src.isMaterialization());
-//        model.setPhysical(src.isPhysical());
-//        model.setRegistered(true);        
-//        model.setSupportsMultiSourceBindings(src.isMultiSourceBindingEnabled());
-//        model.setVisible(src.isVisible());
-//        if (src.isPhysical()) {
-//            List bindings = src.getConnectorBindingNames();
-//            if (bindings != null && !bindings.isEmpty()) {
-//                List names = new ArrayList();
-//                for (int i=0; i<bindings.size();i++) {
-//                    names.add(convertToAdminObject(vdb.getConnectorBindingByName((String)bindings.get(i)), parent));
-//                }
-//                model.setConnectorBindingNames(names);
-//            }
-//        }
-//        return model;
-    	return null;
-    }
-
-    private org.teiid.adminapi.Request convertRequest(final RequestInfo src) {
-        
-        String connId = src.getRequestID().getConnectionID();
-        
-        MMRequest request = null;
-        if (src.getConnectorBindingUUID() != null) {
-            request = new MMRequest(new String[] {connId, String.valueOf(src.getRequestID().getExecutionID()), String.valueOf(src.getNodeID()), String.valueOf(src.getExecutionID())}); 
-        }
-        else {
-            request = new MMRequest(new String[] {connId, String.valueOf(src.getRequestID().getExecutionID())}); 
-        }
-        
-        request.setSqlCommand(src.getCommand());
-        
-        request.setCreated(src.getProcessingTimestamp());
-        
-        if (src.getConnectorBindingUUID() != null) {
-            request.setSource(true);
-            request.setNodeID(String.valueOf(src.getNodeID()));
-        }
-        return request;
-    }
-    
-    /**
-     * Get the connection connection object for the given id. 
-     * @param identifier
-     * @return
-     * @since 4.3
-     */
-//    MetaMatrixSessionInfo getClientConnection(String identifier) throws AdminException {
-//        Collection<MetaMatrixSessionInfo> sessions = getClientConnections();
-//        for (MetaMatrixSessionInfo info:sessions) {
-//            if (info.getSessionID().toString().equals(identifier)) {
-//                return info;
-//            }
-//        }
-//        return null;
-//    }
-
-    /**
-     * Get all the available connections 
-     * @return
-     * @throws AdminException
-     */
-//    Collection<MetaMatrixSessionInfo> getClientConnections() throws AdminException {
-//        try {
-//			return getSessionService().getActiveSessions();
-//		} catch (SessionServiceException e) {
-//			// SessionServiceException not in the client known exception (in common-internal)
-//			throw new AdminComponentException(e.getMessage(), e.getCause());
-//		}
-//    	return null;
-//    }
-
-    boolean matches(String regEx, String value) {
-        regEx = regEx.replaceAll(AdminObject.ESCAPED_WILDCARD, ".*"); //$NON-NLS-1$ 
-        regEx = regEx.replaceAll(AdminObject.ESCAPED_DELIMITER, ""); //$NON-NLS-1$ 
-        return value.matches(regEx);
-    }
-    
-    List matchedCollection(String identifier, List adminObjects) {
-        ArrayList matched = new ArrayList();
-        for (Iterator i = adminObjects.iterator(); i.hasNext();) {
-            AdminObject aObj = (AdminObject)i.next();
-            if (matches(identifier, aObj.getName()) || matches(identifier, aObj.getName())) {
-                matched.add(aObj);
-            }
-        }        
-        return matched;
-    }
-    
-    /**
-     * Get list of available connector bindings 
-     * @param identifier
-     */
-    Collection getConnectorBindings(String identifier) throws AdminException{
-//        try {
-//            List connectorBindings = getDataService().getConnectorBindings();
-//            connectorBindings = (List)convertToAdminObjects(connectorBindings);
-//            return matchedCollection(identifier, connectorBindings);
-//        } catch (MetaMatrixComponentException e) {
-//            throw new AdminComponentException(e);
-//        }
-    	return Collections.EMPTY_LIST;
-    }
-    
-    
-    /**
-     * Get list of available connector types 
-     * @param identifier
-     */
-    Collection getConnectorTypes(String identifier) throws AdminException{
-   
-//        try {
-//            List connectorTypes = getConfigurationService().getConnectorTypes();
-//            connectorTypes = (List)convertToAdminObjects(connectorTypes);
-//            return matchedCollection(identifier, connectorTypes);
-//        } catch (MetaMatrixComponentException err) {
-//            throw new AdminComponentException(err);
-//        } 
-    	return null;
-    }
-
-    boolean isMaskedProperty(String  propName, ComponentType type) {
-        if (type != null) {
-            ComponentTypeDefn typeDef = type.getComponentTypeDefinition(propName);
-            if (typeDef != null && typeDef.getPropertyDefinition().isMasked()) {
-                return true;
-            }
-        }
-        return false;
-    }
-    
-    /**
-     * Encrypt a string 
-     * @param value
-     * @return
-     * @throws AdminException
-     * @since 4.3
-     */
-    String encryptString(String value) throws AdminException {
-        try {
-            return CryptoUtil.stringEncrypt(value);
-        } catch (CryptoException e) {
-            throw new AdminComponentException(e);
-        }
-    }
-    
-    
-    
-    /**
-     * Convert a ComponentType and a set of properties into a Collection of 
-     * com.metamatrix.admin.api.objects.PropertyDefinition objects
-     * @param ctype
-     * @param properties
-     * @return
-     * @since 4.3
-     */
-    protected Collection convertPropertyDefinitions(ComponentType ctype, Properties properties) {
-        ArrayList results = new ArrayList();
-        for (Iterator iter = ctype.getComponentTypeDefinitions().iterator(); iter.hasNext(); ) {
-            ComponentTypeDefn cdefn = (ComponentTypeDefn) iter.next();
-            PropertyDefinition pdefn = cdefn.getPropertyDefinition();
-                        
-            MMPropertyDefinition result = new MMPropertyDefinition(new String[] {pdefn.getName()});
-            result.setAllowedValues(pdefn.getAllowedValues());
-            result.setDefaultValue(pdefn.getDefaultValue());
-            result.setDescription(pdefn.getShortDescription());
-            result.setDisplayName(pdefn.getDisplayName());
-            result.setExpert(pdefn.isExpert());
-            result.setMasked(pdefn.isMasked());
-            result.setModifiable(pdefn.isModifiable());
-            result.setPropertyType(pdefn.getPropertyType().getDisplayName());
-            result.setPropertyTypeClassName(pdefn.getPropertyType().getClassName());
-            result.setRequired(pdefn.isRequired());
-            result.setRequiresRestart(pdefn.getRequiresRestart());
-            
-            String value = properties.getProperty(pdefn.getName());
-            result.setValue(value);
-            
-            results.add(result);
-        }
-        
-        
-        return results;
-    }
-    
-    
-    /**
-     * Convert a set of properties into a Collection of 
-     * com.metamatrix.admin.api.objects.PropertyDefinition objects
-     *  
-     * @param ctype
-     * @param properties
-     * @return
-     * @since 4.3
-     */
-    protected Collection convertPropertyDefinitions(Properties properties) {
-        ArrayList results = new ArrayList();
-        for (Iterator iter = properties.keySet().iterator(); iter.hasNext(); ) {
-            String key = (String) iter.next();
-            String value = properties.getProperty(key);
-                        
-            MMPropertyDefinition result = new MMPropertyDefinition(new String[] {key});
-            result.setDisplayName(key);
-            result.setValue(value);
-            
-            results.add(result);
-        }
-        
-        
-        return results;
-    }
-    
-    protected SessionToken validateSession() {
-        return DQPWorkContext.getWorkContext().getSessionToken();
-    }
-    
-    protected void changeVDBStatus(String name, String version, int status)
-			throws AdminException {
-//		try {
-//
-//			if (name == null || version == null || !name.matches(SINGLE_WORD_REGEX)) {
-//				throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_vdb_name")); //$NON-NLS-1$
-//			}
-//
-//			// Now change the VDB status it self
-//			this.getVDBService().changeVDBStatus(name, version, status);
-//
-//			// If the VDB is modified and if its status changed to DELETED, then
-//			// we can remove all the connector bindings associated with this VDB
-//			// the above delete will also remove them
-//		} catch (ApplicationLifecycleException e) {
-//			throw new AdminComponentException(e);
-//		} catch (MetaMatrixComponentException e) {
-//			throw new AdminComponentException(e);
-//		}
-	}    
-    
-}

Deleted: branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPConfigAdminImpl.java
===================================================================
--- branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPConfigAdminImpl.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPConfigAdminImpl.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,1060 +0,0 @@
-/*
- * 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 com.metamatrix.dqp.embedded.admin;
-
-import java.io.IOException;
-import java.io.StringWriter;
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Properties;
-
-import org.teiid.adminapi.AdminComponentException;
-import org.teiid.adminapi.AdminException;
-import org.teiid.adminapi.AdminOptions;
-import org.teiid.adminapi.AdminProcessingException;
-import org.teiid.adminapi.ConfigurationAdmin;
-import org.teiid.adminapi.EmbeddedLogger;
-import org.teiid.adminapi.LogConfiguration;
-import org.teiid.adminapi.VDB;
-
-import com.metamatrix.api.exception.MetaMatrixComponentException;
-import com.metamatrix.common.application.exception.ApplicationLifecycleException;
-import com.metamatrix.common.config.api.ComponentType;
-import com.metamatrix.common.config.api.ComponentTypeDefn;
-import com.metamatrix.common.config.api.ConnectorArchive;
-import com.metamatrix.common.config.api.ConnectorBinding;
-import com.metamatrix.common.config.api.ConnectorBindingType;
-import com.metamatrix.common.config.api.ExtensionModule;
-import com.metamatrix.common.log.LogManager;
-import com.metamatrix.common.util.crypto.CryptoException;
-import com.metamatrix.common.util.crypto.CryptoUtil;
-import com.metamatrix.common.vdb.api.VDBArchive;
-import com.metamatrix.common.vdb.api.VDBDefn;
-import com.metamatrix.core.vdb.VDBStatus;
-import com.metamatrix.dqp.embedded.DQPEmbeddedPlugin;
-import com.metamatrix.dqp.embedded.configuration.ConnectorConfigurationReader;
-import com.metamatrix.dqp.embedded.configuration.VDBConfigurationReader;
-import com.metamatrix.jdbc.EmbeddedConnectionFactoryImpl;
-
-
-/** 
- * DQP implementation of the Config Admin API
- * @since 4.3
- */
-public abstract class DQPConfigAdminImpl extends BaseAdmin implements ConfigurationAdmin {
-    
-    public DQPConfigAdminImpl(EmbeddedConnectionFactoryImpl manager) {
-        super(manager);
-    }
-
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#setProperty(java.lang.String, java.lang.String, java.lang.String, java.lang.String)
-     * @since 4.3
-     */
-    public void setConnectorBindingProperty(String deployedName, String propertyName, String propertyValue)
-        throws AdminException {
-
-//        try {
-//			ConnectorBinding binding = getConfigurationService().getConnectorBinding(deployedName);
-//			if (binding == null) {
-//				throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.cb_doesnot_exist", deployedName)); //$NON-NLS-1$
-//			}
-//			
-//			ComponentTypeID id = binding.getComponentTypeID();
-//			ConnectorBindingType type = getConfigurationService().getConnectorType(id.getName());
-//			
-//			boolean needsEncryption = isMaskedProperty(propertyName, type);
-//			if (needsEncryption) {
-//			    propertyValue = encryptString(propertyValue);
-//			}
-//			
-//			Properties p = new Properties();
-//			p.setProperty(propertyName, propertyValue);
-//			
-//			//update the configuration
-//			binding = ConnectorConfigurationReader.addConnectorBindingProperties(binding, p);
-//			getConfigurationService().updateConnectorBinding(binding);
-//		} catch (MetaMatrixComponentException e) {
-//			throw new AdminComponentException(e);
-//		}
-    }
-    
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#addConnectorType(java.lang.String, char[])
-     * @since 4.3
-     */
-    public void addConnectorType(String deployName, char[] cdkFile) 
-        throws AdminException {
-//        try {
-//            if (deployName == null || !deployName.matches(MULTIPLE_WORDS_REGEX)) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_ct_name")); //$NON-NLS-1$                
-//            }
-//            if (cdkFile == null || cdkFile.length == 0) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_ct_source")); //$NON-NLS-1$
-//            }
-//            
-//            // This is only place we check the existence in admin. Generally the Admin is not the
-//            // guy to decide, if it can take in or not, it should be the service. I did not 
-//            // want add in the configuration service beacuse, it may need to allow this behavior 
-//            // in case we are updating.  
-//            if (getConfigurationService().getConnectorType(deployName) == null) {            
-//                ConnectorBindingType type = ConnectorConfigurationReader.loadConnectorType(cdkFile);            
-//                saveConnectorType(type);
-//            }
-//            else {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Connector_type_exists", deployName)); //$NON-NLS-1$
-//            }
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//		}            
-    }
-
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#deleteConnectorType(java.lang.String)
-     * @since 4.3
-     */
-    public void deleteConnectorType(String deployName) 
-        throws AdminException {
-//        try {
-//            if (deployName == null || !deployName.matches(MULTIPLE_WORDS_REGEX)) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_ct_name")); //$NON-NLS-1$                
-//            }            
-//            getConfigurationService().deleteConnectorType(deployName);
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//		}         
-    }
-
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#addConnectorBinding(java.lang.String, java.lang.String, java.util.Properties, AdminOptions)
-     * @since 4.3
-     */
-    public org.teiid.adminapi.ConnectorBinding addConnectorBinding(String deployName, String type, Properties properties, AdminOptions options) 
-        throws AdminException {
-//        // if the options object is null treat as if it is IGNORE as default
-//        if (options == null) {
-//            options = new AdminOptions(AdminOptions.OnConflict.IGNORE);
-//        }
-//
-//        if (deployName == null || !deployName.matches(MULTIPLE_WORDS_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_cb_name")); //$NON-NLS-1$                
-//        }
-//        
-//        if (type == null || !type.matches(MULTIPLE_WORDS_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_ct_name")); //$NON-NLS-1$                
-//        }
-//                
-//        ConnectorBinding binding = null;
-//        try {
-//            // Check if the binding exists already, if does take action based on user
-//            // preferences in the admin options
-//            if (bindingExists(deployName)) {
-//                // Based on users preference, either add or replace or ignore 
-//                if (options.containsOption(AdminOptions.OnConflict.EXCEPTION)) {
-//                    throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.addBindingEixists", deployName)); //$NON-NLS-1$
-//                }
-//                else if (options.containsOption(AdminOptions.OnConflict.IGNORE)) {
-//                    binding = getDataService().getConnectorBinding(deployName);
-//                    return (org.teiid.adminapi.ConnectorBinding) convertToAdminObjects(binding);
-//                }
-//            }
-//            
-//            // Get the connector type
-//            ConnectorBindingType ctype = getConfigurationService().getConnectorType(type);
-//            if (ctype == null) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.connector_type_not_exists", type)); //$NON-NLS-1$
-//            }
-//            
-//            // Build the connector binding with informatin we know.
-//            binding = ConnectorConfigurationReader.loadConnectorBinding(deployName, properties, ctype);
-//            
-//            // Check that the connector binding passwords can be decrypted
-//            try {
-//            	checkDecryption(binding, ctype);
-//            } catch(CryptoException e) {
-//            	if (!options.containsOption(AdminOptions.BINDINGS_IGNORE_DECRYPT_ERROR)) {
-//            		throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.CODE_DECRYPTION_FAILED", binding.getFullName())); //$NON-NLS-1$		
-//            	}
-//            }
-//            
-//            // now that all of the input parameters validated, add the connector binding
-//            binding = addConnectorBinding(deployName, binding, ctype, false);
-//            
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }
-//        return (org.teiid.adminapi.ConnectorBinding) convertToAdminObjects(binding);
-    	
-    	return null;
-    }
-
-    boolean bindingExists(String name) throws MetaMatrixComponentException {
-//        ConnectorBinding binding = getDataService().getConnectorBinding(name);
-//        return (binding != null);
-    	return false;
-    }
-    
-    boolean bindingTypeExists(String name) throws MetaMatrixComponentException {
-//        ConnectorBindingType type = getConfigurationService().getConnectorType(name);
-//        return (type != null);
-    	return false;
-    }
-    
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#addConnectorBinding(java.lang.String, char[], AdminOptions)
-     * @since 4.3
-     */
-    public org.teiid.adminapi.ConnectorBinding addConnectorBinding(String deployName, char[] xmlFile, AdminOptions options) 
-        throws AdminException {
-        
-//        // if the options object is null treat as if it is IGNORE as default
-//        if (options == null) {
-//            options = new AdminOptions(AdminOptions.OnConflict.IGNORE);
-//        }
-//
-//        if (deployName == null || !deployName.matches(MULTIPLE_WORDS_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_cb_name")); //$NON-NLS-1$                
-//        }
-//        if (xmlFile == null || xmlFile.length == 0) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_cb_source")); //$NON-NLS-1$
-//        }
-//                
-//        ConnectorBinding binding = null;
-//        try {
-//            // Check if the binding exists already, if does take action based on user
-//            // preferences in the admin options
-//            if (bindingExists(deployName)) {
-//                // Based on users preference, either add or replace or ignore 
-//                if (options.containsOption(AdminOptions.OnConflict.EXCEPTION)) {
-//                    throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.addBindingEixists", deployName)); //$NON-NLS-1$
-//                }
-//                else if (options.containsOption(AdminOptions.OnConflict.IGNORE)) {
-//                    binding = getDataService().getConnectorBinding(deployName);
-//                    return (org.teiid.adminapi.ConnectorBinding) convertToAdminObjects(binding);
-//                }
-//            }
-//            
-//            // now we are in situation we do have the connector or overwriting it.
-//            // before we add the connector binding we need to add the connector type
-//            // as the connector binding only references to type by identifier.
-//            ConnectorBindingType type = ConnectorConfigurationReader.loadConnectorType(xmlFile);
-//            
-//            // Check if the binding type exists already, if does take action based on user
-//            // preferences in the admin options, same rules apply as binding. 
-//            boolean addType = true;
-//            if (bindingTypeExists(type.getName())) {
-//                if (options.containsOption(AdminOptions.OnConflict.EXCEPTION)) {
-//                    throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.addBinding_type_exists", deployName, type.getName())); //$NON-NLS-1$
-//                }
-//                else if (options.containsOption(AdminOptions.OnConflict.IGNORE)) {
-//                	addType = false;
-//                }                
-//            }
-//            
-//            binding = ConnectorConfigurationReader.loadConnectorBinding(deployName, xmlFile);
-//            
-//            // Check that the connector binding passwords can be decrypted
-//            try {
-//            	checkDecryption(binding, type);
-//            } catch(CryptoException e) {
-//            	if (!options.containsOption(AdminOptions.BINDINGS_IGNORE_DECRYPT_ERROR)) {
-//            		throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.CODE_DECRYPTION_FAILED", binding.getFullName())); //$NON-NLS-1$		
-//            	}
-//            }
-//
-//            // now that all of the input parameters validated, add the connector binding
-//            binding = addConnectorBinding(deployName, binding, type, addType);
-//                                
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }
-//        
-//        return (org.teiid.adminapi.ConnectorBinding) convertToAdminObjects(binding);
-    	return null;
-    }
-
-    /**
-     * Helper method to add the connector binding.. 
-     * @param deployName
-     * @param binding
-     * @param type
-     * @param options
-     * @throws AdminException
-     */
-    ConnectorBinding addConnectorBinding(String deployName, ConnectorBinding binding, ConnectorBindingType type, boolean addType) 
-        throws AdminException {
-//        // Make sure we have both correctly configured
-//        if (type != null && binding != null) {
-//            if (binding.getComponentTypeID().getName().equals(type.getName())) {
-//                try {
-//                    
-//                    // First add the connector type if one is not already in here.
-////                    if (getConfigurationService().getConnectorType(type.getName()) == null || addType) {
-////                        saveConnectorType(type);
-////                    }
-//                    // Now add the connector binding.
-//                    binding = getConfigurationService().addConnectorBinding(deployName, binding, true);
-//                    return binding;
-//                } catch (MetaMatrixComponentException e) {
-//                	throw new AdminComponentException(e);
-//                } 
-//            }
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.connector_load_failed_wrong_type", deployName));  //$NON-NLS-1$                    
-//        }
-        throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.connector_load_failed_wrong_contents", deployName));  //$NON-NLS-1$        
-    }
-    
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#deleteConnectorBinding(java.lang.String)
-     * @since 4.3
-     */
-    public void deleteConnectorBinding(String identifier) 
-        throws AdminException {
-//        try {
-//            if (identifier == null || !identifier.matches(MULTIPLE_WORD_WILDCARD_REGEX)) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_cb_name")); //$NON-NLS-1$
-//            }
-//            getConfigurationService().deleteConnectorBinding(identifier);
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }          
-    }
-
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#addVDB(java.lang.String, byte[], char[], AdminOptions)
-     * @since 4.3
-     */
-    private VDB addVDB(String deployName, byte[] vdbFile, char[] defFile, AdminOptions options) 
-        throws AdminException {
-        
-//        // if the options object is null treat as if it is BINDINGS_ADD as default
-//        if (options == null) {
-//            options = new AdminOptions(AdminOptions.OnConflict.IGNORE);
-//        }
-//        
-//        if (deployName == null || !deployName.matches(SINGLE_WORD_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_vdb_name")); //$NON-NLS-1$                
-//        }
-//        if (vdbFile == null || vdbFile.length == 0) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_vdb_source")); //$NON-NLS-1$
-//        }        
-//        
-//        if (defFile == null) {
-//            DQPEmbeddedPlugin.logInfo("Admin.load_combined_vdb", new Object[] {deployName}); //$NON-NLS-1$
-//        }
-//        
-//        VDBArchive vdb = null;
-//        try {
-//        	// Load the VDB from the files
-//        	if (defFile == null) {
-//        		vdb = VDBConfigurationReader.loadVDB(deployName, vdbFile);
-//        	}
-//        	else {
-//        		vdb = VDBConfigurationReader.loadVDB(deployName, defFile, vdbFile);    
-//        	}
-//
-//            // Add the connector binding in the VDB to the system
-//            validateConnectorBindingsInVdb(vdb, options);
-//            
-//            // now deploy the VDB into the system. Flag is to 
-//            VDBArchive deployedVDB = getConfigurationService().addVDB(vdb, !options.containsOption(AdminOptions.OnConflict.IGNORE));
-//
-//            // If the connector bindings are correctly initialized and VDB is active
-//            // start the bindings automatically.
-//            if ( (deployedVDB.getStatus() == VDBStatus.ACTIVE) ||
-//              	  (deployedVDB.getStatus() == VDBStatus.ACTIVE_DEFAULT) ) {
-//                try {
-//                    startVDBConnectorBindings(deployedVDB);
-//                } catch (MetaMatrixComponentException e) {
-//                } catch (ApplicationLifecycleException e) {
-//                    // we can safely ignore these because the cause of the not starting is already recorded
-//                    // and more likely VDB deployment succeeded.
-//                }
-//            }
-//            
-//            return (VDB) convertToAdminObjects(deployedVDB);
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }
-    	return null;
-    }
-
-    /** 
-     * Start the connector bindings in the given VDB
-     * @param vdb
-     */
-    private void startVDBConnectorBindings(VDBArchive vdb) throws MetaMatrixComponentException,
-        ApplicationLifecycleException {
-//        
-//    	VDBDefn def = vdb.getConfigurationDef();
-//    	Collection<ConnectorBinding> bindings = def.getConnectorBindings().values();
-// 	 	for (ConnectorBinding binding:bindings) {
-// 	 		getDataService().startConnectorBinding(binding.getDeployedName());
-// 	 	}        
-    }
-    
-    /**
-     * Validate the connector bindings in a VDB. Since the connector bindings in VDB
-     * are VDB scoped there is no meaning for the admin options provided. Just check
-     * the decrypt properties.
-     */
-    void validateConnectorBindingsInVdb(VDBArchive vdb, AdminOptions options) 
-        throws MetaMatrixComponentException, AdminProcessingException, AdminException {
-//        
-//    	VDBDefn def = vdb.getConfigurationDef();
-//    	
-//        int version = 0; 
-//        VDBArchive existing = null;
-//        do {
-//            version++;
-//            existing = getConfigurationService().getVDB(def.getName(), String.valueOf(version));            
-//        } while(existing != null);
-//                
-//        // Look for the connector bindings in the VDB            
-//        // Based on users preference, either add or replace or throw exception
-//        List vdbbindings = new ArrayList(def.getConnectorBindings().values());        
-//        
-//        for (Iterator i = vdbbindings.iterator(); i.hasNext();) {        
-//            ConnectorBinding binding = (ConnectorBinding)i.next();
-//
-//            String deployName = binding.getDeployedName();
-//            if (deployName == null) {
-//            	deployName = binding.getFullName();
-//            }
-//            
-//            if (bindingExists(deployName)) {
-//                if (options.containsOption(AdminOptions.OnConflict.EXCEPTION)) {
-//                    throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.addBindingEixists", binding.getDeployedName())); //$NON-NLS-1$
-//                }                    
-//            }
-//            
-//            // when the binding is not found it falls in "add", "overwrite" or "ignore"
-//            // first two cases we need to add.
-//            ConnectorBindingType type = (ConnectorBindingType)def.getConnectorType(binding.getComponentTypeID().getName());
-//            
-//            // Check that the connector binding passwords can be decrypted
-//            try {
-//            	checkDecryption(binding, type);
-//            } catch(CryptoException e) {
-//            	if (!options.containsOption(AdminOptions.BINDINGS_IGNORE_DECRYPT_ERROR)) {
-//            		throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.CODE_DECRYPTION_FAILED", binding.getFullName())); //$NON-NLS-1$		
-//            	}
-//            }
-//        }
-    }
-
-    /**
-     * Check that the properties of the specified ConnectorBinding can be decrypted.
-     * @param 
-     * @return
-     * @since 4.3
-     */
-    private void checkDecryption(ConnectorBinding binding, ConnectorBindingType type) throws CryptoException {
-        Properties props = binding.getProperties();
-        Iterator it = props.keySet().iterator();
-        while (it.hasNext()) {
-            String name = (String)it.next();
-            if (isMaskedProperty(name, type)) {
-                decryptProperty(props.getProperty(name));
-            }
-        }
-    }
-       
-    /**
-     * Check to see if the property read is a masked/encoded property 
-     * @param propName
-     * @param type
-     * @return
-     */
-    boolean isMaskedProperty(String  propName, ComponentType type) {
-        if (type != null) {
-            ComponentTypeDefn typeDef = type.getComponentTypeDefinition(propName);
-            if (typeDef != null && typeDef.getPropertyDefinition().isMasked()) {
-                return true;
-            }
-        }
-        return false;
-    }
-    
-    /**
-     * Decrypt the given property using the Crypto libraries. 
-     * @param value
-     * @return decrypted property.
-     */
-    String decryptProperty(String value) throws CryptoException{
-        if (value != null && value.length() > 0 && CryptoUtil.isValueEncrypted(value)) {
-           return CryptoUtil.stringDecrypt(value);
-        }
-        return value;
-    }     
-    
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#addVDB(java.lang.String, byte[], AdminOptions)
-     * @since 4.3
-     */
-    public VDB addVDB(String deployName, byte[] vdbFile, AdminOptions options) 
-        throws AdminException {
-        return addVDB(deployName, vdbFile, null, options);
-    }
-    
-    @Override
-    public void deleteVDB(String vdbName, int vdbVersion) throws AdminException {
-    	//super.changeVDBStatus(vdbName, vdbVersion, VDB.DELETED);
-    }
-        
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#addExtensionModule(java.lang.String, java.lang.String, byte[], java.lang.String)
-     * @since 4.3
-     */
-    public void addExtensionModule(String type, String sourceName, byte[] source, String description) 
-        throws AdminException {
-//        try {
-//            if (sourceName == null) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_ext_source_name")); //$NON-NLS-1$                
-//            }            
-//            if (source == null || source.length == 0) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_ext_source")); //$NON-NLS-1$
-//            }
-//            if (!sourceName.endsWith(".jar") && !sourceName.endsWith(".xmi")) { //$NON-NLS-1$ //$NON-NLS-2$
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_ext_module")); //$NON-NLS-1$                
-//            }   
-//            ExtensionModule previousModule = null;
-//
-//            try {
-//                previousModule = getConfigurationService().getExtensionModule(sourceName);
-//            }catch(MetaMatrixComponentException e) {
-//                // this is OK, we did not find any thing
-//            }
-//            
-//            if ( previousModule == null) {
-//                // Now add it.
-//                BasicExtensionModule extModule = new BasicExtensionModule(sourceName, type, description, source);
-//                getConfigurationService().saveExtensionModule(extModule);
-//            }
-//            else {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.extension_module_exists", sourceName)); //$NON-NLS-1$
-//            }
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }
-    }
-
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#deleteExtensionModule(java.lang.String)
-     * @since 4.3
-     */
-    public void deleteExtensionModule(String sourceName) 
-        throws AdminException {        
-//        try {
-//            if (sourceName == null) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_ext_source_name")); //$NON-NLS-1$                
-//            }                        
-//            getConfigurationService().deleteExtensionModule(sourceName);
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }        
-    }
-
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#assignBindingToModel(java.lang.String, java.lang.String, java.lang.String, java.lang.String)
-     * @since 4.3
-     */
-    public void assignBindingToModel(String deployedConnectorBindingName, String vdbName, String vdbVersion, String modelName) 
-        throws AdminException {
-
-//        if (deployedConnectorBindingName == null || !deployedConnectorBindingName.matches(MULTIPLE_WORD_WILDCARD_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_cb_name")); //$NON-NLS-1$                
-//        }
-//        
-//        if (vdbName == null || vdbVersion == null || !vdbName.matches(SINGLE_WORD_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_vdb_name")); //$NON-NLS-1$
-//        }
-//
-//        if (modelName == null || !modelName.matches(MULTIPLE_WORDS_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_model_name")); //$NON-NLS-1$
-//        }
-//        
-//        // find the connector binding if found in the configuration service
-//        // add to the vdb binding.
-//        try {
-//            ConnectorBinding binding = null;//getDataService().getConnectorBinding(deployedConnectorBindingName);
-//            if (binding != null) {
-//                List list = new ArrayList();
-//                list.add(binding);            
-//                getConfigurationService().assignConnectorBinding(vdbName, vdbVersion, modelName, (ConnectorBinding[])list.toArray(new ConnectorBinding[list.size()]));
-//            }
-//            else {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Vdb_or_Model_notfound")); //$NON-NLS-1$
-//            }
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }                        
-    }
-    
-    public void assignBindingsToModel(String[] deployedConnectorBindingName, String vdbName, String vdbVersion, String modelName) throws AdminException {
-//        if (deployedConnectorBindingName == null || deployedConnectorBindingName.length == 0) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_cb_name")); //$NON-NLS-1$                
-//        }
-//        
-//        if (vdbName == null || vdbVersion == null || !vdbName.matches(SINGLE_WORD_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_vdb_name")); //$NON-NLS-1$
-//        }
-//
-//        if (modelName == null || !modelName.matches(MULTIPLE_WORDS_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_model_name")); //$NON-NLS-1$
-//        }
-//        
-//        // find the connector binding if found in the configuration service
-//        // add to the vdb binding.
-//        try {
-//        	List list = new ArrayList();
-//        	for (int i = 0; i < deployedConnectorBindingName.length; i++) {
-//        		ConnectorBinding binding = null; //getDataService().getConnectorBinding(deployedConnectorBindingName[i]);
-//                if (binding != null) {
-//                    list.add(binding);
-//                }
-//        	}
-//            
-//            if (!list.isEmpty()) {
-//                getConfigurationService().assignConnectorBinding(vdbName, vdbVersion, modelName, (ConnectorBinding[])list.toArray(new ConnectorBinding[list.size()]));
-//            }
-//            else {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Vdb_or_Model_notfound")); //$NON-NLS-1$
-//            }
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }                        
-    	
-    }
-
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#getLogConfiguration()
-     * @since 4.3
-     */
-    public LogConfiguration getLogConfiguration() 
-        throws AdminException {
-            return (LogConfiguration)convertToAdminObjects(LogManager.getLogConfigurationCopy());
-    }
-
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#setLogConfiguration(org.teiid.adminapi.LogConfiguration)
-     * @since 4.3
-     */
-    public void setLogConfiguration(LogConfiguration config) 
-        throws AdminException {
-        LogManager.setLogConfiguration((com.metamatrix.common.log.LogConfiguration)convertToNativeObjects(config));
-    }
-    
-    /** 
-     * @see com.metamatrix.admin.api.embedded.EmbeddedRuntimeStateAdmin#setLogListener(java.lang.Object)
-     * @since 4.3
-     */
-    public void setLogListener(EmbeddedLogger listener) 
-        throws AdminException {
-        if(listener != null) {
-        	LogManager.setLogListener(new DQPLogListener(listener));
-        }
-        else {
-            throw new AdminProcessingException("Admin_invalid_log_listener"); //$NON-NLS-1$
-        }
-    }    
-
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#exportExtensionModule(java.lang.String)
-     * @since 4.3
-     */
-    public byte[] exportExtensionModule(String sourceName) throws AdminException {
-//        try {
-//            if (sourceName == null) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_ext_source_name")); //$NON-NLS-1$                
-//            }            
-//            
-//            ExtensionModule extModule = getConfigurationService().getExtensionModule(sourceName);            
-//            return extModule.getFileContents();
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }
-    	return null;
-    }
-
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#exportConfiguration()
-     * @since 4.3
-     */
-    public char[] exportConfiguration() throws AdminException {
-//        try {
-//        	StringWriter sw = new StringWriter();
-//            Properties props = getConfigurationService().getSystemProperties();
-//            props.store(sw, "Export of Teiid Configuration Properties"); //$NON-NLS-1$
-//            return sw.toString().toCharArray();
-//        } catch (IOException e) {
-//        	throw new AdminComponentException(e);
-//        }
-    	return null;
-    }
-
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#exportConnectorBinding(java.lang.String)
-     * @since 4.3
-     */
-    public char[] exportConnectorBinding(String identifier) 
-        throws AdminException {
-//        try {
-//            if (identifier == null || !identifier.matches(MULTIPLE_WORD_WILDCARD_REGEX)) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_cb_name")); //$NON-NLS-1$                
-//            }
-//            
-//            List bindingList = getDataService().getConnectorBindings();
-//            List matchedList = new ArrayList();
-//            for (Iterator i = bindingList.iterator(); i.hasNext();) {
-//                ConnectorBinding binding = (ConnectorBinding)i.next();
-//                if (matches(identifier, binding.getDeployedName())) {
-//                    matchedList.add(binding);
-//                }
-//            }
-//            
-//            if (!matchedList.isEmpty()) {
-//                ConnectorBinding[] bindings = (ConnectorBinding[])matchedList.toArray(new ConnectorBinding[matchedList.size()]);
-//                ConnectorBindingType[] types = new ConnectorBindingType[bindings.length];
-//                
-//                for (int i = 0; i < bindings.length; i++) {
-//                    types[i] = getConfigurationService().getConnectorType(bindings[i].getComponentTypeID().getName());                
-//                }
-//                return ConnectorConfigurationWriter.writeToCharArray(bindings, types);
-//            }
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Connector_binding_does_not_exists", identifier)); //$NON-NLS-1$
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }
-    	return null;
-    }
-
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#exportConnectorType(java.lang.String)
-     * @since 4.3
-     */
-    public char[] exportConnectorType(String identifier) 
-        throws AdminException {
-//        try {
-//            if (identifier == null || !identifier.matches(MULTIPLE_WORDS_REGEX)) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_ct_name")); //$NON-NLS-1$                
-//            }
-//            
-//            List typesList = getConfigurationService().getConnectorTypes();
-//            List matchedList = new ArrayList();
-//            for (Iterator i = typesList.iterator(); i.hasNext();) {
-//                ConnectorBindingType type = (ConnectorBindingType)i.next();
-//                if (matches(identifier, type.getName())) {
-//                    matchedList.add(type);
-//                }
-//            }
-//            
-//            if (!matchedList.isEmpty()) {
-//                ConnectorBindingType[] types = (ConnectorBindingType[])matchedList.toArray(new ConnectorBindingType[matchedList.size()]);
-//                return ConnectorConfigurationWriter.writeToCharArray(types);
-//            }
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Connector_type_does_not_exists", identifier)); //$NON-NLS-1$
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        } 
-    	return null;
-    }
-
-    /**  
-     * @see org.teiid.adminapi.ConfigurationAdmin#exportVDB(java.lang.String, java.lang.String)
-     * @since 4.3
-     */
-    public byte[] exportVDB(String name, String version) 
-        throws AdminException {     
-    	
-//        try {
-//            if (name == null || version == null || !name.matches(SINGLE_WORD_REGEX)) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_vdb_name")); //$NON-NLS-1$                
-//            }
-//            
-//            VDBArchive vdb = getConfigurationService().getVDB(name, version); 
-//            if (vdb != null) {
-//                return VDBArchive.writeToByteArray(vdb);
-//            }
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.vdb_does_not_exists", name, version)); //$NON-NLS-1$
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }
-    	return null;
-    }
-
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#addConnectorArchive(byte[], org.teiid.adminapi.AdminOptions)
-     * @since 4.3.2
-     */
-    public void addConnectorArchive(byte[] contents, AdminOptions options) throws AdminException {
-        
-        // if the options object is null treat as if it is IGNORE as default
-        if (options == null) {
-            options = new AdminOptions(AdminOptions.OnConflict.IGNORE);
-        }
-
-        if (contents == null || contents.length == 0) {
-            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_ct_source")); //$NON-NLS-1$
-        }
-        
-        try {            
-            // Load the connector Archive from the file            
-            HashSet previouslyAddedModules = new HashSet();
-            ConnectorArchive archive = ConnectorConfigurationReader.loadConnectorArchive(contents);
-            ConnectorBindingType[] connectorTypes = archive.getConnectorTypes();
-                           
-            // Loop through each type and add all of them based on the option.
-            for (int typeIndex = 0; typeIndex < connectorTypes.length; typeIndex++) {
-                
-                // first make sure we do not already have this connector type
-                String connectorName = connectorTypes[typeIndex].getName();
-//               ConnectorBindingType type = getConfigurationService().getConnectorType(connectorName);
-                ConnectorBindingType type = null;
-                if (type == null) {
-                    type = connectorTypes[typeIndex];
-                    ExtensionModule[] extModules = archive.getExtensionModules(type);
-                    checkDuplicateExtensionModules(extModules, options, previouslyAddedModules);
-                    saveConnectorType(type);
-
-                } else {
-                
-                    // if not asked to overwrite/skip writing them
-                    if (options.containsOption(AdminOptions.OnConflict.EXCEPTION)) {
-                        throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Connector_type_exists", connectorName)); //$NON-NLS-1$            
-                    } else if (options.containsOption(AdminOptions.OnConflict.IGNORE)) {
-                        continue;
-                    } else if (options.containsOption(AdminOptions.OnConflict.OVERWRITE)){
-                        deleteConnectorType(connectorName);
-                        // Now that we know we need to add this to configuration; let's get on with it
-                        type = connectorTypes[typeIndex];
-                        ExtensionModule[] extModules = archive.getExtensionModules(type);
-                        checkDuplicateExtensionModules(extModules, options, previouslyAddedModules);
-                        saveConnectorType(type);
-                    }                
-                }
-                // Now that we know we need to add this to configuration; let's get on with it
-                type = connectorTypes[typeIndex];
-                ExtensionModule[] extModules = archive.getExtensionModules(type);
-                checkDuplicateExtensionModules(extModules, options, previouslyAddedModules);
-            }
-            
-            // Now add the extension modules
-            for (Iterator i = previouslyAddedModules.iterator(); i.hasNext();) {
-                ExtensionModule extModule = (ExtensionModule)i.next();
-                addExtensionModule(extModule.getModuleType(), extModule.getFullName(), extModule.getFileContents(), extModule.getDescription());
-            }        
-                        
-        } catch (MetaMatrixComponentException e) {
-            throw new AdminComponentException(e);
-        }
-    }
-
-    /**
-     * This method checks the passed in connector type's extension module is not already in the
-     * system, if it there takes the appropriate action. Otherwise keeps tracks of all modules 
-     * to add. 
-     * @param type - connector type
-     * @param extModules - Extension modules for the Connector Type
-     * @param options - Admin Options
-     * @param ignorableModules - Modules which are already added, can be ignored for adding
-     */
-    void checkDuplicateExtensionModules(ExtensionModule[] extModules, AdminOptions options, HashSet ignorableModules) 
-        throws AdminException  {
-
-//        // Now check if the the extension modules are already there        
-//        for (int i = 0; i < extModules.length; i++) {
-//            boolean add = true;
-//            
-//            String moduleName = extModules[i].getFullName();
-//            ExtensionModule previousModule = null;
-//            
-//            // see if we can ignore this, because we may have just added this during import of
-//            // another connector type through this archive
-//            if (ignorableModules.contains(extModules[i])) {
-//                continue;
-//            }
-//            
-//            // we have not already added this this time around, now check if this available 
-//            // from configuration service
-//            try {
-//                previousModule = getConfigurationService().getExtensionModule(moduleName);
-//            }catch(MetaMatrixComponentException e) {
-//                // this is OK, we did not find any thing
-//            }
-//            
-//            // if we found it take appropriate action.
-//            if(previousModule != null && options.containsOption(AdminOptions.OnConflict.EXCEPTION)) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.extension_module_exists", previousModule.getFullName())); //$NON-NLS-1$
-//            }
-//            else if (previousModule != null && options.containsOption(AdminOptions.OnConflict.IGNORE)) {
-//                add = false;
-//            }
-//            else if (previousModule != null && options.containsOption(AdminOptions.OnConflict.OVERWRITE)) {
-//                // since we are overwrite, first delete and then add, there is no safe way to overwrite
-//                deleteExtensionModule(previousModule.getFullName());
-//            }
-//                            
-//            // Now keep track what extension modules to add; also to ignore in future
-//            // adds
-//            if (add) {                
-//                ignorableModules.add(extModules[i]);
-//            }
-//        }                    
-    }
-    
-    /** 
-     * @see org.teiid.adminapi.ConfigurationAdmin#exportConnectorArchive(java.lang.String)
-     * @since 4.3
-     */
-    public byte[] exportConnectorArchive(String identifier) throws AdminException {
-//        try {
-//            if (identifier == null || !identifier.matches(MULTIPLE_WORD_WILDCARD_REGEX)) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_ct_name")); //$NON-NLS-1$                
-//            }
-//            
-//            // first build the connector archive object
-//            BasicConnectorArchive archive = new BasicConnectorArchive();
-//            List connectorTypes = getConfigurationService().getConnectorTypes();
-//            
-//            for (Iterator i = connectorTypes.iterator(); i.hasNext();) {
-//                ConnectorBindingType type = (ConnectorBindingType)i.next();
-//                
-//                // If the types name matches with the pattern sent in add to archive
-//                if (type != null && matches(identifier, type.getName())) {
-//                    
-//                    // Add connector type first
-//                    archive.addConnectorType(type);
-//    
-//                    // Get the extension modules required for the type
-//                    String[] extModules = type.getExtensionModules();
-//                    for (int m = 0; m < extModules.length; m++) {
-//                        // Get the extension module from the configuration and add to the archive
-//                        ExtensionModule extModule = getConfigurationService().getExtensionModule(extModules[m]);
-//                        if (extModule != null) {
-//                            archive.addExtensionModule(type, extModule);
-//                        }
-//                        else {
-//                            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("DataService.ext_module_not_found", extModules[m])); //$NON-NLS-1$                            
-//                        }                        
-//                    }                    
-//                }
-//            }
-//                
-//            // if no types found to the identifier pattern, then throw an exception
-//            if (archive.getConnectorTypes().length == 0) {
-//                throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Connector_type_does_not_exists", identifier)); //$NON-NLS-1$    
-//            }
-//                            
-//            // now convert the object into file form
-//            return ConnectorConfigurationWriter.writeToByteArray(archive);
-//           
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        } 
-    	return null;
-    }
-    
-    private void saveConnectorType(ConnectorBindingType type) throws MetaMatrixComponentException {
-       // getConfigurationService().saveConnectorType(type);
-    }
-    
-    
-    @Override
-	public void addUDF(byte[] modelFileContents, String classpath)
-			throws AdminException {
-//		if (modelFileContents == null || modelFileContents.length == 0) {
-//			throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_UDF_contents")); //$NON-NLS-1$               
-//		}
-//
-//		try {
-//		
-//			getConfigurationService().unloadUDF();
-//			
-//			// delete any extension module by the same name first
-//			try {
-//				deleteExtensionModule(ConfigurationService.USER_DEFINED_FUNCTION_MODEL);
-//			} catch (AdminException e) {
-//				// if not found then it is OK to fail
-//			}
-//			
-//			// add the function definitions as extension modules
-//			addExtensionModule(ExtensionModule.FUNCTION_DEFINITION_TYPE,ConfigurationService.USER_DEFINED_FUNCTION_MODEL,modelFileContents, "User Defined Functions File"); //$NON-NLS-1$
-//			
-//	        String commonpath = getConfigurationService().getSystemProperties().getProperty(DQPEmbeddedProperties.COMMON_EXTENSION_CLASPATH, ""); //$NON-NLS-1$
-//	        
-//	        StringBuilder sb = new StringBuilder();
-//	        if (classpath != null && classpath.length() > 0 ) {
-//	        	StringTokenizer st = new StringTokenizer(classpath, ";"); //$NON-NLS-1$
-//	        	while (st.hasMoreTokens()) {
-//	        		String partpath = st.nextToken();
-//	        		if (commonpath.indexOf(partpath) == -1) {
-//	        			sb.append(partpath).append(";"); //$NON-NLS-1$
-//	        		}
-//	        	}
-//	        }
-//	        getConfigurationService().setSystemProperty(DQPEmbeddedProperties.COMMON_EXTENSION_CLASPATH, sb.toString()+commonpath);
-//			
-//			
-//			// then update the properties
-//			Properties p = new Properties();
-//			p.setProperty(DQPEmbeddedProperties.COMMON_EXTENSION_CLASPATH, classpath);
-//			getConfigurationService().updateSystemProperties(p);
-//			// reload the new UDF
-//			getConfigurationService().loadUDF();
-//		} catch (MetaMatrixComponentException e) {
-//			throw new AdminComponentException(e);
-//		}
-	}
-
-	@Override
-	public void deleteUDF() throws AdminException {
-//		try {
-//			getConfigurationService().unloadUDF();
-//			deleteExtensionModule(ConfigurationService.USER_DEFINED_FUNCTION_MODEL); 
-//		} catch (MetaMatrixComponentException e) {
-//			throw new AdminComponentException(e);
-//		}
-	}
-	
-	@Override
-	public void extensionModuleModified(String name) throws AdminException {
-//		try {
-//			getConfigurationService().clearClassLoaderCache();
-//			getConfigurationService().loadUDF();
-//		} catch (MetaMatrixComponentException e) {
-//			throw new AdminComponentException(e);
-//		}		
-	}
-
-	@Override
-	public void setProcessProperty(String processIdentifier, String propertyName, String propertyValue) throws AdminException{
-//		try {
-//			getConfigurationService().setSystemProperty(propertyName, propertyValue);
-//		} catch (MetaMatrixComponentException e) {
-//			throw new AdminComponentException(e);
-//		}
-	}
-}

Modified: branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPLogListener.java
===================================================================
--- branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPLogListener.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPLogListener.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -22,7 +22,7 @@
 
 package com.metamatrix.dqp.embedded.admin;
 
-import org.teiid.adminapi.EmbeddedLogger;
+import org.teiid.adminapi.Logger;
 import org.teiid.adminapi.LogConfiguration;
 
 import com.metamatrix.core.log.LogListener;
@@ -31,9 +31,9 @@
 
 public class DQPLogListener implements LogListener {
     
-    private EmbeddedLogger logger;
+    private Logger logger;
     
-    public DQPLogListener(EmbeddedLogger logger) {
+    public DQPLogListener(Logger logger) {
         this.logger = logger;
     }
 

Deleted: branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPMonitoringAdminImpl.java
===================================================================
--- branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPMonitoringAdminImpl.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPMonitoringAdminImpl.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,319 +0,0 @@
-/*
- * 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 com.metamatrix.dqp.embedded.admin;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.List;
-
-import org.teiid.adminapi.AdminException;
-import org.teiid.adminapi.AdminProcessingException;
-import org.teiid.adminapi.Cache;
-import org.teiid.adminapi.ConnectionPool;
-import org.teiid.adminapi.ConnectorBinding;
-import org.teiid.adminapi.ConnectorType;
-import org.teiid.adminapi.ExtensionModule;
-import org.teiid.adminapi.MonitoringAdmin;
-import org.teiid.adminapi.PropertyDefinition;
-import org.teiid.adminapi.QueueWorkerPool;
-import org.teiid.adminapi.Request;
-import org.teiid.adminapi.Session;
-import org.teiid.adminapi.Transaction;
-import org.teiid.adminapi.VDB;
-
-import com.metamatrix.dqp.embedded.DQPEmbeddedPlugin;
-import com.metamatrix.jdbc.EmbeddedConnectionFactoryImpl;
-import com.metamatrix.server.serverapi.RequestInfo;
-
-
-/** 
- * DQP implementation of the Monitoring API
- * @since 4.3
- */
-public abstract class DQPMonitoringAdminImpl extends BaseAdmin implements MonitoringAdmin {
-
-    public DQPMonitoringAdminImpl(EmbeddedConnectionFactoryImpl manager) {
-        super(manager);
-    }
-
-    /** 
-     * @see org.teiid.adminapi.MonitoringAdmin#getConnectorTypes(java.lang.String)
-     * @since 4.3
-     */
-    public Collection<ConnectorType> getConnectorTypes(String identifier) 
-        throws AdminException {
-
-        if (identifier == null || !identifier.matches(MULTIPLE_WORD_WILDCARD_REGEX)) {
-            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-        }
-        
-        return super.getConnectorTypes(identifier);
-    }
-
-    /** 
-     * @see org.teiid.adminapi.MonitoringAdmin#getVDBs(java.lang.String)
-     * @since 4.3
-     */
-    public Collection<VDB> getVDBs(String identifier) 
-        throws AdminException {
-//        
-//        if (identifier == null || !identifier.matches(VDB_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-//        }
-//        
-//        // if . and * not specified, add a STAR at the end to compensate for the
-//        // version number matching.
-//        if (identifier.indexOf(DOT) == -1 && identifier.indexOf(STAR) == -1) {
-//            identifier = identifier +DOT+STAR;
-//        }
-//        
-//        try {
-//            List<VDBArchive> vdbs = getVDBService().getAvailableVDBs();
-//            List matchedVdbs = new ArrayList();
-//            for (VDBArchive vdb:vdbs) {
-//                if (matches(identifier, vdb.getName()+"."+vdb.getVersion())) { //$NON-NLS-1$
-//                    matchedVdbs.add(vdb);
-//                }
-//            }                        
-//            return (List)convertToAdminObjects(matchedVdbs);
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }
-    	return null;
-    }
-
-    /** 
-     * @see org.teiid.adminapi.MonitoringAdmin#getConnectorBindings(java.lang.String)
-     * @since 4.3
-     */
-    public Collection<ConnectorBinding> getConnectorBindings(String identifier) 
-        throws AdminException {
-        
-        if (identifier == null) {
-            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-        }                
-        return super.getConnectorBindings(identifier);
-    }
-    
-
-    @Override
-    public Collection<ConnectorBinding> getConnectorBindingsInVDB(String vdbName, int vdbVersion)  throws AdminException{
-//        try {
-//            VDBArchive vdb = getConfigurationService().getVDB(vdbName, vdbVersion); 
-//            if (vdb != null) {
-//            	return (List)convertToAdminObjects(vdb.getConfigurationDef().getConnectorBindings().values());
-//            }
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.vdb_does_not_exists", vdbVersion, vdbVersion)); //$NON-NLS-1$
-//            
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }
-    	return Collections.EMPTY_LIST;
-    }    
-    
-    /** 
-     * @see org.teiid.adminapi.MonitoringAdmin#getExtensionModules(java.lang.String)
-     * @since 4.3
-     */
-    public Collection<ExtensionModule> getExtensionModules(String identifier) 
-        throws AdminException {
-        
-//        if (identifier == null || !identifier.matches(WORD_AND_DOT_WILDCARD_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-//        }
-//                
-//        try {
-//            List extModules = getConfigurationService().getExtensionModules();
-//            extModules = (List)convertToAdminObjects(extModules);
-//            return matchedCollection(identifier, extModules);            
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }
-    	return null;
-    }
-
-    /** 
-     * @see org.teiid.adminapi.MonitoringAdmin#getQueueWorkerPools(java.lang.String)
-     * @since 4.3
-     */
-    public Collection<QueueWorkerPool> getQueueWorkerPools(String identifier) 
-        throws AdminException {
-//        
-//        if (identifier == null || !identifier.matches(MULTIPLE_WORD_WILDCARD_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-//        }
-//        
-//        List results = new ArrayList();
-//        if (matches(identifier, "dqp")) { //$NON-NLS-1$
-//            // First get the queue statistics for the DQP
-//            Collection c = getManager().getDQP().getQueueStatistics();;
-//            if (c != null && !c.isEmpty()) {
-//                results.addAll(c);
-//            }
-//        }
-//        
-//        try {
-//            // Now get for all the connector bindings
-//            Collection bindings = super.getConnectorBindings(identifier);
-//            for (Iterator i = bindings.iterator(); i.hasNext();) {
-//                ConnectorBinding binding = (ConnectorBinding)i.next();
-//                Collection c = getDataService().getConnectorStatistics(binding.getName());
-//                if (c != null && !c.isEmpty()) {
-//                    results.addAll(c);
-//                }                
-//            }
-//        } catch (MetaMatrixComponentException e) {
-//        	throw new AdminComponentException(e);
-//        }
-//                
-//        if (!results.isEmpty()) {
-//            return (List)convertToAdminObjects(results);
-//        }
-        return Collections.EMPTY_LIST;
-    }
-
-    /** 
-     * @see org.teiid.adminapi.MonitoringAdmin#getCaches(java.lang.String)
-     * @since 4.3
-     */
-    public Collection<Cache> getCaches(String identifier) 
-        throws AdminException {
-        
-        if (identifier == null || !identifier.matches(SINGLE_WORD_WILDCARD_REGEX)) {
-            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-        }
-        
-        List cacheList = new ArrayList();
-        for (int i =0; i < cacheTypes.length; i++) {
-            if (matches(identifier, cacheTypes[i])) {
-                cacheList.add(cacheTypes[i]);
-            }            
-        }
-        return cacheList;
-    }
-
-    /** 
-     * @see org.teiid.adminapi.MonitoringAdmin#getSessions(java.lang.String)
-     * @since 4.3
-     */
-    public Collection<Session> getSessions(String identifier) 
-        throws AdminException {
-//        
-//        if (identifier == null || !identifier.matches(NUMBER_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-//        }
-//        return matchedCollection(identifier, (List)convertToAdminObjects(getClientConnections()));
-    	return null;
-    }
-        
-    /** 
-     * @see org.teiid.adminapi.MonitoringAdmin#getRequests(java.lang.String)
-     * @since 4.3
-     */
-    public Collection<Request> getRequests(String identifier) 
-        throws AdminException {
-
-        if (identifier == null || !identifier.matches(NUMBER_DOT_REGEX)) {
-            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-        }
-        
-        ArrayList requestList = new ArrayList();
-        // List contains both top and atomic requests, only add the top requests
-    	List<RequestInfo> requests = getManager().getDQP().getRequests();                 
-        for(RequestInfo request:requests) {
-        	if (request.getConnectorBindingUUID() == null) {
-        		requestList.add(request);
-        	}
-        }
-        return matchedCollection(identifier, (List)convertToAdminObjects(requestList));
-    }
-
-    /** 
-     * @see org.teiid.adminapi.MonitoringAdmin#getSourceRequests(java.lang.String)
-     * @since 4.3
-     */
-    public Collection<Request> getSourceRequests(String identifier) 
-        throws AdminException {
-        
-        if (identifier == null || !identifier.matches(NUMBER_DOT_REGEX)) {
-            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-        }
-        
-        ArrayList atomicRequestList = new ArrayList();
-    	List<RequestInfo> requests = getManager().getDQP().getRequests();
-        for (RequestInfo request:requests) {
-        	if (request.getConnectorBindingUUID() != null) {
-        		atomicRequestList.add(request);
-        	}
-        }
-        return matchedCollection(identifier, (List)convertToAdminObjects(atomicRequestList));
-    }
-    
-    /** 
-     * @see org.teiid.adminapi.MonitoringAdmin#getPropertyDefinitions(java.lang.String, java.lang.String)
-     * @since 4.3
-     */
-    public Collection<PropertyDefinition> getConnectorTypePropertyDefinitions(String typeName) throws AdminException {
-    	
-//        if (typeName == null || !typeName.matches(MULTIPLE_WORDS_REGEX)) {
-//        	throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_ct_name")); //$NON-NLS-1$                
-//        }
-//
-//        try {
-//			ConnectorBindingType type = getConfigurationService().getConnectorType(typeName);
-//			if (type == null) {
-//				throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.ct_doesnot_exist", typeName)); //$NON-NLS-1$
-//			}
-//   
-//			return convertPropertyDefinitions(type, new Properties());
-//		} catch (MetaMatrixComponentException e) {
-//			throw new AdminComponentException(e);
-//		}
-    	return null;
-    }
-
-    @Override
-    public Collection<Transaction> getTransactions()
-    		throws AdminException {
-//    	TransactionService ts = getTransactionService();
-//    	if (ts == null) {
-//    		return Collections.emptyList();
-//    	}
-//    	return ts.getTransactions();
-    	return Collections.EMPTY_LIST;
-    }
-
-	@Override
-	public Collection<? extends ConnectionPool> getConnectionPoolStats(String identifier)
-			throws AdminException {
-		
-//		try {
-//			return this.getDataService().getConnectionPoolStatistics(identifier);
-//		} catch (MetaMatrixComponentException e) {
-//			throw new AdminComponentException(e);
-//		}
-		return Collections.EMPTY_LIST;
-	}
-
-}

Deleted: branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPRuntimeStateAdminImpl.java
===================================================================
--- branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPRuntimeStateAdminImpl.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPRuntimeStateAdminImpl.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,293 +0,0 @@
-/*
- * 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 com.metamatrix.dqp.embedded.admin;
-
-import javax.transaction.xa.Xid;
-
-import org.teiid.adminapi.AdminComponentException;
-import org.teiid.adminapi.AdminException;
-import org.teiid.adminapi.AdminObject;
-import org.teiid.adminapi.AdminProcessingException;
-import org.teiid.adminapi.Request;
-import org.teiid.adminapi.RuntimeStateAdmin;
-
-import com.metamatrix.admin.objects.MMRequest;
-import com.metamatrix.api.exception.MetaMatrixComponentException;
-import com.metamatrix.dqp.embedded.DQPEmbeddedPlugin;
-import com.metamatrix.dqp.message.AtomicRequestID;
-import com.metamatrix.dqp.message.RequestID;
-import com.metamatrix.jdbc.EmbeddedConnectionFactoryImpl;
-
-
-/** 
- * @since 4.3
- */
-public abstract class DQPRuntimeStateAdminImpl  extends BaseAdmin implements RuntimeStateAdmin {
-
-    public DQPRuntimeStateAdminImpl(EmbeddedConnectionFactoryImpl manager) {
-        super(manager);
-    }
-
-    /** 
-     * @see com.metamatrix.admin.api.embedded.EmbeddedRuntimeStateAdmin#stop(int)
-     * @since 4.3
-     */
-    public void shutdown(int millisToWait) throws AdminException {        
-        // TODO: rreddy need to implement the time to wait.
-        // First terminate all the sessions to the DQP currently have
-        terminateSession(AdminObject.WILDCARD);
-        
-        getManager().shutdown();
-    }
-
-    /** 
-     * @see com.metamatrix.admin.api.embedded.EmbeddedRuntimeStateAdmin#restart()
-     * @since 4.3
-     */
-    public void restart() throws AdminException {
-        // First terminate all the sessions to the DQP currently have
-        terminateSession(AdminObject.WILDCARD);
-        
-        // Now shutdown the DQP, it will automatically start next timea new connection is 
-        // requested.
-        getManager().shutdown();                        
-    }
-
-    /** 
-     * @see org.teiid.adminapi.RuntimeStateAdmin#startConnectorBinding(java.lang.String)
-     * @since 4.3
-     */
-    public void startConnectorBinding(String identifier) 
-        throws AdminException {
-        
-//        if (identifier == null || !identifier.matches(MULTIPLE_WORD_WILDCARD_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-//        }
-//        
-//        AdminException exceptionWrapper = null;
-//        // Get all matching connector bindings
-//        Collection bindings = getConnectorBindings(identifier);
-//        if (bindings != null && !bindings.isEmpty()) {
-//            for (Iterator i = bindings.iterator(); i.hasNext();) {
-//                try {
-//                    AdminObject binding = (AdminObject)i.next();
-//                    getDataService().startConnectorBinding(binding.getName());
-//                } catch (ApplicationLifecycleException e) {
-//                    exceptionWrapper = accumulateSystemException(exceptionWrapper, e);
-//                } catch (MetaMatrixComponentException e) {
-//                    exceptionWrapper = accumulateSystemException(exceptionWrapper, e);
-//                }
-//            }
-//        }
-//        else {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Connector_binding_does_not_exists", new Object[] {identifier})); //$NON-NLS-1$            
-//        }
-//
-//        // If any errors occurred then thow the exception.
-//        if (exceptionWrapper != null) {
-//            throw exceptionWrapper;
-//        }
-    }
-
-    /** 
-     * @see org.teiid.adminapi.RuntimeStateAdmin#stopConnectorBinding(java.lang.String, boolean)
-     * @since 4.3
-     */
-    public void stopConnectorBinding(String identifier, boolean stopNow) 
-        throws AdminException {
-//        // TODO: need to implement "now" part
-//        if (identifier == null || !identifier.matches(MULTIPLE_WORD_WILDCARD_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-//        }
-//        
-//        AdminException exceptionWrapper = null;
-//        // Get all matching connector bindings        
-//        Collection bindings = getConnectorBindings(identifier);
-//        if (bindings != null && !bindings.isEmpty()) {
-//            for (Iterator i = bindings.iterator(); i.hasNext();) {
-//                try {
-//                    AdminObject binding = (AdminObject)i.next();
-//                    getDataService().stopConnectorBinding(binding.getName());
-//                } catch (ApplicationLifecycleException e) {
-//                    exceptionWrapper = accumulateSystemException(exceptionWrapper, e);
-//                } catch (MetaMatrixComponentException e) {
-//                    exceptionWrapper = accumulateSystemException(exceptionWrapper, e);
-//                }
-//            }
-//        }
-//        else {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Connector_binding_does_not_exists", new Object[] {identifier})); //$NON-NLS-1$            
-//        }
-//
-//        // If any errors occurred then thow the exception.
-//        if (exceptionWrapper != null) {
-//            throw exceptionWrapper;
-//        }
-    }
-
-    /** 
-     * @see org.teiid.adminapi.RuntimeStateAdmin#clearCache(java.lang.String)
-     * @since 4.3
-     */
-    public void clearCache(String identifier) 
-        throws AdminException {
-//        
-//        if (identifier == null || !identifier.matches(SINGLE_WORD_WILDCARD_REGEX)) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-//        }
-//        boolean processed = false;
-//        
-//        for (int i = 0; i < cacheTypes.length; i++) {
-//            if (matches(identifier, cacheTypes[i])) {
-//                if(cacheTypes[i].equals(Cache.CODE_TABLE_CACHE)) {
-//                    processed = true;
-//                    getManager().getDQP().clearCodeTableCache();
-//                } else if(cacheTypes[i].equals(Cache.PREPARED_PLAN_CACHE)) {
-//                    processed = true;
-//                    getManager().getDQP().clearPlanCache();
-//                } else if(cacheTypes[i].equals( Cache.QUERY_SERVICE_RESULT_SET_CACHE)) {
-//                    processed = true;
-//                    getManager().getDQP().clearResultSetCache();
-//                } else if (cacheTypes[i].equals(Cache.CONNECTOR_RESULT_SET_CACHE)) {
-//                    processed = true;
-//                    try {
-//                        // Now get for all the connector bindings
-//                        Collection bindings = super.getConnectorBindings("*"); //$NON-NLS-1$
-//                        for (Iterator iter = bindings.iterator(); iter.hasNext();) {
-//                            ConnectorBinding binding = (ConnectorBinding)iter.next();
-//                            getDataService().clearConnectorBindingCache(binding.getName());
-//                        }
-//                    } catch (MetaMatrixComponentException e) {
-//                    	throw new AdminComponentException(e);
-//                    }                                        
-//                } 
-//            }
-//        }
-//        
-//        if (!processed) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.invalid_request", new Object[] {identifier})); //$NON-NLS-1$
-//        }        
-    }
-    
-    /** 
-     * @see org.teiid.adminapi.RuntimeStateAdmin#terminateSession(java.lang.String)
-     * @since 4.3
-     */
-    public void terminateSession(String identifier) 
-        throws AdminException {
-        
-//        Collection<MetaMatrixSessionInfo> sessions = getClientConnections();
-//        ArrayList<MetaMatrixSessionInfo> matchedConnections = new ArrayList<MetaMatrixSessionInfo>();
-//        
-//        for (MetaMatrixSessionInfo info:sessions) {
-//            String id = info.getSessionID().toString();
-//            if (matches(identifier, id)) {
-//                matchedConnections.add(info);
-//            }
-//        }
-//
-//        // terminate the sessions.
-//        for (MetaMatrixSessionInfo info: matchedConnections) {
-//        	getSessionService().terminateSession(info.getSessionID(), DQPWorkContext.getWorkContext().getSessionId());
-//        }
-    }
-    
-    /** 
-     * @see org.teiid.adminapi.RuntimeStateAdmin#cancelRequest(java.lang.String)
-     * @since 4.3
-     */
-    public void cancelRequest(String identifier) 
-        throws AdminException {
-
-        if (identifier == null || !identifier.matches("\\d+\\" + Request.DELIMITER + "\\d+")) { //$NON-NLS-1$ //$NON-NLS-2$
-            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-        }
-                
-        String[] identifierParts = MMRequest.buildIdentifierArray(identifier);
-        String connId = identifierParts[0];
-        long requestId = Long.parseLong(identifierParts[1]);
-        
-        // get the client connection
-        RequestID id = new RequestID(connId, requestId);    
-        
-        try {
-        	getManager().getDQP().cancelRequest(id);
-		} catch (MetaMatrixComponentException e) {
-			throw new AdminComponentException(e);
-		}
-    }
-
-    /** 
-     * @see org.teiid.adminapi.RuntimeStateAdmin#cancelSourceRequest(java.lang.String)
-     * @since 4.3
-     */
-    public void cancelSourceRequest(String identifier) 
-        throws AdminException {
-        
-        if (identifier == null || !identifier.matches("\\d+\\" + Request.DELIMITER + "\\d+\\" + Request.DELIMITER + "\\d+" + Request.DELIMITER + "\\d+")) { //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
-            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("Admin.Invalid_identifier")); //$NON-NLS-1$                
-        }
-        
-        String[] identifierParts = MMRequest.buildIdentifierArray(identifier);
-
-        String connId = identifierParts[0];
-        long requestId = Long.parseLong(identifierParts[1]);
-        int nodeId = Integer.parseInt(identifierParts[2]);
-        int executionId = Integer.parseInt(identifierParts[3]);
-        AtomicRequestID id = new AtomicRequestID(new RequestID(connId, requestId), nodeId, executionId);
-
-        try {
-        	getManager().getDQP().cancelAtomicRequest(id);
-		} catch (MetaMatrixComponentException e) {
-			throw new AdminComponentException(e);
-		}
-    }
-
-    /** 
-     * @see org.teiid.adminapi.RuntimeStateAdmin#changeVDBStatus(java.lang.String, java.lang.String, int)
-     * @since 4.3
-     */
-    public void changeVDBStatus(String name, String version, int status) 
-        throws AdminException {
-    	super.changeVDBStatus(name, version, status);
-    }
-    
-        
-    @Override
-    public void terminateTransaction(String transactionId, String sessionId)
-    		throws AdminException {
-//    	TransactionService ts = getTransactionService();
-//    	if (ts != null) {
-//    		ts.terminateTransaction(transactionId, sessionId);
-//    	}
-    }
-    
-    @Override
-    public void terminateTransaction(Xid transactionId) throws AdminException {
-//    	TransactionService ts = getTransactionService();
-//    	if (ts != null) {
-//    		ts.terminateTransaction(transactionId);
-//    	}
-    }
-    
-}

Deleted: branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPSecurityAdminImpl.java
===================================================================
--- branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPSecurityAdminImpl.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/main/java/com/metamatrix/dqp/embedded/admin/DQPSecurityAdminImpl.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,267 +0,0 @@
-/*
- * 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 com.metamatrix.dqp.embedded.admin;
-
-import java.io.IOException;
-import java.util.Collection;
-import java.util.List;
-
-import javax.xml.parsers.ParserConfigurationException;
-
-import org.teiid.adminapi.AdminComponentException;
-import org.teiid.adminapi.AdminException;
-import org.teiid.adminapi.AdminOptions;
-import org.teiid.adminapi.AdminProcessingException;
-import org.teiid.adminapi.Group;
-import org.teiid.adminapi.SecurityAdmin;
-import org.xml.sax.SAXException;
-
-import com.metamatrix.api.exception.security.AuthorizationException;
-import com.metamatrix.api.exception.security.AuthorizationMgmtException;
-import com.metamatrix.dqp.embedded.DQPEmbeddedPlugin;
-import com.metamatrix.jdbc.EmbeddedConnectionFactoryImpl;
-import com.metamatrix.platform.admin.api.EntitlementMigrationReport;
-import com.metamatrix.platform.security.api.AuthorizationPolicy;
-import com.metamatrix.platform.security.api.AuthorizationPolicyFactory;
-import com.metamatrix.platform.security.api.AuthorizationRealm;
-
-
-/** 
- * @since 4.3
- */
-public abstract class DQPSecurityAdminImpl  extends BaseAdmin implements SecurityAdmin {
-
-    public DQPSecurityAdminImpl(EmbeddedConnectionFactoryImpl manager) {
-        super(manager);
-    }
-    
-    /** 
-     * @see com.metamatrix.admin.api.server.ServerSecurityAdmin#addRoleToGroup(java.lang.String, java.lang.String)
-     * @since 4.3
-     */
-    public void assignRoleToGroup(String roleIdentifier, String groupIdentifier) throws AdminException {
-    	throw new AdminComponentException(DQPEmbeddedPlugin.Util.getString("ServerSecurityAdminImpl.not_implemented")); //$NON-NLS-1$
-    }
-    
-    /** 
-     * @see com.metamatrix.admin.api.server.ServerSecurityAdmin#removeRoleFromGroup(java.lang.String, java.lang.String)
-     * @since 4.3
-     */
-    public void removeRoleFromGroup(String roleIdentifier, String groupIdentifier) throws AdminException {
-    	throw new AdminComponentException(DQPEmbeddedPlugin.Util.getString("ServerSecurityAdminImpl.not_implemented")); //$NON-NLS-1$
-    }
-    
-    /** 
-     * @see com.metamatrix.admin.api.server.ServerSecurityAdmin#getGroupsForUser(java.lang.String, boolean)
-     * @since 4.3
-     */
-    public Collection<Group> getGroupsForUser(String userIdentifier) throws AdminException {
-//        if (userIdentifier == null) {
-//            throwProcessingException("AdminImpl.requiredparameter", new Object[] {}); //$NON-NLS-1$
-//        }
-//        
-//        if ( userIdentifier.equals(AdminObject.WILDCARD) ) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("ServerSecurityAdminImpl.Cant_use_wildcard")); //$NON-NLS-1$
-//        }
-//        Collection groups = new ArrayList();
-//        // Get all memberships - explicit and implicit
-//        Set allMemberships = null;
-//        try {
-//            allMemberships = getMembershipService().getGroupsForUser(userIdentifier);
-//        } catch (MetaMatrixSecurityException e) {
-//            throw new AdminComponentException(e);
-//        }
-//        Iterator allMembershipsItr = allMemberships.iterator();
-//        while ( allMembershipsItr.hasNext() ) {
-//            groups.add(new MMGroup(new String[] {(String)allMembershipsItr.next()}));
-//        }
-//        return groups;
-    	return null;
-    }
-
-    /** 
-     * @see com.metamatrix.admin.api.server.ServerSecurityAdmin#getGroups(java.lang.String)
-     * @since 4.3
-     */
-    public Collection<Group> getGroups(String groupIdentifier) throws AdminException {
-//        if (groupIdentifier == null) {
-//            throwProcessingException("AdminImpl.requiredparameter", new Object[] {}); //$NON-NLS-1$
-//        }
-//        
-//        Collection<Group> groups = new ArrayList<Group>();
-//        Collection allGroups = null;
-//        // Add all groups from internal membership domain
-//        try {
-//            allGroups = getMembershipService().getGroupNames();
-//        } catch (MetaMatrixSecurityException e) {
-//        	throw new AdminComponentException(e);
-//        }
-//
-//        Iterator groupItr = allGroups.iterator();
-//        while ( groupItr.hasNext() ) {
-//            String groupName = (String) groupItr.next();
-//
-//            if (!groupIdentifier.equals(AdminObject.WILDCARD) && !groupName.equals(groupIdentifier)) {
-//                continue;
-//            }
-//
-//            groups.add(new MMGroup(new String[] {groupName}));
-//        }
-//        return groups;
-    	return null;
-    }
-
-
-    /** 
-     * @see com.metamatrix.admin.api.server.ServerSecurityAdmin#getRolesForGroup(java.lang.String)
-     * @since 4.3
-     */
-    public Collection getRolesForGroup(String groupIdentifier) throws AdminException {
-//        if (groupIdentifier == null) {
-//            throwProcessingException("AdminImpl.requiredparameter", new Object[] {}); //$NON-NLS-1$
-//        }
-//        
-//        if ( groupIdentifier.equals(AdminObject.WILDCARD) ) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("ServerSecurityAdminImpl.Cant_use_wildcard")); //$NON-NLS-1$
-//        }
-//        Collection roleNames = null;
-//        try {
-//            roleNames = getAuthorizationService().getRoleNamesForPrincipal(new MetaMatrixPrincipalName(groupIdentifier, MetaMatrixPrincipal.TYPE_GROUP));
-//        } catch (InvalidSessionException e) {
-//        	throw new AdminComponentException(e);
-//        } catch (AuthorizationMgmtException e) {
-//        	throw new AdminComponentException(e);
-//        } catch (AuthorizationException e) {
-//        	throw new AdminComponentException(e);
-//        }
-//        Collection roles = new ArrayList();
-//        Iterator roleNameItr = roleNames.iterator();
-//        while ( roleNameItr.hasNext() ) {
-//             String roleName = (String)roleNameItr.next();
-//             roles.add(new MMRole(new String[] {roleName}));
-//        }
-//        return roles;
-    	return null;
-    }
-       
-    /**
-     * @see com.metamatrix.admin.api.server.ServerSecurityAdmin#importDataRoles(java.lang.String, java.lang.String, char[], org.teiid.adminapi.AdminOptions)
-     */
-    public String importDataRoles(String vdbName, String vdbVersion, char[] xmlContents, AdminOptions options) 
-        throws AdminException{
-        
-//        if (vdbName == null) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("ServerSecurityAdminImpl.vdbName_can_not_be_null")); //$NON-NLS-1$
-//        }
-//        
-//        if (vdbVersion == null) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("ServerSecurityAdminImpl.vdbVersion_can_not_be_null")); //$NON-NLS-1$
-//        }
-//        
-//        if (options == null) {
-//            
-//            options = new AdminOptions(AdminOptions.OnConflict.IGNORE);
-//        }
-//
-//        try {
-//        	EntitlementMigrationReport rpt = new EntitlementMigrationReport("from file", vdbName + " " + vdbVersion); //$NON-NLS-1$ //$NON-NLS-2$
-//        	
-//            Collection<AuthorizationPolicy> roles = AuthorizationPolicyFactory.buildPolicies(vdbName, vdbVersion, xmlContents);
-//
-//            AuthorizationRealm realm = new AuthorizationRealm(vdbName, vdbVersion);
-//            
-//            getAuthorizationService().updatePoliciesInRealm(realm, roles);
-//
-//            return rpt.toString();
-//        } catch (AuthorizationMgmtException e) {
-//        	throw new AdminProcessingException(e);
-//   		} catch (SAXException e) {
-//   			throw new AdminComponentException(e);
-//   		} catch (IOException e) {
-//   			throw new AdminComponentException(e);
-//   		} catch (ParserConfigurationException e) {
-//   			throw new AdminComponentException(e);
-//        }
-    	return null;
-    }
-
-    /**
-     * @see com.metamatrix.admin.api.server.ServerSecurityAdmin#exportDataRoles(java.lang.String, java.lang.String)
-     */
-    public char[] exportDataRoles(String vdbName, String vdbVersion) throws AdminException {
-        
-//        if (vdbName == null) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("ServerSecurityAdminImpl.vdbName_can_not_be_null")); //$NON-NLS-1$
-//        }
-//        
-//        if (vdbVersion == null) {
-//            throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString("ServerSecurityAdminImpl.vdbVersion_can_not_be_null")); //$NON-NLS-1$
-//        }
-//	     
-//        Collection roles = null;
-//		try {
-//			roles = getAuthorizationService().getPoliciesInRealm(new AuthorizationRealm(vdbName, vdbVersion));
-//			if (roles != null && !roles.isEmpty()) {
-//				return AuthorizationPolicyFactory.exportPolicies(roles);
-//			}
-//			return null;
-//		} catch (AuthorizationMgmtException e) {
-//			throw new AdminProcessingException(e);
-//		} catch (AuthorizationException e) {
-//			throw new AdminProcessingException(e);
-//		} catch (IOException e) {
-//			throw new AdminComponentException(e);
-//		}
-    	return null;
-	}
-    
-    @Override
-    public List<String> getDomainNames() throws AdminException {
-		//return this.getMembershipService().getDomainNames();
-    	return null;
-    }
-    
-    @Override
-    public Collection<Group> getGroupsForDomain(String domainName)
-    		throws AdminException {
-//        if (domainName == null) {
-//            throwProcessingException("AdminImpl.requiredparameter", new Object[] {}); //$NON-NLS-1$
-//        }
-//        try {
-//        	Collection<String> groupNames = this.getMembershipService().getGroupsForDomain(domainName);
-//        	List<Group> result = new ArrayList<Group>(groupNames.size());
-//        	for (String groupName : groupNames) {
-//        		result.add(new MMGroup(new String[] {groupName}));
-//			}
-//        	return result;
-//        } catch (MembershipServiceException e) {
-//        	throw new AdminComponentException(e);
-//        }
-    	return null;
-    }
-    
-     void throwProcessingException(String key, Object[] objects) throws AdminException {
-        throw new AdminProcessingException(DQPEmbeddedPlugin.Util.getString(key, objects));
-    }    
- 
-}

Modified: branches/JCA/runtime/src/main/java/com/metamatrix/jdbc/EmbeddedConnectionFactoryImpl.java
===================================================================
--- branches/JCA/runtime/src/main/java/com/metamatrix/jdbc/EmbeddedConnectionFactoryImpl.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/main/java/com/metamatrix/jdbc/EmbeddedConnectionFactoryImpl.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -22,8 +22,6 @@
 
 package com.metamatrix.jdbc;
 
-import static org.teiid.dqp.internal.process.Util.convertStats;
-
 import java.lang.reflect.InvocationHandler;
 import java.lang.reflect.Method;
 import java.lang.reflect.Proxy;
@@ -42,8 +40,10 @@
 import org.teiid.TeiidResourceAdapter;
 import org.teiid.adminapi.Admin;
 import org.teiid.adminapi.impl.BaseAdmin;
+import org.teiid.adminapi.impl.WorkerPoolStatisticsMetadata;
 import org.teiid.dqp.internal.datamgr.impl.ConnectorManagerRepository;
 import org.teiid.dqp.internal.process.DQPCore;
+import org.teiid.dqp.internal.process.DQPManagementView;
 import org.teiid.dqp.internal.transaction.ContainerTransactionProvider;
 import org.teiid.dqp.internal.transaction.TransactionServerImpl;
 import org.teiid.dqp.internal.transaction.XidFactory;
@@ -53,7 +53,6 @@
 import org.teiid.transport.SocketTransport;
 
 import com.metamatrix.admin.objects.MMProcess;
-import com.metamatrix.admin.objects.MMQueueWorkerPool;
 import com.metamatrix.common.application.exception.ApplicationInitializationException;
 import com.metamatrix.common.comm.ClientServiceRegistry;
 import com.metamatrix.common.comm.ClientServiceRegistryImpl;
@@ -62,7 +61,6 @@
 import com.metamatrix.common.comm.exception.CommunicationException;
 import com.metamatrix.common.comm.exception.ConnectionException;
 import com.metamatrix.common.log.LogManager;
-import com.metamatrix.common.queue.WorkerPoolStats;
 import com.metamatrix.common.util.NetUtils;
 import com.metamatrix.common.util.PropertiesUtils;
 import com.metamatrix.core.MetaMatrixCoreException;
@@ -192,6 +190,7 @@
 		String clusterName = this.bootProperties.getProperty(DQPEmbeddedProperties.CLUSTERNAME, "teiid-cluster"); //$NON-NLS-1$
 		ContainerHelper helper = ContainerUtil.lookup("teiid/container-helper");
 		
+		DQPManagementView holder = helper.getService(DQPManagementView.class);
 		this.dqp = new DQPCore();
         this.dqp.setTransactionService(getTransactionService(processName));
         this.dqp.setWorkManager(this.ra.getWorkManager());
@@ -199,7 +198,8 @@
         this.dqp.setBufferService(helper.getService(BufferService.class));
         this.dqp.setSessionService(helper.getService(SessionService.class));
         this.dqp.setConnectorManagerRepository(helper.getService(ConnectorManagerRepository.class));
-		this.dqp.start(bootProperties); 		
+		this.dqp.start(bootProperties); 	
+		holder.setDQP(this.dqp);
 		
     	ClientServiceRegistry services  = new ClientServiceRegistryImpl();
     	services.registerClientService(ILogon.class, new LogonImpl(this.dqp.getSessionService(), this.dqp, clusterName), com.metamatrix.common.util.LogConstants.CTX_SERVER);
@@ -273,12 +273,8 @@
 	            process.setObjectsWritten(socketStats.objectsWritten);
 	        }
 	        
-	        WorkerPoolStats workerStats = this.socketTransport.getProcessPoolStats();
-	        if (workerStats != null) {
-	            MMQueueWorkerPool workerPool = convertStats(workerStats, hostName, processName, workerStats.name);
-	            
-	            process.setQueueWorkerPool(workerPool);
-	        }	        
+	        WorkerPoolStatisticsMetadata workerStats = this.socketTransport.getProcessPoolStats();
+	        process.setQueueWorkerPool(workerStats);
 	        
 	        process.setPort(this.socketTransport.getPort());
 		}

Modified: branches/JCA/runtime/src/main/java/com/metamatrix/platform/security/session/service/SessionServiceImpl.java
===================================================================
--- branches/JCA/runtime/src/main/java/com/metamatrix/platform/security/session/service/SessionServiceImpl.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/main/java/com/metamatrix/platform/security/session/service/SessionServiceImpl.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -39,11 +39,6 @@
 import javax.security.auth.login.LoginContext;
 import javax.security.auth.login.LoginException;
 
-import org.jboss.managed.api.annotation.ManagementComponent;
-import org.jboss.managed.api.annotation.ManagementObject;
-import org.jboss.managed.api.annotation.ManagementProperties;
-import org.jboss.managed.api.annotation.ManagementProperty;
-import org.jboss.managed.api.annotation.ViewUse;
 import org.teiid.adminapi.impl.SessionMetadata;
 import org.teiid.adminapi.impl.VDBMetaData;
 import org.teiid.deployers.VDBRepository;
@@ -66,7 +61,6 @@
 /**
  * This class serves as the primary implementation of the Session Service.
  */
- at ManagementObject(isRuntime=true, componentType=@ManagementComponent(type="teiid",subtype="sessions"), properties=ManagementProperties.EXPLICIT)
 public class SessionServiceImpl implements SessionService, Serializable {
 	private static final long serialVersionUID = 3366022966048148299L;
 
@@ -207,7 +201,6 @@
 	}
 	
 	@Override
-	@ManagementProperty(description="Active sessions", use={ViewUse.STATISTIC}, readOnly=true)
 	public Collection<SessionMetadata> getActiveSessions() throws SessionServiceException {
 		return new ArrayList<SessionMetadata>(this.sessionCache.values());
 	}
@@ -218,7 +211,6 @@
 	}	
 
 	@Override
-	@ManagementProperty(description="Active session count", use={ViewUse.STATISTIC}, readOnly=true)
 	public int getActiveSessionsCount() throws SessionServiceException{
 		return this.sessionCache.size();
 	}

Modified: branches/JCA/runtime/src/main/java/org/teiid/transport/AdminAuthorizationInterceptor.java
===================================================================
--- branches/JCA/runtime/src/main/java/org/teiid/transport/AdminAuthorizationInterceptor.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/main/java/org/teiid/transport/AdminAuthorizationInterceptor.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -27,6 +27,7 @@
 import java.lang.reflect.Method;
 import java.util.Arrays;
 
+import org.teiid.adminapi.AdminProcessingException;
 import org.teiid.adminapi.AdminRoles;
 import org.teiid.dqp.internal.process.DQPWorkContext;
 
@@ -36,7 +37,6 @@
 import com.metamatrix.client.ExceptionUtil;
 import com.metamatrix.common.comm.platform.CommPlatformPlugin;
 import com.metamatrix.common.log.LogManager;
-import com.metamatrix.core.MetaMatrixRuntimeException;
 import com.metamatrix.core.log.MessageLevel;
 import com.metamatrix.core.util.ArgCheck;
 import com.metamatrix.dqp.service.AuditMessage;
@@ -91,7 +91,7 @@
         	}
         }
         if (allowed == null || allowed.value() == null) {
-        	throw new MetaMatrixRuntimeException("Could not determine roles allowed for admin method"); //$NON-NLS-1$
+        	throw new AdminProcessingException("Could not determine roles allowed for admin method"); //$NON-NLS-1$
         }
 
         boolean authorized = false;

Modified: branches/JCA/runtime/src/main/java/org/teiid/transport/LogonImpl.java
===================================================================
--- branches/JCA/runtime/src/main/java/org/teiid/transport/LogonImpl.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/main/java/org/teiid/transport/LogonImpl.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -143,22 +143,4 @@
 		}
 		this.updateDQPContext(sessionInfo);
 	}
-
-	@Override
-	public void terminate(SessionToken terminatee) {
-		long terminator = DQPWorkContext.getWorkContext().getSessionId();
-		
-		SessionMetadata info = this.service.getActiveSession(terminatee.getSessionID());
-		if (info != null) {
-			try {
-				if (info.getVDBName() != null) {
-					this.dqpService.terminateConnection(terminatee.getSessionID());
-				}
-			} catch (MetaMatrixComponentException e) {
-				LogManager.logError(LogConstants.CTX_SESSION, e, "Exception terminitating session");
-			} finally {
-				this.service.terminateSession(terminator, terminatee.getSessionID());
-			}
-		}
-	}
 }

Modified: branches/JCA/runtime/src/main/java/org/teiid/transport/SocketListener.java
===================================================================
--- branches/JCA/runtime/src/main/java/org/teiid/transport/SocketListener.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/main/java/org/teiid/transport/SocketListener.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -34,6 +34,7 @@
 import org.jboss.netty.channel.Channel;
 import org.jboss.netty.channel.ChannelFactory;
 import org.jboss.netty.channel.socket.nio.NioServerSocketChannelFactory;
+import org.teiid.adminapi.impl.WorkerPoolStatisticsMetadata;
 import org.teiid.transport.ChannelListener.ChannelListenerFactory;
 
 import com.metamatrix.common.CommonPlugin;
@@ -42,7 +43,6 @@
 import com.metamatrix.common.log.LogManager;
 import com.metamatrix.common.queue.WorkerPool;
 import com.metamatrix.common.queue.WorkerPoolFactory;
-import com.metamatrix.common.queue.WorkerPoolStats;
 import com.metamatrix.common.util.ApplicationInfo;
 import com.metamatrix.common.util.LogConstants;
 import com.metamatrix.core.log.MessageLevel;
@@ -98,7 +98,7 @@
         this.serverChanel = bootstrap.bind(new InetSocketAddress(bindAddress, port));
     }
     
-    public WorkerPoolStats getProcessPoolStats() {
+    public WorkerPoolStatisticsMetadata getProcessPoolStats() {
     	return this.workerPool.getStats();
     }
     

Modified: branches/JCA/runtime/src/main/java/org/teiid/transport/SocketTransport.java
===================================================================
--- branches/JCA/runtime/src/main/java/org/teiid/transport/SocketTransport.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/main/java/org/teiid/transport/SocketTransport.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -29,9 +29,10 @@
 
 import javax.resource.spi.work.WorkManager;
 
+import org.teiid.adminapi.impl.WorkerPoolStatisticsMetadata;
+
 import com.metamatrix.common.comm.ClientServiceRegistry;
 import com.metamatrix.common.log.LogManager;
-import com.metamatrix.common.queue.WorkerPoolStats;
 import com.metamatrix.common.util.LogConstants;
 import com.metamatrix.common.util.PropertiesUtils;
 import com.metamatrix.core.MetaMatrixRuntimeException;
@@ -90,7 +91,7 @@
     	this.listener.stop();
     }
     
-    public WorkerPoolStats getProcessPoolStats() {
+    public WorkerPoolStatisticsMetadata getProcessPoolStats() {
     	return listener.getProcessPoolStats();
     }
     

Deleted: branches/JCA/runtime/src/test/java/com/metamatrix/dqp/embedded/admin/TestBaseAdmin.java
===================================================================
--- branches/JCA/runtime/src/test/java/com/metamatrix/dqp/embedded/admin/TestBaseAdmin.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/test/java/com/metamatrix/dqp/embedded/admin/TestBaseAdmin.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -1,101 +0,0 @@
-/*
- * 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 com.metamatrix.dqp.embedded.admin;
-
-import junit.framework.TestCase;
-
-
-/** 
- * @since 4.3
- */
-public class TestBaseAdmin extends TestCase {
-
-    public void testRegexStuff() {
-        assertTrue("RegEx Failed", "one".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "one two".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "one two three ".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "one9_two_Three".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "one9_two*Three".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "#one9_two Three".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        
-        assertTrue("RegEx Failed", "one".matches(BaseAdmin.SINGLE_WORD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "one ".matches(BaseAdmin.SINGLE_WORD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "one*".matches(BaseAdmin.SINGLE_WORD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "one two".matches(BaseAdmin.SINGLE_WORD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "one_TWO_three".matches(BaseAdmin.SINGLE_WORD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        
-        assertTrue("RegEx Failed", "one*".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "one two*".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "one two *".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "*one two*".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "*".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "#two*".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "one.*".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "one.two".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "one.two*".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        
-        
-        assertTrue("RegEx Failed", "*".matches(BaseAdmin.SINGLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "one*".matches(BaseAdmin.SINGLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "one_TWO_three*".matches(BaseAdmin.SINGLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "*one".matches(BaseAdmin.SINGLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "* one".matches(BaseAdmin.SINGLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "*.*".matches(BaseAdmin.SINGLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "one.*".matches(BaseAdmin.SINGLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-
-        
-        assertTrue("RegEx Failed", "*".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "one.*".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "one".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "one.two".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "*.one".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "one_two *".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "one.two*".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$       
-        assertTrue("RegEx Failed", "one.two*.three*".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$        
-        assertFalse("RegEx Failed", "one.two**".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$                       
-        assertTrue("RegEx Failed", "one.two.*".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$        
-        assertTrue("RegEx Failed", "one*".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "one.".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "0.10.*".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "0.10..*".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "0.10..".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", ".one*".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", ".one_two".matches(BaseAdmin.WORD_AND_DOT_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        
-        assertTrue("RegEx Failed", "One".matches(BaseAdmin.VDB_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "One.1".matches(BaseAdmin.VDB_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "*.1".matches(BaseAdmin.VDB_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "One.One".matches(BaseAdmin.VDB_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "One*".matches(BaseAdmin.VDB_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "One*.101".matches(BaseAdmin.VDB_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "*.*".matches(BaseAdmin.VDB_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "100.*".matches(BaseAdmin.VDB_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", ".1".matches(BaseAdmin.VDB_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        //assertTrue("RegEx Failed", "V0.*".matches(BaseAdmin.VDB_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        
-        assertTrue("RegEx Failed", "XML-Relational File Connector".matches(BaseAdmin.MULTIPLE_WORDS_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertTrue("RegEx Failed", "XML Connector".matches(BaseAdmin.MULTIPLE_WORDS_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        assertFalse("RegEx Failed", "XML&Relational Connector".matches(BaseAdmin.MULTIPLE_WORDS_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-        //assertTrue("RegEx Failed", "".matches(BaseAdmin.MULTIPLE_WORD_WILDCARD_REGEX)); //$NON-NLS-1$ //$NON-NLS-2$
-    }
-}

Modified: branches/JCA/runtime/src/test/java/org/teiid/transport/TestSocketRemoting.java
===================================================================
--- branches/JCA/runtime/src/test/java/org/teiid/transport/TestSocketRemoting.java	2010-01-06 19:31:14 UTC (rev 1720)
+++ branches/JCA/runtime/src/test/java/org/teiid/transport/TestSocketRemoting.java	2010-01-08 16:42:28 UTC (rev 1721)
@@ -169,10 +169,6 @@
 					MetaMatrixComponentException {
 				}
 
-				@Override
-				public void terminate(SessionToken sessionId) {
-				}
-
 			}, "foo"); //$NON-NLS-1$
 		csr.registerClientService(FakeService.class, new FakeServiceImpl(), "foo"); //$NON-NLS-1$
 		final FakeClientServerInstance serverInstance = new FakeClientServerInstance(csr);



More information about the teiid-commits mailing list