Browse files

- include tsung-plotter tool from Dimitri Fontaine (TSUN-89)

- update to make it work with tsung 1.3.0

SVN Revision: 908
  • Loading branch information...
1 parent c1e6ec9 commit fb11e0f1506331545205fcb206a20f4acb286527 @nniclausse nniclausse committed Oct 14, 2008
@@ -1,7 +1,7 @@
# $Id$
-MANPAGE_SRC = tsung.1.sgml
-MANPAGE = tsung.1
+MANPAGE_SRC = tsung.1.sgml tsplot.1.sgml
+MANPAGE = tsung.1 tsplot.1
@@ -23,7 +23,7 @@ LANGUAGE=
# logos
-LOGOS_EPS = $(LOGOS_JPG:.jpg=.eps)
+LOGOS_EPS = $(LOGOS_JPG:.jpg=.eps)
@@ -38,22 +38,22 @@ HTML_INDEXFILES=$(TEXFILES:.tex=_index.html)
# get figures to be generated from gnuplot file
PLOT_PS = $(shell grep -s output $(PLOT_DIR)/*.gplot | cut -f3 -d" " | perl -e '{ while (<>) {chomp; s/"//;s/"/ /; print} }')
-PLOT=$(addprefix $(PLOT_DIR)/,$(PLOT_PS))
+PLOT=$(addprefix $(PLOT_DIR)/,$(PLOT_PS))
#PLOT = $(wildcard $(PLOT_DIR)/*.ps)
-PLOT_PNG = $(
-PLOT_PDF = $(
+PLOT_PNG = $(
+PLOT_PDF = $(
# figures
FIGURES = $(wildcard $(FIGURES_DIR)/*.fig)
-FIGURES_PNG = $(FIGURES:.fig=.png)
-#FIGURES_JPG = $(FIGURES:.fig=.jpg)
+FIGURES_PNG = $(FIGURES:.fig=.png)
+#FIGURES_JPG = $(FIGURES:.fig=.jpg)
# images
IMAGES_PNG = $(wildcard $(IMAGES_DIR)/*.png)
-IMAGES_EPS = $(IMAGES_PNG:.png=.eps)
+IMAGES_EPS = $(IMAGES_PNG:.png=.eps)
ALL_IMG = $(notdir $(FIGURES))
ALL_IMG += $(notdir $(IMAGES_PNG))
@@ -76,7 +76,7 @@ LATEX=latex --interaction=batchmode
@@ -94,7 +94,7 @@ VPATH = $(TEXINPUTS)
# pour exporter TEXINPUTS
-.PHONY: clean distclean pdf dvi ps all html htmlsingle
+.PHONY: clean distclean pdf dvi ps all html htmlsingle
# Stop GNU make from overzealous deletion of intermediate files
@@ -117,9 +117,9 @@ show:
@echo IMG= $(IMAGES_PNG)
@echo PLOT= $(PLOT_PNG)
- @echo TEX = $(TEXFILES)
- @echo HTML = $(HTMLFILES)
- @echo LOGOS = $(LOGOS_EPS)
+ @echo TEX = $(TEXFILES)
+ @echo HTML = $(HTMLFILES)
+ @echo LOGOS = $(LOGOS_EPS)
@echo ALL_IMG = $(ALL_IMG)
@@ -134,7 +134,7 @@ html: $(HTMLFILES)
htmlsplit: $(HTML_INDEXFILES)
print: $(PSFILES)
@echo "printing $<"
- a2ps $<
+ a2ps $<
# $(MAKEINDEX) -s -o these.gls these.glo
@@ -152,19 +152,19 @@ user_manual.html: user_manual.tex $(INCLUDES) $(FIGURES_PNG) $(IMAGES_PNG) $(HEV
ifeq ($(strip $(IMAGES_PNG)),)
@echo no images
@echo Generating images for html...
@ln -sf $(IMAGES_DIR)/*.png .
ifeq ($(strip $(FIGURES_PNG)),)
@echo no figures
@echo Generating figures for html...
@ln -sf $(FIGURES_DIR)/*.png .
ifeq ($(strip $(PLOT_PNG)),)
@echo no plot
@echo Generating plot for html...
@ln -sf $(PLOT_DIR)/*.png .
@@ -233,35 +233,35 @@ $(PLOT_DIR)/ $(PLOT_DIR)/*.gplot
$(PLOT_DIR)/%.png: $(PLOT_DIR)/
@echo Generating $@
- @$(CONVERT) $< $@
+ @$(CONVERT) $< $@
$(PLOT_DIR)/%.pdf: $(PLOT_DIR)/
@echo Generating $@
@$(EPS2PDF) $<
$(FIGURES_DIR)/%.png: $(FIGURES_DIR)/%.fig
@echo Generating $@
- @$(FIG2DEV) -L png $< $@
+ @$(FIG2DEV) -L png $< $@
$(FIGURES_DIR)/%.jpg: $(FIGURES_DIR)/%.fig
@echo Generating $@
- @$(FIG2DEV) -L jpeg $< $@
+ @$(FIG2DEV) -L jpeg $< $@
$(FIGURES_DIR)/%.eps: $(FIGURES_DIR)/%.fig
@echo Generating $@
- @$(FIG2DEV) -L eps $< $@
+ @$(FIG2DEV) -L eps $< $@
$(IMAGES_DIR)/%.jpg: $(IMAGES_DIR)/%.png
@echo Generating $@
- @$(CONVERT) $< $@
+ @$(CONVERT) $< $@
$(IMAGES_DIR)/%.eps: $(IMAGES_DIR)/%.png
@echo Generating $@
- @$(CONVERT) $< $@
+ @$(CONVERT) $< $@
$(LOGO_DIR)/%.eps: $(IMAGES_DIR)/%.jpg
@echo Generating $@
- @$(CONVERT) $< $@
+ @$(CONVERT) $< $@
mrproper: distclean
@@ -0,0 +1,202 @@
+.\" This manpage has been automatically generated by docbook2man
+.\" from a DocBook document. This tool can be found at:
+.\" <>
+.\" Please send any bug reports, improvements, comments, patches,
+.\" etc. to Steve Cheng <>.
+.TH "TSPLOT" "1" "14 octobre 2008" "" ""
+tsplot \- Plot several tsung logs on the same charts, for comparison purpose.
+\fBtsplot\fR [ \fB-c configuration file\fR ] [ \fB-d images output directory\fR ] [ \fB-v verbose\fR ] [ \fBlegend logfile\fR ]
+Tsung comes with a plotting tool using
+\fBgnuplot\fR, producing some graphs from the
+\fItsung.log\fR file data.
+\fBtsplot\fR is able to plot data from several
+\fItsung.log\fR files onto the same charts serie,
+for further comparison and analyze.
+specifies the configuration file to use. This option has
+no default setting.
+directory where \fBtsplot\fR saves the images
+it produces, defaults to \fI/tmp/tsung\fR\&.
+makes \fBtsplot\fR very verbose about
+what it does.
+The configuration file of \fBtsplot\fR allows to
+define the plots you want to obtain, from their label to the
+data they will show. The configuration file adopts a
+\fI\&.ini\fR file syntax, each section defining a
+\fBtsplot\fR comes with two sample configuration
+files, namely \fIhttp.plots.conf\fR and
+\fIpgsql.plots.conf\fR\&. They respectively define
+charts to be plotted for a \fBtsung\fR HTTP test
+and a \fBtsung\fR PGSQL test. Their labels are in
+A \fBDEFAULT\fR section may be provided, any
+element configured here may then be overriden into a specific
+plot section.
+Another configuration file is used by \fBtsplot\fR:
+the \fItsung/stats.conf\fR one. It's used to
+define by type the statistics to be read into
+\fBtsung\fR log files, and you shouldn't need to
+edit it, short of adding support for new
+\fBtsung\fR statistics.
+Common settings, to be found into \fBDEFAULT\fR
+section or any specific chart section.
+set here the encoding used thereafter in the file, for
+labels and titles.
+dpi setting of produced charts images
+dpi setting of produced charts thumbnail images
+type of chart image to produce, as in
+\fIpng\fR or \fIps\fR
+A complete list might be obtained on the
+\fBpython-matplotlib\fR website,
+default label for horizontal axe, often you want seconds
+or minutes, depending on xfactor.
+Please note you can also set some defaults for ylabel, but
+this seems not to be a good idea in practise.
+tsung logs statistics in its logfile every 10 seconds. By
+default, charts will not scale this and have seconds as
+horizontal axis units. By setting an xfactor of 60, you
+have a minute precision on horizontal axis.
+same as xfactor, but for vertical axis.
+Depending on the data you obtain with your tests, you may
+want to adapt the vertical scale of your plotting. For
+example, the \fBpage.mean\fR statistic is
+logged in milliseconds by \fBtsung\fR\&. You
+may want to display seconds if this unit better fits your
+measures. Then simply set \fByfactor =
+set here any number of \fBmatplotlib\fR
+styles you want to use, separated by spaces, as available
+For exemple, set \fBstyles = b- g+ r- cx\fR
+for plotting first dataset (see \fBstats\fR
+below) with a blue solid line, second with green plus
+symbols, third with a red line and last with cyan cross
+This could fit a \fBstats = 200.count
+400.count\fR stats setting when plotting two
+\fBtsung\fR logs.
+You then can define any number of plot, one by section, and give
+them an arbitrary name. The name must be unique, and will be
+used for naming output images.
+Any option available in DEFAULT section is also available in any
+specific chart section, with the same meaning and effect. The
+specific setting will systematically override the DEFAULT one.
+Title of the chart, as printed into the resulting image.
+The statistics properties to use for this plotting, as
+named in the \fItsung/stats\fR
+configuration file. Please see this bundled file for a
+list of what is available.
+Tsung provide several types of statistics, as documented
+ The
+two main types of statistics used are
+\fBsample\fR and \fBcounter\fR\&. A
+third one is \fBgauge\fR but is only use for a
+single statistic (users).
+sample provides count, mean, stdvar, max, min and gmean
+(global mean)
+properties, and counter provides only count and
+totalcount. gauge provide count and max.
+The stats setting can accept several
+\\fR elements, separated by
+Examples: \fBstats = users.count\fR to plot
+the number of simultaneously connected users, and
+\fBstats = 200.count 400.count\fR to plot
+given HTTP return codes count, both on the same chart.
+Please notice \fBtsplot\fR is currently
+limited to use only one horizontal and only one vertical
+scales. \fBmatplotlib\fR is able to define
+some more complex drawings, but \fBtsplot\fR
+is not yet able to benefit from this.
+Legend prefix, which will be followed by the legend given
+on command line.
+Each plot on a chart has a legend entry, you configure
+here the meaning of the plot (say 'concurrent users') and
+\fBtsplot\fR will add it the name of the data
+serie being plotted (say 'scenario x'). You'd obtain this
+legend: 'concurrent users scenario x'.
+label for vertical axe
+Please see the given configuration examples which should be
+distributed in
+Please reports bugs to the mailing list
+<>, see
+ for
+\fBtsplot\fR is written by Dimitri
+Fontaine <>\&.
Oops, something went wrong.

0 comments on commit fb11e0f

Please sign in to comment.