Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1 | <html><body> |
| 2 | <style> |
| 3 | |
| 4 | body, h1, h2, h3, div, span, p, pre, a { |
| 5 | margin: 0; |
| 6 | padding: 0; |
| 7 | border: 0; |
| 8 | font-weight: inherit; |
| 9 | font-style: inherit; |
| 10 | font-size: 100%; |
| 11 | font-family: inherit; |
| 12 | vertical-align: baseline; |
| 13 | } |
| 14 | |
| 15 | body { |
| 16 | font-size: 13px; |
| 17 | padding: 1em; |
| 18 | } |
| 19 | |
| 20 | h1 { |
| 21 | font-size: 26px; |
| 22 | margin-bottom: 1em; |
| 23 | } |
| 24 | |
| 25 | h2 { |
| 26 | font-size: 24px; |
| 27 | margin-bottom: 1em; |
| 28 | } |
| 29 | |
| 30 | h3 { |
| 31 | font-size: 20px; |
| 32 | margin-bottom: 1em; |
| 33 | margin-top: 1em; |
| 34 | } |
| 35 | |
| 36 | pre, code { |
| 37 | line-height: 1.5; |
| 38 | font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace; |
| 39 | } |
| 40 | |
| 41 | pre { |
| 42 | margin-top: 0.5em; |
| 43 | } |
| 44 | |
| 45 | h1, h2, h3, p { |
| 46 | font-family: Arial, sans serif; |
| 47 | } |
| 48 | |
| 49 | h1, h2, h3 { |
| 50 | border-bottom: solid #CCC 1px; |
| 51 | } |
| 52 | |
| 53 | .toc_element { |
| 54 | margin-top: 0.5em; |
| 55 | } |
| 56 | |
| 57 | .firstline { |
| 58 | margin-left: 2 em; |
| 59 | } |
| 60 | |
| 61 | .method { |
| 62 | margin-top: 1em; |
| 63 | border: solid 1px #CCC; |
| 64 | padding: 1em; |
| 65 | background: #EEE; |
| 66 | } |
| 67 | |
| 68 | .details { |
| 69 | font-weight: bold; |
| 70 | font-size: 14px; |
| 71 | } |
| 72 | |
| 73 | </style> |
| 74 | |
| 75 | <h1><a href="logging_v2.html">Cloud Logging API</a> . <a href="logging_v2.locations.html">locations</a> . <a href="logging_v2.locations.buckets.html">buckets</a></h1> |
| 76 | <h2>Instance Methods</h2> |
| 77 | <p class="toc_element"> |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 78 | <code><a href="logging_v2.locations.buckets.views.html">views()</a></code> |
| 79 | </p> |
| 80 | <p class="firstline">Returns the views Resource.</p> |
| 81 | |
| 82 | <p class="toc_element"> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 83 | <code><a href="#close">close()</a></code></p> |
| 84 | <p class="firstline">Close httplib2 connections.</p> |
| 85 | <p class="toc_element"> |
| 86 | <code><a href="#create">create(parent, body=None, bucketId=None, x__xgafv=None)</a></code></p> |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 87 | <p class="firstline">Creates a log bucket that can be used to store log entries. After a bucket has been created, the bucket's location cannot be changed.</p> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 88 | <p class="toc_element"> |
| 89 | <code><a href="#delete">delete(name, x__xgafv=None)</a></code></p> |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 90 | <p class="firstline">Deletes a log bucket.Changes the bucket's lifecycle_state to the DELETE_REQUESTED state. After 7 days, the bucket will be purged and all log entries in the bucket will be permanently deleted.</p> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 91 | <p class="toc_element"> |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 92 | <code><a href="#get">get(name, x__xgafv=None)</a></code></p> |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 93 | <p class="firstline">Gets a log bucket.</p> |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 94 | <p class="toc_element"> |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 95 | <code><a href="#list">list(parent, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p> |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 96 | <p class="firstline">Lists log buckets.</p> |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 97 | <p class="toc_element"> |
| 98 | <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p> |
| 99 | <p class="firstline">Retrieves the next page of results.</p> |
| 100 | <p class="toc_element"> |
| 101 | <code><a href="#patch">patch(name, body=None, updateMask=None, x__xgafv=None)</a></code></p> |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 102 | <p class="firstline">Updates a log bucket. This method replaces the following fields in the existing bucket with values from the new bucket: retention_periodIf the retention period is decreased and the bucket is locked, FAILED_PRECONDITION will be returned.If the bucket has a lifecycle_state of DELETE_REQUESTED, then FAILED_PRECONDITION will be returned.After a bucket has been created, the bucket's location cannot be changed.</p> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 103 | <p class="toc_element"> |
| 104 | <code><a href="#undelete">undelete(name, body=None, x__xgafv=None)</a></code></p> |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 105 | <p class="firstline">Undeletes a log bucket. A bucket that has been deleted can be undeleted within the grace period of 7 days.</p> |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 106 | <h3>Method Details</h3> |
| 107 | <div class="method"> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 108 | <code class="details" id="close">close()</code> |
| 109 | <pre>Close httplib2 connections.</pre> |
| 110 | </div> |
| 111 | |
| 112 | <div class="method"> |
| 113 | <code class="details" id="create">create(parent, body=None, bucketId=None, x__xgafv=None)</code> |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 114 | <pre>Creates a log bucket that can be used to store log entries. After a bucket has been created, the bucket's location cannot be changed. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 115 | |
| 116 | Args: |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 117 | parent: string, Required. The resource in which to create the log bucket: "projects/[PROJECT_ID]/locations/[LOCATION_ID]" For example:"projects/my-project/locations/global" (required) |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 118 | body: object, The request body. |
| 119 | The object takes the form of: |
| 120 | |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 121 | { # Describes a repository in which log entries are stored. |
Yoshi Automation Bot | 0bf565c | 2020-12-09 08:56:03 -0800 | [diff] [blame] | 122 | "createTime": "A String", # Output only. The creation timestamp of the bucket. This is not set for any of the default buckets. |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 123 | "description": "A String", # Describes this bucket. |
| 124 | "lifecycleState": "A String", # Output only. The bucket lifecycle state. |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 125 | "locked": True or False, # Whether the bucket is locked.The retention period on a locked bucket cannot be changed. Locked buckets may only be deleted if they are empty. |
| 126 | "name": "A String", # Output only. The resource name of the bucket.For example:projects/my-project/locations/global/buckets/my-bucketFor a list of supported locations, see Supported Regions (https://cloud.google.com/logging/docs/region-support)For the location of global it is unspecified where log entries are actually stored.After a bucket has been created, the location cannot be changed. |
| 127 | "restrictedFields": [ # Log entry field paths that are denied access in this bucket.The following fields and their children are eligible: textPayload, jsonPayload, protoPayload, httpRequest, labels, sourceLocation.Restricting a repeated field will restrict all values. Adding a parent will block all child fields. (e.g. foo.bar will block foo.bar.baz) |
yoshi-code-bot | f0c2fa6 | 2021-04-23 08:24:04 -0700 | [diff] [blame] | 128 | "A String", |
| 129 | ], |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 130 | "retentionDays": 42, # Logs will be retained by default for this amount of time, after which they will automatically be deleted. The minimum retention period is 1 day. If this value is set to zero at bucket creation time, the default time of 30 days will be used. |
| 131 | "updateTime": "A String", # Output only. The last update timestamp of the bucket. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 132 | } |
| 133 | |
| 134 | bucketId: string, Required. A client-assigned identifier such as "my-bucket". Identifiers are limited to 100 characters and can include only letters, digits, underscores, hyphens, and periods. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 135 | x__xgafv: string, V1 error format. |
| 136 | Allowed values |
| 137 | 1 - v1 error format |
| 138 | 2 - v2 error format |
| 139 | |
| 140 | Returns: |
| 141 | An object of the form: |
| 142 | |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 143 | { # Describes a repository in which log entries are stored. |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 144 | "createTime": "A String", # Output only. The creation timestamp of the bucket. This is not set for any of the default buckets. |
| 145 | "description": "A String", # Describes this bucket. |
| 146 | "lifecycleState": "A String", # Output only. The bucket lifecycle state. |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 147 | "locked": True or False, # Whether the bucket is locked.The retention period on a locked bucket cannot be changed. Locked buckets may only be deleted if they are empty. |
| 148 | "name": "A String", # Output only. The resource name of the bucket.For example:projects/my-project/locations/global/buckets/my-bucketFor a list of supported locations, see Supported Regions (https://cloud.google.com/logging/docs/region-support)For the location of global it is unspecified where log entries are actually stored.After a bucket has been created, the location cannot be changed. |
| 149 | "restrictedFields": [ # Log entry field paths that are denied access in this bucket.The following fields and their children are eligible: textPayload, jsonPayload, protoPayload, httpRequest, labels, sourceLocation.Restricting a repeated field will restrict all values. Adding a parent will block all child fields. (e.g. foo.bar will block foo.bar.baz) |
yoshi-code-bot | f0c2fa6 | 2021-04-23 08:24:04 -0700 | [diff] [blame] | 150 | "A String", |
| 151 | ], |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 152 | "retentionDays": 42, # Logs will be retained by default for this amount of time, after which they will automatically be deleted. The minimum retention period is 1 day. If this value is set to zero at bucket creation time, the default time of 30 days will be used. |
| 153 | "updateTime": "A String", # Output only. The last update timestamp of the bucket. |
| 154 | }</pre> |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 155 | </div> |
| 156 | |
| 157 | <div class="method"> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 158 | <code class="details" id="delete">delete(name, x__xgafv=None)</code> |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 159 | <pre>Deletes a log bucket.Changes the bucket's lifecycle_state to the DELETE_REQUESTED state. After 7 days, the bucket will be purged and all log entries in the bucket will be permanently deleted. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 160 | |
| 161 | Args: |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 162 | name: string, Required. The full resource name of the bucket to delete. "projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" "organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" "billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" "folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" For example:"projects/my-project/locations/global/buckets/my-bucket" (required) |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 163 | x__xgafv: string, V1 error format. |
| 164 | Allowed values |
| 165 | 1 - v1 error format |
| 166 | 2 - v2 error format |
| 167 | |
| 168 | Returns: |
| 169 | An object of the form: |
| 170 | |
| 171 | { # A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for Empty is empty JSON object {}. |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 172 | }</pre> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 173 | </div> |
| 174 | |
| 175 | <div class="method"> |
| 176 | <code class="details" id="get">get(name, x__xgafv=None)</code> |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 177 | <pre>Gets a log bucket. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 178 | |
| 179 | Args: |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 180 | name: string, Required. The resource name of the bucket: "projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" "organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" "billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" "folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" For example:"projects/my-project/locations/global/buckets/my-bucket" (required) |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 181 | x__xgafv: string, V1 error format. |
| 182 | Allowed values |
| 183 | 1 - v1 error format |
| 184 | 2 - v2 error format |
| 185 | |
| 186 | Returns: |
| 187 | An object of the form: |
| 188 | |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 189 | { # Describes a repository in which log entries are stored. |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 190 | "createTime": "A String", # Output only. The creation timestamp of the bucket. This is not set for any of the default buckets. |
| 191 | "description": "A String", # Describes this bucket. |
| 192 | "lifecycleState": "A String", # Output only. The bucket lifecycle state. |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 193 | "locked": True or False, # Whether the bucket is locked.The retention period on a locked bucket cannot be changed. Locked buckets may only be deleted if they are empty. |
| 194 | "name": "A String", # Output only. The resource name of the bucket.For example:projects/my-project/locations/global/buckets/my-bucketFor a list of supported locations, see Supported Regions (https://cloud.google.com/logging/docs/region-support)For the location of global it is unspecified where log entries are actually stored.After a bucket has been created, the location cannot be changed. |
| 195 | "restrictedFields": [ # Log entry field paths that are denied access in this bucket.The following fields and their children are eligible: textPayload, jsonPayload, protoPayload, httpRequest, labels, sourceLocation.Restricting a repeated field will restrict all values. Adding a parent will block all child fields. (e.g. foo.bar will block foo.bar.baz) |
yoshi-code-bot | f0c2fa6 | 2021-04-23 08:24:04 -0700 | [diff] [blame] | 196 | "A String", |
| 197 | ], |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 198 | "retentionDays": 42, # Logs will be retained by default for this amount of time, after which they will automatically be deleted. The minimum retention period is 1 day. If this value is set to zero at bucket creation time, the default time of 30 days will be used. |
| 199 | "updateTime": "A String", # Output only. The last update timestamp of the bucket. |
| 200 | }</pre> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 201 | </div> |
| 202 | |
| 203 | <div class="method"> |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 204 | <code class="details" id="list">list(parent, pageSize=None, pageToken=None, x__xgafv=None)</code> |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 205 | <pre>Lists log buckets. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 206 | |
| 207 | Args: |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 208 | parent: string, Required. The parent resource whose buckets are to be listed: "projects/[PROJECT_ID]/locations/[LOCATION_ID]" "organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]" "billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]" "folders/[FOLDER_ID]/locations/[LOCATION_ID]" Note: The locations portion of the resource must be specified, but supplying the character - in place of LOCATION_ID will return all buckets. (required) |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 209 | pageSize: integer, Optional. The maximum number of results to return from this request. Non-positive values are ignored. The presence of nextPageToken in the response indicates that more results might be available. |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 210 | pageToken: string, Optional. If present, then retrieve the next batch of results from the preceding call to this method. pageToken must be the value of nextPageToken from the previous response. The values of other method parameters should be identical to those in the previous call. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 211 | x__xgafv: string, V1 error format. |
| 212 | Allowed values |
| 213 | 1 - v1 error format |
| 214 | 2 - v2 error format |
| 215 | |
| 216 | Returns: |
| 217 | An object of the form: |
| 218 | |
Bu Sun Kim | 673ec5c | 2020-11-16 11:05:03 -0700 | [diff] [blame] | 219 | { # The response from ListBuckets. |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 220 | "buckets": [ # A list of buckets. |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 221 | { # Describes a repository in which log entries are stored. |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 222 | "createTime": "A String", # Output only. The creation timestamp of the bucket. This is not set for any of the default buckets. |
| 223 | "description": "A String", # Describes this bucket. |
| 224 | "lifecycleState": "A String", # Output only. The bucket lifecycle state. |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 225 | "locked": True or False, # Whether the bucket is locked.The retention period on a locked bucket cannot be changed. Locked buckets may only be deleted if they are empty. |
| 226 | "name": "A String", # Output only. The resource name of the bucket.For example:projects/my-project/locations/global/buckets/my-bucketFor a list of supported locations, see Supported Regions (https://cloud.google.com/logging/docs/region-support)For the location of global it is unspecified where log entries are actually stored.After a bucket has been created, the location cannot be changed. |
| 227 | "restrictedFields": [ # Log entry field paths that are denied access in this bucket.The following fields and their children are eligible: textPayload, jsonPayload, protoPayload, httpRequest, labels, sourceLocation.Restricting a repeated field will restrict all values. Adding a parent will block all child fields. (e.g. foo.bar will block foo.bar.baz) |
yoshi-code-bot | f0c2fa6 | 2021-04-23 08:24:04 -0700 | [diff] [blame] | 228 | "A String", |
| 229 | ], |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 230 | "retentionDays": 42, # Logs will be retained by default for this amount of time, after which they will automatically be deleted. The minimum retention period is 1 day. If this value is set to zero at bucket creation time, the default time of 30 days will be used. |
| 231 | "updateTime": "A String", # Output only. The last update timestamp of the bucket. |
| 232 | }, |
| 233 | ], |
| 234 | "nextPageToken": "A String", # If there might be more results than appear in this response, then nextPageToken is included. To get the next set of results, call the same method again using the value of nextPageToken as pageToken. |
| 235 | }</pre> |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 236 | </div> |
| 237 | |
| 238 | <div class="method"> |
| 239 | <code class="details" id="list_next">list_next(previous_request, previous_response)</code> |
| 240 | <pre>Retrieves the next page of results. |
| 241 | |
| 242 | Args: |
| 243 | previous_request: The request for the previous page. (required) |
| 244 | previous_response: The response from the request for the previous page. (required) |
| 245 | |
| 246 | Returns: |
| 247 | A request object that you can call 'execute()' on to request the next |
| 248 | page. Returns None if there are no more items in the collection. |
| 249 | </pre> |
| 250 | </div> |
| 251 | |
| 252 | <div class="method"> |
| 253 | <code class="details" id="patch">patch(name, body=None, updateMask=None, x__xgafv=None)</code> |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 254 | <pre>Updates a log bucket. This method replaces the following fields in the existing bucket with values from the new bucket: retention_periodIf the retention period is decreased and the bucket is locked, FAILED_PRECONDITION will be returned.If the bucket has a lifecycle_state of DELETE_REQUESTED, then FAILED_PRECONDITION will be returned.After a bucket has been created, the bucket's location cannot be changed. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 255 | |
| 256 | Args: |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 257 | name: string, Required. The full resource name of the bucket to update. "projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" "organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" "billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" "folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" For example:"projects/my-project/locations/global/buckets/my-bucket" (required) |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 258 | body: object, The request body. |
| 259 | The object takes the form of: |
| 260 | |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 261 | { # Describes a repository in which log entries are stored. |
Yoshi Automation Bot | 0bf565c | 2020-12-09 08:56:03 -0800 | [diff] [blame] | 262 | "createTime": "A String", # Output only. The creation timestamp of the bucket. This is not set for any of the default buckets. |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 263 | "description": "A String", # Describes this bucket. |
| 264 | "lifecycleState": "A String", # Output only. The bucket lifecycle state. |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 265 | "locked": True or False, # Whether the bucket is locked.The retention period on a locked bucket cannot be changed. Locked buckets may only be deleted if they are empty. |
| 266 | "name": "A String", # Output only. The resource name of the bucket.For example:projects/my-project/locations/global/buckets/my-bucketFor a list of supported locations, see Supported Regions (https://cloud.google.com/logging/docs/region-support)For the location of global it is unspecified where log entries are actually stored.After a bucket has been created, the location cannot be changed. |
| 267 | "restrictedFields": [ # Log entry field paths that are denied access in this bucket.The following fields and their children are eligible: textPayload, jsonPayload, protoPayload, httpRequest, labels, sourceLocation.Restricting a repeated field will restrict all values. Adding a parent will block all child fields. (e.g. foo.bar will block foo.bar.baz) |
yoshi-code-bot | f0c2fa6 | 2021-04-23 08:24:04 -0700 | [diff] [blame] | 268 | "A String", |
| 269 | ], |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 270 | "retentionDays": 42, # Logs will be retained by default for this amount of time, after which they will automatically be deleted. The minimum retention period is 1 day. If this value is set to zero at bucket creation time, the default time of 30 days will be used. |
| 271 | "updateTime": "A String", # Output only. The last update timestamp of the bucket. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 272 | } |
| 273 | |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 274 | updateMask: string, Required. Field mask that specifies the fields in bucket that need an update. A bucket field will be overwritten if, and only if, it is in the update mask. name and output only fields cannot be updated.For a detailed FieldMask definition, see: https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.FieldMaskFor example: updateMask=retention_days |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 275 | x__xgafv: string, V1 error format. |
| 276 | Allowed values |
| 277 | 1 - v1 error format |
| 278 | 2 - v2 error format |
| 279 | |
| 280 | Returns: |
| 281 | An object of the form: |
| 282 | |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 283 | { # Describes a repository in which log entries are stored. |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 284 | "createTime": "A String", # Output only. The creation timestamp of the bucket. This is not set for any of the default buckets. |
| 285 | "description": "A String", # Describes this bucket. |
| 286 | "lifecycleState": "A String", # Output only. The bucket lifecycle state. |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 287 | "locked": True or False, # Whether the bucket is locked.The retention period on a locked bucket cannot be changed. Locked buckets may only be deleted if they are empty. |
| 288 | "name": "A String", # Output only. The resource name of the bucket.For example:projects/my-project/locations/global/buckets/my-bucketFor a list of supported locations, see Supported Regions (https://cloud.google.com/logging/docs/region-support)For the location of global it is unspecified where log entries are actually stored.After a bucket has been created, the location cannot be changed. |
| 289 | "restrictedFields": [ # Log entry field paths that are denied access in this bucket.The following fields and their children are eligible: textPayload, jsonPayload, protoPayload, httpRequest, labels, sourceLocation.Restricting a repeated field will restrict all values. Adding a parent will block all child fields. (e.g. foo.bar will block foo.bar.baz) |
yoshi-code-bot | f0c2fa6 | 2021-04-23 08:24:04 -0700 | [diff] [blame] | 290 | "A String", |
| 291 | ], |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 292 | "retentionDays": 42, # Logs will be retained by default for this amount of time, after which they will automatically be deleted. The minimum retention period is 1 day. If this value is set to zero at bucket creation time, the default time of 30 days will be used. |
| 293 | "updateTime": "A String", # Output only. The last update timestamp of the bucket. |
| 294 | }</pre> |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 295 | </div> |
| 296 | |
| 297 | <div class="method"> |
| 298 | <code class="details" id="undelete">undelete(name, body=None, x__xgafv=None)</code> |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 299 | <pre>Undeletes a log bucket. A bucket that has been deleted can be undeleted within the grace period of 7 days. |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 300 | |
| 301 | Args: |
yoshi-code-bot | 3e4b5db | 2021-08-10 00:22:29 -0700 | [diff] [blame] | 302 | name: string, Required. The full resource name of the bucket to undelete. "projects/[PROJECT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" "organizations/[ORGANIZATION_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" "billingAccounts/[BILLING_ACCOUNT_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" "folders/[FOLDER_ID]/locations/[LOCATION_ID]/buckets/[BUCKET_ID]" For example:"projects/my-project/locations/global/buckets/my-bucket" (required) |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 303 | body: object, The request body. |
| 304 | The object takes the form of: |
| 305 | |
| 306 | { # The parameters to UndeleteBucket. |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 307 | } |
Dmitry Frenkel | 3e17f89 | 2020-10-06 16:46:05 -0700 | [diff] [blame] | 308 | |
| 309 | x__xgafv: string, V1 error format. |
| 310 | Allowed values |
| 311 | 1 - v1 error format |
| 312 | 2 - v2 error format |
| 313 | |
| 314 | Returns: |
| 315 | An object of the form: |
| 316 | |
| 317 | { # A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for Empty is empty JSON object {}. |
Yoshi Automation Bot | cc94ec8 | 2021-01-15 07:10:04 -0800 | [diff] [blame] | 318 | }</pre> |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 319 | </div> |
| 320 | |
| 321 | </body></html> |