index int64 0 10.7k | class stringclasses 867 values | comment_sentence stringlengths 1 1.78k | partition int64 0 0 | combo stringlengths 17 1.81k | labels listlengths 7 7 |
|---|---|---|---|---|---|
8,466 | TaskLogAppender.java | //so that log4j can configure it from the configuration(log4j.properties). | 0 | //so that log4j can configure it from the configuration(log4j.properties). | TaskLogAppender.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,467 | TaskLogAppender.java | // System properties passed in from JVM runner | 0 | // System properties passed in from JVM runner | TaskLogAppender.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,468 | TaskLogAppender.java | static final String ISCLEANUP_PROPERTY = "hadoop.tasklog.iscleanup";
static final String LOGSIZE_PROPERTY = "hadoop.tasklog.totalLogFileSize";
static final String TASKID_PROPERTY = "hadoop.tasklog.taskid"; | 0 | static final String ISCLEANUP_PROPERTY = "hadoop.tasklog.iscleanup";
static final String LOGSIZE_PROPERTY = "hadoop.tasklog.totalLogFileSize";
static final String TASKID_PROPERTY = "hadoop.tasklog.taskid"; | TaskLogAppender.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,469 | TaskLogAppender.java | /**
* A simple log4j-appender for the task child's
* map-reduce system logs.
*
*/ | 0 | /**
* A simple log4j-appender for the task child's
* map-reduce system logs.
*
*/ | TaskLogAppender.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,470 | TaskLogAppender.java | /**
* The Task Runner passes in the options as system properties. Set
* the options if the setters haven't already been called.
*/ | 0 | /**
* The Task Runner passes in the options as system properties. Set
* the options if the setters haven't already been called.
*/ | TaskLogAppender.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,471 | TaskLogAppender.java | /**
* Getter/Setter methods for log4j.
*/ | 0 | /**
* Getter/Setter methods for log4j.
*/ | TaskLogAppender.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,472 | TaskLogAppender.java | /**
* Set whether the task is a cleanup attempt or not.
*
* @param isCleanup
* true if the task is cleanup attempt, false otherwise.
*/ | 0 | /**
* Set whether the task is a cleanup attempt or not.
*
* @param isCleanup
* true if the task is cleanup attempt, false otherwise.
*/ | TaskLogAppender.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,473 | TaskLogAppender.java | /**
* Get whether task is cleanup attempt or not.
*
* @return true if the task is cleanup attempt, false otherwise.
*/ | 0 | /**
* Get whether task is cleanup attempt or not.
*
* @return true if the task is cleanup attempt, false otherwise.
*/ | TaskLogAppender.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,474 | BlockPoolSliceStorage.java | /**
* Create a rolling upgrade marker file for each BP storage root, if it
* does not exist already.
*/ | 0 | /**
* Create a rolling upgrade marker file for each BP storage root, if it
* does not exist already.
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,475 | BlockPoolSliceStorage.java | /**
* Check whether the rolling upgrade marker file exists for each BP storage
* root. If it does exist, then the marker file is cleared and more
* importantly the layout upgrade is finalized.
*/ | 0 | /**
* Check whether the rolling upgrade marker file exists for each BP storage
* root. If it does exist, then the marker file is cleared and more
* importantly the layout upgrade is finalized.
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,476 | BlockPoolSliceStorage.java | /** trash is enabled if at least one storage directory contains trash root */ | 0 | /** trash is enabled if at least one storage directory contains trash root */ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,477 | BlockPoolSliceStorage.java | * Delete all files and directories in the trash directories. | 0 | * Delete all files and directories in the trash directories. | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,478 | BlockPoolSliceStorage.java | * @return the target directory to restore a previously deleted block file. | 0 | * @return the target directory to restore a previously deleted block file. | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,479 | BlockPoolSliceStorage.java | * @return the trash directory for a given block file that is being deleted. | 0 | * @return the trash directory for a given block file that is being deleted. | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,480 | BlockPoolSliceStorage.java | * @return root directory for block pool storage | 0 | * @return root directory for block pool storage | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,481 | BlockPoolSliceStorage.java | * @param dnCurDir data node storage root directory | 0 | * @param dnCurDir data node storage root directory | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,482 | BlockPoolSliceStorage.java | * @param bpID block pool ID | 0 | * @param bpID block pool ID | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,483 | BlockPoolSliceStorage.java | * @param fromDir directory where the snapshot is stored | 0 | * @param fromDir directory where the snapshot is stored | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,484 | BlockPoolSliceStorage.java | * @param toDir the current data directory | 0 | * @param toDir the current data directory | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,485 | BlockPoolSliceStorage.java | * @param bpSd Block pool storage directory at <SD>/current/<bpid> | 0 | * @param bpSd Block pool storage directory at <SD>/current/<bpid> | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,486 | BlockPoolSliceStorage.java | * @param detachDir detach directory | 0 | * @param detachDir detach directory | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,487 | BlockPoolSliceStorage.java | * @param bpSd storage directory <SD>/current/<bpid> | 0 | * @param bpSd storage directory <SD>/current/<bpid> | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,488 | BlockPoolSliceStorage.java | * @param nsInfo Namespace Info from the namenode | 0 | * @param nsInfo Namespace Info from the namenode | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,489 | BlockPoolSliceStorage.java | * @param sd storage directory <SD>/current/<bpid> | 0 | * @param sd storage directory <SD>/current/<bpid> | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,490 | BlockPoolSliceStorage.java | * @param nsInfo namespace info | 0 | * @param nsInfo namespace info | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,491 | BlockPoolSliceStorage.java | * @param startOpt startup option | 0 | * @param startOpt startup option | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,492 | BlockPoolSliceStorage.java | * @return true if the new properties has been written. | 0 | * @return true if the new properties has been written. | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,493 | BlockPoolSliceStorage.java | @param absPathToRemove the absolute path of the root for the block pool
* level storage to remove. | 0 | @param absPathToRemove the absolute path of the root for the block pool
* level storage to remove. | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,494 | BlockPoolSliceStorage.java | * @param bpSdir the block pool storage | 0 | * @param bpSdir the block pool storage | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,495 | BlockPoolSliceStorage.java | * @param nsInfo the name space info | 0 | * @param nsInfo the name space info | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,496 | BlockPoolSliceStorage.java | * @param dnCurDir DataStorage current directory | 0 | * @param dnCurDir DataStorage current directory | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,497 | BlockPoolSliceStorage.java | * @param nsInfo the name space info | 0 | * @param nsInfo the name space info | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,498 | BlockPoolSliceStorage.java | * @param nsInfo namespace information | 0 | * @param nsInfo namespace information | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,499 | BlockPoolSliceStorage.java | * @param dataDirs storage directories of block pool | 0 | * @param dataDirs storage directories of block pool | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,500 | BlockPoolSliceStorage.java | * @param startOpt startup option | 0 | * @param startOpt startup option | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,501 | BlockPoolSliceStorage.java | * @param nsInfo namespace information | 0 | * @param nsInfo namespace information | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,502 | BlockPoolSliceStorage.java | * @param dataDirs storage directories of block pool | 0 | * @param dataDirs storage directories of block pool | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,503 | BlockPoolSliceStorage.java | * @param startOpt startup option | 0 | * @param startOpt startup option | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,504 | BlockPoolSliceStorage.java | * @return an array of loaded block pool directories. | 0 | * @return an array of loaded block pool directories. | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,505 | BlockPoolSliceStorage.java | * @param nsInfo namespace information | 0 | * @param nsInfo namespace information | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,506 | BlockPoolSliceStorage.java | * @param dataDir the root path of the storage directory | 0 | * @param dataDir the root path of the storage directory | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,507 | BlockPoolSliceStorage.java | * @param startOpt startup option | 0 | * @param startOpt startup option | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,508 | BlockPoolSliceStorage.java | * @return the StorageDirectory successfully loaded. | 0 | * @return the StorageDirectory successfully loaded. | BlockPoolSliceStorage.java | [
0,
0,
0,
1,
0,
0,
0
] |
8,509 | BlockPoolSliceStorage.java | @see Storage | 0 | @see Storage | BlockPoolSliceStorage.java | [
0,
0,
0,
0,
1,
0,
0
] |
8,510 | BlockPoolSliceStorage.java | /**
* A marker file that is created on each root directory if a rolling upgrade
* is in progress. The NN does not inform the DN when a rolling upgrade is
* finalized. All the DN can infer is whether or not a rolling upgrade is
* currently in progress. When the rolling upgrade is not in progress:
* 1. If the marker file is present, then a rolling upgrade just completed.
* If a 'previous' directory exists, it can be deleted now.
* 2. If the marker file is absent, then a regular upgrade may be in
* progress. Do not delete the 'previous' directory.
*/ | 0 | /**
* A marker file that is created on each root directory if a rolling upgrade
* is in progress. The NN does not inform the DN when a rolling upgrade is
* finalized. All the DN can infer is whether or not a rolling upgrade is
* currently in progress. When the rolling upgrade is not in progress:
* 1. If the marker file is present, then a rolling upgrade just completed.
* If a 'previous' directory exists, it can be deleted now.
* 2. If the marker file is absent, then a regular upgrade may be in
* progress. Do not delete the 'previous' directory.
*/ | BlockPoolSliceStorage.java | [
0,
0,
0,
0,
0,
0,
1
] |
8,511 | BlockPoolSliceStorage.java | // Expose visibility for VolumeBuilder#commit(). | 0 | // Expose visibility for VolumeBuilder#commit(). | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,512 | BlockPoolSliceStorage.java | /**
* Get a target subdirectory under current/ for a given block file that is being
* restored from trash.
*
* The subdirectory structure under trash/ mirrors that under current/ to keep
* implicit memory of where the files are to be restored.
*
* @return the target directory to restore a previously deleted block file.
*/ | 0 | /**
* Get a target subdirectory under current/ for a given block file that is being
* restored from trash.
*
* The subdirectory structure under trash/ mirrors that under current/ to keep
* implicit memory of where the files are to be restored.
*
* @return the target directory to restore a previously deleted block file.
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,513 | BlockPoolSliceStorage.java | /**
* Get a target subdirectory under trash/ for a given block file that is being
* deleted.
*
* The subdirectory structure under trash/ mirrors that under current/ to keep
* implicit memory of where the files are to be restored (if necessary).
*
* @return the trash directory for a given block file that is being deleted.
*/ | 0 | /**
* Get a target subdirectory under trash/ for a given block file that is being
* deleted.
*
* The subdirectory structure under trash/ mirrors that under current/ to keep
* implicit memory of where the files are to be restored (if necessary).
*
* @return the trash directory for a given block file that is being deleted.
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,514 | BlockPoolSliceStorage.java | /**
* Determine whether we can use trash for the given blockFile. Trash
* is disallowed if a 'previous' directory exists for the
* storage directory containing the block.
*/ | 0 | /**
* Determine whether we can use trash for the given blockFile. Trash
* is disallowed if a 'previous' directory exists for the
* storage directory containing the block.
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,515 | BlockPoolSliceStorage.java | /**
* Get a block pool storage root based on data node storage root
* @param bpID block pool ID
* @param dnCurDir data node storage root directory
* @return root directory for block pool storage
*/ | 0 | /**
* Get a block pool storage root based on data node storage root
* @param bpID block pool ID
* @param dnCurDir data node storage root directory
* @return root directory for block pool storage
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,516 | BlockPoolSliceStorage.java | // return the data node root directory | 0 | // return the data node root directory | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,517 | BlockPoolSliceStorage.java | /**
* gets the data node storage directory based on block pool storage
*/ | 0 | /**
* gets the data node storage directory based on block pool storage
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,518 | BlockPoolSliceStorage.java | // do the link
// hardlink finalized blocks in tmpDir | 0 | // do the link
// hardlink finalized blocks in tmpDir | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,519 | BlockPoolSliceStorage.java | /**
* Hardlink all finalized and RBW blocks in fromDir to toDir
*
* @param fromDir directory where the snapshot is stored
* @param toDir the current data directory
* @throws IOException if error occurs during hardlink
*/ | 0 | /**
* Hardlink all finalized and RBW blocks in fromDir to toDir
*
* @param fromDir directory where the snapshot is stored
* @param toDir the current data directory
* @throws IOException if error occurs during hardlink
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,520 | BlockPoolSliceStorage.java | // delete finalized.tmp dir in a separate thread | 0 | // delete finalized.tmp dir in a separate thread | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,521 | BlockPoolSliceStorage.java | // rename previous to finalized.tmp | 0 | // rename previous to finalized.tmp | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,522 | BlockPoolSliceStorage.java | // already finalized | 0 | // already finalized | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,523 | BlockPoolSliceStorage.java | // block pool level previous directory | 0 | // block pool level previous directory | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,524 | BlockPoolSliceStorage.java | /*
* Finalize the block pool storage by deleting <BP>/previous directory
* that holds the snapshot.
*/ | 0 | /*
* Finalize the block pool storage by deleting <BP>/previous directory
* that holds the snapshot.
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,525 | BlockPoolSliceStorage.java | // 3. delete removed.tmp dir | 0 | // 3. delete removed.tmp dir | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,526 | BlockPoolSliceStorage.java | // 2. rename previous to current | 0 | // 2. rename previous to current | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,527 | BlockPoolSliceStorage.java | // 1. rename current to tmp | 0 | // 1. rename current to tmp | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,528 | BlockPoolSliceStorage.java | // We allow rollback to a state, which is either consistent with
// the namespace state or can be further upgraded to it.
// In another word, we can only roll back when ( storedLV >= software LV)
// && ( DN.previousCTime <= NN.ctime) | 0 | // We allow rollback to a state, which is either consistent with
// the namespace state or can be further upgraded to it.
// In another word, we can only roll back when ( storedLV >= software LV)
// && ( DN.previousCTime <= NN.ctime) | BlockPoolSliceStorage.java | [
0,
0,
1,
0,
0,
0,
0
] |
8,529 | BlockPoolSliceStorage.java | // 4.rename <SD>/current/<bpid>/previous.tmp to
// <SD>/current/<bpid>/previous | 0 | // 4.rename <SD>/current/<bpid>/previous.tmp to
// <SD>/current/<bpid>/previous | BlockPoolSliceStorage.java | [
0,
0,
1,
0,
0,
0,
0
] |
8,530 | BlockPoolSliceStorage.java | // 2. Rename <SD>/current/<bpid>/current to
// <SD>/current/<bpid>/previous.tmp | 0 | // 2. Rename <SD>/current/<bpid>/current to
// <SD>/current/<bpid>/previous.tmp | BlockPoolSliceStorage.java | [
0,
0,
1,
0,
0,
0,
0
] |
8,531 | BlockPoolSliceStorage.java | // If <SD>/previous directory exists delete it | 0 | // If <SD>/previous directory exists delete it | BlockPoolSliceStorage.java | [
0,
0,
0,
0,
0,
0,
1
] |
8,532 | BlockPoolSliceStorage.java | <ol>
* <li>If <SD>/current/<bpid>/previous exists then delete it</li>
* <li>Rename <SD>/current/<bpid>/current to
* <SD>/current/bpid/current/previous.tmp</li>
* <li>Create new <SD>current/<bpid>/current directory</li>
* <ol>
* <li>Hard links for block files are created from previous.tmp to current</li>
* <li>Save new version file in current directory</li>
* </ol>
* <li>Rename previous.tmp to previous</li> </ol> | 0 | <ol>
* <li>If <SD>/current/<bpid>/previous exists then delete it</li>
* <li>Rename <SD>/current/<bpid>/current to
* <SD>/current/bpid/current/previous.tmp</li>
* <li>Create new <SD>current/<bpid>/current directory</li>
* <ol>
* <li>Hard links for block files are created from previous.tmp to current</li>
* <li>Save new version file in current directory</li>
* </ol>
* <li>Rename previous.tmp to previous</li> </ol> | BlockPoolSliceStorage.java | [
0,
0,
0,
0,
0,
0,
1
] |
8,533 | BlockPoolSliceStorage.java | Rollback if previousLV >= LAYOUT_VERSION && prevCTime <= namenode.cTime.
* Upgrade if this.LV > LAYOUT_VERSION || this.cTime < namenode.cTime Regular
* startup if this.LV = LAYOUT_VERSION && this.cTime = namenode.cTime | 0 | Rollback if previousLV >= LAYOUT_VERSION && prevCTime <= namenode.cTime.
* Upgrade if this.LV > LAYOUT_VERSION || this.cTime < namenode.cTime Regular
* startup if this.LV = LAYOUT_VERSION && this.cTime = namenode.cTime | BlockPoolSliceStorage.java | [
0,
0,
0,
0,
0,
0,
1
] |
8,534 | BlockPoolSliceStorage.java | /**
* Manages storage for the set of BlockPoolSlices which share a particular
* block pool id, on this DataNode.
*
* This class supports the following functionality:
* <ol>
* <li> Formatting a new block pool storage</li>
* <li> Recovering a storage state to a consistent state (if possible></li>
* <li> Taking a snapshot of the block pool during upgrade</li>
* <li> Rolling back a block pool to a previous snapshot</li>
* <li> Finalizing block storage by deletion of a snapshot</li>
* </ul>
*
* @see Storage
*/ | 0 | /**
* Manages storage for the set of BlockPoolSlices which share a particular
* block pool id, on this DataNode.
*
* This class supports the following functionality:
* <ol>
* <li> Formatting a new block pool storage</li>
* <li> Recovering a storage state to a consistent state (if possible></li>
* <li> Taking a snapshot of the block pool during upgrade</li>
* <li> Rolling back a block pool to a previous snapshot</li>
* <li> Finalizing block storage by deletion of a snapshot</li>
* </ul>
*
* @see Storage
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,535 | BlockPoolSliceStorage.java | // id of the blockpool | 0 | // id of the blockpool | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,536 | BlockPoolSliceStorage.java | /**
* These maps are used as an optimization to avoid one filesystem operation
* per storage on each heartbeat response.
*/ | 0 | /**
* These maps are used as an optimization to avoid one filesystem operation
* per storage on each heartbeat response.
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,537 | BlockPoolSliceStorage.java | /**
* Load one storage directory. Recover from previous transitions if required.
*
* @param nsInfo namespace information
* @param dataDir the root path of the storage directory
* @param startOpt startup option
* @return the StorageDirectory successfully loaded.
* @throws IOException
*/ | 0 | /**
* Load one storage directory. Recover from previous transitions if required.
*
* @param nsInfo namespace information
* @param dataDir the root path of the storage directory
* @param startOpt startup option
* @return the StorageDirectory successfully loaded.
* @throws IOException
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,538 | BlockPoolSliceStorage.java | // format | 0 | // format | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,539 | BlockPoolSliceStorage.java | // recovery part is common | 0 | // recovery part is common | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,540 | BlockPoolSliceStorage.java | // 2. Do transitions
// Each storage directory is treated individually.
// During startup some of them can upgrade or roll back
// while others could be up-to-date for the regular startup. | 0 | // 2. Do transitions
// Each storage directory is treated individually.
// During startup some of them can upgrade or roll back
// while others could be up-to-date for the regular startup. | BlockPoolSliceStorage.java | [
0,
0,
1,
0,
0,
0,
0
] |
8,541 | BlockPoolSliceStorage.java | /**
* Analyze and load storage directories. Recover from previous transitions if
* required.
*
* The block pool storages are either all analyzed or none of them is loaded.
* Therefore, a failure on loading any block pool storage results a faulty
* data volume.
*
* @param nsInfo namespace information
* @param dataDirs storage directories of block pool
* @param startOpt startup option
* @return an array of loaded block pool directories.
* @throws IOException on error
*/ | 0 | /**
* Analyze and load storage directories. Recover from previous transitions if
* required.
*
* The block pool storages are either all analyzed or none of them is loaded.
* Therefore, a failure on loading any block pool storage results a faulty
* data volume.
*
* @param nsInfo namespace information
* @param dataDirs storage directories of block pool
* @param startOpt startup option
* @return an array of loaded block pool directories.
* @throws IOException on error
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,542 | BlockPoolSliceStorage.java | // sd is locked but not opened | 0 | // sd is locked but not opened | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,543 | BlockPoolSliceStorage.java | /**
* Analyze storage directories. Recover from previous transitions if required.
*
* The block pool storages are either all analyzed or none of them is loaded.
* Therefore, a failure on loading any block pool storage results a faulty
* data volume.
*
* @param nsInfo namespace information
* @param dataDirs storage directories of block pool
* @param startOpt startup option
* @throws IOException on error
*/ | 0 | /**
* Analyze storage directories. Recover from previous transitions if required.
*
* The block pool storages are either all analyzed or none of them is loaded.
* Therefore, a failure on loading any block pool storage results a faulty
* data volume.
*
* @param nsInfo namespace information
* @param dataDirs storage directories of block pool
* @param startOpt startup option
* @throws IOException on error
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,544 | BlockPoolSliceStorage.java | /**
* Format a block pool slice storage.
* @param dnCurDir DataStorage current directory
* @param nsInfo the name space info
* @throws IOException Signals that an I/O exception has occurred.
*/ | 0 | /**
* Format a block pool slice storage.
* @param dnCurDir DataStorage current directory
* @param nsInfo the name space info
* @throws IOException Signals that an I/O exception has occurred.
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,545 | BlockPoolSliceStorage.java | /**
* Format a block pool slice storage.
* @param bpSdir the block pool storage
* @param nsInfo the name space info
* @throws IOException Signals that an I/O exception has occurred.
*/ | 0 | /**
* Format a block pool slice storage.
* @param bpSdir the block pool storage
* @param nsInfo the name space info
* @throws IOException Signals that an I/O exception has occurred.
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,546 | BlockPoolSliceStorage.java | // create directory | 0 | // create directory | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,547 | BlockPoolSliceStorage.java | /**
* Remove block pool level storage directory.
* @param absPathToRemove the absolute path of the root for the block pool
* level storage to remove.
*/ | 0 | /**
* Remove block pool level storage directory.
* @param absPathToRemove the absolute path of the root for the block pool
* level storage to remove.
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,548 | BlockPoolSliceStorage.java | /**
* Set layoutVersion, namespaceID and blockpoolID into block pool storage
* VERSION file
*/ | 0 | /**
* Set layoutVersion, namespaceID and blockpoolID into block pool storage
* VERSION file
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,549 | BlockPoolSliceStorage.java | /** Validate and set block pool ID */ | 0 | /** Validate and set block pool ID */ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,550 | BlockPoolSliceStorage.java | /**
* Analyze whether a transition of the BP state is required and
* perform it if necessary.
* <br>
* Rollback if previousLV >= LAYOUT_VERSION && prevCTime <= namenode.cTime.
* Upgrade if this.LV > LAYOUT_VERSION || this.cTime < namenode.cTime Regular
* startup if this.LV = LAYOUT_VERSION && this.cTime = namenode.cTime
*
* @param sd storage directory <SD>/current/<bpid>
* @param nsInfo namespace info
* @param startOpt startup option
* @return true if the new properties has been written.
*/ | 0 | /**
* Analyze whether a transition of the BP state is required and
* perform it if necessary.
* <br>
* Rollback if previousLV >= LAYOUT_VERSION && prevCTime <= namenode.cTime.
* Upgrade if this.LV > LAYOUT_VERSION || this.cTime < namenode.cTime Regular
* startup if this.LV = LAYOUT_VERSION && this.cTime = namenode.cTime
*
* @param sd storage directory <SD>/current/<bpid>
* @param nsInfo namespace info
* @param startOpt startup option
* @return true if the new properties has been written.
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,551 | BlockPoolSliceStorage.java | // rollback if applicable | 0 | // rollback if applicable | BlockPoolSliceStorage.java | [
0,
0,
0,
0,
0,
0,
1
] |
8,552 | BlockPoolSliceStorage.java | // Restore all the files in the trash. The restored files are retained
// during rolling upgrade rollback. They are deleted during rolling
// upgrade downgrade. | 0 | // Restore all the files in the trash. The restored files are retained
// during rolling upgrade rollback. They are deleted during rolling
// upgrade downgrade. | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,553 | BlockPoolSliceStorage.java | // regular startup | 0 | // regular startup | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,554 | BlockPoolSliceStorage.java | // upgrade | 0 | // upgrade | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,555 | BlockPoolSliceStorage.java | // layoutVersion == LAYOUT_VERSION && this.cTime > nsInfo.cTime
// must shutdown | 0 | // layoutVersion == LAYOUT_VERSION && this.cTime > nsInfo.cTime
// must shutdown | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,556 | BlockPoolSliceStorage.java | /**
* Upgrade to any release after 0.22 (0.22 included) release e.g. 0.22 => 0.23
* Upgrade procedure is as follows:
* <ol>
* <li>If <SD>/current/<bpid>/previous exists then delete it</li>
* <li>Rename <SD>/current/<bpid>/current to
* <SD>/current/bpid/current/previous.tmp</li>
* <li>Create new <SD>current/<bpid>/current directory</li>
* <ol>
* <li>Hard links for block files are created from previous.tmp to current</li>
* <li>Save new version file in current directory</li>
* </ol>
* <li>Rename previous.tmp to previous</li> </ol>
*
* @param bpSd storage directory <SD>/current/<bpid>
* @param nsInfo Namespace Info from the namenode
* @throws IOException on error
*/ | 0 | /**
* Upgrade to any release after 0.22 (0.22 included) release e.g. 0.22 => 0.23
* Upgrade procedure is as follows:
* <ol>
* <li>If <SD>/current/<bpid>/previous exists then delete it</li>
* <li>Rename <SD>/current/<bpid>/current to
* <SD>/current/bpid/current/previous.tmp</li>
* <li>Create new <SD>current/<bpid>/current directory</li>
* <ol>
* <li>Hard links for block files are created from previous.tmp to current</li>
* <li>Save new version file in current directory</li>
* </ol>
* <li>Rename previous.tmp to previous</li> </ol>
*
* @param bpSd storage directory <SD>/current/<bpid>
* @param nsInfo Namespace Info from the namenode
* @throws IOException on error
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,557 | BlockPoolSliceStorage.java | // Upgrading is applicable only to release with federation or after | 0 | // Upgrading is applicable only to release with federation or after | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,558 | BlockPoolSliceStorage.java | // get <SD>/previous directory | 0 | // get <SD>/previous directory | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,559 | BlockPoolSliceStorage.java | // 1. Delete <SD>/current/<bpid>/previous dir before upgrading | 0 | // 1. Delete <SD>/current/<bpid>/previous dir before upgrading | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,560 | BlockPoolSliceStorage.java | // 3. Create new <SD>/current with block files hardlinks and VERSION | 0 | // 3. Create new <SD>/current with block files hardlinks and VERSION | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,561 | BlockPoolSliceStorage.java | /**
* Cleanup the detachDir.
*
* If the directory is not empty report an error; Otherwise remove the
* directory.
*
* @param detachDir detach directory
* @throws IOException if the directory is not empty or it can not be removed
*/ | 0 | /**
* Cleanup the detachDir.
*
* If the directory is not empty report an error; Otherwise remove the
* directory.
*
* @param detachDir detach directory
* @throws IOException if the directory is not empty or it can not be removed
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,562 | BlockPoolSliceStorage.java | /**
* Restore all files from the trash directory to their corresponding
* locations under current/
*/ | 0 | /**
* Restore all files from the trash directory to their corresponding
* locations under current/
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,563 | BlockPoolSliceStorage.java | // Recurse to process subdirectories. | 0 | // Recurse to process subdirectories. | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,564 | BlockPoolSliceStorage.java | // Failsafe - we should not hit this case but let's make sure
// we never overwrite a newer version of a block file with an
// older version. | 0 | // Failsafe - we should not hit this case but let's make sure
// we never overwrite a newer version of a block file with an
// older version. | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
8,565 | BlockPoolSliceStorage.java | /*
* Roll back to old snapshot at the block pool level
* If previous directory exists:
* <ol>
* <li>Rename <SD>/current/<bpid>/current to removed.tmp</li>
* <li>Rename * <SD>/current/<bpid>/previous to current</li>
* <li>Remove removed.tmp</li>
* </ol>
*
* Do nothing if previous directory does not exist.
* @param bpSd Block pool storage directory at <SD>/current/<bpid>
*/ | 0 | /*
* Roll back to old snapshot at the block pool level
* If previous directory exists:
* <ol>
* <li>Rename <SD>/current/<bpid>/current to removed.tmp</li>
* <li>Rename * <SD>/current/<bpid>/previous to current</li>
* <li>Remove removed.tmp</li>
* </ol>
*
* Do nothing if previous directory does not exist.
* @param bpSd Block pool storage directory at <SD>/current/<bpid>
*/ | BlockPoolSliceStorage.java | [
1,
0,
0,
0,
0,
0,
0
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.