Class IntegrationTestBigLinkedList.Generator.GeneratorMapper

java.lang.Object
org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>
org.apache.hadoop.hbase.test.IntegrationTestBigLinkedList.Generator.GeneratorMapper
Direct Known Subclasses:
IntegrationTestBigLinkedListWithVisibility.VisibilityGenerator.VisibilityGeneratorMapper
Enclosing class:
IntegrationTestBigLinkedList.Generator

static class IntegrationTestBigLinkedList.Generator.GeneratorMapper extends org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>
Some ASCII art time:

[ . . . ] represents one batch of random longs of length WIDTH

                _________________________
               |                  ______ |
               |                 |      ||
             .-+-----------------+-----.||
             | |                 |     |||
 first   = [ . . . . . . . . . . . ]   |||
             ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^     |||
             | | | | | | | | | | |     |||
 prev    = [ . . . . . . . . . . . ]   |||
             ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^     |||
             | | | | | | | | | | |     |||
 current = [ . . . . . . . . . . . ]   |||
                                       |||
 ...                                   |||
                                       |||
 last    = [ . . . . . . . . . . . ]   |||
             ^ ^ ^ ^ ^ ^ ^ ^ ^ ^ ^_____|||
             |                 |________||
             |___________________________|
 
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static class 
     
    class 
    Randomly selects and walks a random flushed loop concurrently with the Generator Mapper by spawning ConcurrentWalker's with specified StartNodes.

    Nested classes/interfaces inherited from class org.apache.hadoop.mapreduce.Mapper

    org.apache.hadoop.mapreduce.Mapper.Context
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    (package private) byte[]
     
    (package private) org.apache.hadoop.conf.Configuration
     
    (package private) org.apache.hadoop.hbase.client.Connection
     
    (package private) long
     
    (package private) byte[][]
     
    (package private) byte[][]
     
    (package private) List<Long>
     
    (package private) final Object
     
    (package private) int
     
    (package private) byte[]
     
    (package private) boolean
     
    (package private) org.apache.hadoop.hbase.client.BufferedMutator
     
    (package private) long
     
    (package private) int
     
    (package private) byte[][]
     
    private org.apache.hadoop.hbase.util.Random64
     
    (package private) byte[]
     
    (package private) List<Thread>
     
    (package private) boolean
     
    (package private) int
     
    (package private) long
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    private void
    addFlushed(byte[] rowKey)
     
    private static <T> void
    circularLeftShift(T[] first)
     
    protected void
    cleanup(org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>.org.apache.hadoop.mapreduce.Mapper.Context context)
     
    protected void
     
    private void
     
    protected void
    map(org.apache.hadoop.io.BytesWritable key, org.apache.hadoop.io.NullWritable value, org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>.org.apache.hadoop.mapreduce.Mapper.Context output)
     
    protected void
    persist(org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>.org.apache.hadoop.mapreduce.Mapper.Context output, long count, byte[][] prev, byte[][] current, byte[] id)
     
    protected void
    setup(org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>.org.apache.hadoop.mapreduce.Mapper.Context context)
     
    private void
    startWalkers(int numWalkers, org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>.org.apache.hadoop.mapreduce.Mapper.Context context)
     

    Methods inherited from class org.apache.hadoop.mapreduce.Mapper

    run

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

  • Method Details

    • setup

      protected void setup(org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>.org.apache.hadoop.mapreduce.Mapper.Context context) throws IOException, InterruptedException
      Overrides:
      setup in class org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>
      Throws:
      IOException
      InterruptedException
    • instantiateHTable

      protected void instantiateHTable() throws IOException
      Throws:
      IOException
    • cleanup

      protected void cleanup(org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>.org.apache.hadoop.mapreduce.Mapper.Context context) throws IOException, InterruptedException
      Overrides:
      cleanup in class org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>
      Throws:
      IOException
      InterruptedException
    • map

      protected void map(org.apache.hadoop.io.BytesWritable key, org.apache.hadoop.io.NullWritable value, org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>.org.apache.hadoop.mapreduce.Mapper.Context output) throws IOException
      Overrides:
      map in class org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>
      Throws:
      IOException
    • circularLeftShift

      private static <T> void circularLeftShift(T[] first)
    • addFlushed

      private void addFlushed(byte[] rowKey)
    • persist

      protected void persist(org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>.org.apache.hadoop.mapreduce.Mapper.Context output, long count, byte[][] prev, byte[][] current, byte[] id) throws IOException
      Throws:
      IOException
    • startWalkers

      private void startWalkers(int numWalkers, org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.mapreduce.Mapper<org.apache.hadoop.io.BytesWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable,org.apache.hadoop.io.NullWritable>.org.apache.hadoop.mapreduce.Mapper.Context context)
    • joinWalkers

      private void joinWalkers()