summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2025-12-03 18:19:40 -0300
committerEuAndreh <eu@euandre.org>2025-12-03 18:19:42 -0300
commite98077a139aa319c5335a8d3b2477c9d63604189 (patch)
tree7d8eab7543de3f0355a86444129a93fa4287414f /bin
parentbin/transactor.in: Less verbose output (diff)
downloaddatomic-e98077a139aa319c5335a8d3b2477c9d63604189.tar.gz
datomic-e98077a139aa319c5335a8d3b2477c9d63604189.tar.xz
Disable valcache for transactor
Given that the transactor will run on top of SQLite, its disk IO for reads when accessing the valcache is replaced by SQLite itself. In this topology, we don't get any upside on enabling valcache for the transactor, and even loose performance due to the cache IO competing with the database IO. Peers can enable the valcache for themselves, if desired.
Diffstat (limited to 'bin')
-rwxr-xr-xbin/transactor.in20
1 files changed, 1 insertions, 19 deletions
diff --git a/bin/transactor.in b/bin/transactor.in
index 918135d..1e99727 100755
--- a/bin/transactor.in
+++ b/bin/transactor.in
@@ -11,21 +11,13 @@ usage() {
-VALCACHESIZE=
PORT=50200
-CACHEDIR='cache'
TEMPDATADIR='tmp'
-while getopts 'p:C:S:T:' flag; do
+while getopts 'p:T:' flag; do
case "$flag" in
(p)
PORT="$OPTARG"
;;
- (C)
- CACHEDIR="$OPTARG"
- ;;
- (S)
- VALCACHESIZE="$OPTARG"
- ;;
(T)
TEMPDATADIR="$OPTARG"
;;
@@ -46,14 +38,6 @@ FILE="$1"
-if [ -z "$VALCACHESIZE" ]; then
- VALCACHESIZE="$(
- df -Pk -- "$(dirname -- "$FILE")" |
- tail -n1 |
- awk '{printf "%.0f\n", $2 / (1024 * 1024)}'
- )"
-fi
-
sqlite3 "$FILE" < @SYSCONFDIR@/init.sql > /dev/null
exec java \
@@ -70,8 +54,6 @@ exec java \
sed \
-e "s|@PORT@|$PORT|g" \
-e "s|@FILE@|$FILE|g" \
- -e "s|@CACHEDIR@|$CACHEDIR|g" \
-e "s|@TEMPDATADIR@|$TEMPDATADIR|g" \
- -e "s|@VALCACHESIZE@|$VALCACHESIZE|g" \
@SYSCONFDIR@/transactor.properties.tmpl
)