Commit Graph

706 Commits

Author SHA1 Message Date
Paul Wells f49103a003 add participant job type (#3443)
* add participant job type

* cleanup

* deps
2025-02-18 00:40:56 -08:00
Raja Subramanian 56a61b6ce2 Safe access of proto fields. (#3436) 2025-02-15 05:51:53 +05:30
Raja Subramanian dc0ff45fd7 Fix panic due to nil Egress (#3431) 2025-02-14 10:17:32 +05:30
Raja Subramanian 1c3c70a136 Check for nil in sender view stats. (#3426)
Seeing some panic due to sender view being nil. It is possible to have
nil sender view and not-nil receiver view. For analytics, only sender
view is used. Handle nil properly.
2025-02-13 10:55:23 +05:30
Raja Subramanian 1ae2e48c2e Webhook analytics event. (#3423)
* Webhook analytics event.

* deps

* generate

* nil notifier
2025-02-13 10:39:45 +05:30
Raja Subramanian 045bd785a9 Record number of elements, keys size and values sizes separately. (#3415) 2025-02-08 13:12:48 +05:30
Raja Subramanian 99afbf587b Use a Twirp server hook to send API call details to telemetry. (#3401)
* Use a Twirp server hook to send API call details to telemetry.

* mage generate and clean up

* Add project_id

* deps

* - Redact requests
- Do not store responses
- Extract top level fields room_name, room_id, participant_identity,
  participant_id, track_id as appropriate
- Store status as int

* deps
2025-02-07 16:16:41 +05:30
Denys Smirnov ccbc988824 Pass error details and timeouts. (#3402) 2025-02-06 13:53:44 +02:00
Raja Subramanian abcaa9b8ab Fix /etc/validate route (#3403) 2025-02-05 23:20:20 +05:30
Raja Subramanian bb0ee1139c Drive-by misc changes. (#3399)
While working on a different service, noticed delegation of setting up
routes to the service itself. So, making that change and making some
methods internal only as there is no need to export them outside the
service.
2025-02-04 12:32:05 +05:30
Raja Subramanian c30204d56c Fix typo in SendData nonce length check. (#3370)
Definitely need new glasses :-(
2025-01-28 09:59:48 +05:30
Raja Subramanian db75092aa6 Use nonce in data messages to de-dupe SendData API. (#3366)
* Use nonce in data messages to de-dupe SendData API.

With API retries, it is possible that some data messages are sent
multiple times. Check the nonce (if present) to de-dupe data messages
before forwarding it to the clients.

* add nonce to UserPacket

* defer unlock

* 128-bit UUID as nonce

* - UUID nonce
- make a UserPacketDeduper module for easier re-use.

* deps

* feedback
2025-01-27 15:35:37 +05:30
David Zhao 30669722c3 fix: pass RoomConfig along when creating a new dispatch rule (#3367) 2025-01-26 23:36:42 -06:00
Paul Wells ef4b5faba1 close signal session is request messages are undeliverable (#3364) 2025-01-24 00:24:22 -08:00
Raja Subramanian 524441446f Room creation time with ms resolution (#3362) 2025-01-23 09:42:30 +05:30
Paul Wells 759e5f79e0 allocate node for autocreated room in agent dispatch (#3344) 2025-01-17 00:54:30 -08:00
Rajiv Gonzalez 25fa83926f Reject ingress if Enabled flag is false (#3293) 2025-01-16 17:19:26 -08:00
Raja Subramanian ae8c8bc941 Turn off TWCC for Firefox (#3333)
* Debug FF TWCC

* - TURN off TWCC for Firefox. Seems to fail with VP9 send, i.e. there are
  no TWCC feedback packets when sending VP9.
- Relax thresholds for congestion as staging data is showing
  oscillations.
- Clean up some logging.

* debug log a few more signal messages

* revert config

* revert config

* clean up
2025-01-15 10:32:59 +05:30
Alan Willard 5b61bbc446 remove code that deletes state from the store for rooms older than 24 hours (#3320) 2025-01-10 10:09:55 +05:30
David Zhao 6acb4bbd61 add room/participant to logger context for SIP APIs (#3290) 2024-12-26 00:23:21 -06:00
Raja Subramanian 8cf6cbb826 Structured logging of ParticipantInit (#3279)
* Structured logging of ParticipantInit

* use pointer
2024-12-20 11:12:50 +05:30
cnderrauber 713e67cd52 Thottle the publisher data channel sending when subscriber is slow (#3255)
* Thottle the publisher data channel sending when subscriber is slow

Avoid the publisher overwhelm the sfu data channel buffer when
the subscriber has lower receive bitrates. It will drop message
if the subscriber is considered too slow to block the entire room.

* Enable nack in mediaengine and disable it in transceiver as need

pion doesn't support per transciver codec configuration, so the nack of this session will be disabled
forever once it is first disabled by a transceiver.
https://github.com/pion/webrtc/pull/2972
2024-12-18 10:51:34 +08:00
cnderrauber 5dd6858acf Don't wait rtp packet to fire track (#3246)
* Don't wait rtp packet to fire track

Create track from sdp instead of first rtp packet,
it is consistent with the browser behavior and
will accelerate the track publication.

* fix test
2024-12-13 15:06:14 +08:00
Denys Smirnov dc6fe3aae5 Support SIP list filters. (#3240) 2024-12-09 22:57:47 +02:00
Raja Subramanian 8bb29c3a7b Fixes from probe controller refactor (#3222)
* Fixes from probe controller refactor

* fmt

* static check
2024-11-30 13:34:01 +05:30
cnderrauber 54f9f7de51 upgrade to pion/webrtc v4 (#3213) 2024-11-28 16:05:38 +08:00
Paul Wells 29c7906250 skip http request logging when the client aborts the request (#3195)
* skip http request logging when the client aborts the request

* cleanup
2024-11-22 00:42:49 -08:00
Raja Subramanian 9f25603213 One shot signalling mode (#3188)
* WIP

* comment

* Verify method on LocalParticipant

* cleanup

* clean up

* pass in one-shot-mode to StartSession

* null message source and sink

* feedback and also remove check in ParticipantImpl for one-shot-mode-filtering as a null sink can be used for that
2024-11-21 09:33:28 +05:30
Paul Wells 73fbc6b8bb convert psprc error to http code in rtc service failure response (#3187) 2024-11-19 19:45:00 -08:00
Paul Wells 9e4dae7107 add per message deflate to signal ws (#3174) 2024-11-14 00:35:30 -08:00
Denys Smirnov 55d084fd18 Annotate SIP errors with Twirp codes. (#3161) 2024-11-07 17:00:57 +02:00
Paul Wells 09f140afa8 auto create rooms during create agent dispatch api request (#3158) 2024-11-05 16:15:05 -08:00
Raja Subramanian 365e63230d Some misc clean up. (#3156)
* Some misc clean up.

- Have been seeing counterfeiter warnings about efficiency for a while
  with go:generate declaration multiple times in the same package.
  Address that: https://github.com/maxbrunsfeld/counterfeiter?tab=readme-ov-file#step-2b---add-counterfeitergenerate-directives
- A bit more readability on parameters passed to `sendLeave`

* spacing

* revert some deletes as the complaint was in analytics service only

* Declare in package only once.

Although the warning is about go:generate multiple times when directly
giving the interface to generate, have `go:generate` multiple times in a
package even with `-generate` ends up generating once per invocation.
Once per package is enough to run the generation just once.
2024-11-04 11:26:41 +05:30
Raja Subramanian 49b75e94a6 Consolidate operations on LocalNode. (#3140) 2024-10-25 18:57:23 +05:30
Paul Wells b0d3d65f18 update events package (#3126)
* update events package

* deps
2024-10-21 23:44:00 -07:00
David Zhao dd7cd7eafc Handle room configuration that's set in the grant itself (#3120)
* Handle room configuration that's set in the grant itself

* ensure refresh token contains updates

* deps

* dep

---------

Co-authored-by: Paul Wells <paulwe@gmail.com>
2024-10-21 23:31:12 -07:00
Benjamin Pracht d751f209d5 Allow requesting a dialtone during call transfer (#3122) 2024-10-21 21:05:31 -07:00
Raja Subramanian 40b10af960 Use monotonic time util. (#3112)
Thank you @paulwe for doing this. I was promising to do this for a
while, but just like other times, empty promises :-(
2024-10-17 10:49:24 +05:30
Ben Cherry 19c5ed6343 Parse python, cpp, unity-web, node sdks in clientinfo (#3110) 2024-10-16 20:18:44 -07:00
Denys Smirnov 50b4d6605e Type safe IP checks for SIP Trunks. (#3108) 2024-10-16 17:48:55 +03:00
Raja Subramanian 8221471b67 Protocol update to get more precise protoproxy timing (#3107)
* Protocol update to get more precise protoproxy timing

* really update protocol
2024-10-16 18:43:09 +05:30
David Zhao 33098337fc Support for attributes in initial agent token (#3097) 2024-10-14 22:45:10 -07:00
David Zhao c41913225d Log fields in SIP service (#3096) 2024-10-14 16:00:15 -07:00
David Zhao 2d6aa049c9 Improve agent job assignment logging (#3090)
* Improve agent job assignment logging

* add more agent logging

---------

Co-authored-by: Paul Wells <paulwe@gmail.com>
2024-10-13 00:56:51 -07:00
Paul Wells 00ac004604 use AgentDispatch in internal request (#3074)
* use AgentDispatch in internal request

* deps

* deps

* deps
2024-10-08 01:25:00 -07:00
Paul Wells 3261560098 api for agent worker job count (#3068)
* api for agent worker job count

* cleanup

* temp deps

* temp deps

* deps
2024-10-05 05:13:52 -07:00
Raja Subramanian 2491ee7c7c Make lite version of RTPStatsReceiver called RTPStatsReceiverLite. (#3065)
* Make lite version of RTPStatsReceiver called RTPStatsReceiverLite.

Refactor around that.

Will probably make some more flavors to have lighter versions still.

* update deps

* use MarshalLogArray

* use util
2024-10-05 10:50:25 +05:30
Paul Wells 8befc8224a use canonical room log field name (#3054) 2024-09-27 16:52:34 -07:00
Raja Subramanian 45f23f6fc4 Update protocol to get lower case check for kind and source. (#3048)
Also, log kind in starting RTC session and store a clone always in
participants.
2024-09-26 15:45:42 +05:30
Paul Wells 096157e706 clean up worker jobs in handler when job ends (#3042) 2024-09-25 03:04:01 -07:00