Define the database data model and provides helpers to
Define the database data model and provides helpers to
(->namespaced namespace kw)Takes namespace and kw, returns kw namespaced to namespace.
If kw is already namespaced, it will be re-namespaced to namespace.
Takes `namespace` and `kw`, returns `kw` namespaced to `namespace`. If `kw` is already namespaced, it will be re-namespaced to `namespace`.
(->namespaced-provider+kind cloud-provider data-kind kw)Like provider+kind, but also takes a kw argument and returns a keyword namespaced to the
provider+kind namespace.
Like provider+kind, but also takes a `kw` argument and returns a keyword namespaced to the provider+kind namespace.
(cache-key api-name params)Builds a deterministic cache key from api-name and a map of parameter
names to values. All maps (including nested ones) are sorted by key to
ensure consistent ordering regardless of insertion order.
For time-series queries, callers should EXCLUDE date parameters (the gap-filling logic manages date ranges independently).
Returns a string suitable for indexed Datahike lookups.
Builds a deterministic cache key from `api-name` and a map of parameter names to values. All maps (including nested ones) are sorted by key to ensure consistent ordering regardless of insertion order. For time-series queries, callers should EXCLUDE date parameters (the gap-filling logic manages date ranges independently). Returns a string suitable for indexed Datahike lookups.
(compute-schema)Schema entries for caching OCI compute instance data.
Most fields are auto-created by schema-flexibility :read. We pre-declare only those that need specific types, indexing, or are component refs.
Schema entries for caching OCI compute instance data. Most fields are auto-created by schema-flexibility :read. We pre-declare only those that need specific types, indexing, or are component refs.
(datom-schema schema ident)Find the specified ident within schema.
Find the specified `ident` within `schema`.
(identity-schema)Schema entries for caching OCI identity/compartment data.
Schema entries for caching OCI identity/compartment data.
(lookup-key & param-name-keywords)This is how we build the value of :memoized/parameter-names.
We need to memoize query results based on the combination of parameter names used to fetch them. This function takes a variable number of parameter name keywords and returns a single string that uniquely identifies that combination.
This is how we build the value of :memoized/parameter-names. We need to memoize query results based on the combination of parameter names used to fetch them. This function takes a variable number of parameter name keywords and returns a single string that uniquely identifies that combination.
(provider+kind cloud-provider data-kind)Generates a namespaced keyword for stats data for the given
cloud-provider and data-kind.
Generates a namespaced keyword for stats data for the given `cloud-provider` and `data-kind`.
(remove-domain-namespace provider kind result)Strips the provider+kind namespace from keys in a single result map.
Datahike stores results under namespaced keys (e.g. :oci-compute/displayName).
This converts them back to plain camelCase keywords (e.g. :displayName) while
leaving already-unnamespaced keys unchanged.
Strips the provider+kind namespace from keys in a single result map. Datahike stores results under namespaced keys (e.g. `:oci-compute/displayName`). This converts them back to plain camelCase keywords (e.g. `:displayName`) while leaving already-unnamespaced keys unchanged.
(schema cloud-provider data-kind)Generate a minimal schema for the given data-kind (e.g. :usage) and
cloud-provider that includes the expected query parameters and results
for caching API call results.
cloud-provider and data-kind are used to namespace the attributes
in the schema to avoid potential type mismatches between similarly-named data
within/across different providers. For example, usage data from OCI and AWS
Generate a minimal schema for the given `data-kind` (e.g. :usage) and `cloud-provider` that includes the expected query parameters and results for caching API call results. `cloud-provider` and `data-kind` are used to namespace the attributes in the schema to avoid potential type mismatches between similarly-named data within/across different providers. For example, usage data from OCI and AWS
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |