gov.lbl.dsd.sea.nio.demo
Class AsyncPingPongBench
java.lang.Object
gov.lbl.dsd.sea.EventHandler
gov.lbl.dsd.sea.nio.demo.AsyncPingPongBench
- public class AsyncPingPongBench
- extends EventHandler
Asynchronous non-blocking ping pong benchmark; Sends messages back and forth
between client and server and measures throughput.
Example server usage: fire-java gov.lbl.dsd.sea.nio.demo.AsyncPingPongBench
server 9000 256 256
Example client usage: fire-java gov.lbl.dsd.sea.nio.demo.AsyncPingPongBench
client localhost 9000 256 400000 256 256
Should report on the order of 160 MB/s throughput using localhost and
appropriately large packet sizes and TCP buffer sizes.
Set log level to ERROR to avoid logging becoming the bottleneck!
- Version:
- $Revision: 1.22 $, $Date: 2004/05/31 21:23:36 $
Method Summary |
void |
handle(Object event)
Main entry point; called when an event handler should handle the given event. |
static void |
main(String[] args)
|
AsyncPingPongBench
public AsyncPingPongBench(String[] args)
throws IOException
main
public static void main(String[] args)
throws IOException
- Throws:
IOException
handle
public void handle(Object event)
- Description copied from class:
EventHandler
- Main entry point; called when an event handler should handle the given event.
- Specified by:
handle
in class EventHandler