Skip to main content
Stream specifies logging stream parameters. metadata.parent_id defines the parent container to stream logs from.

Schema

Required

Optional

  • disabled (Boolean) If set, logging stream would not be active and its effect on routing logs would not be applied.
  • labels (Map of String) Labels associated with the resource.
  • metadata (Attributes) :

    Inner value description

    Common resource metadata. (see below for nested schema)
  • name (String) Human-readable name for the resource.
  • parent_id (String) Identifier of the parent resource to which the resource belongs.

Read-Only

  • created_at (String) : Timestamp indicating when the resource was created. A string representing a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM
  • id (String) Identifier for the resource, unique for its resource type.
  • labels_all (Map of String) Effective labels sent to the API after merging provider default_labels with resource labels.
  • resource_version (Number) : Version of the resource for safe concurrent modifications and consistent reads. Positive and monotonically increases on each resource spec change (but not on each change of the resource’s container(s) or status). Service allows zero value or current.
  • status (Attributes) (see below for nested schema)
  • updated_at (String) : Timestamp indicating when the resource was last updated. A string representing a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM

Nested Schema for filter

Required:
  • match_expression (String) : LogQL match expression selecting log entries to export. Example: {app="myapp"} |= "error" selects logs from app “myapp” containing the word “error”.

Nested Schema for format

Optional:
  • log_attributes_mode (Attributes) : Enables structured log mode output format (timestamp, level, region, message, attributes map).

    Inner value description

    configuration for structured log output format. Cannot be set alongside message_json_mode. (see below for nested schema)
  • message_json_mode (Attributes) : Enables “message-as-json” output format.

    Inner value description

    configuration for “message-as-json” log output format. Cannot be set alongside log_attributes_mode. (see below for nested schema)

Nested Schema for format.log_attributes_mode

Optional:
  • attributes (List of String) list of attributes to write to log stream, empty means all attributes.

Nested Schema for format.message_json_mode

Nested Schema for sink

Optional:
  • object_storage (Attributes) Destination object storage where exported logs are written. (see below for nested schema)

Nested Schema for sink.object_storage

Optional:
  • by_name (Attributes) : Destination bucket. Cannot be set alongside id. (see below for nested schema)
  • id (String) : ID of the destination Object Storage bucket. Cannot be set alongside by_name.
  • object_prefix (String) Key prefix under which exported objects are written. Defaults to logs/.

Nested Schema for sink.object_storage.by_name

Required:
  • name (String) Name of the destination Object Storage bucket.
Optional:
  • parent_id (String) : Project ID that owns the bucket. Required only when the bucket lives in a different project than --parent-id; defaults to --parent-id otherwise.

Nested Schema for metadata

Nested Schema for status

Read-Only:
  • error_since (String) : time the stream entered state = ERROR; unset in other states A string representing a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ or YYYY-MM-DDTHH:MM:SS.SSS±HH:MM
  • last_error_message (String) last error message when state = ERROR
  • object_storage_bucket_id (String) ID of the destination Object Storage bucket. The service resolves it from spec.sink.object_storage on create.
  • state (String) :

    Supported values

    State is the current state of the stream. Possible values:
    • UNKNOWN
    • ACTIVE
    • DISABLED
    • ERROR