User-Agent: Workspace Webmail 5.15.9Message-Id: <20150831110650.85f80dae80d1d2f2e266ec6278e6cbe8.3dd5974ce5.wbe@email07.europe.secureserver.net>From: “David Demner (AquaQ)” <david.demner>To: personal-kdbplus@googlegroups.comSubject: RE: [personal kdb+] peach type errorDate: Mon, 31 Aug 2015 11:06:50 -0700Mime-Version: 1.0
Sockets/handles with peach
A handle must not be used concurrently between threads as there is no locking around a socket descriptor, and the bytes being read/written from/to the socket will be garbage (due to message interleaving) and most likely result in a crash. Since v3.0, a socket can be used from the main thread only, or if you use the single shot sync request syntax as
q)`:localhost:5000 "2+2" peach forms the basis for a multithreaded hdb, for illustration purposes considering the following query
{select max price by date,sym from trade where date=d} peach date
this would execute a query for each date in parallel. The multithreaded hdb with par.txt hides the complexity of splitting the query up between threads and aggregating the results.