01: package org.compass.needle.coherence;
02:
03: import org.apache.lucene.store.Directory;
04: import org.compass.core.engine.SearchEngineException;
05:
06: /**
07: * @author kimchy
08: */
09: public class InvocableCoherenceDirectoryStore extends
10: AbstractCoherenceDirectoryStore {
11:
12: public static final String PROTOCOL = "coherence";
13:
14: protected String findConnection(String connection) {
15: return connection.substring(PROTOCOL.length());
16: }
17:
18: public Directory open(String subContext, String subIndex)
19: throws SearchEngineException {
20: return new InvocableCoherenceDirectory(getCache(),
21: getIndexName() + "X" + subContext + "X" + subIndex,
22: getBucketSize());
23: }
24: }
|