Resource: QueryMetric
Represents a query metric.
| JSON representation |
|---|
{ "name": string, "query": string, "userId": string, "queryOrigin": enum ( |
| Fields | |
|---|---|
name |
Output only. Identifier. The resource name of the query metric. Format: projects/{project}/locations/{location}/instances/{instance}/queryMetrics/{queryMetric} |
query |
Output only. Actual user query |
userId |
Output only. The user ID of the person or service account that initiated the query. |
queryOrigin |
Output only. The origin of the query (e.g., 'Search', 'Dashboard'). |
queryStartTime |
Output only. The exact timestamp when the user initiated the query. Uses RFC 3339, where generated output will always be Z-normalized and use 0, 3, 6 or 9 fractional digits. Offsets other than "Z" are also accepted. Examples: |
queryId |
Output only. Unique identifier for tracing the query end-to-end. |
Union field origin_metrics. Detailed metrics and dimensions for the query. origin_metrics can be only one of the following: |
|
searchMetrics |
Metrics for Search queries. |
SearchMetrics
Detailed metrics and dimensions for a single search query.
| JSON representation |
|---|
{ "querySource": enum ( |
| Fields | |
|---|---|
querySource |
Output only. The source of the search query. |
queryType |
Output only. Type of search query. |
timeRangeBucket |
Output only. The scan time range bucket of the search query. |
status |
Output only. Query execution Status. |
queryExecutionLatencyMs |
Output only. Query Execution Latency in milliseconds. |
QuerySource
Search entry point/source (e.g., 'UI', 'API', 'LRO-API', 'Backstory API').
| Enums | |
|---|---|
QUERY_SOURCE_UNSPECIFIED |
Query Source unspecified |
QUERY_SOURCE_UI |
UI |
QUERY_SOURCE_API |
Dataplane UdmSearch API |
QUERY_SOURCE_SEARCH_LRO_API |
Dataplane LRO Search API |
QUERY_SOURCE_BACKSTORY_API |
Backstory UdmSearch API |
QUERY_SOURCE_ALL_APIS |
All API query sources combined (excludes UI). |
QueryTimeRangeBucket
Scan Time Range Bucket.
| Enums | |
|---|---|
QUERY_TIME_RANGE_BUCKET_UNSPECIFIED |
Query time range bucket unspecified. |
UP_TO_ONE_HOUR |
<= 1 hour |
ONE_HOUR_TO_ONE_DAY |
|
ONE_DAY_TO_SEVEN_DAYS |
|
SEVEN_TO_THIRTY_DAYS |
|
THIRTY_TO_NINETY_DAYS |
|
GREATER_THAN_NINETY_DAYS |
|
QueryOrigin
Distinguishes where the query was initiated from.
| Enums | |
|---|---|
QUERY_ORIGIN_UNSPECIFIED |
Query Origin unspecified. |
SEARCH |
Query Origin Search. |
Methods |
|
|---|---|
|
Fetches aggregated time series data derived from QueryMetrics. |
|
Lists QueryMetrics for the instance. |