Record Class PendingChange

java.lang.Object
java.lang.Record
com.eqixiac.equinix.mcp.server.broker.PendingChange
Record Components:
token - the single-use confirm token handed back by fabric_propose_change
changeType - the kind of create this proposal performs
canonicalSpec - the canonical-form spec JSON (see SpecHash)
specSha256 - the SHA-256 (hex) of canonicalSpec: the proposal's identity
requestSha256 - the SHA-256 (hex) of the compiled request (change type plus the canonical JSON body the create sends). The confirm phase recompiles the stored spec and executes only when the result hashes to this value
compiledAt - the reference instant the request was compiled at (for example the base of a service token's expiry); the confirm phase recompiles at the same instant
mintedAt - when the dry run passed and the token was minted; the confirm prompt reports the proposal's age from it
expiresAt - when the proposal stops being confirmable
priceSummary - the one-line price context reported by the propose phase, repeated verbatim in the confirm prompt so the approver sees the figure the proposal showed; null when the proposal was minted without one

public record PendingChange(String token, ChangeType changeType, String canonicalSpec, String specSha256, String requestSha256, Instant compiledAt, Instant mintedAt, Instant expiresAt, String priceSummary) extends Record
One dry-run-validated proposal awaiting confirmation: the single-use confirm token, the change type, the exact canonicalized spec the dry run validated (the confirm phase recompiles this stored spec - never a re-supplied one), the SHA-256 of the compiled request the token is bound to, the mint and expiry instants, and the price context the proposal reported.

The token is a lookup key into one server process's ProposalStore. It is not an activation key of any cloud provider or of the Connection Coordinator specification, carries no data, and is meaningless outside the process that minted it.

  • Constructor Details

    • PendingChange

      public PendingChange(String token, ChangeType changeType, String canonicalSpec, String specSha256, String requestSha256, Instant compiledAt, Instant mintedAt, Instant expiresAt, String priceSummary)
      Creates an instance of a PendingChange record class.
      Parameters:
      token - the value for the token record component
      changeType - the value for the changeType record component
      canonicalSpec - the value for the canonicalSpec record component
      specSha256 - the value for the specSha256 record component
      requestSha256 - the value for the requestSha256 record component
      compiledAt - the value for the compiledAt record component
      mintedAt - the value for the mintedAt record component
      expiresAt - the value for the expiresAt record component
      priceSummary - the value for the priceSummary record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • token

      public String token()
      Returns the value of the token record component.
      Returns:
      the value of the token record component
    • changeType

      public ChangeType changeType()
      Returns the value of the changeType record component.
      Returns:
      the value of the changeType record component
    • canonicalSpec

      public String canonicalSpec()
      Returns the value of the canonicalSpec record component.
      Returns:
      the value of the canonicalSpec record component
    • specSha256

      public String specSha256()
      Returns the value of the specSha256 record component.
      Returns:
      the value of the specSha256 record component
    • requestSha256

      public String requestSha256()
      Returns the value of the requestSha256 record component.
      Returns:
      the value of the requestSha256 record component
    • compiledAt

      public Instant compiledAt()
      Returns the value of the compiledAt record component.
      Returns:
      the value of the compiledAt record component
    • mintedAt

      public Instant mintedAt()
      Returns the value of the mintedAt record component.
      Returns:
      the value of the mintedAt record component
    • expiresAt

      public Instant expiresAt()
      Returns the value of the expiresAt record component.
      Returns:
      the value of the expiresAt record component
    • priceSummary

      public String priceSummary()
      Returns the value of the priceSummary record component.
      Returns:
      the value of the priceSummary record component