Hello! I've been working on a project which delivers an asynchronous implementation of a REST API in Java using Tomcat 7, Jersey 2 and Akka. Being neither an expert in Jersey nor Akka, I spent a tremendous amount of time figuring out how to integrate the two (specifically how to instantiate an ActorSystem at server startup and inject it into each service request). I've created a sample project that demonstrates my approach:
(The "magic" is in the constructor of the ExampleApplication class)
That all being said, I'm in the process of writing a blog entry chronicling my experiences in which I'll highlight the above github project. Before I publish it, I'd be interested in any feedback on the sample from folks more experienced in Akka than myself. Is this a reasonable way to integrate the two? Anything you would do differently? (knowing that it has to be Tomcat and Jersey... :-)
Thanks in advance!
- Paul