Comments (6)
I think the actions still need to use the context inside of the http call by attaching it to the request, but it's good as an entry point!
Ah, that should be in 6145404, which I submitted prior.
from goupnp.
ahhhh cool cool then it should be good from my pov!
from goupnp.
Short answer: yes, this library really should use contexts, and not just in the SOAP calls.
This is something that I started thinking about doing a while back, and there was some work I did on the v2
branch to do that and other things. For one reason or another, I never completed that work, and since then various fixes and changes have merged into master
.
There's a lot of things I'd do differently in this package if I were to redesign them, but they'd almost all be breaking changes. It would likely be best to do such breaking changes in bulk on a separate v2 package to avoid breaking existing users.
If this package branched out to a v2, it'd be good to know which things need doing, not just contexts. IPv6 is one thing, although I know basically zero about how multicast/UPnP works with IPv6. There's also other breaking API changes I'd likely make, which would probably make substantial differences to how the SOAP APIs are defined.
I need to ponder that a bit, but would be interested in your thoughts and others on that.
from goupnp.
Hm, I'm not particularly experienced in releasing packages and maintaining compatibility for older versions.
What I think would be best would probably be having a numbered version as you suggest, and seems to be recommended by the golang team. One thing for a v2 might be to release a non major version, and expect breaking changes such as adding IPv6 or others before reaching a completed v2. I suspect that trying to do everything in bulk would probably take way too long and lead to the package not being completed, as is the case when there is feature creep.
One other approach patching existing clients might be to make it so that a UPnP client could patch in a context for the next call... but that seems really hacky and not ideal. But that's just a random idea.
from goupnp.
So hopefully commit 5a0d4bd fixes your current needs. I've made some start on a v2, but as you note it will likely take a while for the limited free time I spend on goupnp. Let me know if this change doesn't work well for you.
from goupnp.
I think the actions still need to use the context inside of the http call by attaching it to the request, but it's good as an entry point!
from goupnp.
Related Issues (20)
- Unable to find devices most of the time HOT 7
- It's not possible to query ssdp:all HOT 1
- Incorrect err (nil) returned incase of timeout in httpu HOT 6
- Discover UPnP as not active if UPnP not ON in device HOT 4
- Show devices connected to discovered UPnP enabled device. HOT 2
- Why can't i find this upnp device (http://192.168.61.1:5000/rootDesc.xml)? HOT 5
- GetTotalBytesSent() can't parse value, if it's negative HOT 3
- Fail on http post request to router. HOT 12
- httpu multicast fails on multiple interfaces HOT 7
- Please provide example of AV dlna device implementation (audio) HOT 2
- Could you specify some examples? HOT 10
- Making charset dependency optional HOT 6
- SSDPRawSearch: With the same USN, ipv4Response was replaced by ipv6Response, which is not effected for ipv4only client. HOT 1
- httpu: error while parsing response HOT 4
- Any plan to add SSDP Server Support ? HOT 1
- get the IP associated with the interface used to successfully discover the upnp setup ? HOT 26
- feat: context everywhere and non-blocking results HOT 2
- update the guide HOT 1
- Provide an API to use specific ip addresses for discovery HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from goupnp.