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

Track / expose mixer status #196

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open

Conversation

benlangfeld
Copy link
Member

WIP. See adhearsion/adhearsion#411

Todo:

@coveralls
Copy link

Coverage Status

Coverage decreased (-11.49%) to 87.58% when pulling 195518e on feature/mixer_status into 85f7b2c on develop.

@benlangfeld
Copy link
Member Author

Support for this was recently added to mod_rayo.

@pungoyal
Copy link

The rayo spec Section 6.4 Mixers Example 41 suggests that the mixer presence is notified as:

<presence from='myMixer@mixer.shakespeare.lit'
          to='juliet@capulet.lit/balcony'>
  <c xmlns='http://jabber.org/protocol/caps'
     hash='sha-1'
     node='urn:xmpp:rayo:mixer:1'
     ver='QgayPKawpkPSDYmwT/WM94uAlu0='/>
</presence>

This has a xmlns of http://jabber.org/protocol/caps. How will Punchblock::Event::MixerCreated register itself to be triggered for this presence notification (from: https://github.com/adhearsion/punchblock/blob/develop/lib/punchblock/core_ext/blather/stanza.rb#L10)?

One way out is to put if-else blocks in https://github.com/adhearsion/punchblock/blob/develop/lib/punchblock/connection/xmpp.rb#L132 and manually trigger Punchblock::Event::MixerCreated and Punchblock::Event::MixerDestroyed. That will be ugly.

Is there another way of achieving the same?

@benlangfeld
Copy link
Member Author

So instead of if-else blocks, we'll could use guards with a further set of handlers defined here: https://github.com/adhearsion/punchblock/blob/develop/lib/punchblock/connection/xmpp.rb#L171. If you'd like to make a pass at this, that'd be lovely. I'll happily review any incoming PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants