×

System and method for transforming a queue from non-blocking to blocking

  • US 10,095,562 B2
  • Filed: 02/28/2013
  • Issued: 10/09/2018
  • Est. Priority Date: 02/28/2013
  • Status: Active Grant
First Claim
Patent Images

1. A method for transforming a queue from non-blocking to blocking, comprising:

  • instantiating a callable object, the callable object having at least one function that can be called;

    providing a non-blocking queue into which requests are placed for processing;

    providing a function of the non-blocking queue that accepts a first parameter and a second parameter;

    associating a thread pool with the non-blocking queue, wherein the thread pool contains one or more threads that process the requests placed in the non-blocking queue, and wherein the thread pool is accessible from the non-blocking queue;

    calling the function of the non-blocking queue from a request manager;

    including, by the request manager, a caller request as the first parameter of the function of the non-blocking queue, and the instantiated callable object as the second parameter of the non-blocking queue;

    determining, by the function of the non-blocking queue, that the non-blocking queue is available to process the caller request;

    calling, by the function of the non-blocking queue, the at least one function of the callable object;

    polling, by the at least one function of the callable object, a thread from the thread pool;

    returning, by the at least one function of the callable object, the polled thread to the function of the non-blocking queue;

    returning, by the function of the non-blocking queue, the polled thread to the request manager; and

    using the polled thread within the thread pool, to process the caller request.

View all claims
  • 1 Assignment
Timeline View
Assignment View
    ×
    ×