Skip to content

http and cli plugin routers collide #38

Open
bmeck opened this Issue Mar 13, 2012 · 5 comments

4 participants

@bmeck
a decoupled application framework member
bmeck commented Mar 13, 2012

if you use both flatiron.plugins.cli and flatiron.plugins.http right now app.router gets overriden.

@indexzero
a decoupled application framework member

Why would you use both of these?

@bmeck
a decoupled application framework member
bmeck commented Apr 25, 2012
@indexzero
a decoupled application framework member

Hmm ... Let me think about this. I'd prefer not to solve this with more namespacing, but that's the only solution I have in my head atm

@mikl
mikl commented Nov 28, 2012

Possibly a duplicate of #81.

@Southern

@mikl #81 would be a duplicate of this since it's #38. :3

@indexzero Ever decide what to do about this? Was looking into it earlier, but couldn't find a solution to the routing problem.

Another problem is that not only do the routers clash with each other, but so does each plugin setting app.start in its exports.attach function. So whichever plugin you include last is the one that will initialize.

The start process is an easy fix. Just have to move the app.inits in app.start to exports.init and then add App.prototype.start to call app.init, which will call both of the exports.inits from the CLI and HTTP plugin.

However, then the routing problem comes into play and that's where I didn't want to venture to since this PR was open and it seems that we're wanting to avoid namespacing it again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.