Has anyone tried hooking up routing within a Reel app? I wouldn't expect anything terribly complex, perhaps just enough to support basic API-style operations? http_router (https://github.com/joshbuddy/http_router) seems like it might be usable in a Reel context.
On Mon, Nov 5, 2012 at 9:02 PM, Doug Mayer <dougtma...@gmail.com> wrote:
> Has anyone tried hooking up routing within a Reel app? I wouldn't expect
> anything terribly complex, perhaps just enough to support basic API-style
> operations? http_router (https://github.com/joshbuddy/http_router) seems
> like it might be usable in a Reel context.
On Monday, November 5, 2012 9:02:56 PM UTC-8, Doug Mayer wrote:
> Has anyone tried hooking up routing within a Reel app? I wouldn't expect > anything terribly complex, perhaps just enough to support basic API-style > operations? http_router (https://github.com/joshbuddy/http_router) seems > like it might be usable in a Reel context.
Webmachine does indeed look pretty slick. I'm having trouble getting its adapter-based system to hook into our existing supervision tree, though. Are you aware of any design that may lend itself well to being started with a top-level supervision group?
I tried creating a wrapper around a Webmachine::Application instance but things seemed to run amok with traps being ignored, etc. Perhaps I just have a little something wrong, which I can dig into further, but I don't want to lose more time on it if it's a clear loser to those more comfortable with such a setup.
On Tuesday, November 6, 2012 at 1:25 AM, Tony Arcieri wrote:
> The webmachine-ruby project has a Reel adapter, a router, and is also a pretty nifty HTTP framework in general:
> On Mon, Nov 5, 2012 at 9:02 PM, Doug Mayer <dougtma...@gmail.com (mailto:dougtma...@gmail.com)> wrote:
> > Has anyone tried hooking up routing within a Reel app? I wouldn't expect anything terribly complex, perhaps just enough to support basic API-style operations? http_router (https://github.com/joshbuddy/http_router) seems like it might be usable in a Reel context.
On Tue, Nov 6, 2012 at 4:07 PM, Doug Mayer <dougtma...@gmail.com> wrote:
> Webmachine does indeed look pretty slick. I'm having trouble getting its
> adapter-based system to hook into our existing supervision tree, though.
> Are you aware of any design that may lend itself well to being started with
> a top-level supervision group?
> I tried creating a wrapper around a Webmachine::Application instance but
> things seemed to run amok with traps being ignored, etc. Perhaps I just
> have a little something wrong, which I can dig into further, but I don't
> want to lose more time on it if it's a clear loser to those more
> comfortable with such a setup.
> Thanks,
> Doug
> On Tuesday, November 6, 2012 at 1:25 AM, Tony Arcieri wrote:
> The webmachine-ruby project has a Reel adapter, a router, and is also a
> pretty nifty HTTP framework in general:
> On Mon, Nov 5, 2012 at 9:02 PM, Doug Mayer <dougtma...@gmail.com> wrote:
> Has anyone tried hooking up routing within a Reel app? I wouldn't expect
> anything terribly complex, perhaps just enough to support basic API-style
> operations? http_router (https://github.com/joshbuddy/http_router) seems
> like it might be usable in a Reel context.
I'd love to hear any solution you may come to when you're able to dig into it.
For now, I was able to remove the trap/sleep from Webmachine::Adapters::Reel#run and add an adapter_option for supervise_as to get it running. (Since I already used supervision groups, I had my own sleep it can hit.) I hooked the adapter's embedded Reel::Server shutdown into my existing supervision group's finalize, and it seems to cleanly terminate. It may be that to do this in a supervisor-aware way, we should make a separate entry point into Webmachine, letting the adapter know if it should handle supervision or not?
We'll see if this ends up causing more problems than it solves. :)
On Tuesday, November 6, 2012 at 6:19 PM, Tony Arcieri wrote:
> I'm working on a project which will be using Webmachine soon. I expect I'll start running into the same problems ;)
> There aren't many people using Webmachine + Reel yet (if you are, want to speak up? ;) so unfortunately it's a bit rough around the edges.
> On Tue, Nov 6, 2012 at 4:07 PM, Doug Mayer <dougtma...@gmail.com (mailto:dougtma...@gmail.com)> wrote:
> > Webmachine does indeed look pretty slick. I'm having trouble getting its adapter-based system to hook into our existing supervision tree, though. Are you aware of any design that may lend itself well to being started with a top-level supervision group?
> > I tried creating a wrapper around a Webmachine::Application instance but things seemed to run amok with traps being ignored, etc. Perhaps I just have a little something wrong, which I can dig into further, but I don't want to lose more time on it if it's a clear loser to those more comfortable with such a setup.
> > Thanks,
> > Doug
> > On Tuesday, November 6, 2012 at 1:25 AM, Tony Arcieri wrote:
> > > The webmachine-ruby project has a Reel adapter, a router, and is also a pretty nifty HTTP framework in general:
> > > On Mon, Nov 5, 2012 at 9:02 PM, Doug Mayer <dougtma...@gmail.com (mailto:dougtma...@gmail.com)> wrote:
> > > > Has anyone tried hooking up routing within a Reel app? I wouldn't expect anything terribly complex, perhaps just enough to support basic API-style operations? http_router (https://github.com/joshbuddy/http_router) seems like it might be usable in a Reel context.