import _m0 from "protobufjs/minimal";
import { HederaFunctionality } from "./basic_types";
export declare const protobufPackage = "proto";
/** A set of operations which should be collectively throttled at a given milli-ops-per-second limit. */
export interface ThrottleGroup {
/** The operations to be throttled */
operations: HederaFunctionality[];
/**
* The number of total operations per second across the entire network, multiplied by 1000. So, to
* choose 3 operations per second (which on a network of 30 nodes is a tenth of an operation per
* second for each node), set milliOpsPerSec = 3000. And to choose 3.6 ops per second, use
* milliOpsPerSec = 3600. Minimum allowed value is 1, and maximum allowed value is 9223372.
*/
milliOpsPerSec: number;
}
/** A list of throttle groups that should all compete for the same internal bucket. */
export interface ThrottleBucket {
/** A name for this bucket (primarily for use in logs) */
name: string;
/**
* The number of milliseconds required for this bucket to drain completely when full. The product
* of this number and the least common multiple of the milliOpsPerSec values in this bucket must
* not exceed 9223372036.
*/
burstPeriodMs: number;
/** The throttle groups competing for this bucket */
throttleGroups: ThrottleGroup[];
}
/**
* A list of throttle buckets which, simultaneously enforced, define the system's throttling policy.
*
* - When an operation appears in more than one throttling bucket, all its buckets must have room
* or it will be throttled.
* - An operation assigned to no buckets is always throttled.
*
*/
export interface ThrottleDefinitions {
throttleBuckets: ThrottleBucket[];
}
export declare const ThrottleGroup: {
encode(message: ThrottleGroup, writer?: _m0.Writer): _m0.Writer;
decode(input: _m0.Reader | Uint8Array, length?: number): ThrottleGroup;
fromJSON(object: any): ThrottleGroup;
toJSON(message: ThrottleGroup): unknown;
create(base?: DeepPartial): ThrottleGroup;
fromPartial(object: DeepPartial): ThrottleGroup;
};
export declare const ThrottleBucket: {
encode(message: ThrottleBucket, writer?: _m0.Writer): _m0.Writer;
decode(input: _m0.Reader | Uint8Array, length?: number): ThrottleBucket;
fromJSON(object: any): ThrottleBucket;
toJSON(message: ThrottleBucket): unknown;
create(base?: DeepPartial): ThrottleBucket;
fromPartial(object: DeepPartial): ThrottleBucket;
};
export declare const ThrottleDefinitions: {
encode(message: ThrottleDefinitions, writer?: _m0.Writer): _m0.Writer;
decode(input: _m0.Reader | Uint8Array, length?: number): ThrottleDefinitions;
fromJSON(object: any): ThrottleDefinitions;
toJSON(message: ThrottleDefinitions): unknown;
create(base?: DeepPartial): ThrottleDefinitions;
fromPartial(object: DeepPartial): ThrottleDefinitions;
};
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
export type DeepPartial = T extends Builtin ? T : T extends Array ? Array> : T extends ReadonlyArray ? ReadonlyArray> : T extends {
$case: string;
} ? {
[K in keyof Omit]?: DeepPartial;
} & {
$case: T["$case"];
} : T extends {} ? {
[K in keyof T]?: DeepPartial;
} : Partial;
export {};
//# sourceMappingURL=throttle_definitions.d.ts.map