Skip to content
Snippets Groups Projects
Unverified Commit 1be718c5 authored by Walter Leibbrandt's avatar Walter Leibbrandt Committed by GitHub
Browse files

Remove object count from log output (#13823)

`count` caused the lazy `objs` to be realized, causing the entire table
to be scanned. For tables with very high numbers of rows this stalls the
program and effectively eliminates the usefulness of chunking `objs`.

If the count is _really_ that big a deal, it can be determined, in
multiples of `chunk-size`, but counting the number of dots after the log
line, as printed by `insert-chunk!`.
parent 23fe8057
No related branches found
No related tags found
No related merge requests found
......@@ -69,7 +69,7 @@
(throw e))))
(defn- insert-entity! [target-db-conn {table-name :table, entity-name :name} objs]
(print (u/format-color 'blue "Transferring %d instances of %s..." (count objs) entity-name))
(print (u/format-color 'blue "Transferring %s data..." entity-name))
(flush)
;; The connection closes prematurely on occasion when we're inserting thousands of rows at once. Break into
;; smaller chunks so connection stays alive
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment