Here is a little stress test server I wrote to test the new Mac Socket/OT code. Mostly to pump gigabytes of data.
Basically it does a listen, and on accepts spins off a work element for another process to pickup via a shared queue. This process then reads the incoming data, and builds a dummy variable length static response string and drops that work element on a queue. Finally a write process wakes up takes the work element and writes the response to the socket and closes the socket and records how long it took to complete the entire accept to close task.
As mentioned before this code has run as many as 58 sustained connections per second and moved anywhere from 4Mbits to 12Mbits per second sustained, these number of course I think were limited by the number of clients I could rustle up.
I cannot speak for how it will work on other platforms or on macintosh without the lastest 28.a update and new VM. Of course willing parties are always welcome to try other combinations of Squeak and VMs
Oh yes yes there *might* be some race conditions on the counters for you folks that look at and work with multithreaded code, but I at the time didn't care mostly because I didn't see any problems.
Note this code creates a log file that gets added to every seconds, great for filling up hard drives. Look at the statistical process to understand what's written. If anyone wants to share some log files you are welcome to send me them (directly please not the list).
Lastly you send terminate to any running instance of the server to terminate it.
-- =========================================================================== John M. McIntosh johnmci@smalltalkconsulting.com 1-800-477-2659 Corporate Smalltalk Consulting Ltd. http://www.smalltalkconsulting.com =========================================================================== Custom Macintosh programming & various Smalltalk dialects PGP Key: DSS/Diff/46FC3BE6 Fingerprint=B22F 7D67 92B7 5D52 72D7 E94A EE69 2D21 46FC 3BE6 ===========================================================================
squeak-dev@lists.squeakfoundation.org