public async Task SubscribeMonster(int monsterId) { var executionContext = Context.GetHttpContext().GetExecutionContext(); try { await _monsterService.EnsureUserCanAccessMonsterAsync(executionContext, monsterId); } catch (ForbiddenAccessException ex) { throw new HubException("Access to this resources is forbidden", ex); } catch (MonsterNotFoundException ex) { throw new HubException("Monster not found", ex); } catch (GroupNotFoundException ex) { throw new HubException("Group not found", ex); } await Groups.AddToGroupAsync(Context.ConnectionId, _hubGroupUtil.GetMonsterGroupName(monsterId)); }