Skip to content

Commit

Permalink
Stop compacting logs when taking out wm, move to scan
Browse files Browse the repository at this point in the history
  • Loading branch information
mbutlerw committed Aug 16, 2023
1 parent e761d4c commit 8d53a3e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions core/src/main/clojure/xtdb/indexer/live_index.clj
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@
(locking this-table
(let [wm-live-rel (open-wm-live-rel live-rel retain?)
col-types (live-rel->col-types wm-live-rel)
wm-live-trie (.compactLogs ^LiveHashTrie @!transient-trie)]
wm-live-trie @!transient-trie]
(reify ILiveTableWatermark
(columnTypes [_] col-types)
(liveRelation [_] wm-live-rel)
Expand Down Expand Up @@ -177,7 +177,7 @@
(locking this
(let [wm-live-rel (open-wm-live-rel live-rel retain?)
col-types (live-rel->col-types wm-live-rel)
wm-live-trie (.compactLogs live-trie)]
wm-live-trie live-trie]

(reify ILiveTableWatermark
(columnTypes [_] col-types)
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/clojure/xtdb/operator/scan.clj
Original file line number Diff line number Diff line change
Expand Up @@ -508,7 +508,7 @@
(.load loader record-batch)
(.add trie-roots root)))))
(let [hash-tries (cond-> (mapv #(ArrowHashTrie/from %) trie-roots)
live-table-wm (conj (.liveTrie live-table-wm)))]
live-table-wm (conj (.compactLogs (.liveTrie live-table-wm))))]

{:arrow-leaves (mapv (fn [{:keys [leaf-buf leaf-root]}]
(reify AutoCloseable
Expand Down

0 comments on commit 8d53a3e

Please sign in to comment.