cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1540
Views
15
Helpful
2
Replies

Raising ALARMS from python code (or pure data)

adam.allen
Level 1
Level 1

We are in the process of implementing a service within NSO which will manage the test-and-turn-up process of devices.

In this case we expect operations folk will log directly into NCS_CLI to carry out the process, and whilst we have oper-plan's which they can look at the process takes > 30 minutes (not a great experience). Ideally we would trigger an alarm from code if the process fails.

As a starting point I managed to provide a customer alarm-type by providing an identity based of ncs-dev-manager-alarm (inspired by tailf-ncs-alarms.yang). However when setting data on a (python maagic) whilst I could see data in the database I was unable to get the alarm to appear like a proper alarm.

I started to adapt the package from 'examples.ncs/getting-started/developing-with-ncs/9-alarms', which relies on java code for sinking the alarms - however I would rather a pure-python/data-only approach to setting the data. I'm sure that this code internally is opening transactions to CDB internally - using the request-action it provides from within a FASTMAP based service caused application timeouts of my service code.

Is this possible without resorting to an ugly hack of setting some data for a kicker/subscriber to pick upon and having a java based package just to manage alarms?

Thanks,

Adam

2 Replies 2

rogaglia
Cisco Employee
Cisco Employee

The Alarm Python API is not currently available but I do know it is in the backlog.

 

do we know Is it released or still in the backlog?

 

Thanks,

Neetika