-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add HLL support in 'calc_metric' tool
Signed-off-by: Łukasz Gryglicki <[email protected]>
- Loading branch information
1 parent
c685d55
commit 206a34d
Showing
7 changed files
with
534 additions
and
186 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#!/bin/bash | ||
# on k8s node-0: 'k exec -n devstats-prod devstats-postgres-0 -- pg_dump tuf > tuf.dump' | ||
# sftp root@node-0: 'mget tuf.dump' | ||
# here: 'PGPASSWORD=[redacted] createdb -Ugha_admin -hlocalhost -p5432 tuf' | ||
# here: 'PGPASSWORD=[redacted] psql -Ugha_admin -hlocalhost -p5432 tuf < tuf.dump' | ||
if [ -z "${PG_PASS}" ] | ||
then | ||
echo "$0: you must specify PG_PASS=..." | ||
exit 1 | ||
fi | ||
make fmt && make calc_metric || exit 2 | ||
cd ../devstats || exit 3 | ||
# GHA2DB_ENABLE_METRICS_DROP=1 PG_DB=tuf GHA2DB_PROJECT=tuf GHA2DB_QOUT=1 GHA2DB_DEBUG=2 GHA2DB_SQLDEBUG=1 GHA2DB_LOCAL=1 GHA2DB_ST=1 GHA2DB_NCPUS=1 ../devstatscode/calc_metric events_hll ./events_hll.sql '2024-01-01 0' '2024-10-01 0' w 'skip_past,hll' | ||
# GHA2DB_ENABLE_METRICS_DROP=1 PG_DB=tuf GHA2DB_PROJECT=tuf GHA2DB_QOUT=1 GHA2DB_DEBUG=2 GHA2DB_SQLDEBUG=1 GHA2DB_LOCAL=1 ../devstatscode/calc_metric multi_row_multi_column ./metrics/shared/project_countries.sql '2024-01-01 0' '2024-01-01 0' q 'multivalue,hll,merge_series:prjcntr,drop:sprjcntr' > ../devstatscode/out @>&1 | ||
# GHA2DB_ENABLE_METRICS_DROP=1 PG_DB=tuf GHA2DB_PROJECT=tuf GHA2DB_QOUT=1 GHA2DB_DEBUG=2 GHA2DB_SQLDEBUG=1 GHA2DB_LOCAL=1 GHA2DB_ST=1 GHA2DB_NCPUS=1 ../devstatscode/calc_metric multi_row_multi_column ./metrics/shared/project_countries.sql '2024-01-01 0' '2024-10-01 0' q 'multivalue,hll,merge_series:prjcntr,drop:sprjcntr' | ||
GHA2DB_ENABLE_METRICS_DROP=1 PG_DB=tuf GHA2DB_PROJECT=tuf GHA2DB_LOCAL=1 ../devstatscode/calc_metric multi_row_multi_column ./metrics/shared/project_countries.sql '2024-01-01 0' '2024-10-01 0' w 'multivalue,hll,merge_series:prjcntr,drop:sprjcntr' |
Oops, something went wrong.