This page captures some of the experimentation going on https://issues.apache.org/jira/browse/SOLR-4818 and various other issues around refactoring some of Solr's plumbing to use Guice and Restlet, as well as very other simplifications. The word "plumbing" is used to differentiate the core functionality of Solr (searching, faceting, indexing, etc.) from things like servlet setup, plugin loading, dependency injections, etc.
Guice makes dependency injection dead simple. A fair amount of Solr's current plumbing code was built before dependency injection was popular (we have discussed Spring in the past, but never ported to it) and thus invents ways of bootstrapping. Guice should simplify a lot of this.
Guice also makes it much easier to test mocks and alternative approaches with very little overhead in terms of rewiring. It should also make it a lot easier for us to add plugins, etc.
Restlet is a framework for easily adding REST APIs to an application. We already use it for the Schema APIs. Combining it with Guice makes for an easy way to quickly add new, easily testable, REST APIs without a lot of work.
Work is under way on https://svn.apache.org/repos/asf/lucene/dev/branches/solr_guice_restlet/.
Existing collection based RequestHandlers are mapped into (note, I picked /api/collections/COLLECTION_NAME, but it can changed)
Simpler, pluggable SolrQueryRequest creation should make it easier to use Solr in a non-servlet environment
- Get the tests to pass
Make SolrRequestParsers and many other things injectable
- Demonstrate with Netty
- Map the Admin APIs
- Verify the UI
https://issues.apache.org/jira/browse/SOLR-5103 with a Plugin mgmt API
- Demonstrate securing access to the APIs
- MORE HERE