Skip to content
Stackship documentation Svenska

ValkeyUsers

Manage a store

The key-value store page — stop, start and restart the store, change its eviction policy, cache size limit and compute plan, turn the password and external access on or off, and delete it.

Requires: valkey/write, valkey/delete

Open Key-Value Store in the sidebar and choose the store. The header shows its status and Restart and Stop while it is Running, or Start while it is Stopped. The Overview shows the store's version and status, its cache behaviour — the cache size limit in force, the eviction policy and Durability: Not persisted — a restart starts empty — its resources, the connection details, its metrics and the Sentinel card. Changing anything on this page needs valkey/write, except deleting the store.

Important

Saving a section on the Configuration tab, and stsh valkeys update, fail today: the key-value store service accepts a change only as a replacement of the whole store (PUT), not as the partial update the portal and the CLI send. Until that changes, read the store, edit the JSON and send all of it back:

bash
stsh api GET /boundaries/<boundary-id>/resourcegroups/<resource-group>/resources/valkeys/my-cache > my-cache.json
stsh api PUT /boundaries/<boundary-id>/resourcegroups/<resource-group>/resources/valkeys/my-cache --body @my-cache.json

Such an update starts a Stopped store again, empty: the stop is not part of what it sends.

Stop, start and restart

Stop and Restart first ask you to confirm, because the store holds its data in memory only: everything in it is discarded, and clients see cache misses until it fills again. Stop shuts the server down; Start brings it back, empty. Follow each on the Operations tab.

Note

Restart is accepted and reported as finished, but a running store is not restarted at once: the server restarts, empty, only the next time the platform applies the store — for example after a configuration change. To restart it now, stop it and start it again.

With the CLI:

bash
stsh valkeys stop my-cache -g my-resource-group
stsh valkeys start my-cache -g my-resource-group
stsh valkeys restart my-cache -g my-resource-group

Change the cache size limit and eviction policy

Configuration → Runtime holds the Eviction policy and the Cache size limit. Both are applied to the running server as soon as you save: the store keeps running and keeps its data. An empty Cache size limit is derived from the memory limit; the field then shows the derived value. If the running server cannot be reached to apply a change, the platform keeps trying, and the store has the new values the next time it starts in any case. How to save a change today is described at the top of this page.

Change the compute plan

Compute Plan is in the same section. A new plan changes the server's CPU and memory, which restarts it and empties the cache. A cache size limit you set yourself stays as it is; a derived one follows the new memory limit.

Password and external access

Configuration → Networking & Security has Require a password, External access and Allowed CIDR ranges — see Connect to a store. Turning Require a password on or off restarts the store, which empties the cache.

Revisions

Every configuration change is recorded as a revision on the Revisions tab. View changes shows what a revision changed, and Roll back restores its configuration; the store is deployed again with it.

Access control

The Access Control tab assigns roles on this store alone — see Role assignments. The roles that matter are listed in Permissions.

Delete the store

On the Danger Zone tab, choose Delete, type the store's name and choose Delete Permanently. This needs valkey/delete, which valkey/write includes; the Owner, Contributor and Databases Operator roles have it. With the CLI:

bash
stsh valkeys delete my-cache -g my-resource-group --yes

Everything goes with the store — the server, its configuration and its password. Nothing is left behind in the resource group.