Skip to content

Commit

Permalink
Fixed DB creation code
Browse files Browse the repository at this point in the history
  • Loading branch information
qvad committed Feb 14, 2024
1 parent b25fff1 commit aea597b
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions yugabyte/src/yugabyte/auto.clj
Original file line number Diff line number Diff line change
Expand Up @@ -532,10 +532,12 @@
db/Primary
(setup-primary! [this test node]
"Executed once on a first node in list (i.e. n1 by default) after per-node setup is done"
(let [colocated-clause (if (:yb-colocated test)
" WITH colocated = true"
"")]
(ysqlsh test :-h (cn/ip node) :-c (str "CREATE DATABASE jepsen" colocated-clause ";")))
(if (= (:api test) :ysql)
(let [colocated-clause (if (:yb-colocated test)
" WITH colocated = true"
"")]
(ysqlsh test :-h (cn/ip node) :-c (str "DROP DATABASE IF EXISTS jepsen;"))
(ysqlsh test :-h (cn/ip node) :-c (str "CREATE DATABASE jepsen" colocated-clause ";"))))
)

db/LogFiles
Expand Down

0 comments on commit aea597b

Please sign in to comment.