Package com.github.ambry.config
Class CompositeAccountServiceConfig
- java.lang.Object
-
- com.github.ambry.config.CompositeAccountServiceConfig
-
public class CompositeAccountServiceConfig extends java.lang.Object
Configs for CompositeAccountService
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
COMPOSITE_ACCOUNT_SERVICE_PREFIX
static java.lang.String
CONSISTENCY_CHECKER_INTERVAL_MINUTES
static java.lang.String
CONSISTENCY_CHECKER_SHUTDOWN_TIMEOUT_MINUTES
int
consistencyCheckerIntervalMinutes
The time interval in minutes for checking consistency in account data between primary and secondary sources.int
consistencyCheckerShutdownTimeoutMinutes
The timeout in minutes to shut down the consistency checker ofCompositeAccountService
.static java.lang.String
PRIMARY_ACCOUNT_SERVICE_FACTORY
java.lang.String
primaryAccountServiceFactory
The AccountServiceFactory that is used inCompositeAccountService
as primary source of account-related information.static java.lang.String
SAMPLING_PERCENTAGE_FOR_GET_CONSISTENCY_CHECK
int
samplingPercentageForGetConsistencyCheck
Percentage of GET requests we want to compare results between primary and secondary sources.static java.lang.String
SECONDARY_ACCOUNT_SERVICE_FACTORY
java.lang.String
secondaryAccountServiceFactory
The AccountServiceFactory that is used inCompositeAccountService
as secondary source of account-related information.
-
Constructor Summary
Constructors Constructor Description CompositeAccountServiceConfig(VerifiableProperties verifiableProperties)
-
-
-
Field Detail
-
COMPOSITE_ACCOUNT_SERVICE_PREFIX
public static final java.lang.String COMPOSITE_ACCOUNT_SERVICE_PREFIX
- See Also:
- Constant Field Values
-
CONSISTENCY_CHECKER_INTERVAL_MINUTES
public static final java.lang.String CONSISTENCY_CHECKER_INTERVAL_MINUTES
- See Also:
- Constant Field Values
-
CONSISTENCY_CHECKER_SHUTDOWN_TIMEOUT_MINUTES
public static final java.lang.String CONSISTENCY_CHECKER_SHUTDOWN_TIMEOUT_MINUTES
- See Also:
- Constant Field Values
-
SAMPLING_PERCENTAGE_FOR_GET_CONSISTENCY_CHECK
public static final java.lang.String SAMPLING_PERCENTAGE_FOR_GET_CONSISTENCY_CHECK
- See Also:
- Constant Field Values
-
PRIMARY_ACCOUNT_SERVICE_FACTORY
public static final java.lang.String PRIMARY_ACCOUNT_SERVICE_FACTORY
- See Also:
- Constant Field Values
-
SECONDARY_ACCOUNT_SERVICE_FACTORY
public static final java.lang.String SECONDARY_ACCOUNT_SERVICE_FACTORY
- See Also:
- Constant Field Values
-
consistencyCheckerIntervalMinutes
@Config("composite.account.service.consistency.checker.interval.minutes") @Default("5") public final int consistencyCheckerIntervalMinutes
The time interval in minutes for checking consistency in account data between primary and secondary sources. Setting to 0 will disable it. Default value is 5 minutes.
-
consistencyCheckerShutdownTimeoutMinutes
@Config("composite.account.service.consistency.checker.shutdown.timeout.minutes") @Default("1") public final int consistencyCheckerShutdownTimeoutMinutes
The timeout in minutes to shut down the consistency checker ofCompositeAccountService
. Default value is 1 minutes.
-
samplingPercentageForGetConsistencyCheck
@Config("composite.account.service.sampling.percentage.for.get.consistency.check") @Default("50") public final int samplingPercentageForGetConsistencyCheck
Percentage of GET requests we want to compare results between primary and secondary sources. Default value is 50%. If we want to avoid latency due to comparison, this value can be set to 0.
-
primaryAccountServiceFactory
@Config("composite.account.service.primary.account.service.factory") @Default("com.github.ambry.account.HelixAccountServiceFactory") public final java.lang.String primaryAccountServiceFactory
The AccountServiceFactory that is used inCompositeAccountService
as primary source of account-related information.
-
secondaryAccountServiceFactory
@Config("composite.account.service.secondary.account.service.factory") @Default("com.github.ambry.account.MySqlAccountServiceFactory") public final java.lang.String secondaryAccountServiceFactory
The AccountServiceFactory that is used inCompositeAccountService
as secondary source of account-related information.
-
-
Constructor Detail
-
CompositeAccountServiceConfig
public CompositeAccountServiceConfig(VerifiableProperties verifiableProperties)
-
-