> For the complete documentation index, see [llms.txt](https://docs.tonic.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.tonic.ai/app/workspace/workspace-schema-cache.md).

# Managing the workspace schema cache

You can configure a workspace to [cache the source database schema](/app/workspace/workspace-configuration-settings/schema-management-settings.md#schema-cache-config), to reduce the number of times that Tonic Structural needs to query the source database.

## Viewing the schema cache status <a href="#schema-cache-status" id="schema-cache-status"></a>

When schema caching is enabled for a workspace, then in the [expanded version of the workspace management view header](/app/workspace/managing-workspaces/selecting-a-workspace-to-manage.md#collapsing-and-expanding-the-workspace-heading), below the workspace name, Structural shows the current status of the schema cache.

<figure><img src="https://3378426797-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LSQCLFQ4bslJ-HYc8c3%2Fuploads%2FuvJXJmaScufDqlkmw0up%2FWorkspaceSchemaCacheStatus.png?alt=media&amp;token=7494ce29-40dd-41ed-87f8-f692fbabfb73" alt=""><figcaption><p>Schema cache status for a workspace</p></figcaption></figure>

The status indicates when:

* Structural is retrieving the schema information.
* Structural is checking for schema updates.
* Structural is refreshing the schema cache.
* Structural fails to connect to the source database.
* The schema cache refresh fails.
* The schema cache is updated. The status includes the timestamp of the most recent refresh.

## Refreshing the schema cache <a href="#schema-cache-refresh" id="schema-cache-refresh"></a>

When the schema cache is updated, or when Structural has detected updates to the schema, then the schema cache status includes an option to refresh the schema cache.

<figure><img src="https://3378426797-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LSQCLFQ4bslJ-HYc8c3%2Fuploads%2FS91ukPA18y98kpJP1CXd%2FWorkspaceSchemaCacheRefreshOption.png?alt=media&amp;token=7e174a47-4fae-46e8-ad73-319b262b44b7" alt=""><figcaption><p>Refresh Schema option for a workspace schema cache</p></figcaption></figure>

To refresh the schema:

1. Click the schema cache status.
2. On the panel, click **Refresh Schema**.

Structural starts a new schema retrieval job. To track the progress of the job, go to the [workspace **Jobs** view](/app/workspace/jobs.md).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.tonic.ai/app/workspace/workspace-schema-cache.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
