[ANN] 1.22.1 is out now!

1.22.1 is now available. This is a non-breaking release, it contains new valid-time predicates and a few bug fixes.

;; lein 
[com.xtdb/xtdb-core "1.22.1"]
;; deps.edn 
com.xtdb/xtdb-core {:mvn/version "1.22.1"}

New temporal query predicates

#1811 Adds the get-start-valid-time, get-end-valid-time query predicates.
These are useful to work with the start/end valid time values of an entity during query.

Here is an example illustrating how you might use these predicates to ask new kinds of temporal question with datalog:

(with-open [node (xt/start-node {})]
  ;; bob likes pizza on the 27th, claire likes cake.
  (->> [[::xt/put {:xt/id "bob", :favorite "pizza"} #inst "2022-09-27"]
        [::xt/put {:xt/id "claire", :favorite "cake"} #inst "2022-09-27"]]
       (xt/submit-tx node))
  
  ;; bob will change his mind about his favorite food on the 28th.
  (->> [[::xt/put {:xt/id "bob", :favorite "pasta"} #inst "2022-09-28"]]
       (xt/submit-tx node))
  
  (xt/sync node)

  ;; on the 27th, what was everyone's favorite food
  ;; and when will they change their mind?
  (xt/q
    (xt/db node {::xt/valid-time #inst "2022-09-27"})
    '{:find [?e, ?food, ?until]
      :where [[?e :favorite ?food] 
              [(get-end-valid-time ?e) ?until]]}))

thanks @FiV0!

Bug fixes

  • #1832 LMDB locking policy made fairer to writers, removed possibility of heavy query load causing ingester timeout. Thanks @tatut for assisting the diagnosis of the issue.
  • #1833 Fix documents added by transaction functions not providing attribute statistics, Thanks @tatut for the bug report.
  • #1827 Fix class cast exception on external merge sort, thanks again to @FiV0.

Thanks to all who raised issues, tested or otherwise contributed to this release :pray: .

Cheers,

XT Team

1 Like