/** * Consensus-level session state, ported from `core/sdk/src/session.rs`. * * Each client instance generates an ephemeral random `clientId` (u128). * After a Register commits, the server assigns a `session` number (commit op * number). Every replicated request (metadata and partition) advances a * monotonic request watermark; non-replicated requests reuse the current * value because they bypass server-side request sequencing. */ export declare class ConsensusSession { private _clientId; private _session; private requestCounter; private registerConsumed; constructor(clientId?: bigint); get clientId(): bigint; /** The bound session number, or null before Register commits. */ get session(): bigint | null; get isBound(): boolean; get hasActivity(): boolean; /** Binds the session after Register commits through consensus. */ bind(session: bigint): void; /** * Begins a registration, re-arming the session for a re-login. A prior * consumed or bound session is replaced wholesale (fresh client id, * unbound), so a repeat login encodes a clean Register instead of tripping * the one-shot guard. Returns the register request id, always 0. */ beginRegister(): bigint; /** * Next application request id, advancing the counter: 1, 2, 3, ... * Request 0 is reserved for Register. */ nextRequestId(): bigint; /** Current counter value without advancing it. */ currentRequestId(): bigint; } //# sourceMappingURL=session.d.ts.map