<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
<channel>
<title>Datomic Knowledgebase - Questions without answers in Datomic</title>
<link>https://ask.datomic.com/index.php/unanswered/datomic</link>
<description>Powered by Question2Answer</description>
<item>
<title>Using a collection of datoms as input to a query</title>
<link>https://ask.datomic.com/index.php/1089/using-a-collection-of-datoms-as-input-to-a-query</link>
<description>&lt;p&gt;I was wondering if there is a way to use a collection of datoms obtained from &lt;code&gt;d/tx-range + get a single tx&lt;/code&gt; or received from a listener that subscribed to a tx queue as input to &lt;code&gt; d/q&lt;/code&gt;? The nature of this collection looks very similar to history db which can be used with &lt;code&gt;d/q&lt;/code&gt;, however passing this collection as input does not produce the expected result. Neither there is any error.&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/1089/using-a-collection-of-datoms-as-input-to-a-query</guid>
<pubDate>Thu, 24 Apr 2025 12:51:36 +0000</pubDate>
</item>
<item>
<title>Using Valcache via Docker bind mounts</title>
<link>https://ask.datomic.com/index.php/1012/using-valcache-via-docker-bind-mounts</link>
<description>&lt;p&gt;I&#039;m evaluating caching options for Datomic Pro. Valcache sounds like a great fit, but there is one thing that might be a showstopper.&lt;/p&gt;
&lt;p&gt;The &lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.datomic.com/pro/operation/valcache.html#prerequisites&quot;&gt;Prerequisites docs&lt;/a&gt; says that &quot;Valcache relies on an SSD with the strictatime and lazytime flags set&quot;. This requirement I can meet pretty easily by remounting the disk on the hosts running the peers.&lt;/p&gt;
&lt;p&gt;Now, the applications that are Datomic peers, who would be the users of these Valcaches, run as Docker containers in a Docker Swarm. The idea is to mount the Valcache as a &lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.docker.com/storage/bind-mounts/&quot;&gt;Docker bind mount&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Would this work? The underlaying SSD disk would be mounted with strictatime and lazytime, but would whatever mechanism that requires these flags to be set work through a Docker bind mount?&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/1012/using-valcache-via-docker-bind-mounts</guid>
<pubDate>Thu, 11 Apr 2024 09:50:54 +0000</pubDate>
</item>
<item>
<title>Possibly security issue with the dev H2 storage?</title>
<link>https://ask.datomic.com/index.php/1003/possibly-security-issue-with-the-dev-h2-storage</link>
<description>&lt;p&gt;While trying to understand more about the behaviour of Datomic dev (mainly from a security/encryption point of view), I attempted to connect to datomic.mv.db from an instance of the H2 console. I accidentally tried to log in as &quot;admin&quot; with a blank password and was surprised when I connected successfully. Connecting as &quot;admin&quot; with any password fails, so it seems explicitly to be blank. As far as I can tell I only have public  schema access and can&#039;t see any transacted data, but I am able to run SQL queries in the console.&lt;/p&gt;
&lt;p&gt;Clearly a dev transactor isn&#039;t intended to be high security, but admin with a blank password seems risky even for a dev environment. In most SQL environments I work with, the sa/admin account is just disabled if not used. Am I missing something?&lt;/p&gt;
&lt;p&gt;As an aside, does the dev transactor use H2&#039;s AES encryption or is the resulting data file unencrypted?&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/1003/possibly-security-issue-with-the-dev-h2-storage</guid>
<pubDate>Wed, 13 Mar 2024 21:58:26 +0000</pubDate>
</item>
<item>
<title>Is `(pull $db2 ?e [*])` supported officially?</title>
<link>https://ask.datomic.com/index.php/937/is-pull-db2-e-supported-officially</link>
<description>&lt;p&gt;The &lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.datomic.com/cloud/query/query-data-reference.html?search=p#pull-expressions&quot;&gt;documentation&lt;/a&gt; only mentions the syntax without a &lt;code&gt;src-var&lt;/code&gt;:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;pull-expr                  = [&#039;pull&#039; variable pattern]&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;but found that this syntax also works:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;pull-expr                  = [&#039;pull&#039; src-var variable pattern]&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I have a self-contained code example here, which demonstrates a use-case, where an entity is split between 2 Datomic databases, for privacy reasons:&lt;/p&gt;
&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://forum.datomic.com/t/pull-db-entity-pattern-is-undocumented/2299&quot;&gt;https://forum.datomic.com/t/pull-db-entity-pattern-is-undocumented/2299&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Is this variant of the &lt;code&gt;pull-expr&lt;/code&gt; in Datalog queries are not supported officially?&lt;/p&gt;
&lt;p&gt;Should I use it in production or does it have some undefined behaviour, compared to its binary arity variant?&lt;/p&gt;
&lt;p&gt;Or the documentation is just incomplete?&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/937/is-pull-db2-e-supported-officially</guid>
<pubDate>Sat, 15 Jul 2023 04:42:45 +0000</pubDate>
</item>
<item>
<title>Datomic Cloud IAM role drift on setup - is this normal?</title>
<link>https://ask.datomic.com/index.php/935/datomic-cloud-iam-role-drift-on-setup-is-this-normal</link>
<description>&lt;p&gt;hi, just set up DC for the first time (ran the two AWS cloudformation templates). The storage stack is showing drift on the IAM managed policy &lt;code&gt;datomic-admin-...&lt;/code&gt;, shows &#039;MODIFIED&#039;, in red. Is this normal upon setup? (checking the changes in the &#039;versions&#039; tab, the difference is addition of autoscaling and s3 actions to the policy; the second version, presumably causing the &#039;drift&#039;, was added during the provisioning). Is this just a setup artifact nothing to worry about? &lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/935/datomic-cloud-iam-role-drift-on-setup-is-this-normal</guid>
<pubDate>Wed, 12 Jul 2023 09:34:33 +0000</pubDate>
</item>
<item>
<title>Request Entity Too Large - clojure.lang.ExceptionInfo: Response body did not conform to Datomic client protocol</title>
<link>https://ask.datomic.com/index.php/882/request-clojure-exceptioninfo-response-conform-protocol</link>
<description>&lt;p&gt;There seems to be a bug in Datomic 990-9202 that breaks the d/tx-range function.&lt;/p&gt;
&lt;p&gt;Earlier I could use the tx-range function the fetch data from my database.&lt;/p&gt;
&lt;p&gt;But after upgrading to Datomic 990-9202 I get and exception when a transaction has too much data. &lt;/p&gt;
&lt;p&gt;&lt;code&gt;`&lt;/code&gt;&lt;br&gt;
clojure.lang.ExceptionInfo: Response body did not conform to Datomic client protocol&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;cognitect.anomalies/category: :cognitect.anomalies/incorrect
 cognitect.anomalies/message: &quot;Response body did not conform to Datomic client protocol&quot;
                 http-result: {:status 413,
                               :headers
                               {&quot;apigw-requestid&quot; &quot;Vg4UxisCDoEEJsQ=&quot;,
                                &quot;server&quot; &quot;Jetty(9.4.44.v20210927)&quot;,
                                &quot;connection&quot; &quot;keep-alive&quot;,
                                &quot;content-length&quot; &quot;38&quot;,
                                &quot;date&quot; &quot;Tue, 19 Jul 2022 12:17:47 GMT&quot;,
                                &quot;content-type&quot; &quot;application/json&quot;},
                               :body &quot;{\&quot;message\&quot;:\&quot;Request Entity Too Large\&quot;}&quot;}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;code&gt;`&lt;/code&gt;&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/882/request-clojure-exceptioninfo-response-conform-protocol</guid>
<pubDate>Tue, 21 Mar 2023 12:26:20 +0000</pubDate>
</item>
<item>
<title>Is it possible for Datomic On-prem to get the storage credentials from Secrets Manager or similar software?</title>
<link>https://ask.datomic.com/index.php/873/possible-datomic-storage-credentials-secrets-manager-software</link>
<description>&lt;p&gt;Is there a way to run the transactor service without storing the credentials to disk?&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/873/possible-datomic-storage-credentials-secrets-manager-software</guid>
<pubDate>Thu, 02 Mar 2023 10:50:19 +0000</pubDate>
</item>
<item>
<title>What&#039;s the state of the art in distributed Datomic?</title>
<link>https://ask.datomic.com/index.php/863/whats-the-state-of-the-art-in-distributed-datomic</link>
<description>&lt;p&gt;I&#039;d like to get an idea of the state of the art in distributed Datomic.  FWIW, my wish list includes the ability for selected processing nodes to have local images and/or participate in federated global images, linked by CRDTs, etc. And a pony.&lt;/p&gt;
&lt;p&gt;-r&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/863/whats-the-state-of-the-art-in-distributed-datomic</guid>
<pubDate>Sun, 18 Dec 2022 00:37:33 +0000</pubDate>
</item>
<item>
<title>Querying 2000+ entities, by passing in uuids (Really slow)</title>
<link>https://ask.datomic.com/index.php/862/querying-2000-entities-by-passing-in-uuids-really-slow</link>
<description>&lt;p&gt;Passing in over 2000 uuids to mysql for a fairly simple query takes milliseconds to retrieve relevant data. However we&#039;re running into an issue with datomic where it takes noticeable longer. Is there a specific syntax to use when processing such long lists, or is the linked example the only way? &lt;/p&gt;
&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.datomic.com/on-prem/query/query.html#collection-binding&quot;&gt;https://docs.datomic.com/on-prem/query/query.html#collection-binding&lt;/a&gt;&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/862/querying-2000-entities-by-passing-in-uuids-really-slow</guid>
<pubDate>Wed, 14 Dec 2022 09:24:29 +0000</pubDate>
</item>
<item>
<title>Inconsistency between d/pull and d/q + pull for non-existent entities</title>
<link>https://ask.datomic.com/index.php/860/inconsistency-between-pull-and-pull-for-existent-entities</link>
<description>&lt;p&gt;Inconsistency between d/pull and d/q + pull for non-existent entities&lt;/p&gt;
&lt;p&gt;Datomic returns a map with the &lt;code&gt;:db/id&lt;/code&gt; of the entity being pulled, even if the entity doesn&#039;t exist in the database. For example:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(d/pull (d/db conn) &#039;[*] 9999999999)
=&amp;gt; #:db{:id 9999999999}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This behavior is somewhat confusing, especially when using &lt;code&gt;d/pull&lt;/code&gt; with time filters. I was expecting &lt;code&gt;d/pull&lt;/code&gt; to return &lt;code&gt;nil&lt;/code&gt; or &lt;code&gt;#:db{:id nil}&lt;/code&gt; if the entity wasn&#039;t created at the given point in time. However, Datomic always returns a map with the entity ID:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(d/pull (as-of (d/db conn) 1) &#039;[*] 9999999999)
=&amp;gt; #:db{:id 9999999999}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Surprisingly, I see the expected behavior if I pull the entity information from a query using &lt;code&gt;d/q&lt;/code&gt;:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(d/q &#039;{:find [(pull ?e [*])]
        :in   [?e]}
      (d/db conn) 9999999999)
=&amp;gt; [[#:db{:id nil}]]
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Is that difference in behavior expected? How can I determine if an entity existed at any point in time using &lt;code&gt;d/pull&lt;/code&gt;?&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/860/inconsistency-between-pull-and-pull-for-existent-entities</guid>
<pubDate>Sat, 10 Dec 2022 15:55:29 +0000</pubDate>
</item>
<item>
<title>How do you add relationship properties, e.g. the time a person met another person?</title>
<link>https://ask.datomic.com/index.php/854/how-you-relationship-properties-time-person-another-person</link>
<description>&lt;p&gt;I have some experience with Neo4j / cypher. In cypher relationships are first-class citizens, so they can have properties, which I really like.&lt;/p&gt;
&lt;p&gt;How do I do something similar with datalog? Do I have to have a &quot;mapping entity&quot; in between two entities that have a relationship?&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/854/how-you-relationship-properties-time-person-another-person</guid>
<pubDate>Mon, 07 Nov 2022 08:35:28 +0000</pubDate>
</item>
<item>
<title>Is using entid function to resolve lookup refs a supported behaviour?</title>
<link>https://ask.datomic.com/index.php/721/using-entid-function-resolve-lookup-refs-supported-behaviour</link>
<description>&lt;p&gt;I&#039;m using &lt;code&gt;datomic.api/entid&lt;/code&gt; to resolve a lookup ref to an entity ID, like&lt;br&gt;
&lt;code&gt;$ (entid db [:user/id &quot;test@test.com&quot;])
17592186045432&lt;/code&gt;&lt;br&gt;
This works fine, but a colleague pointed out this is not a documented behaviour.&lt;br&gt;
&amp;gt;Usage: (entid db ident)&lt;br&gt;
&amp;gt;Returns the entity id associated with a symbolic keyword, or the id&lt;br&gt;
itself if passed.&lt;/p&gt;
&lt;p&gt;Is this a gap in documentation, or is this behaviour accidental and not recommended to rely on?&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/721/using-entid-function-resolve-lookup-refs-supported-behaviour</guid>
<pubDate>Wed, 08 Jun 2022 13:30:29 +0000</pubDate>
</item>
<item>
<title>Notifying clients of database changes in Datomic Cloud?</title>
<link>https://ask.datomic.com/index.php/719/notifying-clients-of-database-changes-in-datomic-cloud</link>
<description>&lt;p&gt;In your 2013 blog post &lt;a rel=&quot;nofollow&quot; href=&quot;https://blog.datomic.com/2013/10/the-transaction-report-queue.html&quot;&gt;The Transaction Report Queue&lt;/a&gt;, you write:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;In Datomic, you can monitor all transactions.  Any peer process in the&lt;br&gt;
system can request a transaction report queue of every transaction&lt;br&gt;
against a particular database.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Is there a change data capture or related mechanism in Datomic Cloud, where changes to the database can be pushed to a client?&lt;/p&gt;
&lt;p&gt;Thank you,&lt;/p&gt;
&lt;p&gt;Andrew&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/719/notifying-clients-of-database-changes-in-datomic-cloud</guid>
<pubDate>Sat, 04 Jun 2022 15:18:15 +0000</pubDate>
</item>
<item>
<title>Retracting entities, including tuples with refs</title>
<link>https://ask.datomic.com/index.php/660/retracting-entities-including-tuples-with-refs</link>
<description>&lt;p&gt;In my schema I have attributes of type tuple that has :db.type/ref as one of the tuple&#039;s types.&lt;br&gt;
My usecase is maintaining a set of ordered to-many relations.&lt;/p&gt;
&lt;p&gt;When I retract an entity using :db/retractEntity, the tuple attrs that refer to the retracted entity still remain, continuing to refer to a now non-existent entity.&lt;br&gt;
I&#039;m not sure whether this is the intended behaviour, and if so, what would be a standard approach to clean up these tuples? My intention would be for these tuples to be completely redacted. As I&#039;m using this in a cardinality-many setup, I&#039;d expect the attribute to retain all tuple values, except the one that does include the ref to the retracted entity in any position.&lt;br&gt;
Should I be writing a custom retractEntity-like transaction function?&lt;br&gt;
Thanks!&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/660/retracting-entities-including-tuples-with-refs</guid>
<pubDate>Tue, 31 Aug 2021 13:36:44 +0000</pubDate>
</item>
<item>
<title>How to authenticate and authorize access to API Gateway endpoints for datomic?</title>
<link>https://ask.datomic.com/index.php/651/authenticate-authorize-access-gateway-endpoints-datomic</link>
<description>&lt;p&gt;I&#039;m currently evaluating Datomic and I&#039;ve deployed a production topology using a split stack. DatomicCloudVersion is 9095 and DatomicCFTVersion is 884. The CloudFormation stack created two API Gateway endpoints: &lt;code&gt;datomic-[system]-client-api&lt;/code&gt; and &lt;code&gt;datomic-[system]-ions&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;From my local computer I can get a client by using &lt;code&gt;datomic-[system]-client-api&lt;/code&gt; endpoint:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(d/client {:system &quot;my-system&quot;
           :server-type :ion
           :region &quot;us-east-1&quot;
           :endpoint &quot;https://[endpoint-id].execute-api.us-east-1.amazonaws.com/&quot;})
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Above, &lt;code&gt;https://[endpoint-id].execute-api.us-east-1.amazonaws.com/&lt;/code&gt; is the client-api API Gateway endpoint. It works, but the endpoint is open to the world. I then added an IAM authorizer to &lt;code&gt;datomic-[system]-client-api&lt;/code&gt; and used an authorized IAM user to make a request to the now authenticated endpoint:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;awscurl --service execute-api -X GET https://[endpoint-id].execute-api.us-east-1.amazonaws.com --profile datomic
{:s3-auth-path &quot;long s3 path&quot;}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;code&gt;awscurl&lt;/code&gt; is just a tool to make authenticated calls to AWS services. As you can see, I can get a response from the endpoint by using my local profile named &quot;datomic&quot;. If I try using regular curl without the v4 AWS signature it fails:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;curl -X GET https://[endpoint-id].execute-api.us-east-1.amazonaws.com
{&quot;message&quot;:&quot;Forbidden&quot;}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Works as expected. The problem is now I can&#039;t get a client using:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(d/client {:system &quot;my-system&quot;
           :server-type :ion
           :region &quot;us-east-1&quot;
           :creds-profile &quot;datomic&quot;
           :endpoint &quot;https://[endpoint-id].execute-api.us-east-1.amazonaws.com/&quot;})
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The response I get is:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;{:status 403,
:headers
{&quot;apigw-requestid&quot; &quot;EUsyNi9aIAMEPlg=&quot;,
&quot;connection&quot; &quot;keep-alive&quot;,
&quot;content-length&quot; &quot;23&quot;,
&quot;date&quot; &quot;Thu, 19 Aug 2021 17:01:40 GMT&quot;,
&quot;content-type&quot; &quot;application/json&quot;},
:body &quot;{\&quot;message\&quot;:\&quot;Forbidden\&quot;}&quot;}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;It is as if the &lt;code&gt;d/client&lt;/code&gt; call is ignoring the profile or not generating the proper signature. I tried setting the &lt;code&gt;AWS_PROFILE&lt;/code&gt; environment variable as well, to no avail.&lt;/p&gt;
&lt;p&gt;Is using an IAM Authorizer not the proper way to go? How can I protect both the client-api and ions endpoints? Finally, what&#039;s the difference between the client-api and ions endpoints?&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/651/authenticate-authorize-access-gateway-endpoints-datomic</guid>
<pubDate>Thu, 19 Aug 2021 17:05:29 +0000</pubDate>
</item>
<item>
<title>Datomic returns empty results where &quot;Insufficient bindings, will cause db scan&quot; exception is expected</title>
<link>https://ask.datomic.com/index.php/644/datomic-returns-insufficient-bindings-exception-expected</link>
<description>&lt;p&gt;Hello&lt;/p&gt;
&lt;p&gt;If we change &lt;code&gt;#uuid&quot;...&quot;&lt;/code&gt; to &lt;code&gt;&quot;&quot;&lt;/code&gt; (from uuid to string), we get the exception (desired behavior)&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;clj -Sdeps &#039;{:deps {com.datomic/dev-local {:mvn/version &quot;0.9.232&quot;}}}&#039; -M \
  -e &quot;(require &#039;[datomic.client.api :as d])&quot; \
  -e &#039;(def client (d/client {:server-type :dev-local :system &quot;hello&quot;}))&#039; \
  -e &#039;(d/create-database client {:db-name &quot;hello&quot;})&#039; \
  -e &#039;(def conn (d/connect client {:db-name &quot;hello&quot;}))&#039; \
  -e &quot;(d/q &#039;[:find ?e :where [?e _ #uuid\&quot;00000000-0000-0000-0000-000000000000\&quot;]] (d/db conn))&quot;
=&amp;gt; #&#039;user/client
=&amp;gt; true
=&amp;gt; #&#039;user/conn
=&amp;gt; []
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Occour on (old) versions of datomic-free too&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;clj -Sdeps &#039;{:deps {com.datomic/datomic-free {:mvn/version &quot;0.9.5697&quot;}}}&#039; \
  -M --report stderr \
  -e &quot;(require &#039;[datomic.api :as d])&quot; \
  -e &#039;(d/create-database &quot;datomic:mem://hello&quot;)&#039; \
  -e &#039;(def conn (d/connect &quot;datomic:mem://hello&quot;))&#039; \
  -e &quot;(d/q &#039;[:find ?e :where [?e _ #uuid\&quot;00000000-0000-0000-0000-000000000000\&quot;]] (d/db conn))&quot;
WARNING: requiring-resolve already refers to: #&#039;clojure.core/requiring-resolve in namespace: datomic.common, being replaced by: #&#039;datomic.common/requiring-resolve
=&amp;gt; true
=&amp;gt; #&#039;user/conn
=&amp;gt; #{}
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/644/datomic-returns-insufficient-bindings-exception-expected</guid>
<pubDate>Wed, 07 Jul 2021 14:30:05 +0000</pubDate>
</item>
<item>
<title>ClassCastException, d/with  inside transact function</title>
<link>https://ask.datomic.com/index.php/638/classcastexception-d-with-inside-transact-function</link>
<description>&lt;p&gt;Calling a transaction function that uses d/with in a dev-local, filesystem (i.e., not :storage-dir :mem) throws a ClassCastException on internal Datomic code.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Environment&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;com.datomic/dev-local {:mvn/version &quot;0.9.232&quot;}&lt;/li&gt;
&lt;li&gt;client-cloud 0.8.105&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;History&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Example with exception using file system dev-local.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(def client (d/client {:server-type :dev-local
                         :storage-dir &quot;/tmp/cce-bug3&quot;
                         :system      &quot;test&quot;}))
=&amp;gt; #&#039;user/client
(d/create-database client {:db-name &quot;test&quot;})
=&amp;gt; true
(def conn (d/connect client {:db-name &quot;test&quot;}))
=&amp;gt; #&#039;user/conn
(d/transact conn {:tx-data [{:db/ident       :user/name
                               :db/valueType   :db.type/string
                               :db/cardinality :db.cardinality/one}]})
=&amp;gt;
{:db-before #datomic.core.db.Db{:id &quot;test&quot;,
                                :basisT 5,
                                :indexBasisT 0,
                                :index-root-id nil,
                                :asOfT nil,
                                :sinceT nil,
                                :raw nil},
 :db-after #datomic.core.db.Db{:id &quot;test&quot;,
                               :basisT 6,
                               :indexBasisT 0,
                               :index-root-id nil,
                               :asOfT nil,
                               :sinceT nil,
                               :raw nil},
 :tx-data [#datom[13194139533318 50 #inst&quot;2021-05-09T00:49:46.400-00:00&quot; 13194139533318 true]
           #datom[73 10 :user/name 13194139533318 true]
           #datom[73 40 23 13194139533318 true]
           #datom[73 41 35 13194139533318 true]
           #datom[0 13 73 13194139533318 true]],
 :tempids {}}
(defn my-tx-fn
    [db argm]
    (let [tx-report (d/with db {:tx-data [{:user/name &quot;asd&quot;}]})]
      []))
=&amp;gt; #&#039;user/my-tx-fn
(d/transact conn {:tx-data [(list &#039;user/my-tx-fn {})]})
Execution error (ClassCastException) at datomic.dev-local.tx/datom-lookup-valfn (tx.clj:397).
class datomic.core.db.Datum cannot be cast to class java.lang.Number (datomic.core.db.Datum is in unnamed module of loader &#039;app&#039;; java.lang.Number is in module java.base of loader &#039;bootstrap&#039;)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Working memdb example.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(def client-memdb (d/client {:server-type :dev-local
                               :storage-dir :mem
                               :system      &quot;test&quot;}))
=&amp;gt; #&#039;user/client-memdb
(d/create-database client-memdb {:db-name &quot;test&quot;})
=&amp;gt; true
(def conn-memdb (d/connect client-memdb {:db-name &quot;test&quot;}))
=&amp;gt; #&#039;user/conn-memdb
(d/transact conn-memdb {:tx-data [{:db/ident       :user/name
                                     :db/valueType   :db.type/string
                                     :db/cardinality :db.cardinality/one}]})
=&amp;gt;
{:db-before #datomic.core.db.Db{:id &quot;394c7a65-bfeb-4dd4-b188-7aecd2057692&quot;,
                                :basisT 5,
                                :indexBasisT 0,
                                :index-root-id nil,
                                :asOfT nil,
                                :sinceT nil,
                                :raw nil},
 :db-after #datomic.core.db.Db{:id &quot;394c7a65-bfeb-4dd4-b188-7aecd2057692&quot;,
                               :basisT 6,
                               :indexBasisT 0,
                               :index-root-id nil,
                               :asOfT nil,
                               :sinceT nil,
                               :raw nil},
 :tx-data [#datom[13194139533318 50 #inst&quot;2021-05-09T01:02:57.965-00:00&quot; 13194139533318 true]
           #datom[73 10 :user/name 13194139533318 true]
           #datom[73 40 23 13194139533318 true]
           #datom[73 41 35 13194139533318 true]
           #datom[0 13 73 13194139533318 true]],
 :tempids {}}
(d/transact conn-memdb {:tx-data [(list &#039;user/my-tx-fn {})]})
=&amp;gt;
{:db-before #datomic.core.db.Db{:id &quot;394c7a65-bfeb-4dd4-b188-7aecd2057692&quot;,
                                :basisT 6,
                                :indexBasisT 0,
                                :index-root-id nil,
                                :asOfT nil,
                                :sinceT nil,
                                :raw nil},
 :db-after #datomic.core.db.Db{:id &quot;394c7a65-bfeb-4dd4-b188-7aecd2057692&quot;,
                               :basisT 7,
                               :indexBasisT 0,
                               :index-root-id nil,
                               :asOfT nil,
                               :sinceT nil,
                               :raw nil},
 :tx-data [#datom[13194139533319 50 #inst&quot;2021-05-09T01:03:08.042-00:00&quot; 13194139533319 true]],
 :tempids {}}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;strong&gt;Expectation&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Transaction functions that use d/with do not throw a ClassCastException. Additionally, the behavior of d/with in all Datomic environments (Cloud, File system, Memdb) is consistent. Given a &lt;a rel=&quot;nofollow&quot; href=&quot;https://forum.datomic.com/t/datomic-cloud-589-8846/1328&quot;&gt;previous Datomic Cloud release&lt;/a&gt; fixed a problem with using with-db from an Ion, it seems using d/with in a transaction function is a supported behavior.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Actual&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The final d/transact transaction function throws a ClassCastException when using d/with on some internal Datomic code. This only occurs when using a dev-local, file system environment.&lt;/p&gt;
&lt;p&gt;Full stacktrace is pasted below.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#error{:cause &quot;class datomic.core.db.Datum cannot be cast to class java.lang.Number (datomic.core.db.Datum is in unnamed module of loader &#039;app&#039;; java.lang.Number is in module java.base of loader &#039;bootstrap&#039;)&quot;,
       :via [{:type java.lang.ClassCastException,
              :message &quot;class datomic.core.db.Datum cannot be cast to class java.lang.Number (datomic.core.db.Datum is in unnamed module of loader &#039;app&#039;; java.lang.Number is in module java.base of loader &#039;bootstrap&#039;)&quot;,
              :at [datomic.dev_local.tx$datom_lookup_valfn invokeStatic &quot;tx.clj&quot; 397]}],
       :trace [[datomic.dev_local.tx$datom_lookup_valfn invokeStatic &quot;tx.clj&quot; 397]
               [datomic.dev_local.tx$datom_lookup_valfn invoke &quot;tx.clj&quot; 397]
               [datomic.dev_local.local_log.LocalLog valAt &quot;local_log.clj&quot; 56]
               [clojure.lang.RT get &quot;RT.java&quot; 760]
               [datomic.dev_local.btindex.BTIndex cons &quot;btindex.clj&quot; 281]
               [clojure.lang.RT conj &quot;RT.java&quot; 677]
               [clojure.core$conj__5390 invokeStatic &quot;core.clj&quot; 85]
               [clojure.core$conj__5390 invoke &quot;core.clj&quot; 82]
               [datomic.core.db.Db addData &quot;db.clj&quot; 2322]
               [datomic.core.db$add_ensured_data invokeStatic &quot;db.clj&quot; 3353]
               [datomic.core.db$add_ensured_data invoke &quot;db.clj&quot; 3351]
               [datomic.core.db$with_tx invokeStatic &quot;db.clj&quot; 3370]
               [datomic.core.db$with_tx invoke &quot;db.clj&quot; 3357]
               [datomic.core.db.Db with &quot;db.clj&quot; 2164]
               [datomic.core.local_db$fn__25633 invokeStatic &quot;local_db.clj&quot; 67]
               [datomic.core.local_db$fn__25633 invoke &quot;local_db.clj&quot; 24]
               [datomic.client.api.protocols$fn__11959$G__11877__11966 invoke &quot;protocols.clj&quot; 126]
               [datomic.client.api$with invokeStatic &quot;api.clj&quot; 363]
               [datomic.client.api$with invoke &quot;api.clj&quot; 353]
               [user$my_tx_fn invokeStatic &quot;user.clj&quot; 3]
               [user$my_tx_fn invoke &quot;user.clj&quot; 20]
               [clojure.lang.AFn applyToHelper &quot;AFn.java&quot; 156]
               [clojure.lang.AFn applyTo &quot;AFn.java&quot; 144]
               [clojure.lang.Var applyTo &quot;Var.java&quot; 705]
               [clojure.core$apply invokeStatic &quot;core.clj&quot; 667]
               [clojure.core$apply invoke &quot;core.clj&quot; 660]
               [datomic.core.db.ProcessExpander inject &quot;db.clj&quot; 3229]
               [datomic.core.db.ProcessInpoint inject &quot;db.clj&quot; 2950]
               [datomic.dev_local.btindex_db$expand_tx$inject_all__18586$fn__18587 invoke &quot;btindex_db.clj&quot; 440]
               [clojure.lang.PersistentVector reduce &quot;PersistentVector.java&quot; 343]
               [clojure.core$reduce invokeStatic &quot;core.clj&quot; 6827]
               [clojure.core$reduce invoke &quot;core.clj&quot; 6810]
               [datomic.dev_local.btindex_db$expand_tx$inject_all__18586 invoke &quot;btindex_db.clj&quot; 440]
               [datomic.dev_local.btindex_db$expand_tx invokeStatic &quot;btindex_db.clj&quot; 444]
               [datomic.dev_local.btindex_db$expand_tx invoke &quot;btindex_db.clj&quot; 429]
               [datomic.dev_local.btindex_db$with_tx invokeStatic &quot;btindex_db.clj&quot; 468]
               [datomic.dev_local.btindex_db$with_tx invoke &quot;btindex_db.clj&quot; 461]
               [datomic.dev_local.impl.DurableConnection transact &quot;impl.clj&quot; 161]
               [datomic.client.api$transact invokeStatic &quot;api.clj&quot; 200]
               [datomic.client.api$transact invoke &quot;api.clj&quot; 183]
               [user$eval124260 invokeStatic &quot;user.clj&quot; 25]
               [user$eval124260 invoke &quot;user.clj&quot; 25]
               [clojure.lang.Compiler eval &quot;Compiler.java&quot; 7177]
               [clojure.lang.Compiler eval &quot;Compiler.java&quot; 7132]
               [clojure.core$eval invokeStatic &quot;core.clj&quot; 3214]
               [clojure.core$eval invoke &quot;core.clj&quot; 3210]
               [nrepl.middleware.interruptible_eval$evaluate$fn__959 invoke &quot;interruptible_eval.clj&quot; 91]
               [clojure.main$repl$read_eval_print__9086$fn__9089 invoke &quot;main.clj&quot; 437]
               [clojure.main$repl$read_eval_print__9086 invoke &quot;main.clj&quot; 437]
               [clojure.main$repl$fn__9095 invoke &quot;main.clj&quot; 458]
               [clojure.main$repl invokeStatic &quot;main.clj&quot; 458]
               [clojure.main$repl doInvoke &quot;main.clj&quot; 368]
               [clojure.lang.RestFn invoke &quot;RestFn.java&quot; 1523]
               [nrepl.middleware.interruptible_eval$evaluate invokeStatic &quot;interruptible_eval.clj&quot; 84]
               [nrepl.middleware.interruptible_eval$evaluate invoke &quot;interruptible_eval.clj&quot; 56]
               [nrepl.middleware.interruptible_eval$interruptible_eval$fn__985$fn__989
                invoke
                &quot;interruptible_eval.clj&quot;
                155]
               [clojure.lang.AFn run &quot;AFn.java&quot; 22]
               [nrepl.middleware.session$session_exec$main_loop__1086$fn__1090 invoke &quot;session.clj&quot; 190]
               [nrepl.middleware.session$session_exec$main_loop__1086 invoke &quot;session.clj&quot; 189]
               [clojure.lang.AFn run &quot;AFn.java&quot; 22]
               [java.lang.Thread run &quot;Thread.java&quot; 829]]}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;strong&gt;Evidence&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The previously pasted example is reproducible and always throws a ClassCastException.  &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Impact&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;We are unable to test functionality in a consistent manner. Local setups using dev-local file systems will not function as expected. Developers are unable to test features in the same way they will work in production.&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/638/classcastexception-d-with-inside-transact-function</guid>
<pubDate>Thu, 24 Jun 2021 14:57:51 +0000</pubDate>
</item>
<item>
<title>d/client external server communication</title>
<link>https://ask.datomic.com/index.php/637/d-client-external-server-communication</link>
<description>&lt;p&gt;&lt;strong&gt;Environment&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;com.datomic/client-cloud 0.8.105&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;History&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Get the docstring for &lt;code&gt;d/client&lt;/code&gt;.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(clojure.repl/doc d/client)
-------------------------
datomic.client.api/client
([arg-map])
  Create a client for a Datomic system. This function does not
communicate with a server and returns immediately.

For a cloud system, arg-map requires:

  :server-type   - :cloud
  :region        - AWS region, e.g. &quot;us-east-1&quot;
  :system        - your system name
  :endpoint      - IP address of your system or query group

Optionally, a cloud system arg-map accepts:

  :creds-provider  - instance of com.amazonaws.auth.AWSCredentialsProvider. Defaults to DefaultAWSCredentialsProviderChain
  :creds-profile   - name of an AWS Named Profile. See http://docs.aws.amazon.com/cli/latest/userguide/cli-multiple-profiles.html
  :proxy-port      - local port for SSH tunnel to bastion 

  Note: :creds-provider and :creds-profile are mutually exclusive, providing both will result in an error.

For a dev-local system, arg-map comprises:

  :server-type   - :dev-local (required)
  :system        - a system name (required)
  :storage-dir   - optional, overrides :storage-dir in ~/.datomic/dev-local.edn

dev-local stores databases under ${storage-dir}/${system}/${db-name}.

For a peer-server system, arg-map requires:

  :server-type   - :peer-server
  :access-key    - access-key from peer server launch
  :secret        - secret from peer server launch
  :endpoint      - peer server host:port
  :validate-hostnames  - false

Returns a client object.
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Note the second sentence in the docstring: &quot;This function does not communicate with a server and returns immediately.&quot; Next call &lt;code&gt;d/client&lt;/code&gt; with an endpoint that does not exist.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(d/client {:server-type :ion
             :system      &quot;my-system&quot;
             :endpoint    &quot;http://i-dont-exist.datomic.net:8182&quot;
             :region      &quot;us-west-2&quot;})
Execution error (ExceptionInfo) at datomic.client.impl.cloud/get-s3-auth-path (cloud.clj:179).
Unable to connect to http://i-dont-exist.datomic.net:8182
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;strong&gt;Expectation&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Calling &lt;code&gt;d/client&lt;/code&gt; does not communicate with a server.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Actual&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Calling &lt;code&gt;d/client&lt;/code&gt; does communicate with a server.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Evidence&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The above reproducible example indicates the &lt;code&gt;d/client&lt;/code&gt; function call is attempted to communicate the the passing in &lt;code&gt;:endpoint&lt;/code&gt; string given the exception thrown.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Impact&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The &lt;code&gt;d/client&lt;/code&gt; docstring misleads the user by saying no server communication will occur when it does occur. The result is calls to &lt;code&gt;d/client&lt;/code&gt; can fail in unexpected ways when an external server communication is not accounted for. For example, we spin up Datomic Cloud query groups dynamically and attempt to communicate with the newly spun up cluster. Until the cluster is up and healthy, we expect calls to fail at &lt;code&gt;d/connect&lt;/code&gt; with an unavailable anomaly, and instead the calls would fail at &lt;code&gt;d/client&lt;/code&gt; with an unavailable anomaly.&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/637/d-client-external-server-communication</guid>
<pubDate>Thu, 24 Jun 2021 14:55:59 +0000</pubDate>
</item>
<item>
<title>Add query group ASG metrics to query group CW dashboard</title>
<link>https://ask.datomic.com/index.php/619/add-query-group-asg-metrics-to-query-group-cw-dashboard</link>
<description>&lt;p&gt;When looking at the query group dashboard, it is helpful to know what &quot;state&quot; the ASG was in when referencing the various dashboard metrics. Currently, I must do one of the following: 1) reference these metrics in the ASG monitoring tab (e.g., &lt;a rel=&quot;nofollow&quot; href=&quot;https://us-west-2.console.aws.amazon.com/ec2autoscaling/home?region=us-west-2#/details/my-query-group?view=monitoring&quot;&gt;https://us-west-2.console.aws.amazon.com/ec2autoscaling/home?region=us-west-2#/details/my-query-group?view=monitoring&lt;/a&gt;), 2) create a CW dashboard of my own, 3) modify the existing Datomic CW dashboard to add this chart. The ASG metrics answer questions like: 1) how many instances was my query group running? 2) was my query group trying to scale out or in? 3) why did my query group not scale out or in? &lt;/p&gt;
&lt;p&gt;I would find the following &lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.aws.amazon.com/autoscaling/ec2/userguide/as-instance-monitoring.html#available-cloudwatch-metrics&quot;&gt;ASG metrics&lt;/a&gt; (in order of importance) useful additions to the current query group dashboard.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;In Service Instances (Count)&lt;/li&gt;
&lt;li&gt;Minimum Group Size (Count), Maximum Group Size (Count), and Desired Capacity (Count)&lt;/li&gt;
&lt;li&gt;Pending Instances (Count)&lt;/li&gt;
&lt;/ol&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/619/add-query-group-asg-metrics-to-query-group-cw-dashboard</guid>
<pubDate>Thu, 27 May 2021 17:22:27 +0000</pubDate>
</item>
<item>
<title>How might multiple systems serve the same database in different contexts?</title>
<link>https://ask.datomic.com/index.php/617/might-multiple-systems-serve-database-different-contexts</link>
<description>&lt;p&gt;From &lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.datomic.com/cloud/operation/planning.html#namin&quot;&gt;the guide on naming&lt;/a&gt; there is the following quote:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;Multiple systems might serve the same primary database in different development stages. So you might name systems via the convention &quot;[db]-[stage]&quot;, e.g.&quot;inventory-dev&quot;, &quot;inventory-staging&quot; and &quot;inventory-prod&quot;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I&#039;m trying to understand how this would work, and how I should think about my system, application, and database name, but I&#039;m not really sure how this would work.&lt;/p&gt;
&lt;p&gt;My understanding was that you have one System per Storage stack, plus some number of Compute stacks, and that databases are &quot;owned&quot; by the Storage stack, but that doesn&#039;t make sense with the quote above.&lt;/p&gt;
&lt;p&gt;Can anyone give some examples of how this would work? I&#039;ve read &lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.datomic.com/cloud/operation/planning.html&quot;&gt;the planning guide&lt;/a&gt; but almost certainly don&#039;t fully understand it.&lt;/p&gt;
&lt;p&gt;Thank you!&lt;br&gt;
Evan&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/617/might-multiple-systems-serve-database-different-contexts</guid>
<pubDate>Mon, 24 May 2021 15:16:46 +0000</pubDate>
</item>
<item>
<title>What is a performant way to do &quot;and&quot; matching on attribute values?</title>
<link>https://ask.datomic.com/index.php/613/what-is-performant-way-to-do-and-matching-on-attribute-values</link>
<description>&lt;p&gt;So I can use&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;[?entity1 ?attrname1 ?attrval]
[?entity2 ?attrname2 ?attrval]
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;in a &lt;code&gt;:where&lt;/code&gt;  clause to get &lt;code&gt;?entity1&lt;/code&gt; and &lt;code&gt;?entity2&lt;/code&gt; where there exists an &lt;code&gt;?attrval&lt;/code&gt; that matches&lt;/p&gt;
&lt;p&gt;I&#039;m using&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;  [(q &#039;[:find (seq ?attrval)
        :in $ ?entity ?attrname
        :where [?entity ?attrname ?attrval]]
      db ?entity1 ?attrname1) [[?attrvals1]]]
  [(q &#039;[:find (seq ?attrval)
        :in $ ?entity ?attrname
        :where [?entity ?attrname ?attrval]]
      db ?entity2 ?attrname2) [[?attrvals2]]]
  (not-join [?attrvals1 ?attrvals2]
               [(seq ?attrvals1) [?element ...]]
               (not [(contains? ?attrvals2 ?element)]))
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;to get &lt;code&gt;?entity1&lt;/code&gt;  and &lt;code&gt;?entity2&lt;/code&gt; where all &lt;code&gt;?attrval&lt;/code&gt;s for &lt;code&gt;?entity1&lt;/code&gt; exist for &lt;code&gt;?entity2&lt;/code&gt;. Is there a more performant way to do this??&lt;br&gt;
(This feels like a directional &quot;and&quot; to the implicit &quot;or&quot; being applied to each &lt;code&gt;attrval&lt;/code&gt; matching in the first case)&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/613/what-is-performant-way-to-do-and-matching-on-attribute-values</guid>
<pubDate>Fri, 21 May 2021 18:04:41 +0000</pubDate>
</item>
<item>
<title>AssertionError shows up as an Event?</title>
<link>https://ask.datomic.com/index.php/609/assertionerror-shows-up-as-an-event</link>
<description>&lt;p&gt;This surprised me.  In a lambda invocation, a failed &lt;code&gt;assert&lt;/code&gt; shows up as an &lt;code&gt;Event&lt;/code&gt;. I would have expected &lt;code&gt;Alert&lt;/code&gt;:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&quot;Msg&quot;: &quot;IonLambdaException&quot;,
&quot;Ex&quot;: {
    &quot;Via&quot;: [
        {
            &quot;Type&quot;: &quot;java.lang.AssertionError&quot;,
            &quot;Message&quot;: &quot;Assert failed: (= (count s) 16)&quot;,
        }
    ],
    &quot;Cause&quot;: &quot;Assert failed: (= (count s) 16)&quot;
},
&quot;Type&quot;: &quot;Event&quot;,
&quot;Tid&quot;: 338,
&quot;Timestamp&quot;: 162134781093
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/609/assertionerror-shows-up-as-an-event</guid>
<pubDate>Tue, 18 May 2021 15:33:51 +0000</pubDate>
</item>
<item>
<title>Use Launch Template instead of Launch Configuration</title>
<link>https://ask.datomic.com/index.php/607/use-launch-template-instead-of-launch-configuration</link>
<description>&lt;p&gt;The compute Datomic CloudFormation templates (primary and query groups) create ASGs using launch configurations. Launch configurations do not support the full set of Auto Scaling group features. For example, you cannot create an Auto Scaling group that launches both Spot and On-Demand Instances or that specifies multiple instance types or multiple launch templates. In fact, &lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.aws.amazon.com/autoscaling/ec2/userguide/create-asg.html&quot;&gt;AWS recommends&lt;/a&gt; creating ASGs using launch templates, not launch configurations. &lt;/p&gt;
&lt;p&gt;We are interested in launch templates for its support for using Spot and On-Demand instances.&lt;/p&gt;
&lt;p&gt;EDIT: As of &lt;a rel=&quot;nofollow&quot; href=&quot;https://aws.amazon.com/blogs/compute/amazon-ec2-auto-scaling-will-no-longer-add-support-for-new-ec2-features-to-launch-configurations/&quot;&gt;2021-10-20&lt;/a&gt;, launch templates will not receive any new EC2 ASG features. &lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/607/use-launch-template-instead-of-launch-configuration</guid>
<pubDate>Fri, 07 May 2021 23:38:51 +0000</pubDate>
</item>
<item>
<title>Does the transactor eagerly fill memcached with indexed segments?</title>
<link>https://ask.datomic.com/index.php/605/does-transactor-eagerly-fill-memcached-with-indexed-segments</link>
<description>&lt;p&gt;The datomic &lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.datomic.com/on-prem/overview/caching.html#memcached&quot;&gt;transactor memcached documentation&lt;/a&gt; says this:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;When configured to used memcached, a Datomic process will automatically write into memcached any segment it needs that is not already present in memcached. &lt;strong&gt;In addition, the transactor (only) will write index and log segments to memcached as the segments are produced.&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;(Emphasis mine.)&lt;/p&gt;
&lt;p&gt;Based on this sentence and assuming a memcached memory pool larger than the storage size that is shared by transactor and peer, my expectation is the following:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;As the transactor is building an index, it writes newly-created index segments to storage &lt;em&gt;and&lt;/em&gt; to memcached at roughly the same time.&lt;/li&gt;
&lt;li&gt;When the index is finished, it commits the new index root and informs all peers of the new index.&lt;/li&gt;
&lt;li&gt;Any peers using the &lt;em&gt;same&lt;/em&gt; memcached cluster should, at the moment the index is released:&lt;ul&gt;
&lt;li&gt;have a &lt;em&gt;decreasing&lt;/em&gt; ObjectCache hitrate because newly-indexed segments are not cached&lt;/li&gt;
&lt;li&gt;but an &lt;em&gt;increasing&lt;/em&gt; memcached GET count&lt;/li&gt;
&lt;li&gt;and a flat StorageGet and MemcachedPut count because the segments are already in memcached&lt;/li&gt;
&lt;li&gt;For an overall flat or increasing memcached hitrate.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Instead, what I actually see is that when peers accept a new index,&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;there&#039;s a &lt;em&gt;dramatic&lt;/em&gt; decrease in Memcached hitrate&lt;/li&gt;
&lt;li&gt;and increase in MemcachedPut counts and Storage Get counts.&lt;/li&gt;
&lt;li&gt;The &lt;code&gt;IndexWrite&lt;/code&gt; count reported by the transactor is very similar to the MemcachedPut count reported by the peer.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;This behavior is consistent with the transactor &lt;em&gt;not&lt;/em&gt; writing newly-indexed segments into memcached eagerly while indexing, which is contrary to the documentation.&lt;/p&gt;
&lt;p&gt;So the question: &lt;strong&gt;Does the transactor &lt;em&gt;really&lt;/em&gt; write index segments to memcached as it is indexing?&lt;/strong&gt;&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/605/does-transactor-eagerly-fill-memcached-with-indexed-segments</guid>
<pubDate>Wed, 07 Apr 2021 15:21:18 +0000</pubDate>
</item>
<item>
<title>Support for recent AWS instance types</title>
<link>https://ask.datomic.com/index.php/604/support-for-recent-aws-instance-types</link>
<description>&lt;p&gt;AWS has released several new instance types that are much better price per performance. It&#039;d be great to have the Datomic query group template updated to support these instance types. The Datomic query group template currently supports the following instance types: t3.medium, m5.large, i3.large, i3.xlarge. Based on this, I propose the following additions: &lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;t3a.medium (~10% cheaper than t3.medium)&lt;/li&gt;
&lt;li&gt;m5a.large (~10% cheaper than m5.large)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;If Datomic can run on ARM based processors then further additions can be made with even better price per performance (the new AWS Graviton2 processors are fantastic. &lt;a rel=&quot;nofollow&quot; href=&quot;https://www.honeycomb.io/blog/graviton2-one-year-retrospective/&quot;&gt;Read about Honeycomb&#039;s success&lt;/a&gt;).&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;t4g.medium (perhaps also large and xlarge, ~20% cheaper than t3.medium)&lt;/li&gt;
&lt;li&gt;m6g.large (~20% cheaper than m5.large)&lt;/li&gt;
&lt;li&gt;r6gd.large	(has NVMe based SSD, 26% cheaper than i3.large)&lt;/li&gt;
&lt;li&gt;I4i (&lt;a rel=&quot;nofollow&quot; href=&quot;https://aws.amazon.com/blogs/aws/new-storage-optimized-amazon-ec2-instances-i4i-powered-by-intel-xeon-scalable-ice-lake-processors/&quot;&gt;released 2022-04-28&lt;/a&gt;)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The Datomic Solo instance type could also be configurable for some inconsequential savings. See monthly prices below:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;(Current) t3.small primary + t3.nano bastion: $18.90&lt;/li&gt;
&lt;li&gt;t3a.small + t3a.nano: $17.15&lt;/li&gt;
&lt;li&gt;t4g.small + t4g.nano: $15.33&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;An example Datomic query group monthly prices. Take a query group with 2 nodes running for the full month. &lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;(Current) m5.large: $140.16&lt;/li&gt;
&lt;li&gt;m5a.large: $125.56 ($14.6/month savings)&lt;/li&gt;
&lt;li&gt;m6g.large: $112.42 ($27.74/month savings)&lt;/li&gt;
&lt;/ul&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/604/support-for-recent-aws-instance-types</guid>
<pubDate>Wed, 24 Mar 2021 18:36:03 +0000</pubDate>
</item>
<item>
<title>Make DesiredCapacity an optional parameter in the query group CF template</title>
<link>https://ask.datomic.com/index.php/603/desiredcapacity-optional-parameter-query-group-template</link>
<description>&lt;p&gt;Currently (March 2021) the Datomic query group CF template has the DesiredCapacity parameter marked as required. Because of this, during a CF template update, CF will always set the DesiredCapacity to the CF parameter for DesiredCapacity. This behavior does not work well in the following situation. &lt;/p&gt;
&lt;p&gt;In the query group template I have the &lt;code&gt;DesiredCapacity&lt;/code&gt; at 2, and &lt;code&gt;MaxCount&lt;/code&gt; at 4. I have an ASG scaling policy to target track 50% average CPU utilization. My query group is currently at the max, because the ASG scaling policy scaled up the group DesiredCapacity to 4 (to match my load). My load has increased to the point where 4 nodes is no longer sufficient. I must update the query group CF template to increase the MacCount. The problem is that when you update the MacCount from 4 to 6 via a CF template update and leave the DesiredCapacity at 2, CF will actually set the DesiredCapacity on the ASG to 2 during the high load situation. This worsens the high load situation. &lt;/p&gt;
&lt;p&gt;One option is to query the ASG for its current DesiredCapacity prior to running a CF update and set the CF parameter to the value you retrieved. This approach complicates the update procedure. It also has a &quot;read-modify-write&quot; race condition -- the DesiredCapacity could have changed from the time you read the DesiredCapacity to the time you are performing the CF update. &lt;/p&gt;
&lt;p&gt;A second option is to make the &lt;code&gt;DesiredCapacity&lt;/code&gt; parameter optional. As per the &lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-as-group.html#cfn-as-group-desiredcapacity&quot;&gt;CF docs&lt;/a&gt;, &lt;code&gt;DesiredCapacity&lt;/code&gt; is not a required parameter. When it is not present, it defaults to the minimum size of the group. Leaving &lt;code&gt;DesiredCapacity&lt;/code&gt; unset will make it so during a CF update, CF will not modify the &lt;code&gt;DesiredCapacity&lt;/code&gt; at all -- leaving the ASG &quot;in control.&quot;&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/603/desiredcapacity-optional-parameter-query-group-template</guid>
<pubDate>Wed, 24 Mar 2021 17:24:25 +0000</pubDate>
</item>
<item>
<title>I am now seeing Iterator+offset is not available doing a an index-pull</title>
<link>https://ask.datomic.com/index.php/601/am-now-seeing-iterator-offset-not-available-doing-index-pull</link>
<description>&lt;p&gt;I am doing an index-pull in Datomic Cloud.  The request was timing out so I addedd :timeout 300000 and not &quot;Iterator+offset is not available&quot; exception starts popping up&lt;/p&gt;
&lt;p&gt;We are on 781-9041&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/601/am-now-seeing-iterator-offset-not-available-doing-index-pull</guid>
<pubDate>Mon, 08 Mar 2021 16:46:35 +0000</pubDate>
</item>
<item>
<title>Dev-local query does not support :timeout</title>
<link>https://ask.datomic.com/index.php/564/dev-local-query-does-not-support-timeout</link>
<description>&lt;p&gt;Dev-local 0.9.229 does not appear to support &lt;code&gt;:timeout&lt;/code&gt; when querying. Here is a repro. &lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(def client (d/client {:server-type :dev-local
                       :system      &quot;example&quot;}))
(d/create-database client {:db-name &quot;example&quot;})
(def conn (d/connect client {:db-name &quot;example&quot;}))
(d/transact conn {:tx-data [{:db/ident       :string
                             :db/cardinality :db.cardinality/one
                             :db/valueType   :db.type/string}]})
(dotimes [n 1000]
  (d/transact conn {:tx-data (map (fn [i]
                                    {:string (str n i)}) (range 1000))}))
(first
  (d/q {:query   &#039;[:find (pull ?e [*])
                   :where
                   [?e :string]]
        :timeout 1000
        :args    [(d/db conn)]}))
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The query takes longer than 1s and does not throw. I would have expected an exception thrown. &lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/564/dev-local-query-does-not-support-timeout</guid>
<pubDate>Wed, 30 Dec 2020 21:25:39 +0000</pubDate>
</item>
<item>
<title>Allow dev-local import-cloud :source and :dest to work with any :server-type</title>
<link>https://ask.datomic.com/index.php/561/allow-dev-local-import-cloud-source-dest-work-with-server-type</link>
<description>&lt;p&gt;Currently &lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.datomic.com/cloud/dev-local.html#import-cloud&quot;&gt;import-cloud&lt;/a&gt; requires the &lt;code&gt;:source&lt;/code&gt; client &lt;code&gt;:server-type&lt;/code&gt; to be &lt;code&gt;:cloud&lt;/code&gt; and the &lt;code&gt;:dest&lt;/code&gt; &lt;code&gt;:server-type&lt;/code&gt; to be &lt;code&gt;:dev-local&lt;/code&gt;. It&#039;d be great if this function allowed any &lt;code&gt;:server-type&lt;/code&gt; to be passed for &lt;code&gt;:source&lt;/code&gt; and &lt;code&gt;:dest&lt;/code&gt;. A possible use case would be copying a dev-local database to a cloud system for testing in a staging environment. &lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/561/allow-dev-local-import-cloud-source-dest-work-with-server-type</guid>
<pubDate>Sun, 20 Dec 2020 00:37:33 +0000</pubDate>
</item>
<item>
<title>What to do about &quot;syncContext completed and\/or Request lifecycle recycled&quot;?</title>
<link>https://ask.datomic.com/index.php/514/what-about-synccontext-completed-request-lifecycle-recycled</link>
<description>&lt;p&gt;We get into a state where we see a lot of &lt;code&gt;syncContext completed and\/or Request lifecycle recycled&lt;/code&gt; &lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;What does it mean?&lt;/li&gt;
&lt;li&gt;What can be done about it?&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The stack trace is:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&quot;Trace&quot;: [
            [
                &quot;org.eclipse.jetty.server.AsyncContextState&quot;,
                &quot;state&quot;,
                &quot;AsyncContextState.java&quot;,
                52
            ],
            [
                &quot;org.eclipse.jetty.server.AsyncContextState&quot;,
                &quot;getResponse&quot;,
                &quot;AsyncContextState.java&quot;,
                118
            ],
            [
                &quot;cognitect.http_endpoint.jetty$respond_bbuf_STAR_&quot;,
                &quot;invokeStatic&quot;,
                &quot;jetty.clj&quot;,
                326
            ],
            [
                &quot;cognitect.http_endpoint.jetty$respond_bbuf_STAR_&quot;,
                &quot;invoke&quot;,
                &quot;jetty.clj&quot;,
                323
            ],
            [
                &quot;cognitect.http_endpoint.jetty$respond_bbuf&quot;,
                &quot;invokeStatic&quot;,
                &quot;jetty.clj&quot;,
                351
            ],
            [
                &quot;cognitect.http_endpoint.jetty$respond_bbuf&quot;,
                &quot;invoke&quot;,
                &quot;jetty.clj&quot;,
                348
            ],
            [
                &quot;cognitect.http_endpoint.Endpoint&quot;,
                &quot;fail_request&quot;,
                &quot;http_endpoint.clj&quot;,
                126
            ],
            [
                &quot;cognitect.http_endpoint.Endpoint&quot;,
                &quot;respond&quot;,
                &quot;http_endpoint.clj&quot;,
                147
            ],
            [
                &quot;cognitect.http_endpoint.Endpoint$fn__13082$state_machine__8637__auto____13127$fn__13129&quot;,
                &quot;invoke&quot;,
                &quot;http_endpoint.clj&quot;,
                199
            ],
            [
                &quot;cognitect.http_endpoint.Endpoint$fn__13082$state_machine__8637__auto____13127&quot;,
                &quot;invoke&quot;,
                &quot;http_endpoint.clj&quot;,
                199
            ],
            [
                &quot;clojure.core.async.impl.ioc_macros$run_state_machine&quot;,
                &quot;invokeStatic&quot;,
                &quot;ioc_macros.clj&quot;,
                978
            ],
            [
                &quot;clojure.core.async.impl.ioc_macros$run_state_machine&quot;,
                &quot;invoke&quot;,
                &quot;ioc_macros.clj&quot;,
                977
            ],
            [
                &quot;clojure.core.async.impl.ioc_macros$run_state_machine_wrapped&quot;,
                &quot;invokeStatic&quot;,
                &quot;ioc_macros.clj&quot;,
                982
            ],
            [
                &quot;clojure.core.async.impl.ioc_macros$run_state_machine_wrapped&quot;,
                &quot;invoke&quot;,
                &quot;ioc_macros.clj&quot;,
                980
            ],
            [
                &quot;clojure.core.async.impl.ioc_macros$take_BANG_$fn__5769&quot;,
                &quot;invoke&quot;,
                &quot;ioc_macros.clj&quot;,
                991
            ],
            [
                &quot;clojure.core.async.impl.channels.ManyToManyChannel$fn__589$fn__590&quot;,
                &quot;invoke&quot;,
                &quot;channels.clj&quot;,
                95
            ],
            [
                &quot;clojure.lang.AFn&quot;,
                &quot;run&quot;,
                &quot;AFn.java&quot;,
                22
            ],
            [
                &quot;java.util.concurrent.ThreadPoolExecutor&quot;,
                &quot;runWorker&quot;,
                &quot;ThreadPoolExecutor.java&quot;,
                1149
            ],
            [
                &quot;java.util.concurrent.ThreadPoolExecutor$Worker&quot;,
                &quot;run&quot;,
                &quot;ThreadPoolExecutor.java&quot;,
                624
            ],
            [
                &quot;clojure.core.async.impl.concurrent$counted_thread_factory$reify__492$fn__493&quot;,
                &quot;invoke&quot;,
                &quot;concurrent.clj&quot;,
                29
            ],
            [
                &quot;clojure.lang.AFn&quot;,
                &quot;run&quot;,
                &quot;AFn.java&quot;,
                22
            ],
            [
                &quot;java.lang.Thread&quot;,
                &quot;run&quot;,
                &quot;Thread.java&quot;,
                748
            ]
        ]
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/514/what-about-synccontext-completed-request-lifecycle-recycled</guid>
<pubDate>Mon, 16 Nov 2020 22:03:14 +0000</pubDate>
</item>
<item>
<title>Provide way to interact with a datomic database before making the system available</title>
<link>https://ask.datomic.com/index.php/500/provide-interact-datomic-database-before-making-available</link>
<description>&lt;p&gt;Currently in Cloud there is no way to interact with a datomic database before making the system available for external requests.&lt;/p&gt;
&lt;p&gt;Potential uses:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;deploy the same code everywhere (dev &amp;amp; prod) and it does db-ensure&lt;br&gt;
actions&lt;/li&gt;
&lt;li&gt;load data and/or schema prior to the system being live &lt;/li&gt;
&lt;li&gt;start components or other system-management tooling&lt;/li&gt;
&lt;li&gt;provide (easy) way to integrate startup (e.g. mount/system-component) &lt;/li&gt;
&lt;li&gt;provide status and ability to know when pieces are started so you can finish app initialization&lt;/li&gt;
&lt;/ul&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/500/provide-interact-datomic-database-before-making-available</guid>
<pubDate>Mon, 02 Nov 2020 15:45:42 +0000</pubDate>
</item>
<item>
<title>Does dev-local/import-cloud handle failure in the middle of an import?</title>
<link>https://ask.datomic.com/index.php/495/does-dev-local-import-cloud-handle-failure-the-middle-import</link>
<description>&lt;p&gt;When running an import-cloud, does dev-local gracefully handle import-cloud failing in the middle of the import? i.e., it fails (gets killed or throws) and I can call import-cloud again without worrying about corrupt data, missing data, etc. &lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/495/does-dev-local-import-cloud-handle-failure-the-middle-import</guid>
<pubDate>Fri, 30 Oct 2020 16:21:53 +0000</pubDate>
</item>
<item>
<title>Expose an alt-port transactor configuration property</title>
<link>https://ask.datomic.com/index.php/469/expose-an-alt-port-transactor-configuration-property</link>
<description>&lt;p&gt;The alt-host configuration property is great and helps in many scenarios, but not having an equivalent for the port (alt-port?) is a blocker in some other scenarios. It would be great to have such property, which would default to the same port as the transactor is listening.&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/469/expose-an-alt-port-transactor-configuration-property</guid>
<pubDate>Sun, 25 Oct 2020 19:45:14 +0000</pubDate>
</item>
<item>
<title>Allow for datomic cloud installs into pre-existing VPCs</title>
<link>https://ask.datomic.com/index.php/459/allow-for-datomic-cloud-installs-into-pre-existing-vpcs</link>
<description>&lt;p&gt;The default Marketplace/CF config is great for getting started, more greenfield usage, etc. But it doesn&#039;t accomodate more complex (but common) situations. For instance, we&#039;ve just completed a complete overhaul of our AWS infrastructure. The project had kind of shuffled into AWS. Started with one account, with lifecycle environments only segregated via security groups. After accepting that that was a VeryBadThing, went to VPC&#039;s per environment, with AWS account segregation (one for production and pre-production, another for all dev lifecycle environments), we&#039;ve now moved to something a bit more sophisticated with accounts/vpcs per lifecycle environments, dedicated shared accounts/VPCs for ingress, data vault/logging, management, etc with IPSec tunnels between them all, as opposed to VPC peering.&lt;/p&gt;
&lt;p&gt;Sorry about the excruciating detail, but just wanted to provide context. So, in this scenario, shoehorning in Datomic Cloud becomes a bit difficult. Especially in conjunction with the current app/system assumptions (bring on those multiple query groups please! :)). For instance, my plan was to give each of my devs their own sandbox Solo instance, this won&#039;t scale well (there are 40 of them ;)) of they each need their own VPC, never mind the other issues. And I guess that might be basically a separate but related request, where one could stand up multiple &#039;systems&#039; in a single VPC&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/459/allow-for-datomic-cloud-installs-into-pre-existing-vpcs</guid>
<pubDate>Sun, 25 Oct 2020 19:29:15 +0000</pubDate>
</item>
<item>
<title>Store values encrypted, allowing key rotation.</title>
<link>https://ask.datomic.com/index.php/464/store-values-encrypted-allowing-key-rotation</link>
<description>&lt;p&gt;In our application we have a requirement to store certain fields encrypted. This encryption is done in the application. However, we would like to be able to rotate the encryption key should it become compromised, and retain the historical query features that you would get with unencrypted storage. In order to rotate the key, we have to excise the data and re-transact it with the new key, or store the encrypted values outside of Datomic. It would be nice to have an encryption API that enabled this use case.&lt;/p&gt;
</description>
<category>Datomic</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/464/store-values-encrypted-allowing-key-rotation</guid>
<pubDate>Sun, 25 Oct 2020 19:14:02 +0000</pubDate>
</item>
<item>
<title>Create DB from sequence of transactions</title>
<link>https://ask.datomic.com/index.php/462/create-db-from-sequence-of-transactions</link>
<description>&lt;p&gt;Given an input sequence of transactions expressed as EDN or some other format, provide a process to create a new Datomic database &quot;offline&quot; as quickly as possible, either in a supported storage backend or as a backup suitable for restore-db.&lt;/p&gt;
&lt;p&gt;The input transactions will use real Entity IDs, not tempids. Provide public APIs for constructing Entity IDs correctly.&lt;/p&gt;
&lt;p&gt;No other transactions or queries can be performed while the new database is being built. The input transactions cannot call any transaction functions.&lt;/p&gt;
&lt;p&gt;Similarly, provide an &quot;export&quot; process to write out the transaction log of an existing database to a file in the same format.&lt;/p&gt;
&lt;p&gt;This is essentially an optimization of the current process for bulk imports with a Transactor, with the added benefit of being able to control the creation of Entity IDs. This might be used, for example, to make a copy of a Datomic database with a filter or transformation applied to the transactions.&lt;/p&gt;
</description>
<category>Datomic</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/462/create-db-from-sequence-of-transactions</guid>
<pubDate>Sun, 25 Oct 2020 18:35:40 +0000</pubDate>
</item>
<item>
<title>Datomic CLI should support AWS SSO</title>
<link>https://ask.datomic.com/index.php/460/datomic-cli-should-support-aws-sso</link>
<description>&lt;p&gt;Datomic CLI should be able to load SSO profile from ~/.aws/config. It should be able to authorize Datomic users from AWS SSO console.&lt;/p&gt;
</description>
<category>Cloud</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/460/datomic-cli-should-support-aws-sso</guid>
<pubDate>Sun, 25 Oct 2020 18:24:06 +0000</pubDate>
</item>
<item>
<title>Allow for setting transactor properties using environment variables</title>
<link>https://ask.datomic.com/index.php/470/allow-setting-transactor-properties-environment-variables</link>
<description>&lt;p&gt;Datomic should be able to read it&#039;s settings from environment variables, following a naming standard like what Spring Boot does. E.g.:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;DATOMIC_LICENSE_KEY&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;DATOMIC_PROTOCOL&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;DATOMIC_PORT&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;…&lt;/li&gt;
&lt;/ul&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/470/allow-setting-transactor-properties-environment-variables</guid>
<pubDate>Sun, 25 Oct 2020 18:08:09 +0000</pubDate>
</item>
<item>
<title>Support AWS dynamo point in time backup in on-prem.</title>
<link>https://ask.datomic.com/index.php/468/support-aws-dynamo-point-in-time-backup-in-on-prem</link>
<description>&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://aws.amazon.com/blogs/aws/new-amazon-dynamodb-continuous-backups-and-point-in-time-recovery-pitr/&quot;&gt;https://aws.amazon.com/blogs/aws/new-amazon-dynamodb-continuous-backups-and-point-in-time-recovery-pitr/&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Currently Datomic supplies backup/restore capability here:&lt;/p&gt;
&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.datomic.com/on-prem/backup.html&quot;&gt;https://docs.datomic.com/on-prem/backup.html&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Dynamo&#039;s PITR remains untested for use with Datomic DBs. Implementation of this feature would ensure that using Dynamo&#039;s PITR causes no issues on a Datomic DB.&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/468/support-aws-dynamo-point-in-time-backup-in-on-prem</guid>
<pubDate>Sun, 25 Oct 2020 16:57:02 +0000</pubDate>
</item>
<item>
<title>Pass along DDB request IDs with transactions</title>
<link>https://ask.datomic.com/index.php/463/pass-along-ddb-request-ids-with-transactions</link>
<description>&lt;p&gt;Include the Dynamo DB request IDs with transactions.&lt;/p&gt;
&lt;p&gt;In order to provide more information for troubleshooting, the DDB team has indicated that passing along the DDB request ID with transactions would enable further troubleshooting, down to the specific problematic transactions.&lt;/p&gt;
</description>
<category>Datomic</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/463/pass-along-ddb-request-ids-with-transactions</guid>
<pubDate>Sun, 25 Oct 2020 16:41:05 +0000</pubDate>
</item>
<item>
<title>New engine for executing java scripts on the transactor</title>
<link>https://ask.datomic.com/index.php/455/new-engine-for-executing-java-scripts-on-the-transactor</link>
<description>&lt;p&gt;Is it planned to consider another script executing engines than &lt;strong&gt;janino&lt;/strong&gt;? There is script evaluator provided by &lt;strong&gt;groovy.lang.GroovyShell&lt;/strong&gt; which can execute java scripts too. I  have compared the time to evaluate the same java script by both engines and groovy engine executes significantly faster. Another positive side effect: support of groovy scripts. I believe using of new script evaluator will make improvements to the time of executing transactor functions written in java &lt;/p&gt;
&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.groovy-lang.org/latest/html/api/groovy/lang/GroovyShell.html&quot;&gt;https://docs.groovy-lang.org/latest/html/api/groovy/lang/GroovyShell.html&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;UPD.&lt;/strong&gt; How much are java transactor scripts executted longer than clojure transactor scripts?&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/455/new-engine-for-executing-java-scripts-on-the-transactor</guid>
<pubDate>Fri, 23 Oct 2020 13:52:54 +0000</pubDate>
</item>
<item>
<title>Can datomic.api/q be used inside or/or-join to query data from other DB?</title>
<link>https://ask.datomic.com/index.php/454/can-datomic-api-be-used-inside-or-or-join-query-data-from-other</link>
<description>&lt;p&gt;Hi, when I&#039;m executing query in repl in such way:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(d/q &quot;[:find
 [?Post ...]
 :in
 $
 $comment
 [?Post_value_0 ...]
 :where

[?Post :IModel/typeName ?Post_value_0]
(or-join 
 [?Post ?Comment_text_value_3]

 [(datomic.api/q
   \&quot;[:find [?Comment_uid_2 ...] :in $ :where 
   [?Comment_by_text_1 :Comment/text _]
   [?Comment_by_text_1 :IModel/uid ?Comment_uid_2]
   ]\&quot;
   $comment)
  [?Comment_uid_2 ...]]

  [(datomic.api/q
   \&quot;[:find [?Comment_uid_2 ...] :in $ :where 
   [?Comment_by_text_1 :Comment/text _]
   [?Comment_by_text_1 :IModel/uid ?Comment_uid_2]
   ]\&quot;
   $comment)
  [?Comment_uid_2 ...]]

)
 [?Post :Post/comments ?Comment_uid_2]
]
&quot; (d/db conn) (d/db connComment) #{&quot;Post&quot;})
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The next error is returned:&lt;br&gt;
&lt;strong&gt;:db.error/not-an-entity Unable to resolve entity: :Comment/text&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;My supposing is that query inside &lt;strong&gt;datomic.api/q&lt;/strong&gt; is executed for database returned by &lt;strong&gt;(d/db conn)&lt;/strong&gt; but not &lt;strong&gt;(d/db connComment)&lt;/strong&gt; because if I create &lt;strong&gt;:Comment/text&lt;/strong&gt; for the first database from input list then query is executed without errors.&lt;/p&gt;
&lt;p&gt;If to avoid &lt;strong&gt;or-join&lt;/strong&gt; and execute the query in the next way:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;(d/q &quot;[:find
 [?Post ...]
 :in
 $
 $comment
 [?Post_value_0 ...]
 :where

[?Post :IModel/typeName ?Post_value_0]
 [?Post ?Comment_text_value_3]

 [(datomic.api/q
   \&quot;[:find [?Comment_uid_2 ...] :in $ :where 
   [?Comment_by_text_1 :Comment/text _]
   [?Comment_by_text_1 :IModel/uid ?Comment_uid_2]
   ]\&quot;
   $comment)
  [?Comment_uid_2 ...]]

  [(datomic.api/q
   \&quot;[:find [?Comment_uid_2 ...] :in $ :where 
   [?Comment_by_text_1 :Comment/text _]
   [?Comment_by_text_1 :IModel/uid ?Comment_uid_2]
   ]\&quot;
   $comment)
  [?Comment_uid_2 ...]]


 [?Post :Post/comments ?Comment_uid_2]
]
&quot; (d/db conn) (d/db connComment) #{&quot;Post&quot;})
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;then query is executed without errors.&lt;/p&gt;
&lt;p&gt;Datamic on prem 0.9.6.* version&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/454/can-datomic-api-be-used-inside-or-or-join-query-data-from-other</guid>
<pubDate>Fri, 23 Oct 2020 10:53:08 +0000</pubDate>
</item>
<item>
<title>Delete all except the latest point in time within a backup URI</title>
<link>https://ask.datomic.com/index.php/452/delete-all-except-the-latest-point-in-time-within-backup-uri</link>
<description>&lt;p&gt;Also deleting a single point in time might be useful&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/452/delete-all-except-the-latest-point-in-time-within-backup-uri</guid>
<pubDate>Thu, 22 Oct 2020 21:46:45 +0000</pubDate>
</item>
<item>
<title>Provide integrity check on Datomic Backups</title>
<link>https://ask.datomic.com/index.php/432/provide-integrity-check-on-datomic-backups</link>
<description>&lt;p&gt;A tool to confirm the validity and completeness of a Datomic backup.&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/432/provide-integrity-check-on-datomic-backups</guid>
<pubDate>Thu, 22 Oct 2020 18:03:10 +0000</pubDate>
</item>
<item>
<title>Custom Value Types</title>
<link>https://ask.datomic.com/index.php/444/custom-value-types</link>
<description>&lt;p&gt;An attribute could accept a custom comparator and validator (as installed functions) and any fressian/edn-compatible value.  We often have a complex type which datomic either forces us to serialize to a string (slow, hacky, space-inefficient), or encode into a long (hacky, tricky), or use a full entity (lost value semantics, need to declare more attributes). Custom value types would solve all this.&lt;/p&gt;
</description>
<category>Datomic</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/444/custom-value-types</guid>
<pubDate>Thu, 22 Oct 2020 17:58:01 +0000</pubDate>
</item>
<item>
<title>Add Cassandra Cluster callback to the Peer</title>
<link>https://ask.datomic.com/index.php/436/add-cassandra-cluster-callback-to-the-peer</link>
<description>&lt;p&gt;The transactor provides a configurable cassandra cluster callback, but the peers do not. The Cassandra driver depends on old versions of metrics libraries that are incompatible with newer versions used in (for example) clojure metrics. Datastax solution for this requires use of the cluster callback &lt;a rel=&quot;nofollow&quot; href=&quot;https://docs.datastax.com/en/developer/java-driver/3.5/manual/metrics/#metrics-4-compatibility&quot;&gt;https://docs.datastax.com/en/developer/java-driver/3.5/manual/metrics/#metrics-4-compatibility&lt;/a&gt;, but that isn&#039;t available in Peers.&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/436/add-cassandra-cluster-callback-to-the-peer</guid>
<pubDate>Thu, 22 Oct 2020 17:52:42 +0000</pubDate>
</item>
<item>
<title>Primary-Replica Database Replication</title>
<link>https://ask.datomic.com/index.php/440/primary-replica-database-replication</link>
<description>&lt;p&gt;Provide a turnkey Primary-Replica feature for disaster recover. Alternatively provide API such that a &quot;Replication Peer Instance&quot; can: &lt;em&gt;connect to a &quot;primary&quot; database &lt;/em&gt; simultaneously connect to a &quot;replica&quot; database (in a different data center) * read transactions from primary sequentially and write those transactions to the replica.&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/440/primary-replica-database-replication</guid>
<pubDate>Thu, 22 Oct 2020 17:44:38 +0000</pubDate>
</item>
<item>
<title>Per-db metrics</title>
<link>https://ask.datomic.com/index.php/450/per-db-metrics</link>
<description>&lt;p&gt;Add a &quot;database&quot; dimension to the CloudWatch metric to distinguish which Database is being reported on, including an &quot;all databases&quot; value.&lt;/p&gt;
</description>
<category>Datomic</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/450/per-db-metrics</guid>
<pubDate>Thu, 22 Oct 2020 17:33:06 +0000</pubDate>
</item>
<item>
<title>Provide a progress bar/percentage on backup/restore process.</title>
<link>https://ask.datomic.com/index.php/435/provide-progress-bar-percentage-on-backup-restore-process</link>
<description>&lt;p&gt;It would be nice to be able to see the percentage complete when the restoring progress is not clear.&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/435/provide-progress-bar-percentage-on-backup-restore-process</guid>
<pubDate>Thu, 22 Oct 2020 17:10:52 +0000</pubDate>
</item>
<item>
<title>Ability to start peer without transactor.</title>
<link>https://ask.datomic.com/index.php/433/ability-to-start-peer-without-transactor</link>
<description>&lt;p&gt;If all transactors are down, no peers can start.  Add the ability to start a peer in a read-only mode while continuing to try to connect to the transactor.&lt;/p&gt;
</description>
<category>On-Prem</category>
<guid isPermaLink="true">https://ask.datomic.com/index.php/433/ability-to-start-peer-without-transactor</guid>
<pubDate>Thu, 22 Oct 2020 16:48:41 +0000</pubDate>
</item>
</channel>
</rss>