Skip to main content
Version: 2.0

Subscribe to products submission requests events (SIP)

Introduction

This section describes how to subscribe to events sent by rs-ingest microservice about submitted products requests as described in Submit Product SIP guide.

After your SIP Submission request is sent you will receive :

  1. A GRANTED or a DENIED response to inform you if your request has been accepted or not.
  2. A SUCCESS or an ERROR response to inform you that your request has been processed.

Requests and responses are linked with a correlation identifier : requestId that is provided into submission requests and added in service responses.

Regards AMQP api

The Regards AMQP API concept describe how AMQP interfaces must be handled to submit events or to subscribe to events.

Exchange

SIP submission responses from REGARDS are sent to exchange :

ExchangeVirtual host
regards.broadcast.fr.cnes.regards.modules.ingest.dto.request.event.IngestRequestEventregards.multitenant.manager

Queue

Every consumer of this exchange must create its own queue bound to this exchange.

Message format

Properties

ParameterTypeDescription
app_idStringStandard RabbitMQ property to track message origin.
priorityIntegerStandard RabbitMQ property to sort messages by priority order.
content_encodingStringStandard RabbitMQ property for the encoding type of the message
content_typeStringStandard RabbitMQ property for the MIME Type of the message sent
delivery_modeIntegerStandard RabbitMQ property for the delivery mode (persistent or not)

Headers

ParameterTypeDescription
regards.tenantStringTenant name depends on REGARDS instance project configuration.
regards.typeStringType of content of the message
Example of the properties and headers of an Ingest request event message
{
"app_id": "{ID of app}",
"priority": 1,
"delivery_mode": 2,
"content_encoding": "UTF-8",
"content_type": "application/json",
"headers": [
{
"regards.tenant": "REGARDS",
"regards.type": "fr.cnes.regards.modules.ingest.dto.request.event.DisseminationAckEvent"
}
]
}

Body

{
"requestId": "xxxxxxxxxxxx",
"providerId": "yyyyyyyyy",
"sipId": "URN:SIP:DATA:xxxxxxxxxxxx:V1",
"state": "",
"errors": []
}
ParameterTypeDescription
requestIdStringRequest unique identifier. This identifier is the same as the provided one in the SIP submission request
providerIdStringSIP providerId. This parameter is the same as the provided one in the SIP submission request
sipIdStringUnique SIP identifier generated by rs-ingest service with URN format
stateStringState of the SIP submission request
errorsList<String\>Optional error messages to inform about request process errors