locked
Retry Atomic Scope RRS feed

  • Question

  • Hi Folks,

    We have a BizTalk project in which an orchestration holds a Atomic Scope. I need to retry the Atomic Scope in case of any failure...

    Please validate the below procedure to retry Atomic Scope:

    1. Set Retry property to True for Atomic Scope.
    2. Create a Non-Transactional Sub Scope in Atomic Scope.
    3. In the ExceptionHandler of Non-Transactional Scope throw “Microsoft.XLANGs.BaseTypes.RetryTransactionException()” exception.

    I have few questions regarding the number of retry attemps and retry interval.

    1. How to set the time interval for retry (by default i think it is 2 seconds)?
    2. I think number of retry attempts is 21 (Please confirm). How to limit the retry attempts to some other value less than 21?
    3. Will this retry mechanism give arise to any other performance issues?

    It would of great help if any one answers the above questions.

    Friday, March 20, 2009 6:24 AM

Answers

  • Hi there,

    I don't think there's a way to change the 20 retries behavior (one try and 20 retries).

    If you use a RetryTransactionException you should set the retry time interval by populating the DelayFor property of the RetryTransactionException object. For example, in your atomic scope you create a variable called retryEx of the RetryTransactionException class type with the default constructor. To set the retry to 10 seconds you can do this in your inner scope's catch exception:

    retryEx.DelayFor = new System.TimeSpan(0,0,10); 
    throw retryEx; 


    Regards,

    Thiago Almeida

    Thiago Almeida - http://connectedthoughts.wordpress.com
    Saturday, March 21, 2009 6:22 AM
    Answerer

All replies

  • Hi there,

    I don't think there's a way to change the 20 retries behavior (one try and 20 retries).

    If you use a RetryTransactionException you should set the retry time interval by populating the DelayFor property of the RetryTransactionException object. For example, in your atomic scope you create a variable called retryEx of the RetryTransactionException class type with the default constructor. To set the retry to 10 seconds you can do this in your inner scope's catch exception:

    retryEx.DelayFor = new System.TimeSpan(0,0,10); 
    throw retryEx; 


    Regards,

    Thiago Almeida

    Thiago Almeida - http://connectedthoughts.wordpress.com
    Saturday, March 21, 2009 6:22 AM
    Answerer
  • Thank you very much Almeida. It was of great help.
    Wednesday, April 1, 2009 4:29 AM