To allow rudimentary security auditing of logs,
add the authenticating ID and the user ID when
possible to the request logs. When a request is
authorized for V1 or V2 API, store the authorizer
object to be used by the logger up the call stack.
closes https://github.com/influxdata/influxdb/issues/24473
* feat(monitor-ci/415): get oss-e2es working locally in UI repo
* chore: remove old, unused artifact directories
* fix: handle import cycle caused by trying to use the onboarding client
---------
Co-authored-by: Jeffrey Smith II <jsmith@influxdata.com>
* fix: improve delete speed when a measurement is part of the predicate
* test: add test for deleting measurement by predicate
* chore: improve error messaging and capturing
* chore: set goland to use the right formatting style
* feat: Add the instance owner concept
* feat: improve handling of instance resource type
* fix: remove relic of cloud/oss split
* feat: Add an instance id. This gets set during onboarding and can be used to uniquely identify that instance.
* chore: Revert "feat: Add an instance id. This gets set during onboarding and can be used to uniquely identify that instance."
This reverts commit 6a712df61e.
We decided to stick with the "singleton" 1 id for now, as there is not a clear need for unique identifiers.
* build(flux): update flux to v0.173.0
* fix(fluxfmt): update tests for newline in Flux fmt
Flux fmt now explicitly adds a newline to the end of a file, updating
tests accordingly.
* fix: forbid reading OSS buckets for a token with only write permissions
We previously enabled write tokens to also find DBRP buckets, in order to allow
the legacy /write (not /api/v2/write) endpoint to read the DBRP mappings and
find the real bucket id to write to.
This had the unintended consequency of allowing tokens with only write permissions
to read data in buckets via the legacy /query (not /api/v2/query) endpoint with
InfluxQL.
This change fixes the behaviour to allow writing to /write with a write-only
token, while forbidding reading from /query.
* fix: nanosecond precision in tests
* feat: api/v2/config endpoint for runtime config
* feat: use a type switch
* fix: add tests
* chore: add config key to returned json
* chore: update swagger ref
* fix: duplicated X-version and X-Build headers for /ping endpoint
Signed-off-by: Jakub Bednar <jakub.bednar@gmail.com>
* chore: change branch to master
* chore: only http/handler.go is responsible for sets headers
Signed-off-by: Jakub Bednar <jakub.bednar@gmail.com>
* feat: show measurement database and retention policy wildcards
Closes#22390
* chore: formatting
* test: this commit fails tests with empty database
* fix: show measurements with one empty database
* Move tenant.Service unit tests into its package
* Delete the top-level TenantService interface now that it's not used.
* Move helper funcs for setting up test stores into testing pkg
* Delete duplicate implementations scattered through the codebase
* Move error assertions into store-creation helpers