Commit Graph

721 Commits

Author SHA1 Message Date
5f8b5fdb62 Use for range loop in pc/channel.cc
Bug: webrtc:9732
Change-Id: Ie682bea3f192eba22d60fdff63b599082ae979d3
Reviewed-on: https://webrtc-review.googlesource.com/c/115750
Commit-Queue: Seth Hampson <shampson@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26105}
2018-12-28 19:19:08 +00:00
7e0978c5e8 Use project-level include path in rtptransceiver_unittest.cc
Bug: None
Change-Id: I7c53d798f5b6a379028a19834ac9dffa8359fa73
Reviewed-on: https://webrtc-review.googlesource.com/c/115656
Reviewed-by: Amit Hilbuch <amithi@webrtc.org>
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26099}
2018-12-26 23:00:13 +00:00
77938e6409 Simulcast work to enable RID mux.
Rids can now be sent using rtp_sender.
Hooking up the rid values in the voice and video engine is still WIP.

Bug: webrtc:10074
Change-Id: I245c7ecb23b67fc0ba65caaa5dbb4fcfd60c81bb
Reviewed-on: https://webrtc-review.googlesource.com/c/114505
Commit-Queue: Amit Hilbuch <amithi@webrtc.org>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Reviewed-by: Fredrik Solenberg <solenberg@webrtc.org>
Reviewed-by: Sam Zackrisson <saza@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26092}
2018-12-21 20:59:23 +00:00
7f57788ab7 Removes trial to enable BBR congestion controller.
The BBR controller can still be injected, but the trials
will no longer work. This reduces the binary size.

Bug: webrtc:8415
Change-Id: I2c32c414d08ef0cc16bfd72651535a755cde9916
Reviewed-on: https://webrtc-review.googlesource.com/c/114120
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26077}
2018-12-20 16:42:07 +00:00
afa07dda42 [Unified Plan] SRD: Always set associated remote streams.
This fixes a bug where the streams are not updated if the "msid" changes
without triggering "ontrack", such as if the streams associated with a
receiver changes while the receiver is active.

Bug: webrtc:10083, chromium:916934
Change-Id: Ic7b19ad5ef648ed6880cae4157bf49f8435467ae
Reviewed-on: https://webrtc-review.googlesource.com/c/114161
Commit-Queue: Henrik Boström <hbos@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26069}
2018-12-20 13:01:58 +00:00
54fa02486a Removed log from StatsCollector::GetTrackIdBySsrc.
Bug: chromium:906988
Change-Id: I353db16687e66c265a6121ee24e6353971d7884e
Reviewed-on: https://webrtc-review.googlesource.com/c/115120
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26064}
2018-12-20 00:54:52 +00:00
ceac0152b1 Fail SetLocalDescription if a=mid lines are missing
Bug: webrtc:9540
Change-Id: I5f75feedf2aca5162269e6b4ded6e797b064415a
Reviewed-on: https://webrtc-review.googlesource.com/c/115062
Reviewed-by: Amit Hilbuch <amithi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26063}
2018-12-20 00:18:20 +00:00
31d8b52075 Delete unneeded includes of rtc_base/stringutils.h.
Also delete corresponding dependencies on rtc_base:stringutils.

Bug: webrtc:6424
Change-Id: I2be5e021292eea2d788c76a63cc0e4f7cefd927d
Reviewed-on: https://webrtc-review.googlesource.com/c/114544
Commit-Queue: Niels Moller <nisse@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Henrik Andreassson <henrika@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26057}
2018-12-19 11:04:27 +00:00
06817cd973 [Unified Plan] Support legacy endpoints that do not use a=mid
These legacy endpoints were supported with Plan B since the SDP
parser would fill in default MID values if a=mid was absent that
happened to match the default offered MIDs.

With Unified Plan, these default MIDs changed so the autofilled
MIDs do not match any more.

This CL adds information to the SessionDescription struct to
indicate whether or not a=mid was present and modified
PeerConnection::SetRemoteDescription to copy MIDs from the local
description if the a=mid lines are not present.

Bug: webrtc:9540
Change-Id: Ibf923b4ad59edb0facd06ddbd01cc10c62fc48e6
Reviewed-on: https://webrtc-review.googlesource.com/c/114820
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Amit Hilbuch <amithi@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26054}
2018-12-19 01:01:59 +00:00
5a1de87e9a Use unique_ptr in webrtcsdp.cc
Bug: None
Change-Id: I68c1d1bbde928667b215340e2b1a6133b344d179
Reviewed-on: https://webrtc-review.googlesource.com/c/114907
Reviewed-by: Amit Hilbuch <amithi@webrtc.org>
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26052}
2018-12-18 20:38:54 +00:00
8eeccbe6a6 Delete Start and Stop methods from TestVideoCapturer.
Preparation for replacing use of TestVideoCapturer as an interface,
instead using VideoSourceInterface.

Methods kept as non-virtual on the subclass FrameGeneratorCapturer,
but it's changed to be started on creation.

Bug: webrtc:6353
Change-Id: Iae1c9a0ee55d730d4992204f62227ef2f057d58e
Reviewed-on: https://webrtc-review.googlesource.com/c/114425
Reviewed-by: Sebastian Jansson <srte@webrtc.org>
Reviewed-by: Erik Språng <sprang@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Per Kjellander <perkj@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26037}
2018-12-18 09:29:52 +00:00
41f3a43c74 Remove CodecInst pt.3
Finally remove CodecInst from common_types.h, including remaining code referencing it.

TBR=kwiberg

Bug: webrtc:7626
Change-Id: I5e6b949ae9093641e33972af8438d1126fc48556
Reviewed-on: https://webrtc-review.googlesource.com/c/114546
Commit-Queue: Fredrik Solenberg <solenberg@webrtc.org>
Reviewed-by: Oskar Sundbom <ossu@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26036}
2018-12-18 07:42:21 +00:00
68586e80fc Replace starts_with and ends_with with Abseil
Bug: None
Change-Id: I7eae3db1aeb81f0f1d37ff50d5c85c16ecb1f366
Reviewed-on: https://webrtc-review.googlesource.com/c/114221
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26032}
2018-12-17 17:33:06 +00:00
eb02ecd358 Move peerconnectionwrapper.(h|cc) into separate build target
Bug: webrtc:10138
Change-Id: I32f8b9721c37075e355b90c3794a4bef6bd46761
Reviewed-on: https://webrtc-review.googlesource.com/c/114548
Reviewed-by: Oleh Prypin <oprypin@webrtc.org>
Commit-Queue: Artem Titov <titovartem@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26027}
2018-12-17 14:08:34 +00:00
944c7557e1 Use unique_ptr in DataChannel PacketQueue
Bug: None
Change-Id: I629d42c5a2e736ae352ef5df01eb19b2a9498e7f
Reviewed-on: https://webrtc-review.googlesource.com/c/114261
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Amit Hilbuch <amithi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26008}
2018-12-14 00:07:44 +00:00
833979f7b8 Adding metrics for hostname candidate use.
These metrics by themselves won't be as useful, unless they can be correlated to the use of the
feature 'WebRtcHideLocalIpsWithMdns'. This can be done by running a finch experiment where we turn
the feature on for a % of users, we can then compare these metrics for users with and without
the feature turned on.

A complementary change is required in Chrome:
tools/metrics/histograms/enums.xml

Bug: webrtc:9605 webrtc:10091 chromium:914452
Change-Id: Ibc6d16dec95a8e3943ce40063c02903769fe1cb4
Reviewed-on: https://webrtc-review.googlesource.com/c/113321
Commit-Queue: Jeroen de Borst <jeroendb@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26003}
2018-12-13 17:35:10 +00:00
e1301a8b3a Revert "Implement read-only codecPayloadType in RtpParameters"
This reverts commit 806e06d1366b58878ced05cdd8d1d56394982fe6.

Reason for revert: Breaks WebRTC roll to Chromium. https://chromium-review.googlesource.com/c/chromium/src/+/1375538

02:52:35.346 7748   [6936:11248:1213/025234.206:ERROR:mediaengine.cc(80)] Attempted to set RtpParameters with modified codecPayloadType (INVALID_MODIFICATION)

Original change's description:
> Implement read-only codecPayloadType in RtpParameters
> 
> Bug: webrtc:7580
> Change-Id: I6d901afa97262b6c6d9fe6c7366df465ec77bfb3
> Reviewed-on: https://webrtc-review.googlesource.com/c/113944
> Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
> Reviewed-by: Seth Hampson <shampson@webrtc.org>
> Reviewed-by: Anders Carlsson <andersc@webrtc.org>
> Reviewed-by: Steve Anton <steveanton@webrtc.org>
> Commit-Queue: Florent Castelli <orphis@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#25993}

TBR=steveanton@webrtc.org,sakal@webrtc.org,andersc@webrtc.org,shampson@webrtc.org,orphis@webrtc.org

Change-Id: I157f9a79ae7133395431891e15e2c053559d359b
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:7580
Reviewed-on: https://webrtc-review.googlesource.com/c/114300
Reviewed-by: Henrik Grunell <henrikg@webrtc.org>
Commit-Queue: Henrik Grunell <henrikg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#26000}
2018-12-13 12:13:30 +00:00
1dac6d8839 Sanitize candidates in ICE-level stats when necessary.
The address and the related address of local candidates are sanitized
accordingly when the mDNS concealment of local IPs is enabled. Also,
remote hostname candidates created from signaling are sanitized in stats
as well. A couple of unit tests are revised to reflect the desired
behavior of AsyncResolverInterface so that when a hostname candidate is
resolved, the hostname is kept in the candidate address.

Bug: webrtc:9605, chromium:914452
Change-Id: Iad9ad04ce4e50304e44cf04b15b97a7ae2dec960
Reviewed-on: https://webrtc-review.googlesource.com/c/113643
Reviewed-by: Qingsi Wang <qingsi@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Reviewed-by: Jeroen de Borst <jeroendb@webrtc.org>
Commit-Queue: Qingsi Wang <qingsi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25996}
2018-12-13 00:27:33 +00:00
806e06d136 Implement read-only codecPayloadType in RtpParameters
Bug: webrtc:7580
Change-Id: I6d901afa97262b6c6d9fe6c7366df465ec77bfb3
Reviewed-on: https://webrtc-review.googlesource.com/c/113944
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Reviewed-by: Anders Carlsson <andersc@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Commit-Queue: Florent Castelli <orphis@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25993}
2018-12-12 16:24:29 +00:00
ab64e8a7ea Using fully qualified names for using declarations.
Using declarations should use fully qualified names (with leading `::`)
unless they are referring to a name inside the current namespace.
Source: https://abseil.io/tips/119.

This CL removes a lot of "using webrtc::*" adding a namespace to the
tests. It also removes some unneeded "using" declarations.

Bug: webrtc:9855
Change-Id: Id6eb843e9dcee2e458b1ffd0c499df390fa9c45d
Reviewed-on: https://webrtc-review.googlesource.com/c/114001
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25987}
2018-12-12 11:44:19 +00:00
c57d573d0f RID parsing for Simulcast support.
Adding RidDescription to StreamParams that will contain the list of rids
for the track.
Adding receive_stream to MediaContentDescription to allow identifying
the stream that originates from the answerer (but is referenced by the
sender). For example, to signal that it will be received in Simulcast.

Bug: webrtc:10073.
Change-Id: Icd9a6b0a69d42bef51f525e673ce447255584334
Reviewed-on: https://webrtc-review.googlesource.com/c/113794
Commit-Queue: Amit Hilbuch <amithi@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25978}
2018-12-12 00:33:59 +00:00
9d4fd55580 Make CONNECTION_WRITE_TIMEOUT configurable for ice connection
Bug: None
Change-Id: I0fd0616132705c6d15a77fc442be47080f1b81b1
Reviewed-on: https://webrtc-review.googlesource.com/c/112721
Reviewed-by: Qingsi Wang <qingsi@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25975}
2018-12-11 19:24:42 +00:00
6fe1fba7b1 Convert MediaSessionFactory to return unique_ptrs
Bug: None
Change-Id: Ia0dbe00fd063b083caad8598102236aa3bb3079d
Reviewed-on: https://webrtc-review.googlesource.com/c/113826
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25974}
2018-12-11 19:10:27 +00:00
1a9d3c398d Convert TransportDescriptionFactory to return unique_ptrs
Bug: None
Change-Id: I887f38c680c813d4a1ce9a06387638b47779eb48
Reviewed-on: https://webrtc-review.googlesource.com/c/113825
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25973}
2018-12-11 18:03:36 +00:00
8f66ddbae3 Move is_unified_plan flag to a member variable
This changes MediaSessionFactory to take the unified plan
configuration option as an explicit setter rathen than a
MediaSessionOptions flag. This is fine since a PeerConnection will
always be in unified plan mode or not, and we know this at
construction.

Bug: None
Change-Id: Ifca45d1d7c9d62b2b41bb879f8665fb39b4cdcd0
Reviewed-on: https://webrtc-review.googlesource.com/c/113824
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25960}
2018-12-11 01:14:42 +00:00
5c72e71e14 [Unified Plan] Fix issues with recycling m= sections
Previously, the PeerConnection would look at the pending local
and remote descriptions also to determine if an m= section is
recycled. That is not quite spec compliant and breaks down under
some edge cases. This changes the PeerConnection to look only at
the *current* local or remote description (i.e., the descriptions
from the last time the PeerConnection was in a stable signaling
state) to determine if an m= section is recycled.

Additionally, the MediaSessionFactory only looked at the local
description to determine if an m= section is recycled. The full
criteria requires looking at the current local and current remote
m= sections. This change adds a state enum to the
MediaDescriptionOptions so that the MediaSessionFactory knows if
a media section is being recycled without duplicating the logic
in PeerConnection.

Tests are added to cover additional edge cases.

Bug: chromium:899680
Change-Id: I5bcf0f88957a61653269ed8bb50b2018500bc1d5
Reviewed-on: https://webrtc-review.googlesource.com/c/111293
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25959}
2018-12-10 23:38:55 +00:00
514f084c26 New statistic added to VideoReceiveStream to determine latency to first decode.
This change introduces a new measurement into the VideoReceiveStream::Stats
structure to measure the latency between the first frame being received and
the first frame being decoded in WebRTC. The goal here is to measure the latency
difference when a FrameEncryptor is attached and not attached.

Change-Id: I0f0178aff73b66f25dbc6617098033e226da2958
Bug: webrtc:10105
Reviewed-on: https://webrtc-review.googlesource.com/c/113328
Commit-Queue: Benjamin Wright <benwright@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25956}
2018-12-10 18:49:34 +00:00
6a8727bd2a Update connection states to match spec changes.
These changes simplify the code, and also fix the issue where the peerconnectionstate would sometimes return to "new" during connection setup.

Bug: webrtc:9308
Change-Id: I895cd2f94a2b9688c821cca64d1a077317b99d44
Reviewed-on: https://webrtc-review.googlesource.com/c/111964
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Jonas Olsson <jonasolsson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25942}
2018-12-10 10:01:24 +00:00
120469086a Export the standardized IceConnectionState.
Since a lot of native users have taken dependencies on our old, non-standard behaviour
we'll have to have two ice connection states living side by side until we can get rid
of the old one.

Bug: webrtc:6145
Change-Id: I9b673bffeb1dfcf410f7c56d4def5912121e644c
Reviewed-on: https://webrtc-review.googlesource.com/c/113421
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Commit-Queue: Jonas Olsson <jonasolsson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25929}
2018-12-07 09:54:59 +00:00
d644feb81f Make sure media transport is deleted before ICE.
This was regression due to
https://webrtc-review.googlesource.com/c/src/+/111920

which broke downstream projects. The break was not caught in
unit tests, because unit tests use loopback and fake media
transports that do not use ICE.

Bug: None
Change-Id: If95935afed430d62d5ff9a2ee01d8eaccadc198d
Reviewed-on: https://webrtc-review.googlesource.com/c/113440
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Peter Slatala <psla@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25926}
2018-12-06 18:11:28 +00:00
628f37a6fe Delete a cricket::DtlsTransport when PC is closed
This avoids use-after-free problems that occur when references
to webrtc::DtlsTransport objects are held outside of the PC.

Bug: chromium:907849
Change-Id: Id428c8e616482eff0f4327d2eac17e29bb3f6484
Reviewed-on: https://webrtc-review.googlesource.com/c/113303
Reviewed-by: Fredrik Solenberg <solenberg@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25915}
2018-12-06 12:06:34 +00:00
5b1477839d [Unified Plan] If "a=msid" is missing, create default stream.
Prior to this CL, if the "a=msid" attribute was missing it was treated
the same as if "no streams" were explicitly signaled (a=msid:-); the
receivers would not be associated with any streams.

In order to support legacy endpoints that don't recognize "a=msid" that
assume the Plan B behavior of a stream being created anyway, this CL
creates a stream with a random ID in such cases. For background, see
https://github.com/web-platform-tests/wpt/pull/14054.

Bug: chromium:907508
Change-Id: I9d9dd0e4ba8f9941f8652f4d7873adc560777cd9
Reviewed-on: https://webrtc-review.googlesource.com/c/112900
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Commit-Queue: Henrik Boström <hbos@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25901}
2018-12-05 09:53:21 +00:00
af2adda252 Explicit comparisons on NetworkRoute.
Since not all fields are compared on NetworkRoute structs, the ==
operator overload doesn't really make the code easier to read. In fact
the feature that it only compares a subset of the fields is only used
once, at the other places, all fields are compared.

Removing the overload makes it more clear what is compared at each call
site.

Bug: webrtc:9883
Change-Id: I74f7eb32b602aa33fd282a815b71a172ae3f6a8b
Reviewed-on: https://webrtc-review.googlesource.com/c/113001
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Sebastian Jansson <srte@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25891}
2018-12-04 12:36:50 +00:00
41390474fc Add LookupDtlsTransportByMid to proxy map
Bug: chromium:907849
Change-Id: Ib707f18fdf67617967b83cd17f0454d182b8011f
Reviewed-on: https://webrtc-review.googlesource.com/c/112907
Reviewed-by: Fredrik Solenberg <solenberg@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25885}
2018-12-04 10:29:32 +00:00
a201204215 Adding SDP parsing for Simulcast.
Parsing simulcast according to:
https://tools.ietf.org/html/draft-ietf-mmusic-sdp-simulcast-13#section-5.1
Created SdpSerializer for making serialized components more testable.
Simulcast functionality is still not accessible to users.

Bug: webrtc:10055
Change-Id: Ia6e4cef756cb954521dd19e22911f8eb6498880e
Reviewed-on: https://webrtc-review.googlesource.com/c/112160
Commit-Queue: Amit Hilbuch <amithi@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25883}
2018-12-03 20:13:53 +00:00
cc88737845 Parse ice_unwritable_timeout and ice_unwritable_min_checks from RTCConfiguration into IceConfig
These two configs are in both RTConfiguration and IceConfig,
but ParseIceConfig() function does not move them.

Bug: webrtc:10079
Change-Id: I11cbedfeabaf77228a253c7bc5e2781b28b08642
Reviewed-on: https://webrtc-review.googlesource.com/c/112546
Reviewed-by: Qingsi Wang <qingsi@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Commit-Queue: Qingsi Wang <qingsi@webrtc.org>
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25860}
2018-11-30 19:06:02 +00:00
ffa6ce4714 Add integration test for new GetStats() with many tracks
Bug: None
Change-Id: Ia134b4563edbb40e5082592666aad8ad70f1f1a4
Reviewed-on: https://webrtc-review.googlesource.com/c/112186
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25859}
2018-11-30 18:09:31 +00:00
a41959e550 [Unified Plan] Fix old GetStats() not associating track id
The method for looking up track ID by SSRC was never updated for
Unified Plan so it only looked at the first audio section and the
first video section.

This CL changes the method to look through all audio and video
media sections rather than just the first.

Bug: chromium:906988
Change-Id: Ie79e6162b2bd24b8ac9e983b5fa7360c96f030da
Reviewed-on: https://webrtc-review.googlesource.com/c/112223
Commit-Queue: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25833}
2018-11-28 20:22:10 +00:00
c64078fdc0 Log DTLS state changes to RtcEventLog
Bug: webrtc:9972
Change-Id: Icb2cdda87c1c42607ed06653e053699532f25e84
Reviewed-on: https://webrtc-review.googlesource.com/c/111023
Commit-Queue: Zach Stein <zstein@webrtc.org>
Reviewed-by: Qingsi Wang <qingsi@webrtc.org>
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Reviewed-by: Elad Alon <eladalon@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25832}
2018-11-28 19:49:29 +00:00
ad88c886d7 Add API for returning a webrtc::DtlsTransport for a MID on a PC
This includes a refactoring of jseptransport to store a refcounted
object instead of a std::unique_ptr to the cricket::DtlsTransport.

Bug: chromium:907849
Change-Id: Ib557ce72c2e6ce8af297c2b8deb7ec3a103d6d31
Reviewed-on: https://webrtc-review.googlesource.com/c/111920
Reviewed-by: Fredrik Solenberg <solenberg@webrtc.org>
Commit-Queue: Harald Alvestrand <hta@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25831}
2018-11-28 19:39:28 +00:00
3e70781361 [Cleanup] Add missing #include. Remove useless ones. IWYU part 2.
This is a follow-up to
https://webrtc-review.googlesource.com/c/src/+/106280.
This time the whole code base is covered.
Some files may have not been fixed though, whenever the IWYU tool
was breaking the build.

Bug: webrtc:8311
Change-Id: I2c31f552a87e887d33931d46e87b6208b1e483ef
Reviewed-on: https://webrtc-review.googlesource.com/c/111965
Commit-Queue: Yves Gerey <yvesg@google.com>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25830}
2018-11-28 18:25:07 +00:00
10403ae87c Add PeerConnection option to configure minimum audio jitter buffer delay.
Note that this value will override the minimum delay that is used for audio/video sync.

Bug: webrtc:10053
Change-Id: Ia129f6c9ee9da5d00a3d955afaaa6e8f0c2bee33
Reviewed-on: https://webrtc-review.googlesource.com/c/112121
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Jakob Ivarsson‎ <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25805}
2018-11-27 19:49:48 +00:00
8b5560218a Batch RTC event log output if using the new wire format.
The new wire format doesn't have much effect on compression unless
the log is encoded in reasonably large batches.

PeerConnection has two functions to start logging; one which takes
an output period (or batch size) in milliseconds and one which uses
a default period instead. This CL changes the default batch size to
5 seconds if the the new format is enabled as a field trial.

Bug: webrtc:8111
Change-Id: I638f6114325251b6a9acf4f863afe2688a3b0522
Reviewed-on: https://webrtc-review.googlesource.com/c/112130
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Commit-Queue: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25803}
2018-11-27 16:11:59 +00:00
352ce5c419 Expose delayed packet outage as a cumulative metric of samples in the new getStats API.
The stat will be exposed through origin trial described in:
https://docs.google.com/document/d/1stYIZhEmDZ7NJF9gjjsM66eLFJUdc-14a3QutrFbIwI

Change-Id: Ib191a11c6bd9e617abbe9dd82239b0c5b4e6b4e0
Bug: webrtc:10043
Reviewed-on: https://webrtc-review.googlesource.com/c/111922
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Reviewed-by: Minyue Li <minyue@webrtc.org>
Commit-Queue: Jakob Ivarsson‎ <jakobi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25802}
2018-11-27 15:10:09 +00:00
59cfd35438 Address vptr race condition while PeerConnection is destructed.
Auxiliary threads (worker, network) are still active
while PeerConnection is destructed, leading to race condition
in tests such as:
  * RTCStatsIntegrationTest.GetStatsFromCaller
  * RTCStatsIntegrationTest.GetsStatsWhileDestroyingPeerConnection

This CL prevents the conflict to happen by explicitly
closing the PeerConnection.

Bug: webrtc:9847
Change-Id: I40880bb9b193201711031b8c4563c6bbd4983c71
Reviewed-on: https://webrtc-review.googlesource.com/c/104820
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Commit-Queue: Yves Gerey <yvesg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25801}
2018-11-27 14:06:37 +00:00
e38a5a1acb Small cleanup to mediasession_unittest.cc
- Uses GMock EXPECT_THAT(..., ElementsAreArray(...)) instead of EXPECT_EQ
      with MAKE_VECTOR.
- Removes unnecessary std::string casts.

Bug: None
Change-Id: I5411ac0a2260176acb333efe9a47660aada03acd
Reviewed-on: https://webrtc-review.googlesource.com/c/111727
Reviewed-by: Seth Hampson <shampson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25789}
2018-11-26 20:20:52 +00:00
9289edae6f Revert "Replace the IceConnectionState implementation."
This reverts commit 1e87b4f32b73526f9caaae2a7bccfbd0cd84dcb9.

Reason for revert: Breaks internal project

Original change's description:
> Replace the IceConnectionState implementation.
> 
> PeerConnection::ice_connection_state() used to return a value based on both DTLS and ICE transports.
> Now that we have PeerConnection::peer_connection_state() to fill that role we can change the implementation of ice_connection_state over to match the spec.
> 
> Bug: webrtc:6145
> Change-Id: Ia4f348f728f24faf4b976c63dea2187bb1f01ef0
> Reviewed-on: https://webrtc-review.googlesource.com/c/108780
> Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
> Reviewed-by: Harald Alvestrand <hta@webrtc.org>
> Commit-Queue: Jonas Olsson <jonasolsson@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#25773}

TBR=kwiberg@webrtc.org,hbos@webrtc.org,hta@webrtc.org,jonasolsson@webrtc.org

Change-Id: Icc4368d120a4167286fa6ba2e884a3650b453eff
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:6145
Reviewed-on: https://webrtc-review.googlesource.com/c/111925
Reviewed-by: Alex Loiko <aleloi@webrtc.org>
Commit-Queue: Alex Loiko <aleloi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25775}
2018-11-23 16:19:05 +00:00
1e87b4f32b Replace the IceConnectionState implementation.
PeerConnection::ice_connection_state() used to return a value based on both DTLS and ICE transports.
Now that we have PeerConnection::peer_connection_state() to fill that role we can change the implementation of ice_connection_state over to match the spec.

Bug: webrtc:6145
Change-Id: Ia4f348f728f24faf4b976c63dea2187bb1f01ef0
Reviewed-on: https://webrtc-review.googlesource.com/c/108780
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Commit-Queue: Jonas Olsson <jonasolsson@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25773}
2018-11-23 15:05:18 +00:00
e3abb8134f Decouple //rtc_base:rtc_base_tests_utils from gunit.
This CL decouples //rtc_base:rtc_base_tests_utils from gunit by
moving gunit helpers (rtc_base/gunit.h) and rtc_base/testclient.h
(which depends on gunit helpers) to their own build target.

It also removes some unused dependencies in the WebRTC build graph.

Bug: None
Change-Id: Ia9820e84ff697da39b351eef73c45f6e4bdf2623
Reviewed-on: https://webrtc-review.googlesource.com/c/111861
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25769}
2018-11-23 12:52:46 +00:00
8af8896596 Expose jitter buffer flushes metric in new getStats api.
Origin trial experiment proposal (new statistic part):
https://docs.google.com/document/d/1stYIZhEmDZ7NJF9gjjsM66eLFJUdc-14a3QutrFbIwI/edit?ts=5bf5535c#

Bug: chromium:907113
Change-Id: I1d005291f9b47665f70c26148dbdcbb55564bef8
Reviewed-on: https://webrtc-review.googlesource.com/c/111505
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Reviewed-by: Jonas Olsson <jonasolsson@webrtc.org>
Reviewed-by: Henrik Boström <hbos@webrtc.org>
Commit-Queue: Ruslan Burakov <kuddai@google.com>
Cr-Commit-Position: refs/heads/master@{#25768}
2018-11-23 11:41:43 +00:00