Skip to main content
Version: 1.16

Notify product

This section describes how to notify a product to recipients with the Feature manager or rs-fem service of REGARDS with AMQP interfaces.

Introduction

To notify products to one or many recipients Feature manager or rs-fem microservice relies on rs-notifier microservice.

There is two ways to notify products to rs-notifier service:

  • Normal notification : Send the notifications in the format specific to the rs-notifier service and let the service decide, based on its configuration, who to distribute the product to.
  • Direct notification : Send notifications using the format specific to the rs-notifier service and specify the recipients required.

The diagram below explains the global processing of a new Feature notification request by REGARDS system.
For a REGARDS client using message queuing, responses are sent for each change of your request status:

  • DENIED : Your request has been denied (possibly malformed request).
  • GRANTED : Your request has been granted and will be processed soon
  • ERROR : Processing of your granted request finished in error status.
  • SUCCESS : Processing of your granted request finished with success. Your SIP as been successfully ingest, AIP generated and associated files stored.

sequence

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

info

When you submit a Feature notification request you have to ensure that the provided requestId is unique. Service will respond to your request with this identifier.

AMQP API

How to

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

Exchange

Notification requests have to be published to this REGARDS RabbitMQ exchange:

ExchangeVirtual host
regards.broadcast.fr.cnes.regards.modules.feature.dto.event.in.FeatureNotificationRequestEventregards.multitenant.manager

Request content

Properties

ParameterTypeDescription
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

HeaderValueMandatory
regards.tenantThe tenant or project to request. It must be an existing Regards tenant.True
regards.request.idString of max 36 characters long. You must ensure that this id is unique.True
regards.request.dateISO 8601 date (can be in the future to delay request processing).
See How it works section for more information.
False
regards.request.ownerString of max 128 characters longTrue
info

Use the request date parameter to delay the request processing if you need to by giving a date in the future. The given date, will the execution date of our request. If a past date is provided, request will be processed as soon as possible.

Body

ParameterTypeDescriptionMandatory
urnStringProduct URN to notify.True
priorityStringHIGH, NORMAL, LOW.
See How it works section for more information.
True
recipientsset<String>List of recipients. To be provided only for direct notification mode.False
caution

If notification recipients are supplied, they must correspond to existing recipients configured on the rs-notifier service.

Example for standard notification mode

# Headers
regards.tenant=project1
regards.request.id=12345463-0f6b-4488-b58c-52af3f7e9563
regards.request.owner=owner
paylod for notification request
{
"urn": "URN:FEATURE:DATA:project1:87fdda0e-27d1-494f-a1c0-c57f2f0810f7:V1",
"priority": "NORMAL"
}

Example for direct notification mode

# Headers
regards.tenant=project1
regards.request.id=12345463-0f6b-4488-b58c-52af3f7e9563
regards.request.owner=owner
paylod for notification request
{
"urn": "URN:FEATURE:DATA:project1:87fdda0e-27d1-494f-a1c0-c57f2f0810f7:V1",
"priority": "NORMAL",
"recipients": [
"MISSION-1",
"MISSION-2"
]
}

Responses format

To learn how to subscribe to your request responses as described in the introduction diagram see Subscribe to responses.