Vincent Bernat
78fb01c223
chore: fix some small issues detected by golangci-lint
...
But not using it as some linters are either plain incorrect (the one
suggesting to not use nil for `c.t.Context()`) or just
debatable (checking for err value is a good practice, but there are
good reasons to opt out in some cases).
2022-08-10 17:44:32 +02:00
Vincent Bernat
454a3eb9d3
console: add "previous period" mode
...
This displays a line for the previous period on stacked graphs.
Previous period depends on the current period. It could be hour, day,
week, month, or year.
2022-08-09 21:40:06 +02:00
Vincent Bernat
8e755ae0e1
console: ensure we fill missing values including the last one
...
BETWEEN is inclusive, while FILL excludes the upper bound. This may
trigger a subtle bug where sometimes, one axis has one value the other
does not have.
2022-08-09 19:16:16 +02:00
Vincent Bernat
67703cc61e
console: use templates to build SQL query
...
This is needed if we want to be able to mix use of several tables
inside a single query (for example, flows_1m0s for a part of the query
and flows_5m0s for another part to overlay historical data).
Also, the way we handle time buckets is now cleaner. The previous way
had two stages of rounding and was incorrect. We were discarding the
first and last value for this reason. The new way only has one stage
of rounding and is correct. It tries hard to align the buckets at the
specified start time. We don't need to discard these values anymore.
We still discard the last one because it could be incomplete (when end
is "now").
2022-08-09 11:45:40 +02:00
Vincent Bernat
b5e48e8cfd
console: also use dimensions to tell if we need to use main table
2022-08-08 11:35:18 +02:00
Vincent Bernat
b745cfd356
console: fix test about reverse filter direction
2022-08-08 09:42:27 +02:00
Vincent Bernat
50614cef5b
console: add a bidirectional mode for graphs
...
It allows one to also display flows in the opposite direction.
2022-08-07 23:15:18 +02:00
Vincent Bernat
1aa260bae2
console/filter: let parser tells us if we need the main table or not
...
This is more robust this way. We also introduce the ability to reverse
the direction of a filter.
2022-08-04 18:54:41 +02:00
Vincent Bernat
fad0c5db16
console: simplify SQL request by computing target resolution in Go
2022-07-26 23:51:32 +02:00
Vincent Bernat
f5e2e85d0d
console: fix a possible divide by 0 error
...
This is not the only problem we have.
2022-07-09 08:42:42 +02:00
Vincent Bernat
418bf5176e
console: exclude 0 from minimum value
2022-07-08 15:36:12 +02:00
Vincent Bernat
412bb1f535
console: fill missing values with 0 for timeseries graphs
2022-07-08 09:43:09 +02:00
Vincent Bernat
8be1bca4fd
license: AGPL-3.0-only
...
```
git ls-files \*.js \*.go \
| xargs sed -i '1i // SPDX-FileCopyrightText: 2022 Free Mobile\n// SPDX-License-Identifier: AGPL-3.0-only\n'
git ls-files \*.vue \
| xargs sed -i '1i <!-- SPDX-FileCopyrightText: 2022 Free Mobile -->\n<!-- SPDX-License-Identifier: AGPL-3.0-only -->\n'
```
2022-06-29 11:42:28 +02:00
Vincent Bernat
a1ff21eb09
console: ability to display L2 bps in addition to L3 bps
2022-06-03 11:47:38 +02:00
Vincent Bernat
2d4f5214bd
tests: handle JSON in TestHTTPEndpoints
2022-05-26 10:40:55 +02:00
Vincent Bernat
6b6e1b8fba
doc: update with a few words about the console
2022-05-24 22:09:21 +02:00
Vincent Bernat
be444652f0
console: ability to get values in pps instead of bps
2022-05-24 20:34:23 +02:00
Vincent Bernat
eb75dc40ac
console: add 95th percentile
2022-05-24 19:46:41 +02:00
Vincent Bernat
bd3c79c057
console: endpoint for sankey graph
2022-05-22 16:48:36 +02:00
Vincent Bernat
fb7c51653f
console: rely on validator to check input values
2022-05-21 22:47:19 +02:00
Vincent Bernat
375a0fe88f
console: split graph.go into query.go and graph.go
...
We will introduce more query types.
2022-05-21 19:53:08 +02:00
Vincent Bernat
c23e5c1687
console/frontend: use static generated content for fields
...
This is more reliable and efficient but it also remove a bug with
equality comparison failing and thus inability to remove entries.
Also, sorted exactly as we want.
2022-05-18 08:49:03 +02:00
Vincent Bernat
dd64d02b48
console/frontend: better error formatting
2022-05-16 21:45:03 +02:00
Vincent Bernat
44ab2c380c
console: use a parser to parse filter
...
An AST is not that useful for us. We just need to validate and
transform to proper SQL a filter string. Since it is SQL-like, this is
not hard to do.
2022-05-16 18:29:46 +02:00
Vincent Bernat
34f153d9cd
console: dynamically fetch available dimensions
2022-05-16 10:19:53 +02:00
Vincent Bernat
eefd7088b9
console: remove /fields endpoint as we don't use it
2022-05-15 15:24:50 +02:00
Vincent Bernat
04d818e00f
console/frontend: add a selector for dimensions
2022-05-15 15:19:55 +02:00
Vincent Bernat
0258e2bedb
console: rename column to field
2022-05-13 10:44:51 +02:00
Vincent Bernat
eeb6da5730
console: rename max-series to limit
2022-05-12 14:27:18 +02:00
Vincent Bernat
31aca4c73b
console: ensure "Other" is last when returning data
2022-05-12 14:27:18 +02:00
Vincent Bernat
d2cc5f1953
console: ensure we don't return more than max-series
...
We weren't matching only the top series, but any combination of
columns matching the top series. Fix that.
2022-05-12 14:27:18 +02:00
Vincent Bernat
2319262340
console: add visualize tab
...
Currently, there is no controls available.
2022-05-12 14:27:18 +02:00