scopes
Creates, updates, deletes, gets or lists a scopes resource.
Overview
| Name | scopes |
| Type | Resource |
| Id | google.observability.scopes |
Fields
The following fields are returned by SELECT queries:
- get
| Name | Datatype | Description |
|---|---|---|
name | string | Identifier. Name of the resource. The format is: projects/{project}/locations/{location}/scopes/{scope} The {location} field must be set to global. The {scope} field must be set to _Default. |
logScope | string | Required. The full resource name of the LogScope. For example: //logging.googleapis.com/projects/myproject/locations/global/logScopes/my-log-scope |
traceScope | string | Required. The resource name of the TraceScope. For example: projects/myproject/locations/global/traceScopes/my-trace-scope |
updateTime | string (google-datetime) | Output only. Update timestamp. Note: The Update timestamp for the default scope is initially unset. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | projectsId, locationsId, scopesId | Gets details of a single Scope. | |
patch | update | projectsId, locationsId, scopesId | updateMask | Updates the parameters of a single Scope. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
locationsId | string | |
projectsId | string | |
scopesId | string | |
updateMask | string (google-fieldmask) |
SELECT examples
- get
Gets details of a single Scope.
SELECT
name,
logScope,
traceScope,
updateTime
FROM google.observability.scopes
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND scopesId = '{{ scopesId }}' -- required
;
UPDATE examples
- patch
Updates the parameters of a single Scope.
UPDATE google.observability.scopes
SET
data__name = '{{ name }}',
data__logScope = '{{ logScope }}',
data__traceScope = '{{ traceScope }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND scopesId = '{{ scopesId }}' --required
AND updateMask = '{{ updateMask}}'
RETURNING
name,
logScope,
traceScope,
updateTime;