Commit Graph

100 Commits (7ea1db0079f7fad3049d61ffc6ea49f7835cb735)

Author SHA1 Message Date
Adam af0cad76ba
chore(query/influxql): moved query_test.go and requisite files to the influxql dir to be closer to the code it tests. (#2013) 2018-12-20 11:48:33 -05:00
Jonathan A. Sternberg cc93531400 fix(storage): convert the storage table interface to use arrow buffers
The table interface was modified to expose the arrow buffers. The
storage table has now been converted to use this interface with the same
fixes so that it exposes arrow buffers.

The influxql package has also been updated to use the `DoArrow` method
from the `flux.Table` interface.
2018-12-18 09:47:53 -07:00
Christopher M. Wolff f1d21b8132
refactor(query): update transpiler to reflect signature change to `group()` (#1689)
update other modules that used old syntax as well
2018-12-04 09:32:37 -08:00
Edd Robinson 9403c1ec8e Ensure error strings not capitalised ST1005 2018-11-30 10:54:24 +00:00
Ben Johnson 1862b4421d
Integrate scanned values statistics tracking. 2018-11-28 15:32:06 -07:00
Lorenzo Affetti 987370d1c9
Merge pull request #1565 from influxdata/la-median-transp
Support for median in transpiler
2018-11-27 17:38:35 +01:00
Lorenzo Affetti eda4a59c35 Support for median in transpiler 2018-11-27 17:23:29 +01:00
jlapacik 2b52224e84 update flux dependency - add missing Statistics() methods 2018-11-26 13:19:14 -08:00
jlapacik 17413276c2 update transpiler result iterators with new Statistics method 2018-11-26 12:17:16 -08:00
Adam 41aa5688a0
Add default column to databases and add support for `show retention policies` (#1423)
* Add default column to databases to support `show retention policies`

* add unit test for show retention policies

* update transpiler readme for show databases, show retention policies
2018-11-16 15:20:49 -05:00
Christopher M. Wolff bbd460e7d9
Add method QueryRawJSON to influxql.service (for querytest tool) (#1402) 2018-11-15 10:45:38 -08:00
Adam 2321d81291
Feat/transpiler show databases (#1363)
* feat(query): databases transformation implementation
add show databases to transpiler
2018-11-13 16:07:28 -05:00
Adam c950a6dc00
fix to transpiler result encoder when there's no _time column (#1350)
* fix to transpiler result encoder when there's no _time column
* add unit tests
2018-11-12 15:35:16 -05:00
Jonathan A. Sternberg fadf4f3e4f
deps: update flux dependency 2018-11-08 14:49:35 -06:00
jlapacik 3a6810c7ff generated influxql json tests 2018-11-06 14:04:40 -08:00
Jonathan A. Sternberg 66920f253a
fix: show tag values must specify a range stop 2018-11-06 09:17:37 -06:00
Nathaniel Cook 9fecaa0eb0 chore: Update for Flux renaming 2018-11-05 19:30:22 -07:00
Mark Rushakoff dae3dc8a7e chore(bolt,http,mock,query,testing): fix megacheck errors 2018-11-01 12:54:46 -07:00
Nathaniel Cook 2a1d76eb2d chore: Update flux dependency for the type-inference changes 2018-10-31 17:11:11 -06:00
Adam 98be8bcd32
moved to_http and to_kafka to flux and update to latest flux (#1175) 2018-10-24 12:33:43 -04:00
Chris Goller 2bea48f15a refactor(testing): rename MustIDFromString to MustIDBase16 2018-10-11 09:54:19 -05:00
Leonardo Di Donato 8d7f06cf4b feat(platform/id): using uint64 for platform.IDs
Signed-off-by: Leonardo Di Donato <leodidonato@gmail.com>
Co-Authored-by: Lorenzo Fontana <lo@linux.com>
2018-10-11 09:54:18 -05:00
Adam 195eb04350
Chore/move from function to platform (#1013)
* moved execution code for from into query/functions/inputs

* rebase with master, disable buckets accessed test
2018-10-09 20:36:41 -04:00
Chris Goller 90494a5309 chore(fmt): fix and simplify go formatting 2018-10-08 17:23:54 -05:00
Adam 58f4e9fc0b
Refactor Platform according to new organization in `flux` (#966)
We reorganized the functions in flux to have the structure:
/functions
/inputs
/transformations
/outputs
this PR catches up platform to work with the new package layout.

As a separate refactoring issue, we should discuss:

from(bucket: ) should migrate from flux --> platform
to_http and to_kafka should migrate from platform --> flux
2018-10-05 00:06:14 -04:00
Jonathan A. Sternberg 37ffbfc687
feat: add an influxql service that communicates with influxdb 1.x
It creates a simple client that follows the QueryService interface and
uses the `influxql.Compiler` type to determine where the query should be
routed to and to return the query as a `flux.ResultIterator`.

This will be useful for replaying transpiler queries against influxdb
1.x servers to verify correctness.
2018-10-03 11:17:29 -05:00
Jonathan A. Sternberg 9cda24a69c
adding a test for the measurements and fixing the functionality 2018-09-25 10:25:58 -05:00
Jonathan A. Sternberg 129186efec
feat: implement basic show tag values in the transpiler 2018-09-24 15:02:05 -05:00
Jonathan A. Sternberg d5631c3366 docs(query/influxql): update the transpiler doc for show tag values 2018-09-14 16:59:38 -05:00
Jonathan A. Sternberg e884764664 fix(query/influxql): fix the formatting of the influxql readme
The previous format was easier to edit and I reorganized the headers.
2018-09-14 16:33:27 -05:00
Jonathan A. Sternberg dfc32d2635 feat(query/influxql): normalize the time for all aggregate queries
The transpiler will normalize the `_time` column by dropping any
existing time column and then duplicating `_start` when the query is an
aggregate type.

This works for the selectors because they did not normalize their
`_time` column at all and, while the aggregates did normalize their
`_time` column, we have made the decision to remove that functionality
and have aggregates not set a `_time` column at all.
2018-09-12 16:25:51 -05:00
Adam 4733ecd1f2
README + initial skeleton in place for SHOW TAG VALUES(#815)
* README + initial skeleton in place

* Fixes according to review
2018-09-12 14:54:13 -04:00
Jonathan A. Sternberg 131767572e feat(query/influxql): update the spec for time normalization in selectors 2018-09-11 13:09:48 -05:00
Jonathan A. Sternberg a5641f6fd9 fix(query/influxql): join multiple aggregates with the new join function 2018-09-10 11:54:38 -05:00
Stuart Carnie ac75af2f58 refactor: Migrate query package to influxdata/flux repository 2018-09-06 11:13:48 -07:00
Jonathan A. Sternberg a45bd08cf6 docs: update the transpiler docs to use pivot
Instead of generating multiple cursors, a pivot is used to join fields
within the same series.

This should be easier than generating a new cursor for everything.
2018-08-31 16:15:28 -05:00
Michael Desa 4eb2b72bf3 feat(query/influxql): implement query.ResultIterator for influxql.Response
WIP: saving state reword

feat(query/influxql): implement query.ResultIterator directly on response

review(influxql): add ResponseIterator that implement query.ResultIterator

review(influxql): update code is response to review
2018-08-31 13:38:25 -04:00
Nathaniel Cook 46a32e874c chore: Update 'from' to match spec
Removes the `db` parameter and used only bucket and bucketID.
2018-08-30 14:51:51 -06:00
Jonathan A. Sternberg 22673adee7 fix(query/influxql): disable the join behavior in the transpiler
The behavior needs to be updated so we are goinig to just disable it
temporarily so bad query specs are not generated.
2018-08-27 12:41:53 -05:00
Adam Perlin 302aaee1f5
Bounds Refactor (#675)
* Refactor bounds in planner
2018-08-23 15:58:29 -07:00
Jonathan A. Sternberg 3e7a04e887
Merge pull request #624 from influxdata/js-godoc-query-package
docs(query): add package docs for the packages in the query package
2018-08-13 16:07:16 -05:00
Jonathan A. Sternberg 73b4b1d0d8 docs(query): add package docs for the packages in the query package 2018-08-13 15:21:02 -05:00
jlapacik 27b2093116 new join implementation
This commit provides a new join implementation that can join
tables with different group keys. It also implements a strategy
for evicting stale data from the join operation's cache when
it can be determined that a table will no longer be joined.

Currently early table eviction from the buffers of the join occurs
when the left-most group key column of both input streams are equal
and that column is part of the join key.
2018-08-13 10:51:57 -07:00
Nathaniel Cook 5bde0b5be6 fix: Update query services to use Request type
Moves idpe.QueryService into platform/query.ProxyQueryService
Splits the Request into ProxyRequest and Request.

Changes query.QueryService and query.AsyncQueryService to use a Request
type. This means that the Compiler interface is consumed by the service
to abstract out transpilation vs Flux compilation vs raw spec.

The transpiler handler is removed.

There are separate http handlers and service implementations for each of
the three query services.

Query logging types are moved into platform.

The ResultIterator now expects Cancel to always be called.

The fluxd binary exposes the query endpoint specified in the swagger
file.
2018-08-08 15:31:35 -06:00
Michael Desa 8c87c9d132 revert #442 2018-08-01 14:54:32 -04:00
Leonardo Di Donato 5addb88eb5 MustIDFromString no more requires test instance
It panics now.
2018-08-01 18:20:59 +02:00
Leonardo Di Donato 3191de776d Refactoring code using platform.IDs
Signed-off-by: Leonardo Di Donato <leodidonato@gmail.com>
2018-08-01 18:20:59 +02:00
Leonardo Di Donato 4387206181 Other test for IDs
Signed-off-by: Leonardo Di Donato <leodidonato@gmail.com>
2018-08-01 18:20:59 +02:00
Leonardo Di Donato 0778344cb0 Refactoring query package 2018-08-01 18:20:59 +02:00
Jonathan A. Sternberg c94fc4d799 fix(query/influxql): include default parameters in the range spec 2018-07-31 12:53:34 -05:00