Tuesday, 24 January 2012

Shared Context in Websphere ESB

                   Context is a temparary area which is created along with Service Message Object (SMO) in the Mediation Flows. Shared Context is a type of context which is present in the SMO. Shared Context is mainly used when we are using Aggregation process where we need to Iterate the BO for Certain times. Shared Context maitains Aggregation data between  Aggregation (FanOut and FanIn) primitives. The Content (data) which is present in the shared context BO does not persist across Request and Response flows i.e The Data in the Shared Context which is used in Request flow can not be used again in Response flow.
                  The Shared Context is a thread-based storage area that's shared in the same thread. Shared Context provides a single memory area to store the data, that means single memory area used be all of the SMO Instances. We can say that the SMO is cloned at the start of each iteration between FanOut and FanIn primitives. Therefore the Shared context is need to provide a location where the aggregated information can be Build-Up during the Iterative process. After the Fan In primitive, it's expected that in most cases the flow performs a map/transform against the information in Shared Context to produce a new SMO body message type.

1 comment:

  1. Hi KanakaRaju, Can help me in understanding how multple callout response aggregation happens in mediation.

    ReplyDelete