BAM – The BAM API objects…

Posted: August 20, 2010 in BizTalk
Tags: ,

The BAM API defines four main classes:

  • DirectEventStream: used in a :NET application to do a buffered write of data to BAM.
  • BufferedEventStream: used in a :NET application to do a unbuffered write of data to BAM.
  • OrchestrationEventStream: used when writing to BAM programmatically within an orchestration; Provides transactional consistency with the orchestration.
  • MessagingEventStream: used when writing to BAM programmatically within a pipeline; Provides transactional consistency with the messaging engine.

All of these classes are derived from the base class EventStream.

Differences between BufferedEventStream and DirectEventStream

  • BufferedEventStream:
    • Is asynchronous
    • When you update a BufferedEventStream, the update is cached and written later.
    • The BufferedEventStream take advantage of the cache to improve performance
  • DirectEventStream
    • Is synchronous
    • When you execute an update, the call won’t return until the database write is commited
    • If your application can’t ever afford to lose data in server crash, use this class

Advantages of using OrchestrationEventStream

  • Performance: it can piggyback its databases writes on the orchestration persistence points for maximum performance
  • Consistency: because it writes during orchestration persistence points, even in the event of the server crash, the state of the orchestration recorded by BAM is guaranteed to be consistent with the last orchestration persistence point

Tags: BizTalk | BAM

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s