// SPDX-License-Identifier: Apache-2.0
import { Duration } from '../../../../src/core/time/duration.js';
export class NoopLeaseRenewalService {
    buffer;
    counter;
    constructor() {
        this.buffer = new SharedArrayBuffer(Uint32Array.BYTES_PER_ELEMENT);
        this.counter = new Uint32Array(this.buffer);
        Atomics.store(this.counter, 0, 1);
    }
    async isScheduled(_scheduleId) {
        return _scheduleId > 0;
    }
    async schedule(_lease) {
        return Atomics.add(this.counter, 0, 1);
    }
    async cancel(_scheduleId) {
        return true;
    }
    async cancelAll() {
        return new Map();
    }
    calculateRenewalDelay(_lease) {
        return Duration.ofSeconds(10);
    }
}
//# sourceMappingURL=noop-lease-renewal-service.test.js.map