【问题标题】:Interpreting qpid-bench output解释 qpid-bench 输出
【发布时间】:2011-12-23 18:21:36
【问题描述】:

我正在针对几台不同的机器运行 Apache qpid 附带的 qpid-bench 工具,以对性能进行基准测试。我无法找到关于 qpid-bench 程序的输出/结果的任何文档。以下是样本测试的结果:

$ qpid-bench
broker = localhost                                                                                                                                                                                                                                                             
port = 5672                                                                                                                                                                                                                                                                    
count = 1000000                                                                                                                                                                                                                                                                
window = 100000                                                                                                                                                                                                                                                                
sample = 100000                                                                                                                                                                                                                                                                
size = 1024                                                                                                                                                                                                                                                                    
mode = BOTH                                                                                                                                                                                                                                                                    
timestamp = false                                                                                                                                                                                                                                                              
message_id = false                                                                                                                                                                                                                                                             
message_cache = false                                                                                                                                                                                                                                                          
persistent = false                                                                                                                                                                                                                                                             
jms_publish = false                                                                                                                                                                                                                                                            
jms_consume = false                                                                                                                                                                                                                                                            
help = false                                                                                                                                                                                                                                                                   
IoReceiver - localhost/127.0.0.1:5672 2011-12-23 09:39:11,427 INFO ...                                    
IoReceiver - localhost/127.0.0.1:5672 2011-12-23 09:39:11,427 INFO ...                                                             
NP: Fri Dec 23 09:39:11 PST 2011                   --                                                                                                                                                                                                                          
               --                   NC: Fri Dec 23 09:39:11 PST 2011                                                                                                                                                                                                           
NP: 100000 6246.49 6246.49                         --                                                                                                                                                                                                                          
               --                   NC: 100000 6205.01 6205.01                                                                                                                                                                                                                 
NP: 200000 6775.07 7401.38                         --                                                                                                                                                                                                                          
               --                   NC: 200000 6758.58 7420.60                                                                                                                                                                                                                 
NP: 300000 6795.94 6838.07                         --                                                                                                                                                                                                                          
               --                   NC: 300000 6782.27 6830.13                                                                                                                                                                                                                 
NP: 400000 6618.02 6136.10                         --                                                                                                                                                                                                                          
               --                   NC: 400000 6609.28 6139.49                                                                                                                                                                                                                 
NP: 500000 6673.07 6902.74                         --                                                                                                                                                                                                                          
               --                   NC: 500000 6662.31 6883.26                                                                                                                                                                                                                 
NP: 600000 6723.89 6990.07                         --                                                                                                                                                                                                                          
               --                   NC: 600000 6707.36 6942.03                                                                                                                                                                                                                 
NP: 700000 6780.32 7139.80                         --                                                                                                                                                                                                                          
               --                   NC: 700000 6775.07 7211.89                                                                                                                                                                                                                 
NP: 800000 6679.08 6047.05                         --                                                                                                                                                                                                                          
               --                   NC: 800000 6673.67 6040.84                                                                                                                                                                                                                 
NP: 900000 6547.26 5654.51                         --                                                                                                                                                                                                                          
               --                   NC: 900000 6538.56 5627.15                                                                                                                                                                                                                 
Producer Completed
Consumer Completed

我猜 NP 是发布的数量,NC 是每个窗口消耗的数量。第一个数字是发送/接收消息的数量。第二个和第三个数字是什么意思?

【问题讨论】:

    标签: java benchmarking messaging amqp qpid


    【解决方案1】:

    这里是 QpidBench.java 的源代码:https://svn.apache.org/repos/asf/qpid/trunk/qpid/java/tools/src/main/java/org/apache/qpid/tools/QpidBench.java

    以下是 qpid-bench 命令的选项:

    $ qpid-bench --help
       qpid-bench <options>
      -b, --broker    (localhost)   the broker hostname
      -p, --port      (5672)        the broker port
      -c, --count     (1000000)     the number of messages to send/receive, 0 means no limit
      -w, --window    (100000)      the number of messages to send before blocking, 0 disables
      --sample        (100000)      print stats after this many messages, 0 disables
      -i, --interval  (100000)      sets both --window and --sample
      -s, --size      (1024)        the message size
      -m, --mode      (BOTH)        one of publish, consume, or both
      --timestamp     (false)       set timestamps on each message if true
      --mesage-id     (false)       set the message-id on each message if true
      --message-cache (false)       reuse the same message for each send if true
      --persistent    (false)       set the delivery-mode to persistent if true
      --jms-publish   (false)       use the jms client for publish
      --jms-consume   (false)       use the jms client for consume
      --jms           (false)       sets both --jms-publish and --jms-consume
      -h, --help                    prints this message
    

    第一个累积的数字定义为“双累积 = 1000 * (double) count / (double) (time - start);”在 QPidBench.java 中。即每个样本期间发布或消费的总数。

    第二个数字区间定义为“double interval = 1000 * ((double) opts.sample / (double) (time - lastTime));”在 QpidBench.java 中。即每个样本期间发布或消费的数量。

    count 是发布/使用的消息数量,opts.sample 是运行 qpid-bench 时在选项中定义的样本大小。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2011-05-04
      • 2023-03-18
      • 2012-05-19
      • 2014-02-17
      • 2011-05-03
      • 2012-02-17
      • 2021-12-18
      • 1970-01-01
      相关资源
      最近更新 更多