Quantcast
Channel: Service Bus forum
Viewing all 1916 articles
Browse latest View live

Azure Servicebus gave System.ServiceModel.AddressAlreadyInUseException

$
0
0

Hi Support,

My azure service bus giving me below exception when listener trying to connect it:
Service cannot be started. System.ServiceModel.AddressAlreadyInUseException: The specified address already exists.Address sb://ServiceBusName.servicebus.windows.net/ is already in use by an existing listener with different settings. TrackingId:2fa03e51-934c-4d40-b8ce-e65f1d0d3883_G17, SystemTracker:NoSystemTracker, Timestamp:7/3/2018 11:37:46 AM

Error occurred: The specified address already exists.Address sb://ServiceBusName.servicebus.windows.net/ is already in use by an existing listener with different settings. TrackingId:2fa03e51-934c-4d40-b8ce-e65f1d0d3883_G17, SystemTracker:NoSystemTracker, Timestamp:7/3/2018 11:37:46 AM

Service bus can connect with multiple listener with different settings.

We used NetTcpRelayBinding in the listener to connect with service bus.

Exception comes when "ServiceHost.Open(new TimeSpan(0, 0, 30)); method is called.

Even I can't see how many listener are connected with service bus.

I googled it and found a image where they specify the listener count("https://stackoverflow.com/questions/42683450/can-i-programmatically-get-a-list-of-azure-service-bus-relays-and-how-many-liste") , but same is not appeared on my azure machine. Can you help me to find out this, how I can locate the no. of listener?

Looking forward a quick reply.




What maintenance should be done on the sql server instance housing Local Service Bus?

$
0
0

The sql instance hosting local service bus has a log file (SBMessageContainer01_log.ldf) that is suddenly consuming 40GB of drive space. It consumed all available drive space.

Also, reviewing the tables in the SBMessageContainer01 database shows most tables have a reasonable number of entries, but two tables have very high numbers of entries (BodiesTable and MessageReferencesTable).

What SQL maintenance should be performed to keep the database size down and the log low?

ACS Migration - Existing Namespace no longer accessible

$
0
0

Hi Folks, 

We are in the middle of the replacing Azure Access Control Namespaces due to its EOL in November this year. 

We were previously using free tier AAD and ACS for authentication in SharePoint 2013. 

It looks like we have lost access to our Development ACS, accessible via the "ACSNAME.accesscontrol.windows.net"

Most likely due to an expired certificate or Microsoft deleting it as it looks under utilized. Problem is we need it to test the migration work. 

Can anyone advise how I get access / re-enable this ACS?

I've seen the posts on accessing ACS via Poweshell, but I think the issue is most likely the ACS has been deactivated or removed by MS. 

Many Thanks
Denis

Migration from ACS authentication for Azure Topic Subscription

$
0
0

The Azure Service Bus authentication is retiring and the suggested migration guide doesn't talk about ACS simple rule authentication on Topic Subscriptions. There is a provision to create SAS rule with service identity name as the rule name and assign permissions like Send or Listen or manage. But is there any guidelines to implement SAS authentication for Service Bus Topic Subscription?

Thanks,

Ravi

How to properly complete session message?

$
0
0

Other info

  • Sessions enabled in queue

Recipient (full dotnet 4.6.2)

Task OnStart() {
    var factory = MessagingFactory.CreateFromConnectionString(Settings.ConnectionString);
    var queueClient = factory.CreateQueueClient(Settings.RecipientQueue, ReceiveMode.PeekLock);
    var options = new SessionHandlerOptions()
    {
          AutoComplete = false,
          MaxConcurrentSessions = 1
    };
    queueClient.RegisterSessionHandler(typeof(SessionHandler), options);
}

...

class SessionHandler : IMessageSessionAsyncHandler {
...
    public async Task OnMessageAsync(MessageSession session, BrokeredMessage message)
    {
         await message.CompleteAsync();
    }
...
}

Publisher (dotnet core 2.1):

        public Task PublishAsync(string queueName, string eventName, object data)
        {
            var message = new Message
            {
                Body = Encoding.UTF8.GetBytes(JsonConvert.SerializeObject(data)),
                SessionId = queueName,
                ReplyToSessionId = queueName,
                TimeToLive = TimeSpan.FromSeconds(30),
                ReplyTo = settings.RecipientQueue
            };
            return new MessageSender(connection, queueName).SendAsync(message);
        }

Actual Behavior

  1. Everything is OK when I'm using queues without SessionId and Session disabled
  2. User errors in Azure Portal Metrics when using queues with SessionId and Session enabled
  3. Exception: Exception thrown: 'System.ServiceModel.FaultException1' in Microsoft.ServiceBus.dll ("A timeout has occurred during the operation. e786d05b-<numers>-404b-917b-<numbers>5b_G6"). Exception thrown: 'System.ServiceModel.FaultException1' in Microsoft.ServiceBus.dll ("A timeout has occurred during the operation. e786d05b--404b-917b-5b_G6")
  4. Exception: Exception thrown: 'System.ServiceModel.FaultException1' in Microsoft.ServiceBus.dll ("A timeout has occurred during the operation. TrackingId:<numbers>-3b64-4dc1-b9e5-<number>, SystemTracker:<message-bus-name>:queue:<queue-name>~<numbers>, Timestamp:<date-time>"). Exception thrown: 'System.ServiceModel.FaultException1' in Microsoft.ServiceBus.dll

Expected Behavior

  1. Sessions works and no reason for errors in monitor

How to write Unit Test for Azure Function

$
0
0

Hi , 

I want to write Unit test for Azure function app , this function app use TopicClient for creating topics and post messages to it the function receive HttpRequestMessage and TraceWrite as parameter .

I want to use Moq and NUnit framework for unit test can any one help how i should write unit tests for auzre functions

Can I send encrypted binary content to an Azure WCF Relay? If not, why not?

$
0
0

I am trying to use an Azure WCF Relay to send an encrypted AS2 message to a BizTalk WCF endpoint hosted on-premises. I've confirmed that the relay is connected on the receiver side and I've been able to send it junk text-based messages and confirmed that these arrive on the receiver.

My working AS2 sender is an Azure Logic App with the AS2 encoder and an HTTP send action. This works with another real AS2 receiver provided by a third party. The message is encrypted and signed and transmitted with a content type of application/pkcs7-mime; smime-type=enveloped-data; name=\"smime.p7m\" and a content transfer encoding of binary.

This yields a SOAP Fault as a response, with the fault code namespace of http://schemas.microsoft.com/netservices/2009/05/servicebus/relay. This pretty well confirms to me that it's the relay returning this error. Nothing at all shows up on the on-premises side. I've experimented with BasicHttpRelayBinding - which should expect SOAP - and WebHttpRelayBinding, which from my understanding, should accept anything. Neither works.

Must the message sent to a WCF Relay be a SOAP message? If so, how would I embed this binary content in it so that it can be unpacked and processed as "normal" AS2 on the other side? Otherwise, will this ever work, or am I onto a loser here?

Queue is being created with wrong size

$
0
0

In Azure portal, if I navigate to an existing "Basic" tiered Service Bus namespace and add a new queue to it with the default options and by only providing name (default max size is 1GB) it creates a queue with 16GB max size. If I select 2 GB, I get 32GB max size queue. But when I use the REST API - what I am getting is correct. But on the other hand, if I go to the queue's properties and change the max size to 1GB - it shrinks to 1GB from 16 GB. The same behavior persists for the "Standard" scale as well.  

Current Max size enums are 1GB, 2GB, 3GB, 4GB and 5GB

 

Does Service Bus REST API support RBAC

$
0
0

I'm very interested to know if/when the Service Bus REST API will support RBAC.  It's my understanding this already works using the .NET API.  I see .NET API samples on GitHub but have yet to try them out.  I'm more interested in getting it working using the REST API 

For now I'll be routing requests to Service Bus via APIM.  I can add a valid authorization header with oAuth token (Bearer ...) for an application with Owner rights for the Service Bus Namespace, but Service Bus complains about the format.  I can also enable the MSI setting for APIM and Service Bus still complains.

Please let me know if Service Bus's RBAC support works for the REST API, or only when using the .NET API.


ServiceBusClientWebSocket was expecting more bytes

$
0
0

I am getting the error "ServiceBusClientWebSocket was expecting more bytes" when trying to receive a message via the Azure Service Bus Relay service via WCF over a netTcp relay.  I request makes it to the listener and the listener sends a response, but the sender gets the error.  The response could be more that 64KB long. I set the WCF binding on the listener and sending to maxBufferPoolSize="1000000000" maxBufferSize="100000000" maxReceivedMessageSize="100000000". 

Can the WCF relay service allow responses > 64KB?  Do I need to use a HybridConnection?

Service bus - get messages - REST - no content

$
0
0

Newbie question on the Azure SB Queue

I managed to get the to get the token, and can perfectly create Messages in a queue. However when trying to retrieve Messages from the queue it is rather random.

Sometimes it works, and I can retrieve a Message, but 
Most times, I get either a 204 - no content, yet in Azure i can see there are many Messages.

So why does the exact same call give different results? It seems that if I wait a couple of minutes there is a higher chance of success.

{"method":"POST","transformRequest": [ null ], "transformResponse": [ null ], "url":"http://xxx.servicebus.windows.net/gipsqueue/messages/head","headers": { "Content-Type":"application/atom+xml;type=entry;charset=utf-8","Authorization":"SharedAccessSignature sr=xxxxxxxxxxxxxxxx","Accept":"application/json, text/plain, */*" }, "data":"","timeout": {} }


Price difference between Standard and Premium

$
0
0

I'm looking to stabilize my Azure Service Bus infrastructure. I'm experiencing poor performance from time to time, probably caused by noisy neighbours. I've looked at the premium pricing tier, but I've found it extremely expensive compared to Standard.

Just to make sure I understand correctly. A standard subscription with, let's say 20.000.000 messages per month is around $40 permonth. And if I choose the premium tier instead, it wil increase to almost $700 dollars. And this includes a single message unit only. I do understand that it is more expensive with a dedicated environment, but I think that a factor 17 is just crazy. Am I missing something?

Azure Event Hub - Enable Kafka in ARM template

$
0
0
I would like to automate deploying Event Hubs with Kafka enabled. Is there an ARM template property on the "Microsoft.EventHub/namespaces" resource I can use to enable Kafka? If not, is there a way to enable Kafka using PowerShell?

Bug in the message scheduling

$
0
0

Steps to reproduce:

  1. A message is scheduled on the empty Azure ServiceBus Queue
  2. The message scheduling is cancelled using its <g class="gr_ gr_158 gr-alert gr_spell gr_inline_cards gr_run_anim ContextualSpelling ins-del multiReplace" data-gr-id="158" id="158">scheduleId</g> after becoming active but before it is processed by the receiver
  3. The message is still active and the number of scheduled messages (visible on the Azure portal) is decreased by 1 (even below 0)

... so if there was just 1 message scheduled that is now active and being <g class="gr_ gr_791 gr-alert gr_spell gr_inline_cards gr_run_anim ContextualSpelling multiReplace" data-gr-id="791" id="791">cancelled</g> then the number of messages in the schedule queue stands at -1. 

This is appearing in ServiceBus service as of 26 of July 2018

Publish to Event Grid failing with "A task was canceled"

$
0
0

Hi,

We have recently started to see issues publishing events to the event grid in that it appears to be incredibly unreliable.  We are hosting the event grid topic in North Europe.  Searching the web, it seems that we are not alone in these issues and they have only surfaced very recently.  See;

https://github.com/Azure/azure-functions-host/issues/3160

https://github.com/Azure/azure-sdk-for-net/issues/4575

Stack Trace;

{System.Threading.Tasks.TaskCanceledException: A task was canceled.

   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)

   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)

   at Microsoft.Rest.RetryDelegatingHandler.<>c__DisplayClass11_0.<<SendAsync>b__1>d.MoveNext()

--- End of stack trace from previous location where exception was thrown ---

   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()

   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)

   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)

   at Microsoft.Rest.RetryDelegatingHandler.<SendAsync>d__11.MoveNext()

--- End of stack trace from previous location where exception was thrown ---

   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()

   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)

   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)

   at System.Runtime.CompilerServices.ConfiguredTaskAwaitable`1.ConfiguredTaskAwaiter.GetResult()

   at System.Net.Http.HttpClient.<FinishSendAsyncBuffered>d__58.MoveNext()

--- End of stack trace from previous location where exception was thrown ---

   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()

   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)

   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)

   at Microsoft.Azure.EventGrid.EventGridClient.<PublishEventsWithHttpMessagesAsync>d__38.MoveNext()

--- End of stack trace from previous location where exception was thrown ---

   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()

   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)

   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)

   at Microsoft.Azure.EventGrid.EventGridClientExtensions.<PublishEventsAsync>d__0.MoveNext()

--- End of stack trace from previous location where exception was thrown ---

   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()

   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)

   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)

   at EventBus.AzureEventGrid.EventPublisher.Publish[TEvent](TEvent integrationEvent)} System.Exception {System.Threading.Tasks.TaskCanceledException}


Service bus scalable to 1 million subscribers? How to impliment, how to price...

$
0
0

All,

I have a hypothetical situation where a single or small group of message generators will want to sent a topic message to potentially 1 Million subscribers, say 5 times a day.  The requirement is for this message to reach the subscribers in under 30 seconds.  The payload is a small 32 bit string.  A small amount of missed messages IS permitted.  My questions may seem basic given the size of this task but please bare with me.

  1. Is this feasible in some form?  I use service bus as the assumed correct path but this is not a requirement.
  2. What would be the proper way to architect or implement such a scale?
  3. How would such be priced?  I see additional charges for high brokered message count with timeout greater than 0.  To me, naively, this does not make sense, as how would a message with a 0 timeout ever even be seen?

I am willing to pay for support to have this question answered if not possible on this forum.  If that is required, then input on how or where I pursue that support would instead be appreciated.

Thank you!


Edward Schoenherr

Channel gets closed automatically

$
0
0

Hi,

    I often run into below exception. Can you please elaborate why the below exception occurs? Is it due to large amount of data or some timeout issue?

This channel can no longer be used to send messages as the output session was auto-closed due to a server-initiated shutdown. Either disable auto-close by setting the DispatchRuntime.AutomaticInputSessionShutdown to false, or consider modifying the shutdown protocol with the remote server.

Unable to send message into Service Bus Queue using Azure function

$
0
0
[FunctionName("Demo")]publicstaticvoidRun([ServiceBusTrigger("%Demo-Queue%",Connection="AzureWebJobsBPGAServiceBus")]string myQueueItem,[ServiceBus("%Update-Queue%",Connection="AzureWebJobsBPGAServiceBus")]ICollector<BrokeredMessage> updateMessage,TraceWriter log){string query ="SELECT Id FROM MyTable";var data = dbs.GetData(query).GetAwaiter().GetResult();BrokeredMessage brokeredMessage;foreach(var item in data){JObject jObject =newJObject(newJProperty("Id", item),newJProperty("MessageId",newGuid(item)));
                brokeredMessage =newBrokeredMessage(jObject.ToString());
                updateMessage.Add(brokeredMessage);}}

But message going in dead letter queue . why ? Message format is also correct.Any clue ?

I tried using another queue it works fine, also delete that queue and re-create which has issue still message goes into dead letter queue and message property delivery count is 11.


SE

Fastest way to get a notification to 1 million users?

$
0
0

All,

I have a hypothetical situation where a single or small group of message generators will want to sent a topic message to potentially 1 Million subscribers, say 5 times a day.  The requirement is for this message to reach the subscribers in under 30 seconds.  The payload is a small 32 bit string.  A small amount of missed messages IS permitted.  My questions may seem basic given the size of this task but please bare with me.

  1. Is this feasible in some form?  I use service bus as the assumed correct path but this is not a requirement.
  2. What would be the proper way to architect or implement such a scale?
  3. How would such be priced?  I see additional charges for high brokered message count with timeout greater than 0.  To me, naively, this does not make sense, as how would a message with a 0 timeout ever even be seen?

I am willing to pay for support to have this question answered if not possible on this forum.  If that is required, then input on how or where I pursue that support would instead be appreciated.

Thank you!


Edward Schoenherr

Settingup Service Bus in Visual Studio

$
0
0

Hi Expert,

 I have a requirement to test real time streaming data using Event Hub and Stream Analytics. But I would like to do this setup in my local machine, VS 2017.

 Is is possible to test this using VS / C#? Can Someone help me to find good article to Setting this up in VS.

Thanks In Advance,

Regards

Vikas


Regards Vikas Pathak

Viewing all 1916 articles
Browse latest View live