From: Asynch M. <asy...@ho...> - 2004-03-26 04:29:18
|
> > >Oh well. Anyway, I have a /separate/ client in > >net.xmlrouter.mod_pubsub.client. > > Have you checked it in? Yeah - it's been there for quite a while & I updated it over the weekend & tonight. I finished some re-factoring. There are now some low level classes like EventServer (just routes on remote server), Connection (handles journal topic) and Dispatcher (routes incoming message to multiple listener objects based on kn_routed_from). There was already an EventStream which handled all the parsing by reading an InputStream and a SimpleRouter that simplified doing simple things (which is why it is simply named SimpleRouter). There is some unfinished business with 'MessageInterceptor' that I'll someday use to inject default headers (like username, etc) into outgoing messages. None of these have the rigorous testing that your packages have. The next time I get some free time I'll add unit tests. I also added a sample console app 'Snoop'. try { SimpleRouter router = new SimpleRouter(args[0]); DebugListener listener = new DebugListener(); router.subscribe(args[1],listener,null); } catch(Exception e) { System.err.println("ERROR: "+e.getMessage()); } |