Aviso is a system developed at ECMWF with the aim of:
- Notifying for data availability
- Real-Time Model Output Data
- Product dissemination via ECPDS
- Meant for automated systems
- Based on an Event system supporting a mechanism When <this> … Do <that> …
It allows users to:
- Define which events to be notified of.
- Define the triggers to be executed once a notification is received.
- Dispatch notifications to the notification server.
...
- Install AVISO following instructions on: https://pyaviso.readthedocs.io/en/latest/guide/getting_started.html#installing
- Configure MARS credentials following instructions on Access MARS
Create a configuration file in the default location ~/.aviso/config.yaml
Code Block language yml username_file: ~/.marsrc/mars.email key_file: ~/.marsrc/mars.token notification_engine: type: etcd_rest host: aviso.ecmwf.int port: 443 https: true configuration_engine: type: etcd_rest host: aviso.ecmwf.int port: 443 https: true schema_parser: ecmwf remote_schema: True auth_type: ecmwf
- Create ~/.marsrc/mars.email and ~/.marsrc/mars.token files. mars.email file should contain “email” listed here: https://api.ecmwf.int/v1/key and mars.token file should contain “key” shown on the same page.
- Crate a your listener configuration file(s) with following content:
- Example for dissemination:
Note theCode Block language yml title listener_diss.yaml listeners: - event: dissemination request: destination: <user_destination> class: od expver: 1 domain: g stream: enfo step: [1,2,3] triggers: - type: echo
dissemination
event listener.request
describes for which dissemination event users want to execute the triggers. It is made of a set of fields. Users have to specify only the fields they wants to use as filters.destination
is a mandatory field and it is associated to one or more destinations which are linked to the user's ECMWF account. Only the notifications complying with all the fields defined will execute the trigger. The trigger in this example isecho
. This will simply print out the notification to the console output. - Example for MARS:
Note, in the MARS event listener, destination field is not present.Code Block language yml title listener_mars.yaml listeners: - event: mars request: class: od expver: 1 domain: g stream: enfo step: [1,2,3] triggers: - type: echo
- Example for dissemination:
- If AVISO is installed in conda or Python virtual environment, activate the environment first:
- Python virtual environment: "myenv"
Code Block language bash source {PATH_TO_MY_ENV}/myenv/bin/activate
- Conda:
Code Block language bash conda activate
- Python virtual environment: "myenv"
- Launch the AVISO application to listen ECMWF defined in your configuration file:
Code Block language bash aviso listen listener_diss.yaml #or aviso listen listener_mars.yaml
...