WazStorageExtensions icon indicating copy to clipboard operation
WazStorageExtensions copied to clipboard

is there a small issue in the ctor of AutoRenewLease?

Open cbertolasio opened this issue 14 years ago • 5 comments

So I have been kicking the tires on your AutoRenewLease class. Its very cool.

Sometimes you may run into various http errors when working with azure storage. Some of these http status codes are handled, some are not, and result in a "rethrow" of the exception.

If line 61 of AutoRenewLease were to encounter a temporary hiccup, what would happen?

So line 61 calles RenewLease, in its own thread. Line 61 is in the ctor.

If my code, say in my worker role, created an instance of AutoRenewLease, and 30s later, the thread tried to renew the lease, but line 61 encounters an http 500, would my worker role crash?

cbertolasio avatar Nov 10 '11 22:11 cbertolasio

Yes, I believe the worker role would crash. There's no retry logic built into my lease methods.

smarx avatar Nov 11 '11 01:11 smarx

I have refactored my fork to use Task.StartNew with a ContinueWith() delegate to handle the background processing. Are you interested in a pull request?

cbertolasio avatar Nov 13 '11 15:11 cbertolasio

Not quite sure I follow what you did, but I'd be interested in seeing it. Looks like you already deleted your fork. :-(

smarx avatar Nov 13 '11 17:11 smarx

Are you opposed to adding a reference to the Transient Fault Handling framework in this package?

tommck avatar Aug 10 '12 13:08 tommck

Yes.

smarx avatar Aug 10 '12 15:08 smarx