org.apache.hadoop.hbase.migration.nineteen
Class HStoreFileToStoreFile

java.lang.Object
  extended by org.apache.hadoop.conf.Configured
      extended by org.apache.hadoop.hbase.migration.nineteen.HStoreFileToStoreFile
All Implemented Interfaces:
org.apache.hadoop.conf.Configurable, org.apache.hadoop.util.Tool

public class HStoreFileToStoreFile
extends org.apache.hadoop.conf.Configured
implements org.apache.hadoop.util.Tool

Mapper that rewrites hbase 0.19 HStoreFiles as 0.20 StoreFiles. Creates passed directories as input and output. On startup, it does not check filesystem is 0.19 generation just in case it fails part way so it should be possible to rerun the MR job. It'll just fix the 0.19 regions found. If the input dir does not exist, it first crawls the filesystem to find the files to migrate writing a file into the input directory. Next it starts up the MR job to rewrite the 0.19 HStoreFiles as 0.20 StoreFiles deleting the old as it goes. Presumption is that only one file per in the family Store else stuff breaks; i.e. the 0.19 install was major compacted before migration began. If this job fails, fix why then it should be possible to rerun the job. You may want to edit the generated file in the input dir first.


Nested Class Summary
static class HStoreFileToStoreFile.Map
           
 
Field Summary
static String JOBNAME
           
 
Method Summary
static void main(String[] args)
           
 int run(String[] args)
           
 
Methods inherited from class org.apache.hadoop.conf.Configured
getConf, setConf
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.hadoop.conf.Configurable
getConf, setConf
 

Field Detail

JOBNAME

public static final String JOBNAME
See Also:
Constant Field Values
Method Detail

run

public int run(String[] args)
        throws Exception
Specified by:
run in interface org.apache.hadoop.util.Tool
Throws:
Exception

main

public static void main(String[] args)
                 throws Exception
Throws:
Exception


Copyright © 2010 The Apache Software Foundation