Closed
Bug 979966
Opened 9 years ago
Closed 4 years ago
Need better r_log diagnostics when no candidate pairs exist for a stream
Categories
(Core :: WebRTC: Networking, defect, P4)
Core
WebRTC: Networking
Tracking
()
RESOLVED
FIXED
mozilla67
Tracking | Status | |
---|---|---|
firefox67 | --- | fixed |
backlog | webrtc/webaudio+ |
People
(Reporter: bwc, Assigned: bwc)
Details
Attachments
(2 files, 3 obsolete files)
We've observed an intermittent mochitest failure (bug 977944) that resulted from the lack of any candidate pairs, but the logging gives us no indication whether this was due to the lack of local or remote candidates. We probably want to dump the local and remote candidates when this happens, so we at least know what we're missing. This may end up being related to bug 833043.
Assignee | ||
Updated•9 years ago
|
Assignee: nobody → docfaraday
Assignee | ||
Comment 1•9 years ago
|
||
I'm seeing some *_dump_state functions that seem to gathering dust; I think that fixing them up is going to be the best approach here.
Assignee | ||
Updated•9 years ago
|
Status: NEW → ASSIGNED
Assignee | ||
Comment 2•9 years ago
|
||
Initial cut.
Assignee | ||
Updated•9 years ago
|
Attachment #8386490 -
Flags: review?(ekr)
Comment 3•9 years ago
|
||
Comment on attachment 8386490 [details] [diff] [review] Log some diagnostic information when we have no candidate pairs on a stream when starting checks. Review of attachment 8386490 [details] [diff] [review]: ----------------------------------------------------------------- ::: media/mtransport/third_party/nICEr/src/ice/ice_component.c @@ +1085,5 @@ > return(_status); > } > + > + > +int nr_ice_component_dump_state(nr_ice_component *comp) Can we rename this something that's more indicative that it's loud? Dump sounds like debugging. @@ +1087,5 @@ > + > + > +int nr_ice_component_dump_state(nr_ice_component *comp) > + { > + nr_ice_candidate *cand; Whitesapace after this line please. ::: media/mtransport/third_party/nICEr/src/ice/ice_media_stream.c @@ +357,5 @@ > > /* Find the highest priority WAITING check and move it to RUNNING */ > pair=TAILQ_FIRST(&stream->check_list); > + > + if(!pair){ This isn't correct. Chrome only trickles and we probably will n future. @@ +389,5 @@ > nr_ice_candidate_pair_start(pair->pctx,pair); /* Ignore failures */ > NR_ASYNC_TIMER_SET(timer_val,nr_ice_media_stream_check_timer_cb,cb_arg,&stream->timer); > } > else { > + r_log(LOG_ICE,LOG_INFO,"ICE-PEER(%s): no FROZEN/WAITING pairs for %s",stream->pctx->label,stream->label); for stream %s. @@ +547,3 @@ > > + if(stream->local_stream){ > + // stream has a corresponding local_stream Please convert to C-style comments. I know this is a big in the original. @@ +547,4 @@ > > + if(stream->local_stream){ > + // stream has a corresponding local_stream > + nr_ice_media_stream_dump_state(stream->local_stream->pctx,stream->local_stream,0); You are passing a null file pointer, so this doesn't do anything, right? @@ +547,5 @@ > > + if(stream->local_stream){ > + // stream has a corresponding local_stream > + nr_ice_media_stream_dump_state(stream->local_stream->pctx,stream->local_stream,0); > + r_log(LOG_ICE,LOG_WARNING,"ICE-PEER(%s)/STREAM(%s): state dump", stream->pctx->label, stream->label); This seems like it could be a clearer message.
Attachment #8386490 -
Flags: review?(ekr) → review-
Assignee | ||
Comment 4•9 years ago
|
||
Comment on attachment 8386490 [details] [diff] [review] Log some diagnostic information when we have no candidate pairs on a stream when starting checks. Review of attachment 8386490 [details] [diff] [review]: ----------------------------------------------------------------- ::: media/mtransport/third_party/nICEr/src/ice/ice_component.c @@ +1085,5 @@ > return(_status); > } > + > + > +int nr_ice_component_dump_state(nr_ice_component *comp) How about "s/dump_state/postmortem_log/"? ::: media/mtransport/third_party/nICEr/src/ice/ice_media_stream.c @@ +357,5 @@ > > /* Find the highest priority WAITING check and move it to RUNNING */ > pair=TAILQ_FIRST(&stream->check_list); > + > + if(!pair){ Hmm. Then we'll have to completely change when we dump. However, it seems reasonable to do this when the stream fails, and that will be more useful than just catching this specific problem. @@ +547,4 @@ > > + if(stream->local_stream){ > + // stream has a corresponding local_stream > + nr_ice_media_stream_dump_state(stream->local_stream->pctx,stream->local_stream,0); This function (and nr_ice_candidate_pair_dump_state) never used that param anyhow; they contained some commented-out logging statements but did nothing. I can prune out the dead code if you like. @@ +547,5 @@ > > + if(stream->local_stream){ > + // stream has a corresponding local_stream > + nr_ice_media_stream_dump_state(stream->local_stream->pctx,stream->local_stream,0); > + r_log(LOG_ICE,LOG_WARNING,"ICE-PEER(%s)/STREAM(%s): state dump", stream->pctx->label, stream->label); How about "begin state dump"? This is only there to explain what the following output is all about.
Assignee | ||
Comment 5•9 years ago
|
||
Incorporate some review feedback, and perform a postmortem dump whenever a media stream fails. Clean up some dead code, with a relatively light touch. Might be useful to scrub harder.
Assignee | ||
Updated•9 years ago
|
Attachment #8386490 -
Attachment is obsolete: true
Assignee | ||
Updated•9 years ago
|
Attachment #8402950 -
Flags: review?(ekr)
Assignee | ||
Comment 6•9 years ago
|
||
Comment on attachment 8402950 [details] [diff] [review] Dump diagnostic information when an ICE media stream fails. Review of attachment 8402950 [details] [diff] [review]: ----------------------------------------------------------------- Actually, I'm seeing output that doesn't make sense. Need to dig into it and fix.
Attachment #8402950 -
Flags: review?(ekr)
Assignee | ||
Comment 7•9 years ago
|
||
Remove some redundant information from the component log dump.
Assignee | ||
Updated•9 years ago
|
Attachment #8403593 -
Flags: review?(ekr)
Assignee | ||
Comment 8•9 years ago
|
||
Remove a hunk that I decided we didn't need, but missed on the last export. Also, fix commit message.
Assignee | ||
Updated•9 years ago
|
Attachment #8403593 -
Attachment is obsolete: true
Attachment #8403593 -
Flags: review?(ekr)
Assignee | ||
Updated•9 years ago
|
Attachment #8402950 -
Attachment is obsolete: true
Assignee | ||
Updated•9 years ago
|
Attachment #8404120 -
Flags: review?(ekr)
Comment 9•9 years ago
|
||
Comment on attachment 8404120 [details] [diff] [review] Dump diagnostic information when an ICE media stream fails. Review of attachment 8404120 [details] [diff] [review]: ----------------------------------------------------------------- ::: media/mtransport/third_party/nICEr/src/ice/ice_component.c @@ +1089,5 @@ > +int nr_ice_component_postmortem_log(nr_ice_component *comp) > + { > + nr_ice_candidate *cand; > + > + if (comp->local_component) { This could use a comment to explain what is going on. Took me a minute to realize that you were using the existence of a local component to indicate that it was a remote componet. ::: media/mtransport/third_party/nICEr/src/ice/ice_media_stream.c @@ +537,4 @@ > > + if(stream->local_stream){ > + /* stream has a corresponding local_stream */ > + nr_ice_media_stream_postmortem_log(stream->local_stream->pctx,stream->local_stream); Why are you not checking for errors here? @@ +552,4 @@ > > + comp=STAILQ_FIRST(&stream->components); > + while(comp){ > + nr_ice_component_postmortem_log(comp); Error checks. ::: media/mtransport/third_party/nICEr/src/ice/ice_peer_ctx.h @@ +77,5 @@ > int nr_ice_peer_ctx_pair_candidates(nr_ice_peer_ctx *pctx); > int nr_ice_peer_ctx_parse_global_attributes(nr_ice_peer_ctx *pctx, char **attrs, int attr_ct); > int nr_ice_peer_ctx_start_checks(nr_ice_peer_ctx *pctx); > int nr_ice_peer_ctx_start_checks2(nr_ice_peer_ctx *pctx, int allow_non_first); > +int nr_ice_peer_ctx_postmortem_log(nr_ice_peer_ctx *pctx); Is this only called on failure? I thought it could be called anywhere. Suggest instead we just call it dump and provide a log level argument
Attachment #8404120 -
Flags: review?(ekr) → review-
Updated•8 years ago
|
backlog: --- → webRTC+
Rank: 35
Priority: -- → P3
Comment 10•6 years ago
|
||
Mass change P3->P4 to align with new Mozilla triage process.
Priority: P3 → P4
Assignee | ||
Comment 11•4 years ago
|
||
Assignee | ||
Comment 12•4 years ago
|
||
https://treeherder.mozilla.org/#/jobs?repo=try&revision=53980b5582c6a0cf7cf53f2e38b043168bd1cb67
Assignee | ||
Comment 13•4 years ago
|
||
Comment 14•4 years ago
|
||
Pushed by bcampen@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/f9252c02242c Dump diagnostic information when an ICE stream fails. r=mjf
Comment 15•4 years ago
|
||
bugherder |
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
status-firefox67:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla67
You need to log in
before you can comment on or make changes to this bug.
Description
•