Method and system for migrating connections between receive-any and receive-direct threads
First Claim
1. A method of migrating a connection to a server between a receive-direct thread and a listening thread configured to listen for new connections, comprising:
- calling a function from the receive-direct thread, the function receiving data on the connection and timing out when the connection had no activity for a period of time;
returning to the receive-direct thread from the function, the function providing information indicative of whether data was received or the connection had no activity; and
migrating the connection to the listening thread when the information indicates the connection had no activity for a period of time.
2 Assignments
0 Petitions
Accused Products
Abstract
A method and mechanism for efficiently handling connections in a computer system between client sockets and data sockets of a server. The server includes a receive-any thread having a socket mask associated therewith to listen for new connection requests and for activity on data sockets handled thereby. The server further includes receive-direct threads associated with at least some of the data sockets for handling data communication. When a receive-direct connection has no activity for a period of time, the connection is migrated to a receive-any connection. When a receive-any connection becomes active, the connection is migrated to a receive-direct connection if a receive-direct thread is available.
87 Citations
50 Claims
-
1. A method of migrating a connection to a server between a receive-direct thread and a listening thread configured to listen for new connections, comprising:
-
calling a function from the receive-direct thread, the function receiving data on the connection and timing out when the connection had no activity for a period of time;
returning to the receive-direct thread from the function, the function providing information indicative of whether data was received or the connection had no activity; and
migrating the connection to the listening thread when the information indicates the connection had no activity for a period of time. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20)
-
-
21. In a computer system including a client socket connected via a virtual connection with a data socket of a server, a mechanism for handling the connection, comprising:
-
a receive-direct thread associated with the data socket for handling communication on the connection;
a listening thread configured to listen for new connections;
a set of socket information associated with the listening thread;
means for detecting when the connection has no activity for a period of time; and
means for moving information referencing the data socket associated with the receive-direct thread to the set of socket information associated with the listening thread when the connection has no activity for a period of time. - View Dependent Claims (22, 23, 24, 25, 26, 27, 28, 29, 30, 31)
-
-
32. A method for handling a connection, comprising:
-
providing a set of at least one listening thread, each listening thread configured to listen for new connections;
providing a set of at least one receive-direct thread;
migrating the connection from a first listening thread of the set thereof to a first receive-direct thread of the set thereof when a level of activity is achieved on the connection; and
migrating the connection from the first receive-direct thread to one listening thread of the set thereof when a level of inactivity is achieved. - View Dependent Claims (33, 34, 35, 36, 37, 38)
-
-
39. A method for handling a connection, comprising:
-
providing a listening thread to listen for new connections and receive data on existing connections, the listening thread listening for requests for new connections on a plurality of different protocols;
receiving data on a connection at the listening thread; and
migrating the connection from the listening thread to a receive-direct thread such that further data on the connection is received for handling by the receive-direct thread. - View Dependent Claims (40, 41, 42, 43)
-
-
44. A system for handling data connections, comprising:
-
a listening thread configured to listen for new connections;
a receive-direct thread configured to handle data received from at least one of a plurality of connections, the listening thread migrating a first connection to the receive-direct thread to handle data received on the first connection;
a mechanism configured to detect activity on the first connection and to provide information to the receive-direct thread corresponding to a level of inactivity; and
the receive-direct thread receiving the information corresponding to the level of inactivity from the mechanism, and in response, migrating the first connection to the listening thread. - View Dependent Claims (45, 46, 47, 48, 49, 50)
-
Specification