10.24.0

ISessionCreateFlow Method

Overload List

CreateFlow(FlowProperties, IEndpoint, ISubscription, EventHandlerMessageEventArgs, EventHandlerFlowEventArgs) Creates IFlow instances. A flow is an API concept, which allows client applications to consume messages from an IEndpoint. Messges are attracted by a ISubscription to a IDestination.

The message receive delegate is invoked for each received message on this flow. The flow event delegate is invoked when flow events occur, such as the flow going up or down. Both delegates are invoked in the context of the context thread to which this session belongs.

Note: disposing the corresponding context (IContext) or any of its contained context timers (TimerTask), sessions (ISession) or flows (IFlow) must not be performed from within the registered delegates (messageEventHandler or flowEventHandler).

An endpoint is a holding area which allows a client to attract Guaranteed messages matching a given subscription to a destination. There are two types of endpoints: "durable" and "non-durable". Durable in this context means that the client that is bound to the given endpoint does not have to be online to attract messages. Non-durable endpoints are disposed when the bound client disconnects.

A destination can be either temporary or non-temporary. A temporary destination is used as a "reply to" field in request/reply message exchange patterns. Wildcard subscription capabilities do not apply to temporary destinations.

With the exception of durable endpoint with temporary destination, the following cases are supported:

use caseendPointsubscription
A flow bound to a non-temporary IQueue.A non-null IQueue, created by CreateQueue(String)null
A flow bound to a temporary IQueue.A non-null IQueue, created by CreateTemporaryQueue.null
A flow bound to a non-temporary ITopic and a durable ITopicEndpoint.A non-null ITopicEndpoint, created by CreateDurableTopicEndpoint(String).A non-null ITopic, created by CreateTopic(String) or CreateTopic(TopicProperties).
A flow bound to a non-temporary ITopic and a non-durable ITopicEndpoint.A Non-Durable ITopicEndpoint, created by CreateNonDurableTopicEndpoint. A non-null ITopic, created by CreateTopic(String) or CreateTopic(TopicProperties).
A flow bound to a temporary ITopic and a non-durable ITopicEndpoint.A Non-Durable ITopicEndpoint, created by CreateNonDurableTopicEndpoint. A non-null ITopic, created by CreateTemporaryTopic or CreateTopic(TopicProperties).
CreateFlow(FlowProperties, IEndpoint, ISubscription, EventHandlerMessageEventArgs, EventHandlerFlowEventArgs, EndpointProperties) Creates IFlow instances. In addition, if endPoint is a non-durable Endpoint, it is possible to specify the EndpointProperties of implicitly created Endpoint on the appliance.

The message receive delegate is invoked for each received message on this flow. The flow event delegate is invoked when flow events occur, such as the flow going up or down. Both delegates are invoked in the context of the context thread to which this session belongs.

Note: disposing the corresponding context (IContext) or any of its contained context timers (TimerTask), sessions (ISession) or flows (IFlow) must not be performed from within the registered delegates (messageEventHandler or flowEventHandler).

See Also