For now, update of TPR with new agent data is performed in the handler that processes the agent's POST request to the server. This way, server's response to the agent's POST request is delayed until the answer from k8s API is received. This can cause issues with server's responsiveness when the number of agents is big or when server experiences the issues with k8s API availability. Also, queue will eliminate such issues as possible conflicts between TPR updates with data from different agents.
So, we need to introduce a message queue to process agent data updates in TPR, i.e. k8s API POST requests.
For now, update of TPR with new agent data is performed in the handler that processes the agent's POST request to the server. This way, server's response to the agent's POST request is delayed until the answer from k8s API is received. This can cause issues with server's responsiveness when the number of agents is big or when server experiences the issues with k8s API availability. Also, queue will eliminate such issues as possible conflicts between TPR updates with data from different agents.
So, we need to introduce a message queue to process agent data updates in TPR, i.e. k8s API POST requests.