2701 Commits

Author SHA1 Message Date
cnderrauber
dc6ed04c39 go mod tidy 2024-07-30 14:52:50 +08:00
cnderrauber
e90502104c solve comments 2024-07-30 10:51:34 +08:00
cnderrauber
11360cd257 WHEP support 2024-07-29 16:20:52 +08:00
cnderrauber
b74b03024c WIP 2024-07-25 11:11:46 +08:00
cnderrauber
f6f6cca133 don't push 0 ssrc probing packets to pending queue (#2888) 2024-07-23 17:58:04 +08:00
Benjamin Pracht
0fd09d73c1 Instantiate default agent dispatches in rtc for better backward compatibility (#2886) 2024-07-22 08:44:13 -07:00
Raja Subramanian
bd616d6074 Split ICE candidate queue. (#2885)
Shared ICE candidate queue meant only one of PUBLISHER/SUBSCRIBER pc got
final candidate notification. Split the queue.
2024-07-20 10:25:06 +05:30
Benjamin Pracht
73b3a91a5c Use RoomConfiguration message from protocol (#2882) 2024-07-19 13:54:33 -07:00
cnderrauber
0c5b5537b2 Don't create DDParser for non-svc codec (#2883) 2024-07-19 10:52:27 +08:00
Benjamin Pracht
a877ba2352 Partial support for agent dispatch management (#2872)
- Store agent dispaches independently of room agents on rtc.Room
- Serialize agent dispatches in rtc.Room
- Support for agent dispatch and job serialization in redis

The agent Job object references denormalized Room and ParticipantInfo object. When storing Jobs, this sets the Room to nil, and only stores the Participant identity field. When read back, these fields need to be set to their current value.
2024-07-18 13:36:43 -07:00
Raja Subramanian
95f4b304ef Prevent data race. (#2881)
* Prevent data race.

CI is reporting some data race warnings. Prevent that.

* prevent recursive lock

* prevent more recursive locks

* more lock dance
2024-07-18 19:53:41 +05:30
Raja Subramanian
91782b68be Recalc gap of sequence number after forcing rollover. (#2880) 2024-07-18 18:58:10 +05:30
Paul Wells
afda860162 prevent race in telemetry worker cleanup (#2879) 2024-07-18 03:37:45 -07:00
cnderrauber
e3597d780d Update pion to handle different extensions in two media section (#2878)
Also remove the code to disable DD extension for vp8/h264, it
cause DD can't be processed if the first video track is non-svc
codec.
2024-07-18 14:49:04 +08:00
Raja Subramanian
4733e864bc Rollover sequence number when time stamp is moving forward. (#2876)
* Rollover sequence number when time stamp is moving forward.

Seeing large gaps in sequence number due to potential network issues.
In that gap, the sequence number could roll over.

Using packet time jumps to figure out if a roll over could have happened
and force roll over the sequence number to ensure that it does not flow
backwards.

* fix test
2024-07-18 11:02:52 +05:30
renovate[bot]
fbc0cf3f86 Update golang.org/x/exp digest to 1d5bc16 (#2856)
Generated by renovateBot

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-07-16 11:44:41 -07:00
Paul Wells
c905336fec mark final ice candidate (#2871)
* add IsFinal flag to last ice candidate

* deps
2024-07-16 09:50:55 -07:00
Benjamin Pracht
8605ada485 Update protocol (#2867) 2024-07-16 09:38:59 -07:00
Paul Wells
9f42063fed use atomic pointer for MediaTrackReceiver TrackInfo (#2870) 2024-07-16 02:39:14 -07:00
Raja Subramanian
3621e9957e Prevent deadlock when adding down track. (#2869)
* Prevent deadlock when adding down track.

* revert down track lock scope change
2024-07-16 12:24:45 +05:30
Raja Subramanian
f7695cf9f4 Move track update methods to LocalParticipant. (#2868) 2024-07-16 08:09:46 +05:30
Raja Subramanian
f3d3ec1ce7 Record packet/octet count in sender report. (#2864)
Seeing cases of huge jumps in sender erport rtp time stamp
(of the order of minutes) a few hundred ms after start of track.
Only less than 20 packets have been published at that time as seen by
server. Adding these to sender report to check if client thinks it has
sent much more.
2024-07-16 07:59:27 +05:30
Benjamin Pracht
a9aa65fdc6 Remove unused fields from RegisterWorkerRequest (#2866) 2024-07-15 15:22:20 -07:00
renovate[bot]
fe05322f7f Update pion deps (#2840)
Generated by renovateBot

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-07-16 00:26:00 +05:30
cnderrauber
e7424e5a8e don't send unknown signal message to rust sdk with protocol 9 (#2860)
rust sdk can't handle unknown message (ErrorResponse and
TrackSubscribed)
2024-07-16 00:03:54 +05:30
Raja Subramanian
e815c99eac Log roll back reason. (#2865)
There are cases of subscriber of a FF publisher not able to lock onto
layer 0 and kept rolling back till it switched to a higher layer and
then it could switch to layer 0. Must have been due to not having a
sender report. Can't think of a reason why that would be missing.
Logging more to debug this further.

Also, using a wrapping logger because of this bug: https://github.com/uber-go/zap/issues/836
Tried using `json:"" yaml:""` tag for `refInfos` field and all fields
inside `refInfo` struct. But, they were still logging nils. So, using
the wrapper logger.
2024-07-15 23:54:45 +05:30
Raja Subramanian
affcd1ffdb Support updating local track features when pending. (#2863) 2024-07-15 23:51:39 +05:30
cnderrauber
5e1b18dab3 Add option to disable ice lite (#2862)
Some sfu's ice agent implementation has problem
to establish ice connection with lite ice agent,
add option to let client to disble it in server side.
2024-07-15 15:11:46 +08:00
Raja Subramanian
faa66d1138 Make sender report pass through an option. (#2861)
Enabled by default.

Also, tweak the long term propagation delay a bit. The first propagation
delay itself was too high and the long term initialized with a high
value. Prevent that and also ensure large negtaives do not have an
effect by using a lower bound of 0. Lower bound of 0 is okay as the main
purpose is to track sustained high positive values.
2024-07-15 11:27:31 +05:30
cnderrauber
a995c71f84 Fallback to primary encoding if redundant block overflow (#2858)
* Fallback to primary encoding if redundant block overflow

* revert mtu change
2024-07-12 16:39:54 +08:00
Raja Subramanian
1a4b1d30db Revert to protocol with go-jose@v3 (#2857)
As dev mode uses a short secret, revert it for now.
2024-07-12 13:40:24 +05:30
Raja Subramanian
09e3aef859 Check size limits on metadata and name set from client. (#2850)
* Send error response when update metadata fails.

Keeping it simple for the first implementation.
- Send error response only if request_id != 0
- Two kinds of errors notified
  o does not have permissions - NOT_ALLOWED
  o attributes exceeds size limits -  INVALID_ARGUMENT

* Check size limits on metadata and name set from client.

Added a name length limit also.

* check name length in service update participant path also

* limit check in limit config

* update protocol

* longer keys
2024-07-12 09:57:17 +05:30
David Colburn
ff66b545b4 update protocol/room internal (#2855) 2024-07-11 21:12:35 -07:00
Benjamin Pracht
6c1d5e8699 Do not create room in UpdateRoomMetadata (#2854) 2024-07-11 17:50:30 -07:00
Benjamin Pracht
a1f8e879cd Allow specifying room configuration in token (#2853) 2024-07-10 20:48:19 -07:00
dependabot[bot]
a44874cbc4 Bump google.golang.org/grpc from 1.64.0 to 1.64.1 (#2851)
Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.64.0 to 1.64.1.
- [Release notes](https://github.com/grpc/grpc-go/releases)
- [Commits](https://github.com/grpc/grpc-go/compare/v1.64.0...v1.64.1)

---
updated-dependencies:
- dependency-name: google.golang.org/grpc
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-07-11 00:17:15 +05:30
Raja Subramanian
b8847cd8e9 Send error response when update metadata fails. (#2849)
Keeping it simple for the first implementation.
- Send error response only if request_id != 0
- Two kinds of errors notified
  o does not have permissions - NOT_ALLOWED
  o attributes exceeds size limits -  INVALID_ARGUMENT
2024-07-10 23:26:44 +05:30
Denys Smirnov
40d7a8add0 Always forward DTMF data messages. (#2848) 2024-07-10 00:29:49 +03:00
cnderrauber
deee816d0a Forward correct payload type for mixed up red/primary payload (#2847)
* Forward correct payload type for mixed up red/primary payload

* empty line

* log field & test case
2024-07-09 23:04:47 +08:00
Raja Subramanian
27f6794e77 Check sender report against media path. (#2843)
Seeing cases (mostly across relay) of large first packet time adjustment
getting ignored. From data, it looks like the first packet is extremely
delayed (some times of the order of minutes) which does not make sense.

Adding some checks against media path, i. e. compare RTP timestamp from
sender report against expected RTP timestamp based on media path
arrivals and log deviations more than 5 seconds.

Another puzzling case. Trying to understand more.

Also, refactoring SetRtcpSenderReportData() function as it was getting
unwieldy.
2024-07-09 09:20:27 +05:30
cnderrauber
4e9ab46091 use correct payload type for red primary encoding (#2845) 2024-07-09 10:30:05 +08:00
Benjamin Pracht
fb7eb3450e Update agents service to updated protocol (#2837)
- Deprecate namespace field
- Restore former semantic of starting a job for each registered namespace, for a given Agent Name
- Add agentName field
- Use "dispatcher" naming convention
2024-07-08 17:09:11 -07:00
renovate[bot]
e4fba5634a Update golang.org/x/exp digest to 46b0784 (#2841)
Generated by renovateBot

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-07-08 00:09:10 -07:00
Raja Subramanian
acbd4ea104 Handle cases of long mute/rollover of time stamp. (#2842)
* Handle cases of long mute/rollover of time stamp.

There are cases where the track is muted for long enough for timestamp
roll over to happen. There are no packets in that window (typically
there should be black frames (for video) or silence (for audio)). But,
maybe the pause based implementation of mute is causing this.

Anyhow, use time since last packet to gauge how much roll over should
have happened and use that to update time stamp. There will be really
edge cases where this could also fail (for e. g. packet time is affected
by propagation delay, so it could theoretically happen that mute/unmute
+ packet reception could happen exactly around that rollover point and
  miscalculate, but should be rare).

As this happen per packet on receive side, changing time to `UnixNano()`
to make it more efficient to check this.

* spelling

* tests

* test util

* tests
2024-07-08 11:07:20 +05:30
Raja Subramanian
39c59d913d Do not warn on padding (#2839) 2024-07-07 12:30:54 +05:30
renovate[bot]
2619bc366e Update pion deps (#2781)
Generated by renovateBot

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-07-06 23:13:03 -07:00
Raja Subramanian
2bcfcbc354 Log mime and subscriberID for downtrack and descendents (#2838) 2024-07-06 23:15:23 +05:30
cnderrauber
70fbba2844 Add track subscribed notification to publisher (#2834)
* Add track subscribed notification to publisher

* update go mod
2024-07-05 21:57:03 +08:00
Raja Subramanian
bfb7db2d91 RTP packet validity check. (#2833)
Adding some checks before packet is forwarded to check for anomalies.
Will remove after a round of debug.
2024-07-04 12:42:25 +05:30
cnderrauber
7a5c90dc01 log non-trickle candidate in details (#2832)
* log non-trickle candidate in details

* fix test
2024-07-03 14:16:58 +08:00