mirror of
https://github.com/nosqlbench/nosqlbench.git
synced 2025-02-25 18:55:28 -06:00
avoid decoding msgBody twice in JmsMsgSendOp
This commit is contained in:
parent
18e9bb91ff
commit
2d84c4d036
@ -108,11 +108,10 @@ public class JmsMsgSendOp extends JmsTimeTrackOp {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
int messageSize;
|
|
||||||
try {
|
try {
|
||||||
byte[] msgBytes = msgBody.getBytes(StandardCharsets.UTF_8);
|
byte[] msgBytes = msgBody.getBytes(StandardCharsets.UTF_8);
|
||||||
messageSize = msgBytes.length;
|
int messageSize = msgBytes.length;
|
||||||
jmsProducer.send(jmsDestination, msgBody.getBytes(StandardCharsets.UTF_8));
|
jmsProducer.send(jmsDestination, msgBytes);
|
||||||
|
|
||||||
messagesizeHistogram.update(messageSize);
|
messagesizeHistogram.update(messageSize);
|
||||||
bytesCounter.inc(messageSize);
|
bytesCounter.inc(messageSize);
|
||||||
|
Loading…
Reference in New Issue
Block a user