@@ -0,0 +1,2570 @@
+package kg.apc.jmeter.vizualizers;%0A%0Aimport kg.apc.jmeter.charting.AbstractGraphRow;%0Aimport kg.apc.jmeter.charting.GraphRowSumValues;%0Aimport org.apache.jmeter.samplers.SampleResult;%0A%0A/**%0A *%0A * @author Stephane Hoblingre%0A */%0Apublic class TotalTransactionsPerSecondGui%0A        extends AbstractGraphPanelVisualizer%0A%7B%0A    //private static final Logger log = LoggingManager.getLoggerForClass();%0A%0A    /**%0A     *%0A     */%0A    public TotalTransactionsPerSecondGui()%0A    %7B%0A        super();%0A        graphPanel.getGraphObject().setxAxisLabelRenderer(new DateTimeRenderer(%0A                %22HH:mm:ss%22));%0A        graphPanel.getGraphObject().setDrawFinalZeroingLines(true);%0A        setGranulation(1000);%0A    %7D%0A%0A    private synchronized AbstractGraphRow getNewRow(String label)%0A    %7B%0A        AbstractGraphRow row = null;%0A        if(!model.containsKey(label)) %7B%0A            row = new GraphRowSumValues(false);%0A            row.setLabel(label);%0A            row.setColor(colors.getNextColor());%0A            row.setDrawLine(true);%0A            row.setMarkerSize(AbstractGraphRow.MARKER_SIZE_SMALL);%0A            model.put(label, row);%0A            graphPanel.addRow(row);%0A        %7D else %7B%0A            row = model.get(label);%0A        %7D%0A%0A        return row;%0A    %7D%0A%0A    private void addTransaction(String threadGroupName, long time, double count)%0A    %7B%0A        AbstractGraphRow row = model.get(threadGroupName);%0A        if (row == null)%0A        %7B%0A            row = getNewRow(threadGroupName);%0A        %7D%0A%0A        //fix to have trans/sec values in all cases%0A        if (getGranulation() %3E 0)%0A        %7B%0A            row.add(time, count * 1000.0d / getGranulation());%0A        %7D%0A    %7D%0A%0A    public String getLabelResource()%0A    %7B%0A        return this.getClass().getSimpleName();%0A    %7D%0A%0A    @Override%0A    public String getStaticLabel()%0A    %7B%0A        return %22Total Transactions Per Second%22;%0A    %7D%0A%0A    public void add(SampleResult res)%0A    %7B%0A        //always add 0 failed transactions%0A        if (res.isSuccessful())%0A        %7B%0A            addTransaction(%22Failed Transactions per Second%22, res.getEndTime() - res.getEndTime() %25 getGranulation(), 0);%0A            addTransaction(%22Successful Transactions per Second%22, res.getEndTime() - res.getEndTime() %25 getGranulation(), 1);%0A        %7D else%0A        %7B%0A            addTransaction(%22Failed Transactions per Second%22, res.getEndTime() - res.getEndTime() %25 getGranulation(), 1);%0A        %7D%0A        updateGui(null);%0A    %7D%0A%0A    @Override%0A    protected JSettingsPanel getSettingsPanel()%0A    %7B%0A        return new JSettingsPanel(this, true, true, false, true, true);%0A    %7D%0A%7D%0A

rollback obsolete listeners removal