On 21.09.2011 12:09, Nigel Deakin wrote:
> On 20/09/2011 15:33, Ruediger zu Dohna wrote:
>> +1 for createDurableConsumer, but I'd also suggest to change the first
>> parameter from Topic to Destination... or we'd
>> still have a dependency.
>
> We're not removing the Topic and Queue interfaces - or the distinction
> between topics and queues in general. You can't create a durable
> consumer on a queue, so the first argument still needs to be a Topic.
>
> In the same way, you can't create a QueueBrowser on a topic, so we still
> need Session.createBrowser(Queue queue).
I understand that the concepts of p2p and pub/sub still must exist for
durable subscribers (to Topics) and browsers (in Queues). If that's the
only reason to keep those interfaces, I'd vote to define the methods to
take a Destination and have Topic, Queue, etc. deprecated and eventually
removed. Their methods (getQueue/TopicName and delete for the Temporary
subtypes) should be moved into the Destination (getDestinationName or
getName?). And maybe the delete method should be moved into a new
TemporaryDestination?
But maybe this is a separate issue?