Created
June 16, 2011 06:07
-
-
Save abdullin/1028765 to your computer and use it in GitHub Desktop.
An example of registering poison quarantine.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
x.Quarantine(c => { | |
var logRoot = c.Resolve<IStreamingRoot>(); | |
var registry = c.Resolve<QueueWriterRegistry>(); | |
IQueueWriterFactory factory; | |
if (!registry.TryGet("azure-account-name", out factory)) | |
throw new IOE("Didn't find the specified Azure account. Did you register it in the queue registry?") | |
// registration is right now, if you don't have it already | |
// builder.Advanced.RegisterQueueWriterFactory(c => new AzureQueueWriterFactory(account, c.Resolve<IEnvelopeStreamer>())); | |
return new SampleQuarantine(logging, factory); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment