Skip to content

Update partial write handling for v1, v2, Cloud 2 #6071

@jstirnaman

Description

@jstirnaman

OSS v2

Fix write-data/troubleshooting guide

In OSS v2 docs, we say that writes all or nothing--no partial writes

The first rejected point in a batch causes InfluxDB to reject the entire > batch and respond with an HTTP error status.
https://docs.influxdata.com/influxdb/v2/write-data/troubleshoot/#handle-write-and-delete-responses

This is no longer true.
Partial writes are detected and errors are communicated to the user:

  • HTTP status code 4xx
  • HTTP response payload (JSON) describes the problems in the payload, indicating to the user that part of the request succeeded, but not all of it

Cloud 2

Verify with IDPE/Platform and restore write-data/troubleshooting

For Cloud, looks like we munged the reference to that shared content and so the page is empty. I can restore it, but I'll check with [platform?] to make sure it Cloud still works the same.

Confirm if the following is still true:

some errors cannot be detected before the HTTP response is returned to the client, but are detected a few seconds or minutes later.
If a partial or complete error is detected before the response is generated, then the service returns 4xx
If any error is detected after the successful (204) response is generated, then the details of the failed request are written to a special InfluxDB bucket, named _monitoring, accessible to the customer for later analysis.

Background:

https://github.com/influxdata/influxdb/blob/ec9dcde5d6f0e1c4d15ff2332127987a42ca30fc/tsdb/shard.go#L706C2-L726C3

You can see here that we write as many points as we can, and return a partial write error, which I think comes out as a 422.

Slack Message

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions