Record Class EngineManifest.SinkRegistration

java.lang.Object
java.lang.Record
com.inductiveautomation.ignition.gateway.storeforward.engine.EngineManifest.SinkRegistration
Record Components:
storageKey - the storage key identifying the sink
engineBound - true if this sink is bound to the engine's lifecycle
Enclosing class:
EngineManifest

public static record EngineManifest.SinkRegistration(StorageKey storageKey, boolean engineBound) extends Record
Represents a sink registration within the manifest, combining the storage key with the engine-bound status.

Engine-bound sinks (like DatasourceQuerySink) are inherently tied to their engine. When the engine is renamed, both the engineId and sinkId will be updated, and the sink's data directory will be renamed accordingly.

Independent sinks (like SQL Historian profiles) have their own identity separate from the engine. When the engine is renamed, only the engineId is updated; the sinkId and data directory remain unchanged.

  • Constructor Details

    • SinkRegistration

      public SinkRegistration(StorageKey storageKey, boolean engineBound)
      Creates an instance of a SinkRegistration record class.
      Parameters:
      storageKey - the value for the storageKey record component
      engineBound - the value for the engineBound record component
  • Method Details

    • from

      public static EngineManifest.SinkRegistration from(StorageKey storageKey)
      Creates a SinkRegistration with automatic engine-bound detection based on the storage key pattern.
      Parameters:
      storageKey - the storage key
      Returns:
      a new SinkRegistration with engineBound inferred from storageKey
    • withRenamedEngine

      public EngineManifest.SinkRegistration withRenamedEngine(String newEngineId)
      Creates a new SinkRegistration with the storage key updated for engine rename.
      Parameters:
      newEngineId - the new engine ID
      Returns:
      a new SinkRegistration with updated storage key
    • withRenamedSink

      public EngineManifest.SinkRegistration withRenamedSink(String oldSinkId, String newSinkId)
      Creates a new SinkRegistration with the sink ID updated.
      Parameters:
      oldSinkId - the old sink ID to match
      newSinkId - the new sink ID
      Returns:
      a new SinkRegistration with updated sink ID if it matched, otherwise this
    • 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. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      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.
    • storageKey

      public StorageKey storageKey()
      Returns the value of the storageKey record component.
      Returns:
      the value of the storageKey record component
    • engineBound

      public boolean engineBound()
      Returns the value of the engineBound record component.
      Returns:
      the value of the engineBound record component