FS-10167: Switched connection lifecycle to an isolated pool similar to sessions, also refactored the inner WSS transport implementation to be part of the same pool so it is cleaned up with the connection. Switched the connection state machine thread to also utilize thread pool to avoid direct ownership over the thread, similar to session but without the use of a signaled condition due to abstraction of transports which may need to deal with polling for socket events such as with WSS transport. Completely removed the temporary worker thread in the main handle that was for connection/session cleanup.

This commit is contained in:
Shane Bryldt committed 2017-04-18 13:41:00 -06:00
1 parent b84662ae6b
commit 2c996b592f
9 files changed
+178 -371

No files matched your search

+1 -1
View File
@@ -171,7 +171,7 @@ KS_DECLARE(void) ks_sleep(ks_time_t microsec)
do {
QueryPerformanceCounter((LARGE_INTEGER*) &now);
SwitchToThread();
if (!SwitchToThread()) Sleep(1);
} while ((now.QuadPart - start.QuadPart) / (float)(perfCnt.QuadPart) * 1000 * 1000 < (DWORD)microsec);
}