Skip to content

Commit f83c135

Browse files
committed
fix: consistent RCDB URIs
1 parent 8b1cf96 commit f83c135

4 files changed

Lines changed: 8 additions & 8 deletions

File tree

.github/workflows/ci.yml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ defaults:
1212

1313
env:
1414
dataset: ci_test
15-
rcdb_connection: mysql://rcdb@clasdb.jlab.org/rcdb # RCDB server available to runners
1615
# NOTE: if any of these versions are changed, update the POM files too
1716
java_version: 21
1817
java_distribution: zulu
@@ -143,8 +142,6 @@ jobs:
143142
run: ls *.tar.zst | xargs -I{} tar xavf {}
144143
- name: tree
145144
run: tree
146-
- name: set RCDB connection # to one that's available to the runner
147-
run: echo RCDB_CONNECTION=${{env.rcdb_connection}} | tee -a $GITHUB_ENV
148145
- name: run monitoring
149146
run: bin/run-monitoring.sh -d ${{env.dataset}} --findhipo --series --focus-${{matrix.type}} validation_files
150147
- name: tree slurm
@@ -197,8 +194,6 @@ jobs:
197194
run: ls *.tar.zst | xargs -I{} tar xavf {}
198195
- name: tree
199196
run: tree
200-
- name: set RCDB connection # to one that's available to the runner
201-
run: echo RCDB_CONNECTION=${{env.rcdb_connection}} | tee -a $GITHUB_ENV
202197
- name: test monitoring swifjob
203198
run: |
204199
single_rundir=$(find validation_files -mindepth 1 -maxdepth 1 -type d | head -n1)

bin/environ.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ log_config=logging # set to 'logging' for quiet, or to 'debug' for verbose
1212
export TIMELINESRC=$(realpath $(dirname $thisEnv)/..)
1313

1414
# RCDB
15-
[ -z "${RCDB_CONNECTION-}" ] && RCDB_CONNECTION=mysql://rcdb@clasdb-farm.jlab.org/rcdb
15+
[ -z "${RCDB_CONNECTION-}" ] && RCDB_CONNECTION=mysql://rcdb@clasdb.jlab.org/rcdb
1616
export RCDB_CONNECTION
1717

1818
# check coatjava environment

qa-physics/QA/modifyQaTree.groovy

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,10 @@ else if(cmd=="misc") {
247247
if(args.length<5 || args[4]=="all") secList = (1..6).collect{it}
248248
else (4..<args.length).each{ secList<<args[it].toInteger() }
249249

250-
def db = RCDB.createProvider("mysql://rcdb@clasdb/rcdb")
250+
def rcdbURL = System.getenv('RCDB_CONNECTION')
251+
if(rcdbURL==null)
252+
throw new Exception("RCDB_CONNECTION not set")
253+
def db = RCDB.createProvider(rcdbURL)
251254
def shift_expert_comment = null
252255
try {
253256
db.connect()

qa-physics/QA/parseQaTree.groovy

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,9 @@ SQLite : sqlite:////group/clas12/rcdb/example.db
3535
*/
3636

3737
// Open SQL database connection
38-
def address = "mysql://rcdb@clasdb/rcdb"
38+
def address = System.getenv('RCDB_CONNECTION')
39+
if(address==null)
40+
throw new Exception("RCDB_CONNECTION not set")
3941
def db = RCDB.createProvider(address)
4042
def success = false
4143
try { db.connect(); success = true; println("Connected to "+address) }

0 commit comments

Comments
 (0)