Campus Switching and Routing

Reply
Aruba Employee

Get familiar with ArubaOS-CX real-time notifications (~Next-gen SNMP trap)

The WebSocket protocol is the considered to be the best protocol in the industry to use for real-time notifications. ArubaOS-CX offers this great capability. Please have a look at the API documentation p44:

https://support.hpe.com/hpsc/doc/public/display?docId=a00044804en_us

 

"The ArubaOS-CX real-time notifications subsystem enables external clients to connect to the switch through WebSocket secure and subscribe to receive real-time notifications about the switch resources and the configuration changes, state changes, and statistical information that interest them..."

 

In this documenation, there are two scrips provided for testing: one in javascript, one in Python. Here is attached the Python one (to avoid copy/paste issue). 

 

As an example,  this script could be used to provide in real time the interface name that is transitioning state:

python script_name.py "wss://<ip_address>:443/rest/v1/notification" "/rest/v1/system/interfaces?attributes=link_state%2Cname&depth=1"

 

Event message subscription is very efficient to trigger automation flow. Due to the TCP nature of the communication, you are less exposed in loosing an event, and thank to the fine granularity of the subscription, only interesting selected events are received.

 

Get empowered with this feature in your automation work.

 

 

 

 

Search Airheads
cancel
Showing results for 
Search instead for 
Did you mean: