Alert Notification Accelerator in Oracle Integration Cloud

Alert Notification Accelerator in Oracle Integration Cloud

When you log in to Oracle Integration, in the home page you see Recipe/Accelerator

No alt text provided for this image

Today we will look at a hidden gem, an accelerator Alert Notification. Now before we delve into this, it is important to understand the difference between an Accelerator and a Recipe

Accelerator: These are end to end use case in the form of an integration that as a developer you can use but you are not allowed to modify it. They are managed and maintained by Oracle.

Recipes: ?These are also integration templates based on a particular use case but you as a developer has control to modify and change it. There are some 135 plus recipes available in Oracle Integration .If it meets your complete requirement you can just configure it and use it. On the other hand say it meets 75% of your requirement, you can modify it as well per your needs. I also encourage developers to explore recipes as they are a great learning resource.

Alert Notification

A common requirement is to notify support and operations team in case of an error. Support might like to receive an email or Jira ticket or maybe a slack message. Keeping this common requirement in view. Oracle Integration has provided this Alert Notification accelerator.

The official documentation can be found here.

https://docs.oracle.com/en/cloud/paas/application-integration/int-get-started/alert-notification.html

Alert Notification can be configured to send notification via Email, PagerDuty, JIRA or you may create a custom integration and call it, where this custom integration may send message to slack channel using OIC Slack Adapter.

Today we will look at how to install Alert Notification Accelerator, configure it and than use it in one of the integration.

From OIC home page search “Alert Notifications” in View All Recipes/Accelerator

No alt text provided for this image

Next click on the + sign to install this accelerator in your environment

No alt text provided for this image


Once the accelerator is installed you can click on the configure button to configure it.

No alt text provided for this image

It has two connections, make sure they are configured. These are Rest Connections for Trigger and Invoke.

No alt text provided for this image

For Invoke as it will be in draft state, you shall provide your OIC 3 URL in Connection URL, in case it is empty (for example: https://<oic>.integration.eu-frankfurt-1.ocp.oraclecloud.com)

No alt text provided for this image

Next we have three lookups

No alt text provided for this image

The documentation explains in detail, what parameter and values need to be setup in these lookups. I will not go in the detail you can refer the documentation. I will quickly show what I have set to configure it for sending an email from one of the integrations. One of the advantages of lookups is, when you modify lookups, no need to re-activate the integrations.

First lookup is ORCL-T-GENRIC_ENS_NOTIFICATION_DATA, where we provide the configuration parameters for Email, Pagerduty, Custom integration etc. In my case, I will be sending myself an email so in param1 as per documentation I have provided the email address where I want the notification to be sent. If we do not wish to set other notification types, we can leave them blank.

No alt text provided for this image

Second lookup is ORCL-T-GENRIC_ENS_NOTIFICATION_SELECTOR, where we provide the list of integrations that will call this accelerator and corresponding notification type. IntegrationCode_Version is a concatenation of the invoking integration code and its version separated by a colon : sign. e.g. INT_CODE:VERSION(01.00.0000)

No alt text provided for this image

Final lookup ORCL-T-GENRIC_ENS_NOTIFICATION_SELECTOR_MSGID, here we can configure different Message_Id and Message_Subject for our notification type. These are custom message ids and you can provide any values and later its utilized by the invoking integration.

No alt text provided for this image

Next we need to activate this integration, if we browse this accelerator. You will find a very complex integration as it takes care of all different scenarios. Since it is an accelerator, you will not find an option to edit it. It is available in view only mode.

No alt text provided for this image

Next activate this integration clicking on the activate button. Once activated, it can be used from other integrations.

No alt text provided for this image

I will be using the accelerator from my integration HQ_Employee_v2, it inserts some employee data into the Oracle ATP database.

No alt text provided for this image

I can call the Alert Notification like any other integration. As it is for error alerts, I will like to place it in a fault handler. It can be the fault handler of a Scope or Global Fault Handler. In this example I have chosen to set it in Global Fault Handler. Click the View Global Fault Handler link at the top right.

No alt text provided for this image

Next from the actions, drag the Integration Action and drop it after Global Fault.

No alt text provided for this image

It will open the Integration Adapter wizard, first up in basic info provide details on what you want to call it.

No alt text provided for this image

Next in Select Integration, select the Oracle Alerting Service. Please note, you will only see it here if you have activated Alert Service integration already.

No alt text provided for this image

Next in Select Operations, there is only one operation available i.e. Post. Select that. Than view the summary and click Done.

No alt text provided for this image

Your Global Fault will look like this.

No alt text provided for this image

Now the final step we need to perform the mapping, so edit the mapper

No alt text provided for this image

The mapping is quite straight forward. For OIC 3 you should use the Instance Id String, this you can get from <Integration Metadata>-<Runtime Details>. For Message Id provide value as per your settings in the lookup ORCL-T-GENRIC_ENS_NOTIFICATION_SELECTOR_MSGID. Message Details, can be any custom message like sending some payload information.

Once your integration is complete, activate and test it. As I am producing error for it to go into Fault handler, you see some error message here.

No alt text provided for this image

And here is the email sent by the alert notification service to my mailbox.

No alt text provided for this image

Conclusion

Accelerators and Recipes are great way to learn Oracle Integration. You can utilize it to enhance your projects. Here in this blog we have looked at how to use the Alert Notification accelerator. One time configuration and then you can easily call it as child integration to send notifications. We have configured it for Email but similarly it can be done for other available options.

When working in integration projects, while the focus is on success path, it is paramount to consider error handling scenarios and think about support teams that will have to manage and maintain the integrations. Consider what information they require, what is the best way to alert them and how to build the framework to help support teams fix the issues. If this topic interests you, have a look at these other blogs where I provide some tips in relations to Oracle Integration Cloud.

Error Handling in Oracle Integration Cloud

Tracking Table & Saving Payload As Is in Oracle Integration Cloud

I have used?Oracle Integration 3?here for my screenshots. If you are currently using Oracle Integration 2, you can follow the exact same steps to achieve the goal.

Hamid Mukhtar

Director @ ATG Asia Pacific | Engineering and Technology

2 年

Harris Qureshi you have the art of making things so simple and easy to understand. Well done!

要查看或添加评论,请登录

Harris Qureshi的更多文章

社区洞察

其他会员也浏览了