Package krati.core.segment

Examples of krati.core.segment.MemorySegmentFactory


    int idStart = rand.nextInt(1000);
    int idCount = 1000 + rand.nextInt(1000);
    int segmentFileSizeMB = Segment.minSegmentFileSizeMB;
    ElementSerializer<SimpleElement> serializer = createSerializer();
   
    return StoreFactory.createElementStorePartition(storeHomeDir, idStart, idCount, new MemorySegmentFactory(), segmentFileSizeMB, serializer);
  }
View Full Code Here


  protected ArrayStoreElement<SimpleElement> createElementStore(int idStart, int idCount) throws Exception {
    File storeHomeDir = getStoreHomeDir();
    int segmentFileSizeMB = Segment.minSegmentFileSizeMB;
    ElementSerializer<SimpleElement> serializer = createSerializer();
   
    return StoreFactory.createElementStorePartition(storeHomeDir, idStart, idCount, new MemorySegmentFactory(), segmentFileSizeMB, serializer);
  }
View Full Code Here

    int initialCapacity = 500000;
    String storeName = getClass().getSimpleName();
    File storeHome = FileUtils.getTestDir(storeName);
   
    int indexSegmentFileSizeMB = 8;
    SegmentFactory indexSegmentFactory = new MemorySegmentFactory();
    int storeSegmentFileSizeMB = 32;
    SegmentFactory storeSegmentFactory = new MemorySegmentFactory();
   
    try {
      KratiDataStore underlyingStore =
        StoreFactory.createKratiDataStore(storeHome,
                                          initialCapacity,
View Full Code Here

  protected void setUp() {
    int capacity = 1000;
    String storeName = getClass().getSimpleName();
    try {
      File storeHome = FileUtils.getTestDir(storeName);
      KratiArrayStore kas = StoreFactory.createKratiArrayStore(storeHome, capacity, new MemorySegmentFactory(), 32);
      store = new KratiArrayStoreFilters(kas);
    } catch (Exception e) {
      e.printStackTrace();
    }
  }
View Full Code Here

    int initialCapacity = 500000;
    String storeName = getClass().getSimpleName();
    File storeHome = FileUtils.getTestDir(storeName);
   
    int indexSegmentFileSizeMB = 8;
    SegmentFactory indexSegmentFactory = new MemorySegmentFactory();
    int storeSegmentFileSizeMB = 32;
    SegmentFactory storeSegmentFactory = new MemorySegmentFactory();
   
    try {
      store = StoreFactory.createKratiDataStore(storeHome,
                                                initialCapacity,
                                                indexSegmentFileSizeMB,
View Full Code Here

    int initialCapacity = 500000;
    String storeName = getClass().getSimpleName();
    File storeHome = FileUtils.getTestDir(storeName);
   
    int indexSegmentFileSizeMB = 8;
    SegmentFactory indexSegmentFactory = new MemorySegmentFactory();
    int storeSegmentFileSizeMB = 32;
    SegmentFactory storeSegmentFactory = new MemorySegmentFactory();
   
    try {
      KratiDataStore underlyingStore =
        StoreFactory.createKratiDataStore(storeHome,
                                          initialCapacity,
View Full Code Here

    ArrayStoreElement<E> elementStore =
      StoreFactory.createElementStorePartition(
          elementStoreDir,
          getElementStoreIndexStart(),
          getElementStoreCapacity(),
          new MemorySegmentFactory(),
          elementStoreSegMB,
          createElementSerializer());
    return elementStore;
  }
View Full Code Here

    ArrayStoreElement<E> elementStore =
      StoreFactory.createElementStorePartition(
          elementStoreDir,
          getElementStoreIndexStart(),
          getElementStoreCapacity(),
          new MemorySegmentFactory(),
          elementStoreSegMB,
          createElementSerializer());
    return elementStore;
  }
View Full Code Here

  }
 
  protected ArrayStoreConnections createConnectionsStore() throws Exception {
    File connectionsStoreDir = new File(getHomeDir(), "connections-store");
    int connectionsStoreSegMB = 32;
    SegmentFactory connectionsStoreSegFactory = new MemorySegmentFactory();
   
    ArrayStoreConnections connectionsStore =
      StoreFactory.createArrayStoreConnections(
          connectionsStoreDir,
          getConnectionsStoreCapacity(),
View Full Code Here

 
  public KratiArrayStoreCurrents(int length,
                                 int batchSize,
                                 int numSyncBatches,
                                 String homeDirPath) throws Exception {
    this(length, batchSize, numSyncBatches, homeDirPath, new MemorySegmentFactory());
  }
View Full Code Here

TOP

Related Classes of krati.core.segment.MemorySegmentFactory

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.