This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-09-22
Channels
- # beginners (104)
- # bitcoin (1)
- # boot (5)
- # clara (3)
- # cljs-dev (14)
- # cljsjs (5)
- # cljsrn (1)
- # clojure (242)
- # clojure-italy (17)
- # clojure-news (13)
- # clojure-norway (3)
- # clojure-russia (101)
- # clojure-spec (41)
- # clojure-uk (87)
- # clojurescript (38)
- # core-async (38)
- # cursive (6)
- # datomic (11)
- # defnpodcast (3)
- # docs (14)
- # editors (8)
- # events (1)
- # fulcro (7)
- # hoplon (25)
- # leiningen (4)
- # luminus (7)
- # off-topic (25)
- # onyx (1)
- # portkey (14)
- # random (1)
- # re-frame (7)
- # reagent (4)
- # rum (4)
- # schema (8)
- # shadow-cljs (257)
- # spacemacs (10)
- # specter (4)
- # unrepl (3)
- # yada (1)
@alandipert ok, more info, i've refactored the filtered db out of my critical performance path, but i still wouldn't say that equality checking a datascript db is fast
ah, i tried to upload a profiler screenshot but slack wouldn't let me š
well, it appears to be adding ~13ms to my propagation
which is happening on keypress
doesn't leave me much wiggle room before things get janky
i do like the idea of being able to use something other than =
for cell propagation
in this case i could simply assign a new UUID to the metadata of the datascript conn each time i transact to it, and propagate whenever that changes, rather than having it scan the whole db for equality every time
it could also potentially open up alternate solutions to https://github.com/hoplon/hoplon/issues/194
actually, i think in both cases an "unconditional propagation" flag would be enough
the equality checking is slow for dbs and broken for sorting read/write dom elements, so why not skip it?
but i suppose that's a special case of the more generalised control you'd get if you could set your own function
not sure about your db-cell use case though @thedavidmeister - what is the cell graph so that db gets triggered o keypress?
i transact the user's input from a text field into the db
but seems like the very first thing javelin does is tries to see if the value of the db is the same as it was before the transaction
which it never is, but the equality check has to scan through all the datoms in the db to find that out
based on my rather unscientific profiling this check seems to take ~5-15ms and seems unavoidable because if i try to transact on a timeout or something then i get weird bugs in the UI, like FOUCs, etc.