Fork me on GitHub
#datomic
<
2015-09-14
>
az18:09:53

Hi all, just started working through the tutorial on datomic, hitting a few road blocks. Any idea how to generate run

gpg --default-recipient-self -e \
    ~/.lein/credentials.clj > ~/.lein/credentials.clj.gpg
I get this error:
Enter the user ID.  End with an empty line: 
gpg: no valid addressees                     
gpg: /Users/Limix/.lein/credentials.clj: encryption failed: no such user id
Thanks

marshall19:09:04

@limix: Do you require automated download of the peer library? If you’re just hoping to get started exploring Datomic, I would suggest skipping the GPG steps, downloading the Datomic Starter zip, and using bin/maven-install to install it into your local maven repo

az19:09:38

Thanks @marshall, will do.

az19:09:18

Hi @marshall, so I created the maven repo, but how do I register that repo with the musicbrainz sample project? I still get the follow error when trying lein repl:

Could not find artifact com.datomic:datomic-pro:jar:0.9.5130 in central ()
Could not find artifact com.datomic:datomic-pro:jar:0.9.5130 in clojars ()
This could be due to a typo in :dependencies or network issues.
If you are behind a proxy, try setting the 'http_proxy' environment variable.
Exception in thread "Thread-3" clojure.lang.ExceptionInfo: Could not resolve dependencies {:suppress-msg true, :exit-code 1}

az19:09:58

Sorry I don’t know much about maven, does something need to be running?

az19:09:40

everything seems to have built correctly after running bin/maven-install:

Installing datomic-pro-0.9.5206 in local maven repository...
[INFO] Scanning for projects...
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building datomic-pro 0.9.5206
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- maven-install-plugin:2.4:install-file (default-cli) @ datomic-pro ---
[INFO] Installing /Users/Limix/Documents/sandbox/datomic/datomic-pro-0.9.5206/datomic-pro-0.9.5206.jar to /Users/Limix/.m2/repository/com/datomic/datomic-pro/0.9.5206/datomic-pro-0.9.5206.jar
[INFO] Installing /Users/Limix/Documents/sandbox/datomic/datomic-pro-0.9.5206/pom.xml to /Users/Limix/.m2/repository/com/datomic/datomic-pro/0.9.5206/datomic-pro-0.9.5206.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.295 s
[INFO] Finished at: 2015-09-14T12:34:20-07:00
[INFO] Final Memory: 7M/289M
[INFO] ————————————————————————————————————

az19:09:31

the project file in the mbrainz sample project:

(defproject com.datomic/mbrainz-sample "0.1.0"
  :description "Example queries and rules for working with the Datomic mbrainz example database."
  :url ""
  :license {:name "Eclipse Public License"
            :url ""}
  :dependencies [[org.clojure/clojure "1.7.0-alpha4"]
                ;  [com.datomic/datomic-free "0.9.5130"]

                 ;; To run on Datomic Pro, comment out the free
                 ;; version above, and enable the pro version below
                [com.datomic/datomic-pro "0.9.5130"]]



  :source-paths ["src/clj" "examples/clj"]
  :jvm-opts ^:replace ["-Xmx2g" "-server"])

marshall19:09:51

@limix: You have a version mismatch - you bin/maven-installed version 0.9.5206 but you have 0.9.5130 in the project.clj file. Update the project.clj to 5206 and you should be good.

az19:09:33

worked!

az19:09:29

details! pay attention 😣

az19:09:36

thank you

az20:09:19

The pull api seems pretty amazing, am I wrong to think this is going to be the go to solution for building a graphdb backend?

az20:09:36

are there other DBs that can shape data like this? Is it plausible to build a system that returns data straight out of datomic via the pull api, and not even have to remold the data at all? Just pass it through to a client?

az20:09:47

with the pull api, is it possible to apply authorization rules to just part of a pattern?

stuartsierra20:09:22

@limix The Pull API describes only the attributes you want to get out. Authorization rules would have be implemented in your application code.

ghadi21:09:29

Does datomic use some sort of delta compression scheme in the indices?