The query system specifically expects an Authorization. When a request
comes in using a Session, use the target task's Authorization, if we are
allowed to read it, when executing a query against the system bucket.
Previously the APIBackend understood only a ProxyQueryService,
but it needs to understand that there are two implementations of the
ProxyQueryService one for handling InfluxQL queries and one for handling
Flux queries. The names of the fields have been updated to make this
clear. As well as the FluxBackend is now initialized using the
FluxService explicitly.
Also set the generated token's description while we're here.
This enables us to use task's Authorization when we need to query the
system bucket to get run logs, etc. but we only have a Session.
The YAML parser used by the go-openapi libraries treats an unquoted y as
a boolean key, which will lead to a difficult-to-understand parser
error:
types don't match expect map key string or int got: bool
See also https://yaml.org/type/bool.html.
* Condense appearance of inline create label form
Co-Authored-By: Delmer <ofthedelmer@users.noreply.github.com>
* Fine tune copy and click outside behavior
Co-Authored-By: Delmer <ofthedelmer@users.noreply.github.com>
* Show label color error color when invalid hex
Co-Authored-By: Delmer <ofthedelmer@users.noreply.github.com>
* Shrink width of random label color button
Co-Authored-By: Delmer <ofthedelmer@users.noreply.github.com>
* Add full color palette to list of random label colors
Co-Authored-By: Delmer <ofthedelmer@users.noreply.github.com>
* fix(ui/prettier-errors): fix ui prettier errors
Co-authored-by: Alex Paxton <thealexpaxton@gmail.com>
The `/api/v2/query` endpoint requires an organization or organizationID
query parameter.
Previously, there existed a bug in the API where if the organization
parameters were left off, the API would use the first organization
created in the backend, rather than returning a 400 error.
We built the entire UI on top of this bug, but it has now been fixed. So
in every location where we use the `/api/v2/query` endpoint, we need to
supply an organization.
This commit updates all such locations to use the first organization
present in our Redux store as the organization parameter, thus roughly
reproducing the behavior of the load bearing bug.
This is just a quick fix. Long term, we will want to think about what
organization queries should run under and build an appropriate UI around
that design.
* ci(litmus): do not run litmus tests on forked PRs
- add a step to check if PR is from fork. If it is, then stop execution of the step and successfully return.
- Fix for https://github.com/influxdata/influxdb/issues/11965