Communication and integration protocol
This documentation defines the payload model for publishing events to streaming systems such as RabbitMQ and Kafka, and details the adaptations required for legacy applications, highlighting the required and optional fields. For external applications, it is essential that the payload follows the same format and includes the specified information, ensuring compatibility and efficient monitoring. While native integration is optional, it is recommended to maximize the benefits of Devprime across the application ecosystem.
Event Default Payload Structure
|
|
Description of Fields
| Field | Type | Description | Obligation |
|---|---|---|---|
| Headers | object |
Contains additional headers, can be used to carry specific metadata. | Optional |
| Id | string (GUID) |
Unique Guid identifier of the event generated by the legacy application when creating a new event. | Required |
| CorrelationId | string (GUID) |
Guid identifier used to correlate events and must be generated by the legacy application. | Required |
| TraceId | string (GUID) |
Tracking Guid identifier, useful for distributed tracing. | Required |
| AppId | string (GUID) |
Fixed Guid identifier of the legacy application that generates the event. | Required |
| AppName | string |
Name of the application that is publishing the event. Example: “Integrator 1.0”. | Required |
| Version | integer |
Event version. Usually incremented in case of changes in the payload format. | Required |
| Name | string |
Event name. Example: “OrderCreated”. | Required |
| CreateDate | string (DateTime) |
Date and time of creation of the event, in ISO 8601 format. | Required |
| Payload | object (JSON) |
JSON file containing the event data. | Required |
Examples of Use
Full Payload (Recommended)
This example includes all the fields required for complete traceability and proper integration with the observability system:
|
|
Reduced Payload (Optional)
This example omits some fields for a simpler implementation for cases where traceability is not required:
|
|
Final Thoughts
Implementing the payload pattern described above will allow legacy and external applications to interact effectively with the Devprime platform, ensuring that events are properly monitored and tracked throughout the homologation and production process. It is strongly recommended that developers follow the guidance to ensure compatibility and integration efficiency.
To learn more:
Last modified November 20, 2024 (61099f59)