mirror of
https://gitlab.cern.ch/wotsubo/PSBoardDataBase.git
synced 2025-06-07 21:45:43 +09:00
update: document on how to make database
- wrt update on slavelogs requirement
This commit is contained in:
parent
29399c094a
commit
a64b8f20e5
1 changed files with 33 additions and 1 deletions
|
@ -14,6 +14,17 @@ Depth = 4
|
|||
このリポジトリにあるのは、JATHub masterのログファイル、及びGoogle SheetsからエクスポートしたCSVファイルからデータベースを作成するためのコードである。
|
||||
メインの関数は[`create_database_from_exported_csvs`](@ref)である。
|
||||
|
||||
!!! info
|
||||
**TLDR**;
|
||||
データベースがほしいときは_Masterのログ_と_Slaveのログ_を用意して、[`create_database_from_exported_csvs`](@ref)
|
||||
```julia
|
||||
create_database_from_exported_csvs(
|
||||
"database_name.db";
|
||||
masterlog_dir = "dir/to/master/logs",
|
||||
slavelog_dir = "dir/to/slave/logs"
|
||||
)
|
||||
```
|
||||
|
||||
## 動かし方
|
||||
[Julia](https://julialang.org)は[juliaup](https://github.com/JuliaLang/juliaup)でインストールする。
|
||||
リポジトリのルート(`Project.toml`がある)で
|
||||
|
@ -33,7 +44,8 @@ backspaceでjulianモードに戻り(左側が`julia>`になってる)、`using
|
|||
# テストについて
|
||||
|
||||
テストでは実際にデータベースを作成している。
|
||||
デフォルトでは全部は実行しないが、master log fileをおき、かつ環境変数`LOCAL_TEST`を設定することで、master log fileが必要な工程まで含めて実行できる。[^1]
|
||||
デフォルトでは全部は実行しないが、master logとslave logをおき、かつ環境変数`LOCAL_TEST`を設定することで、すべての工程を実行できる。[^1]
|
||||
用意するものの詳細は下に書いてある。
|
||||
|
||||
Pkgモード(`]`を押す)で`test`とうつと実行できる。
|
||||
環境変数の設定は`ENV["LOCAL_TEST"] = "1"`とでも書く。
|
||||
|
@ -64,6 +76,26 @@ test/input/
|
|||
...
|
||||
```
|
||||
|
||||
## Slave logを用意する
|
||||
|
||||
同様にJATHub slaveで作られるログも用意する。
|
||||
これはskewを抽出するのに使われる。
|
||||
最悪なくてもいいのでそのときは空のディレクトリを関数に渡す。
|
||||
|
||||
```sh
|
||||
tree -L 2 test/input/slavelogs/ | head -n 10
|
||||
test/input/slavelogs/
|
||||
└── main
|
||||
├── 101_28_longrun.txt
|
||||
├── 101_29.txt
|
||||
├── 101_29_clk.txt
|
||||
├── 103_28_longrun.txt
|
||||
├── 103_29.txt
|
||||
├── 103_29_clk.txt
|
||||
├── 103_89.txt
|
||||
├── 103_89_clk.txt
|
||||
```
|
||||
|
||||
# 新しいQAQCキャンペーン時に更新すべき内容
|
||||
|
||||
- [`PSBoardDataBase.insert_qaqc_campaign_id`](@ref): キャンペーンの日時
|
||||
|
|
Loading…
Add table
Reference in a new issue