Class EffectKeys

java.lang.Object
com.kingsrook.qqq.backend.core.jobs.effects.EffectKeys

public final class EffectKeys extends Object
The deterministic idempotency key of an effect, and the forms targets need (spec section 2.13): jobId:chunkSeq:rowKey:effectName. A rerun chunk derives the same keys, so the outbox, the provider and the target all dedupe.
  • Method Details

    • key

      public static String key(Integer jobId, Integer chunkSeq, String rowKey, String effectName)
      jobId:chunkSeq:rowKey:effectName.
    • digest

      public static String digest(String key)
      A short, URL- and filename-safe digest of a key (SHA-256, hex, 32 chars): for object names, header values and Message-IDs whatever the row key holds.
    • idempotencyKeyHeader

      public static String idempotencyKeyHeader(String key)
      The provider Idempotency-Key header value for an effect.
    • objectName

      public static String objectName(String prefix, String key, String extension)
      A deterministic object name under a prefix: a repeated PUT overwrites the same object instead of creating another.
    • messageId

      public static String messageId(String key, String domain)
      A fixed RFC 5322 Message-ID for an email effect, so a resend carries the same id and receiving systems (and reconcile lookups) recognize it.