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

Split feathers transports into their own modules #156

Closed
3 tasks done
ekryski opened this issue Nov 4, 2015 · 11 comments · Fixed by #188
Closed
3 tasks done

Split feathers transports into their own modules #156

ekryski opened this issue Nov 4, 2015 · 11 comments · Fixed by #188
Assignees
Milestone

Comments

@ekryski
Copy link
Contributor

ekryski commented Nov 4, 2015

We should do this so that people don't need to include compile engine.io when they don't need to. It also helps with our mantra of keeping things small and modular.

Modules that should be created:

@ekryski ekryski added the task label Nov 4, 2015
@ekryski ekryski added this to the 2.0.0 milestone Nov 4, 2015
@ahdinosaur
Copy link

this would be awesome. 👍

@ahdinosaur
Copy link

i reckon it'd be even more magical if these modules also contained their respective client transport functionality in feathers-client, specified using the browser field. 🌸

@daffl
Copy link
Member

daffl commented Dec 30, 2015

@ahdinosaur What do you mean? I would think since the client adapters are so small (e.g. https://github.com/feathersjs/feathers-client/blob/master/src/sockets/base.js is the code for websocket clients) we probably don't need to split those up.

Status of this is that I already split out the server side REST API provider at feathers-rest with the other ones to follow very quickly.

@ahdinosaur
Copy link

@daffl let's say i'm using the mythical feathers-primus, then i only want the code you linked, not the code for the rest client adapters. similarly, if i'm using feathers-rest then i only want the code for the rest adapters (you could even split these up, but eh). so i think it'd be pretty sweet to combine the server and the client code into the same module, also because i'm interested in isomorphic feathers (removing feathers-client entirely). 😄

@ekryski
Copy link
Contributor Author

ekryski commented Dec 30, 2015

Hmm. @ahdinosaur I sort of get what you're going after but not really... ha ha.

feathers-client is isomorphic and can be used both server and client side. @daffl is currently in the process of splitting out the purely server side pieces into feathers-rest, feathers-socketio, and feathers-primus so that you don't have install them if you aren't going to use them (it's rare that you need socketio and primus at the same time).

So were you thinking that you wanted to use the server side stuff client side as well? Maybe you didn't know that feathers-client is isomorphic?

@ahdinosaur
Copy link

hmm, yeah i messed up my comment about isomorphism. i guess the question on my mind is what it'd mean for feathers to provide an interface like multilevel, multiplex-rpc, or muxrpc.

so here's a more concrete strawman proposal, to throw some more spaghetti on the wall and see if anything sticks 🍝

@daffl
Copy link
Member

daffl commented Dec 30, 2015

I like it. We'd just make Feathers v2 depend on feathers-client and pull out the transports for the client into the respective server provider module (feathers-rest, feathers-socketio and feathers-primus). Everything else is just mapping it correctly in the browser field.

Could you maybe create a small example app we can test it with?

@ekryski
Copy link
Contributor Author

ekryski commented Dec 30, 2015

👍 to all of that. I'd also like to see a quick example app that would be sweet.

If it would be a quick change and we can squeeze it into the 2.0 release then I'm down with that, otherwise maybe a fast follow 3.0 release? We have a lot of stuff into this 2.0 release and I'd really like to get a new version out in early January.

@ahdinosaur
Copy link

sweet. :)

Could you maybe create a small example app we can test it with?

yep, here's a quick example i just threw together that demonstrates the three different use cases (node server, node client, browser client) of using feathers with the rest transport. hope that helps, not sure exactly what kind of example is most helpful.

@ekryski
Copy link
Contributor Author

ekryski commented Dec 30, 2015

As I was showering this morning I had a thought that we'll need to make sure that it still works in React Native as well because it's not a Node runtime and it's not a browser so sometimes things get a bit quirky.

@lock
Copy link

lock bot commented Feb 8, 2019

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue with a link to this issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Feb 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants