public MessageConsumer createConsumer ( IntegerID consumerId , Destination destination , String messageSelector , boolean noLocal ) throws JMSException { externalAccessLock . readLock ( ) . lock ( ) ; try { checkNotClosed ( ) ; LocalMessageConsumer consumer = new LocalMessageConsumer ( engine , this , destination , messageSelector , noLocal , consumerId , null ) ; registerConsumer ( consumer ) ; consumer . initDestination ( ) ; return consumer ; } finally { externalAccessLock . readLock ( ) . unlock ( ) ; } }
Create a consumer with the given id