Hi Jeff,

now, you don't need to add these to Backend.java. These are just shortcuts
for commonly used IndexProviders. You can always provide the full class
name in the configuration without making any changes to Titan core.
So, the code you are referencing is just syntactic sugar.


On Mon, Jan 20, 2014 at 6:05 PM, Jeff Schmidt <notifications@github.com>wrote:

> In
> titan-core/src/main/java/com/thinkaurelius/titan/diskstorage/Backend.java:
>
> > @@ -477,6 +477,7 @@ public void clearStorage() throws StorageException {
> >          put("lucene", "com.thinkaurelius.titan.diskstorage.lucene.LuceneIndex");
> >          put("elasticsearch", "com.thinkaurelius.titan.diskstorage.es.ElasticSearchIndex");
> >          put("es", "com.thinkaurelius.titan.diskstorage.es.ElasticSearchIndex");
> > +        put("solr", "com.thinkaurelius.titan.diskstorage.solr.SolrIndex");
>
> This makes it difficult for search backends to be independent from Titan
> itself. That is, suppose I subclass the new SolrIndex class as say,
> DseSolrIndex to make some accommodations for DataStax Enterprise. Then I'd
> have to add another map entry in the Titan project itself so this
> IndexProvider implementation would be recognized.
>
> I admit, I'm just now looking at Backend.java in more detail, so maybe I'm
> missing something. Would it make sense to define annotations such as
> \@IndexProvider and \@StorageManager and then Titan can scan for those and
> register the components actually present on the classpath? Or I suppose
> implementations of the IndexProvider could be located, and then invoke a
> new registerProvider() method which returns the 'shortcut(s)' by which the
> provider can be referenced?
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/thinkaurelius/titan/pull/372/files#r9025422>
> .
>



-- 
Matthias Broecheler
http://www.matthiasb.com