com.bigdata.service
Class MetadataService.RegisterScaleOutIndexTask
java.lang.Object
com.bigdata.journal.AbstractTask
com.bigdata.service.MetadataService.RegisterScaleOutIndexTask
- All Implemented Interfaces:
- ITask, Callable
- Enclosing class:
- MetadataService
protected static class MetadataService.RegisterScaleOutIndexTask
- extends AbstractTask
Registers a metadata index for a named scale-out index and statically
partition the index using the given separator keys and data services.
- Version:
- $Id: MetadataService.java 4523 2011-05-18 18:14:45Z thompsonbry $
- Author:
- Bryan Thompson
- TODO:
- this does not attempt to handle errors on data services when
attempting to register the index partitions. it should failover
rather than just dying., an error during execution can result in the task aborting but any
registered index partitions will already exist on the various data
servers. that will make it impossible to re-register the scale-out
index until those index partitions have been cleaned up, which is a
more than insignificant pain (they could be cleaned up by a
bottom-up index rebuild followed by dropping the rebuilt index).
| Fields inherited from class com.bigdata.journal.AbstractTask |
checkpointNanoTime, concurrencyManager, DEBUG, INFO, isReadWriteTx, log, nanoTime_assignedWorker, nanoTime_beginWork, nanoTime_finishedWork, nanoTime_submitTask, readOnly, resourceManager, taskCounters, timestamp, transactionManager, tx |
|
Method Summary |
protected Object |
doTask()
Create and statically partition the scale-out index. |
| Methods inherited from class com.bigdata.journal.AbstractTask |
assertResource, assertRunning, assertUnisolated, call, clearLoggingContext, dropIndex, getCommitTime, getIndex, getJournal, getOnlyResource, getResource, getResourceManager, getTaskCounters, getTaskName, getTimestamp, isResource, registerIndex, setupLoggingContext, toString |
MetadataService.RegisterScaleOutIndexTask
public MetadataService.RegisterScaleOutIndexTask(IBigdataFederation fed,
ConcurrencyManager concurrencyManager,
IResourceManager resourceManager,
String metadataIndexName,
IndexMetadata metadata,
byte[][] separatorKeys,
UUID[] dataServiceUUIDs)
- Create and statically partition a scale-out index.
- Parameters:
metadataIndexName - The name of the metadata index (the resource on which the
task must have a lock).separatorKeys - The array of separator keys. Each separator key is
interpreted as an unsigned byte[]. The first
entry MUST be an empty byte[]. The entries MUST be in
sorted order.dataServiceUUIDs - The array of data services onto which each partition
defined by a separator key will be mapped (optional). The
#of entries in this array MUST agree with the #of entries
in the separatorKeys array. When null,
the index paritions will be auto-assigned to data
services.
doTask
protected Object doTask()
throws Exception
- Create and statically partition the scale-out index.
- Specified by:
doTask in class AbstractTask
- Returns:
- The UUID assigned to the managed index.
- Throws:
Exception - The exception that will be thrown by AbstractTask.call() iff the
operation fails.
InterruptedException - This exception SHOULD be thrown if
Thread.interrupted() becomes true during
execution.
Copyright © 2006-2011 SYSTAP, LLC. All Rights Reserved.