Class EsbOutboxTable
java.lang.Object
com.kingsrook.qqq.esb.outbox.EsbOutboxTable
The ESB outbox table: one row per event per destination, written in the same
backend transaction as the record write that made it, and published by
EsbOutboxRelay.
Columns are snake_case; there are no foreign keys. The application adds the
table to its instance (defineTable) and creates it in its migrations (the
PostgreSQL DDL is in docs/esb/index.adoc).
A row is PENDING until it is sent (SENT, kept retentionDays, then purged),
or until it fails maxAttempts times while the broker is connected (DEAD,
kept until someone deletes it, or sets it back to PENDING to retry it).
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final String -
Method Summary
Modifier and TypeMethodDescriptionstatic QTableMetaDatadefineTable(String tableName, String backendName) The outbox table, on the given backend.
-
Field Details
-
FIELD_ID
- See Also:
-
FIELD_UUID
- See Also:
-
FIELD_DESTINATION_NAME
- See Also:
-
FIELD_EVENT_TYPE
- See Also:
-
FIELD_EVENT_JSON
- See Also:
-
FIELD_STATUS
- See Also:
-
FIELD_ATTEMPTS
- See Also:
-
FIELD_NEXT_ATTEMPT_AT
- See Also:
-
FIELD_LEASE_OWNER
- See Also:
-
FIELD_LEASE_EXPIRES_AT
- See Also:
-
FIELD_LAST_ERROR
- See Also:
-
FIELD_CREATE_DATE
- See Also:
-
FIELD_SENT_AT
- See Also:
-
STATUS_PENDING
- See Also:
-
STATUS_SENT
- See Also:
-
STATUS_DEAD
- See Also:
-
-
Method Details
-
defineTable
The outbox table, on the given backend. Put it on the same backend as the tables that publish, so their events are written in the same transaction as their records.
-