- java.lang.Object
-
- org.apache.lucene.monitor.QueryIndex
-
- org.apache.lucene.monitor.ReadonlyQueryIndex
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
class ReadonlyQueryIndex extends QueryIndex
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static class
ReadonlyQueryIndex.LazyMonitorQueryCollector
A Collector that decodes the stored query for each document hit reparsing them everytime.-
Nested classes/interfaces inherited from class org.apache.lucene.monitor.QueryIndex
QueryIndex.CachePopulator, QueryIndex.DataValues, QueryIndex.FIELDS, QueryIndex.QueryBuilder, QueryIndex.QueryCollector, QueryIndex.QueryTermFilter
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.concurrent.ScheduledExecutorService
refreshExecutor
-
Fields inherited from class org.apache.lucene.monitor.QueryIndex
decomposer, listeners, manager, serializer, termFilters
-
-
Constructor Summary
Constructors Constructor Description ReadonlyQueryIndex(MonitorConfiguration configuration)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
cacheSize()
void
clear()
void
close()
void
commit(java.util.List<MonitorQuery> updates)
void
deleteQueries(java.util.List<java.lang.String> ids)
long
getLastPurged()
int
numDocs()
void
purgeCache()
(package private) void
purgeCache(QueryIndex.CachePopulator populator)
long
search(QueryIndex.QueryBuilder queryBuilder, QueryIndex.QueryCollector matcher)
-
Methods inherited from class org.apache.lucene.monitor.QueryIndex
addListener, getQuery, scan, search
-
-
-
-
Constructor Detail
-
ReadonlyQueryIndex
public ReadonlyQueryIndex(MonitorConfiguration configuration) throws java.io.IOException
- Throws:
java.io.IOException
-
-
Method Detail
-
commit
public void commit(java.util.List<MonitorQuery> updates) throws java.io.IOException
- Specified by:
commit
in classQueryIndex
- Throws:
java.io.IOException
-
search
public long search(QueryIndex.QueryBuilder queryBuilder, QueryIndex.QueryCollector matcher) throws java.io.IOException
- Specified by:
search
in classQueryIndex
- Throws:
java.io.IOException
-
purgeCache
public void purgeCache() throws java.io.IOException
- Specified by:
purgeCache
in classQueryIndex
- Throws:
java.io.IOException
-
purgeCache
void purgeCache(QueryIndex.CachePopulator populator)
- Specified by:
purgeCache
in classQueryIndex
-
close
public void close() throws java.io.IOException
- Throws:
java.io.IOException
-
numDocs
public int numDocs() throws java.io.IOException
- Specified by:
numDocs
in classQueryIndex
- Throws:
java.io.IOException
-
cacheSize
public int cacheSize()
- Specified by:
cacheSize
in classQueryIndex
-
deleteQueries
public void deleteQueries(java.util.List<java.lang.String> ids) throws java.io.IOException
- Specified by:
deleteQueries
in classQueryIndex
- Throws:
java.io.IOException
-
clear
public void clear() throws java.io.IOException
- Specified by:
clear
in classQueryIndex
- Throws:
java.io.IOException
-
getLastPurged
public long getLastPurged()
- Specified by:
getLastPurged
in classQueryIndex
-
-