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

Event subscriptions #2

Open
smaiLee opened this issue Aug 25, 2017 · 5 comments
Open

Event subscriptions #2

smaiLee opened this issue Aug 25, 2017 · 5 comments

Comments

@smaiLee
Copy link
Contributor

smaiLee commented Aug 25, 2017

First of all: Nice work!

Your client doesn't know anything about events, right? Or did I just miss this in code?

@flyte
Copy link
Owner

flyte commented Aug 25, 2017

Nope, that's not something I've implemented just yet. I expect we could add the configuration of the event subscription, but not necessarily the actual server for it to call back to - that may be beyond the scope of this library.

What do you think?

@smaiLee
Copy link
Contributor Author

smaiLee commented Aug 25, 2017

Actually I'm just at the beginning of knowing UPnP and didn't yet investigate what the call back server has to do in detail 😄
But I see the problem of implementing a long living server in the library.

But otherwise a control point has to implement events. And actually this library could provide anything a control point needs.

As far as I read the events are sent by HTTP verb NOTIFY and have the sequence number in HTTP header.
So, unfortunately, you can not just use a "normal" webserver for call back and parse the received content by this lib.

@flyte
Copy link
Owner

flyte commented Aug 26, 2017

What you see here is my current understanding of uPnP - I learned it while writing this library :)

I think perhaps we can add something to make handling the incoming messages simpler, as well as sending the HTTP SUBSCRIBE request. I'd have to have a play around with it/read the documentation again to see what's required.

@flyte
Copy link
Owner

flyte commented Aug 29, 2017

I've added event subscription/renewal/deletion to the library. In the next episode I'll add a way of parsing the responses too. Leaving this issue open until then.

@castorinop
Copy link

Can you write an example how use?

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

No branches or pull requests

3 participants