public class VersionInfo extends Object
Modifier and Type | Field and Description |
---|---|
static org.slf4j.Logger |
log |
static String |
VERSION_FIELD |
Constructor and Description |
---|
VersionInfo(UpdateLog ulog,
int nBuckets) |
Modifier and Type | Method and Description |
---|---|
void |
blockUpdates() |
VersionBucket |
bucket(int hash) |
static SchemaField |
getAndCheckVersionField(IndexSchema schema)
Gets and returns the
VERSION_FIELD from the specified
schema, after verifying that it is indexed, stored, and single-valued. |
Long |
getMaxVersionFromIndex(SolrIndexSearcher searcher) |
long |
getNewClock() |
long |
getOldClock() |
SchemaField |
getVersionField() |
Long |
getVersionFromIndex(BytesRef idBytes) |
void |
lockForUpdate() |
Long |
lookupVersion(BytesRef idBytes) |
void |
reload() |
void |
seedBucketsWithHighestVersion(long highestVersion) |
void |
unblockUpdates() |
void |
unlockForUpdate() |
void |
updateClock(long clock) |
public static org.slf4j.Logger log
public static final String VERSION_FIELD
public VersionInfo(UpdateLog ulog, int nBuckets)
public static SchemaField getAndCheckVersionField(IndexSchema schema) throws SolrException
VERSION_FIELD
from the specified
schema, after verifying that it is indexed, stored, and single-valued.
If any of these pre-conditions are not met, it throws a SolrException
with a user suitable message indicating the problem.SolrException
public void reload()
public SchemaField getVersionField()
public void lockForUpdate()
public void unlockForUpdate()
public void blockUpdates()
public void unblockUpdates()
public long getNewClock()
public long getOldClock()
public void updateClock(long clock)
public VersionBucket bucket(int hash)
public Long getMaxVersionFromIndex(SolrIndexSearcher searcher) throws IOException
IOException
public void seedBucketsWithHighestVersion(long highestVersion)
Copyright © 2000-2015 Apache Software Foundation. All Rights Reserved.