1
0
Fork 0
mirror of https://github.com/imjasonh/gcloud-help synced 2026-07-08 10:35:03 +00:00
gcloud-help/gcloud/logging/sinks/update

162 lines
6.1 KiB
Text
Raw Normal View History

2022-03-01 04:29:52 +00:00
NAME
2023-01-19 00:56:33 +00:00
gcloud logging sinks update - update a sink
2022-03-01 04:29:52 +00:00
SYNOPSIS
gcloud logging sinks update SINK_NAME [DESTINATION]
[--add-exclusion=[description=DESCRIPTION],
[disabled=DISABLED],[filter=FILTER],[name=NAME]] [--clear-exclusions]
2023-06-08 11:29:23 +00:00
[--custom-writer-identity=SERVICE_ACCOUNT_EMAIL]
2022-03-01 04:29:52 +00:00
[--description=DESCRIPTION] [--disabled] [--log-filter=LOG_FILTER]
[--remove-exclusions=[EXCLUSION ID,...]]
[--update-exclusion=[description=DESCRIPTION],
[disabled=DISABLED],[filter=FILTER],[name=NAME]]
[--use-partitioned-tables]
[--billing-account=BILLING_ACCOUNT_ID | --folder=FOLDER_ID
| --organization=ORGANIZATION_ID | --project=PROJECT_ID]
[GCLOUD_WIDE_FLAG ...]
DESCRIPTION
2023-01-19 00:56:33 +00:00
Change the [DESTINATION] or --log-filter associated with a sink. The new
2022-03-01 04:29:52 +00:00
destination must already exist and Cloud Logging must have permission to
write to it.
Log entries are exported to the new destination immediately.
EXAMPLES
To only update a sink filter, run:
$ gcloud logging sinks update my-sink --log-filter='severity>=ERROR'
Detailed information about filters can be found at:
https://cloud.google.com/logging/docs/view/logging-query-language
POSITIONAL ARGUMENTS
SINK_NAME
The name of the sink to update.
[DESTINATION]
A new destination for the sink. If omitted, the sink's existing
destination is unchanged.
FLAGS
--add-exclusion=[description=DESCRIPTION],[disabled=DISABLED],[filter=FILTER],[name=NAME]
Add an exclusion filter for log entries that are not to be routed to
the sink' destination. This flag can be repeated.
The name and filter attributes are required. The following keys are
accepted:
name
Required. An identifier, such as load-balancer-exclusion.
Identifiers are limited to 100 characters and can include only
letters, digits, underscores, hyphens, and periods.
description
Optional. A description of this exclusion.
filter
Required. Entries that match this advanced log filter will be
excluded. Filter cannot be empty.
disabled
Optional. By default, an exclusion is not disabled. To disable an
exclusion, include this key and specify any value.
--clear-exclusions
Remove all logging exclusions from the sink.
2023-06-08 11:29:23 +00:00
--custom-writer-identity=SERVICE_ACCOUNT_EMAIL
Writer identity for the sink. This flag can only be used if the
destination is a log bucket in a different project. The writer identity
is automatically generated when it is not provided for a sink.
2022-03-01 04:29:52 +00:00
--description=DESCRIPTION
Description of the sink.
--disabled
Disable the sink. Disabled sinks do not route logs to the sink
destination. Specify --no-disabled to enable a disabled sink. If this
flag is not specified, the value will not be updated.
--log-filter=LOG_FILTER
A new filter expression for the sink. If omitted, the sink's existing
filter (if any) is unchanged.
--remove-exclusions=[EXCLUSION ID,...]
Specify the name of the Logging exclusion(s) to delete.
--update-exclusion=[description=DESCRIPTION],[disabled=DISABLED],[filter=FILTER],[name=NAME]
Update an exclusion filter for a log entry that is not to be exported.
This flag can be repeated.
The name attribute is required. The following keys are accepted:
name
Required. An identifier, such as load-balancer-exclusion.
Identifiers are limited to 100 characters and can include only
letters, digits, underscores, hyphens, and periods.
description
Optional. A description of this exclusion.
filter
Optional. Entries that match this advanced log filter will be
excluded. Filter cannot be empty.
disabled
Optional. To disable an exclusion, include this key and specify any
value. To enable a disabled exclusion, include this key, but do not
specify any value. Do not include this key unless you want to
change its value.
Settings for sink exporting data to BigQuery.
--use-partitioned-tables
If specified, use BigQuery's partitioned tables. By default, Logging
creates dated tables based on the log entries' timestamps, e.g.
'syslog_20170523'. Partitioned tables remove the suffix and special
query syntax
(https://cloud.google.com/bigquery/docs/querying-partitioned-tables)
must be used.
At most one of these can be specified:
--billing-account=BILLING_ACCOUNT_ID
2023-01-19 00:56:33 +00:00
Billing account of the sink to update.
2022-03-01 04:29:52 +00:00
--folder=FOLDER_ID
2023-01-19 00:56:33 +00:00
Folder of the sink to update.
2022-03-01 04:29:52 +00:00
--organization=ORGANIZATION_ID
2023-01-19 00:56:33 +00:00
Organization of the sink to update.
2022-03-01 04:29:52 +00:00
--project=PROJECT_ID
2023-01-19 00:56:33 +00:00
Project of the sink to update.
2022-03-01 04:29:52 +00:00
The Google Cloud project ID to use for this invocation. If omitted,
then the current project is assumed; the current project can be
listed using gcloud config list --format='text(core.project)' and can
be set using gcloud config set project PROJECTID.
--project and its fallback core/project property play two roles in
the invocation. It specifies the project of the resource to operate
on. It also specifies the project for API enablement check, quota,
and billing. To specify a different project for quota and billing,
use --billing-project or billing/quota_project property.
GCLOUD WIDE FLAGS
These flags are available to all commands: --access-token-file, --account,
--billing-project, --configuration, --flags-file, --flatten, --format,
--help, --impersonate-service-account, --log-http, --project, --quiet,
--trace-token, --user-output-enabled, --verbosity.
Run $ gcloud help for details.
NOTES
These variants are also available:
$ gcloud alpha logging sinks update
$ gcloud beta logging sinks update