Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

How to retrieve a dead letter msg dotnet

private static async Task GetMessage()
{
    string connection = 
    "Endpoint=sb://theurloftheconnection;SharedAccessKeyName=aKeyName;SharedAccessKey=fdgsdfg=";
    string topic = "DavesChat";
    string subscription = "TestQueue";
    var subPath = EntityNameHelper.FormatSubscriptionPath(topic, subscription);
    var deadLetterPath = EntityNameHelper.FormatDeadLetterPath(subPath);
    var receiver = new MessageReceiver(connection, deadLetterPath, ReceiveMode.PeekLock);
    var message = await receiver.PeekAsync();
}
 
PREVIOUS NEXT
Tagged: #How #retrieve #dead #letter #msg #dotnet
ADD COMMENT
Topic
Name
8+1 =