Queries in the portal
Queries shows what your service is allowed to run: the operations you declared, and the ones your clients registered for themselves. Open a service in the portal and choose Queries. It has two tabs.
How persisted queries work at the edge, and how to configure them, is in Persisted queries.
When the live deployment’s configuration does not turn persisted queries on, or that is not known
yet, both tabs open with a warning: the edge then answers every request that sends a hash with
PERSISTED_QUERY_NOT_SUPPORTED, whatever the registry holds. gpilot pq push prints the same
warning.
Persisted queries
Section titled “Persisted queries”Your manifest: the operations you pushed with gpilot pq push. You can search it by operation
name. The list has these columns:
| Column | Shows |
|---|---|
| Operation | The operation’s name, or that it is anonymous. adopted marks one a client first registered through APQ. |
| Type | The operation type, or unparsed for a document that could not be read. |
| Size | The size of the stored document, in bytes. |
| Requests | How often it was called over the last 30 days, or over your plan’s telemetry retention if that is shorter (1 day on Glider (Free), 7 days on Jet (Starter)). |
| Last seen | When it was last called. |
| Cache hits | The share of those calls answered from the cache, as a percentage. |
| Hash | The start of the hash clients send instead of the document. |
The usage figures come from stored request telemetry, so they count only requests that were stored; see what Insights needs. On a plan with a short retention, an operation called a week ago already shows no requests, so check before you revoke it. The same is true after a history reset: every operation shows no requests until it is called again.
If you have not declared anything yet, the list says so and names the command to run.
Operations your clients registered themselves through Automatic Persisted Queries, and that
your manifest does not declare. These are exactly the operations that trusted mode would start
refusing, so read this list before you switch to it.
To keep one, open it to read its document, then declare it with gpilot pq push from where your
client code lives. It then joins your manifest. The portal does not add operations to the
manifest itself.
The list loads a page at a time; Load more fetches the next one. It shows no total.
Reading one operation
Section titled “Reading one operation”Select an operation on either tab to open it. The panel shows whether it is in your manifest or registered by a client, its usage (Requests, Last seen, Cache hits, Errors), and the GraphQL Document, which you can copy or open larger. On Jet (Starter) and above, it also links to the operation’s requests in Insights.
Revoke an operation
Section titled “Revoke an operation” Permission service:edit
Revoke in the operation’s panel removes it from the registry, on either tab. After that, no client can run it by its hash. The dialog then reports what the revocation did for each operation: revoked; revoked but not yet recorded in the manifest (try again, or a push of the same manifest registers it once more); removed but still served from the cache, or not removed at all (try again in both cases); or not registered in the first place.
Related
Section titled “Related”- Persisted queries
- CLI commands:
gpilot pqandgpilot apq - Insights