December 2013
Intermediate to advanced
288 pages
5h 48m
English
In this example we will show how an AMQP message is divided, and how to use message properties.
You can find the source at Chapter01/Recipe11/Java_11/.
To use this recipe you will need to set up the Java development environment as indicated in the Introduction section.
In order to access the message properties you need to perform the following steps:
channel.queueDeclare(MyQueue, false, false, false,null);
BasicProperties class:Map<String,Object>headerMap = new HashMap<String, Object>(); headerMap.put("key1", "value1"); headerMap.put("key2", new Integer(50) ); headerMap.put("key3", new Boolean(false)); headerMap.put("key4", "value4"); BasicProperties messageProperties = new ...Read now
Unlock full access