SMILA 1.0 API documentation

org.eclipse.smila.importing.state.objectstore
Class StateStoreConfiguration

java.lang.Object
  extended by org.eclipse.smila.importing.state.objectstore.StateStoreConfiguration

public class StateStoreConfiguration
extends java.lang.Object

configuration for ObjectStoreStateService. Main purpose is creation of configurable entry key so that it's possible to optimize the StateService for varying numbers of entries and to adapt it to underlying objectstore implementations.


Field Summary
static java.lang.String KEY_KEYPATTERN
          property name to the {@link String#format(String, Object...) pattern that combines shard part and segmented rest of digest into an entry key.
static java.lang.String KEY_SEGMENTCOUNT
          property name to configure the count of the segments in the remaining part of the entry key.
static java.lang.String KEY_SEGMENTLENGTH
          property name to configure the length of the segments in the remaining part of the entry key.
static java.lang.String KEY_SHARDLENGTH
          property name to configure the length of the "shard" part of the entry key.
 
Constructor Summary
StateStoreConfiguration(java.util.Properties properties)
          create configuration from properties.
 
Method Summary
 java.lang.String getEntryKey(java.lang.String idDigest)
          compute entry key from id digest according to configuration properties.
 java.lang.String getEntryKey(java.lang.String idDigest, java.lang.String compoundDigest)
          compute entry key from id digest for a compound element according to configuration properties.
 java.lang.String getShardKey(java.lang.String idDigest)
          compute entry key from id digest according to configuration properties.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

KEY_SHARDLENGTH

public static final java.lang.String KEY_SHARDLENGTH
property name to configure the length of the "shard" part of the entry key.

See Also:
Constant Field Values

KEY_SEGMENTLENGTH

public static final java.lang.String KEY_SEGMENTLENGTH
property name to configure the length of the segments in the remaining part of the entry key.

See Also:
Constant Field Values

KEY_SEGMENTCOUNT

public static final java.lang.String KEY_SEGMENTCOUNT
property name to configure the count of the segments in the remaining part of the entry key.

See Also:
Constant Field Values

KEY_KEYPATTERN

public static final java.lang.String KEY_KEYPATTERN
property name to the {@link String#format(String, Object...) pattern that combines shard part and segmented rest of digest into an entry key.

See Also:
Constant Field Values
Constructor Detail

StateStoreConfiguration

public StateStoreConfiguration(java.util.Properties properties)
create configuration from properties.

Method Detail

getEntryKey

public java.lang.String getEntryKey(java.lang.String idDigest)
compute entry key from id digest according to configuration properties.


getEntryKey

public java.lang.String getEntryKey(java.lang.String idDigest,
                                    java.lang.String compoundDigest)
compute entry key from id digest for a compound element according to configuration properties. In this case the shard ID is computed from the compoundDigest, and the complete idDigest is used for the segmented part.


getShardKey

public java.lang.String getShardKey(java.lang.String idDigest)
compute entry key from id digest according to configuration properties.


SMILA 1.0 API documentation