Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
fairblue
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Container Registry
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
hosting
chat
fairblue
Commits
c8d5e65e
Commit
c8d5e65e
authored
6 years ago
by
prlanzarin
Browse files
Options
Downloads
Patches
Plain Diff
Add missing changes to SFU AudioManager
parent
05540835
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
labs/bbb-webrtc-sfu/lib/audio/AudioManager.js
+8
-6
8 additions, 6 deletions
labs/bbb-webrtc-sfu/lib/audio/AudioManager.js
with
8 additions
and
6 deletions
labs/bbb-webrtc-sfu/lib/audio/AudioManager.js
+
8
−
6
View file @
c8d5e65e
...
...
@@ -21,6 +21,7 @@ module.exports = class AudioManager extends BaseManager {
this
.
_meetings
=
{};
this
.
_trackMeetingTermination
();
this
.
messageFactory
(
this
.
_onMessage
);
this
.
_iceQueues
=
{};
}
_trackMeetingTermination
()
{
...
...
@@ -50,15 +51,12 @@ module.exports = class AudioManager extends BaseManager {
async
_onMessage
(
message
)
{
Logger
.
debug
(
this
.
_logPrefix
,
'
Received message [
'
+
message
.
id
+
'
] from connection
'
,
message
.
connectionId
);
let
session
;
let
sessionId
=
message
.
voiceBridge
;
let
voiceBridge
=
sessionId
;
let
connectionId
=
message
.
connectionId
;
if
(
this
.
_sessions
[
sessionId
])
{
session
=
this
.
_sessions
[
sessionId
];
}
let
session
=
this
.
_fetchSession
(
sessionId
);
let
iceQueue
=
this
.
_fetchIceQueue
(
sessionId
+
connectionId
);
switch
(
message
.
id
)
{
case
'
start
'
:
...
...
@@ -76,6 +74,9 @@ module.exports = class AudioManager extends BaseManager {
const
sdpAnswer
=
await
session
.
start
(
sessionId
,
connectionId
,
sdpOffer
,
caleeName
,
userId
,
userName
);
Logger
.
info
(
this
.
_logPrefix
,
"
Started presenter
"
,
sessionId
,
"
for connection
"
,
connectionId
);
// Empty the ICE queue
this
.
_flushIceQueue
(
session
,
iceQueue
);
session
.
once
(
C
.
MEDIA_SERVER_OFFLINE
,
async
(
event
)
=>
{
const
errorMessage
=
this
.
_handleError
(
this
.
_logPrefix
,
connectionId
,
caleeName
,
C
.
RECV_ROLE
,
errors
.
MEDIA_SERVER_OFFLINE
);
errorMessage
.
id
=
'
webRTCAudioError
'
;
...
...
@@ -117,12 +118,13 @@ module.exports = class AudioManager extends BaseManager {
session
.
onIceCandidate
(
message
.
candidate
,
connectionId
);
}
else
{
Logger
.
warn
(
this
.
_logPrefix
,
"
There was no audio session for onIceCandidate for
"
,
sessionId
,
"
. There should be a queue here
"
);
iceQueue
.
push
(
message
.
candidate
);
}
break
;
case
'
close
'
:
Logger
.
info
(
this
.
_logPrefix
,
'
Connection
'
+
connectionId
+
'
closed
'
);
this
.
_deleteIceQueue
(
sessionId
+
connectionId
);
if
(
typeof
session
!==
'
undefined
'
)
{
Logger
.
info
(
this
.
_logPrefix
,
"
Stopping viewer
"
+
sessionId
);
session
.
stopListener
(
message
.
connectionId
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment