Need synchronization between UVE update in redis and UVE notification in kafka

Bug #1557711 reported by Sundaresan Rajangam
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Juniper Openstack
Status tracked in Trunk
R3.0
Won't Fix
High
Sundaresan Rajangam
R3.1
Won't Fix
Medium
Sundaresan Rajangam
Trunk
New
Medium
Unassigned

Bug Description

Presently, there is no synchronization between UVE update in redis and publishing UVE notification in kafka bus. Therefore, there is a possibility that alarm-gen reads/processes UVE notification before the UVE is actually updated in redis.

Tags: analytics
summary: - Publish UVE notification on kafka only after UVEs are updated in Redis
+ Need synchronization between UVE update in redis and UVE notification in
+ kafka
Revision history for this message
Sundaresan Rajangam (srajanga) wrote :

Per Anish, redis is single-threaded; collector writes UVE before publishing on the kafka bus and alarm-gen's read request to redis would only be processed after the write request from collector gets processed. Therefore, there is no need for synchronization between UVE update in redis and UVE notification in kafka at the collector side.

Revision history for this message
Sundaresan Rajangam (srajanga) wrote :

Redis documentation:

*In what order clients are served*

The order is determined by a combination of the client socket file descriptor number and order in which the kernel reports events, so the order is to be considered as unspecified.
However Redis does the following two things when serving clients:
It only performs a single read() system call every time there is something new to read from the client socket, in order to ensure that if we have multiple clients connected, and a few are very demanding clients sending queries at an high rate, other clients are not penalized and will not experience a bad latency figure.
However once new data is read from a client, all the queries contained in the current buffers are processed sequentially. This improves locality and does not need iterating a second time to see if there are clients that need some processing time.

Per the redis documentation, there is no guarantee that the events would be processed in the same order they are received across clients. Therefore, we would need synchronization between UVE update in redis and UVE notify in kafka.

Revision history for this message
Raj Reddy (rajreddy) wrote :

theoretically the above is possible, but we have not seen this happen, we will not target this for R3.0

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.