public class ReplaceConfigurationCommand extends Object implements RemoteCommand<Nothing>, ComparableByContent<ReplaceConfigurationCommand>
Modifier and Type | Field and Description |
---|---|
static SerializationHandle<ReplaceConfigurationCommand> |
SERIALIZATION_HANDLE |
Constructor and Description |
---|
ReplaceConfigurationCommand(BucketConfiguration newConfiguration,
TokensInheritanceStrategy tokensInheritanceStrategy) |
Modifier and Type | Method and Description |
---|---|
boolean |
equalsByContent(ReplaceConfigurationCommand other) |
long |
estimateTokensToConsume() |
CommandResult<Nothing> |
execute(MutableBucketEntry mutableEntry,
long currentTimeNanos) |
long |
getConsumedTokens(Nothing result) |
BucketConfiguration |
getNewConfiguration() |
SerializationHandle |
getSerializationHandle() |
TokensInheritanceStrategy |
getTokensInheritanceStrategy() |
boolean |
isImmediateSyncRequired(long unsynchronizedTokens,
long nanosSinceLastSync) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
asVerbose, deserialize, isInitializationCommand, serialize
equals
public static final SerializationHandle<ReplaceConfigurationCommand> SERIALIZATION_HANDLE
public ReplaceConfigurationCommand(BucketConfiguration newConfiguration, TokensInheritanceStrategy tokensInheritanceStrategy)
public CommandResult<Nothing> execute(MutableBucketEntry mutableEntry, long currentTimeNanos)
execute
in interface RemoteCommand<Nothing>
public BucketConfiguration getNewConfiguration()
public TokensInheritanceStrategy getTokensInheritanceStrategy()
public SerializationHandle getSerializationHandle()
getSerializationHandle
in interface RemoteCommand<Nothing>
public boolean equalsByContent(ReplaceConfigurationCommand other)
equalsByContent
in interface ComparableByContent<ReplaceConfigurationCommand>
public boolean isImmediateSyncRequired(long unsynchronizedTokens, long nanosSinceLastSync)
isImmediateSyncRequired
in interface RemoteCommand<Nothing>
public long estimateTokensToConsume()
estimateTokensToConsume
in interface RemoteCommand<Nothing>
public long getConsumedTokens(Nothing result)
getConsumedTokens
in interface RemoteCommand<Nothing>
Copyright © 2021. All rights reserved.