package com.cameleer.server.app.config;

import org.springframework.boot.context.properties.ConfigurationProperties;

/**
 * Configuration properties for the agent registry.
 * Bound from the {@code cameleer.server.agentregistry.*} namespace in application.yml.
 * <p>
 * Registered via {@code @EnableConfigurationProperties} on the application class.
 */
@ConfigurationProperties(prefix = "cameleer.server.agentregistry")
public class AgentRegistryConfig {

    private long heartbeatIntervalMs = 30_000;
    private long staleThresholdMs = 90_000;
    private long deadThresholdMs = 300_000;
    private long pingIntervalMs = 15_000;
    private long commandExpiryMs = 60_000;
    private long lifecycleCheckIntervalMs = 10_000;

    public long getHeartbeatIntervalMs() {
        return heartbeatIntervalMs;
    }

    public void setHeartbeatIntervalMs(long heartbeatIntervalMs) {
        this.heartbeatIntervalMs = heartbeatIntervalMs;
    }

    public long getStaleThresholdMs() {
        return staleThresholdMs;
    }

    public void setStaleThresholdMs(long staleThresholdMs) {
        this.staleThresholdMs = staleThresholdMs;
    }

    public long getDeadThresholdMs() {
        return deadThresholdMs;
    }

    public void setDeadThresholdMs(long deadThresholdMs) {
        this.deadThresholdMs = deadThresholdMs;
    }

    public long getPingIntervalMs() {
        return pingIntervalMs;
    }

    public void setPingIntervalMs(long pingIntervalMs) {
        this.pingIntervalMs = pingIntervalMs;
    }

    public long getCommandExpiryMs() {
        return commandExpiryMs;
    }

    public void setCommandExpiryMs(long commandExpiryMs) {
        this.commandExpiryMs = commandExpiryMs;
    }

    public long getLifecycleCheckIntervalMs() {
        return lifecycleCheckIntervalMs;
    }

    public void setLifecycleCheckIntervalMs(long lifecycleCheckIntervalMs) {
        this.lifecycleCheckIntervalMs = lifecycleCheckIntervalMs;
    }
}
