|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.apama.services.scenario.ScenarioServiceConfig
public class ScenarioServiceConfig
ScenarioServiceConfig is a helper class that assists in building a properies map for use when creating a new ScenarioService via the ScenarioServiceFactory.
Note that EventServiceChannel configuration properties are also valid configuration properties for a ScenarioService, and will be applied to any channel created by the ScenarioService.
Any configuration property not explicitly specified will take its default value. Defaults are available for all configuration properties, in the same interface as the property.
ChannelConfig
Method Summary | |
---|---|
static void |
setAckDataTimeout(java.util.Map<java.lang.String,java.lang.Object> properties,
long timeout)
Set the timeout for operations to wait for the Data channel to catch up. |
static void |
setAutoInstanceDiscovery(java.util.Map<java.lang.String,java.lang.Object> properties,
boolean autoInstanceDiscovery)
Set the boolean configuration property to indicate if the service should discover instances automatically. |
static void |
setDisconnectIfSlow(java.util.Map<java.lang.String,java.lang.Object> properties,
boolean disconnectIfSlow)
Set the boolean configuration property to indicate if our event receiver should be disconnected if slow. |
static void |
setReconnectPeriod(java.util.Map<java.lang.String,java.lang.Object> properties,
long time)
Set the float configuration property to indicate how long to wait between reconections |
static void |
setScenarioExclusionFilter(java.util.Map<java.lang.String,java.lang.Object> properties,
java.util.Set<java.lang.String> scenarioExclusionFilter)
Set the configuration property to the Set of ScenarioID's that the client wishes to ignore. |
static void |
setScenarioInclusionFilter(java.util.Map<java.lang.String,java.lang.Object> properties,
java.util.Set<java.lang.String> scenarioInclusionFilter)
Set the configuration property to the Set of ScenarioID's in which the client is interested. |
static void |
setStrongDataInboundEventQueue(java.util.Map<java.lang.String,java.lang.Object> properties,
boolean strong)
Set the boolean configuration property to indicate if the 'Data' channels (EventServiceChannel's), created for listening to scenario instance output variable updates, should use strong or soft references to events in the inbound event queue. |
static void |
setUseRawDataChannel(java.util.Map<java.lang.String,java.lang.Object> properties,
boolean useRawData)
Set the boolean configuration property to indicate if the 'Data' channels (EventServiceChannel's), created for listening to scenario instance output variable updates, should be subscribed to the normal Data channel (possibly throttled), or the Raw Data channel (always unthrottled). |
static void |
setUsernameFilter(java.util.Map<java.lang.String,java.lang.Object> properties,
java.lang.String owner)
Set the configuration property to filter by a given user If present, the scenario(s) listened for must have the ConfigureUpdates property sendRawUser or sendThrottledUser set to true. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static void setScenarioInclusionFilter(java.util.Map<java.lang.String,java.lang.Object> properties, java.util.Set<java.lang.String> scenarioInclusionFilter)
properties
- The Map in which the configuration properties should be updated.scenarioInclusionFilter
- The new value of the property.IScenarioService.CONFIG_SCENARIO_INCLUSION_FILTER
,
IScenarioService.DEFAULT_SCENARIO_INCLUSION_FILTER
,
setScenarioExclusionFilter(Map, Set)
public static void setScenarioExclusionFilter(java.util.Map<java.lang.String,java.lang.Object> properties, java.util.Set<java.lang.String> scenarioExclusionFilter)
properties
- The Map in which the configuration properties should be updated.scenarioExclusionFilter
- The new value of the property.IScenarioService.CONFIG_SCENARIO_EXCLUSION_FILTER
,
IScenarioService.DEFAULT_SCENARIO_EXCLUSION_FILTER
,
setScenarioInclusionFilter(Map, Set)
public static void setStrongDataInboundEventQueue(java.util.Map<java.lang.String,java.lang.Object> properties, boolean strong)
Note that this property would apply ONLY to 'Data' channels, and not to
any other channels. For 'Data' channels, this setting overrides
IEventServiceChannel.CONFIG_INBOUND_EVENT_QUEUE_SOFT_REFERENCE_PREFIXES
.
properties
- The Map in which the configuration properties should be updated.strong
- The new value of the property.IScenarioService.CONFIG_STRONG_DATA_INBOUND_EVENT_QUEUE
,
IScenarioService.DEFAULT_STRONG_DATA_INBOUND_EVENT_QUEUE
public static void setUseRawDataChannel(java.util.Map<java.lang.String,java.lang.Object> properties, boolean useRawData)
The event throttling mechanism is global within a correlator, so if the throttling mechanism is used, all scenarios will emit throttled output variable updates on the normal Data channel. However, for some applications the complete (unthrottled) output is required. For this reason, there is also a 'Raw' output channel that clients may choose to consume. This configuration property simply instructs a ScenarioService if it should use the alternative Raw channel instead of the normal Data channel.
Note that this property would apply ONLY to 'Data' channels, and not to any other channels.
properties
- The Map in which the configuration properties should be updated.useRawData
- The new value of the property.IScenarioService.CONFIG_USE_RAW_DATA_CHANNEL
,
IScenarioService.DEFAULT_USE_RAW_DATA_CHANNEL
public static void setAckDataTimeout(java.util.Map<java.lang.String,java.lang.Object> properties, long timeout)
Operations (Create, Edit, Delete) only complete once the Updates from the Data channel have been processed up to the point of that operation. Thus, if there are a lot of updates from scenario instances, a number of updates will be queued up, and any from before the operation will be processed before the update from the operation. This wait will time out if the data channel is too congested - the changes will still be seen, but after the operation has completed
Note that operations are "fail fast" - if an operation fails, the failure notification is delivered on the control channel, so the operation call will return quickly. Other operations can also be performed while waiting for the operation to complete.
properties
- The Map in which the configuration properties should be updated.timeout
- the new value for the timeoutIScenarioService.CONFIG_ACKDATA_TIMEOUT
,
IScenarioService.DEFAULT_ACKDATA_TIMEOUT
public static void setDisconnectIfSlow(java.util.Map<java.lang.String,java.lang.Object> properties, boolean disconnectIfSlow)
The disconnect if slow property is only set when a connection is made between components; thus if any receiver, via scenario service, event service or other API, from this process (more exactly, this classloader) has been made, then that connection's disconnect if slow property will be used.
It is not (currently) possible to change the disconnect if slow property of a connection.
Connections to different correlators can use different values of this property.
properties
- The Map in which the configuration properties should be updated.disconnectIfSlow
- The new value of the property.IScenarioService.CONFIG_DISCONNECT_IF_SLOW
,
IScenarioService.DEFAULT_DISCONNECT_IF_SLOW
public static void setReconnectPeriod(java.util.Map<java.lang.String,java.lang.Object> properties, long time)
The scenario service will wait at least this many milliseconds between a disconnect and attempting to reconnect
properties
- The Map in which the configuration properties should be updated.time
- the time in milliseconds to wait between reconnections.IScenarioService.CONFIG_RECONNECT_PERIOD
,
IScenarioService.DEFAULT_RECONNECT_PERIOD
public static void setAutoInstanceDiscovery(java.util.Map<java.lang.String,java.lang.Object> properties, boolean autoInstanceDiscovery)
properties
- The Map in which the configuration properties should be updated.autoInstanceDiscovery
- The new value of the property.IScenarioService.CONFIG_AUTO_INSTANCE_DISCOVERY
,
IScenarioService.DEFAULT_AUTO_INSTANCE_DISCOVERY
public static void setUsernameFilter(java.util.Map<java.lang.String,java.lang.Object> properties, java.lang.String owner)
properties
- The Map in which the configuration properties should be updated.owner
- the username to filter forIScenarioService.CONFIG_FILTER_USER
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |