(enhancer {:keys [db]} {:keys [enhancer-input-chan enhancer-output-chan]})
An enhancer that upserts supplied batches of contexts into the database.
An enhancer that upserts supplied batches of contexts into the database.
(maybe-store-in-db
db
{:keys [name :skyscraper.db/columns :skyscraper.db/key-columns] :as processor}
contexts)
Wraps upsert-context, skipping contexts that contain ::skip.
Wraps upsert-context, skipping contexts that contain ::skip.
(upsert-contexts db table key-columns columns ctxs)
Inserts new contexts into a given db table, returning them augmented
with the :parent
fields corresponding to the DB-generated primary
keys. If key-columns
(a vector of column names) is provided,
does an upsert rather than an insert, checking for conflicts on
those columns and updating db accordingly.
Inserts new contexts into a given db table, returning them augmented with the `:parent` fields corresponding to the DB-generated primary keys. If `key-columns` (a vector of column names) is provided, does an upsert rather than an insert, checking for conflicts on those columns and updating db accordingly.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close