Skip to content

Task for Groups.Add never completes #3037

@bp74

Description

@bp74

Let's start with a simple code snippet:

var groupName = string.Format("channel/{0}/{1}", channelNumber, language);
var hubContext = GlobalHost.ConnectionManager.GetHubContext<LiveFeedHub>();
await hubContext.Groups.Add(connectionID, groupName);
await hubContext.Clients.Client(connectionID).init(initPackage);

So i want to add a connectionID to a group and then send a message to the client.

The problem is that the await for the first Task never completes. If i remove the await, the connectionID is added to the group successfully! I know it because the client receives broadcast messages for this group afterwards. The await for the second Task works perfectly fine.

This is my setup:

  • The system works with SignalR Scaleout 2.0.3.
  • The Scaleout backplane is using Service Bus for Windows 1.1.
  • The code runs in a Windows Services on the backend.
  • The clients connect to the hub via a website running on IIS.

Btw. The same is true for hubContext.Groups.Remove(..). If you await the completion of the remove operation, you have to wait forever.

Thanks a lot for your help!

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions