com.unister.semweb.drums.bucket
Class BucketSplitter<Data extends AbstractKVStorable>

java.lang.Object
  extended by com.unister.semweb.drums.bucket.BucketSplitter<Data>
Type Parameters:
Data - an implementation of AbstractKVStorable, e.g. GeneralStorable

public class BucketSplitter<Data extends AbstractKVStorable>
extends java.lang.Object

This class manages the splitting of a bucket. It would be possible to implement all functionality of this class in a static context. But for reasons of inheritance, the implementation is done this way. The splitting should be done by the following steps

  • determine new maxRangeValues
  • adapt HashFunction or generate a new one
  • generate files and move elements according to the old and new HashFunction
  • store the HashFunction

    Author:
    Martin Nettling

    Constructor Summary
    BucketSplitter(RangeHashFunction hashFunction, DRUMSParameterSet<Data> gp)
              Instantiates a new BucketSplitter
     
    Method Summary
     void splitAndStoreConfiguration(int bucketId, int numberOfPartitions)
               
     
    Methods inherited from class java.lang.Object
    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
     

    Constructor Detail

    BucketSplitter

    public BucketSplitter(RangeHashFunction hashFunction,
                          DRUMSParameterSet<Data> gp)
    Instantiates a new BucketSplitter

    Parameters:
    hashFunction -
    gp -
    Method Detail

    splitAndStoreConfiguration

    public void splitAndStoreConfiguration(int bucketId,
                                           int numberOfPartitions)
                                    throws java.io.IOException,
                                           FileLockException
    Parameters:
    bucketId -
    numberOfPartitions -
    Throws:
    java.io.IOException
    FileLockException