Class AgentRuleProposalStore

java.lang.Object
com.xebialabs.xlrelease.agentrules.AgentRuleProposalStore

public class AgentRuleProposalStore extends Object
Pending and recently decided propose-mode actions, newest first. In-memory and bounded, like the run store: a proposal is an operational decision point, not audit truth — the decision's effect (the action comment, the retry) is what persists. A pending proposal that outlives PENDING_TTL_MILLIS reads as expired and can no longer be approved: approving a stale remediation against a release that has long moved on is worse than asking again.
  • Constructor Details

    • AgentRuleProposalStore

      public AgentRuleProposalStore()
  • Method Details

    • add

      public void add(AgentRuleProposal proposal)
    • list

      public List<AgentRuleProposal> list(int limit)
      Newest-first window; pending entries past their TTL are surfaced as expired.
    • decide

      public Optional<AgentRuleProposal> decide(String proposalId, String newStatus, String user)
      Atomically decides a pending proposal. Empty when the proposal is unknown, already decided, or expired — the caller reports that instead of acting twice.