diff --git a/x/ccv/provider/keeper/distribution.go b/x/ccv/provider/keeper/distribution.go index b20c07c15e..928fbf3150 100644 --- a/x/ccv/provider/keeper/distribution.go +++ b/x/ccv/provider/keeper/distribution.go @@ -411,7 +411,7 @@ func (k Keeper) AllocateTokensToConsumerValidators( // consumer reward pools getter and setter -// GetConsumerRewardsAllocation returns the consumer rewards allocation for the given consumer id +// [DEPRECATED - See #2311] GetConsumerRewardsAllocation returns the consumer rewards allocation for the given consumer id func (k Keeper) GetConsumerRewardsAllocation(ctx sdk.Context, consumerId string) (pool types.ConsumerRewardsAllocation) { store := ctx.KVStore(k.storeKey) b := store.Get(types.ConsumerRewardsAllocationKey(consumerId)) @@ -419,14 +419,14 @@ func (k Keeper) GetConsumerRewardsAllocation(ctx sdk.Context, consumerId string) return } -// SetConsumerRewardsAllocation sets the consumer rewards allocation for the given consumer id +// [DEPRECATED - See #2311] SetConsumerRewardsAllocation sets the consumer rewards allocation for the given consumer id func (k Keeper) SetConsumerRewardsAllocation(ctx sdk.Context, consumerId string, pool types.ConsumerRewardsAllocation) { store := ctx.KVStore(k.storeKey) b := k.cdc.MustMarshal(&pool) store.Set(types.ConsumerRewardsAllocationKey(consumerId), b) } -// DeleteConsumerRewardsAllocation deletes the consumer rewards allocation for the given consumer id +// [DEPRECATED - See #2311] DeleteConsumerRewardsAllocation deletes the consumer rewards allocation for the given consumer id func (k Keeper) DeleteConsumerRewardsAllocation(ctx sdk.Context, consumerId string) { store := ctx.KVStore(k.storeKey) store.Delete(types.ConsumerRewardsAllocationKey(consumerId)) diff --git a/x/ccv/provider/types/keys.go b/x/ccv/provider/types/keys.go index 345a26e252..1892ba8a10 100644 --- a/x/ccv/provider/types/keys.go +++ b/x/ccv/provider/types/keys.go @@ -119,6 +119,7 @@ const ( DenylistKeyName = "DenylistKey" + // [DEPRECATED - See #2311] ConsumerRewardsAllocationKeyName = "ConsumerRewardsAllocationKey" ConsumerCommissionRateKeyName = "ConsumerCommissionRateKey" @@ -329,7 +330,7 @@ func getKeyPrefixes() map[string]byte { // denylisted. DenylistKeyName: 37, - // ConsumerRewardsAllocationKey is the key for storing for each consumer the ICS rewards + // [DEPRECATED - See #2311] ConsumerRewardsAllocationKey is the key for storing for each consumer the ICS rewards // allocated to the consumer rewards pool ConsumerRewardsAllocationKeyName: 38, @@ -606,7 +607,7 @@ func OptedInKey(consumerId string, providerAddr ProviderConsAddress) []byte { return StringIdAndConsAddrKey(OptedInKeyPrefix(), consumerId, providerAddr.ToSdkConsAddr()) } -// ConsumerRewardsAllocationKey returns the key used to store the ICS rewards per consumer chain +// [DEPRECATED - See #2311]ConsumerRewardsAllocationKey returns the key used to store the ICS rewards per consumer chain func ConsumerRewardsAllocationKey(consumerId string) []byte { return append([]byte{mustGetKeyPrefix(ConsumerRewardsAllocationKeyName)}, []byte(consumerId)...) }