sourabh_sourabh | 9a76aa3 | 2023-07-25 10:58:52 +0100 | [diff] [blame] | 1 | .. This work is licensed under a Creative Commons Attribution 4.0 International License. |
| 2 | .. http://creativecommons.org/licenses/by/4.0 |
| 3 | .. Copyright (C) 2023 Nordix Foundation |
| 4 | |
| 5 | .. DO NOT CHANGE THIS LABEL FOR RELEASE NOTES - EVEN THOUGH IT GIVES A WARNING |
| 6 | .. _dataOperationEvents: |
| 7 | |
| 8 | CPS-NCMP Data Operations Events |
| 9 | ############################### |
| 10 | |
| 11 | These events are based on the cloud events standard which is a specification for describing event data in common formats to provide interoperability across services, platforms and systems. |
| 12 | |
| 13 | Please refer to the `cloud events <https://cloudevents.io/>`_ for more details. |
| 14 | |
| 15 | Data operation response events |
| 16 | ****************************** |
| 17 | |
| 18 | :download:`Data operation event schema <schemas/data-operation-event-schema-1.0.0.json>` |
| 19 | |
| 20 | Event headers example |
| 21 | ^^^^^^^^^^^^^^^^^^^^^ |
| 22 | |
| 23 | .. code-block:: json |
| 24 | |
| 25 | { |
| 26 | "specversion": "1.0", |
| 27 | "id": "77b8f114-4562-4069-8234-6d059ff742ac", |
| 28 | "type": "org.onap.cps.ncmp.events.async1_0_0.DataOperationEvent", |
| 29 | "source": "DMI", |
| 30 | "dataschema": "urn:cps:org.onap.cps.ncmp.events.async1_0_0.DataOperationEvent:1.0.0", |
| 31 | "time": "2020-12-01T00:00:00.000+0000", |
| 32 | "content-type": "application/json", |
| 33 | "data": "{some-key:some-value}", |
| 34 | "correlationid": "6ea5cb30ecfd4a938de36fdc07a5008f", |
| 35 | "destination": "client-topic" |
| 36 | } |
| 37 | |
| 38 | Data operation event headers |
| 39 | ============================ |
| 40 | |
| 41 | +----------------+-----------------+------------------------------------------------------------------------+ |
| 42 | | Field name | Mandatory | Description | |
| 43 | +================+=================+========================================================================+ |
| 44 | | specversion | Yes | default : 1.0 | |
| 45 | +----------------+-----------------+------------------------------------------------------------------------+ |
| 46 | | id | Yes | UUID | |
| 47 | +----------------+-----------------+------------------------------------------------------------------------+ |
| 48 | | type | Yes | org.onap.cps.ncmp.events.async1_0_0.DataOperationEvent | |
| 49 | +----------------+-----------------+------------------------------------------------------------------------+ |
| 50 | | source | Yes | NCMP / DMI | |
| 51 | +----------------+-----------------+------------------------------------------------------------------------+ |
| 52 | | dataschema | No | `urn:cps:org.onap.cps.ncmp.events.async1_0_0.DataOperationEvent:1.0.0` | |
| 53 | +----------------+-----------------+------------------------------------------------------------------------+ |
| 54 | | time | No | ISO_TIMESTAMP_PATTERN = "yyyy-MM-dd'T'HH:mm:ss.SSSZ" | |
| 55 | +----------------+-----------------+------------------------------------------------------------------------+ |
| 56 | | content-type | No | default : application/json | |
| 57 | +----------------+-----------------+------------------------------------------------------------------------+ |
| 58 | | data | Yes | actual event/payload now would be under "data" field. | |
| 59 | +----------------+-----------------+------------------------------------------------------------------------+ |
| 60 | | correlationid | Yes | request id | |
| 61 | +----------------+-----------------+------------------------------------------------------------------------+ |
| 62 | | destination | Yes | client topic | |
| 63 | +----------------+-----------------+------------------------------------------------------------------------+ |
| 64 | |