The http error schema has been changed to simplify the outward facing
API. The `op` and `error` attributes have been dropped because they
confused people. The `error` attribute will likely be readded in some
form in the future, but only as additional context and will not be
required or even suggested for the UI to use.
Errors are now output differently both when they are serialized to JSON
and when they are output as strings. The `op` is no longer used if it is
present. It will only appear as an optional attribute if at all. The
`message` attribute for an error is always output and it will be the
prefix for any nested error. When this is serialized to JSON, the
message is automatically flattened so a nested error such as:
influxdb.Error{
Msg: errors.New("something bad happened"),
Err: io.EOF,
}
This would be written to the message as:
something bad happened: EOF
This matches a developers expectations much more easily as most
programmers assume that wrapping an error will act as a prefix for the
inner error.
This is flattened when written out to HTTP in order to make this logic
immaterial to a frontend developer.
The code is still present and plays an important role in categorizing
the error type. On the other hand, the code will not be output as part
of the message as it commonly plays a redundant and confusing role when
humans read it. The human readable message usually gives more context
and a message like with the code acting as a prefix is generally not
desired. But, the code plays a very important role in helping to
identify categories of errors and so it is very important as part of the
return response.
The `/query` swagger endpoint now specifies that error messages are
returned as the standard JSON schema. The standard JSON schema has also
been changed slightly so that only `code` and `message` are documented
and the intention is that we will flatten the message from an
`influxdb.Error` before we encode the JSON.
* refacotor(ui): split first time create check button into one for each type
* refactor(ui): replace create check button with dropdown
* refactor(ui): remove check type toggle from conditions card
* refactor(ui): split check creation into 2 routes
* refactor(ui): change default check depending on type
* refactor(ui): hide function selector when building a deadman check
* refactor(ui): move validation popover to check save button
* refactor(ui): remove unused component
* refactor(ui): ensure deadman queries do not have an aggregate function
Co-Authored-By: Deniz Kusefoglu <deniz@influxdata.com>
* refactor(ui): update alerting get started copy
* refactor(ui): update e2e test
* refactor(ui): use existing checkType type
Implementations of the backend.Executor produce errors limited to
querying the KV store. The remainder of the errors will be processed
in the implementation of a `RunPromise`.
Fixes#15161
We are planning to change the allocator interface within flux to use the
arrow allocator. To make the release easier, this updates the test in
advance to use the arrow allocator instead of the to be changed memory
allocator interface from flux.
We have been tracking down odd error messages when writing data and
found the problem to be internal server errors when writing empty
bodies.
I added fairly comprehensive test coverage for /api/v2/write as well
as simplify and clarify the error messages.
Writes directly to a PointsWriter require the tag key, value pairs
are sorted in lexicographically ascending order. This commit uses
new API from the `models` package to ensure this invariant is
maintained.
Closes https://github.com/influxdata/influxdb/issues/15060
Previously, the create button for a variable wouldn't be enabled unless
the user clicked in the text box, despite a query being present. This
adds an aditional check to the `isFormValid` method that ensures that if
a query is present the create button will be enabled.