Azure / azure-relay-dotnet

☁️ .NET Standard client library for Azure Relay Hybrid Connections

Home Page:https://docs.microsoft.com/en-us/azure/service-bus-relay/relay-what-is-it

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Listener stops listening after 24 hours

zurdev opened this issue · comments

Actual Behavior

  1. Successfully opened listener and connected from remote client
  2. After about 24 hours, no listeners available
  3. Listener authenticates with SAS KeyName/Key, ETW indicates successful token renewal every 1hr
  4. No ETW events indicating any error

Expected Behavior

  1. Listener should stay active

Versions

  • OS platform and version: Windows Azure Server
  • .NET Version: v4.6
  • NuGet package version or commit ID: 0.1.4-preview

Just to confirm, you're gathering "Microsoft-Azure-Relay" ETW traces and after 24 hours nothing of interest appears in those traces when the listener becomes unavailable? Does the listener count in the portal show 0 or non-zero?

Not that this is a reasonable work-around, but have you let it run long enough to attempt to renew the token after that time? Do the ETW traces show any error at the next token renewal?

I'm gathering Microsoft-Azure-Relay ETW traces. The traces for token renewal are continuously logged, every 1 hour, even after the listener count drops to 0. There're no other traces around the time the listener disappeared.
The listener count in the portal matches the value I'm getting when calling the GetRuntimeInformationAsync. The count drops to 0 also in the portal after around 24hrs.

Thanks for the details. I've determined what is going on and a cloud-service fix is needed. It's currently in the code review process.

For the mean time, even though it's a terrible work-around, you should recycle your HybridConnectionListener just shy of every 24 hours.

Thanks for the quick turnaround. I will recycle the listener when listener count drops to 0 for now.

Is this issue resolved now and ready to be closed?

I can't tell if it's resolved, since I have mitigated this issue in my code, but I'm no longer blocked, so feel free to close.

The cloud service fix was checked in on 3/8/2017 8:38 AM. It would have been deployed 1-2 months after that time.