[GitHub] kafka pull request #3417: MINOR: Correct the ConsumerPerformance print forma...

2017-07-14 Thread asfgit
Github user asfgit closed the pull request at:

https://github.com/apache/kafka/pull/3417


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---


[GitHub] kafka pull request #3417: MINOR: Correct the ConsumerPerformance print forma...

2017-06-22 Thread ConeyLiu
GitHub user ConeyLiu opened a pull request:

https://github.com/apache/kafka/pull/3417

MINOR: Correct the ConsumerPerformance print format

Currently, the output of `ConsumerPerformance` looks strange. Before the 
`header` format as follow:
```
"time, threadId, data.consumed.in.MB, MB.sec, data.consumed.in.nMsg, 
nMsg.sec"
```
while the `body` as follow:
```
println("%s, %d, %.4f, %.4f, %d, %.4f".format(dateFormat.format(endMs), id, 
totalMBRead,
1000.0 * (mbRead / elapsedMs), messagesRead, ((messagesRead - 
lastMessagesRead) / elapsedMs) * 1000.0))
```

So we get the follow result:
```
time, data.consumeed.in.MB, MB.sec, data.consumeed.in.nMsg, nMsg.Sec
09:52:00, 0, 1100.3086, 220.0177, 563358, 112649.0702
```
So the `header` and `body` mismatching.

And also, this pr makes the functions more readable.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/ConeyLiu/kafka consumertest

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/kafka/pull/3417.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #3417


commit 7e90edb4b7deb828a96d41aa0d66a8dd5b872c0d
Author: Xianyang Liu 
Date:   2017-06-23T02:06:03Z

small fix

commit b0889209f4cd245c6e7de39d694de2dd0e9dfb8b
Author: Xianyang Liu 
Date:   2017-06-23T02:06:31Z

Merge remote-tracking branch 'kafka/trunk' into consumertest




---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---