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

JVB/Web OCTO region sharding support #111

Open
anirbandas18 opened this issue Apr 16, 2024 · 9 comments
Open

JVB/Web OCTO region sharding support #111

anirbandas18 opened this issue Apr 16, 2024 · 9 comments
Assignees
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@anirbandas18
Copy link

anirbandas18 commented Apr 16, 2024

Hi,

I would like to know if this helm-chart supports a Jitsi shard and videobridge pools naturally out of the box?

jitsi shard = web + jicofo + prosody
videobridge pools = jvb replicas (already supported I guess)

My use case is to have multiple shards accessing a common set of videobridges amongst them.

Will this helm-chart support my use case naturally or do i have to modify it or roll out my own helm-charts?

@spijet
Copy link
Collaborator

spijet commented Apr 16, 2024

Hello @anirbandas18!

As for now, JVB multi-replica setups are supported via OCTO, and same should hold true for the Web component. Not sure about Jicofo, and Prosody is a stateful service holding all internal state of Jitsi Meet components, so sharding it should roughly be equal to deploying multiple (separate) Jitsi Meet instances, if I understand it right. See also #89 for a similar question.

There's an ongoing discussion about splitting JVB replicas to OCTO regions in #107, you can join.

@spijet spijet closed this as completed Apr 16, 2024
@spijet spijet reopened this Apr 16, 2024
@anirbandas18
Copy link
Author

So, my idea is to apply horizontal pod auto scaling to a jitsi shard (as defined above) which should handle the stateful nature of prosody as well and use octo in conjunction between jicofo of each shard vs the common jvb in the videobridge pool by ensuring each shard sets the correct userRegion value for jicofo to select a jvb from the pool properly.

Does this sound achievable ?

@spijet
Copy link
Collaborator

spijet commented Apr 16, 2024

AFAICT, HPA operates on groups of identical pods, so by definition it would be possible to use it to scale individual groups of Jitsi Web or JVB pods (as in separate auto-scaling groups for different regions or one "global" auto-scaling group), not to create new regions/shards.

@anirbandas18
Copy link
Author

anirbandas18 commented Apr 17, 2024

does this helm-chart support HPA of such group of pods?

what do you mean by creating new region/shards in this context?

@spijet
Copy link
Collaborator

spijet commented Apr 17, 2024

Unfortunately not, this is not supported at the moment.

As for the regions/shards, here's an example from current main branch:

# templates/jvb/configmap.yaml
  {{- if .Values.octo.enabled }}
  ENABLE_OCTO: "1"
  JVB_OCTO_BIND_PORT: "4096"
  JVB_OCTO_REGION: "all"
  {{- end }}

The last variable (JVB_OCTO_REGION) tells us that all JVB pods (no matter the replica count) are assigned to the same OCTO region, called all, and all the pods will be equally eligible for use by all clients, no matter their IP/location/etc.

In order to introduce different shards/regions we have to rework this part of the chart, so that we can create separate JVB Deployments with separate ConfigMaps that specify different values for JVB_OCTO_REGION, and then do the same for the Web component as well.

@spijet spijet added the enhancement New feature or request label Apr 17, 2024
@spijet spijet self-assigned this Apr 17, 2024
@spijet spijet changed the title Sharding support JVB/Web OCTO region sharding support Apr 17, 2024
@spijet spijet pinned this issue Apr 17, 2024
@anirbandas18
Copy link
Author

Will this be reworked as an enhancement?

@spijet
Copy link
Collaborator

spijet commented Apr 17, 2024

Maybe/probably, if I come up with a good enough way to implement it. :)

@anirbandas18
Copy link
Author

Anyway I can help?

@spijet
Copy link
Collaborator

spijet commented Apr 18, 2024

PRs are always welcome, so you can try implementing it if you have an idea how to do it. :)

I'll try to do so too, but unfortunately at the moment I'm a bit caught up at my full-time job.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants