If you remove this line:
// Create the queue programmatically and the corresponding messaging resource
Queue queue = session.createQueue(QUEUE_NAME);
it will not try and create a queue
If you remove this line:
// Create the queue programmatically and the corresponding messaging resource
Queue queue = session.createQueue(QUEUE_NAME);
it will not try and create a queue