org.mapdb
Interface CC


public interface CC

Compiler Configuration. There are some static final boolean fields, which describe features MapDB was compiled with.

MapDB can be compiled with/without some features. For example fine logging is useful for debuging, but should not be present in production version. Java does not have preprocessor so we use Dead code elimination to achieve it.

Typical usage:

     if(CC.PARANOID && arg.calculateSize()!=33){  //calculateSize may take long time
         throw new IllegalArgumentException("wrong size");
     }
 

Author:
Jan Kotek

Field Summary
static int ASYNC_RECID_PREALLOC_QUEUE_SIZE
           
static int ASYNC_WRITE_FLUSH_DELAY
           
static int ASYNC_WRITE_QUEUE_SIZE
           
static int CONCURRENCY
          Concurrency level.
static String DEFAULT_CACHE
           
static int DEFAULT_CACHE_SIZE
           
static int DEFAULT_FREE_SPACE_RECLAIM_Q
           
static boolean FAIR_LOCKS
          controls if locks used in MapDB are fair
static boolean LOG_STORE
          Compile-in detailed log messages from store.
static boolean PARANOID
          Compile with more assertions and verifications.
static int VOLUME_CHUNK_SHIFT
           
 

Field Detail

PARANOID

static final boolean PARANOID
Compile with more assertions and verifications. For example HashMap may check if keys implements hash function correctly. This may slow down MapDB thousands times

See Also:
Constant Field Values

LOG_STORE

static final boolean LOG_STORE
Compile-in detailed log messages from store.

See Also:
Constant Field Values

ASYNC_WRITE_FLUSH_DELAY

static final int ASYNC_WRITE_FLUSH_DELAY
See Also:
Constant Field Values

ASYNC_WRITE_QUEUE_SIZE

static final int ASYNC_WRITE_QUEUE_SIZE
See Also:
Constant Field Values

ASYNC_RECID_PREALLOC_QUEUE_SIZE

static final int ASYNC_RECID_PREALLOC_QUEUE_SIZE
See Also:
Constant Field Values

CONCURRENCY

static final int CONCURRENCY
Concurrency level. Should be greater than number of threads accessing MapDB concurrently. On other side larger number consumes more memory

This number must be power of two: `CONCURRENCY = 2^N`

See Also:
Constant Field Values

DEFAULT_CACHE_SIZE

static final int DEFAULT_CACHE_SIZE
See Also:
Constant Field Values

DEFAULT_CACHE

static final String DEFAULT_CACHE
See Also:
Constant Field Values

DEFAULT_FREE_SPACE_RECLAIM_Q

static final int DEFAULT_FREE_SPACE_RECLAIM_Q
See Also:
Constant Field Values

FAIR_LOCKS

static final boolean FAIR_LOCKS
controls if locks used in MapDB are fair

See Also:
Constant Field Values

VOLUME_CHUNK_SHIFT

static final int VOLUME_CHUNK_SHIFT
See Also:
Constant Field Values


Copyright © 2014. All Rights Reserved.