diff --git a/nomad/structs/structs.go b/nomad/structs/structs.go index 8a76e83e0..e500192cd 100644 --- a/nomad/structs/structs.go +++ b/nomad/structs/structs.go @@ -9954,6 +9954,11 @@ func (c *Constraint) Validate() error { return mErr.ErrorOrNil() } +// DiffID fulfills the DiffableWithID interface. +func (c *Constraint) DiffID() string { + return c.String() +} + type Constraints []*Constraint // Equal compares Constraints as a set @@ -10070,6 +10075,11 @@ func (a *Affinity) Validate() error { return mErr.ErrorOrNil() } +// DiffID fulfills the DiffableWithID interface. +func (a *Affinity) DiffID() string { + return a.String() +} + // Spread is used to specify desired distribution of allocations according to weight type Spread struct { // Attribute is the node attribute used as the spread criteria