aboutsummaryrefslogtreecommitdiff
path: root/src/com/github/ivarref/yoltq/migrate.clj
diff options
context:
space:
mode:
authorIvar Refsdal <refsdal.ivar@gmail.com>2022-03-28 19:56:37 +0200
committerIvar Refsdal <refsdal.ivar@gmail.com>2022-03-28 19:56:37 +0200
commitfc6dbf142005c57623cd1386a576b1fb487ac44a (patch)
treead189d98e2d5777ceb8f27aa4c003073ed3eb4f7 /src/com/github/ivarref/yoltq/migrate.clj
parentRelease 0.2.48 (diff)
downloadfiinha-fc6dbf142005c57623cd1386a576b1fb487ac44a.tar.gz
fiinha-fc6dbf142005c57623cd1386a576b1fb487ac44a.tar.xz
Don't OOM on migrating large datasets. Always prefer user specified value for config, also for `false`/`nil` values.
Diffstat (limited to 'src/com/github/ivarref/yoltq/migrate.clj')
-rw-r--r--src/com/github/ivarref/yoltq/migrate.clj2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/com/github/ivarref/yoltq/migrate.clj b/src/com/github/ivarref/yoltq/migrate.clj
index 89fc286..6313b73 100644
--- a/src/com/github/ivarref/yoltq/migrate.clj
+++ b/src/com/github/ivarref/yoltq/migrate.clj
@@ -47,7 +47,7 @@
(let [tx (to->v2-ent cfg now-ms id)]
@(d/transact conn tx)
(if loop?
- (recur (conj tx-vec tx))
+ (recur (vec (take 10 (conj tx-vec tx))))
tx))
(do
(log/info "No items left to migrate")