[jboss-svn-commits] JBL Code SVN: r31993 - in labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src: main/java/org/drools/services/command and 2 other directories.

jboss-svn-commits at lists.jboss.org jboss-svn-commits at lists.jboss.org
Mon Mar 8 08:12:12 EST 2010


Author: salaboy21
Date: 2010-03-08 08:12:12 -0500 (Mon, 08 Mar 2010)
New Revision: 31993

Added:
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/ExecutionGridConnection.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/ExecutionNodeConnection.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/LocalExecutionNodeConnection.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/RemoteExecutionNodeConnection.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ExecutionNodeClientConnectCommand.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ExecutionNodeContext.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/ExecutionNodeBaseTest.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/LocalExecutionNodeTest.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/RemoteExecutionNodeTest.java
Removed:
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/GridConnection.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/LocalNodeConnection.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/NodeConnection.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/RemoteNodeConnection.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ServiceManagerClientConnectCommand.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ServiceManagerServerContext.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/LocalNodeServiceTest.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/NodeServiceLocatorBaseTest.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/RemoteNodeServiceTest.java
Modified:
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBaseProviderRemoteClient.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBaseRemoteClient.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBuilderProviderRemoteClient.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBuilderRemoteClient.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/StatefulKnowledgeSessionRemoteClient.java
   labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/WorkItemManagerRemoteClient.java
Log:
JBRULES-2446: Drools Services API
	- drools-services more refactoring

Copied: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/ExecutionGridConnection.java (from rev 31991, labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/GridConnection.java)
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/ExecutionGridConnection.java	                        (rev 0)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/ExecutionGridConnection.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -0,0 +1,58 @@
+/*
+ *  Copyright 2010 salaboy.
+ * 
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *  under the License.
+ */
+
+package org.drools.services;
+
+import java.util.List;
+
+/**
+ *
+ * @author salaboy
+ */
+public class ExecutionGridConnection {
+    private List<ExecutionNode> nodes;
+    private String url;
+
+    public ExecutionGridConnection() {
+    }
+
+    public ExecutionGridConnection(String url) {
+        this.url = url;
+    }
+
+    public List<ExecutionNode> connect(){
+        return this.nodes;
+    }
+
+    public List<ExecutionNode> getNodes() {
+        return nodes;
+    }
+
+    public void setNodes(List<ExecutionNode> nodes) {
+        this.nodes = nodes;
+    }
+
+    public String getUrl() {
+        return url;
+    }
+
+    public void setUrl(String url) {
+        this.url = url;
+    }
+
+    
+}

Copied: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/ExecutionNodeConnection.java (from rev 31991, labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/NodeConnection.java)
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/ExecutionNodeConnection.java	                        (rev 0)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/ExecutionNodeConnection.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -0,0 +1,28 @@
+/*
+ *  Copyright 2010 salaboy.
+ * 
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *  under the License.
+ */
+
+package org.drools.services;
+
+/**
+ *
+ * @author salaboy
+ */
+public interface ExecutionNodeConnection {
+    public ExecutionNode connect();
+    public void disconnect();
+    
+}

Deleted: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/GridConnection.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/GridConnection.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/GridConnection.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -1,58 +0,0 @@
-/*
- *  Copyright 2010 salaboy.
- * 
- *  Licensed under the Apache License, Version 2.0 (the "License");
- *  you may not use this file except in compliance with the License.
- *  You may obtain a copy of the License at
- * 
- *       http://www.apache.org/licenses/LICENSE-2.0
- * 
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- *  under the License.
- */
-
-package org.drools.services;
-
-import java.util.List;
-
-/**
- *
- * @author salaboy
- */
-public class GridConnection {
-    private List<ExecutionNode> nodes;
-    private String url;
-
-    public GridConnection() {
-    }
-
-    public GridConnection(String url) {
-        this.url = url;
-    }
-
-    public List<ExecutionNode> connect(){
-        return this.nodes;
-    }
-
-    public List<ExecutionNode> getNodes() {
-        return nodes;
-    }
-
-    public void setNodes(List<ExecutionNode> nodes) {
-        this.nodes = nodes;
-    }
-
-    public String getUrl() {
-        return url;
-    }
-
-    public void setUrl(String url) {
-        this.url = url;
-    }
-
-    
-}

Copied: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/LocalExecutionNodeConnection.java (from rev 31991, labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/LocalNodeConnection.java)
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/LocalExecutionNodeConnection.java	                        (rev 0)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/LocalExecutionNodeConnection.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -0,0 +1,49 @@
+/*
+ *  Copyright 2010 salaboy.
+ * 
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *  under the License.
+ */
+
+package org.drools.services;
+import org.drools.KnowledgeBaseFactoryService;
+import org.drools.builder.KnowledgeBuilderFactoryService;
+import org.drools.services.local.KnowledgeBaseProviderLocalClient;
+import org.drools.services.local.KnowledgeBuilderProviderLocalClient;
+/**
+ *
+ * @author salaboy
+ */
+public class LocalExecutionNodeConnection implements ExecutionNodeConnection {
+
+    
+
+    public LocalExecutionNodeConnection() {
+    }
+
+
+    public ExecutionNode connect() {
+        ExecutionNode node = new ExecutionNode();
+        node.set(KnowledgeBuilderFactoryService.class, new KnowledgeBuilderProviderLocalClient() );
+        node.set(KnowledgeBaseFactoryService.class, new KnowledgeBaseProviderLocalClient() );
+
+        return node;
+    }
+
+    public void disconnect() {
+        
+    }
+
+    
+
+}

Deleted: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/LocalNodeConnection.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/LocalNodeConnection.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/LocalNodeConnection.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -1,49 +0,0 @@
-/*
- *  Copyright 2010 salaboy.
- * 
- *  Licensed under the Apache License, Version 2.0 (the "License");
- *  you may not use this file except in compliance with the License.
- *  You may obtain a copy of the License at
- * 
- *       http://www.apache.org/licenses/LICENSE-2.0
- * 
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- *  under the License.
- */
-
-package org.drools.services;
-import org.drools.KnowledgeBaseFactoryService;
-import org.drools.builder.KnowledgeBuilderFactoryService;
-import org.drools.services.local.KnowledgeBaseProviderLocalClient;
-import org.drools.services.local.KnowledgeBuilderProviderLocalClient;
-/**
- *
- * @author salaboy
- */
-public class LocalNodeConnection implements NodeConnection {
-
-    
-
-    public LocalNodeConnection() {
-    }
-
-
-    public ExecutionNode connect() {
-        ExecutionNode node = new ExecutionNode();
-        node.set(KnowledgeBuilderFactoryService.class, new KnowledgeBuilderProviderLocalClient() );
-        node.set(KnowledgeBaseFactoryService.class, new KnowledgeBaseProviderLocalClient() );
-
-        return node;
-    }
-
-    public void disconnect() {
-        
-    }
-
-    
-
-}

Deleted: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/NodeConnection.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/NodeConnection.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/NodeConnection.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -1,28 +0,0 @@
-/*
- *  Copyright 2010 salaboy.
- * 
- *  Licensed under the Apache License, Version 2.0 (the "License");
- *  you may not use this file except in compliance with the License.
- *  You may obtain a copy of the License at
- * 
- *       http://www.apache.org/licenses/LICENSE-2.0
- * 
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- *  under the License.
- */
-
-package org.drools.services;
-
-/**
- *
- * @author salaboy
- */
-public interface NodeConnection {
-    public ExecutionNode connect();
-    public void disconnect();
-    
-}

Copied: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/RemoteExecutionNodeConnection.java (from rev 31991, labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/RemoteNodeConnection.java)
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/RemoteExecutionNodeConnection.java	                        (rev 0)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/RemoteExecutionNodeConnection.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -0,0 +1,95 @@
+/*
+ *  Copyright 2010 salaboy.
+ * 
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *  under the License.
+ */
+
+package org.drools.services;
+
+import java.util.List;
+import java.util.concurrent.atomic.AtomicInteger;
+import org.drools.KnowledgeBaseFactoryService;
+import org.drools.builder.KnowledgeBuilderFactoryService;
+import org.drools.services.generic.GenericConnector;
+import org.drools.services.remote.KnowledgeBaseProviderRemoteClient;
+import org.drools.services.remote.KnowledgeBuilderProviderRemoteClient;
+
+/**
+ *
+ * @author salaboy
+ */
+public class RemoteExecutionNodeConnection implements ExecutionNodeConnection {
+
+    private String name;
+
+    public GenericConnector client;
+
+    private List<GenericConnector> services;
+
+    public AtomicInteger    counter;
+
+    private int sessionId = -1;
+
+
+    
+
+    public RemoteExecutionNodeConnection(String name, GenericConnector connector) {
+        this.name = name;
+        this.client = connector;
+        this.counter = new AtomicInteger();
+    }
+
+    public ExecutionNode connect() {
+
+        if(client.connect()){
+
+            ExecutionNode node = new ExecutionNode();
+            node.set(KnowledgeBuilderFactoryService.class, new KnowledgeBuilderProviderRemoteClient(this) );
+            node.set(KnowledgeBaseFactoryService.class, new KnowledgeBaseProviderRemoteClient(this) );
+            return node;
+        }
+        return null;
+    }
+
+    public void disconnect(){
+        client.disconnect();
+    }
+    public GenericConnector getClient() {
+        return client;
+    }
+
+    public void setClient(GenericConnector client) {
+        this.client = client;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+   
+
+    
+    public int getSessionId() {
+        return sessionId;
+    }
+
+    public int getNextId() {
+        return this.counter.incrementAndGet();
+    }
+
+}

Deleted: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/RemoteNodeConnection.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/RemoteNodeConnection.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/RemoteNodeConnection.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -1,95 +0,0 @@
-/*
- *  Copyright 2010 salaboy.
- * 
- *  Licensed under the Apache License, Version 2.0 (the "License");
- *  you may not use this file except in compliance with the License.
- *  You may obtain a copy of the License at
- * 
- *       http://www.apache.org/licenses/LICENSE-2.0
- * 
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- *  under the License.
- */
-
-package org.drools.services;
-
-import java.util.List;
-import java.util.concurrent.atomic.AtomicInteger;
-import org.drools.KnowledgeBaseFactoryService;
-import org.drools.builder.KnowledgeBuilderFactoryService;
-import org.drools.services.generic.GenericConnector;
-import org.drools.services.remote.KnowledgeBaseProviderRemoteClient;
-import org.drools.services.remote.KnowledgeBuilderProviderRemoteClient;
-
-/**
- *
- * @author salaboy
- */
-public class RemoteNodeConnection implements NodeConnection {
-
-    private String name;
-
-    public GenericConnector client;
-
-    private List<GenericConnector> services;
-
-    public AtomicInteger    counter;
-
-    private int sessionId = -1;
-
-
-    
-
-    public RemoteNodeConnection(String name, GenericConnector connector) {
-        this.name = name;
-        this.client = connector;
-        this.counter = new AtomicInteger();
-    }
-
-    public ExecutionNode connect() {
-
-        if(client.connect()){
-
-            ExecutionNode node = new ExecutionNode();
-            node.set(KnowledgeBuilderFactoryService.class, new KnowledgeBuilderProviderRemoteClient(this) );
-            node.set(KnowledgeBaseFactoryService.class, new KnowledgeBaseProviderRemoteClient(this) );
-            return node;
-        }
-        return null;
-    }
-
-    public void disconnect(){
-        client.disconnect();
-    }
-    public GenericConnector getClient() {
-        return client;
-    }
-
-    public void setClient(GenericConnector client) {
-        this.client = client;
-    }
-
-    public String getName() {
-        return name;
-    }
-
-    public void setName(String name) {
-        this.name = name;
-    }
-
-   
-
-    
-    public int getSessionId() {
-        return sessionId;
-    }
-
-    public int getNextId() {
-        return this.counter.incrementAndGet();
-    }
-
-}

Copied: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ExecutionNodeClientConnectCommand.java (from rev 31991, labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ServiceManagerClientConnectCommand.java)
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ExecutionNodeClientConnectCommand.java	                        (rev 0)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ExecutionNodeClientConnectCommand.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -0,0 +1,34 @@
+package org.drools.services.command;
+
+import org.drools.command.Context;
+import org.drools.command.impl.GenericCommand;
+import org.drools.command.impl.KnowledgeCommandContext;
+import org.drools.runtime.impl.ExecutionResultImpl;
+import org.drools.services.generic.NodeData;
+
+public class ExecutionNodeClientConnectCommand
+    implements
+    GenericCommand<Integer> {
+    
+    private String outIdentifier;
+
+    
+
+    public ExecutionNodeClientConnectCommand(String outIdentifier) {
+        this.outIdentifier = outIdentifier;
+    }
+
+
+
+    public Integer execute(Context context) {
+        NodeData data = (NodeData) context.get( NodeData.NODE_DATA );
+        
+        Integer sessionId = data.getSessionIdCounter().getAndIncrement();
+        if ( this.outIdentifier != null ) {
+            ((ExecutionResultImpl)((KnowledgeCommandContext) context).getExecutionResults()).getResults().put( this.outIdentifier, sessionId );
+        } 
+        
+        return sessionId;
+    }
+
+}

Copied: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ExecutionNodeContext.java (from rev 31991, labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ServiceManagerServerContext.java)
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ExecutionNodeContext.java	                        (rev 0)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ExecutionNodeContext.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -0,0 +1,40 @@
+package org.drools.services.command;
+
+import org.drools.command.Context;
+import org.drools.command.ContextManager;
+import org.drools.services.generic.NodeData;
+
+public class ExecutionNodeContext
+    implements
+    Context {
+    private Context            context;
+    private NodeData data;
+
+    public ExecutionNodeContext(Context context,
+                                       NodeData data) {
+        this.data = data;
+    }
+
+    public NodeData getServiceManagerData() {
+        return this.data;
+    }
+
+    public ContextManager getContextManager() {
+        return context.getContextManager();
+    }
+
+    public String getName() {
+        return context.getName();
+    }
+
+    public Object get(String identifier) {
+        return context.get( identifier );
+    }
+
+    public void set(String identifier,
+                    Object value) {
+        context.set( identifier,
+                     value );
+    }
+
+}

Deleted: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ServiceManagerClientConnectCommand.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ServiceManagerClientConnectCommand.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ServiceManagerClientConnectCommand.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -1,34 +0,0 @@
-package org.drools.services.command;
-
-import org.drools.command.Context;
-import org.drools.command.impl.GenericCommand;
-import org.drools.command.impl.KnowledgeCommandContext;
-import org.drools.runtime.impl.ExecutionResultImpl;
-import org.drools.services.generic.NodeData;
-
-public class ServiceManagerClientConnectCommand
-    implements
-    GenericCommand<Integer> {
-    
-    private String outIdentifier;
-
-    
-
-    public ServiceManagerClientConnectCommand(String outIdentifier) {
-        this.outIdentifier = outIdentifier;
-    }
-
-
-
-    public Integer execute(Context context) {
-        NodeData data = (NodeData) context.get( NodeData.NODE_DATA );
-        
-        Integer sessionId = data.getSessionIdCounter().getAndIncrement();
-        if ( this.outIdentifier != null ) {
-            ((ExecutionResultImpl)((KnowledgeCommandContext) context).getExecutionResults()).getResults().put( this.outIdentifier, sessionId );
-        } 
-        
-        return sessionId;
-    }
-
-}

Deleted: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ServiceManagerServerContext.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ServiceManagerServerContext.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/command/ServiceManagerServerContext.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -1,40 +0,0 @@
-package org.drools.services.command;
-
-import org.drools.command.Context;
-import org.drools.command.ContextManager;
-import org.drools.services.generic.NodeData;
-
-public class ServiceManagerServerContext
-    implements
-    Context {
-    private Context            context;
-    private NodeData data;
-
-    public ServiceManagerServerContext(Context context,
-                                       NodeData data) {
-        this.data = data;
-    }
-
-    public NodeData getServiceManagerData() {
-        return this.data;
-    }
-
-    public ContextManager getContextManager() {
-        return context.getContextManager();
-    }
-
-    public String getName() {
-        return context.getName();
-    }
-
-    public Object get(String identifier) {
-        return context.get( identifier );
-    }
-
-    public void set(String identifier,
-                    Object value) {
-        context.set( identifier,
-                     value );
-    }
-
-}

Modified: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBaseProviderRemoteClient.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBaseProviderRemoteClient.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBaseProviderRemoteClient.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -11,15 +11,15 @@
 import org.drools.command.SetVariableCommand;
 import org.drools.runtime.Environment;
 import org.drools.runtime.KnowledgeSessionConfiguration;
-import org.drools.services.RemoteNodeConnection;
+import org.drools.services.RemoteExecutionNodeConnection;
 import org.drools.services.generic.Message;
 
 public class KnowledgeBaseProviderRemoteClient
     implements
     KnowledgeBaseFactoryService {
-    private RemoteNodeConnection nodeConnection;
+    private RemoteExecutionNodeConnection nodeConnection;
 
-    public KnowledgeBaseProviderRemoteClient(RemoteNodeConnection nodeConnection) {
+    public KnowledgeBaseProviderRemoteClient(RemoteExecutionNodeConnection nodeConnection) {
         this.nodeConnection = nodeConnection;
     }
 

Modified: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBaseRemoteClient.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBaseRemoteClient.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBaseRemoteClient.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -18,7 +18,7 @@
 import org.drools.runtime.KnowledgeSessionConfiguration;
 import org.drools.runtime.StatefulKnowledgeSession;
 import org.drools.runtime.StatelessKnowledgeSession;
-import org.drools.services.RemoteNodeConnection;
+import org.drools.services.RemoteExecutionNodeConnection;
 import org.drools.services.generic.CollectionClient;
 import org.drools.services.generic.Message;
 
@@ -26,11 +26,11 @@
     implements
     KnowledgeBase {
 
-    private RemoteNodeConnection nodeConnection;
+    private RemoteExecutionNodeConnection nodeConnection;
     private String                     instanceId;
 
     public KnowledgeBaseRemoteClient(String instanceId,
-                                     RemoteNodeConnection nodeConnection) {
+                                     RemoteExecutionNodeConnection nodeConnection) {
         this.instanceId = instanceId;
         this.nodeConnection = nodeConnection;
     }

Modified: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBuilderProviderRemoteClient.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBuilderProviderRemoteClient.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBuilderProviderRemoteClient.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -14,15 +14,15 @@
 import org.drools.command.FinishedCommand;
 import org.drools.command.SetVariableCommand;
 import org.drools.command.builder.NewKnowledgeBuilderCommand;
-import org.drools.services.RemoteNodeConnection;
+import org.drools.services.RemoteExecutionNodeConnection;
 import org.drools.services.generic.Message;
 
 public class KnowledgeBuilderProviderRemoteClient
     implements
     KnowledgeBuilderFactoryService {
-    private RemoteNodeConnection nodeConnection;
+    private RemoteExecutionNodeConnection nodeConnection;
 
-    public KnowledgeBuilderProviderRemoteClient(RemoteNodeConnection nodeConnection) {
+    public KnowledgeBuilderProviderRemoteClient(RemoteExecutionNodeConnection nodeConnection) {
         this.nodeConnection =  nodeConnection;
     }
 

Modified: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBuilderRemoteClient.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBuilderRemoteClient.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/KnowledgeBuilderRemoteClient.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -15,18 +15,18 @@
 import org.drools.definition.KnowledgePackage;
 import org.drools.io.Resource;
 import org.drools.runtime.ExecutionResults;
-import org.drools.services.RemoteNodeConnection;
+import org.drools.services.RemoteExecutionNodeConnection;
 import org.drools.services.generic.CollectionClient;
 import org.drools.services.generic.Message;
 
 public class KnowledgeBuilderRemoteClient
     implements
     KnowledgeBuilder {
-    private RemoteNodeConnection nodeConnection;
+    private RemoteExecutionNodeConnection nodeConnection;
     private String                     instanceId;
 
     public KnowledgeBuilderRemoteClient(String instanceId,
-                                        RemoteNodeConnection nodeConnection) {
+                                        RemoteExecutionNodeConnection nodeConnection) {
         this.instanceId = instanceId;
         this.nodeConnection = nodeConnection;
     }

Modified: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/StatefulKnowledgeSessionRemoteClient.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/StatefulKnowledgeSessionRemoteClient.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/StatefulKnowledgeSessionRemoteClient.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -28,7 +28,7 @@
 import org.drools.runtime.rule.FactHandle;
 import org.drools.runtime.rule.QueryResults;
 import org.drools.runtime.rule.WorkingMemoryEntryPoint;
-import org.drools.services.RemoteNodeConnection;
+import org.drools.services.RemoteExecutionNodeConnection;
 import org.drools.time.SessionClock;
 import org.drools.services.generic.Message;
 
@@ -36,11 +36,11 @@
     implements
     StatefulKnowledgeSession {
 
-    private RemoteNodeConnection nodeConnection;
+    private RemoteExecutionNodeConnection nodeConnection;
     private String                     instanceId;
 
     public StatefulKnowledgeSessionRemoteClient(String instanceId,
-                                                RemoteNodeConnection nodeConnection) {
+                                                RemoteExecutionNodeConnection nodeConnection) {
         this.instanceId = instanceId;
         this.nodeConnection = nodeConnection;
     }

Modified: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/WorkItemManagerRemoteClient.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/WorkItemManagerRemoteClient.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/main/java/org/drools/services/remote/WorkItemManagerRemoteClient.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -7,7 +7,7 @@
 import org.drools.command.runtime.process.CompleteWorkItemCommand;
 import org.drools.runtime.process.WorkItemHandler;
 import org.drools.runtime.process.WorkItemManager;
-import org.drools.services.RemoteNodeConnection;
+import org.drools.services.RemoteExecutionNodeConnection;
 import org.drools.services.generic.Message;
 
 /**
@@ -19,7 +19,7 @@
 
 	private static final long serialVersionUID = 1L;
 	
-	private RemoteNodeConnection nodeConnection;
+	private RemoteExecutionNodeConnection nodeConnection;
 	private String instanceId;
 
 	public void abortWorkItem(long id) {
@@ -47,7 +47,7 @@
 		throw new UnsupportedOperationException("Not supported yet.");
 	}
 
-	public void setNodeConnection(RemoteNodeConnection nodeConnection) {
+	public void setNodeConnection(RemoteExecutionNodeConnection nodeConnection) {
 		this.nodeConnection = nodeConnection;
 	}
 

Copied: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/ExecutionNodeBaseTest.java (from rev 31991, labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/NodeServiceLocatorBaseTest.java)
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/ExecutionNodeBaseTest.java	                        (rev 0)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/ExecutionNodeBaseTest.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -0,0 +1,88 @@
+/*
+ *  Copyright 2010 salaboy.
+ * 
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *  under the License.
+ */
+
+package org.drools.service;
+
+
+import org.drools.KnowledgeBase;
+import org.drools.services.ExecutionNode;
+import org.drools.KnowledgeBaseFactoryService;
+import org.drools.builder.KnowledgeBuilder;
+import org.drools.builder.KnowledgeBuilderFactoryService;
+import org.drools.builder.ResourceType;
+import org.drools.io.ResourceFactory;
+import org.drools.runtime.StatefulKnowledgeSession;
+import org.junit.Assert;
+import org.junit.Test;
+/**
+ *
+ * @author salaboy
+ */
+
+public class ExecutionNodeBaseTest {
+
+    protected ExecutionNode node;
+
+    public ExecutionNodeBaseTest() {
+        
+    }
+
+
+    @Test
+    public void fireAllRules(){
+
+        String str = "";
+        str += "package org.drools \n";
+        str += "global java.util.List list \n";
+        str += "rule rule1 \n";
+        str += "    dialect \"java\" \n";
+        str += "when \n";
+        str += "then \n";
+        str += "    System.out.println( \"hello1!!!\" ); \n";
+        str += "end \n";
+        str += "rule rule2 \n";
+        str += "    dialect \"java\" \n";
+        str += "when \n";
+        str += "then \n";
+        str += "    System.out.println( \"hello2!!!\" ); \n";
+        str += "end \n";
+
+         
+        KnowledgeBuilder kbuilder = node.get(KnowledgeBuilderFactoryService.class).newKnowledgeBuilder();
+        kbuilder.add( ResourceFactory.newByteArrayResource( str.getBytes() ),
+                      ResourceType.DRL );
+
+        if ( kbuilder.hasErrors() ) {
+            System.out.println( "Errors: " + kbuilder.getErrors() );
+        }
+
+        KnowledgeBase kbase = node.get(KnowledgeBaseFactoryService.class).newKnowledgeBase();
+        Assert.assertNotNull(kbase);
+
+        kbase.addKnowledgePackages( kbuilder.getKnowledgePackages() );
+
+        StatefulKnowledgeSession ksession = kbase.newStatefulKnowledgeSession();
+        Assert.assertNotNull(ksession);
+
+        int fired = ksession.fireAllRules();
+        Assert.assertEquals( 2, fired );
+
+
+    }
+  
+
+}

Copied: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/LocalExecutionNodeTest.java (from rev 31965, labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/LocalNodeServiceTest.java)
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/LocalExecutionNodeTest.java	                        (rev 0)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/LocalExecutionNodeTest.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -0,0 +1,48 @@
+/*
+ *  Copyright 2010 salaboy.
+ * 
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *  under the License.
+ */
+
+package org.drools.service;
+
+import org.drools.services.LocalExecutionNodeConnection;
+import org.junit.After;
+import org.junit.AfterClass;
+import org.junit.Before;
+import org.junit.BeforeClass;
+import org.junit.Test;
+import static org.junit.Assert.*;
+
+/**
+ *
+ * @author salaboy
+ */
+public class LocalExecutionNodeTest extends ExecutionNodeBaseTest{
+
+    public LocalExecutionNodeTest() {
+    }
+
+   
+
+    @Before
+    public void setUp() {
+        node = new LocalExecutionNodeConnection().connect();
+
+    }
+
+   
+
+
+}
\ No newline at end of file

Deleted: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/LocalNodeServiceTest.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/LocalNodeServiceTest.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/LocalNodeServiceTest.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -1,48 +0,0 @@
-/*
- *  Copyright 2010 salaboy.
- * 
- *  Licensed under the Apache License, Version 2.0 (the "License");
- *  you may not use this file except in compliance with the License.
- *  You may obtain a copy of the License at
- * 
- *       http://www.apache.org/licenses/LICENSE-2.0
- * 
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- *  under the License.
- */
-
-package org.drools.service;
-
-import org.drools.services.LocalNodeConnection;
-import org.junit.After;
-import org.junit.AfterClass;
-import org.junit.Before;
-import org.junit.BeforeClass;
-import org.junit.Test;
-import static org.junit.Assert.*;
-
-/**
- *
- * @author salaboy
- */
-public class LocalNodeServiceTest extends NodeServiceLocatorBaseTest{
-
-    public LocalNodeServiceTest() {
-    }
-
-   
-
-    @Before
-    public void setUp() {
-        node = new LocalNodeConnection().connect();
-
-    }
-
-   
-
-
-}
\ No newline at end of file

Deleted: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/NodeServiceLocatorBaseTest.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/NodeServiceLocatorBaseTest.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/NodeServiceLocatorBaseTest.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -1,88 +0,0 @@
-/*
- *  Copyright 2010 salaboy.
- * 
- *  Licensed under the Apache License, Version 2.0 (the "License");
- *  you may not use this file except in compliance with the License.
- *  You may obtain a copy of the License at
- * 
- *       http://www.apache.org/licenses/LICENSE-2.0
- * 
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- *  under the License.
- */
-
-package org.drools.service;
-
-
-import org.drools.KnowledgeBase;
-import org.drools.services.ExecutionNode;
-import org.drools.KnowledgeBaseFactoryService;
-import org.drools.builder.KnowledgeBuilder;
-import org.drools.builder.KnowledgeBuilderFactoryService;
-import org.drools.builder.ResourceType;
-import org.drools.io.ResourceFactory;
-import org.drools.runtime.StatefulKnowledgeSession;
-import org.junit.Assert;
-import org.junit.Test;
-/**
- *
- * @author salaboy
- */
-
-public class NodeServiceLocatorBaseTest {
-
-    protected ExecutionNode node;
-
-    public NodeServiceLocatorBaseTest() {
-        
-    }
-
-
-    @Test
-    public void fireAllRules(){
-
-        String str = "";
-        str += "package org.drools \n";
-        str += "global java.util.List list \n";
-        str += "rule rule1 \n";
-        str += "    dialect \"java\" \n";
-        str += "when \n";
-        str += "then \n";
-        str += "    System.out.println( \"hello1!!!\" ); \n";
-        str += "end \n";
-        str += "rule rule2 \n";
-        str += "    dialect \"java\" \n";
-        str += "when \n";
-        str += "then \n";
-        str += "    System.out.println( \"hello2!!!\" ); \n";
-        str += "end \n";
-
-         
-        KnowledgeBuilder kbuilder = node.get(KnowledgeBuilderFactoryService.class).newKnowledgeBuilder();
-        kbuilder.add( ResourceFactory.newByteArrayResource( str.getBytes() ),
-                      ResourceType.DRL );
-
-        if ( kbuilder.hasErrors() ) {
-            System.out.println( "Errors: " + kbuilder.getErrors() );
-        }
-
-        KnowledgeBase kbase = node.get(KnowledgeBaseFactoryService.class).newKnowledgeBase();
-        Assert.assertNotNull(kbase);
-
-        kbase.addKnowledgePackages( kbuilder.getKnowledgePackages() );
-
-        StatefulKnowledgeSession ksession = kbase.newStatefulKnowledgeSession();
-        Assert.assertNotNull(ksession);
-
-        int fired = ksession.fireAllRules();
-        Assert.assertEquals( 2, fired );
-
-
-    }
-  
-
-}

Copied: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/RemoteExecutionNodeTest.java (from rev 31991, labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/RemoteNodeServiceTest.java)
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/RemoteExecutionNodeTest.java	                        (rev 0)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/RemoteExecutionNodeTest.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -0,0 +1,84 @@
+/*
+ *  Copyright 2010 salaboy.
+ * 
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ *  under the License.
+ */
+
+package org.drools.service;
+
+import org.drools.services.ExecutionNodeConnection;
+import org.drools.services.remote.mina.MinaConnector;
+import org.drools.services.generic.GenericConnector;
+import org.apache.mina.transport.socket.nio.NioSocketConnector;
+import java.io.IOException;
+import org.drools.services.remote.mina.MinaAcceptor;
+import org.drools.services.generic.GenericMessageHandlerImpl;
+import org.drools.services.remote.mina.MinaIoHandler;
+import org.drools.SystemEventListenerFactory;
+import org.apache.mina.transport.socket.nio.NioSocketAcceptor;
+import org.apache.mina.transport.socket.SocketAcceptor;
+import org.drools.services.generic.NodeData;
+import java.net.SocketAddress;
+import java.net.InetSocketAddress;
+import org.drools.services.RemoteExecutionNodeConnection;
+import org.junit.After;
+import org.junit.Before;
+
+/**
+ *
+ * @author salaboy
+ */
+public class RemoteExecutionNodeTest extends ExecutionNodeBaseTest{
+    private MinaAcceptor server;
+    private ExecutionNodeConnection nodeConnection;
+    public RemoteExecutionNodeTest() {
+    }
+
+   
+
+    @Before
+    public void setUp() throws IOException {
+        SocketAddress address = new InetSocketAddress( "127.0.0.1",
+                                                       9123 );
+
+        NodeData serverData = new NodeData();
+        // setup Server
+        SocketAcceptor acceptor = new NioSocketAcceptor();
+        acceptor.setHandler( new MinaIoHandler( SystemEventListenerFactory.getSystemEventListener(),
+                                                new GenericMessageHandlerImpl( serverData,
+                                                                               SystemEventListenerFactory.getSystemEventListener() ) ) );
+        this.server = new MinaAcceptor( acceptor,
+                                        address );
+        this.server.start();
+
+        // setup Client
+        NioSocketConnector clientConnector = new NioSocketConnector();
+        clientConnector.setHandler( new MinaIoHandler( SystemEventListenerFactory.getSystemEventListener() ) );
+        GenericConnector minaClient = new MinaConnector( "client 1",
+                                                         clientConnector,
+                                                         address,
+                                                         SystemEventListenerFactory.getSystemEventListener() );
+
+        nodeConnection = new RemoteExecutionNodeConnection("client 1", minaClient);
+        node = nodeConnection.connect();
+    }
+
+    @After
+    public void tearDown() {
+        nodeConnection.disconnect();
+    }
+
+    
+
+}
\ No newline at end of file

Deleted: labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/RemoteNodeServiceTest.java
===================================================================
--- labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/RemoteNodeServiceTest.java	2010-03-08 13:04:41 UTC (rev 31992)
+++ labs/jbossrules/branches/salaboy_ServiceAPIs/drools-services/src/test/java/org/drools/service/RemoteNodeServiceTest.java	2010-03-08 13:12:12 UTC (rev 31993)
@@ -1,84 +0,0 @@
-/*
- *  Copyright 2010 salaboy.
- * 
- *  Licensed under the Apache License, Version 2.0 (the "License");
- *  you may not use this file except in compliance with the License.
- *  You may obtain a copy of the License at
- * 
- *       http://www.apache.org/licenses/LICENSE-2.0
- * 
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- *  under the License.
- */
-
-package org.drools.service;
-
-import org.drools.services.NodeConnection;
-import org.drools.services.remote.mina.MinaConnector;
-import org.drools.services.generic.GenericConnector;
-import org.apache.mina.transport.socket.nio.NioSocketConnector;
-import java.io.IOException;
-import org.drools.services.remote.mina.MinaAcceptor;
-import org.drools.services.generic.GenericMessageHandlerImpl;
-import org.drools.services.remote.mina.MinaIoHandler;
-import org.drools.SystemEventListenerFactory;
-import org.apache.mina.transport.socket.nio.NioSocketAcceptor;
-import org.apache.mina.transport.socket.SocketAcceptor;
-import org.drools.services.generic.NodeData;
-import java.net.SocketAddress;
-import java.net.InetSocketAddress;
-import org.drools.services.RemoteNodeConnection;
-import org.junit.After;
-import org.junit.Before;
-
-/**
- *
- * @author salaboy
- */
-public class RemoteNodeServiceTest extends NodeServiceLocatorBaseTest{
-    private MinaAcceptor server;
-    private NodeConnection nodeConnection;
-    public RemoteNodeServiceTest() {
-    }
-
-   
-
-    @Before
-    public void setUp() throws IOException {
-        SocketAddress address = new InetSocketAddress( "127.0.0.1",
-                                                       9123 );
-
-        NodeData serverData = new NodeData();
-        // setup Server
-        SocketAcceptor acceptor = new NioSocketAcceptor();
-        acceptor.setHandler( new MinaIoHandler( SystemEventListenerFactory.getSystemEventListener(),
-                                                new GenericMessageHandlerImpl( serverData,
-                                                                               SystemEventListenerFactory.getSystemEventListener() ) ) );
-        this.server = new MinaAcceptor( acceptor,
-                                        address );
-        this.server.start();
-
-        // setup Client
-        NioSocketConnector clientConnector = new NioSocketConnector();
-        clientConnector.setHandler( new MinaIoHandler( SystemEventListenerFactory.getSystemEventListener() ) );
-        GenericConnector minaClient = new MinaConnector( "client 1",
-                                                         clientConnector,
-                                                         address,
-                                                         SystemEventListenerFactory.getSystemEventListener() );
-
-        nodeConnection = new RemoteNodeConnection("client 1", minaClient);
-        node = nodeConnection.connect();
-    }
-
-    @After
-    public void tearDown() {
-        nodeConnection.disconnect();
-    }
-
-    
-
-}
\ No newline at end of file



More information about the jboss-svn-commits mailing list