Instances of it can be obtained from {@link HornetQBuffers} factory.
Much of it derived from Netty ChannelBuffer by Trustin Lee @author Tim Fox @see HornetQBuffers
176177178179180181182183184185186187188
for (int i = 0; i < numberOfMessages; i++) { message = session.createMessage(true); HornetQBuffer bodyLocal = message.getBodyBuffer(); bodyLocal.writeBytes(body); message.putIntProperty(new SimpleString("id"), i); producer.send(message); if (i % 1000 == 0)
403404405406407408409410411412413414415
552553554555556557558559560561562563564
for (int i = 0; i < numberOfMessages; i++) { message = session.createMessage(true); HornetQBuffer bodyLocal = message.getBodyBuffer(); bodyLocal.writeBytes(body); message.putIntProperty(new SimpleString("id"), i); producer.send(message); if (i % messagesPerTX == 0)
736737738739740741742743744745746747748
for (int i = 0; i < numberOfMessages; i++) { message = session.createMessage(true); HornetQBuffer bodyLocal = message.getBodyBuffer(); bodyLocal.writeBytes(body); message.putStringProperty("id", "str-" + i); producer.send(message); if ((i + 1) % messagesPerTX == 0)
889890891892893894895896897898899900901
for (int i = 0; i < numberOfMessages; i++) { message = session.createMessage(persistentMessages); HornetQBuffer bodyLocal = message.getBodyBuffer(); bodyLocal.writeBytes(body); message.putIntProperty(new SimpleString("id"), i); producer.send(message); if (i % 1000 == 0)
1068106910701071107210731074107510761077107810791080
{ session.commit(); } message = session.createMessage(true); HornetQBuffer bodyLocal = message.getBodyBuffer(); bodyLocal.writeBytes(body); message.putIntProperty(new SimpleString("id"), i); producer.send(message); }
1261126212631264126512661267126812691270127112721273
1439144014411442144314441445144614471448144914501451
for (int i = 0; i < numberOfMessages; i++) { message = session.createMessage(persistentMessages); HornetQBuffer bodyLocal = message.getBodyBuffer(); bodyLocal.writeBytes(body); message.putIntProperty(new SimpleString("id"), i); producer.send(message); }
241124122413241424152416241724182419242024212422242324242425
for (int i = 0; i < numberOfMessages; i++) { message = session.createMessage(true); HornetQBuffer bodyLocal = message.getBodyBuffer(); for (int j = 1; j <= numberOfIntegers; j++) { bodyLocal.writeInt(j); } message.putIntProperty(new SimpleString("id"), i); producer.send(message);
248424852486248724882489249024912492249324942495249624972498