File size: 662 Bytes
f0743f4 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | import { math } from '~/utils';
const clusterConfig = {
/** Duration in seconds that the leader lease is valid before it expires */
LEADER_LEASE_DURATION: math(process.env.LEADER_LEASE_DURATION, 25),
/** Interval in seconds at which the leader renews its lease */
LEADER_RENEW_INTERVAL: math(process.env.LEADER_RENEW_INTERVAL, 10),
/** Maximum number of retry attempts when renewing the lease fails */
LEADER_RENEW_ATTEMPTS: math(process.env.LEADER_RENEW_ATTEMPTS, 3),
/** Delay in seconds between retry attempts when renewing the lease */
LEADER_RENEW_RETRY_DELAY: math(process.env.LEADER_RENEW_RETRY_DELAY, 0.5),
};
export { clusterConfig };
|