Event Structure and Definition

The following shows an example of the event that creates the Account class in the BankingModelSchema.

{
   "eventId": "21fe3632-ff91-ef11-9f3c-005056a9d6b5.8445.1.1",
   "schemaId": "8445.v1",
   "eventType": "JadeSoftware.ObjectStorage.ObjectCreated",
   "eventTime": "2024-10-24T11:58:49.872Z",
   "eventTimezoneOffset": "+13:00",
   "eventSequenceNumber": "5736406",
   "contentType": "application/json",
   "transactionId": 570,
   "objectType": "BankModelSchema::Account",
   "object": {
      "Jade.oid": "8445.1",
      "Jade.instanceId": 1,
      "Jade.edition": 1,
      "active": false,
      "date": "2013-01-01",
      "district_id": 55,
      "frequency": "Monthly Issuance",
      "id": "A00000576",
      "myBank": {
         "Jade.objectType": "BankModelSchema::Bank",
         "Jade.instanceId": 1,
         "Jade.oid": "8443.1"
      },
      "myDistrict": {
         "Jade.objectType": "BankModelSchema::District",
         "Jade.instanceId": 55,
         "Jade.oid": "8448.55"
      }
   }
}

Event Properties

The following table lists the required event properties.

Property Type Description
eventId String

Unique identifier for the event. If a duplicate event is re‑sent (for example, due to a network error), it could have the same identifier. Consumers may assume that events with an identical source and eventId property are duplicates.

The eventId property format is <database‑unique‑ID>-<object‑OID>-<object‑edition>; for example, "560df1f8‑3556‑ef11-8a20-005056a99710.2051.4501.1".

schemaId String

The schema identifier associated with the event.

The schemaId value is a string that has the following formats.

  • Azure: a GUID string

  • Kafka(Confluent): An integer starting at 1, stored as a string

  • None: <class-number>.v<class-version-number>

eventType String

Type of event that occurred (that is, ObjectCreated, ObjectUpdated, ObjectDeleted, or TransactionCommitted); for example, "JadeSoftware.ObjectStorage.ObjectCreated".

eventTime String

Timestamp of when the state change was audited in the database journal; for example, "2024-08-12T02:11:02.873Z".

eventTimezoneOffset String Timezone offset for the event time; for example, "+12:00".
eventSequenceNumber Integer

Monotonically increasing sequence number that can be for ordering events. These are unique for the source database identified by the <database‑unique‑ID> part of the eventId property; for example, "5512494".

contentType String

Content type of the event payload. The value is always "application/json" for events serialised to a JSON format; that is, "application/json".

transactionId Integer

The database unique transaction identifier associated with the event. This is the identifier of the database transaction that performed the create, update, or delete operation.

An example of the transactionId property is 756.

objectType String

Type of object contained in the embedded object property (for example, BankModelSchema::Account, BankModelSchema::District).

The objectType property format is <schema‑name>::<class‑name>; for example, "BankModelSchema::Account".

object Object

Embedded object representing the event payload.

Object Properties

This section covers the properties of the object property.

Jade Object Properties

The following table lists the required Jade properties of the object property.

Property Type Description
Jade.edition Integer

Update edition for the object. Starts off as 1 when an object is created and is incremented each time it is updated, once for each transaction; for example, 1.

Jade.instanceId Integer

Instance identifier for the object; for example, 4501.

Jade.oid String

Unique identifier for the object within the database; for example, "2051.4501".

User‑Defined Object Properties

The Jade properties are followed by the static properties defined in the user class. For reference, the following table lists examples of user‑defined object property descriptions.

Property Type Description
active Boolean

Indicates whether the object is currently active.

date String

Date associated with the object.

district_id Integer

Identifier for the district associated with the object.

frequency String

Frequency of the object issuance.

id String

Unique identifier for the object.

incarnation Integer

Incarnation identifier for the object.

myBank ObjectReference

Reference to the bank associated with the object.

myDistrict ObjectReference

Reference to the district associated with the object.

Object Reference Properties

The following table lists the required object reference properties.

Property Type Description
Jade.instanceId Integer

Instance identifier for the object; for example, 132.

Jade.objectType Integer

Type of object being referenced. The Jade.objectType property format is <schema-name>::<class-name>; for example, "BankModelSchema::Account".

Jade.oid String

Unique identifier for the object within the database; for example, "2054.132".