shgraph.hedera-protobuf-java-api.0.55.0.source-code.node_stake_update.proto Maven / Gradle / Ivy
The newest version!
syntax = "proto3";
package proto;
/*-
*
* Hedera Network Services Protobuf
*
* Copyright (C) 2018 - 2021 Hedera Hashgraph, LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
option java_package = "com.hederahashgraph.api.proto.java";
// <<>> This comment is special code for setting PBJ Compiler java package
option java_multiple_files = true;
import "basic_types.proto";
import "timestamp.proto";
/**
* Updates the staking info at the end of staking period to indicate new staking period has started.
*/
message NodeStakeUpdateTransactionBody {
/**
* Time and date of the end of the staking period that is ending
*/
Timestamp end_of_staking_period = 1;
/**
* Staking info of each node at the beginning of the new staking period
*/
repeated NodeStake node_stake = 2;
/**
* The maximum reward rate, in tinybars per whole hbar, that any account could receive in this
* staking period.
*/
int64 max_staking_reward_rate_per_hbar = 3;
/**
* The fraction of the network and service fees paid to the node reward account 0.0.801.
*/
Fraction node_reward_fee_fraction = 4;
/**
* The maximum number of trailing periods for which a user can collect rewards. For example, if this
* is 365 with a UTC calendar day period, then users must collect rewards at least once per calendar
* year to avoid missing any value.
*/
int64 staking_periods_stored = 5;
/**
* The number of minutes in a staking period. Note for the special case of 1440 minutes, periods are
* treated as UTC calendar days, rather than repeating 1440 minute periods left-aligned at the epoch.
*/
int64 staking_period = 6;
/**
* The fraction of the network and service fees paid to the staking reward account 0.0.800.
*/
Fraction staking_reward_fee_fraction = 7;
/**
* The minimum balance of staking reward account 0.0.800 required to active rewards.
*/
int64 staking_start_threshold = 8;
/**
* (DEPRECATED) The maximum total number of tinybars to be distributed as staking rewards in the
* ending period. Please consult the max_total_reward field instead.
*/
int64 staking_reward_rate = 9 [deprecated = true];
/**
* The amount of the staking reward funds (account 0.0.800) reserved to pay pending rewards that
* have been earned but not collected.
*/
int64 reserved_staking_rewards = 10;
/**
* The unreserved balance of account 0.0.800 at the close of the just-ending period; this value is
* used to compute the HIP-782 balance ratio.
*/
int64 unreserved_staking_reward_balance = 11;
/**
* The unreserved tinybar balance of account 0.0.800 required to achieve the maximum per-hbar reward
* rate in any period; please see HIP-782 for details.
*/
int64 reward_balance_threshold = 12;
/**
* The maximum amount of tinybar that can be staked for reward while still achieving the maximum
* per-hbar reward rate in any period; please see HIP-782 for details.
*/
int64 max_stake_rewarded = 13;
/**
* The maximum total tinybars that could be paid as staking rewards in the ending period, after
* applying the settings for the 0.0.800 balance threshold and the maximum stake rewarded. This
* field replaces the deprecated field staking_reward_rate. It is only for convenience, since a
* mirror node could also calculate its value by iterating the node_stake list and summing
* stake_rewarded fields; then multiplying this sum by the max_staking_reward_rate_per_hbar.
*/
int64 max_total_reward = 14;
}
/**
* Staking info for each node at the end of a staking period.
*/
message NodeStake {
/**
* The maximum stake (rewarded or not rewarded) this node can have as consensus weight. If its stake to
* reward is above this maximum at the start of a period, then accounts staking to the node in that
* period will be rewarded at a lower rate scaled by (maxStake / stakeRewardStart).
*/
int64 max_stake = 1;
/**
* The minimum stake (rewarded or not rewarded) this node must reach before having non-zero consensus weight.
* If its total stake is below this minimum at the start of a period, then accounts staking to the node in
* that period will receive no rewards.
*/
int64 min_stake = 2;
/**
* The id of this node.
*/
int64 node_id = 3;
/**
* The reward rate _per whole hbar_ that was staked to this node with declineReward=false from the start of
* the staking period that is ending.
*/
int64 reward_rate = 4;
/**
* Consensus weight of this node for the new staking period.
*/
int64 stake = 5;
/**
* Total of (balance + stakedToMe) for all accounts staked to this node with declineReward=true, at the
* beginning of the new staking period.
*/
int64 stake_not_rewarded = 6;
/**
* Total of (balance + stakedToMe) for all accounts staked to this node with declineReward=false, at the
* beginning of the new staking period.
*/
int64 stake_rewarded = 7;
}