Added: servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/java/org/apache/servicemix/osworkflow/functions/AnswerExampleFunction.java URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/java/org/apache/servicemix/osworkflow/functions/AnswerExampleFunction.java?rev=631361&view=auto ============================================================================== --- servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/java/org/apache/servicemix/osworkflow/functions/AnswerExampleFunction.java (added) +++ servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/java/org/apache/servicemix/osworkflow/functions/AnswerExampleFunction.java Tue Feb 26 11:49:43 2008 @@ -0,0 +1,93 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.servicemix.osworkflow.functions; + +import java.util.Map; + +import javax.jbi.messaging.MessageExchange; +import javax.jbi.messaging.NormalizedMessage; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.servicemix.jbi.jaxp.StringSource; +import org.apache.servicemix.osworkflow.OSWorkflow; +import org.apache.servicemix.osworkflow.OSWorkflowEndpoint; + +import com.opensymphony.module.propertyset.PropertySet; +import com.opensymphony.workflow.FunctionProvider; +import com.opensymphony.workflow.WorkflowException; + +/** + * @author lhe + */ +public class AnswerExampleFunction implements FunctionProvider { + + private static Log logger = LogFactory.getLog(AnswerExampleFunction.class); + + /* + * (non-Javadoc) + * + * @see com.opensymphony.workflow.FunctionProvider#execute(java.util.Map, + * java.util.Map, com.opensymphony.module.propertyset.PropertySet) + */ + public void execute(Map transientVars, Map args, PropertySet propertySet) + throws WorkflowException { + OSWorkflowEndpoint ep = null; + boolean isAsynchron = false; + MessageExchange exchange = null; + + if (transientVars.containsKey(OSWorkflow.KEY_ENDPOINT)) { + ep = (OSWorkflowEndpoint) transientVars + .get(OSWorkflow.KEY_ENDPOINT); + } else { + throw new WorkflowException( + "AnswerExampleFunction: Missing transient variable for endpoint object. (" + + OSWorkflow.KEY_ENDPOINT + ")"); + } + + if (transientVars.containsKey(OSWorkflow.KEY_ASYNC_PROCESSING)) { + isAsynchron = (Boolean) transientVars + .get(OSWorkflow.KEY_ASYNC_PROCESSING); + } else { + throw new WorkflowException( + "AnswerExampleFunction: Missing transient variable for async object. (" + + OSWorkflow.KEY_ASYNC_PROCESSING + ")"); + } + + if (transientVars.containsKey(OSWorkflow.KEY_EXCHANGE)) { + exchange = (MessageExchange) transientVars + .get(OSWorkflow.KEY_EXCHANGE); + } else { + throw new WorkflowException( + "AnswerExampleFunction: Missing transient variable for exchange object. (" + + OSWorkflow.KEY_EXCHANGE + ")"); + } + + if (!isAsynchron) { + try { + NormalizedMessage msg = exchange.createMessage(); + msg.setContent(new StringSource( + "<example>Test passed!</example>")); + exchange.setMessage(msg, "out"); + ep.send(exchange, false); + } catch (Exception ex) { + throw new WorkflowException( + "AnswerExampleFunction: Unable to answer request.", ex); + } + } + } +}
Added: servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/java/org/apache/servicemix/osworkflow/functions/ExampleFunction.java URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/java/org/apache/servicemix/osworkflow/functions/ExampleFunction.java?rev=631361&view=auto ============================================================================== --- servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/java/org/apache/servicemix/osworkflow/functions/ExampleFunction.java (added) +++ servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/java/org/apache/servicemix/osworkflow/functions/ExampleFunction.java Tue Feb 26 11:49:43 2008 @@ -0,0 +1,128 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.servicemix.osworkflow.functions; + +import java.util.Map; + +import javax.jbi.messaging.MessageExchange; +import javax.jbi.messaging.MessagingException; +import javax.jbi.messaging.NormalizedMessage; +import javax.xml.transform.dom.DOMSource; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.servicemix.jbi.jaxp.SourceTransformer; +import org.apache.servicemix.osworkflow.OSWorkflow; +import org.apache.servicemix.osworkflow.OSWorkflowEndpoint; +import org.apache.xpath.CachedXPathAPI; +import org.w3c.dom.Node; + +import com.opensymphony.module.propertyset.PropertySet; +import com.opensymphony.workflow.FunctionProvider; +import com.opensymphony.workflow.WorkflowException; + +public class ExampleFunction implements FunctionProvider { + + private static Log logger = LogFactory.getLog(ExampleFunction.class); + + /* + * (non-Javadoc) + * + * @see com.opensymphony.workflow.FunctionProvider#execute(java.util.Map, + * java.util.Map, com.opensymphony.module.propertyset.PropertySet) + */ + public void execute(Map transientVars, Map args, PropertySet propertySet) + throws WorkflowException { + + logger.info("Executing function..."); + + NormalizedMessage msg = null; + OSWorkflowEndpoint ep = null; + boolean isAsynchron = false; + MessageExchange exchange = null; + + if (transientVars.containsKey(OSWorkflow.KEY_ASYNC_PROCESSING)) { + isAsynchron = (Boolean) transientVars + .get(OSWorkflow.KEY_ASYNC_PROCESSING); + } else { + throw new WorkflowException( + "ExampleFunction: Missing transient variable for async object. (" + + OSWorkflow.KEY_ASYNC_PROCESSING + ")"); + } + + if (transientVars.containsKey(OSWorkflow.KEY_EXCHANGE)) { + exchange = (MessageExchange) transientVars + .get(OSWorkflow.KEY_EXCHANGE); + } else { + throw new WorkflowException( + "ExampleFunction: Missing transient variable for exchange object. (" + + OSWorkflow.KEY_EXCHANGE + ")"); + } + + if (transientVars.containsKey(OSWorkflow.KEY_IN_MESSAGE)) { + msg = (NormalizedMessage) transientVars + .get(OSWorkflow.KEY_IN_MESSAGE); + } else { + throw new WorkflowException( + "ExampleFunction: Missing transient variable for message object. (" + + OSWorkflow.KEY_IN_MESSAGE + ")"); + } + + if (transientVars.containsKey(OSWorkflow.KEY_ENDPOINT)) { + ep = (OSWorkflowEndpoint) transientVars + .get(OSWorkflow.KEY_ENDPOINT); + } else { + throw new WorkflowException( + "ExampleFunction: Missing transient variable for endpoint object. (" + + OSWorkflow.KEY_ENDPOINT + ")"); + } + + SourceTransformer sourceTransformer = new SourceTransformer(); + + try { + DOMSource inMessageXml = (DOMSource) sourceTransformer + .toDOMSource(msg.getContent()); + + // Parse out the actual message content + CachedXPathAPI xpath = new CachedXPathAPI(); + + Node exampleNode = xpath.selectSingleNode(inMessageXml.getNode(), + "/example"); + + if (exampleNode != null) { + String value = exampleNode.getTextContent(); + logger.info("Received content: " + value); + propertySet.setString("ExampleKey", value); + } else { + throw new WorkflowException( + "ExampleFunction: Missing tag: example"); + } + } catch (Exception ex) { + throw new WorkflowException(ex); + } finally { + // if the exchange came as asynchronous inOnly or RobustInOnly + // we will now send a receipt to the sender + try { + if (isAsynchron) { + ep.done(exchange); + } + } catch (MessagingException mex) { + throw new WorkflowException(mex); + } + } + } +} Added: servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/java/org/apache/servicemix/osworkflow/functions/FailExampleFunction.java URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/java/org/apache/servicemix/osworkflow/functions/FailExampleFunction.java?rev=631361&view=auto ============================================================================== --- servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/java/org/apache/servicemix/osworkflow/functions/FailExampleFunction.java (added) +++ servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/java/org/apache/servicemix/osworkflow/functions/FailExampleFunction.java Tue Feb 26 11:49:43 2008 @@ -0,0 +1,93 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.servicemix.osworkflow.functions; + +import java.util.Map; + +import javax.jbi.messaging.MessageExchange; +import javax.jbi.messaging.NormalizedMessage; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.servicemix.jbi.jaxp.StringSource; +import org.apache.servicemix.osworkflow.OSWorkflow; +import org.apache.servicemix.osworkflow.OSWorkflowEndpoint; + +import com.opensymphony.module.propertyset.PropertySet; +import com.opensymphony.workflow.FunctionProvider; +import com.opensymphony.workflow.WorkflowException; + +/** + * @author lhe + */ +public class FailExampleFunction implements FunctionProvider { + + private static Log logger = LogFactory.getLog(FailExampleFunction.class); + + /* + * (non-Javadoc) + * + * @see com.opensymphony.workflow.FunctionProvider#execute(java.util.Map, + * java.util.Map, com.opensymphony.module.propertyset.PropertySet) + */ + public void execute(Map transientVars, Map args, PropertySet propertySet) + throws WorkflowException { + OSWorkflowEndpoint ep = null; + boolean isAsynchron = false; + MessageExchange exchange = null; + + if (transientVars.containsKey(OSWorkflow.KEY_ENDPOINT)) { + ep = (OSWorkflowEndpoint) transientVars + .get(OSWorkflow.KEY_ENDPOINT); + } else { + throw new WorkflowException( + "FailExampleFunction: Missing transient variable for endpoint object. (" + + OSWorkflow.KEY_ENDPOINT + ")"); + } + + if (transientVars.containsKey(OSWorkflow.KEY_ASYNC_PROCESSING)) { + isAsynchron = (Boolean) transientVars + .get(OSWorkflow.KEY_ASYNC_PROCESSING); + } else { + throw new WorkflowException( + "FailExampleFunction: Missing transient variable for async object. (" + + OSWorkflow.KEY_ASYNC_PROCESSING + ")"); + } + + if (transientVars.containsKey(OSWorkflow.KEY_EXCHANGE)) { + exchange = (MessageExchange) transientVars + .get(OSWorkflow.KEY_EXCHANGE); + } else { + throw new WorkflowException( + "FailExampleFunction: Missing transient variable for exchange object. (" + + OSWorkflow.KEY_EXCHANGE + ")"); + } + + if (!isAsynchron) { + try { + NormalizedMessage msg = exchange.createMessage(); + msg.setContent(new StringSource( + "<example>Error Case Test passed!</example>")); + exchange.setMessage(msg, "out"); + ep.send(exchange, false); + } catch (Exception ex) { + throw new WorkflowException( + "FailExampleFunction: Unable to answer request.", ex); + } + } + } +} Added: servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/exampleflow.xml URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/exampleflow.xml?rev=631361&view=auto ============================================================================== --- servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/exampleflow.xml (added) +++ servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/exampleflow.xml Tue Feb 26 11:49:43 2008 @@ -0,0 +1,116 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +--> +<!DOCTYPE workflow PUBLIC + "-//OpenSymphony Group//DTD OSWorkflow 2.8//EN" + "http://www.opensymphony.com/osworkflow/workflow_2_8.dtd"> +<workflow> + + <initial-actions> + <action id="1" name="Start Workflow"> + <results> + <unconditional-result old-status="Finished" status="Queued" step="1"/> + </results> + </action> + </initial-actions> + + <steps> + + <step id="1" name="Example Step"> + <actions> + + <action id="2" name="Examine Message Exchange"> + <restrict-to> + <conditions> + <condition type="class"> + <arg name="class.name"> + com.opensymphony.workflow.util.StatusCondition </arg> + <arg name="status">Queued</arg> + </condition> + </conditions> + </restrict-to> + + <pre-functions> + <function type="class"> + <arg name="class.name"> org.apache.servicemix.osworkflow.functions.ExampleFunction </arg> + </function> + </pre-functions> + + <results> + <unconditional-result old-status="Finished" status="Examined" step="-1"/> + </results> + </action> + + <action id="3" name="Answer Example"> + <restrict-to> + <conditions type="AND"> + <condition type="class"> + <arg name="class.name"> + com.opensymphony.workflow.util.StatusCondition </arg> + <arg name="status">Examined</arg> + </condition> + <condition type="class"> + <arg name="class.name"> + org.apache.servicemix.osworkflow.conditions.ExampleCondition </arg> + </condition> + </conditions> + </restrict-to> + + <pre-functions> + <function type="class"> + <arg name="class.name"> org.apache.servicemix.osworkflow.functions.AnswerExampleFunction </arg> + </function> + </pre-functions> + + <results> + <unconditional-result old-status="Finished" status="Evaluated" step="2"/> + </results> + + </action> + + <action id="4" name="Fail Example"> + <restrict-to> + <conditions> + <condition type="class"> + <arg name="class.name"> + com.opensymphony.workflow.util.StatusCondition </arg> + <arg name="status">Examined</arg> + </condition> + </conditions> + </restrict-to> + + <pre-functions> + <function type="class"> + <arg name="class.name"> org.apache.servicemix.osworkflow.functions.FailExampleFunction </arg> + </function> + </pre-functions> + + <results> + <unconditional-result old-status="Finished" status="Evaluated" step="2"/> + </results> + + </action> + + </actions> + </step> + + <step id="2" name="finished" /> + + </steps> +</workflow> Added: servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/log4j-tests.properties URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/log4j-tests.properties?rev=631361&view=auto ============================================================================== --- servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/log4j-tests.properties (added) +++ servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/log4j-tests.properties Tue Feb 26 11:49:43 2008 @@ -0,0 +1,42 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or +# implied. +# +# See the License for the specific language governing permissions and +# limitations under the License. +# +# + +# +# The logging properties used during tests.. +# +log4j.rootLogger=DEBUG, out + +log4j.logger.org.springframework=INFO +log4j.logger.org.apache.activemq=INFO +log4j.logger.org.apache.activemq.spring=WARN +log4j.logger.org.apache.activemq.store.journal=INFO +log4j.logger.org.activeio.journal=INFO + +# CONSOLE appender not used by default +log4j.appender.stdout=org.apache.log4j.ConsoleAppender +log4j.appender.stdout.layout=org.apache.log4j.PatternLayout +log4j.appender.stdout.layout.ConversionPattern=%d [%-15.15t] %-5p %-30.30c{1} - %m%n + +# File appender +log4j.appender.out=org.apache.log4j.FileAppender +log4j.appender.out.layout=org.apache.log4j.PatternLayout +log4j.appender.out.layout.ConversionPattern=%d [%-15.15t] %-5p %-30.30c{1} - %m%n +log4j.appender.out.file=target/servicemix-test.log +log4j.appender.out.append=true Added: servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/log4j.properties URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/log4j.properties?rev=631361&view=auto ============================================================================== --- servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/log4j.properties (added) +++ servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/log4j.properties Tue Feb 26 11:49:43 2008 @@ -0,0 +1,41 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or +# implied. +# +# See the License for the specific language governing permissions and +# limitations under the License. +# +# + +# +# The logging properties used during tests.. +# +log4j.rootLogger=INFO, stdout + +log4j.logger.org.springframework=INFO +log4j.logger.org.apache.activemq=INFO +log4j.logger.org.apache.activemq.spring=WARN +log4j.logger.org.apache.servicemix=DEBUG + +# CONSOLE appender +log4j.appender.stdout=org.apache.log4j.ConsoleAppender +log4j.appender.stdout.layout=org.apache.log4j.PatternLayout +log4j.appender.stdout.layout.ConversionPattern=%d [%-15.15t] %-5p %-30.30c{1} - %m%n + +# File appender +log4j.appender.out=org.apache.log4j.FileAppender +log4j.appender.out.layout=org.apache.log4j.PatternLayout +log4j.appender.out.layout.ConversionPattern=%d [%-15.15t] %-5p %-30.30c{1} - %m%n +log4j.appender.out.file=target/servicemix-test.log +log4j.appender.out.append=true Added: servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/osworkflow.xml URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/osworkflow.xml?rev=631361&view=auto ============================================================================== --- servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/osworkflow.xml (added) +++ servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/osworkflow.xml Tue Feb 26 11:49:43 2008 @@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +--> +<osworkflow> + <persistence class="com.opensymphony.workflow.spi.memory.MemoryWorkflowStore"/> + <factory class="com.opensymphony.workflow.loader.XMLWorkflowFactory"> + <property key="resource" value="workflows.xml" /> + </factory> +</osworkflow> \ No newline at end of file Added: servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/spring.xml URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/spring.xml?rev=631361&view=auto ============================================================================== --- servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/spring.xml (added) +++ servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/spring.xml Tue Feb 26 11:49:43 2008 @@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +--> +<beans xmlns:sm="http://servicemix.apache.org/config/1.0" + xmlns:my="http://servicemix.apache.org/osworkflow/1.0" + xmlns:test="urn:test"> + + <sm:container id="jbi" embedded="true" createMBeanServer="false"> + + <sm:activationSpecs> + + <sm:activationSpec> + <sm:component> + <my:component> + <my:endpoints> + <my:endpoint service="test:service" endpoint="endpoint" action="1" caller="testUser" workflowName="exampleflow"/> + </my:endpoints> + </my:component> + </sm:component> + </sm:activationSpec> + + </sm:activationSpecs> + </sm:container> + +</beans> \ No newline at end of file Added: servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/workflows.xml URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/workflows.xml?rev=631361&view=auto ============================================================================== --- servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/workflows.xml (added) +++ servicemix/smx3/trunk/deployables/serviceengines/servicemix-osworkflow/src/test/resources/workflows.xml Tue Feb 26 11:49:43 2008 @@ -0,0 +1,22 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +--> +<workflows> + <workflow name="exampleflow" type="resource" location="exampleflow.xml"/> +</workflows> \ No newline at end of file Modified: servicemix/smx3/trunk/distributions/apache-servicemix/pom.xml URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/distributions/apache-servicemix/pom.xml?rev=631361&r1=631360&r2=631361&view=diff ============================================================================== --- servicemix/smx3/trunk/distributions/apache-servicemix/pom.xml (original) +++ servicemix/smx3/trunk/distributions/apache-servicemix/pom.xml Tue Feb 26 11:49:43 2008 @@ -78,6 +78,10 @@ </dependency> <dependency> <groupId>org.apache.servicemix</groupId> + <artifactId>servicemix-osworkflow</artifactId> + </dependency> + <dependency> + <groupId>org.apache.servicemix</groupId> <artifactId>servicemix-wsn2005</artifactId> </dependency> <dependency> @@ -387,6 +391,13 @@ <artifactItem> <groupId>org.apache.servicemix</groupId> <artifactId>servicemix-jsr181</artifactId> + <version>${servicemix-version}</version> + <classifier>installer</classifier> + <type>zip</type> + </artifactItem> + <artifactItem> + <groupId>org.apache.servicemix</groupId> + <artifactId>servicemix-osworkflow</artifactId> <version>${servicemix-version}</version> <classifier>installer</classifier> <type>zip</type> Modified: servicemix/smx3/trunk/distributions/apache-servicemix/src/main/release/bin/smx-arch URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/distributions/apache-servicemix/src/main/release/bin/smx-arch?rev=631361&r1=631360&r2=631361&view=diff ============================================================================== --- servicemix/smx3/trunk/distributions/apache-servicemix/src/main/release/bin/smx-arch (original) +++ servicemix/smx3/trunk/distributions/apache-servicemix/src/main/release/bin/smx-arch Tue Feb 26 11:49:43 2008 @@ -77,7 +77,7 @@ echo " jms-consumer, jms-provider," echo " ftp-poller, ftp-sender," echo " jsr181-annotated, jsr181-wsdl-first," - echo " saxon-xquery, saxon-xslt," + echo " saxon-xquery, saxon-xslt, osworkflow," echo " eip, lwcontainer, bean, ode, camel" echo " cxf-se, cxf-bc" echo "Optional arguments:" Modified: servicemix/smx3/trunk/distributions/apache-servicemix/src/main/release/bin/smx-arch.bat URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/distributions/apache-servicemix/src/main/release/bin/smx-arch.bat?rev=631361&r1=631360&r2=631361&view=diff ============================================================================== --- servicemix/smx3/trunk/distributions/apache-servicemix/src/main/release/bin/smx-arch.bat (original) +++ servicemix/smx3/trunk/distributions/apache-servicemix/src/main/release/bin/smx-arch.bat Tue Feb 26 11:49:43 2008 @@ -48,7 +48,7 @@ echo jms-consumer, jms-provider, echo ftp-poller, ftp-sender, echo jsr181-annotated, jsr181-wsdl-first, -echo saxon-xquery, saxon-xslt, +echo saxon-xquery, saxon-xslt, osworkflow, echo eip, lwcontainer, bean, ode, camel echo cxf-se, cxf-bc echo Optional arguments: Modified: servicemix/smx3/trunk/pom.xml URL: http://svn.apache.org/viewvc/servicemix/smx3/trunk/pom.xml?rev=631361&r1=631360&r2=631361&view=diff ============================================================================== --- servicemix/smx3/trunk/pom.xml (original) +++ servicemix/smx3/trunk/pom.xml Tue Feb 26 11:49:43 2008 @@ -734,6 +734,11 @@ </dependency> <dependency> <groupId>org.apache.servicemix</groupId> + <artifactId>servicemix-osworkflow</artifactId> + <version>3.3-SNAPSHOT</version> + </dependency> + <dependency> + <groupId>org.apache.servicemix</groupId> <artifactId>servicemix-sca</artifactId> <version>3.3-SNAPSHOT</version> </dependency>
