public class ShardedDocumentStore extends DocumentStoreBase
conventions, failoverServers, initialized, profilingContext, subscriptions, url, useFips
Constructor and Description |
---|
ShardedDocumentStore(ShardStrategy shardStrategy)
Initializes a new instance of the ShardedDocumentStore class.
|
Modifier and Type | Method and Description |
---|---|
void |
addAfterDisposeEventHandler(EventHandler<VoidArgs> event)
Called after dispose is completed
|
CleanCloseable |
aggressivelyCacheFor(long cacheDurationInMilis)
Setup the context for aggressive caching.
|
BulkInsertOperation |
bulkInsert()
Deprecated.
|
BulkInsertOperation |
bulkInsert(String database)
Cannot use BulkInsert using sharded store, use shardedBulkInsert, instead
|
BulkInsertOperation |
bulkInsert(String database,
BulkInsertOptions options)
Cannot use BulkInsert using sharded store, use shardedBulkInsert, instead
|
IDatabaseChanges |
changes()
Subscribe to change notifications from the server
|
IDatabaseChanges |
changes(String database)
Subscribe to change notifications from the server
|
void |
close() |
IDatabaseCommands |
databaseCommandsFor(String shardId) |
CleanCloseable |
disableAggressiveCaching()
Setup the context for no aggressive caching
This is mainly useful for internal use inside RavenDB, when we are executing
queries that has been marked with WaitForNonStaleResults, we temporarily disable
aggressive caching.
|
void |
executeIndex(AbstractIndexCreationTask indexCreationTask)
Executes the index creation against each of the shards.
|
void |
executeIndexes(List<AbstractIndexCreationTask> indexCreationTasks) |
void |
executeTransformer(AbstractTransformerCreationTask transformerCreationTask)
Executes the transformer creation
|
DocumentConvention |
getConventions()
Gets the conventions.
|
IDatabaseCommands |
getDatabaseCommands()
Gets the database commands.
|
String |
getIdentifier()
Gets the identifier
|
HttpJsonRequestFactory |
getJsonRequestFactory()
Get the
HttpJsonRequestFactory for this store |
Etag |
getLastWrittenEtag()
Gets the etag of the last document written by any session belonging to this
|
ShardStrategy |
getShardStrategy() |
Map<String,String> |
getSharedOperationsHeaders()
Gets the shared operations headers.
|
String |
getUrl()
Gets the URL.
|
boolean |
hasJsonRequestFactory()
Whatever this instance has json request factory available
|
IDocumentStore |
initialize()
Initializes this instance.
|
void |
initializeProfiling() |
IDocumentSession |
openSession()
Opens the session.
|
IDocumentSession |
openSession(OpenSessionOptions sessionOptions)
Opens the session with the specified options.
|
IDocumentSession |
openSession(String database)
Opens the session for a particular database
|
void |
removeAfterDisposeEventHandler(EventHandler<VoidArgs> event)
Remove event handler
|
void |
setConventions(DocumentConvention conventions) |
void |
setIdentifier(String identifier)
Sets the identifier
|
CleanCloseable |
setRequestsTimeoutFor(long timeout)
Setup the WebRequest timeout for the session
|
protected void |
setSharedOperationsHeaders(Map<String,String> sharedOperationsHeaders) |
ShardedBulkInsertOperation |
shardedBulkInsert() |
ShardedBulkInsertOperation |
shardedBulkInsert(String database) |
ShardedBulkInsertOperation |
shardedBulkInsert(String database,
ShardedDocumentStore store,
BulkInsertOptions options) |
void |
sideBySideExecuteIndex(AbstractIndexCreationTask indexCreationTask,
Etag minimumEtagBeforeReplace,
Date replaceTimeUtc)
Executes the index creation in side-by-side mode.
|
void |
sideBySideExecuteIndexes(List<AbstractIndexCreationTask> indexCreationTasks) |
void |
sideBySideExecuteIndexes(List<AbstractIndexCreationTask> indexCreationTasks,
Etag minimumEtagBeforeReplace,
Date replaceTimeUtc) |
addSessionCreatedInternal, afterSessionCreated, aggressivelyCache, assertInitialized, ensureNotClosed, getFailoverServers, getLastEtagHolder, getListeners, getProfilingInformationFor, getRegisteredConflictListeners, getRegisteredConversionListeners, getRegisteredDeleteListeners, getRegisteredQueryListeners, getRegisteredStoreListeners, getTransactionRecoveryStorage, getWasDisposed, initializeEncryptor, registerListener, registerListener, registerListener, registerListener, registerListener, removeSessionCreatedInternal, setFailoverServers, setLastEtagHolder, setListeners, setTransactionRecoveryStorage, setUrl, setWasDisposed, sideBySideExecuteIndex, subscriptions, withConventions
public ShardedDocumentStore(ShardStrategy shardStrategy)
protected void setSharedOperationsHeaders(Map<String,String> sharedOperationsHeaders)
setSharedOperationsHeaders
in class DocumentStoreBase
public Map<String,String> getSharedOperationsHeaders()
IDocumentStore
getSharedOperationsHeaders
in interface IDocumentStore
getSharedOperationsHeaders
in class DocumentStoreBase
public boolean hasJsonRequestFactory()
hasJsonRequestFactory
in interface IDocumentStore
hasJsonRequestFactory
in class DocumentStoreBase
public HttpJsonRequestFactory getJsonRequestFactory()
IDocumentStore
HttpJsonRequestFactory
for this storepublic DocumentConvention getConventions()
IDocumentStore
getConventions
in interface IDocumentStore
getConventions
in class DocumentStoreBase
public void setConventions(DocumentConvention conventions)
setConventions
in class DocumentStoreBase
public String getIdentifier()
IDocumentStore
public void setIdentifier(String identifier)
IDocumentStore
public void addAfterDisposeEventHandler(EventHandler<VoidArgs> event)
IDisposalNotification
public void removeAfterDisposeEventHandler(EventHandler<VoidArgs> event)
IDisposalNotification
public void close()
public IDatabaseChanges changes()
public IDatabaseChanges changes(String database)
database
- public CleanCloseable aggressivelyCacheFor(long cacheDurationInMilis)
public CleanCloseable disableAggressiveCaching()
public CleanCloseable setRequestsTimeoutFor(long timeout)
IDocumentStore
timeout
- Specify the timeout durationpublic IDocumentSession openSession()
public IDocumentSession openSession(String database)
public IDocumentSession openSession(OpenSessionOptions sessionOptions)
public IDatabaseCommands getDatabaseCommands()
public String getUrl()
IDocumentStore
getUrl
in interface IDocumentStore
getUrl
in class DocumentStoreBase
public ShardStrategy getShardStrategy()
public Etag getLastWrittenEtag()
getLastWrittenEtag
in interface IDocumentStore
getLastWrittenEtag
in class DocumentStoreBase
@Deprecated public BulkInsertOperation bulkInsert()
public BulkInsertOperation bulkInsert(String database)
public BulkInsertOperation bulkInsert(String database, BulkInsertOptions options)
public ShardedBulkInsertOperation shardedBulkInsert()
public ShardedBulkInsertOperation shardedBulkInsert(String database)
public ShardedBulkInsertOperation shardedBulkInsert(String database, ShardedDocumentStore store, BulkInsertOptions options)
public void initializeProfiling()
public IDocumentStore initialize()
public IDatabaseCommands databaseCommandsFor(String shardId)
public void executeTransformer(AbstractTransformerCreationTask transformerCreationTask)
executeTransformer
in interface IDocumentStore
executeTransformer
in class DocumentStoreBase
public void executeIndex(AbstractIndexCreationTask indexCreationTask)
executeIndex
in interface IDocumentStore
executeIndex
in class DocumentStoreBase
public void executeIndexes(List<AbstractIndexCreationTask> indexCreationTasks)
executeIndexes
in interface IDocumentStore
executeIndexes
in class DocumentStoreBase
public void sideBySideExecuteIndexes(List<AbstractIndexCreationTask> indexCreationTasks)
sideBySideExecuteIndexes
in interface IDocumentStore
sideBySideExecuteIndexes
in class DocumentStoreBase
public void sideBySideExecuteIndexes(List<AbstractIndexCreationTask> indexCreationTasks, Etag minimumEtagBeforeReplace, Date replaceTimeUtc)
sideBySideExecuteIndexes
in interface IDocumentStore
sideBySideExecuteIndexes
in class DocumentStoreBase
public void sideBySideExecuteIndex(AbstractIndexCreationTask indexCreationTask, Etag minimumEtagBeforeReplace, Date replaceTimeUtc)
IDocumentStore
sideBySideExecuteIndex
in interface IDocumentStore
sideBySideExecuteIndex
in class DocumentStoreBase
Copyright © 2016. All Rights Reserved.