Overlord SVN: r484 - cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/actions/stateless.
by overlord-commits@lists.jboss.org
Author: objectiser
Date: 2009-02-09 15:27:42 -0500 (Mon, 09 Feb 2009)
New Revision: 484
Modified:
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/actions/stateless/SwitchAction.java
Log:
Add 'event' element, with an appropriate description, for top level SwitchAction paths that are not triggered by received message types.
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/actions/stateless/SwitchAction.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/actions/stateless/SwitchAction.java 2009-02-07 20:41:26 UTC (rev 483)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/actions/stateless/SwitchAction.java 2009-02-09 20:27:42 UTC (rev 484)
@@ -34,7 +34,9 @@
private static final long serialVersionUID = 3765702614644769281L;
public static final String TYPE_ATTR = "type";
+ public static final String DESCRIPTION_ATTR = "description";
public static final String MESSAGE_ELEMENT = "message";
+ public static final String EVENT_ELEMENT = "event";
private static final String SERVICE_NAME = "service-name";
private static final String SERVICE_CATEGORY = "service-category";
private static final String CASE = "case";
@@ -257,6 +259,8 @@
public void addCase(String category, String name,
java.util.Set<Interaction> messageTypes, int position) {
boolean f_associatePath=false;
+ boolean f_eventBased=false;
+ String eventDescription="TODO: Path triggered by internal event";
org.w3c.dom.Element paths=getPropertyElement(PATHS);
org.w3c.dom.Element path=
@@ -267,6 +271,7 @@
if (messageTypes != null && messageTypes.size() > 0) {
java.util.Iterator<Interaction> iter=messageTypes.iterator();
boolean f_onlySend=true;
+ String sendEventTypes=null;
while (iter.hasNext()) {
Interaction interaction=iter.next();
@@ -291,6 +296,16 @@
f_associatePath = true;
}
+ } else if (interaction.getMessageSignature().getTypes().size()==1) {
+ if (sendEventTypes == null) {
+ sendEventTypes = InteractionUtil.getTypeString(
+ interaction.getMessageSignature().
+ getTypes().get(0));
+ } else {
+ sendEventTypes += ", "+InteractionUtil.getTypeString(
+ interaction.getMessageSignature().
+ getTypes().get(0));
+ }
}
}
@@ -301,6 +316,11 @@
// conformance checking to understand that it is a
// valid path, that needs to be handled.
f_associatePath = true;
+
+ f_eventBased = true;
+
+ eventDescription="Event trigger to send "+
+ sendEventTypes+" message type(s)";
}
} else {
// Associate the path, even though it has no associated
@@ -309,8 +329,19 @@
// conformance checking to understand that it is a
// valid path, that needs to be handled.
f_associatePath = true;
+
+ f_eventBased = true;
}
+ if (f_eventBased) {
+ org.w3c.dom.Element mt=
+ getAction().getOwnerDocument().createElement(EVENT_ELEMENT);
+
+ mt.setAttribute(DESCRIPTION_ATTR, eventDescription);
+
+ path.appendChild(mt);
+ }
+
//if (f_associatePath) {
paths.appendChild(path);
//}
15 years, 2 months
Overlord SVN: r483 - in cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src: test and 7 other directories.
by overlord-commits@lists.jboss.org
Author: objectiser
Date: 2009-02-07 15:41:26 -0500 (Sat, 07 Feb 2009)
New Revision: 483
Added:
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/generator/
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/generator/GeneratorTest.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/generator/MANIFEST.MF
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/generator/ManifestRegistryUtil.java
Log:
Added unit test
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/generator/GeneratorTest.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/generator/GeneratorTest.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/generator/GeneratorTest.java 2009-02-07 20:41:26 UTC (rev 483)
@@ -0,0 +1,126 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.generator;
+
+import org.jboss.tools.overlord.cdl.bpel.model.BPELLanguageModel;
+import org.jboss.tools.overlord.cdl.bpel.model.DefaultBPELLanguageModel;
+import org.scribble.extensions.RegistryFactory;
+import org.scribble.model.*;
+import org.scribble.model.change.ModelGenerator;
+import org.scribble.conversation.model.*;
+
+import junit.framework.TestCase;
+
+public class GeneratorTest extends TestCase {
+
+ protected void setUp() {
+
+ // Uses a locally defined manifest to register
+ // the extra extension 'rules'
+ java.io.InputStream is=ManifestRegistryUtil.class.getResourceAsStream("MANIFEST.MF");
+
+ try {
+ org.scribble.extensions.ClasspathRegistry reg=
+ new org.scribble.extensions.ClasspathRegistry();
+
+ reg.initialize();
+
+ ManifestRegistryUtil.registerScribbleExtensions(reg, new java.util.jar.Manifest(is));
+
+ RegistryFactory.setRegistry(reg);
+
+ } catch(Exception e) {
+ e.printStackTrace();
+ }
+ }
+
+ public void testGenerate() {
+
+ // TODO: Write a 'Manifest' utility for registering rules
+ // into the registry - when working move into scribble core,
+ // but so that it is accessible to other plugins
+ ConversationModel model=new ConversationModel();
+
+ Role role=new Role();
+ role.setName("Broker");
+
+ ModelName modelName=new ModelName();
+ modelName.setLocatedRole(role);
+
+ Conversation conv=new Conversation();
+
+ conv.setModelName(modelName);
+
+ model.setConversation(conv);
+
+ ConversationInteraction interaction=new ConversationInteraction();
+
+ MessageSignature msig=new MessageSignature();
+ msig.setOperation("purchase");
+
+ TypeReference order=new TypeReference();
+ order.setLocalpart("Order");
+ msig.getTypes().add(order);
+
+ interaction.setMessageSignature(msig);
+
+ BPELLanguageModel bpelModel=getBPELLanguageModel(model);
+
+ org.w3c.dom.Element elem=bpelModel.getBPELProcess();
+
+ if (elem == null) {
+ fail("No BPEL process");
+ } else {
+
+ // TODO: Verify the BPEL process returned
+
+ }
+ }
+
+ protected BPELLanguageModel getBPELLanguageModel(ConversationModel model) {
+
+ if (model == null) {
+ fail("Model is null");
+ } else if (model.getModelName() == null) {
+ fail("Model Name is null");
+ } else if (model.getModelName().getLocatedRole() == null) {
+ fail("Model does not define a located role");
+ }
+
+ ModelReference targetRef=
+ new ModelReference(BPELLanguageModel.BPEL_NOTATION);
+
+ System.out.println("REG="+RegistryFactory.getRegistry());
+
+ DefaultBPELLanguageModel target=
+ new DefaultBPELLanguageModel(targetRef);
+
+ ModelGenerator generator=(ModelGenerator)
+ RegistryFactory.getRegistry().getExtension(
+ ModelGenerator.class, null);
+
+ if (generator != null) {
+ generator.generate(targetRef, model.getModelName().getLocatedRole(),
+ target, model);
+ } else {
+ fail("Could not get ModelGenerator");
+ }
+
+ return(target);
+ }
+}
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/generator/MANIFEST.MF
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/generator/MANIFEST.MF (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/generator/MANIFEST.MF 2009-02-07 20:41:26 UTC (rev 483)
@@ -0,0 +1,28 @@
+Manifest-Version: 1.0
+Bundle-ManifestVersion: 2
+Bundle-Name: Overlord CDL BPEL Plug-in
+Bundle-SymbolicName: org.jboss.tools.overlord.cdl.bpel;singleton:=true
+Bundle-Version: 1.0.0.qualifier
+Bundle-Activator: org.jboss.tools.overlord.cdl.bpel.eclipse.Activator
+Require-Bundle: org.eclipse.ui,
+ org.eclipse.core.runtime,
+ org.scribble.conversation.model,
+ org.scribble.core,
+ org.scribble.lang.model,
+ org.eclipse.core.resources,
+ org.scribble.osgi,
+ org.eclipse.jdt.core,
+ org.junit
+Bundle-ActivationPolicy: lazy
+Bundle-RequiredExecutionEnvironment: J2SE-1.5
+Bundle-Vendor: www.jboss.org
+Scribble-Extensions: org.jboss.tools.overlord.cdl.bpel.parser.BPELParser,
+ org.jboss.tools.overlord.cdl.bpel.parser.BPELNotation,
+ org.jboss.tools.overlord.cdl.bpel.model.change.LanguageToConversationModelChangeRule,
+ org.jboss.tools.overlord.cdl.bpel.model.change.ConversationModelChangeRule,
+ org.jboss.tools.overlord.cdl.bpel.model.change.WhileModelChangeRule,
+ org.jboss.tools.overlord.cdl.bpel.model.change.WhenModelChangeRule,
+ org.jboss.tools.overlord.cdl.bpel.model.change.IfModelChangeRule,
+ org.jboss.tools.overlord.cdl.bpel.model.change.RunModelChangeRule,
+ org.jboss.tools.overlord.cdl.bpel.model.change.SpawnModelChangeRule,
+ org.jboss.tools.overlord.cdl.bpel.model.change.ConversationInteractionModelChangeRule
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/generator/ManifestRegistryUtil.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/generator/ManifestRegistryUtil.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/test/org/jboss/tools/overlord/cdl/bpel/generator/ManifestRegistryUtil.java 2009-02-07 20:41:26 UTC (rev 483)
@@ -0,0 +1,40 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.generator;
+
+public class ManifestRegistryUtil {
+
+ public static void registerScribbleExtensions(org.scribble.extensions.AbstractRegistry registry,
+ java.util.jar.Manifest manifest) {
+
+ String str=manifest.getMainAttributes().getValue("Scribble-Extensions");
+
+ java.util.StringTokenizer st=new java.util.StringTokenizer(str, ", ");
+
+ while (st.hasMoreTokens()) {
+ String clsName=st.nextToken();
+
+ try {
+ Class<?> cls=Class.forName(clsName);
+ registry.addExtension(cls);
+ } catch(Exception e) {
+ e.printStackTrace();
+ }
+ }
+ }
+}
15 years, 2 months
Overlord SVN: r482 - in cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel: META-INF and 1 other directory.
by overlord-commits@lists.jboss.org
Author: objectiser
Date: 2009-02-07 15:40:48 -0500 (Sat, 07 Feb 2009)
New Revision: 482
Modified:
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/.classpath
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/META-INF/MANIFEST.MF
Log:
Added unit test
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/.classpath
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/.classpath 2009-02-07 00:16:30 UTC (rev 481)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/.classpath 2009-02-07 20:40:48 UTC (rev 482)
@@ -3,5 +3,6 @@
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src/java"/>
+ <classpathentry kind="src" path="src/test"/>
<classpathentry kind="output" path="bin"/>
</classpath>
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/META-INF/MANIFEST.MF
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/META-INF/MANIFEST.MF 2009-02-07 00:16:30 UTC (rev 481)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/META-INF/MANIFEST.MF 2009-02-07 20:40:48 UTC (rev 482)
@@ -11,7 +11,8 @@
org.scribble.lang.model,
org.eclipse.core.resources,
org.scribble.osgi,
- org.eclipse.jdt.core
+ org.eclipse.jdt.core,
+ org.junit
Bundle-ActivationPolicy: lazy
Bundle-RequiredExecutionEnvironment: J2SE-1.5
Bundle-Vendor: www.jboss.org
15 years, 2 months
Overlord SVN: r481 - in cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel: META-INF and 4 other directories.
by overlord-commits@lists.jboss.org
Author: objectiser
Date: 2009-02-06 19:16:30 -0500 (Fri, 06 Feb 2009)
New Revision: 481
Added:
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/BPELSequenceActivity.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/AbstractGroupingActivity.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/AbstractInteractionActivity.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/IfActivity.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/SequenceActivity.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/WhileActivity.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/ConversationModelChangeRule.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/IfModelChangeRule.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/RunModelChangeRule.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/SpawnModelChangeRule.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/WhenModelChangeRule.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/WhileModelChangeRule.java
Modified:
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/META-INF/MANIFEST.MF
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/plugin.xml
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/BPELActivity.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/BPELLanguageModel.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/DefaultBPELLanguageModel.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/InvokeActivity.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/ReceiveActivity.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/ReplyActivity.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/AbstractBPELModelChangeRule.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/ConversationInteractionModelChangeRule.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/util/InteractionUtil.java
Log:
Established basic structure for generation.
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/META-INF/MANIFEST.MF
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/META-INF/MANIFEST.MF 2009-02-06 19:12:16 UTC (rev 480)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/META-INF/MANIFEST.MF 2009-02-07 00:16:30 UTC (rev 481)
@@ -18,4 +18,10 @@
Scribble-Extensions: org.jboss.tools.overlord.cdl.bpel.parser.BPELParser,
org.jboss.tools.overlord.cdl.bpel.parser.BPELNotation,
org.jboss.tools.overlord.cdl.bpel.model.change.LanguageToConversationModelChangeRule,
+ org.jboss.tools.overlord.cdl.bpel.model.change.ConversationModelChangeRule,
+ org.jboss.tools.overlord.cdl.bpel.model.change.WhileModelChangeRule,
+ org.jboss.tools.overlord.cdl.bpel.model.change.WhenModelChangeRule,
+ org.jboss.tools.overlord.cdl.bpel.model.change.IfModelChangeRule,
+ org.jboss.tools.overlord.cdl.bpel.model.change.RunModelChangeRule,
+ org.jboss.tools.overlord.cdl.bpel.model.change.SpawnModelChangeRule,
org.jboss.tools.overlord.cdl.bpel.model.change.ConversationInteractionModelChangeRule
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/plugin.xml
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/plugin.xml 2009-02-06 19:12:16 UTC (rev 480)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/plugin.xml 2009-02-07 00:16:30 UTC (rev 481)
@@ -1,6 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.2"?>
<plugin>
+ <extension
+ id="org.jboss.tools.overlord.cdl.bpel.extension"
+ name="Overlord CDL BPEL model extension"
+ point="org.scribble.extension">
+ </extension>
+
<extension point="org.eclipse.ui.popupMenus">
<objectContribution
id="org.jboss.tools.overlord.cdl.bpel.object.contribution"
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/BPELActivity.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/BPELActivity.java 2009-02-06 19:12:16 UTC (rev 480)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/BPELActivity.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -19,4 +19,12 @@
public interface BPELActivity {
+ /**
+ * This method returns the XML configuration representation
+ * of the activity.
+ *
+ * @return The XML configuration for the activity
+ */
+ public org.w3c.dom.Element getActivity();
+
}
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/BPELLanguageModel.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/BPELLanguageModel.java 2009-02-06 19:12:16 UTC (rev 480)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/BPELLanguageModel.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -51,6 +51,13 @@
*/
public String getOriginalContents();
+ /**
+ * This method returns the top level grouping
+ * activity.
+ *
+ * @return The top level grouping activity
+ */
+ public BPELSequenceActivity getActivity();
/**
* This method returns the reference to the DOM
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/BPELSequenceActivity.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/BPELSequenceActivity.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/BPELSequenceActivity.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -0,0 +1,47 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.model;
+
+public interface BPELSequenceActivity extends BPELActivity {
+
+ /**
+ * This method adds an activity to the grouping construct.
+ *
+ * @param act The activity to be added
+ * @param pos The position to add, or -1 if at the end
+ */
+ public void addActivity(BPELActivity act, int pos);
+
+ /**
+ * This method removes an activity from the grouping
+ * construct.
+ *
+ * @param act The activity to be removed
+ * @return Whether the activity was removed
+ */
+ public boolean removeActivity(BPELActivity act);
+
+ /**
+ * This method returns the list of activities associated
+ * with the grouping construct.
+ *
+ * @return The list of activities
+ */
+ public java.util.List<BPELActivity> getActivities();
+
+}
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/DefaultBPELLanguageModel.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/DefaultBPELLanguageModel.java 2009-02-06 19:12:16 UTC (rev 480)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/DefaultBPELLanguageModel.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -140,6 +140,27 @@
}
/**
+ * This method returns the top level grouping
+ * activity.
+ *
+ * @return The top level grouping activity
+ */
+ public BPELSequenceActivity getActivity() {
+ return(m_activity);
+ }
+
+ /**
+ * This method sets the top level activity.
+ *
+ * @param act The top level activity
+ */
+ public void setActivity(BPELSequenceActivity act) {
+ m_activity = act;
+
+ m_bpelProcess.appendChild(act.getActivity());
+ }
+
+ /**
* This method returns the reference to the DOM
* representation of the BPEL process.
*
@@ -154,6 +175,7 @@
private ModelReference m_source=null;
private org.w3c.dom.Element m_bpelProcess=null;
private String m_contents=null;
+ private BPELSequenceActivity m_activity=null;
public class InnerModelListener implements ModelListener {
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/AbstractGroupingActivity.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/AbstractGroupingActivity.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/AbstractGroupingActivity.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -0,0 +1,71 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.model.activities;
+
+import java.util.logging.Logger;
+
+import org.jboss.tools.overlord.cdl.bpel.model.*;
+
+/**
+ * This is the generic BPEL activity class.
+ *
+ * @author gary
+ */
+public abstract class AbstractGroupingActivity extends AbstractBPELActivity {
+
+ /**
+ * The constructor for initializing the activity based on
+ * an existing DOM element.
+ */
+ protected AbstractGroupingActivity(BPELLanguageModel model,
+ org.w3c.dom.Element activity) {
+ super(model, activity);
+ }
+
+ /**
+ * The contructor for initializing a new activity.
+ */
+ protected AbstractGroupingActivity(BPELLanguageModel model,
+ String activityName) {
+ super(model, activityName);
+ }
+
+ /**
+ * This method sets the contained activity.
+ *
+ * @param act The contained activity
+ */
+ public void setContainedActivity(BPELActivity act) {
+ m_containedActivity = act;
+
+ getActivity().appendChild(act.getActivity());
+ }
+
+ /**
+ * This method returns the contained activity.
+ *
+ * @return The contained activity
+ */
+ public BPELActivity getContainedActivity() {
+ return(m_containedActivity);
+ }
+
+ private static Logger logger = Logger.getLogger("org.jboss.tools.overlord.cdl.bpel.model");
+
+ private BPELActivity m_containedActivity=null;
+}
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/AbstractInteractionActivity.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/AbstractInteractionActivity.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/AbstractInteractionActivity.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -0,0 +1,82 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.model.activities;
+
+import org.scribble.conversation.model.ConversationInteraction;
+import org.scribble.model.admin.ModelListener;
+import org.jboss.tools.overlord.cdl.bpel.model.*;
+
+/**
+ * This class represents an abstract interaction activity.
+ *
+ * @author gary
+ */
+public abstract class AbstractInteractionActivity extends AbstractBPELActivity {
+
+ private static final long serialVersionUID = -5048477859609625462L;
+
+ /**
+ * The constructor for the activity.
+ *
+ * @param model The BPEL model
+ * @param activity The XML configuration details for the activity
+ */
+ public AbstractInteractionActivity(BPELLanguageModel model,
+ org.w3c.dom.Element activity) {
+ super(model, activity);
+ }
+
+ /**
+ * The constructor for the activity.
+ *
+ * @param model The BPEL model
+ * @param interaction The conversation
+ */
+ public AbstractInteractionActivity(BPELLanguageModel model,
+ String name, ConversationInteraction interaction) {
+ super(model, name);
+
+ initialize(interaction);
+ }
+
+ /**
+ * This method initializes the invoke interaction.
+ *
+ * @param interaction The invoke interaction
+ */
+ protected void initialize(ConversationInteraction interaction) {
+
+ getActivity().setAttribute("operation",
+ interaction.getMessageSignature().getOperation());
+
+ // TODO: Record variables against relevant interaction
+ // based activity - probably only mechanism for
+ // establishing message type
+ }
+
+ /**
+ * This method validates the BPEL activity and reports warnings or
+ * errors to the supplied model listener.
+ *
+ * @param l The model listener
+ */
+ @Override
+ public void validate(ModelListener l) {
+ }
+
+}
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/IfActivity.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/IfActivity.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/IfActivity.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -0,0 +1,115 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.model.activities;
+
+import org.scribble.model.*;
+import org.scribble.model.admin.ModelListener;
+import org.jboss.tools.overlord.cdl.bpel.model.*;
+
+/**
+ * This class represents an 'if' grouping construct.
+ *
+ * @author gary
+ */
+public class IfActivity extends AbstractBPELActivity {
+
+ private static final long serialVersionUID = -763221632866464831L;
+ private static final String IF = "if";
+
+ /**
+ * The constructor for the activity.
+ *
+ * @param model The BPEL model
+ * @param activity The XML configuration details for the activity
+ */
+ public IfActivity(BPELLanguageModel model,
+ org.w3c.dom.Element activity) {
+ super(model, activity);
+ }
+
+ /**
+ * The constructor for the activity.
+ *
+ * @param model The BPEL model
+ */
+ public IfActivity(BPELLanguageModel model) {
+ super(model, IF);
+ }
+
+ /**
+ * This method validates the BPEL activity and reports warnings or
+ * errors to the supplied model listener.
+ *
+ * @param l The model listener
+ */
+ @Override
+ public void validate(ModelListener l) {
+ }
+
+ /**
+ * This method converts the BPEL activity into an equivalent
+ * behavioural description for conformance checking.
+ *
+ * @param activities The list of activities that will contain
+ * the converted action(s)
+ * @param context The conversion context
+ */
+ public void convert(java.util.List<Activity> activities,
+ ConversionContext context) {
+ }
+
+ public void setConditionPath(SequenceActivity act) {
+ m_conditionPath = act;
+ getActivity().appendChild(act.getActivity());
+ }
+
+ public SequenceActivity getConditionPath() {
+ return(m_conditionPath);
+ }
+
+ public void addElseIfPath(SequenceActivity act) {
+ m_elseIfPaths.add(act);
+
+ org.w3c.dom.Element elem=getActivity().getOwnerDocument().createElement("elseif");
+
+ getActivity().appendChild(elem);
+ elem.appendChild(act.getActivity());
+ }
+
+ public java.util.List<SequenceActivity> getElseIfPaths() {
+ return(m_elseIfPaths);
+ }
+
+ public void setElsePath(SequenceActivity act) {
+ m_elsePath = act;
+
+ org.w3c.dom.Element elem=getActivity().getOwnerDocument().createElement("else");
+
+ getActivity().appendChild(elem);
+ elem.appendChild(act.getActivity());
+ }
+
+ public SequenceActivity getElsePath() {
+ return(m_elsePath);
+ }
+
+ private SequenceActivity m_conditionPath=null;
+ private SequenceActivity m_elsePath=null;
+ private java.util.List<SequenceActivity> m_elseIfPaths=
+ new java.util.Vector<SequenceActivity>();
+}
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/InvokeActivity.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/InvokeActivity.java 2009-02-06 19:12:16 UTC (rev 480)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/InvokeActivity.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -17,29 +17,47 @@
*/
package org.jboss.tools.overlord.cdl.bpel.model.activities;
+import org.scribble.conversation.model.ConversationInteraction;
import org.scribble.model.*;
import org.scribble.model.admin.ModelListener;
import org.jboss.tools.overlord.cdl.bpel.model.*;
+
/**
* This class represents an unsupported (or custom) action within
* the conversation based ESB service descriptor.
*
* @author gary
*/
-public class InvokeActivity extends AbstractBPELActivity {
+public class InvokeActivity extends AbstractInteractionActivity {
+ private static final String INVOKE = "invoke";
+ private static final long serialVersionUID = 928076947383263387L;
+
/**
* The constructor for the activity.
*
* @param model The BPEL model
* @param activity The XML configuration details for the activity
*/
- public InvokeActivity(BPELLanguageModel model,
+ public InvokeActivity(BPELLanguageModel model,
org.w3c.dom.Element activity) {
super(model, activity);
}
/**
+ * The constructor for the activity.
+ *
+ * @param model The BPEL model
+ * @param interaction The conversation
+ */
+ public InvokeActivity(BPELLanguageModel model,
+ ConversationInteraction interaction) {
+ super(model, INVOKE, interaction);
+
+ initialize(interaction);
+ }
+
+ /**
* This method validates the BPEL activity and reports warnings or
* errors to the supplied model listener.
*
@@ -47,7 +65,6 @@
*/
@Override
public void validate(ModelListener l) {
- // Don't validate unsupported actions
}
/**
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/ReceiveActivity.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/ReceiveActivity.java 2009-02-06 19:12:16 UTC (rev 480)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/ReceiveActivity.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -17,6 +17,7 @@
*/
package org.jboss.tools.overlord.cdl.bpel.model.activities;
+import org.scribble.conversation.model.ConversationInteraction;
import org.scribble.model.*;
import org.scribble.model.admin.ModelListener;
import org.jboss.tools.overlord.cdl.bpel.model.*;
@@ -26,8 +27,11 @@
*
* @author gary
*/
-public class ReceiveActivity extends AbstractBPELActivity {
+public class ReceiveActivity extends AbstractInteractionActivity {
+ private static final String RECEIVE = "receive";
+ private static final long serialVersionUID = -3041725198724191842L;
+
/**
* The constructor for the activity.
*
@@ -40,6 +44,19 @@
}
/**
+ * The constructor for the activity.
+ *
+ * @param model The BPEL model
+ * @param interaction The conversation
+ */
+ public ReceiveActivity(BPELLanguageModel model,
+ ConversationInteraction interaction) {
+ super(model, RECEIVE, interaction);
+
+ initialize(interaction);
+ }
+
+ /**
* This method validates the BPEL activity and reports warnings or
* errors to the supplied model listener.
*
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/ReplyActivity.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/ReplyActivity.java 2009-02-06 19:12:16 UTC (rev 480)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/ReplyActivity.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -17,17 +17,21 @@
*/
package org.jboss.tools.overlord.cdl.bpel.model.activities;
+import org.scribble.conversation.model.ConversationInteraction;
import org.scribble.model.*;
import org.scribble.model.admin.ModelListener;
import org.jboss.tools.overlord.cdl.bpel.model.*;
+
/**
- * This class represents an unsupported (or custom) action within
- * the conversation based ESB service descriptor.
+ * This class represents a BPEL reply activity.
*
* @author gary
*/
-public class ReplyActivity extends AbstractBPELActivity {
+public class ReplyActivity extends AbstractInteractionActivity {
+ private static final String REPLY = "reply";
+ private static final long serialVersionUID = 8582738107125170604L;
+
/**
* The constructor for the activity.
*
@@ -40,6 +44,19 @@
}
/**
+ * The constructor for the activity.
+ *
+ * @param model The BPEL model
+ * @param interaction The conversation
+ */
+ public ReplyActivity(BPELLanguageModel model,
+ ConversationInteraction interaction) {
+ super(model, REPLY, interaction);
+
+ initialize(interaction);
+ }
+
+ /**
* This method validates the BPEL activity and reports warnings or
* errors to the supplied model listener.
*
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/SequenceActivity.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/SequenceActivity.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/SequenceActivity.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -0,0 +1,141 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.model.activities;
+
+import org.scribble.model.*;
+import org.scribble.model.admin.ModelListener;
+import org.jboss.tools.overlord.cdl.bpel.model.*;
+
+/**
+ * This class represents a sequence grouping activity.
+ *
+ * @author gary
+ */
+public class SequenceActivity extends AbstractBPELActivity
+ implements BPELSequenceActivity {
+
+ private static final String SEQUENCE = "sequence";
+ private static final long serialVersionUID = 6656299352423612770L;
+
+ /**
+ * The constructor for the activity.
+ *
+ * @param model The BPEL model
+ * @param activity The XML configuration details for the activity
+ */
+ public SequenceActivity(BPELLanguageModel model,
+ org.w3c.dom.Element activity) {
+ super(model, activity);
+ }
+
+ /**
+ * The constructor for the activity.
+ *
+ * @param model The BPEL model
+ */
+ public SequenceActivity(BPELLanguageModel model) {
+ super(model, SEQUENCE);
+ }
+
+ /**
+ * This method validates the BPEL activity and reports warnings or
+ * errors to the supplied model listener.
+ *
+ * @param l The model listener
+ */
+ @Override
+ public void validate(ModelListener l) {
+ }
+
+ /**
+ * This method converts the BPEL activity into an equivalent
+ * behavioural description for conformance checking.
+ *
+ * @param activities The list of activities that will contain
+ * the converted action(s)
+ * @param context The conversion context
+ */
+ public void convert(java.util.List<Activity> activities,
+ ConversionContext context) {
+ }
+
+ /**
+ * This method adds an activity to the grouping construct.
+ *
+ * @param act The activity to be added
+ * @param pos The position to add, or -1 if at the end
+ */
+ public void addActivity(BPELActivity act, int pos) {
+ if (pos == -1) {
+ m_activities.add(act);
+ getActivity().appendChild(act.getActivity());
+ } else {
+ m_activities.add(pos, act);
+
+ org.w3c.dom.NodeList nl=getActivity().getChildNodes();
+ org.w3c.dom.Element elem=null;
+ int cur=-1;
+
+ for (int i=0; i < nl.getLength(); i++) {
+ if (nl.item(i) instanceof org.w3c.dom.Element) {
+ cur++;
+
+ if (cur == pos) {
+ elem = (org.w3c.dom.Element)nl.item(i);
+ }
+ }
+ }
+
+ if (elem != null) {
+ getActivity().insertBefore(act.getActivity(), elem);
+ } else {
+ getActivity().appendChild(act.getActivity());
+ }
+ }
+ }
+
+ /**
+ * This method removes an activity from the grouping
+ * construct.
+ *
+ * @param act The activity to be removed
+ * @return Whether the activity was removed
+ */
+ public boolean removeActivity(BPELActivity act) {
+ boolean ret=m_activities.remove(act);
+
+ if (ret) {
+ getActivity().removeChild(act.getActivity());
+ }
+
+ return(ret);
+ }
+
+ /**
+ * This method returns the list of activities associated
+ * with the grouping construct.
+ *
+ * @return The list of activities
+ */
+ public java.util.List<BPELActivity> getActivities() {
+ return(m_activities);
+ }
+
+ private java.util.List<BPELActivity> m_activities=
+ new java.util.Vector<BPELActivity>();
+}
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/WhileActivity.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/WhileActivity.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/activities/WhileActivity.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -0,0 +1,76 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.model.activities;
+
+import org.scribble.model.*;
+import org.scribble.model.admin.ModelListener;
+import org.jboss.tools.overlord.cdl.bpel.model.*;
+
+/**
+ * This class represents a while grouping activity.
+ *
+ * @author gary
+ */
+public class WhileActivity extends AbstractGroupingActivity {
+
+ private static final long serialVersionUID = -4173984531470466407L;
+ private static final String WHILE = "while";
+
+ /**
+ * The constructor for the activity.
+ *
+ * @param model The BPEL model
+ * @param activity The XML configuration details for the activity
+ */
+ public WhileActivity(BPELLanguageModel model,
+ org.w3c.dom.Element activity) {
+ super(model, activity);
+ }
+
+ /**
+ * The constructor for the activity.
+ *
+ * @param model The BPEL model
+ */
+ public WhileActivity(BPELLanguageModel model) {
+ super(model, WHILE);
+ }
+
+ /**
+ * This method validates the BPEL activity and reports warnings or
+ * errors to the supplied model listener.
+ *
+ * @param l The model listener
+ */
+ @Override
+ public void validate(ModelListener l) {
+ }
+
+ /**
+ * This method converts the BPEL activity into an equivalent
+ * behavioural description for conformance checking.
+ *
+ * @param activities The list of activities that will contain
+ * the converted action(s)
+ * @param context The conversion context
+ */
+ public void convert(java.util.List<Activity> activities,
+ ConversionContext context) {
+ }
+
+}
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/AbstractBPELModelChangeRule.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/AbstractBPELModelChangeRule.java 2009-02-06 19:12:16 UTC (rev 480)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/AbstractBPELModelChangeRule.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -19,6 +19,7 @@
import org.scribble.model.*;
import org.scribble.model.change.*;
+import org.jboss.tools.overlord.cdl.bpel.model.*;
/**
* This is the abstract ESB model change rule.
@@ -41,6 +42,11 @@
Model model, ModelObject mobj, ModelObject ref) {
boolean ret=false;
+ if (context.getParent() instanceof BPELSequenceActivity &&
+ model instanceof BPELLanguageModel) {
+ ret = true;
+ }
+
return(ret);
}
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/ConversationInteractionModelChangeRule.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/ConversationInteractionModelChangeRule.java 2009-02-06 19:12:16 UTC (rev 480)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/ConversationInteractionModelChangeRule.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -88,31 +88,53 @@
Model model, ModelObject mobj, ModelObject ref) {
BPELLanguageModel bpelModel=(BPELLanguageModel)model;
ConversationInteraction interaction=(ConversationInteraction)mobj;
+ boolean ret=false;
// Check if send or receive
if (InteractionUtil.isSend(interaction)) {
- // Send
- insertSend(context, bpelModel, interaction, ref);
-
+ if (InteractionUtil.isRequest(interaction)) {
+ InvokeActivity act=new InvokeActivity(bpelModel,
+ interaction);
+
+ if (context.getParent() instanceof BPELSequenceActivity) {
+ ((BPELSequenceActivity)context.getParent()).addActivity(act, -1);
+
+ ret = true;
+ }
+
+ // TODO: Need to deal with subsequent responses
+ // which could be in a following choice - with each
+ // choice path being a normal or fault response.
+ // The faults need to be encoded in a fault handler
+ // possibly wrapped around, or contained within the
+ // invoke.
+ } else {
+ ReplyActivity act=new ReplyActivity(bpelModel,
+ interaction);
+
+ if (context.getParent() instanceof BPELSequenceActivity) {
+ ((BPELSequenceActivity)context.getParent()).addActivity(act, -1);
+
+ ret = true;
+ }
+ }
} else {
- // Receive
- insertReceive(context, bpelModel, interaction, ref);
+ if (InteractionUtil.isRequest(interaction)) {
+ ReceiveActivity act=new ReceiveActivity(bpelModel,
+ interaction);
+
+ if (context.getParent() instanceof BPELSequenceActivity) {
+ ((BPELSequenceActivity)context.getParent()).addActivity(act, -1);
+
+ ret = true;
+ }
+ }
}
- return(true);
+ return(ret);
}
- protected void insertSend(ModelChangeContext context,
- BPELLanguageModel bpelModel, ConversationInteraction interaction,
- ModelObject ref) {
- }
-
- protected void insertReceive(ModelChangeContext context,
- BPELLanguageModel bpelModel, ConversationInteraction interaction,
- ModelObject ref) {
- }
-
/**
* This method determines whether the rule is appropriate
* for the supplied type of model, parent (in the context)
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/ConversationModelChangeRule.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/ConversationModelChangeRule.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/ConversationModelChangeRule.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -0,0 +1,124 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.model.change;
+
+import org.jboss.tools.overlord.cdl.bpel.model.*;
+import org.jboss.tools.overlord.cdl.bpel.model.activities.*;
+import org.scribble.model.*;
+import org.scribble.model.change.*;
+import org.scribble.conversation.model.*;
+import org.scribble.extensions.RegistryInfo;
+
+/**
+ * This is the model change rule for the Conversation.
+ */
+(a)RegistryInfo(extension=ModelChangeRule.class,notation=BPELLanguageModel.BPEL_NOTATION)
+public class ConversationModelChangeRule extends AbstractModelChangeRule {
+
+ private static final String NAME_SUFFIX = "_main";
+
+ /**
+ * This method determines whether the rule is appropriate
+ * for the supplied type of model, parent (in the context) and
+ * model object.
+ *
+ * @param context The context
+ * @param model The model
+ * @param mobj The model object causing the change
+ * @param ref The optional reference model object
+ * @return Whether the rule supports the supplied information
+ */
+ @Override
+ public boolean isInsertSupported(ModelChangeContext context,
+ Model model, ModelObject mobj, ModelObject ref) {
+ boolean ret=false;
+
+ if (mobj instanceof Conversation &&
+ model instanceof DefaultBPELLanguageModel) {
+ ret = true;
+ }
+
+ return(ret);
+ }
+
+ /**
+ * This method adds a new model object, within a
+ * parent model object, with the details supplied in
+ * another model object. The supplied model object
+ * will usually be from a different model representation
+ * (e.g. due to a merge), so the details will be
+ * copied and placed in the representation associated
+ * with the supplied model and parent model object.<p>
+ * <p>
+ * If a reference model object is supplied, then the
+ * insertion will occur relative to it. If the reference
+ * object is a block, then it means that the insertion
+ * should occur at the end of the block. Otherwise the
+ * new model object should be inserted before the
+ * reference object, within the containing block.<p>
+ * <p>
+ * If the reference object is not supplied, then the
+ * new model object should be inserted at the end of
+ * the behaviour associated with the parent in the model
+ * change context.
+ *
+ * @param context The context
+ * @param model The model being changed
+ * @param mobj The model object details to be inserted
+ * @param ref The optional reference model object
+ * @return Whether the change has been applied
+ */
+ @Override
+ public boolean insert(ModelChangeContext context,
+ Model model, ModelObject mobj, ModelObject ref) {
+ DefaultBPELLanguageModel bpelModel=(DefaultBPELLanguageModel)model;
+ Conversation conv=(Conversation)mobj;
+
+ SequenceActivity seq=new SequenceActivity(bpelModel);
+
+ // Check if root conversation
+ if (conv.getParent() instanceof Model) {
+
+ // Add sequence to model
+ bpelModel.setActivity(seq);
+
+ } else if (context.getParent() instanceof BPELSequenceActivity) {
+
+ ((BPELSequenceActivity)context.getParent()).addActivity(seq, -1);
+ }
+
+ // Process the activities within the conversation
+ java.util.List<Activity> acts=conv.getBlock().getContents();
+
+ Object parent=context.getParent();
+
+ context.setParent(seq);
+
+ for (int i=0; i < acts.size(); i++) {
+ if ((acts.get(i) instanceof Definition) == false) {
+ context.insert(model, acts.get(i), null);
+ }
+ }
+
+ // Reset old parent
+ context.setParent(parent);
+
+ return(true);
+ }
+
+}
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/IfModelChangeRule.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/IfModelChangeRule.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/IfModelChangeRule.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -0,0 +1,126 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.model.change;
+
+import org.jboss.tools.overlord.cdl.bpel.model.*;
+import org.jboss.tools.overlord.cdl.bpel.model.activities.*;
+import org.scribble.model.*;
+import org.scribble.model.change.*;
+import org.scribble.conversation.model.*;
+import org.scribble.extensions.RegistryInfo;
+
+/**
+ * This is the model change rule for the If.
+ */
+(a)RegistryInfo(extension=ModelChangeRule.class,notation=BPELLanguageModel.BPEL_NOTATION)
+public class IfModelChangeRule extends AbstractModelChangeRule {
+
+ /**
+ * This method determines whether the rule is appropriate
+ * for the supplied type of model, parent (in the context) and
+ * model object.
+ *
+ * @param context The context
+ * @param model The model
+ * @param mobj The model object causing the change
+ * @param ref The optional reference model object
+ * @return Whether the rule supports the supplied information
+ */
+ @Override
+ public boolean isInsertSupported(ModelChangeContext context,
+ Model model, ModelObject mobj, ModelObject ref) {
+ boolean ret=false;
+
+ if (mobj instanceof If &&
+ model instanceof DefaultBPELLanguageModel) {
+ ret = true;
+ }
+
+ return(ret);
+ }
+
+ /**
+ * This method adds a new model object, within a
+ * parent model object, with the details supplied in
+ * another model object. The supplied model object
+ * will usually be from a different model representation
+ * (e.g. due to a merge), so the details will be
+ * copied and placed in the representation associated
+ * with the supplied model and parent model object.<p>
+ * <p>
+ * If a reference model object is supplied, then the
+ * insertion will occur relative to it. If the reference
+ * object is a block, then it means that the insertion
+ * should occur at the end of the block. Otherwise the
+ * new model object should be inserted before the
+ * reference object, within the containing block.<p>
+ * <p>
+ * If the reference object is not supplied, then the
+ * new model object should be inserted at the end of
+ * the behaviour associated with the parent in the model
+ * change context.
+ *
+ * @param context The context
+ * @param model The model being changed
+ * @param mobj The model object details to be inserted
+ * @param ref The optional reference model object
+ * @return Whether the change has been applied
+ */
+ @Override
+ public boolean insert(ModelChangeContext context,
+ Model model, ModelObject mobj, ModelObject ref) {
+ DefaultBPELLanguageModel bpelModel=(DefaultBPELLanguageModel)model;
+ If elem=(If)mobj;
+
+ IfActivity act=new IfActivity(bpelModel);
+
+ if (context.getParent() instanceof SequenceActivity) {
+ ((SequenceActivity)context.getParent()).addActivity(act, -1);
+ }
+
+ for (int i=0; i < elem.getPaths().size(); i++) {
+ Block path=elem.getPaths().get(i);
+
+ SequenceActivity seq=new SequenceActivity(bpelModel);
+
+ if (i == 0) {
+ act.setConditionPath(seq);
+ } else if (i == elem.getPaths().size()-1) {
+ act.setElsePath(seq);
+ } else {
+ act.addElseIfPath(seq);
+ }
+
+ // Process the activities within the conversation
+ java.util.List<Activity> acts=path.getContents();
+
+ Object parent=context.getParent();
+
+ context.setParent(seq);
+
+ for (int j=0; j < acts.size(); j++) {
+ context.insert(model, acts.get(j), null);
+ }
+
+ context.setParent(parent);
+ }
+
+ return(true);
+ }
+
+}
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/RunModelChangeRule.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/RunModelChangeRule.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/RunModelChangeRule.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -0,0 +1,97 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.model.change;
+
+import org.jboss.tools.overlord.cdl.bpel.model.*;
+import org.jboss.tools.overlord.cdl.bpel.model.activities.*;
+import org.scribble.model.*;
+import org.scribble.model.change.*;
+import org.scribble.conversation.model.*;
+import org.scribble.extensions.RegistryInfo;
+
+/**
+ * This is the model change rule for the Run.
+ */
+(a)RegistryInfo(extension=ModelChangeRule.class,notation=BPELLanguageModel.BPEL_NOTATION)
+public class RunModelChangeRule extends AbstractModelChangeRule {
+
+ /**
+ * This method determines whether the rule is appropriate
+ * for the supplied type of model, parent (in the context) and
+ * model object.
+ *
+ * @param context The context
+ * @param model The model
+ * @param mobj The model object causing the change
+ * @param ref The optional reference model object
+ * @return Whether the rule supports the supplied information
+ */
+ @Override
+ public boolean isInsertSupported(ModelChangeContext context,
+ Model model, ModelObject mobj, ModelObject ref) {
+ boolean ret=false;
+
+ if (mobj instanceof Run &&
+ model instanceof DefaultBPELLanguageModel) {
+ ret = true;
+ }
+
+ return(ret);
+ }
+
+ /**
+ * This method adds a new model object, within a
+ * parent model object, with the details supplied in
+ * another model object. The supplied model object
+ * will usually be from a different model representation
+ * (e.g. due to a merge), so the details will be
+ * copied and placed in the representation associated
+ * with the supplied model and parent model object.<p>
+ * <p>
+ * If a reference model object is supplied, then the
+ * insertion will occur relative to it. If the reference
+ * object is a block, then it means that the insertion
+ * should occur at the end of the block. Otherwise the
+ * new model object should be inserted before the
+ * reference object, within the containing block.<p>
+ * <p>
+ * If the reference object is not supplied, then the
+ * new model object should be inserted at the end of
+ * the behaviour associated with the parent in the model
+ * change context.
+ *
+ * @param context The context
+ * @param model The model being changed
+ * @param mobj The model object details to be inserted
+ * @param ref The optional reference model object
+ * @return Whether the change has been applied
+ */
+ @Override
+ public boolean insert(ModelChangeContext context,
+ Model model, ModelObject mobj, ModelObject ref) {
+ DefaultBPELLanguageModel bpelModel=(DefaultBPELLanguageModel)model;
+ Run elem=(Run)mobj;
+
+ if (elem.getDefinition() != null) {
+ context.insert(bpelModel, elem.getDefinition(), ref);
+ }
+
+ return(true);
+ }
+
+}
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/SpawnModelChangeRule.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/SpawnModelChangeRule.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/SpawnModelChangeRule.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -0,0 +1,97 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.model.change;
+
+import org.jboss.tools.overlord.cdl.bpel.model.*;
+import org.jboss.tools.overlord.cdl.bpel.model.activities.*;
+import org.scribble.model.*;
+import org.scribble.model.change.*;
+import org.scribble.conversation.model.*;
+import org.scribble.extensions.RegistryInfo;
+
+/**
+ * This is the model change rule for the Run.
+ */
+(a)RegistryInfo(extension=ModelChangeRule.class,notation=BPELLanguageModel.BPEL_NOTATION)
+public class SpawnModelChangeRule extends AbstractModelChangeRule {
+
+ /**
+ * This method determines whether the rule is appropriate
+ * for the supplied type of model, parent (in the context) and
+ * model object.
+ *
+ * @param context The context
+ * @param model The model
+ * @param mobj The model object causing the change
+ * @param ref The optional reference model object
+ * @return Whether the rule supports the supplied information
+ */
+ @Override
+ public boolean isInsertSupported(ModelChangeContext context,
+ Model model, ModelObject mobj, ModelObject ref) {
+ boolean ret=false;
+
+ if (mobj instanceof Spawn &&
+ model instanceof DefaultBPELLanguageModel) {
+ ret = true;
+ }
+
+ return(ret);
+ }
+
+ /**
+ * This method adds a new model object, within a
+ * parent model object, with the details supplied in
+ * another model object. The supplied model object
+ * will usually be from a different model representation
+ * (e.g. due to a merge), so the details will be
+ * copied and placed in the representation associated
+ * with the supplied model and parent model object.<p>
+ * <p>
+ * If a reference model object is supplied, then the
+ * insertion will occur relative to it. If the reference
+ * object is a block, then it means that the insertion
+ * should occur at the end of the block. Otherwise the
+ * new model object should be inserted before the
+ * reference object, within the containing block.<p>
+ * <p>
+ * If the reference object is not supplied, then the
+ * new model object should be inserted at the end of
+ * the behaviour associated with the parent in the model
+ * change context.
+ *
+ * @param context The context
+ * @param model The model being changed
+ * @param mobj The model object details to be inserted
+ * @param ref The optional reference model object
+ * @return Whether the change has been applied
+ */
+ @Override
+ public boolean insert(ModelChangeContext context,
+ Model model, ModelObject mobj, ModelObject ref) {
+ DefaultBPELLanguageModel bpelModel=(DefaultBPELLanguageModel)model;
+ Spawn elem=(Spawn)mobj;
+
+ if (elem.getDefinition() != null) {
+ context.insert(bpelModel, elem.getDefinition(), ref);
+ }
+
+ return(true);
+ }
+
+}
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/WhenModelChangeRule.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/WhenModelChangeRule.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/WhenModelChangeRule.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -0,0 +1,108 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.model.change;
+
+import org.jboss.tools.overlord.cdl.bpel.model.*;
+import org.jboss.tools.overlord.cdl.bpel.model.activities.*;
+import org.scribble.model.*;
+import org.scribble.model.change.*;
+import org.scribble.conversation.model.*;
+import org.scribble.extensions.RegistryInfo;
+
+/**
+ * This is the model change rule for the When.
+ */
+(a)RegistryInfo(extension=ModelChangeRule.class,notation=BPELLanguageModel.BPEL_NOTATION)
+public class WhenModelChangeRule extends AbstractModelChangeRule {
+
+ /**
+ * This method determines whether the rule is appropriate
+ * for the supplied type of model, parent (in the context) and
+ * model object.
+ *
+ * @param context The context
+ * @param model The model
+ * @param mobj The model object causing the change
+ * @param ref The optional reference model object
+ * @return Whether the rule supports the supplied information
+ */
+ @Override
+ public boolean isInsertSupported(ModelChangeContext context,
+ Model model, ModelObject mobj, ModelObject ref) {
+ boolean ret=false;
+
+ if (mobj instanceof When &&
+ model instanceof DefaultBPELLanguageModel) {
+ ret = true;
+ }
+
+ return(ret);
+ }
+
+ /**
+ * This method adds a new model object, within a
+ * parent model object, with the details supplied in
+ * another model object. The supplied model object
+ * will usually be from a different model representation
+ * (e.g. due to a merge), so the details will be
+ * copied and placed in the representation associated
+ * with the supplied model and parent model object.<p>
+ * <p>
+ * If a reference model object is supplied, then the
+ * insertion will occur relative to it. If the reference
+ * object is a block, then it means that the insertion
+ * should occur at the end of the block. Otherwise the
+ * new model object should be inserted before the
+ * reference object, within the containing block.<p>
+ * <p>
+ * If the reference object is not supplied, then the
+ * new model object should be inserted at the end of
+ * the behaviour associated with the parent in the model
+ * change context.
+ *
+ * @param context The context
+ * @param model The model being changed
+ * @param mobj The model object details to be inserted
+ * @param ref The optional reference model object
+ * @return Whether the change has been applied
+ */
+ @Override
+ public boolean insert(ModelChangeContext context,
+ Model model, ModelObject mobj, ModelObject ref) {
+ DefaultBPELLanguageModel bpelModel=(DefaultBPELLanguageModel)model;
+ When elem=(When)mobj;
+
+ // TODO: Need to decide best way to deal with single
+ // and multi-path when constructs.
+
+ if (elem.getPaths().size() == 1) {
+ // Single path - so ignore it for now
+ Block path=elem.getPaths().get(0);
+
+ // Process the activities within the conversation
+ java.util.List<Activity> acts=path.getContents();
+
+ for (int i=0; i < acts.size(); i++) {
+ context.insert(model, acts.get(i), null);
+ }
+ }
+
+ return(true);
+ }
+
+}
Added: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/WhileModelChangeRule.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/WhileModelChangeRule.java (rev 0)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/change/WhileModelChangeRule.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -0,0 +1,116 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.tools.overlord.cdl.bpel.model.change;
+
+import org.jboss.tools.overlord.cdl.bpel.model.*;
+import org.jboss.tools.overlord.cdl.bpel.model.activities.*;
+import org.scribble.model.*;
+import org.scribble.model.change.*;
+import org.scribble.conversation.model.*;
+import org.scribble.extensions.RegistryInfo;
+
+/**
+ * This is the model change rule for the While.
+ */
+(a)RegistryInfo(extension=ModelChangeRule.class,notation=BPELLanguageModel.BPEL_NOTATION)
+public class WhileModelChangeRule extends AbstractModelChangeRule {
+
+ /**
+ * This method determines whether the rule is appropriate
+ * for the supplied type of model, parent (in the context) and
+ * model object.
+ *
+ * @param context The context
+ * @param model The model
+ * @param mobj The model object causing the change
+ * @param ref The optional reference model object
+ * @return Whether the rule supports the supplied information
+ */
+ @Override
+ public boolean isInsertSupported(ModelChangeContext context,
+ Model model, ModelObject mobj, ModelObject ref) {
+ boolean ret=false;
+
+ if (mobj instanceof While &&
+ model instanceof DefaultBPELLanguageModel) {
+ ret = true;
+ }
+
+ return(ret);
+ }
+
+ /**
+ * This method adds a new model object, within a
+ * parent model object, with the details supplied in
+ * another model object. The supplied model object
+ * will usually be from a different model representation
+ * (e.g. due to a merge), so the details will be
+ * copied and placed in the representation associated
+ * with the supplied model and parent model object.<p>
+ * <p>
+ * If a reference model object is supplied, then the
+ * insertion will occur relative to it. If the reference
+ * object is a block, then it means that the insertion
+ * should occur at the end of the block. Otherwise the
+ * new model object should be inserted before the
+ * reference object, within the containing block.<p>
+ * <p>
+ * If the reference object is not supplied, then the
+ * new model object should be inserted at the end of
+ * the behaviour associated with the parent in the model
+ * change context.
+ *
+ * @param context The context
+ * @param model The model being changed
+ * @param mobj The model object details to be inserted
+ * @param ref The optional reference model object
+ * @return Whether the change has been applied
+ */
+ @Override
+ public boolean insert(ModelChangeContext context,
+ Model model, ModelObject mobj, ModelObject ref) {
+ DefaultBPELLanguageModel bpelModel=(DefaultBPELLanguageModel)model;
+ While elem=(While)mobj;
+
+ WhileActivity act=new WhileActivity(bpelModel);
+
+ SequenceActivity seq=new SequenceActivity(bpelModel);
+ act.setContainedActivity(seq);
+
+ if (context.getParent() instanceof BPELSequenceActivity) {
+ ((BPELSequenceActivity)context.getParent()).addActivity(act, -1);
+ }
+
+ // Process the activities within the conversation
+ java.util.List<Activity> acts=elem.getBlock().getContents();
+
+ Object parent=context.getParent();
+
+ context.setParent(seq);
+
+ for (int i=0; i < acts.size(); i++) {
+ context.insert(model, acts.get(i), null);
+ }
+
+ // Reset old parent
+ context.setParent(parent);
+
+ return(true);
+ }
+
+}
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/util/InteractionUtil.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/util/InteractionUtil.java 2009-02-06 19:12:16 UTC (rev 480)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/model/util/InteractionUtil.java 2009-02-07 00:16:30 UTC (rev 481)
@@ -52,4 +52,22 @@
return(ret);
}
+ /**
+ * This method determines whether the supplied interaction
+ * is a request.
+ *
+ * @param interaction The interaction
+ * @return Whether the interaction is a request
+ */
+ public static boolean isRequest(Interaction interaction) {
+ boolean ret=false;
+
+ if (interaction.getRequestLabel() != null ||
+ interaction.getReplyToLabel() == null) {
+ ret = true;
+ }
+
+ return(ret);
+ }
+
}
15 years, 2 months
Overlord SVN: r480 - cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator.
by overlord-commits@lists.jboss.org
Author: objectiser
Date: 2009-02-06 14:12:16 -0500 (Fri, 06 Feb 2009)
New Revision: 480
Removed:
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/ConversationBasedGenerator.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/ModelBasedGenerator.java
Modified:
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/AntBuildSystem.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/BuildSystem.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/Generator.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/MavenBuildSystem.java
Log:
Changes to remove aspects copied from jbossesb action generation, to make more appropriate for bpel.
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/AntBuildSystem.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/AntBuildSystem.java 2009-02-06 12:18:23 UTC (rev 479)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/AntBuildSystem.java 2009-02-06 19:12:16 UTC (rev 480)
@@ -24,11 +24,7 @@
private static final String BUILD_FILE = "build.xml";
private static final String ANT = "Ant";
- private static final String ESB_CONFIG_PATH = "src/conf/jboss-esb.xml";
- private static final String DEPLOYMENT_PATH = "src/conf/deployment.xml";
- private static final String JBMQ_CONFIG_PATH = "src/conf/jbmq-queue-service.xml";
- private static final String JAVA_SOURCE_PATH = "src/java";
- private static final String LIBRARY_PATH = "src/lib";
+ private static final String BPEL_PATH = "bpel";
/**
* This method represents the name of the build
@@ -51,51 +47,13 @@
}
/**
- * This method returns the ESB configuration file
+ * This method returns the BPEL file
* path.
*
- * @return The ESB configuration file path
+ * @return The BPEL file path
*/
- public String getESBConfigFilePath() {
- return(ESB_CONFIG_PATH);
+ public String getBPELFilePath() {
+ return(BPEL_PATH);
}
- /**
- * This method returns the deployment file
- * path.
- *
- * @return The deployment file path
- */
- public String getDeploymentFilePath() {
- return(DEPLOYMENT_PATH);
- }
-
- /**
- * This method returns the JBMQ configuration file
- * path.
- *
- * @return The JBMQ configuration file path
- */
- public String getJBMQConfigFilePath() {
- return(JBMQ_CONFIG_PATH);
- }
-
- /**
- * This method returns the Java source path.
- *
- * @return The Java source path
- */
- public String getJavaSourcePath() {
- return(JAVA_SOURCE_PATH);
- }
-
- /**
- * This method returns the library path.
- *
- * @return The library path
- */
- public String getLibraryPath() {
- return(LIBRARY_PATH);
- }
-
}
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/BuildSystem.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/BuildSystem.java 2009-02-06 12:18:23 UTC (rev 479)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/BuildSystem.java 2009-02-06 19:12:16 UTC (rev 480)
@@ -49,41 +49,10 @@
public String getBuildFileContents(String projectName);
/**
- * This method returns the ESB configuration file
- * path.
+ * This method returns the BPEL file path.
*
- * @return The ESB configuration file path
+ * @return The BPEL file path
*/
- public String getESBConfigFilePath();
-
- /**
- * This method returns the deployment file
- * path.
- *
- * @return The deployment file path
- */
- public String getDeploymentFilePath();
-
- /**
- * This method returns the JBMQ configuration file
- * path.
- *
- * @return The JBMQ configuration file path
- */
- public String getJBMQConfigFilePath();
-
- /**
- * This method returns the Java source path.
- *
- * @return The Java source path
- */
- public String getJavaSourcePath();
-
- /**
- * This method returns the library path.
- *
- * @return The library path, or null if not required
- */
- public String getLibraryPath();
-
+ public String getBPELFilePath();
+
}
Deleted: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/ConversationBasedGenerator.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/ConversationBasedGenerator.java 2009-02-06 12:18:23 UTC (rev 479)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/ConversationBasedGenerator.java 2009-02-06 19:12:16 UTC (rev 480)
@@ -1,42 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
- * by the @authors tag. All rights reserved.
- * See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU Lesser General Public License, v. 2.1.
- * This program is distributed in the hope that it will be useful, but WITHOUT A
- * 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,
- * v.2.1 along with this distribution; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- */
-package org.jboss.tools.overlord.cdl.bpel.generator;
-
-import org.eclipse.jdt.core.IJavaProject;
-import org.scribble.conversation.model.Conversation;
-
-/**
- * This interface represents a module that generates artefacts
- * based on a specific conversation.
- */
-public interface ConversationBasedGenerator {
-
- /**
- * This method generates the relevant artefacts based on
- * the supplied conversation, within the specified Java project.
- *
- * @param jproj The Java project
- * @param conversation The conversation
- * @param buildSystem The build system to use
- * @throws GeneratorException Failed to generate
- */
- public void generate(IJavaProject jproj,
- Conversation conversation, BuildSystem buildSystem)
- throws GeneratorException;
-
-}
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/Generator.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/Generator.java 2009-02-06 12:18:23 UTC (rev 479)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/Generator.java 2009-02-06 19:12:16 UTC (rev 480)
@@ -46,9 +46,6 @@
*/
public class Generator {
- private static final String CLASSPATH_FILENAME = ".classpath";
- private static final String OUTPUT_LOCATION = "classes";
-
/**
* This is the constructor for the generator.
*
@@ -68,13 +65,6 @@
*/
protected void initialize(IFile res) {
- // Initialize the artefact generators
- //m_conversationBasedGen.add(new BusinessObjectTypeGenerator());
-
- //m_modelBasedGen.add(new BuildConfigurationGenerator());
- //m_modelBasedGen.add(new JBMQConfigurationGenerator());
- //m_modelBasedGen.add(new DeploymentFileGenerator());
-
// Initialize the model
ModelReference ref=
org.scribble.osgi.model.admin.OSGIModelRepository.createReference(res);
@@ -170,144 +160,44 @@
}
protected void generateRoleProject(String projectName,
- org.w3c.dom.Element esbConfig, ConversationModel localcm,
+ org.w3c.dom.Element bpel, ConversationModel localcm,
BPELLanguageModel model) throws Exception {
- final IJavaProject jproj=createJavaProject(projectName);
+ final IProject proj=createProject(projectName);
- if (jproj != null && esbConfig != null) {
- // Generate business object types for
- // local conversation model
- localcm.visit(new Visitor() {
+ if (proj != null && bpel != null) {
- public boolean visit(ModelObject obj) {
-
- if (obj instanceof Conversation) {
- for (int i=0; i < m_conversationBasedGen.size(); i++) {
- try {
- m_conversationBasedGen.get(i).generate(jproj,
- (Conversation)obj, getBuildSystem());
- } catch(GeneratorException e) {
- logger.log(java.util.logging.Level.SEVERE,
- "Failed to generate conversation based artefact",
- e);
- }
- }
- }
-
- return true;
- }
- });
+ // Store BPEL configuration
+ IPath bpelPath=proj.getFullPath().append(
+ new Path(getBuildSystem().getBPELFilePath())).
+ append(localcm.getModelName().getName()+"_"+
+ localcm.getModelName().getLocatedRole().getName()+".bpel");
- // Store ESB configuration
- IPath esbConfigPath=jproj.getPath().append(
- new Path(getBuildSystem().getESBConfigFilePath()));
-
- IFile esbConfigFile=jproj.getProject().getWorkspace().getRoot().getFile(esbConfigPath);
- GeneratorUtil.createParentFolder(esbConfigFile);
- esbConfigFile.create(null, true,
+ IFile bpelFile=proj.getProject().getWorkspace().getRoot().getFile(bpelPath);
+ GeneratorUtil.createParentFolder(bpelFile);
+ bpelFile.create(null, true,
new org.eclipse.core.runtime.NullProgressMonitor());
- String config=getText(esbConfig);
+ String bpelText=getText(bpel);
- if (config != null) {
- esbConfigFile.setContents(new java.io.ByteArrayInputStream(
- config.getBytes()), true, false,
+ if (bpelText != null) {
+ bpelFile.setContents(new java.io.ByteArrayInputStream(
+ bpelText.getBytes()), true, false,
new org.eclipse.core.runtime.NullProgressMonitor());
}
-
- for (int i=0; i < m_modelBasedGen.size(); i++) {
- try {
- m_modelBasedGen.get(i).generate(jproj, model,
- getBuildSystem());
- } catch(GeneratorException e) {
- logger.log(java.util.logging.Level.SEVERE,
- "Failed to generate model based artefact",
- e);
- }
- }
}
}
- protected IJavaProject createJavaProject(String projectName)
+ protected IProject createProject(String projectName)
throws Exception {
// Create project
IProject project=m_file.getWorkspace().getRoot().getProject(projectName);
project.create(new org.eclipse.core.runtime.NullProgressMonitor());
- IJavaProject jproj=JavaCore.create(project);
-
project.open(new org.eclipse.core.runtime.NullProgressMonitor());
- IProjectDescription description = jproj.getProject().getDescription();
-
- // Update the project natures to include Java Nature
- String[] prevNatures= description.getNatureIds();
- String[] newNatures= new String[prevNatures.length + 1];
- System.arraycopy(prevNatures, 0, newNatures, 0, prevNatures.length);
- newNatures[prevNatures.length]= JavaCore.NATURE_ID;
- description.setNatureIds(newNatures);
-
- // Setup project reference to CDM project
- IProject[] prevProjects=description.getReferencedProjects();
- IProject[] newProjects=new IProject[prevProjects.length+1];
- System.arraycopy(prevProjects, 0, newProjects, 0, prevProjects.length);
- newProjects[prevProjects.length] = m_file.getProject();
- description.setReferencedProjects(newProjects);
-
- // Set the description
- jproj.getProject().setDescription(description,
- new org.eclipse.core.runtime.NullProgressMonitor());
-
- IPath outputLocation=jproj.getPath().append(new Path(OUTPUT_LOCATION));
- IPath classpathLocation=jproj.getPath().append(new Path(CLASSPATH_FILENAME));
- IPath sourceLocation=jproj.getPath().append(
- new Path(getBuildSystem().getJavaSourcePath()));
- IPath libLocation=null;
-
- if (getBuildSystem().getLibraryPath() != null) {
- libLocation=jproj.getPath().append(new Path(getBuildSystem().getLibraryPath()));
- }
-
- // create and set the output and source paths first
- IFolder outputFolder= jproj.getProject().getWorkspace().getRoot().getFolder(outputLocation);
- GeneratorUtil.createParentFolder(outputFolder);
- outputFolder.create(true, true, new org.eclipse.core.runtime.NullProgressMonitor());
- outputFolder.setDerived(true);
-
- IFolder sourceFolder= jproj.getProject().getWorkspace().getRoot().getFolder(sourceLocation);
- GeneratorUtil.createParentFolder(sourceFolder);
- sourceFolder.create(true, true, new org.eclipse.core.runtime.NullProgressMonitor());
- sourceFolder.setDerived(true);
-
- if (libLocation != null) {
- IFolder libFolder= jproj.getProject().getWorkspace().getRoot().getFolder(libLocation);
- GeneratorUtil.createParentFolder(libFolder);
- libFolder.create(true, true, new org.eclipse.core.runtime.NullProgressMonitor());
- libFolder.setDerived(true);
- }
-
- IFile file=jproj.getProject().getWorkspace().getRoot().getFile(classpathLocation);
- file.create(null, true, new org.eclipse.core.runtime.NullProgressMonitor());
- file.setDerived(true);
-
- // Write empty contents, to overcome 'Resource '..' is not local' exception
- String classpath="<classpath/>";
- file.setContents(new java.io.ByteArrayInputStream(classpath.getBytes()), true,
- false, new org.eclipse.core.runtime.NullProgressMonitor());
-
- IClasspathEntry[] classpaths=new IClasspathEntry[2];
-
- classpaths[0] = JavaCore.newContainerEntry(
- new Path("org.eclipse.jdt.launching.JRE_CONTAINER"));
-
- classpaths[1] = JavaCore.newSourceEntry(sourceLocation);
-
- jproj.setRawClasspath(classpaths, outputLocation,
- new org.eclipse.core.runtime.NullProgressMonitor());
-
- return(jproj);
+ return(project);
}
/**
@@ -454,8 +344,4 @@
private java.util.List<Role> m_roles=null;
private ConversationModel m_conversationModel=null;
private BuildSystem m_buildSystem=null;
- private java.util.List<ConversationBasedGenerator> m_conversationBasedGen=
- new java.util.Vector<ConversationBasedGenerator>();
- private java.util.List<ModelBasedGenerator> m_modelBasedGen=
- new java.util.Vector<ModelBasedGenerator>();
}
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/MavenBuildSystem.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/MavenBuildSystem.java 2009-02-06 12:18:23 UTC (rev 479)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/MavenBuildSystem.java 2009-02-06 19:12:16 UTC (rev 480)
@@ -24,11 +24,7 @@
private static final String BUILD_FILE = "pom.xml";
private static final String MAVEN = "Maven";
- private static final String ESB_CONFIG_PATH = "src/main/resources/META-INF/jboss-esb.xml";
- private static final String DEPLOYMENT_PATH = "src/main/resources/META-INF/deployment.xml";
- private static final String JBMQ_CONFIG_PATH = "src/main/resources/jbmq-queue-service.xml";
- private static final String JAVA_SOURCE_PATH = "src/main/java";
- private static final String LIBRARY_PATH = null;
+ private static final String BPEL_PATH = "src/main/resources/bpel";
/**
* This method represents the name of the build
@@ -51,51 +47,13 @@
}
/**
- * This method returns the ESB configuration file
+ * This method returns the BPEL file
* path.
*
- * @return The ESB configuration file path
+ * @return The BPEL file path
*/
- public String getESBConfigFilePath() {
- return(ESB_CONFIG_PATH);
+ public String getBPELFilePath() {
+ return(BPEL_PATH);
}
-
- /**
- * This method returns the deployment file
- * path.
- *
- * @return The deployment file path
- */
- public String getDeploymentFilePath() {
- return(DEPLOYMENT_PATH);
- }
-
- /**
- * This method returns the JBMQ configuration file
- * path.
- *
- * @return The JBMQ configuration file path
- */
- public String getJBMQConfigFilePath() {
- return(JBMQ_CONFIG_PATH);
- }
-
- /**
- * This method returns the Java source path.
- *
- * @return The Java source path
- */
- public String getJavaSourcePath() {
- return(JAVA_SOURCE_PATH);
- }
-
- /**
- * This method returns the library path.
- *
- * @return The library path
- */
- public String getLibraryPath() {
- return(LIBRARY_PATH);
- }
}
Deleted: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/ModelBasedGenerator.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/ModelBasedGenerator.java 2009-02-06 12:18:23 UTC (rev 479)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.bpel/src/java/org/jboss/tools/overlord/cdl/bpel/generator/ModelBasedGenerator.java 2009-02-06 19:12:16 UTC (rev 480)
@@ -1,42 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
- * by the @authors tag. All rights reserved.
- * See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU Lesser General Public License, v. 2.1.
- * This program is distributed in the hope that it will be useful, but WITHOUT A
- * 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,
- * v.2.1 along with this distribution; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
- */
-package org.jboss.tools.overlord.cdl.bpel.generator;
-
-import org.eclipse.jdt.core.IJavaProject;
-import org.jboss.tools.overlord.cdl.bpel.model.*;
-
-/**
- * This interface represents a module that generates artefacts
- * based on the complete model.
- */
-public interface ModelBasedGenerator {
-
- /**
- * This method generates the relevant artefacts based on
- * the supplied model, within the specified Java project.
- *
- * @param jproj The Java project
- * @param model The model
- * @param buildSystem The build system to use
- * @throws GeneratorException Failed to generate
- */
- public void generate(IJavaProject jproj,
- BPELLanguageModel model, BuildSystem buildSystem)
- throws GeneratorException;
-
-}
15 years, 2 months
Overlord SVN: r479 - in cdl/trunk/validator/jbossesb: src and 8 other directories.
by overlord-commits@lists.jboss.org
Author: objectiser
Date: 2009-02-06 07:18:23 -0500 (Fri, 06 Feb 2009)
New Revision: 479
Added:
cdl/trunk/validator/jbossesb/src/
cdl/trunk/validator/jbossesb/src/main/
cdl/trunk/validator/jbossesb/src/main/java/
cdl/trunk/validator/jbossesb/src/main/java/org/
cdl/trunk/validator/jbossesb/src/main/java/org/jboss/
cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/
cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/
cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/
cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/
cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ESBUtil.java
cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidationAction.java
cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidatorFilter.java
cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidatorGenerator.java
cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidatorManager.java
Modified:
cdl/trunk/validator/jbossesb/
Log:
Move Service Validators from pi4soa to Overlord project codebase, as originally developed before Overlord was established, but now is an integral part of the CDL component of this project.
Property changes on: cdl/trunk/validator/jbossesb
___________________________________________________________________
Name: svn:ignore
+ lib
.classpath
.project
Added: cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ESBUtil.java
===================================================================
--- cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ESBUtil.java (rev 0)
+++ cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ESBUtil.java 2009-02-06 12:18:23 UTC (rev 479)
@@ -0,0 +1,149 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.soa.overlord.validator.jbossesb;
+
+import java.util.logging.Logger;
+
+import org.pi4soa.common.util.NamesUtil;
+import org.pi4soa.common.xml.NameSpaceUtil;
+
+public class ESBUtil {
+
+ /**
+ * This method returns the pi4soa message associated
+ * with the supplied JBoss ESB message.
+ *
+ * @param message The esb message
+ * @return The pi4soa message
+ */
+ public static java.io.Serializable getMessage(
+ org.jboss.soa.esb.message.Message message) {
+ java.io.Serializable ret=null;
+
+ ret = (java.io.Serializable)message.getBody().get();
+
+ // Check if should return a multipart message
+ if (ret == null) {
+
+ // Check if single or multipart message
+ if (message.getBody().getNames() != null &&
+ message.getBody().getNames().length == 1) {
+
+ Object mesg=message.getBody().get(message.getBody().getNames()[0]);
+
+ if (logger.isLoggable(java.util.logging.Level.FINEST)) {
+ logger.finest("MESSAGE("+
+ message.getBody().getNames()[0]+")="+mesg);
+ }
+
+ if (mesg instanceof java.io.Serializable) {
+ ret = (java.io.Serializable)mesg;
+ }
+
+ } else if (message.getBody().getNames() != null &&
+ message.getBody().getNames().length > 1) {
+
+ java.util.Hashtable multipart=new java.util.Hashtable();
+
+ for (int i=0; i < message.getBody().getNames().length; i++) {
+ multipart.put(message.getBody().getNames()[i],
+ message.getBody().get(message.getBody().getNames()[i]));
+ }
+
+ ret = multipart;
+ }
+ }
+
+ if (ret instanceof byte[]) {
+ ret = new String((byte[])ret);
+ }
+
+ return(ret);
+ }
+
+ /**
+ * This method returns the JBoss ESB message associated
+ * with the supplied pi4soa message.
+ *
+ * @param message The pi4soa message
+ * @return The esb message
+ */
+ public static org.jboss.soa.esb.message.Message getMessage(
+ org.pi4soa.service.Message message) {
+ org.jboss.soa.esb.message.Message ret=
+ org.jboss.soa.esb.message.format.MessageFactory.getInstance().getMessage();
+
+ // Check if multi-part message
+ if (message.isMultiPart()) {
+ if (message.getValue() instanceof java.util.Map) {
+ java.util.Map parts=(java.util.Map)message.getValue();
+
+ java.util.Iterator iter=parts.keySet().iterator();
+ while (iter.hasNext()) {
+ String key=(String)iter.next();
+
+ ret.getBody().add(key, parts.get(key));
+ }
+ } else {
+ logger.severe("JBossESB message " +
+ "is not a valid multi-part message");
+ }
+ } else {
+ ret.getBody().add(message.getValue());
+ }
+
+ // Determine if the message represents a fault
+ if (NamesUtil.isSet(message.getFaultName())) {
+ String namespace=NameSpaceUtil.getNamespace(message.getFaultName());
+ String localpart=NameSpaceUtil.getLocalPart(message.getFaultName());
+
+ try {
+ ret.getFault().setCode(new java.net.URI(
+ namespace+"/"+localpart));
+ } catch(Exception e) {
+ logger.severe("JBossESB message " +
+ "failed to set fault code: "+e);
+ }
+ }
+
+ return(ret);
+ }
+
+ public static String encodeServiceParameter(String param) {
+ return(param.replaceAll(":", "/colon/"));
+ }
+
+ public static String decodeServiceParameter(String param) {
+ return(param.replaceAll("/colon/", ":"));
+ }
+
+ public static String getCategory(String category) {
+ String ret=category;
+
+ if (ret.startsWith("http://")) {
+ ret = ret.substring(7);
+ }
+
+ // Convert '/' into another separator
+ ret = ret.replace('/', '_');
+
+ return(ret);
+ }
+
+ private static Logger logger = Logger.getLogger("org.pi4soa.jbossesb.util");
+}
Added: cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidationAction.java
===================================================================
--- cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidationAction.java (rev 0)
+++ cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidationAction.java 2009-02-06 12:18:23 UTC (rev 479)
@@ -0,0 +1,247 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.soa.overlord.validator.jbossesb;
+
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
+import org.jboss.soa.esb.actions.*;
+import org.jboss.soa.esb.helpers.ConfigTree;
+import org.jboss.soa.esb.message.Message;
+
+import org.pi4soa.common.util.MessageUtil;
+import org.pi4soa.service.*;
+import org.pi4soa.service.behavior.*;
+import org.pi4soa.service.monitor.*;
+import org.pi4soa.common.util.NamesUtil;
+
+/**
+ * This class provides the action implementation for validation
+ * against the pi4soa state machine.
+ */
+public class ValidationAction extends AbstractActionLifecycle {
+
+ private static final String ACTIVE_ATTR = "active";
+ private static final String INBOUND_ATTR = "inbound";
+ public static final String CDM_FILE_PATH="cdmFilePath";
+ public static final String PARTICIPANT_TYPE="participantType";
+
+ /**
+ * This constructor initializes the actions with the
+ * service configuration details.
+ *
+ * @param config The service configuration
+ */
+ public ValidationAction(ConfigTree config) {
+ m_config = config;
+ }
+
+ /**
+ * This method initializes the service action.
+ */
+ public void initialise() throws ActionLifecycleException {
+
+ if (logger.isLoggable(Level.FINE)) {
+ logger.fine("ValidationAction initialise: "+this);
+ }
+
+ super.initialise();
+
+ String direction=
+ m_config.getAttribute(INBOUND_ATTR);
+
+ if (direction != null && direction.equalsIgnoreCase("false")) {
+ m_inbound = false;
+ }
+
+ String active=
+ m_config.getAttribute(ACTIVE_ATTR);
+
+ if (active != null && active.equalsIgnoreCase("false")) {
+ m_active = false;
+ }
+
+ getServiceMonitor();
+ }
+
+ /**
+ * This method returns the service monitor associated with
+ * the ESB service.
+ *
+ * @return The service monitor
+ */
+ protected synchronized ServiceMonitor getServiceMonitor() {
+
+ if (m_serviceMonitor == null) {
+
+ try {
+ ServiceDescription sdesc=null;
+ String cdmFilePath=
+ m_config.getAttribute(CDM_FILE_PATH);
+ String participantType=
+ m_config.getAttribute(PARTICIPANT_TYPE);
+
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest("ValidationAction config: cdm="+
+ cdmFilePath+" participant="+participantType);
+ }
+
+ if (NamesUtil.isSet(cdmFilePath) &&
+ NamesUtil.isSet(participantType)) {
+
+ java.io.InputStream is=ValidationAction.class.
+ getClassLoader().getResourceAsStream(cdmFilePath);
+
+ if (is == null) {
+
+ is = ClassLoader.getSystemResourceAsStream(cdmFilePath);
+
+ if (is == null) {
+ throw new ServiceException("Failed to locate path '"+
+ cdmFilePath+"'");
+ }
+ }
+
+ if (is != null) {
+ sdesc = org.pi4soa.service.util.DescriptionRetrievalUtil.instance().getServiceDescription(is, participantType);
+ }
+ } else {
+ logger.severe("Choreography file and Participant Type not specified: "+this);
+ }
+
+ if (sdesc != null) {
+ m_serviceDescriptionName = sdesc.getFullyQualifiedName();
+
+ // Obtain the service container
+ m_serviceMonitor = ValidatorManager.createServiceContainer(
+ sdesc);
+ } else {
+ logger.severe("Service description could not be loaded: "+
+ cdmFilePath+" participant="+participantType);
+ }
+
+ } catch(Exception e) {
+ logger.log(Level.SEVERE,
+ "Failed to initialize ValidationAction", e);
+ }
+ }
+
+ return(m_serviceMonitor);
+ }
+
+ /**
+ * This method processes a message for the service associated
+ * with this ESB action.
+ *
+ * @param message The message
+ * @return The message
+ */
+ public Message processMessage(Message message) throws ActionProcessingException {
+
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest("ValidationAction: "+this+" message="+message);
+ }
+
+ try {
+ java.io.Serializable value=ESBUtil.getMessage(message);
+
+ if (value == null) {
+ throw new ServiceException("Failed to obtain value from message: "+message);
+ }
+
+ String mesgType=MessageUtil.getMessageType(value);
+
+ org.pi4soa.service.Message mesg=
+ getServiceMonitor().createMessage(mesgType, null,
+ null, value, null, null);
+
+ try {
+ if (m_inbound) {
+ getServiceMonitor().messageReceived(mesg);
+ } else {
+ getServiceMonitor().messageSent(mesg);
+ }
+ } catch(OutOfSequenceMessageException osme) {
+
+ if (m_active) {
+ throw osme;
+ } else {
+ logger.severe("Out of sequence message detected");
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest(message.toString());
+ }
+ }
+ } catch(UnexpectedMessageException ume) {
+
+ if (m_active) {
+ throw ume;
+ } else {
+ logger.severe("Unexpected message detected");
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest(message.toString());
+ }
+ }
+ }
+
+ } catch(Throwable t) {
+ logger.log(java.util.logging.Level.SEVERE,
+ "Failed to handle message", t);
+
+ throw new ActionProcessingException("Failed to handle message", t);
+ }
+
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest("ValidationAction: "+this+
+ "serviceDescriptionName="+
+ m_serviceDescriptionName+
+ " finished processing message="+message);
+ }
+
+ return(message);
+ }
+
+ /**
+ * This method is called to tidy up after the action is
+ * no longer required.
+ */
+ public void destroy() throws ActionLifecycleException {
+ if (logger.isLoggable(Level.FINE)) {
+ logger.fine("ValidationAction destroy: "+this);
+ }
+
+ super.destroy();
+
+ if (m_serviceMonitor != null &&
+ m_serviceDescriptionName != null) {
+ try {
+ ValidatorManager.releaseServiceMonitor(m_serviceDescriptionName);
+ } catch(org.pi4soa.service.ServiceException se) {
+ throw new ActionLifecycleException("Failed to destroy service monitor",
+ se);
+ }
+ }
+ }
+
+ private static final Logger logger = Logger.getLogger("org.pi4soa.jbossesb.validator");
+
+ private ConfigTree m_config=null;
+ private String m_serviceDescriptionName=null;
+ private ServiceMonitor m_serviceMonitor=null;
+ private boolean m_inbound=true;
+ private boolean m_active=true;
+}
\ No newline at end of file
Added: cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidatorFilter.java
===================================================================
--- cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidatorFilter.java (rev 0)
+++ cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidatorFilter.java 2009-02-06 12:18:23 UTC (rev 479)
@@ -0,0 +1,616 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.soa.overlord.validator.jbossesb;
+
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
+import org.jboss.soa.esb.message.*;
+import org.jboss.soa.esb.couriers.*;
+import org.jboss.soa.esb.helpers.*;
+import org.pi4soa.common.util.MessageUtil;
+import org.pi4soa.common.util.NamesUtil;
+import org.pi4soa.common.xml.XMLUtils;
+import org.pi4soa.service.OutOfSequenceMessageException;
+import org.pi4soa.service.ServiceException;
+import org.pi4soa.service.UnexpectedMessageException;
+import org.pi4soa.service.monitor.*;
+
+import com.sun.org.apache.xerces.internal.impl.validation.ValidationManager;
+
+public class ValidatorFilter extends org.jboss.soa.esb.filter.InputOutputFilter {
+
+ private static final String CONFIG_FILE = "validator-config.xml";
+ public static final String CDM_FILE_PATH="cdmFilePath";
+ public static final String PARTICIPANT_TYPE="participantType";
+ public static final String VALIDATE="validate";
+
+ public ValidatorFilter() {
+ initialize();
+ }
+
+ public Message onOutput(Message msg, java.util.Map params)
+ throws CourierException {
+
+ String key=getKey(msg);
+
+ if (key != null) {
+ ServiceMonitor sm=(ServiceMonitor)m_outputServices.get(key);
+
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest("ValidationFilter: "+this+" message="+
+ msg+" monitor="+sm);
+ }
+
+ if (sm != null) {
+ try {
+ java.io.Serializable value=ESBUtil.getMessage(msg);
+
+ if (value == null) {
+ throw new ServiceException("Failed to obtain value from message: "+msg);
+ }
+
+ String mesgType=MessageUtil.getMessageType(value);
+
+ org.pi4soa.service.Message mesg=
+ sm.createMessage(mesgType,
+ null, null, value, null, null);
+
+ try {
+ sm.messageSent(mesg);
+ } catch(OutOfSequenceMessageException osme) {
+
+ if (m_active) {
+ throw osme;
+ } else {
+ logger.severe("Out of sequence message detected");
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest(msg.toString());
+ }
+ }
+ } catch(UnexpectedMessageException ume) {
+
+ if (m_active) {
+ throw ume;
+ } else {
+ logger.severe("Unexpected message detected");
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest(msg.toString());
+ }
+ }
+ }
+
+ } catch(Throwable t) {
+ logger.log(java.util.logging.Level.SEVERE,
+ "Failed to handle message", t);
+
+ throw new CourierException("Failed to handle message", t);
+ }
+ }
+ }
+
+ return(msg);
+ }
+
+ public Message onInput(Message msg, java.util.Map params)
+ throws CourierException {
+
+ String key=getKey(msg);
+
+ if (key != null) {
+ ServiceMonitor sm=(ServiceMonitor)m_inputServices.get(key);
+
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest("ValidationFilter: "+this+" message="+msg+" monitor="+sm);
+ }
+
+ if (sm != null) {
+ try {
+ java.io.Serializable value=ESBUtil.getMessage(msg);
+
+ if (value == null) {
+ throw new ServiceException("Failed to obtain value from message: "+msg);
+ }
+
+ String mesgType=MessageUtil.getMessageType(value);
+
+ org.pi4soa.service.Message mesg=
+ sm.createMessage(mesgType,
+ null, null, value, null, null);
+
+ try {
+ sm.messageReceived(mesg);
+ } catch(OutOfSequenceMessageException osme) {
+
+ if (m_active) {
+ throw osme;
+ } else {
+ logger.severe("Out of sequence message detected");
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest(msg.toString());
+ }
+ }
+ } catch(UnexpectedMessageException ume) {
+
+ if (m_active) {
+ throw ume;
+ } else {
+ logger.severe("Unexpected message detected");
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest(msg.toString());
+ }
+ }
+ }
+
+ } catch(Throwable t) {
+ logger.log(java.util.logging.Level.SEVERE,
+ "Failed to handle message", t);
+
+ throw new CourierException("Failed to handle message", t);
+ }
+ }
+ }
+
+ return(msg);
+ }
+
+ protected void initialize() {
+
+ java.net.URL url=
+ ValidatorFilter.class.getClassLoader().getResource(CONFIG_FILE);
+
+ System.out.println("CONFIG FILE URL="+url);
+ System.out.println("CONFIG FILE URL TYPE="+url.getClass());
+
+ if (url != null) {
+ java.io.File file=new java.io.File(url.getFile());
+
+ java.io.File[] files=file.getParentFile().listFiles();
+ java.io.File models=null;
+
+ for (int i=0; models == null && i < files.length; i++) {
+ if (files[i].getName().equals("models") &&
+ files[i].isDirectory()) {
+ models = files[i];
+ }
+ }
+
+ if (models != null) {
+ ValidatorConfigChangeMonitor mon=new ValidatorConfigChangeMonitor(file, models);
+
+ new Thread(mon).start();
+ }
+ }
+ }
+
+ /**
+ * This method performs the update of the configuration of
+ * service monitors, based on the information in the validator
+ * configuration XML file, and the choreographies defined in the
+ * models folder.
+ */
+ protected void updateConfiguration(java.io.InputStream is,
+ java.util.Set<String> existingServiceDescriptions,
+ java.util.Set<String> existingInputKeys,
+ java.util.Set<String> existingOutputKeys) {
+
+ try {
+ updateConfiguration(ConfigTree.fromInputStream(is),
+ existingServiceDescriptions, existingInputKeys,
+ existingOutputKeys);
+ } catch(Exception e) {
+
+ logger.log(Level.SEVERE,
+ "Failed to update configuration from input stream", e);
+ }
+ }
+
+ /**
+ * This method performs the update of the configuration of
+ * service monitors, based on the information in the validator
+ * configuration XML file, and the choreographies defined in the
+ * models folder.
+ */
+ protected void updateConfiguration(org.w3c.dom.Element elem,
+ java.util.Set<String> existingServiceDescriptions,
+ java.util.Set<String> existingInputKeys,
+ java.util.Set<String> existingOutputKeys) {
+
+ try {
+ updateConfiguration(ConfigTree.fromElement(elem),
+ existingServiceDescriptions, existingInputKeys,
+ existingOutputKeys);
+ } catch(Exception e) {
+
+ logger.log(Level.SEVERE,
+ "Failed to update configuration from DOM element", e);
+ }
+ }
+
+ /**
+ * This method performs the update of the configuration of
+ * service monitors, based on the information in the validator
+ * configuration XML file, and the choreographies defined in the
+ * models folder.
+ */
+ protected void updateConfiguration(ConfigTree config,
+ java.util.Set<String> existingServiceDescriptions,
+ java.util.Set<String> existingInputKeys,
+ java.util.Set<String> existingOutputKeys) {
+ logger.info("Update Service Validator Configuration");
+
+ if (config != null) {
+ try {
+ if (config.getName().equals(VALIDATOR_NODE)) {
+ String active=config.getAttribute(ACTIVE_ATTR);
+
+ if (active != null && active.equalsIgnoreCase("true")) {
+
+ logger.info("Setting validator into active mode");
+ m_active = true;
+ }
+ }
+
+ ConfigTree[] services=config.getChildren(SERVICE_NODE);
+
+ if (logger.isLoggable(Level.FINEST)) {
+ if (services != null) {
+ logger.finest("ValidationFilter: services="+services.length);
+ } else {
+ logger.finest("ValidationFilter: services null");
+ }
+ }
+
+ for (int i=0; i < services.length; i++) {
+ org.pi4soa.service.monitor.ServiceMonitor sm=null;
+
+ // Create service monitor for service
+ String cdmFilePath=
+ services[i].getAttribute(CDM_FILE_PATH);
+ String participantType=
+ services[i].getAttribute(PARTICIPANT_TYPE);
+ boolean validate=
+ services[i].getBooleanAttribute(VALIDATE, true);
+
+ if (NamesUtil.isSet(participantType)) {
+
+ if (NamesUtil.isSet(cdmFilePath)) {
+ java.io.InputStream is = ValidatorFilter.class.
+ getClassLoader().getResourceAsStream(
+ cdmFilePath);
+
+ if (is != null) {
+ org.pi4soa.service.behavior.ServiceDescription sdesc=
+ org.pi4soa.service.util.DescriptionRetrievalUtil.instance().getServiceDescription(is, participantType);
+
+ if (sdesc != null) {
+
+ // Obtain the service container
+ sm = ValidatorManager.createServiceContainer(sdesc, validate);
+
+ if (logger.isLoggable(Level.FINE)) {
+ logger.fine("Service monitor for '"+cdmFilePath+
+ "' and participantType '"+participantType+"' = "+sm);
+ }
+
+ // Remove service description from list
+ existingServiceDescriptions.remove(sdesc.getFullyQualifiedName());
+
+ } else {
+ logger.severe("Service description could not be loaded");
+ }
+
+ } else {
+ logger.severe("Choreography file path not found: "+this);
+ }
+ } else if (validate == false) {
+
+ logger.fine("Create non-validating service monitor for: "+
+ participantType);
+
+ // Just record information for participant
+ // using the service tracker
+ org.pi4soa.service.behavior.ServiceDescription sdesc=
+ org.pi4soa.service.behavior.BehaviorFactory.eINSTANCE.createServiceDescription();
+ sdesc.setName(participantType);
+
+ sm = ValidatorManager.createServiceContainer(sdesc, validate);
+
+ // Remove service description from list
+ existingServiceDescriptions.remove(sdesc.getFullyQualifiedName());
+
+ } else {
+ logger.severe("Choreography file path not specified: "+this);
+ }
+ } else {
+ logger.severe("Participant type not specified: "+this);
+ }
+
+ if (sm != null) {
+ // Map inputs to service
+ ConfigTree[] inputs=services[i].getChildren(INPUT_NODE);
+
+ for (int j=0; j < inputs.length; j++) {
+ String epr=inputs[j].getAttribute(EPR_ATTR);
+
+ if (epr != null) {
+
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest("Storing input epr '"+
+ epr+"' against monitor: "+sm);
+ }
+
+ // Check if EPR associated with different
+ // input service
+ ServiceMonitor tmp=m_inputServices.get(epr);
+
+ if (tmp != null && tmp != sm) {
+ logger.severe("Input EPR '"+epr+
+ "' already associated with another Service Monitor");
+ }
+
+ m_inputServices.put(epr, sm);
+
+ existingInputKeys.remove(epr);
+ }
+ }
+
+ // Map outputs to service
+ ConfigTree[] outputs=services[i].getChildren(OUTPUT_NODE);
+
+ for (int j=0; j < outputs.length; j++) {
+ String epr=outputs[j].getAttribute(EPR_ATTR);
+
+ if (epr != null) {
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest("Storing output epr '"+
+ epr+"' against monitor: "+sm);
+ }
+
+ // Check if EPR associated with different
+ // output service
+ ServiceMonitor tmp=m_outputServices.get(epr);
+
+ if (tmp != null && tmp != sm) {
+ logger.severe("Output EPR '"+epr+
+ "' already associated with another Service Monitor");
+ }
+
+ m_outputServices.put(epr, sm);
+
+ existingOutputKeys.remove(epr);
+ }
+ }
+ }
+ }
+ } catch(Exception e) {
+ logger.log(java.util.logging.Level.SEVERE,
+ "Failed to load validator config", e);
+ }
+ }
+ }
+
+ /**
+ * This method returns a key associated with the 'to'
+ * destination of the supplied message.
+ *
+ * @param msg The message
+ * @return The key, or null if not relevant
+ */
+ protected String getKey(Message msg) {
+ String ret=null;
+
+ if (msg != null && msg.getHeader() != null &&
+ msg.getHeader().getCall() != null &&
+ msg.getHeader().getCall().getTo() != null &&
+ msg.getHeader().getCall().getTo().getAddr() != null) {
+
+ String key=msg.getHeader().getCall().getTo().getAddr().getAddress();
+ int ind=-1;
+
+ if (key.startsWith(JMS_PROTOCOL_PREFIX) &&
+ ((ind=key.indexOf(QUEUE_PREFIX)) != -1 ||
+ (ind=key.indexOf(TOPIC_PREFIX)) != -1)) {
+ ret = JMS_PROTOCOL_PREFIX+key.substring(ind);
+ }
+ }
+
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest("Key for message '"+msg+"' is: "+ret);
+ }
+
+ return(ret);
+ }
+
+ private static final Logger logger = Logger.getLogger("org.pi4soa.jbossesb.validator");
+
+ private static final String TOPIC_PREFIX = "topic/";
+ private static final String QUEUE_PREFIX = "queue/";
+ private static final String JMS_PROTOCOL_PREFIX = "jms:";
+ private static final String EPR_ATTR = "epr";
+ private static final String OUTPUT_NODE = "output";
+ private static final String INPUT_NODE = "input";
+ private static final String SERVICE_NODE = "service";
+ private static final String ACTIVE_ATTR = "active";
+ private static final String VALIDATOR_NODE = "validator";
+
+ private java.util.Map<String,ServiceMonitor> m_inputServices=new java.util.Hashtable<String,ServiceMonitor>();
+ private java.util.Map<String,ServiceMonitor> m_outputServices=new java.util.Hashtable<String,ServiceMonitor>();
+ private boolean m_active=false;
+
+ public class ValidatorConfigChangeMonitor implements java.lang.Runnable {
+
+ public ValidatorConfigChangeMonitor(java.io.File validatorConfigFile,
+ java.io.File modelsDir) {
+ m_validatorConfigFile = validatorConfigFile;
+ m_modelsDir = modelsDir;
+
+ // Do initial check for updates, so monitors
+ // initialized before returning from construct,
+ // as remainder of checks will be in a separate
+ // thread - so we need to ensure that the monitors
+ // are configured before the first message is
+ // passed through the filter.
+ checkForUpdates();
+ }
+
+ public void run() {
+
+ while (true) {
+ checkForUpdates();
+
+ try {
+ synchronized(ValidatorConfigChangeMonitor.this) {
+ wait(30000);
+ }
+ } catch(Exception e) {
+ e.printStackTrace();
+ }
+ }
+ }
+
+ protected void checkForUpdates() {
+ logger.info("Checking for config updates");
+
+ // Get last update time
+ long lastUpdate=getLastUpdate();
+
+ if (lastUpdate > m_lastUpdate) {
+
+ updateConfigurations();
+
+ m_lastUpdate = lastUpdate;
+ }
+ }
+
+ protected void updateConfigurations() {
+ java.util.Set<String> existingServiceDescriptions=
+ ValidatorManager.getServiceDescriptionNames();
+
+ java.util.Set<String> existingInputKeys=
+ new java.util.HashSet<String>(m_inputServices.keySet());
+
+ java.util.Set<String> existingOutputKeys=
+ new java.util.HashSet<String>(m_outputServices.keySet());
+
+ java.io.InputStream is=ValidatorFilter.class.getClassLoader().
+ getResourceAsStream(CONFIG_FILE);
+
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest("ValidationFilter: config="+CONFIG_FILE+" is="+is);
+ }
+
+ updateConfiguration(is, existingServiceDescriptions,
+ existingInputKeys, existingOutputKeys);
+
+ // Work through choreography files in the models directory
+ java.io.File[] files=m_modelsDir.listFiles();
+
+ for (int i=0; i < files.length; i++) {
+ if (files[i].getName().endsWith(".cdm")) {
+
+ try {
+ java.io.FileInputStream fis=new java.io.FileInputStream(files[i]);
+
+ org.pi4soa.cdl.Package cdlpack=
+ org.pi4soa.service.util.DescriptionRetrievalUtil.instance().getCDLPackage(fis);
+
+ ValidatorGenerator generator=new ValidatorGenerator();
+
+ org.w3c.dom.Element validator=
+ generator.generate(cdlpack, files[i].getName());
+
+ if (logger.isLoggable(Level.FINEST)) {
+ logger.finest("ValidationFilter: model="+files[i].getName()+
+ " cdlpack="+cdlpack+" config=\r\n"+
+ XMLUtils.getText(validator, true));
+ }
+
+ updateConfiguration(validator,
+ existingServiceDescriptions,
+ existingInputKeys, existingOutputKeys);
+
+ fis.close();
+ } catch(Exception e) {
+ logger.log(Level.SEVERE,
+ "Failed to update configuration for model '"+
+ files[i].getName()+"'", e);
+ }
+ }
+ }
+
+ // Any remaining service description names need to
+ // have their associated monitors removed
+ java.util.Iterator<String> iter=
+ existingServiceDescriptions.iterator();
+
+ while (iter.hasNext()) {
+ String sdescName=iter.next();
+
+ try {
+ logger.info("Removing service monitor for '"+sdescName+"'");
+ ValidatorManager.removeServiceMonitor(sdescName);
+ } catch(Exception e) {
+ logger.log(Level.SEVERE,
+ "Failed to remove service monitor '"+sdescName+"'", e);
+ }
+ }
+
+ // Any remaining input keys need to be removed
+ iter = existingInputKeys.iterator();
+
+ while (iter.hasNext()) {
+ String key=iter.next();
+ m_inputServices.remove(key);
+ }
+
+ // Any remaining output keys need to be removed
+ iter = existingOutputKeys.iterator();
+
+ while (iter.hasNext()) {
+ String key=iter.next();
+ m_outputServices.remove(key);
+ }
+ }
+
+ protected long getLastUpdate() {
+ long ret=0;
+
+ if (m_validatorConfigFile != null) {
+ ret = m_validatorConfigFile.lastModified();
+ }
+
+ if (m_modelsDir != null) {
+ java.io.File[] files=m_modelsDir.listFiles();
+
+ for (int i=0; i < files.length; i++) {
+ if (files[i].getName().endsWith(".cdm") &&
+ ret < files[i].lastModified()) {
+ ret = files[i].lastModified();
+ }
+ }
+ }
+
+ return(ret);
+ }
+
+ private java.io.File m_validatorConfigFile=null;
+ private java.io.File m_modelsDir=null;
+ private long m_lastUpdate=0;
+ }
+}
Added: cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidatorGenerator.java
===================================================================
--- cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidatorGenerator.java (rev 0)
+++ cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidatorGenerator.java 2009-02-06 12:18:23 UTC (rev 479)
@@ -0,0 +1,229 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.soa.overlord.validator.jbossesb;
+
+import java.util.Collections;
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+
+import org.pi4soa.cdl.*;
+import org.pi4soa.common.annotations.*;
+import org.pi4soa.common.xml.XMLUtils;
+
+/**
+ * This class provides a generator for the JBossESB Validator
+ * configuration.
+ */
+public class ValidatorGenerator {
+
+ private static final String CDM_FILE_PATH_ATTR = "cdmFilePath";
+ private static final String FILE_PATH_PREFIX = "models/";
+ private static final String SERVICE_ELEMENT = "service";
+ private static final String VALIDATOR_ELEMENT = "validator";
+
+ public ValidatorGenerator() {
+ }
+
+ public org.w3c.dom.Element generate(org.pi4soa.cdl.Package cdlpack,
+ String cdmFileName) {
+ org.w3c.dom.Element ret=null;
+
+ try {
+ ret = createValidatorConfig();
+
+ String cdmFilePath=getFilePath(cdmFileName);
+
+ // Create the new entries for the supplied choreography
+ createEntries(ret, cdmFilePath, cdlpack);
+
+ } catch(Exception e) {
+ e.printStackTrace();
+ }
+
+ return(ret);
+ }
+
+ protected org.w3c.dom.Element createValidatorConfig()
+ throws Exception {
+ org.w3c.dom.Element ret=null;
+
+ org.w3c.dom.Document doc=
+ javax.xml.parsers.DocumentBuilderFactory.
+ newInstance().newDocumentBuilder().newDocument();
+
+ ret = doc.createElement(VALIDATOR_ELEMENT);
+
+ doc.appendChild(ret);
+
+ return(ret);
+ }
+
+ protected void createEntries(org.w3c.dom.Element validator,
+ String cdmFilePath, org.pi4soa.cdl.Package cdlpack) {
+
+ for (int i=0; i < cdlpack.getTypeDefinitions().getParticipantTypes().size(); i++) {
+ org.pi4soa.cdl.ParticipantType ptype=
+ cdlpack.getTypeDefinitions().getParticipantTypes().get(i);
+
+ org.w3c.dom.Element service=
+ validator.getOwnerDocument().createElement(SERVICE_ELEMENT);
+
+ service.setAttribute(CDM_FILE_PATH_ATTR, cdmFilePath);
+ service.setAttribute("participantType", ptype.getName());
+
+ cdlpack.visit(new InputOutputAnalyser(ptype, service));
+
+ if (service.getFirstChild() != null) {
+ validator.appendChild(service);
+ }
+ }
+ }
+
+ protected String getFilePath(String cdmFileName) {
+ return(FILE_PATH_PREFIX+cdmFileName);
+ }
+
+ private static Logger logger = Logger.getLogger("org.jboss.tools.overlord.cdl.validator.jbossesb.actions");
+
+ public class InputOutputAnalyser extends DefaultCDLVisitor {
+
+ private static final String JBOSSESB_ANNOTATION = "jbossesb";
+ private static final String JBOSSESB_ELEMENT = "jbossesb";
+ private static final String DESTINATION_ELEMENT = "destination";
+ private static final String NAME_ATTR = "name";
+ private static final String EPR_ATTR = "epr";
+ private static final String INPUT_ELEMENT = "input";
+ private static final String OUTPUT_ELEMENT = "output";
+
+ public InputOutputAnalyser(org.pi4soa.cdl.ParticipantType ptype,
+ org.w3c.dom.Element service) {
+ m_participantType = ptype;
+ m_service = service;
+
+ m_templateProcessor =
+ org.pi4soa.common.annotations.AnnotationsManagerFactory.getAnnotationsManager().getTemplateProcessor(JBOSSESB_ANNOTATION);
+ }
+
+ public void interaction(Interaction interaction) {
+ if (m_participantType.getRoleTypes().contains(interaction.getFromRoleType()) ||
+ (interaction.getFromParticipant() != null &&
+ Collections.disjoint(m_participantType.getRoleTypes(),
+ interaction.getFromParticipant().getRoleTypes()) == false)) {
+
+ for (int i=0; i < interaction.getExchangeDetails().size(); i++) {
+ processExchangeDetails(interaction.getExchangeDetails().get(i), true);
+ }
+ } else if (m_participantType.getRoleTypes().contains(interaction.getToRoleType()) ||
+ (interaction.getToParticipant() != null &&
+ Collections.disjoint(m_participantType.getRoleTypes(),
+ interaction.getToParticipant().getRoleTypes()) == false)) {
+ for (int i=0; i < interaction.getExchangeDetails().size(); i++) {
+ processExchangeDetails(interaction.getExchangeDetails().get(i), false);
+ }
+ }
+ }
+
+ protected void processExchangeDetails(ExchangeDetails details, boolean from) {
+
+ for (int i=0; i < details.getSemanticAnnotations().size(); i++) {
+ SemanticAnnotation sa=details.getSemanticAnnotations().get(i);
+ org.w3c.dom.Element dest=null;
+
+ if (sa.getAnnotation() != null && sa.getName() != null &&
+ sa.getName().equals(JBOSSESB_ANNOTATION)) {
+ try {
+ // Transform the text representation to DOM
+ DocumentBuilderFactory fact=DocumentBuilderFactory.newInstance();
+ fact.setNamespaceAware(true);
+
+ DocumentBuilder builder=fact.newDocumentBuilder();
+ org.w3c.dom.Document doc=
+ builder.parse(new java.io.ByteArrayInputStream(
+ sa.getAnnotation().getBytes()));
+
+ if (doc.getDocumentElement() != null &&
+ doc.getDocumentElement().getNodeName().equals(
+ JBOSSESB_ELEMENT)) {
+ org.w3c.dom.NodeList nl=
+ doc.getDocumentElement().getElementsByTagName(DESTINATION_ELEMENT);
+
+ if (nl.getLength() == 1) {
+ dest = (org.w3c.dom.Element)nl.item(0);
+ } else if (nl.getLength() > 1) {
+ logger.severe("Too many destination elements ("+
+ nl.getLength()+") found");
+ } else {
+ logger.severe("No destinations found");
+ }
+ }
+
+ } catch(Exception e) {
+ logger.log(Level.SEVERE,
+ "Failed to load jbossesb annotation", e);
+ }
+ }
+
+ if (dest != null) {
+ processDestination(details, dest, from);
+ }
+ }
+ }
+
+ protected void processDestination(ExchangeDetails details,
+ org.w3c.dom.Element dest, boolean from) {
+ String elemName=null;
+
+ if (dest != null &&
+ dest.getAttribute("temporary").equalsIgnoreCase("true") == false) {
+ if (from) {
+ if (details.getAction() == ExchangeActionType.REQUEST) {
+ elemName = OUTPUT_ELEMENT;
+ } else {
+ elemName = INPUT_ELEMENT;
+ }
+ } else {
+ if (details.getAction() == ExchangeActionType.REQUEST) {
+ elemName = INPUT_ELEMENT;
+ } else {
+ elemName = OUTPUT_ELEMENT;
+ }
+ }
+
+ // Parameter has been stored in a structured manner
+ // to support use of templates and presentations,
+ // so need to extract the value
+ java.util.List<TemplateParameter> params=
+ m_templateProcessor.getTemplateParameters(dest.getAttribute(NAME_ATTR));
+
+ if (params != null && params.size() > 0) {
+ org.w3c.dom.Element elem=m_service.getOwnerDocument().createElement(elemName);
+ elem.setAttribute(EPR_ATTR, params.get(0).getValue());
+
+ m_service.appendChild(elem);
+ }
+ }
+ }
+
+ private ParticipantType m_participantType=null;
+ private org.w3c.dom.Element m_service=null;
+ private org.pi4soa.common.annotations.TemplateProcessor m_templateProcessor=null;
+ }
+}
Added: cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidatorManager.java
===================================================================
--- cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidatorManager.java (rev 0)
+++ cdl/trunk/validator/jbossesb/src/main/java/org/jboss/soa/overlord/validator/jbossesb/ValidatorManager.java 2009-02-06 12:18:23 UTC (rev 479)
@@ -0,0 +1,234 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2008, Red Hat Middleware LLC, and others contributors as indicated
+ * by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.jboss.soa.overlord.validator.jbossesb;
+
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
+import org.pi4soa.service.ServiceException;
+import org.pi4soa.service.behavior.ServiceDescription;
+import org.pi4soa.service.monitor.*;
+
+public class ValidatorManager {
+
+ /**
+ * This method returns a reference to the service monitor
+ * associated with the supplied service description name,
+ * or null if one does not exist.
+ *
+ * @param sdesc The service description name
+ * @return The service monitor, or null if does not exist
+ */
+ public static ServiceMonitor getServiceMonitor(String sdesc) {
+ ServiceMonitor ret=null;
+
+ synchronized(m_serviceMonitors) {
+ ret = (ServiceMonitor)m_serviceMonitors.get(sdesc);
+ }
+
+ return(ret);
+ }
+
+ /**
+ * This method returns a reference counted Service Monitor
+ * associated with the supplied service description.
+ *
+ * @param sdesc The service description
+ * @return The service monitor
+ */
+ public static ServiceMonitor createServiceContainer(ServiceDescription sdesc) {
+ return(createServiceContainer(sdesc, true));
+ }
+
+ /**
+ * This method returns a reference counted Service Monitor
+ * associated with the supplied service description.
+ *
+ * @param sdesc The service description
+ * @param validate Whether the behavior should be validated
+ * @return The service monitor
+ */
+ public static ServiceMonitor createServiceContainer(ServiceDescription sdesc,
+ boolean validate) {
+ ServiceMonitor ret=null;
+
+ synchronized(m_serviceMonitors) {
+
+ if ((ret = (ServiceMonitor)m_serviceMonitors.get(
+ sdesc.getFullyQualifiedName())) == null) {
+
+ if (logger.isLoggable(Level.FINE)) {
+ logger.fine("Service monitor for '"+
+ sdesc.getFullyQualifiedName()+
+ "' being created");
+ }
+
+ try {
+ // Use XML configuration, to enable alternative
+ // runtime configuration to be specified by
+ // including a pi4soa.xml file in the environment
+ DefaultMonitorConfiguration conf=
+ new XMLMonitorConfiguration();
+
+ conf.setValidateBehaviour(validate);
+
+ ret = ServiceMonitorFactory.getServiceMonitor(conf);
+
+ // Register service description
+ ret.getConfiguration().getServiceRepository().
+ addServiceDescription(sdesc);
+
+ logger.info("Created monitor for service description "+sdesc.getFullyQualifiedName());
+
+ m_serviceMonitors.put(sdesc.getFullyQualifiedName(), ret);
+
+ //m_serviceMonitorCounters.put(sdesc.getFullyQualifiedName(), new Integer(1));
+
+ } catch(Exception e) {
+ logger.severe("Failed to initialize service monitor: "+e);
+ }
+ } else {
+
+ // Service monitor already in use for the service
+ // description, so update description
+ try {
+ // Clear previous version of the service description
+ ServiceDescription[] sdescs=
+ ret.getConfiguration().getServiceRepository().getServiceDescriptions();
+
+ for (int i=0; sdescs != null && i < sdescs.length; i++) {
+ ret.getConfiguration().getServiceRepository().
+ removeServiceDescription(sdescs[i]);
+ }
+
+ logger.info("Updating service description for "+sdesc.getFullyQualifiedName());
+
+ ret.getConfiguration().getServiceRepository().addServiceDescription(sdesc);
+ } catch(Exception e) {
+ logger.log(Level.SEVERE, "Failed to update service description '"+
+ sdesc.getFullyQualifiedName()+"'", e);
+ }
+
+ /* MAY REMOVE
+ *
+ // Increment the counter
+ Integer counter=(Integer)m_serviceMonitorCounters.get(sdesc.getFullyQualifiedName());
+ if (counter != null) {
+ counter = new Integer(counter.intValue()+1);
+ m_serviceMonitorCounters.put(sdesc.getFullyQualifiedName(), counter);
+
+ if (logger.isLoggable(Level.FINE)) {
+ logger.fine("Service monitor for '"+
+ sdesc.getFullyQualifiedName()+"' reference count now: "+counter);
+ }
+ } else {
+ logger.severe("Failed to find counter for "+sdesc.getFullyQualifiedName());
+ }
+ */
+ }
+ }
+
+ return(ret);
+ }
+
+ /**
+ * This method removes the service monitor associated with
+ * the supplied service description name.
+ *
+ * @param sdesc The service description name
+ * @throws ServiceException Failed to remove the service monitor
+ */
+ public static void removeServiceMonitor(String sdesc)
+ throws ServiceException {
+ synchronized(m_serviceMonitors) {
+ ServiceMonitor monitor=(ServiceMonitor)
+ m_serviceMonitors.remove(sdesc);
+
+ if (monitor != null) {
+ monitor.close();
+ }
+ }
+ }
+
+ /**
+ * This method decrements the service monitor reference count
+ * associated with the service description, and if reaches zero,
+ * then it will close the service monitor.
+ *
+ * @param sdesc The service description name
+ * @throws ServiceException Failed to release the service monitor
+ */
+ public static void releaseServiceMonitor(String sdesc)
+ throws ServiceException {
+
+ /* MAY REMOVE
+ *
+ synchronized(m_serviceMonitors) {
+
+ Integer counter=(Integer)m_serviceMonitorCounters.get(sdesc);
+ if (counter != null) {
+
+ if (counter.intValue() > 1) {
+ counter = new Integer(counter.intValue()-1);
+ m_serviceMonitorCounters.put(sdesc, counter);
+
+ if (logger.isLoggable(Level.FINE)) {
+ logger.fine("Service monitor for '"+
+ sdesc+"' reference count now: "+counter);
+ }
+ } else {
+ if (logger.isLoggable(Level.FINE)) {
+ logger.fine("Service monitor for '"+
+ sdesc+"' being closed");
+ }
+
+ m_serviceMonitorCounters.remove(sdesc);
+
+ ServiceMonitor monitor=(ServiceMonitor)
+ m_serviceMonitors.remove(sdesc);
+
+ monitor.close();
+ }
+ } else {
+ logger.severe("Failed to find counter for "+sdesc);
+ }
+ }
+ */
+ }
+
+ /**
+ * This method returns the set of service description names
+ * that are associated with service monitors.
+ *
+ * @return The set of service monitors
+ */
+ public static java.util.Set<String> getServiceDescriptionNames() {
+ java.util.Set<String> ret=new java.util.HashSet<String>();
+
+ // Return copy to ensure changes in the map, do not
+ // affect the returned set of names
+ ret.addAll(m_serviceMonitors.keySet());
+
+ return(ret);
+ }
+
+ private static Logger logger = Logger.getLogger("org.pi4soa.jbossesb.validator");
+
+ private static java.util.Map<String,ServiceMonitor> m_serviceMonitors=new java.util.Hashtable<String,ServiceMonitor>();
+ //private static java.util.Map<String,Integer> m_serviceMonitorCounters=new java.util.Hashtable<String,Integer>();
+}
15 years, 2 months
Overlord SVN: r478 - in cdl/trunk: validator and 1 other directory.
by overlord-commits@lists.jboss.org
Author: objectiser
Date: 2009-02-06 07:16:28 -0500 (Fri, 06 Feb 2009)
New Revision: 478
Added:
cdl/trunk/validator/
cdl/trunk/validator/jbossesb/
Log:
Moving Service Validator code from pi4soa project to Overlord, as the service validator for JBossESB was developed prior to the creation of the Overlord project, but now really belongs as part of its code base.
15 years, 2 months
Overlord SVN: r477 - cdl/trunk.
by overlord-commits@lists.jboss.org
Author: jeff.yuchang
Date: 2009-02-06 05:34:18 -0500 (Fri, 06 Feb 2009)
New Revision: 477
Added:
cdl/trunk/Developer.txt
Log:
* Put Developer.txt for contributors, help them get it started quickly.
Added: cdl/trunk/Developer.txt
===================================================================
--- cdl/trunk/Developer.txt (rev 0)
+++ cdl/trunk/Developer.txt 2009-02-06 10:34:18 UTC (rev 477)
@@ -0,0 +1,17 @@
+
+Building from source
+---------------------------
+0. Checked you have installed the Maven 2.0.9 or above.
+ Otherwise, you can download it from http://maven.apache.org
+1. Download the JBossESB 4.4 from http://www.jboss.org/jbossesb/downloads/
+2. Install the rosetta.jar into local repository using command like:
+ mvn install:install-file -DgroupId=org.jboss.jbossesb -DartifactId=rosetta -Dversion=4.3 -Dpackaging=jar -Dfile=path/to/jbossesb-rosetta.jar
+3. Install the config-model.jar into local repository using command like:
+ mvn install:install-file -DgroupId=org.jboss.jbossesb -DartifactId=config-model -Dversion=1.0.1 -Dpackaging=jar -Dfile=path/to/jbossesb-config-model-1.0. 1.jar
+
+
+Setting up in IDE
+---------------------------
+1. Setup in Eclipse
+ run: mvn eclipse:eclipse
+
15 years, 2 months
Overlord SVN: r476 - in cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model: change/stateless and 1 other directory.
by overlord-commits@lists.jboss.org
Author: objectiser
Date: 2009-02-04 14:58:09 -0500 (Wed, 04 Feb 2009)
New Revision: 476
Modified:
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/actions/stateless/SendMessageAction.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/actions/stateless/SwitchAction.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/change/stateless/ConversationInteractionModelChangeRule.java
cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/change/stateless/IfModelChangeRule.java
Log:
Generate response category/name properties, if an interaction represents the sending of a request, with an associated response.
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/actions/stateless/SendMessageAction.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/actions/stateless/SendMessageAction.java 2009-02-01 19:18:46 UTC (rev 475)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/actions/stateless/SendMessageAction.java 2009-02-04 19:58:09 UTC (rev 476)
@@ -34,6 +34,8 @@
public static final String SERVICE_NAME = "serviceName";
public static final String SERVICE_CATEGORY = "serviceCategory";
+ public static final String RESPONSE_SERVICE_NAME = "responseServiceName";
+ public static final String RESPONSE_SERVICE_CATEGORY = "responseServiceCategory";
/**
* The constructor for the action.
@@ -70,6 +72,8 @@
ret.add(SERVICE_NAME);
ret.add(SERVICE_CATEGORY);
+ ret.add(RESPONSE_SERVICE_NAME);
+ ret.add(RESPONSE_SERVICE_CATEGORY);
return(ret);
}
@@ -189,4 +193,25 @@
prop.setAttribute(VALUE_ATTR, name);
}
}
+
+ /**
+ * This method sets the response service descriptor properties.
+ *
+ * @param category The category
+ * @param name The name
+ */
+ public void setResponseDestination(String category, String name) {
+
+ org.w3c.dom.Element prop=getPropertyElement(RESPONSE_SERVICE_CATEGORY);
+
+ if (prop != null) {
+ prop.setAttribute(VALUE_ATTR, category);
+ }
+
+ prop = getPropertyElement(RESPONSE_SERVICE_NAME);
+
+ if (prop != null) {
+ prop.setAttribute(VALUE_ATTR, name);
+ }
+ }
}
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/actions/stateless/SwitchAction.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/actions/stateless/SwitchAction.java 2009-02-01 19:18:46 UTC (rev 475)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/actions/stateless/SwitchAction.java 2009-02-04 19:58:09 UTC (rev 476)
@@ -256,7 +256,7 @@
*/
public void addCase(String category, String name,
java.util.Set<Interaction> messageTypes, int position) {
-
+ boolean f_associatePath=false;
org.w3c.dom.Element paths=getPropertyElement(PATHS);
org.w3c.dom.Element path=
@@ -264,29 +264,56 @@
path.setAttribute(SERVICE_CATEGORY, category);
path.setAttribute(SERVICE_NAME, name);
- if (messageTypes != null) {
+ if (messageTypes != null && messageTypes.size() > 0) {
java.util.Iterator<Interaction> iter=messageTypes.iterator();
+ boolean f_onlySend=true;
while (iter.hasNext()) {
Interaction interaction=iter.next();
- //TODO: Only deals with single type for now
- if (InteractionUtil.isSend(interaction) == false &&
- interaction.getMessageSignature().getTypes().size()==1) {
- org.w3c.dom.Element mt=
- getAction().getOwnerDocument().createElement(MESSAGE_ELEMENT);
+ if (InteractionUtil.isSend(interaction) == false) {
+ f_onlySend = false;
+
+ //TODO: Only deals with single type for now
+
+ // Only associate message type for requests
+ if (//interaction.getReplyToLabel() == null &&
+ interaction.getMessageSignature().getTypes().size()==1) {
+ org.w3c.dom.Element mt=
+ getAction().getOwnerDocument().createElement(MESSAGE_ELEMENT);
+
+ mt.setAttribute(TYPE_ATTR,
+ InteractionUtil.getTypeString(
+ interaction.getMessageSignature().
+ getTypes().get(0)));
- mt.setAttribute(TYPE_ATTR,
- InteractionUtil.getTypeString(
- interaction.getMessageSignature().
- getTypes().get(0)));
-
- path.appendChild(mt);
+ path.appendChild(mt);
+
+ f_associatePath = true;
+ }
}
}
+
+ if (f_onlySend) {
+ // Associate the path, even though it has no associated
+ // receive interactions, as it represents a path triggered by
+ // a different stimulus. Need this to enable the
+ // conformance checking to understand that it is a
+ // valid path, that needs to be handled.
+ f_associatePath = true;
+ }
+ } else {
+ // Associate the path, even though it has no associated
+ // interactions, as it represents a path triggered by
+ // a different stimulus. Need this to enable the
+ // conformance checking to understand that it is a
+ // valid path, that needs to be handled.
+ f_associatePath = true;
}
- paths.appendChild(path);
+ //if (f_associatePath) {
+ paths.appendChild(path);
+ //}
}
/**
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/change/stateless/ConversationInteractionModelChangeRule.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/change/stateless/ConversationInteractionModelChangeRule.java 2009-02-01 19:18:46 UTC (rev 475)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/change/stateless/ConversationInteractionModelChangeRule.java 2009-02-04 19:58:09 UTC (rev 476)
@@ -156,6 +156,13 @@
action.setDestination("", "");
}
+ if (interaction.getRequestLabel() != null) {
+ ESBService gw=esbModel.getGatewayService();
+
+ action.setResponseDestination(gw.getCategory(),
+ gw.getName());
+ }
+
/* IS REQUIRED??
if (interaction.getRequestLabel() != null) {
Modified: cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/change/stateless/IfModelChangeRule.java
===================================================================
--- cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/change/stateless/IfModelChangeRule.java 2009-02-01 19:18:46 UTC (rev 475)
+++ cdl/trunk/tools/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb/src/java/org/jboss/tools/overlord/cdl/runtime/jbossesb/model/change/stateless/IfModelChangeRule.java 2009-02-04 19:58:09 UTC (rev 476)
@@ -338,10 +338,16 @@
for (int i=0; i < ifElem.getConditionalBlocks().size(); i++) {
ConditionalBlock cb=ifElem.getConditionalBlocks().get(i);
+ java.util.Set<Interaction> interactions=null;
+
+ if (la != null) {
+ interactions = la.getInteractions(cb);
+ }
+
ESBService subService=
esbModel.createService(service.getCategory(),
- esbModel.getUniqueServiceName(service.getCategory(),
- service.getName()));
+ esbModel.getUniqueServiceName(service.getCategory(),
+ service.getName()));
esbModel.addService(subService);
@@ -351,12 +357,6 @@
context.insert(model, cb.getContents().get(j), null);
}
- java.util.Set<Interaction> interactions=null;
-
- if (la != null) {
- interactions = la.getInteractions(cb);
- }
-
switchAction.addCase(subService.getCategory(),
subService.getName(), interactions, i);
15 years, 2 months
Overlord SVN: r475 - in cdl/trunk/distribution/eclipse: features and 1 other directories.
by overlord-commits@lists.jboss.org
Author: objectiser
Date: 2009-02-01 14:18:46 -0500 (Sun, 01 Feb 2009)
New Revision: 475
Added:
cdl/trunk/distribution/eclipse/features/org.jboss.tools.overlord.cdl.jbossesb.feature_1.0.0.200902011914.jar
cdl/trunk/distribution/eclipse/features/org.scribble.conversation.feature_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/features/org.scribble.experimental.feature_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/features/org.scribble.feature_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/features/org.scribble.java.feature_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/features/org.scribble.protocol.feature_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb_1.0.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.jboss.tools.overlord.cdl.validator.jbossesb_1.0.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conformance_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.comparator_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.export.text_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.model_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.parser_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.projector_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.validation_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.core_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.designer_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.comparator_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.java.parser_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.model_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.osgi_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.comparator_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.export.text_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.model_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.parser_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.projector_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.validation_0.1.0.200902011914.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.type.java.parser_0.1.0.200902011914.jar
Removed:
cdl/trunk/distribution/eclipse/features/org.jboss.tools.overlord.cdl.jbossesb.feature_1.0.0.200901132140.jar
cdl/trunk/distribution/eclipse/features/org.scribble.conversation.feature_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/features/org.scribble.experimental.feature_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/features/org.scribble.feature_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/features/org.scribble.java.feature_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/features/org.scribble.protocol.feature_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb_1.0.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.jboss.tools.overlord.cdl.validator.jbossesb_1.0.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conformance_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.comparator_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.export.text_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.model_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.parser_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.projector_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.validation_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.core_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.designer_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.comparator_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.java.parser_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.model_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.osgi_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.comparator_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.export.text_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.model_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.parser_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.projector_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.validation_0.1.0.200901132140.jar
cdl/trunk/distribution/eclipse/plugins/org.scribble.type.java.parser_0.1.0.200901132140.jar
Modified:
cdl/trunk/distribution/eclipse/site.xml
Log:
Update the plugins.
Deleted: cdl/trunk/distribution/eclipse/features/org.jboss.tools.overlord.cdl.jbossesb.feature_1.0.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/features/org.jboss.tools.overlord.cdl.jbossesb.feature_1.0.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/features/org.jboss.tools.overlord.cdl.jbossesb.feature_1.0.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/features/org.scribble.conversation.feature_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/features/org.scribble.conversation.feature_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/features/org.scribble.conversation.feature_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/features/org.scribble.experimental.feature_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/features/org.scribble.experimental.feature_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/features/org.scribble.experimental.feature_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/features/org.scribble.feature_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/features/org.scribble.feature_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/features/org.scribble.feature_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/features/org.scribble.java.feature_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/features/org.scribble.java.feature_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/features/org.scribble.java.feature_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/features/org.scribble.protocol.feature_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/features/org.scribble.protocol.feature_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/features/org.scribble.protocol.feature_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb_1.0.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb_1.0.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.jboss.tools.overlord.cdl.runtime.jbossesb_1.0.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.jboss.tools.overlord.cdl.validator.jbossesb_1.0.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.jboss.tools.overlord.cdl.validator.jbossesb_1.0.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.jboss.tools.overlord.cdl.validator.jbossesb_1.0.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.conformance_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.conformance_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.conformance_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.comparator_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.comparator_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.comparator_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.export.text_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.export.text_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.export.text_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.model_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.model_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.model_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.parser_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.parser_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.parser_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.projector_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.projector_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.projector_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.validation_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.validation_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.conversation.validation_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.core_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.core_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.core_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.designer_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.designer_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.designer_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.comparator_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.comparator_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.comparator_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.java.parser_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.java.parser_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.java.parser_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.model_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.model_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.lang.model_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.osgi_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.osgi_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.osgi_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.comparator_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.comparator_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.comparator_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.export.text_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.export.text_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.export.text_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.model_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.model_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.model_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.parser_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.parser_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.parser_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.projector_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.projector_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.projector_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.validation_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.validation_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.protocol.validation_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: cdl/trunk/distribution/eclipse/plugins/org.scribble.type.java.parser_0.1.0.200901132140.jar
===================================================================
(Binary files differ)
Added: cdl/trunk/distribution/eclipse/plugins/org.scribble.type.java.parser_0.1.0.200902011914.jar
===================================================================
(Binary files differ)
Property changes on: cdl/trunk/distribution/eclipse/plugins/org.scribble.type.java.parser_0.1.0.200902011914.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Modified: cdl/trunk/distribution/eclipse/site.xml
===================================================================
--- cdl/trunk/distribution/eclipse/site.xml 2009-02-01 18:28:52 UTC (rev 474)
+++ cdl/trunk/distribution/eclipse/site.xml 2009-02-01 19:18:46 UTC (rev 475)
@@ -1,21 +1,21 @@
<?xml version="1.0" encoding="UTF-8"?>
<site>
- <feature url="features/org.scribble.conversation.feature_0.1.0.200901132140.jar" id="org.scribble.conversation.feature" version="0.1.0.200901132140">
+ <feature url="features/org.scribble.conversation.feature_0.1.0.200902011914.jar" id="org.scribble.conversation.feature" version="0.1.0.200902011914">
<category name="Common"/>
</feature>
- <feature url="features/org.scribble.experimental.feature_0.1.0.200901132140.jar" id="org.scribble.experimental.feature" version="0.1.0.200901132140">
+ <feature url="features/org.scribble.experimental.feature_0.1.0.200902011914.jar" id="org.scribble.experimental.feature" version="0.1.0.200902011914">
<category name="Common"/>
</feature>
- <feature url="features/org.scribble.feature_0.1.0.200901132140.jar" id="org.scribble.feature" version="0.1.0.200901132140">
+ <feature url="features/org.scribble.feature_0.1.0.200902011914.jar" id="org.scribble.feature" version="0.1.0.200902011914">
<category name="Common"/>
</feature>
- <feature url="features/org.scribble.java.feature_0.1.0.200901132140.jar" id="org.scribble.java.feature" version="0.1.0.200901132140">
+ <feature url="features/org.scribble.java.feature_0.1.0.200902011914.jar" id="org.scribble.java.feature" version="0.1.0.200902011914">
<category name="Common"/>
</feature>
- <feature url="features/org.scribble.protocol.feature_0.1.0.200901132140.jar" id="org.scribble.protocol.feature" version="0.1.0.200901132140">
+ <feature url="features/org.scribble.protocol.feature_0.1.0.200902011914.jar" id="org.scribble.protocol.feature" version="0.1.0.200902011914">
<category name="Common"/>
</feature>
- <feature url="features/org.jboss.tools.overlord.cdl.jbossesb.feature_1.0.0.200901132140.jar" id="org.jboss.tools.overlord.cdl.jbossesb.feature" version="1.0.0.200901132140">
+ <feature url="features/org.jboss.tools.overlord.cdl.jbossesb.feature_1.0.0.200902011914.jar" id="org.jboss.tools.overlord.cdl.jbossesb.feature" version="1.0.0.200902011914">
<category name="JBossESB"/>
</feature>
<category-def name="JBossESB" label="JBossESB">
15 years, 2 months