This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-01-09
Channels
- # announcements (1)
- # atlanta-clojurians (1)
- # beginners (198)
- # calva (4)
- # cider (16)
- # clara (8)
- # cljs-dev (14)
- # cljsrn (4)
- # clojure (204)
- # clojure-europe (3)
- # clojure-gamedev (2)
- # clojure-italy (8)
- # clojure-nl (17)
- # clojure-poland (3)
- # clojure-russia (20)
- # clojure-spec (32)
- # clojure-uk (45)
- # clojurescript (59)
- # community-development (1)
- # core-async (25)
- # cursive (20)
- # datomic (47)
- # emacs (7)
- # fulcro (8)
- # iot (1)
- # iotivity (2)
- # jobs (1)
- # jobs-discuss (8)
- # juxt (11)
- # luminus (5)
- # nrepl (4)
- # off-topic (136)
- # onyx (24)
- # other-lisps (1)
- # parinfer (74)
- # pedestal (1)
- # planck (3)
- # portkey (67)
- # random (1)
- # re-frame (28)
- # reagent (11)
- # reitit (9)
- # remote-jobs (3)
- # ring-swagger (2)
- # rum (3)
- # shadow-cljs (96)
- # slack-help (3)
- # spacemacs (6)
- # tools-deps (3)
- # unrepl (1)
- # vim (4)
I have a datalog query that returns 10e6 rows.
I wish to process these lazily
I've been using the sample
datalog function to work on subsets of data at a time
but now I'm timing how long the sample takes and I'm not sure its any faster than a simple (take 256 (d/q ...)
its not any faster
I was attempting to adhere to https://docs.datomic.com/on-prem/best-practices.html#prefer-query_
but now I've tried the datalog approach
I shall get down and dirty with the datoms
yeah q is generally what you want to start with, but in your case, sounds like just traversing one of the indicies might make more sense. Are you using on-prem or cloud? If it’s the former, you can say filter the db, then grab your datoms
on-prem
ooh I hadn't considered doing that. interesting
Hi. I have problemy with my query: https://pastebin.com/bGRMKfxm it is really small. The error is: Caused by: java.lang.ClassCastException: mount.core.DerefableState cannot be cast to datomic.Connection I don't understand what is wrong with that. Any help? I am using datomic with Luminus framework.
you are passing something unexpected as the parameter conn
?
it needs to be a datomic.Connection
but it is getting a mount.core.DerefableState
whatever that is
oh its probably a system state, isn't it
so you would need to pluck your datomic Connection value out of the mount Derefable state
Hi friends, when reading the docs (https://docs.datomic.com/cloud/ions/ions-reference.html#parameters-example) it states NOTE The datomic-shared prefix is readable by any Datomic system. If you want more granular permissions, you can choose your own naming convention (under a different prefix!), and explicitly add permissions to the IAM policy for your Datomic nodes.
Does this mean any datomic system in my aws account or truly that a different org has access to whatever I put under that prefix?
"Statement": [
{
"Effect": "Allow",
"Action": [
"ssm:GetParametersByPath"
],
"Resource": [
"arn:aws:ssm:us-east-1:879742242852:parameter/datomic-shared/*"
],
"Sid": "DatomicSharedParameters"
}
]
and if you look at the <stack-name>-<region> IAM role you’ll see a similar permission ^ under get-parameters
"Statement": [
{
"Action": [
"ssm:GetParametersByPath"
],
"Resource": [
"arn:aws:ssm:us-east-1:879742242852:parameter/datomic-shared/*"
],
"Effect": "Allow"
}
]
I'm attempting to work through the Datomic on-prem tutorial here: https://docs.datomic.com/on-prem/tutorial.html. The example of d/transact
throws a ClassCastException for me:
(d/transact
conn
{:tx-data [{:db/ident :red}
{:db/ident :green}
{:db/ident :blue}
{:db/ident :yellow}]})
If I get rid of the containing map and the :tx-data
and just pass the vector of idents, it seems to work as expected. Am I misunderstanding something?that tutorial seems wrong to me
unless there’s some newer datomic om-prem API that accepts a map instead of tx data
I’m running ‘0.9.5561.50’ and I get the same ClassCastException
I think that must be a copy/paste error from a tutorial written for the client API https://docs.datomic.com/client-api/datomic.client.api.html
a similar walkthrough for using the peer API can be found here: https://docs.datomic.com/on-prem/peer-getting-started.html
the confusion probably came from the URL which contains “on-prem” https://docs.datomic.com/on-prem/tutorial.html
ooh, didn’t know that 🙂