Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[1.x] Suggestion: add the feed IDS for the subscriber's data stream #2967

Closed
jamken opened this issue May 3, 2022 · 3 comments
Closed

[1.x] Suggestion: add the feed IDS for the subscriber's data stream #2967

jamken opened this issue May 3, 2022 · 3 comments
Labels
multistream Related to Janus 1.x

Comments

@jamken
Copy link

jamken commented May 3, 2022

What version of Janus is this happening on?
1.0.1

Have you tested a more recent version of Janus too?
Yes

Was this working before?
From the janus_videoroom_subscriber_streams_summary()

		json_t *m = json_object();
		json_object_set_new(m, "type", json_string(janus_videoroom_media_str(stream->type)));
		json_object_set_new(m, "active", (ps || stream->type == JANUS_VIDEOROOM_MEDIA_DATA) ? json_true() : json_false());
		json_object_set_new(m, "mindex", json_integer(stream->mindex));
		json_object_set_new(m, "mid", json_string(stream->mid));
		json_object_set_new(m, "ready", g_atomic_int_get(&stream->ready) ? json_true() : json_false());
		json_object_set_new(m, "send", stream->send ? json_true() : json_false());
		if(ps && stream->type == JANUS_VIDEOROOM_MEDIA_DATA) {
			json_object_set_new(m, "sources", json_integer(g_slist_length(stream->publisher_streams)));
		} else if(ps && stream->type != JANUS_VIDEOROOM_MEDIA_DATA) {
			if(ps->publisher) {
               .......

The current code only give the number of feed on the subscriber data stream, which is very hard for the client to know and maintain who give his data packet to this subscriber and it's a important infomation for the applicawtion.

Suggest: sources field maintain a feed ID list instead of a number.

@jamken jamken added the multistream Related to Janus 1.x label May 3, 2022
@lminiero
Copy link
Member

lminiero commented May 3, 2022

I don't think the user will have problems figuring out who sent them a packet, since the label will be the participant ID, and they should know the participant IDs from all the notifications the plugin sends (otherwise they wouldn't have subscribed in the first place). That said, I agree that having an explicit list of IDs in the data subscription might help: it will need to be a separate property, though, since I'm not going to just change the type of an existing one as that would cause a breaking change.

I'll add this to the TODO list, but I'm not sure when I'll have time to work on that.

@jamken
Copy link
Author

jamken commented May 3, 2022

That's OK, Actually, if there is an explicit list of IDs in the data subscription, it would be easy for me to implement Janus-cloud(https://github.com/OpenSight/janus-cloud).
Thank you for your quickly reply

@lminiero
Copy link
Member

lminiero commented May 9, 2022

Implemented in the commit above.

mwalbeck pushed a commit to mwalbeck/docker-janus-gateway that referenced this issue May 25, 2022
This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [meetecho/janus-gateway](https://github.com/meetecho/janus-gateway) | patch | `v1.0.1` -> `v1.0.2` |

---

### Release Notes

<details>
<summary>meetecho/janus-gateway</summary>

### [`v1.0.2`](https://github.com/meetecho/janus-gateway/blob/HEAD/CHANGELOG.md#v102---2022-05-23)

[Compare Source](meetecho/janus-gateway@v1.0.1...v1.0.2)

-   Abort DTLS handshake if DTLSv1\_handle_timeout returns an error
-   Fixed rtx not being offered on Janus originated PeerConnections
-   Added configurable property to put a cap to task threads \[[Issue-2964](meetecho/janus-gateway#2964)]
-   Fixed build issue with libressl >= 3.5.0 (thanks [@&#8203;ffontaine](https://github.com/ffontaine)!) \[[PR-2980](meetecho/janus-gateway#2980)]
-   Link to -lresolv explicitly when building websockets transport
-   Fixed RED parsing not returning blocks when only primary data is available
-   Fixed typo in stereo support in EchoTest plugin
-   Added support for dummy publishers in VideoRoom \[[PR-2958](meetecho/janus-gateway#2958)]
-   Added new VideoRoom request to combine subscribe and unsubscribe operations \[[PR-2962](meetecho/janus-gateway#2962)]
-   Fixed incorrect removal of owner/subscriptions mapping in VideoRoom plugin \[[Issue-2965](meetecho/janus-gateway#2965)]
-   Explicitly return list of IDs VideoRoom users are subscribed to for data \[[Issue-2967](meetecho/janus-gateway#2967)]
-   Fixed data port not being returned when creating Streaming mountpoints with the legacy API
-   Fix address size in Streaming plugin RTCP sendto call (thanks [@&#8203;sjkummer](https://github.com/sjkummer)!) \[[PR-2976](meetecho/janus-gateway#2976)]
-   Added custom headers for SIP SUBSCRIBE requests (thanks [@&#8203;oriol-c](https://github.com/oriol-c)!) \[[PR-2971](meetecho/janus-gateway#2971)]
-   Make SIP timer T1X64 configurable (thanks [@&#8203;oriol-c](https://github.com/oriol-c)!) \[[PR-2972](meetecho/janus-gateway#2972)]
-   Disable IPv6 in WebSockets transport if binding to IPv4 address explicitly \[[Issue-2969](meetecho/janus-gateway#2969)]
-   Other smaller fixes and improvements (thanks to all who contributed pull requests and reported issues!)

</details>

---

### Configuration

📅 **Schedule**: At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, click this checkbox.

---

This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate).

Reviewed-on: https://git.walbeck.it/walbeck-it/docker-janus-gateway/pulls/79
Co-authored-by: renovate-bot <[email protected]>
Co-committed-by: renovate-bot <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
multistream Related to Janus 1.x
Projects
None yet
Development

No branches or pull requests

2 participants