public abstract class PivotTableRenderer extends Object implements IRenderer
Minutes Timestamp hostname indexName indexPartitionName readSecs writeSecs leafSplits tailSplits 0 1:41PM blade8 spo spo#12 0.12 0.3 10 4 0 1:41PM blade8 spo spo#14 0.01 0.2 20 1There are two time columns. One gives the #of elapsed units and the column header is the specified basePeriod and will be zero for the first row and is incremented by one each time we move into another sampling period for the given
PeriodEnum
. The other time column
is the timestamp associated with the row. The format of that timestamp is
specified by URLQueryModel.timestampFormat
.
In this example, there are three category columns (hostname, indexName,
and indexPartitionName). The category columns were selected by the
capturing groups in URLQueryModel.pattern
and take on different values
for each row in the table. In order to get nice column names you MUST
specify the column names using the URLQueryModel.CATEGORY
URL query
parameter. The given category column names are used in order and
synthetic column names are generated if none (or not enough) were
specified in the URLQueryModel
.
In this example, there are four value columns. Each vlaue column
corresponds to an ICounter
whose path was matched by the
URLQueryModel.pattern
.
Note: The orientation of the data in the pivot table view is different
from the data in the correlated view. The pivot table puts each set of
cells having the same values for the category columns onto a single line.
Those cells are choosen by a read cross the columns in a given row of the
HistoryTable
. The timestamp columns correspond to the current
row of the history table and are therefore repeated if there is more than
one set of distinct ordered bindings for the category column values in
the selected counters.
Note: The counter sets are designed as regular hierarchies: we often find the "same" counter name under different paths. For example:
indices/TERM2ID/TERM2ID#0/IO/writeSecs indices/TERM2ID/TERM2ID#2/IO/writeSecs indices/SPO/SPO#7/IO/writeSecs Live Journal/IO/writeSecsAll of these have a "writeSecs" counter. However, the first 3 are in essence the same counter, just for a different resource index, while the last one is a counter for a journal resource.
The Pattern
.*\Qindices/\E(.*)\Q/IO/writeSecs\Ewould match only the first three rows and would capture
[TERM2ID/TERM2ID#0] [TERM2ID/TERM2ID#2] [SPO/SPO#7]You can also capture additional groups, such as the name of the host on which the data service was running within which the index partition is living. Those capture groups might look like:
[blade2, TERM2ID/TERM2ID#0] [blade3, TERM2ID/TERM2ID#2] [blade2, SPO/SPO#7]There will be only one "writeSecs" value column in the generated pivot table. The performance
ICounter
for a given resource will be
reported under that "writeSecs" column in a row whose category column
values are identical to the captured groups for that
ICounterNode.getPath()
.
Note: When switching from a pivot table view to a correlated view be sure that you DO NOT use a capturing group for the counter name (the last component of its path). That will give you a distinct row for every sample and blanks in the other value columns.
Modifier and Type | Field and Description |
---|---|
protected ValueFormatter |
formatter |
protected static org.apache.log4j.Logger |
log |
protected PivotTable |
pt |
Modifier | Constructor and Description |
---|---|
protected |
PivotTableRenderer(PivotTable pt,
ValueFormatter formatter) |
protected static final org.apache.log4j.Logger log
protected final PivotTable pt
protected final ValueFormatter formatter
protected PivotTableRenderer(PivotTable pt, ValueFormatter formatter)
Copyright © 2006–2019 SYSTAP, LLC DBA Blazegraph. All rights reserved.