How to write all the alerts from Ens.Alert to a file instead of sending to an email?

Primary tabs

Replies

Alerts (Ens.AlertRequest) are treated like any other message in Ensemble -- you can transform them to different message types and route them to an outbound business operation.

Have a look at the docs regarding alerts here:
http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=...

And the docs regarding file adapters here:
http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=...

One approach you can consider is to transform the Ens.AlertRequest into an Ens.StreamContainer and then use an EnsLib.File.PassthroughOperation to write it out to a file:
http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=...

If you need to write the alert to a file in a structured format, you can consider creating a RecordMap for your output format, transform the Ens.AlertRequest into your custom RecordMap object, and then use EnsLib.RecordMap.Operation.FileOperation to write it out to the file:
http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=...

Thanks Marc. Will look into the links you have provided.

Is there any possibility we can see an example of this? I read the alert documentation and have set up my production to route alert request messages to a file BO from Ens.Alert and nothing is working. All of the alert messages have a status of "queued".