org.mule.api.annotations
Annotation Type Source


@Target(value=METHOD)
@Retention(value=SOURCE)
@Documented
public @interface Source

This annotation marks a method inside a Connector as a callable from within a Mule flow and capable of generating Mule events. Each marked method will have a org.mule.api.source.MessageSource generated.

The method must receive a org.mule.api.callback.SourceCallback as one of its arguments. It does not matter which parameter it is as long it is there.


Optional Element Summary
 String friendlyName
          A user-friendly name for this processor.
 String name
          The xml name of the element that will invoke this source.
 long pollingPeriod
          Polling period for SourceStrategy.POLLING.
 boolean primaryNodeOnly
          Does this message source must run on all cluster nodes, or just the primary one?
 SourceStrategy sourceStrategy
          Message Source Strategy
 SourceThreadingModel threadingModel
          Threading model
 

name

public abstract String name
The xml name of the element that will invoke this source. This is optional and if it is not specified a name will be derived from the name of the method.

Default:
""

friendlyName

public abstract String friendlyName
A user-friendly name for this processor.

Default:
""

primaryNodeOnly

public abstract boolean primaryNodeOnly
Does this message source must run on all cluster nodes, or just the primary one?

Default:
false

threadingModel

public abstract SourceThreadingModel threadingModel
Threading model

Default:
org.mule.api.annotations.SourceThreadingModel.SINGLE_THREAD

sourceStrategy

public abstract SourceStrategy sourceStrategy
Message Source Strategy

Default:
org.mule.api.annotations.SourceStrategy.NONE

pollingPeriod

public abstract long pollingPeriod
Polling period for SourceStrategy.POLLING.

Default:
-1L


Copyright © 2010–2015 MuleSoft, Inc.. All rights reserved.