I am working on a ticketing model framework, where we receive requests for user account creation in an SAP system. The request is an agent which is assigned to one resource from the resource pool. In other words, one request is handled by a specific resource from the resource pool only.
For e.g. if I am a resource from the resource pool I will be fully responsible for a request assigned to me until it goes out from the sink.
Some account creation requests requires special approval. So they wait in a queue for a specific wait time and then goes back in for user creation.
Here I have two questions to solve for-
- How do the request wait for a variable time and come out of the queue when wait time is over. For e.g. request 1 comes in to wait for 5 hours, after that request 2 comes in to wait for 1 hour how does the request 2 goes out from the queue first?
- Once a request gets out of the queue - it goes back to userCreation block. Here, how do we make sure that the same resource from the resource pool handles this request who has handled it before (when it came in the userCreation block for the first time)?