Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a REST API to create metadata caches #25546

Open
Tracked by #25539
hiltontj opened this issue Nov 13, 2024 · 0 comments · May be fixed by #25587
Open
Tracked by #25539

Add a REST API to create metadata caches #25546

hiltontj opened this issue Nov 13, 2024 · 0 comments · May be fixed by #25587
Assignees
Labels

Comments

@hiltontj
Copy link
Contributor

hiltontj commented Nov 13, 2024

Metadata caches can be created via the following API:

POST /api/v3/configure/meta_cache

with body parameters:

  • db: database the cache is configured on
  • table: table the cache is configured on
  • name: (optional) name of the cache, must be unique within the db/table, will be generated if not provided
  • columns: (optional) list of ordered columns to construct the cache
  • max_age: (optional) values that have not been seen for this amount of time will be evicted from the cache
  • max_cardinality: (optional) the max number of unique value combinations to hold in the cache

The API should respond with a structure representing the created cache. This API should be idempotent, so duplicate calls to create a cache will not result in duplicate caches being created, but only a single cache. The last cache create API behaves similar.

The columns, if not provided in the request, will be selected as the tag set in lexicographical order, or the series key, of the table. Only string columns, i.e., tags or string fields, are allowed for the time being - specifying another column type is an error.

The max_cardinality will default to 100,000 if not specified.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant