Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "SMILA/Documentation/QueueWorker/Router"

(New page: == What is Router== The main goal of Router is to put Record into JMS queue but it also make any Queue Worker specific tasks like executing BPEL piplen...)
 
Line 23: Line 23:
  
 
Configuration is a list of routing rules.
 
Configuration is a list of routing rules.
 +
  
 
== Configuration Sample==
 
== Configuration Sample==
Line 51: Line 52:
 
</RouterConfig>
 
</RouterConfig>
 
</source>
 
</source>
 +
 +
== Tasks ==
 +
<source lang="xml">
 +
<Synchronize Filter="no-filter"/>
 +
</source>
 +
Executes synchronization of Record with Blackboard service. Optional Filter attribute point that Record should be filtered before next step.
 +
 +
<source lang="xml">
 +
  <Process Workflow="AddPipeline"/>
 +
</source>
 +
Executes BPEL pipeline.
 +
 +
<source lang="xml">
 +
<Send BrokerId="broker1" Queue="EILF.connectivity">
 +
  <SetProperty Name="doSomething">really do something</SetProperty>
 +
</Send>
 +
</source>
 +
Send Record to JMS queue. Broker connection with correspondent BrokerID should be specified in [[SMILA/Documentation/QueueWorker/BrokerConnectionService|Broker Connection Service]] configuration
  
 
[[Category:SMILA]]
 
[[Category:SMILA]]

Revision as of 10:15, 20 August 2008

What is Router

The main goal of Router is to put Record into JMS queue but it also make any Queue Worker specific tasks like executing BPEL piplene.

Interface

public enum Operation { 
  ADD,
  DELETE,
  NONE
}
public interface Router extends QueueWorker {
  void route(Record record, Operation operation) throws RouterException;
}

Configuration

Schema:org.eclipse.eilf.connectivity.queue.worker/schemas/QueueWorkerConfig.xsd

Configuration is a list of routing rules.


Configuration Sample

<RouterConfig xmlns="http://www.eclipse.org/eilf/queue"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:noNamespaceSchemaLocation="schemas/QueueWorkerConfig.xsd"
>
 
  <Rule Name="Default ADD Rule">
    <Condition>Operation='ADD'</Condition>
    <Task>
      <Synchronize Filter="only-attributes"/>
      <Send BrokerId="broker1" Queue="EILF.connectivity"/>
    </Task>
  </Rule>
 
  <Rule Name="Default DELETE Rule">
    <Condition>Operation='DELETE'</Condition>
    <Task>
      <Synchronize Filter="no-filter"/>
      <Send BrokerId="broker1" Queue="EILF.connectivity">
        <SetProperty Name="doSomething">really do something</SetProperty>
      </Send>
    </Task>
  </Rule>
 
</RouterConfig>

Tasks

 <Synchronize Filter="no-filter"/>

Executes synchronization of Record with Blackboard service. Optional Filter attribute point that Record should be filtered before next step.

  <Process Workflow="AddPipeline"/>

Executes BPEL pipeline.

 <Send BrokerId="broker1" Queue="EILF.connectivity">
   <SetProperty Name="doSomething">really do something</SetProperty>
 </Send>

Send Record to JMS queue. Broker connection with correspondent BrokerID should be specified in Broker Connection Service configuration

Back to the top