Jump to: navigation, search

SMILA/Documentation/Pipelets

This page describes pipelets and their lifecycle.

Definition

Pipelets are reusable Java Components in a BPEL workflow and can be orchestrated like any regular BPEL Service. They are used to process the data contained in records.

A pipelet is a POJO that implements the interface org.eclipse.smila.processing.SimplePipelet. Its lifecycle and configuration are managed by the workflow engine. An instance of a pipelet is not shared by multiple pipelines (workflows), even multiple invocations of a pipelet in the same pipeline do not share the same instance. Each <invokePipelet> pipeline has its own instance. An instance may still be accessed by multiple threads, for example if the same pipeline is executed in parallel. The configuration of each pipelet instance is included in the <invokePipelet> call in the BPEL pipeline. Technical details on pipelet development can be found in How to write a Pipelet.

Lifecycle

The following diagram shows the lifecycle of pipelets.

Lifecycle of Pipelets.png

Pipelets live inside the workflow engine. When the engine starts, it reads the pipeline definitions (i.e. BPEL workflows) from the ConfigurationHelper. The pipelines are introspected for pipelet invocations (invokePipelet extension activities) and the pipelet configurations that are contained in the invocation XML elements. For each invocation it creates an instance of the specified pipelet class, parses the configuration from the BPEL document and injects it into the pipelet instance. The pipelet instance is stored in the workflow engine as long as the engine is not stopped (and as long as the bundle providing the pipelet is available, of course). So for each single pipelet invocation occurring in the pipelines a different pipelet instance exists with a single configuration.