Tabnine Logo
VolumeScanner.markSuspectBlock
Code IndexAdd Tabnine to your IDE (free)

How to use
markSuspectBlock
method
in
org.apache.hadoop.hdfs.server.datanode.VolumeScanner

Best Java code snippets using org.apache.hadoop.hdfs.server.datanode.VolumeScanner.markSuspectBlock (Showing top 3 results out of 315)

origin: org.apache.hadoop/hadoop-hdfs

/**
 * Mark a block as "suspect."
 *
 * This means that we should try to rescan it soon.  Note that the
 * VolumeScanner keeps a list of recently suspicious blocks, which
 * it uses to avoid rescanning the same block over and over in a short
 * time frame.
 *
 * @param storageId     The ID of the storage where the block replica
 *                      is being stored.
 * @param block         The block's ID and block pool id.
 */
synchronized void markSuspectBlock(String storageId, ExtendedBlock block) {
 if (!isEnabled()) {
  LOG.debug("Not scanning suspicious block {} on {}, because the block " +
    "scanner is disabled.", block, storageId);
  return;
 }
 VolumeScanner scanner = scanners.get(storageId);
 if (scanner == null) {
  // This could happen if the volume is in the process of being removed.
  // The removal process shuts down the VolumeScanner, but the volume
  // object stays around as long as there are references to it (which
  // should not be that long.)
  LOG.info("Not scanning suspicious block {} on {}, because there is no " +
    "volume scanner for that storageId.", block, storageId);
  return;
 }
 scanner.markSuspectBlock(block);
}
origin: ch.cern.hadoop/hadoop-hdfs

/**
 * Mark a block as "suspect."
 *
 * This means that we should try to rescan it soon.  Note that the
 * VolumeScanner keeps a list of recently suspicious blocks, which
 * it uses to avoid rescanning the same block over and over in a short
 * time frame.
 *
 * @param storageId     The ID of the storage where the block replica
 *                      is being stored.
 * @param block         The block's ID and block pool id.
 */
synchronized void markSuspectBlock(String storageId, ExtendedBlock block) {
 if (!isEnabled()) {
  LOG.debug("Not scanning suspicious block {} on {}, because the block " +
    "scanner is disabled.", block, storageId);
  return;
 }
 VolumeScanner scanner = scanners.get(storageId);
 if (scanner == null) {
  // This could happen if the volume is in the process of being removed.
  // The removal process shuts down the VolumeScanner, but the volume
  // object stays around as long as there are references to it (which
  // should not be that long.)
  LOG.info("Not scanning suspicious block {} on {}, because there is no " +
    "volume scanner for that storageId.", block, storageId);
  return;
 }
 scanner.markSuspectBlock(block);
}
origin: io.prestosql.hadoop/hadoop-apache

/**
 * Mark a block as "suspect."
 *
 * This means that we should try to rescan it soon.  Note that the
 * VolumeScanner keeps a list of recently suspicious blocks, which
 * it uses to avoid rescanning the same block over and over in a short
 * time frame.
 *
 * @param storageId     The ID of the storage where the block replica
 *                      is being stored.
 * @param block         The block's ID and block pool id.
 */
synchronized void markSuspectBlock(String storageId, ExtendedBlock block) {
 if (!isEnabled()) {
  LOG.debug("Not scanning suspicious block {} on {}, because the block " +
    "scanner is disabled.", block, storageId);
  return;
 }
 VolumeScanner scanner = scanners.get(storageId);
 if (scanner == null) {
  // This could happen if the volume is in the process of being removed.
  // The removal process shuts down the VolumeScanner, but the volume
  // object stays around as long as there are references to it (which
  // should not be that long.)
  LOG.info("Not scanning suspicious block {} on {}, because there is no " +
    "volume scanner for that storageId.", block, storageId);
  return;
 }
 scanner.markSuspectBlock(block);
}
org.apache.hadoop.hdfs.server.datanodeVolumeScannermarkSuspectBlock

Popular methods of VolumeScanner

  • calculateShouldScan
  • <init>
  • disableBlockPoolId
    Disallow the scanner from scanning the given block pool.
  • enableBlockPoolId
    Allow the scanner to scan the given block pool.
  • expireOldScannedBytesRecords
  • findNextUsableBlockIter
    Find a usable block iterator. We will consider available block iterators in order. This property is
  • getStatistics
  • interrupt
  • popNextSuspectBlock
    If there are elements in the suspectBlocks list, removes and returns the first one. Otherwise, retur
  • positiveMsToHours
  • printStats
  • runLoop
    Run an iteration of the VolumeScanner loop.
  • printStats,
  • runLoop,
  • saveBlockIterator,
  • scanBlock,
  • setConf,
  • setDaemon,
  • setName,
  • shutdown,
  • start

Popular in Java

  • Running tasks concurrently on multiple threads
  • addToBackStack (FragmentTransaction)
  • getSystemService (Context)
  • getSharedPreferences (Context)
  • GridLayout (java.awt)
    The GridLayout class is a layout manager that lays out a container's components in a rectangular gri
  • Format (java.text)
    The base class for all formats. This is an abstract base class which specifies the protocol for clas
  • Collections (java.util)
    This class consists exclusively of static methods that operate on or return collections. It contains
  • BlockingQueue (java.util.concurrent)
    A java.util.Queue that additionally supports operations that wait for the queue to become non-empty
  • JLabel (javax.swing)
  • JPanel (javax.swing)
  • Top Vim plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now