This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-10-26
Channels
- # announcements (17)
- # babashka (68)
- # beginners (8)
- # biff (14)
- # calva (25)
- # cherry (10)
- # clj-kondo (1)
- # clj-on-windows (12)
- # cljsrn (6)
- # clojure (134)
- # clojure-berlin (1)
- # clojure-europe (33)
- # clojure-nl (4)
- # clojure-norway (6)
- # clojure-uk (10)
- # clojurescript (9)
- # datalevin (8)
- # datomic (34)
- # docker (1)
- # emacs (31)
- # fulcro (6)
- # honeysql (8)
- # java (7)
- # joyride (14)
- # kaocha (7)
- # malli (11)
- # nbb (4)
- # off-topic (11)
- # pedestal (14)
- # rdf (53)
- # re-frame (6)
- # reagent (39)
- # reitit (2)
- # releases (9)
- # rewrite-clj (14)
- # shadow-cljs (97)
- # specter (1)
- # testing (5)
- # tools-deps (12)
- # vim (4)
- # xtdb (9)
is it possible to add :db/unique :db.unique/identity
to a schema that's already in the DB? when i do i get errors related to index
if you are on on-prem and the attribute does not have a value index yet, you need to add one first so it can verify uniqness
https://docs.datomic.com/on-prem/schema/schema-change.html#adding-avet-index that should be good enough?
yes. Note this section https://docs.datomic.com/on-prem/schema/schema-change.html#altering-attribute-to-unique > In order to add a unique constraint to an attribute, Datomic must already be maintaining an AVET index on the attribute, or the attribute must have never had any values asserted. Furthemore, if there are values present for that attribute, they must be unique in the set of current assertions. If either of these constraints are not met, the alteration will not be accepted and the transaction will fail.
(I”m assuming through all of this that you are using on-prem--if you are using cloud you may have a different problem)
Is it possible to fetch just the datomic-transactor-pro-<version>.jar from my.datomic ?
for reference, for datomic-pro (and the other deps) this just works: wget --http-user=$DATOMIC_REPO_USER --http-password=$DATOMIC_REPO_PASS
context: we need to bump the postgresql adapter to something recent so we can use modern password strategies (iirc). We run datomic on Nomad (i.e. in a docker container) and built our own.
We need to include some jars in the installation anyway for prometheus metrics and custom database functions.
currently we fetch a datomic installation, manually fetch a bunch of jars to update and replace them in ./lib
.
We figured we could just write a pom.xml to ‘bump’ the postgres dependencies and include our own, and simply switch to jib
to built the Dockerfile. But we hit a snag here because we can’t actually fetch the datomic-transctor-pro jar.
how can you confidently write a pom.xml that accurately reflects everything a datomic transactor needs?
and this is even being 90% sure that most of the bytes in lib are just transient-deps of requiring the entire aws sdk and are not used.
And refer to it in my own pom, using managed deps to make sure i get the deps i want
Are you referring to the pom.xml in the root of the zip? That appears to be for the client (note the artifactId).
I just hoped it would be available to pull from my.datomic 😁, orherwise well have to do the unpacking and lib patching, but it started to grow too big for my liking,
Hi Cognitect, we might have found a disparity between Client API's pull
and dev-local's pull
.
(d/pull db '[*] nil) ; eid arg is nil, what happens next?
• dev-local's pull
accepts a nil
eid
and makes this pull return nil
.
• cloud's pull
raises an exception about the nil
eid
.
Might we have a dev-local behavior identical to the cloud for this, please?Now, I'm sure Cognitect will tell me I forgot something obvious... 😬
forum or ask?
You asked, https://ask.datomic.com/index.php/790/is-there-disparity-in-d-pull-between-dev-local-and-client-api. Thanks @U050ECB92. :)
I think there is a mistake in this documentation: https://docs.datomic.com/on-prem/overview/architecture.html. The bullet points under the “Peer Server” and “Transactor” headings are identical (I believe they describe transactors, not peer servers.)
I think I see what we did there. An org mode error. The section is missing the following bullet points:
The ${Peer} server is a JVM process that provides an interface for the Datomic Client library.
- Accepts queries and ${transaction}s from Datomic Clients
- Submits transactions to, and accepts changes from, the ${transactor}
- Provides data access, caching, and ${query} capability to connected Clients, reading from the ${storage service} as needed
I saw your first question before you deleted it. I just wanted to add that while there is currently no way (api or other tooling) to heat up a new cache you can use a shared memcached for transactor and multiple peers. This pattern enables new peers to have some relevant information ready in the shared cache. Particularly useful if you have a dedicated peer walking the indexes or a reporting type peer process that might touch all data. I am happy to answer more questions about caching in Datomic if you have a need. <mailto:[email protected]|[email protected]> or DM me.