This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2015-06-18
Channels
- # admin-announcements (10)
- # boot (260)
- # cider (44)
- # clojure (226)
- # clojure-berlin (24)
- # clojure-dev (68)
- # clojure-germany (5)
- # clojure-india (14)
- # clojure-italy (3)
- # clojure-japan (21)
- # clojure-poland (34)
- # clojure-russia (20)
- # clojure-spain (2)
- # clojure-uk (8)
- # clojurescript (86)
- # core-async (38)
- # core-typed (70)
- # datomic (41)
- # docs (8)
- # editors (7)
- # euroclojure (6)
- # instaparse (2)
- # jobs (8)
- # ldnclj (47)
- # om (17)
- # other-lisps (1)
- # reactive (1)
- # reading-clojure (8)
- # reagent (13)
- # sneer (1)
- # sneer-br (1)
Has anyone encountered datom conflicts after restores? I.e. two entities with the same value for a :db/unique
attribute.
e.g.
(d/q '[:find ?e ?unique-ident
:in $ ?a ?v
:where
[?e ?a ?v]
[?a :db/unique ?unique]
[?unique :db/ident ?unique-ident]]
(d/db (db/connection))
:cat.block/key
"designers22")
->
[[17592187845110 :db.unique/identity]
,[17592189560149 :db.unique/identity]]
i'm pretty sure it's a real conflict, as when I try to retract the entity I get a two datoms conflict
error.
restores are a bit funny aren't they? I noticed yesterday that datomic will still do a differential restore even if I've delete-database
'd the target db
FYI in my case it this was due to trying to restore on divergent dbs (the target had some transactions that were not in the source)
if I really want to guarantee i've got two identical databases after a restore (like if I want my staging env to match prod exactly), I think I'd have to clean out everything related to my target db in the storage layer. does anyone have a decent way to do that in dynamo besides deleting the table? I've got several database in my dynamo table, but the raw data just looks like gibberish to me.
There is no "differential restore"
Restore always starts from an empty database.
"starts from an empty database" and "only copies when necessary" sound like conflicting statements to me?
but, as jthomson mentioned above, if you have a divergent DB, restoring to that existing DB is not supported
right, so if I have DBs that have diverged, and I want to resolve that, what do I do?
basically I want to force prod -> staging while ignoring anything from staging that has diverged
So I guess this means use a different name? Thinking about it in my case (which was actually the same use case @kbaribeau) I had deleted the old DB but reused the name, thinking this would create a new db.
see the bottom of this page: http://docs.datomic.com/capacity.html
yep, different name won't work because db has unique id that will report conflict if you try to restore same db to different name in the same datomic storage (i.e. into the same bucket/table, w/e)
Datomic 0.9.5186 has been released: https://groups.google.com/forum/#!topic/datomic/IGzjBbHr10E
curious about this, "* Fixed bug in Pull API when using selectors built from strings."