// the message IDs are set on the server
Map<String, Object>[] messages = queueControl.listMessages(null);
Assert.assertEquals(1, messages.length);
long messageID = (Long)messages[0].get("messageID");
boolean priorityChanged = queueControl.changeMessagePriority(messageID, newPriority);
Assert.assertTrue(priorityChanged);
ClientConsumer consumer = session.createConsumer(queue);
ClientMessage m = consumer.receive(500);
Assert.assertNotNull(m);