[jboss-dev-forums] [Design of Messaging on JBoss (Messaging/JBoss)] - Re: Refactoring on delegates

timfox do-not-reply at jboss.com
Tue Nov 27 19:16:31 EST 2007


A few initial comments.

The "agnostic" layer doesn't talk directly to MINA - it talks to Jeff's new Dispatcher which in turn talks to an abstracted MINA-like set of interfaces (so they can be mocked) which in turn talks to MINA.

I don't want to see any state or delegates methods remainaing - that's a half way hack. There should just be ConnectionFactory, Connection, Session and Consumer classes in the agnostic layer - all the code from the delegate, state and aspect classes should end up in those classes.

Actually ConnectionFactory, Connection, Session and Consumer should be interfaces, not concrete classes so they can be easily mocked.

I don't think we have need of any interceptors (apart from * see below), ClosedInterceptor can be easily implemented without being an interceptor.

Failover doesn't need interceptors either. We just have a simple valve on Jeff's dispatcher send methods. So no need for a factory or anything else to create any proxies.

The current wiki page describes various intermediate versions. That's fine, but I'm not so interested in the intermediate ones, but really the end goal. I think it's a bit confusing describing intermediate stages.

* - one place where an interceptor will be necessary is to allow an extension point for users to add their own client and server side interceptor(s) - this can probably be a simple java.lang.reflect.Proxy implementation

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4108270#4108270

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4108270



More information about the jboss-dev-forums mailing list