This rule reorders group and window so it will switch from using
`ReadGroup` to using `ReadWindowAggregate` when the intent is to
aggregate a grouped window. It will then add a group node that groups by
the given columns and the start and stop columns and then reperform the
aggregate. This is more performant than performing the group first.
* fix: remove urm create from task create request.
This will greatly reduce the amount of urms created in the system. To make this change to the system we need to also remove our direct reliance on the urm's in tasks.
Remove the create and delete portion of the task actions that are creating and deleting urms
Remove reliance on urm's when we are doing FindTaskByUser and instead rely on the user filter matching the task.OwnerID
One test had to be changed because the test was explicitly hacking the task to remove the owner ID and then trying to successfully look up the task by ownerID
* fix: add in feature flag
* fix: apply cursor cleanliness and permission error handling
* feat: flags for pushing down new aggregates
* refactor: grouped aggregate rewrite rules
The storage operation ReadGroup aggregates per series on the storage
side. The planner will rewrite grouped aggregate queries to call
ReadGroup, which will perform a partial aggregation, followed by
another operation that will perform the rest of the aggregation on
the compute side.
* feat: storage capabilities for grouped aggregates
* fix: changes from review
* feat: group read operation name should include aggregate
this ability exports all resources associated with a stack by the same
metadata.name fields as the original application had done it. This can
be used as a means to snapshot the current state of the stack. This can
be used for source control or other means.
closes: #18271
Added a (disabled) planner rule that matches:
ReadGroupPhys -> { count }
It uses the same physical spec node for group to implement the aggregate. The
rule requires:
* the pushDownGroupAggregateCount feature flag enabled
* no existing aggregate present in the ReadGroup
* use of the "_value" column only
This commit checks http.Request.Context().Err() to see if the context
has been canceled before writing an error code. It uses the non-standard
Nginx 499 error code for client disconnection.
Added a (disabled and feature-flagged) planner rule that matches:
ReadRange -> window -> { min, max, mean, count, sum }
The rule requires:
* the pushDownWindowAggregate{Count,Rest} feature flags enabled
* having WindowAggregateCapability
(which StorageReader does not currently have)
* use of "_value" columns only
* window.period == window.every
* window.every.months == 0
* window.every is positive
* window.offset == 0
* standard time columns
* createEmpty is false
this fix is necessary to avoid the superflour write header error. When the
write fails, we log it, this shoudl never happen unless the connection gets
corrupted. In that case there is nothing for the server to do except log
It is solid to use retrieve the method directly from the request.
Co-authored-by: George MacRorie <gmacrorie@influxdata.com>
Signed-off-by: Gianluca Arbezzano <gianarb92@gmail.com>
I think it is a nice utility function that I would like to use
elsewhere.
So I decided to move it out to the tracing package.
Signed-off-by: Gianluca Arbezzano <gianarb92@gmail.com>
With `/health`, it is possible to override the overall status reported.
This change adds the same functionality to `/ready`. This allows
incident responders to take an unhealthy pod out of a service without
killing it—giving them time to gather meaningful forensic data from the
pod. The new contract is:
Force not ready:
GET /ready?force=true&ready=false
Force ready:
GET /ready?force=true&ready=true
Disable override:
GET /ready?force=false
* chore: Remove several instances of WithLogger
* chore: unexport Logger fields
* chore: unexport some more Logger fields
* chore: go fmt
chore: fix test
chore: s/logger/log
chore: fix test
chore: revert http.Handler.Handler constructor initialization
* refactor: integrate review feedback, fix all test nop loggers
* refactor: capitalize all log messages
* refactor: rename two logger to log
* feat(tracing): dont trace spans with full URL path names in ExtractFromHTTPRequest
* chore(multiple): replace all occurrences of julienschmidt/httprouter with influxdata/httprouter
This command performs verification of TSM blocks
* expected and actual CRC-32 checksums match
* expected and actual min and max timestamps match decoded
data
This commit consists of several improvements or changes:
* migrate the influxd binary to cobra.Command
* introduce a default run sub-command to start the server
* register the run sub-command flags with viper
to maintain compatibility with the existing behavior of automatic
binding of flags to environment variables.
Closes#12602
* fix: Use simple function name for tracing operation name
Every span has an operation name, which shows up in multiple places in
the Jaeger UI. Verbose function names like
`github.com/influxdata/influxdb/kit/tracing.StartSpanFromContext`
are not readable in this UI. Shorter function names like
`StartSpanFromContext` improve UX. Context is not lost because (1) the
filename and line number are logged with the span and (2) spans are
understood in the context of other spans, marked with service name and
operation name.
Extra cost is ~22 ns per call to StartSpanFromContext. No additional
memory is allocated.
* goimports
* slice more than function name as span operatio name
I did this with a dumb editor macro, so some comments changed too.
Also rename root package from platform to influxdb.
In interest of minimizing risk, anyone importing the root package has
now aliased it to "platform" so that no changes beyond imports were
necessary in those files.
Lastly, replace the old platform module to local path /dev/null so that
nobody can accidentally reintroduce a platform dependency while
migrating platform code to influxdb.
* feat(api/health): Add a standardized health and ready check system
Build a system that can be used for both ready and health checking.
It can be used directly as a http.Handler and can be given a passthrough handler,
allowing it to operate as middleware.