From: timfox <nu...@jb...> - 2005-05-18 07:19:17
|
We _could_ do this either way and make it configurable by the user. However, discriminating the two types of NACKs adds significant complexity to the implementation (it prompted this whole discussion) including changes to the core interfaces. My gut feeling is to keep it simple unless we really think the new feature would add value for the user. I.e. perhaps we should ask the quesion: Would a user really care about discriminating those messages that have never been delivered and those that have been NACKed by the channel's receivers? I'm sure there probably is a use case where this distinction is important - but I can't think of one right now. My feeling is that in most cases JMS users just want to have a rough idea of what's on the queue and hence what's going to be (re)delivered when the consumer/durables subcriber attaches. (I add durable subscriber here - since even though it's not part of JMS spec, browsing durable subscribers is something we could add, that does add value IMO... but that's a different discussion). Moreover, as Adrian has pointed out, the JMS spec makes no guarantees as to the consistency/"staticness" so anyone building a JMS application that relies on some extra knowledge of what's in the queue other than what's guaranteed by the spec. would be non-portable between JMS implementations. If it really is important for JMS Users to distinguish messages that have been never delivered/messages that have been delivered once etc., then another approach could be to use a jmsx message property, e.g. delivery_count which gets incremented every-time a delivery is attempted. The JMS user could then just filter on this value via a message selector when they do the browse. This should allow them to discriminate between these messages, and would require no changes to the core class interfaces. I think this approach is used by several jms implementations (i'm not sure about this but I just googled) including websphere and activemq. View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3878145#3878145 Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3878145 |