Commit Graph

828 Commits (903d30d65894cd282eae91c4026e39fe57a7b538)

Author SHA1 Message Date
Yiqun (Ethan) Zhang 6f805cbc2b
feat: flux query profiler (#19359) 2020-08-25 18:00:02 -05:00
Paul Hummer df41d42457 build(flux): update Flux to v0.82.2 2020-08-25 08:04:28 -06:00
Stuart Carnie 505f40c158
Merge remote-tracking branch 'origin/master' into sgc/tsm1
# Conflicts:
#	go.mod
#	go.sum
#	query/promql/internal/promqltests/go.mod
2020-08-18 14:04:52 -07:00
Paul Hummer 446c13f06b build(flux): update Flux to v0.81.0 2020-08-17 08:55:48 -06:00
Stuart Carnie 56e27b8893
Merge remote-tracking branch 'origin/master' into sgc/tsm1
# Conflicts:
#	go.mod
#	go.sum
#	query/promql/internal/promqltests/go.mod
2020-08-12 09:07:30 -07:00
Yiqun (Ethan) Zhang b12c3ef77b
build(flux): update Flux to v0.80.0 (#19298) 2020-08-12 10:29:46 -05:00
George 2636e976b9
chore(query): use dbrp v2 service in flux influx.v1 dependencies (#19108)
* chore(query): use dbrp v2 service in flux influx.v1 dependencies

* chore: update transpiler to use dbrp mapping service v2
2020-08-12 11:08:25 +01:00
Paul Hummer 9d7330a1c1 build(flux): update Flux to v0.79.0 2020-08-11 10:27:12 -06:00
jlapacik 46c7345dae
feat: enable pushdowns for sum, count, min, and max by default (#19227) 2020-08-05 12:06:35 -07:00
Adrian Thurston 08cfb3f773
feat: allow a metadata key to be required for a query to be logged (#19200)
Can specify that a key must be present in the query response metadata before
LoggingProxyQueryService logs the query. Will use this in gateway to only log
the query when the connection to queryd fails.
2020-08-05 18:14:53 +03:00
Faith Chikwekwe d48dc690a6
feat(query/stdlib): add min and max to ReadGroup (#19158)
Enables the mix and max aggregates for the ReadGroupAggregte pushdown behind a feature flag.

Co-authored-by: Jonathan A. Sternberg <jonathan@influxdata.com>
2020-08-05 09:40:26 -05:00
Stuart Carnie 87d153c84b
Merge branch 'master' into sgc/tsm1
# Conflicts:
#	go.mod
#	go.sum
#	query/promql/internal/promqltests/go.mod
2020-08-03 15:23:33 -07:00
Stuart Carnie 262023ae4a
fix(launcher): influxd inspect commands now start instantly
Lazily initialize flux, which increases startup time considerably
2020-08-03 15:16:36 -07:00
Stuart Carnie 0a644dceed
fix(storage): BufferedPointsWriter is for a single org / bucket only
Fixes experimental.to tests
2020-08-03 15:15:00 -07:00
Stuart Carnie f3501aa338
fix(stdlib): Fix unit tests and improved to implementation 2020-08-03 09:21:04 -07:00
Stuart Carnie 81e3a017de
fix(testing): Fix compilation errors 2020-08-03 09:21:04 -07:00
Stuart Carnie 89532f0c29
refactor: move v2/v1/models to v2/models 2020-08-03 09:20:51 -07:00
Stuart Carnie a71b43ff17
refactor: remove redundant files
* retention will be enforced by the InfluxDB 1.x engine
* storage will be a shim for `tsdb`, so don't need tests here
2020-08-03 09:20:50 -07:00
Edd Robinson 2b175291be
refactor: WIP removing tsbd 2020-08-03 09:18:34 -07:00
Stuart Carnie a97ec1f34e
feat: Initial commit with working reads 2020-08-03 09:18:34 -07:00
Stuart Carnie e3060c291c
refactor: tsdb store builds an runs 2020-08-03 09:18:32 -07:00
Paul Hummer 61fe279d4b
build(flux): update Flux to v0.77.1 2020-08-03 09:51:19 -05:00
Yiqun (Ethan) Zhang baa8323431
fix: group resultset produces 1 table per group (#18968)
This helps resolve #18098
2020-07-29 15:31:29 -05:00
Jonathan A. Sternberg 0cdbd496f4
fix(query): paginate bucket results in the bucket lookup (#19111)
The `buckets()` command would use a bucket lookup that wrapped the
`FindBuckets` API. It did not use the pagination aspect of this API
correctly. When the underlying implementation was changed to a version
that correctly implemented pagination, this broke the query `buckets()`
command. Since it was query that used the API incorrectly rather than a
regression in the `FindBuckets` implementation, this fixes the usage to
correctly use pagination.
2020-07-29 11:23:13 -05:00
Yiqun (Ethan) Zhang 8a27388601
feat: log query plan in metadata (#19100) 2020-07-27 17:14:49 -05:00
George 4a845f64cf
chore: simplify to transform dependencies (#18820)
* chore: remove bucket and org cruft from experimental to transformation

* chore: remove URM dependency from bucket auth middleware
2020-07-24 11:49:23 +01:00
Jonathan A. Sternberg 8678a22ee3
feat(storage/flux): add tests for min/max pushdowns (#19028) 2020-07-23 16:07:30 -05:00
Christopher M. Wolff 8b106bcee1
feat(storage): add mean aggregate array cursor and tests (#19019) 2020-07-23 09:49:53 -07:00
Adrian Thurston c693f0b080
test: use experimental.chain in flux e2e tests to allow a single pass (#18898)
Force the writing of data and running of the test to happen sequentially. As
the results come out, collect them and report an error only if the diff results
are not empty.
2020-07-23 15:58:21 +03:00
yukta dbcd363dad feat(query/stdlib): update flags.yml with mergleFilterRule and add mergeFilterRule to rules.go with corresponding unit tests. 2020-07-22 08:16:35 -07:00
yukta 6448a155c3 feat(query/stdlib): update flags.yml with mergleFilterRule and add mergeFilterRule to rules.go with corresponding unit tests. 2020-07-22 08:16:35 -07:00
Paul Hummer aa33f440a0 build(flux): update Flux to v0.74.0 2020-07-21 09:05:26 -06:00
jlapacik 36987bec0f feat: add offset parameter to window cursors 2020-07-20 12:23:37 -07:00
jlapacik 8907eee68d feat: rewrite rule for pushing down window offset 2020-07-20 12:23:37 -07:00
Christopher M. Wolff c695be2f56
feat(storage/reads): add min/max aggregate array cursors (#18957) 2020-07-20 10:17:04 -07:00
Faith Chikwekwe 43b5ef4db4 fix(query): produce error not panic for influxdb.to() 2020-07-15 08:50:15 -07:00
Paul Hummer 0265acf744
Merge pull request #18934 from influxdata/flux-staging/v0.73.0
build(flux): update Flux to v0.73.0
2020-07-14 11:40:27 -06:00
Paul Hummer 21a1faac6e chore: fix accidental typo 2020-07-14 11:20:42 -06:00
Paul Hummer ed66937378 chore: skip unbounded tests 2020-07-14 10:30:47 -06:00
Christopher M. Wolff a68ecc3d03
fix(query/stdlib): exclude logic and errors in Flux function to() (#18937) 2020-07-13 14:09:40 -07:00
Paul Hummer 4264f63822 build(flux): update Flux to v0.73.0 2020-07-13 11:48:19 -06:00
jlapacik 9f9be91828 feat: remove feature flags for first and last pushdowns 2020-07-07 14:15:48 -07:00
jlapacik 3246b3c7ad refactor: remove feature flag for certain pushdowns 2020-07-01 12:59:39 -07:00
Jonathan A. Sternberg e4e28526f8
build(flux): update Flux to v0.71.0 (#18809)
Additional changes:

* fix(query/stdlib): update rewrite rules for schema mutation

The schema mutator was wrapped in a dual implementation spec so the
rewrite rules were type asserting on the wrong type.
2020-07-01 13:12:50 -05:00
Jonathan A. Sternberg 1cd9569bff
feat(flags): add a feature flag for memory optimized schema mutation (#18794) 2020-06-29 16:53:45 -05:00
Jonathan A. Sternberg 5aeca082c8
chore: update staticcheck and fix newly identified lint checks (#18737) 2020-06-26 18:54:09 -05:00
jlapacik 3958c76604 feat: turn on storage capability for first 2020-06-25 14:37:07 -07:00
Jonathan A. Sternberg 61362e4d63
feat(query/stdlib): add a rule to reorder group and window (#18613)
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.
2020-06-22 11:11:27 -05:00
Yiqun (Ethan) Zhang 95d97c6e29
feat(query): planner rule to push down window and bare first() and la… (#18534) 2020-06-17 14:00:40 -05:00
Adrian Thurston 5d1a759170
feat: annotate context with feature flags when handling flux queries (#18506)
Annotate the context with feature flags when handling flux queries in influxdb.
Taking advantage of this in flux end-to-end tests. Using a custom flagger that
can set overrides based on the test case that is about to be run, allowing us
to enable features in the end-to-end tests.
2020-06-17 16:55:29 +03:00
jlapacik a19604c0ea refactor: windowed read operation should include aggregate name 2020-06-16 18:05:21 -07:00
Christopher M. Wolff 8fa5d3f591
feat(query): add test and feature flag for pushing down sum (#18484) 2020-06-12 13:28:03 -07:00
Johnny Steenbergen b1c7800bbe chore(query): skip flakey test
references: #18463
2020-06-11 11:26:38 -07:00
Yiqun (Ethan) Zhang 82185dd434
feat: add feature flag for fill() (#18445) 2020-06-10 16:00:43 -05:00
Yiqun (Ethan) Zhang 07c01cf79d
chore: update flux to v0.69.2 (#18441) 2020-06-10 15:36:17 -05:00
Jonathan A. Sternberg db686349e7
feat(storage/flux): support full aggregate window push down (#18399)
This enables a new rule that will push down the full `aggregateWindow`
query including the `duplicate` and `window(every: inf)` that recombines
the tables. When the full rule is used, the table is not split into
tables for each window and instead retains itself as a single table. The
start or stop column is renamed to `_time` and `_start` and `_stop` will
be the boundaries of the query.
2020-06-10 13:21:41 -05:00
Faith Chikwekwe 1bf2ce1a32 feat(query): register bare aggregate 2020-06-09 14:24:41 -07:00
Jonathan A. Sternberg 077949cd96
chore(flux): downgrade flux to v0.68.0 (#18413)
* revert: "feat: add feature flag for fill() (#18386)"

This reverts commit 8f9e73af27.

* chore(flux): downgrade flux to v0.68.0
2020-06-09 11:38:55 -05:00
Yiqun (Ethan) Zhang 8f9e73af27
feat: add feature flag for fill() (#18386) 2020-06-08 21:57:19 -05:00
Yiqun (Ethan) Zhang 78526a2210
chore: update flux to v0.69.1 (#18403) 2020-06-08 20:57:56 -05:00
jlapacik eba496d1bd
feat: grouped aggregate rewrite rules (#18342)
* 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
2020-06-04 14:36:15 -07:00
Jonathan A. Sternberg efbc4ae7c1
feat(storage/flux): implement create empty for the window table reader (#18288)
This implements create empty for the window table reader and allows this
table read function to be used when it is specified. It will pass down
the create empty flag from the original window call into the storage
read function.

This also fixes the window table reader so it properly creates
individual tables for each window. Previously, it was constructing one
table for an entire series instead of one table per window.

Tests have been added to verify three edge case behaviors. The first is
the normal read operation where all values are present. The second is
when create empty is specified so null values may be created. The third
is with truncated boundaries to ensure that storage is read from and the
start and stop timestamps get correctly truncated.
2020-06-01 17:57:50 -05:00
jlapacik baf400c4d4 chore: update flux to v0.68.0 2020-05-28 14:18:54 -07:00
Yiqun (Ethan) Zhang 41156ca646
feat(query): implement window count aggregate pushdown (#18043) 2020-05-28 13:42:38 -05:00
Christopher M. Wolff 53165bfb7f
feat(query): add a planner rule to push down bare aggregates (#18144) 2020-05-21 23:03:09 -07:00
Jonathan A. Sternberg 0bb847b7e7
Merge branch 'master' into feat/use-algo-w 2020-05-21 10:33:13 -05:00
Christopher M. Wolff 49df5e51eb
feat(query): add conditional option to LoggingProxyQueryService (#18170) 2020-05-20 10:22:21 -07:00
Adrian Thurston b776cf46f5
feat: added PushDownGroupAggregate planner rewrite rule (#18085)
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
2020-05-20 16:57:16 +03:00
Jonathan A. Sternberg 342c3c2630
fix(query): do not free the column reader in the no content encoders (#18116)
The column reader passed to `flux.Table.Do` is automatically released.
The function passed to the column reader should never release it
manually. This causes a double release which causes the table to be
erroneously freed when it might be referenced by another transformation.

In particular, this affected the following:

    tables
    |> yield()
    |> to()

This is because this would produce a buffered table with two references
and pass it to both `yield()` and `to()` because `yield()` is a
pseudo-node that doesn't really exist. The real graph looks more like:

    tables |> yield()
    tables |> to()

The `yield()` would double release which would release the `to()`
transformation's copy of the column readers. The `to()` method would
then be invoked with an invalid column reader.
2020-05-15 13:55:37 -05:00
Adrian Thurston b43f79b980
fix: need to rebuild the query request before the second e2e test run (#18112)
The e2e test driver in influxdb runs the tests twice to get past the fact that there
is no way to force order between the write to storage and the read back. When
the json.Marshal call became mandatory it was added to the first run, but not
the second.
2020-05-15 18:50:33 +03:00
Jonathan A. Sternberg 09b8e40933
fix(query/stdlib): update to function to use the refactored row functions (#18086)
The row functions were refactored to remove state from the dynamic
function. This updates the code that invoked row functions.
2020-05-13 14:11:14 -05:00
jlapacik 20a583dbcf chore: update flux to latest revision 2020-05-12 11:22:37 -07:00
jlapacik 9a1e31a12f chore: update flux to latest revision 2020-05-07 10:46:29 -07:00
jlapacik 6dd385d3b4 chore: update flux to latest revision 2020-05-06 10:00:00 -07:00
Adrian Thurston e51a2b81e9
feat: added PushDownWindowAggregate planner rewrite rule (#17898)
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
2020-05-06 10:27:17 +03:00
jlapacik 02c8e02c58 chore: update flux to latest revision 2020-05-05 09:46:19 -07:00
Yiqun Zhang e341a51ff0 fix: fmt 2020-05-05 01:43:22 -05:00
Yiqun (Ethan) Zhang 8bb5065769 refactor: unify WindowAggregateCapability (#17901) 2020-05-05 01:35:02 -05:00
jlapacik f2478a1d9a chore: update flux to latest revision 2020-04-29 10:11:29 -07:00
jlapacik 6d885c7112 Merge branch 'master' into chore/update-flux 2020-04-29 10:02:19 -07:00
Yiqun (Ethan) Zhang 3c2ab1b681
feat(query): Reader implementation for WindowAggregate (#17885) 2020-04-29 10:42:16 -05:00
jlapacik 457637ed22 Merge branch 'master' into chore/merge-master 2020-04-28 13:13:36 -07:00
jlapacik f5cf024c1a chore: update flux to latest algo-w revision 2020-04-28 13:06:14 -07:00
jlapacik 19ba69b783 fix: planner methods take a context 2020-04-28 12:23:38 -07:00
jlapacik f52391ef3e chore: update flux to v0.67.0 2020-04-28 12:23:38 -07:00
Yiqun (Ethan) Zhang e29eeabcec
feat: complete ReadWindowAggregateRequest (#17871) 2020-04-27 10:51:43 -05:00
jlapacik 3f4368ddd9 chore: update flux to latest algo-w revision 2020-04-24 14:40:37 -07:00
jlapacik 3079d2a8aa Merge branch 'master' into chore/merge-master-into-algo-w 2020-04-24 14:21:26 -07:00
Johnny Steenbergen 46f69bfc8c fix(flux): skip flakey test
references: #17847
2020-04-23 11:47:32 -07:00
jlapacik ff2a2cc66b chore: update flux to latest algo-w revision 2020-04-23 11:32:55 -07:00
Jonathan A. Sternberg d764ca3798
refactor(query): return detailed capabilities for the read window aggregate interfaces (#17836)
This modifies the read window aggregate interfaces to future-proof it
if and when we add additional capabilities to the method. Previously,
the interface was all or nothing. If we modified the RPC call itself, we
would have to make a new interface to denote the change to the Go code.

This changes the interface so now a `WindowAggregateCapability` exists.
This way, we can modify the struct to include things like:

```
type WindowAggregateCapability struct {
    WindowPeriodCapability bool
    MeanAggregateCapability bool
}
```

This way we can learn if the RPC call itself supports some specific
option. If the first iteration doesn't support a mean aggregate or the
mean aggregate is only supported by single server implementations, the
window aggregate can tell the caller that it won't be able to compute
the mean aggregate.

Since it fills in a struct with these capabilities, the struct can
safely introduce new values. If a downstream consumer wants to take
advantage of that functionality, then all interfaces in the chain have
to be updated to consume the upstream capabilities.
2020-04-23 10:22:33 -05:00
jlapacik c6ffeac22b test: skip flux end to end test for writing null values 2020-04-22 14:58:58 -07:00
jlapacik 54ac783475 refactor(query): move ReadWindowAggregateSpec to query package 2020-04-22 14:54:09 -07:00
jlapacik 63fd3655be Merge branch 'master' into chore/merge-master-into-algo-w 2020-04-22 14:52:59 -07:00
Jonathan A. Sternberg 58522d1190
feat(query): implement the ReadWindowAggregateSource (#17839)
The `ReadWindowAggregateSource` will invoke the `ReadWindowAggregate`
method on the `influxdb.Reader` and return the table. It is implemented
using the same common methods that are used for the other sources.
2020-04-22 16:07:45 -05:00
Yiqun (Ethan) Zhang 52dc494edb
feat(query): add ReadWindowAggregatePhysSpec (#17824) 2020-04-22 13:53:59 -05:00
Jonathan A. Sternberg 60c58ad805
feat(query): add interface for the window aggregate capability (#17801)
Added an interface for an additional storage capability. This interface
will allow for checking if the reader supports the window aggregate call
and another method for invoking the call if it does.

This is implemented using a single interface. If the reader implements
the interface, it indicates that the client is capable of reading the
response. The `HasXXX` method is intended to check if the store supports
the operation. This method also takes a context because it could require
a remote call or to wait for one.
2020-04-21 14:15:38 -05:00
jlapacik e076b61d5c fix: planner rewrite rules take a context 2020-04-20 14:09:02 -07:00
Paul Hummer 724e624970 chore: update flux 0.66.1 2020-04-20 12:36:53 -06:00
jlapacik 7541af8414 chore: merge master into algow 2020-04-15 14:42:03 -07:00
Alirie Gray 8975fd2365
refactor(tenant): move bucket and urm auth layers to tenant service (#17474)
Co-authored-by: Lyon Hill <lyondhill@gmail.com>
2020-04-07 11:13:27 -07:00
Jonathan A. Sternberg 687ab7001b
refactor(query): update semantic graph usage for function expression refactor (#17653)
This updates the semantic graph usage to accomodate the change to the
semantic graph that removed the ambiguity of the body so now it is
always a block instead of being a block or an expression.
2020-04-07 12:36:24 -05:00
Jonathan A. Sternberg 1bb08ceaf8
refactor(query/stdlib): modify storage filters to use the predicate directly (#17650)
The storage filters are modified to use the predicates directly so we do
not have to pass `semantic.FunctionExpression` around. Instead, since
simple expressions are all that are supported anyway, we transform
suitable function expressions into predicates as part of the push down
rule and this simplifies the influxdb reader code.

This also moves the storage predicate conversion code into the standard
library package as it is the only location that uses this code now that
the predicate conversion is done as part of the push down rule.

This refactor was prompted by another refactor of the
`semantic.FunctionExpression` that would cause it to always contain a
`semantic.Block`. Since the push down filter needs the expressions and
to combine them, this refactor allows us not do construct a combined
filter inside of blocks which allows us to have better type safety.
2020-04-07 10:45:08 -05:00
Jonathan A. Sternberg 17c244d1a7
chore: fix the promqltests go module file (#17631)
The replace directive in the promqltests pointed to the wrong module
path. This is now fixed.
2020-04-06 17:19:27 -05:00
Jonathan A. Sternberg 84386b884a
chore: fix the promqltests go module file (#17628)
The replace directive in the promqltests pointed to the wrong module
path. This is now fixed.
2020-04-06 16:28:29 -05:00
Jonathan A. Sternberg d3fa60991f
Merge branch 'master' into chore/merge-master 2020-04-06 12:17:47 -05:00
Jonathan A. Sternberg f09ee881fb
Merge pull request #17607 from influxdata/refactor/rewrite-imports
refactor: rewrite imports to include the /v2 suffix for version 2
2020-04-03 15:12:10 -05:00
Yiqun (Ethan) Zhang ace02b1b35
fix: nil timestamp panic in to() (#17591) 2020-04-03 15:03:39 -04:00
Jonathan A. Sternberg 0ae8bebd75
refactor: rewrite imports to include the /v2 suffix for version 2 2020-04-03 12:39:20 -05:00
Jonathan A. Sternberg 9895657dc0
ci: run go mod tidy for the promqltests (#17580) 2020-04-03 11:05:49 -05:00
Jonathan A. Sternberg 469c5849c4
Merge branch 'master' into feat/use-algo-w 2020-04-03 09:30:04 -05:00
Gianluca Arbezzano 47959b7436
Merge pull request #17499 from influxdata/feature/move-prometheus-span
chore(tracing): Span with Prometheus Metrics moved to kit/tracing
2020-04-03 10:07:49 +02:00
Lorenzo Affetti 13fc4f335d
test(launcher): e2e test memory limits 2020-04-02 11:20:42 +02:00
Jonathan A. Sternberg eda8d44c74
ci(promqltests): update promqltests go.mod file to be compatible with go 1.13 (#17510)
The prometheus project doesn't adhere to the module suffix so any
attempt to use it as a library fails with go 1.13 or greater. The
workaround is to `go get` a specific commit revision that corresponds to
a tag and let go figure out a pseudo-version for it.

In this case, I updated the revision to the one pointed at by `v2.9.2`
since that is what the current `go.mod` file pointed at. I also updated
the go version to 1.13 inside of `go.mod` to be the same as influxdb.

See https://github.com/prometheus/prometheus/issues/6048 for details.
2020-04-01 10:00:43 -05:00
Gianluca Arbezzano 8e5bd1a2dd chore(tracing): embed the opentracing.Span
Signed-off-by: Gianluca Arbezzano <gianarb92@gmail.com>
2020-03-31 16:01:31 +02:00
Gianluca Arbezzano af06897014 chore(tracing): Span with Prometheus Metrics moved to kit/tracing
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>
2020-03-31 14:17:50 +02:00
Yiqun (Ethan) Zhang 48efdb52ea
build(flux): update Flux to v0.65.0 (#17484) 2020-03-27 18:42:19 -04:00
Alirie Gray ad7a4a05bb
refactor: change log level back for query controller panics (#17450) 2020-03-26 15:19:07 -07:00
jlapacik 7d885fb2c6 chore: update flux
Closes https://github.com/influxdata/influxdb/issues/17065.
2020-03-26 10:07:17 -07:00
Christopher M. Wolff e57c28d4b7
chore: update to latest algo-w flux (#17422) 2020-03-25 14:53:46 -07:00
Lorenzo Affetti 7f70353b18
feat(query): add unused memory bytes prom metric to controller 2020-03-25 18:03:38 +01:00
Christopher M. Wolff e9689b7269
chore: update to latest flux algo-w (#17408) 2020-03-24 15:45:10 -07:00
Alirie Gray bdd6dc644a
refactor(query): change log level to record panic stack traces (#17406) 2020-03-24 14:13:11 -07:00
Alirie Gray 9c3c0b9592
refactor(query): add stack trace to query controller execution (#17392) 2020-03-23 15:01:43 -07:00
Christopher M. Wolff 20c2439230
refactor(http): change *ast.Package to json.RawMessage in query requests (#17316) 2020-03-23 12:39:24 -07:00
Alirie Gray e51412f6db
refactor(query): add stack trace to executeQuery in controller (#17377) 2020-03-20 16:01:15 -07:00
jlapacik 6c8125b1e8 chore: update flux dependency 2020-03-20 09:24:39 -07:00
Jonathan A. Sternberg 5f30466b5d
feat(query): update buckets and v1.databases calls (#17294)
The `buckets()` and `v1.databases()` functions have been updated to
support their remote counterparts that were added to flux. These
functions now do the same thing as the `from()` call where they will
default to the current organization when run against the server and will
use the remote versions from the repl.
2020-03-17 10:41:53 -05:00
Christopher M. Wolff 790661c196
test(query/stdlib/influxdata/influxdb): update rules_test to use algo-w (#17295)
Algorithm W will return a semantic graph where every function block
always uses a block and a return statement. This is in contrast to the
Go code which would have the semantic graph be an expression or a block.

The push down code would not introspect blocks which meant that any
function expression produced by algorithm w would never be pushed down.
This fixes it so the code will now extract the semantic expression from
inside of a block if there is exactly one statement and the statement is
a return statement.

Co-authored-by: Jonathan A. Sternberg <jonathan@influxdata.com>
2020-03-16 16:46:51 -07:00
jlapacik 07c9a7c921 fix(stdlib): unskip stateChanges end to end test
Closes https://github.com/influxdata/influxdb/issues/17064.
2020-03-12 15:44:56 -07:00
Jonathan A. Sternberg 45c51128ae build(flux): update Flux to v0.64.0 2020-03-12 10:08:45 -07:00
Jonathan A. Sternberg 8d2ba699a0
refactor(http): remove the spec and update lang usage (#17148)
This removes the spec and updates the lang package usage to make use of
passing in the runtime as a parameter.

It removes all direct dependendencies on the flux runtime from the http
package.
2020-03-09 13:30:43 -05:00
Jonathan A. Sternberg 400d710bc0
refactor(storage/reads): remove the storage dependency on libflux (#17109)
This removes the storage dependency on libflux by moving the interfaces
it implements to the `query` package so it can reference the definitions
rather than the package with the implementation and the registration
with the runtime. This breaks the dependency where a storage package
depends on a flux runtime package.
2020-03-06 19:59:16 -06:00
Jonathan A. Sternberg 0d6e4e310b
Merge branch 'master' into feat/use-algo-w 2020-03-06 16:46:49 -06:00
Yiqun (Ethan) Zhang 5333ff4d1b
feat(transpiler): support difference(), group by wildcard, and correc… (#17021)
* feat(transpiler): support difference(), stddev(), spread(), group by wildcard, and correct _time column
2020-03-06 11:19:46 -05:00
Jonathan A. Sternberg bcbb9df72e
refactor(task): tasks will now use the flux language service (#17104)
The tasks subsystem will now use the flux language service to parse and
evaluate flux instead of directly interacting with the parser or
runtime. This helps break the dependency on the libflux parser for the
base influxdb package.

This includes the task notification packages which were changed at the
same time.
2020-03-05 14:36:58 -06:00
Jonathan A. Sternberg a907e05426
refactor(http): modify query handler to use a language service (#17074)
The language service abstracts away the parse source which breaks the
dependency without moving any of the code.
2020-03-05 10:32:17 -06:00
jlapacik 3250fb1453 fix(stdlib): update flux dependency and unskip test 2020-03-05 08:24:51 -08:00
Christopher M. Wolff 027d29dd30
chore: update to Flux version v0.63.0 (#17083) 2020-03-03 13:17:37 -08:00
Jonathan A. Sternberg a84df749cc
feat(stdlib): add influxdb source (#17047)
This updates the repl to support the new influxdb source and use it by
default in the repl. It will automatically set some default variables
for the influxdb source to make it easier to use the cli. In particular,
it will set the default organization, token, and the host. The
organization gets set to the one specified in the repl command and the
token gets filled in with the user installed one. The host defaults to
localhost but will change to whichever one was specified on the cli.

In addition, this will replace the http client with one that sets
insecure skip verify if the `--skip-verify` flag is used.
2020-03-02 20:08:19 -06:00
jlapacik 03cfdba832 fix(stdlib): unskip flux end to end tests
Closes https://github.com/influxdata/influxdb/issues/16812.
2020-03-02 13:47:03 -08:00
Jonathan A. Sternberg 0872af8553
refactor: update semantic builtin lookups to use runtime now (#17066) 2020-03-02 14:51:49 -06:00
Christopher M. Wolff 7547ab8fc2
chore: update to Flux v0.62.0 (#17048) 2020-02-28 10:53:10 -08:00
Jonathan A. Sternberg 25b0e37522
feat: add support for pkg-config (#17036)
This adds support for using pkg-config to build libflux inside of the
flux dependency. The build can occur by either installing `pkg-config`
into your path or the `env` script can be used to invoke it from the go
modules.
2020-02-28 11:08:21 -06:00
Jonathan A. Sternberg ff848bcd55
refactor(repl): remove the querier from the repl (#17031)
The repl no longer takes in a querier and it will run everything
locally. The spec interface will now not be used and will be removed
from the http endpoint at some point.
2020-02-27 15:06:38 -06:00
Jonathan A. Sternberg 935180e9bd
refactor: update flux for the runtime package (#17002) 2020-02-27 11:31:45 -06:00
docmerlin (j. Emrys Landivar) cbbb5db71a fix(tasks): update to newer github.com/influxdb/cron 2020-02-24 09:20:05 -06:00
jlapacik 2c184ead7f chore: update flux dependency and unskip notification tests
Fixes https://github.com/influxdata/influxdb/issues/16809.
2020-02-21 14:58:41 -08:00
jlapacik b01e194613 chore: update flux dependency in promqltests 2020-02-21 14:03:02 -08:00
Jonathan A. Sternberg 7c88946eab
build(flux): update flux for promqltests (#16968) 2020-02-21 14:23:16 -06:00