Commit Graph

11680 Commits (a8018532b2a9d6a6be4a6bf69d29a32723c969ed)

Author SHA1 Message Date
Mark Rushakoff a8018532b2 test(task): fix two flaky tests
In TestScheduler_RunLog, the run log gets updated asynchronously so we
need to poll to ensure we don't read a stale value.

In TestScheduler_CreateNextRunOnTick, we were previously reading the
one entry out of two from a map, so it was often the entry we weren't
interested in.
2018-08-29 10:02:45 -07:00
Andrew Watkins 2e0af93c59
chore(chronograf): move tests out of test dir
* chore(chronograf): remove logs

* chore(chronograf): delete dead code

* chore(chronograf): move tests out of test dir

* Move test resources out of test dir

* chore(chronograf): remove test dir
2018-08-29 09:11:01 -07:00
Mark Rushakoff a177069b49 ci: restore cache for deploy job
The last few runs of deploy took 3m33s, 3m40s, and 4m27s. It should be
noticeably faster after we restore the cache.
2018-08-28 15:20:36 -07:00
Mark Rushakoff 8a6749fc1c ci: share yarn cache on Circle
On a cache miss, `yarn install` via `make node_modules` takes about 42
seconds, plus about 19 seconds to upload the cache. See
https://circleci.com/gh/influxdata/platform/1872.

On a cache hit, `make node_modules` takes about 7 seconds to download
the cache plus 19 seconds to `yarn install`. See
https://circleci.com/gh/influxdata/platform/1877. Using the cache here
is a net gain of about 16 seconds on cache hit, which is the most likely
case given a random commit.
2018-08-28 14:43:04 -07:00
Jonathan A. Sternberg 5b4506db1d
Merge pull request #725 from influxdata/js-default-memory-limit-for-planner
feat(query/plan): make it possible to configure the default memory limit for queries
2018-08-28 16:40:42 -05:00
Jonathan A. Sternberg aa052e1a57 feat(query/plan): make it possible to configure the default memory limit for queries
The previous default was just to have no limit at all. This adds a
configuration option to the planner so a static value can be set for the
memory limit on each individual query.
2018-08-28 16:24:49 -05:00
Mark Rushakoff 66b0ea1f14 ci: cache dep too
Running `dep ensure` via `make vendor`, with a clean dep cache, takes
around 30 seconds.

For run https://circleci.com/gh/influxdata/platform/1838, we can see
that `make vendor` took 33 seconds and saving the dep cache took 38
seconds. The 38 seconds to save the dep cache is paid the first time
that a particular version of Gopkg.lock is pushed. A subsequent run that
fully uses the dep cache costs 14 seconds to restore the dep cache and 5
seconds to run `make vendor`, so this saves about 10 seconds for any run
that doesn't change Gopkg.lock. See
https://circleci.com/gh/influxdata/platform/1840.
2018-08-28 13:59:25 -07:00
Mark Rushakoff d26233f47e ci: enable GOCACHE for Circle
With a clean GOCACHE, `make test-go` took about 30 seconds. It's hard to
tell the exact time since `make vendor` was implicitly executed in the
same block.

Now, `make test-go` uses GOCACHE and takes about 5 seconds to restore
the cache, then about 8 seconds to run through a fully cached set of
tests. If any test is actually broken or doesn't compile, this will give
us fast feedback.

But this change also runs `go test -race -count=1`, so that we fully
exercise any possible data races. That currently takes about 19 seconds.

Then finally we save GOCACHE, which has our `go test` results, and a
populated build cache for our test files, including built with the race
detector. Saving that takes about 14 seconds.

That means we took about 30 seconds originally to just run `go test
-count=1`, and now we take (5+8+19+14)=46 seconds to run plain go test
and go test with the race detector. There's probably an argument to be
made for just running with the race detector, but running both gives us
more coverage IMO, and it does allow us to run tests that aren't enabled
on race builds.

See https://circleci.com/gh/influxdata/platform/1840 for a run with full
caching.
2018-08-28 13:59:25 -07:00
Mark Rushakoff 548bf5d3da ci: use Go 1.11 in CircleCI 2018-08-28 13:59:25 -07:00
Michael Desa 2efa84131d
Merge pull request #648 from influxdata/594-query-request-struct
Using query request struct to query resources
2018-08-28 15:55:58 -04:00
Michael Desa 45233d939a feat(platform): add uniform query endpoint for sources
Using query request struct to query resources

Signed-off-by: Lorenzo Fontana <lo@linux.com>

Use query.ProxyRequest instead query.Request

Signed-off-by: Lorenzo Fontana <lo@linux.com>

Proxy request from idpd

Signed-off-by: Lorenzo Fontana <lo@linux.com>

Comments about the desired results

Signed-off-by: Lorenzo Fontana <lo@linux.com>

V1 endpoints working with flux

Signed-off-by: Lorenzo Fontana <lo@linux.com>

Influxql working for v1

Signed-off-by: Lorenzo Fontana <lo@linux.com>
Co-authored-by: Michael De Sa <mjdesa@gmail.com>

V2 influxql query endpoint working

Signed-off-by: Lorenzo Fontana <lo@linux.com>
Co-authored-by: Michael De Sa <mjdesa@gmail.com>
Signed-off-by: Lorenzo Fontana <lo@linux.com>

V2 Flux compiler support

Co-authored-by: Michael De Sa <mjdesa@gmail.com>
Signed-off-by: Lorenzo Fontana <lo@linux.com>

Improve comments in bolt sources and give error on self

Signed-off-by: Lorenzo Fontana <lo@linux.com>
Co-authored-by: Michael De Sa <mjdesa@gmail.com>

Review tests failing

Signed-off-by: Lorenzo Fontana <lo@linux.com>
Co-authored-by: Michael De Sa <mjdesa@gmail.com>

Avoid type casts for compiler types

Signed-off-by: Lorenzo Fontana <lo@linux.com>
Co-authored-by: Michael De Sa <mjdesa@gmail.com>

Using nil instead of dbrp mapping service for influxql v1

Signed-off-by: Lorenzo Fontana <lo@linux.com>

Check if compiler types are valid for influxql

Signed-off-by: Lorenzo Fontana <lo@linux.com>

Organization as query param in the flux external handler

Signed-off-by: Lorenzo Fontana <lo@linux.com>

feat(http): update swagger documentation for flux query endpoint

feat(http): document query endpoint design

The code documented does not currently work. It is indended that this
will be implemented in follow up PRs.

feat(platform): move source to platform package

The source Query endpoint implements what's in the query swagger docs

Signed-off-by: Lorenzo Fontana <lo@linux.com>
Co-authored-by: Michael De Sa <mjdesa@gmail.com>

feat(platform): allow for encoding and decoding of csv dialects

feat(platform): specify dialect in flux page

Co-authored-by: Andrew Watkins <andrew.watkinz@gmail.com>
Co-authored-by: Michael Desa <mjdesa@gmail.com>
2018-08-28 15:53:20 -04:00
Jonathan A. Sternberg bb4fc188a2
Merge pull request #721 from influxdata/js-query-log-statistics
fix(query): report query statistics correctly
2018-08-28 12:55:22 -05:00
Jonathan A. Sternberg 1fe16a04de fix(query): report query statistics correctly
The query statistics would only be read after the cancel call so we need
to wait for that before attempting to read the statistics rather than
attempting to read them immediately after the result is returned (before
it is read).
2018-08-28 12:39:56 -05:00
Nathaniel Cook 0c3d9a52a4 Merged pull request #720 from influxdata/nc-object-race
fix: Fixes data race on object type
2018-08-28 11:24:11 -06:00
Nathaniel Cook a9f10e11a5 fix: Fixes data race on object type 2018-08-28 10:39:56 -06:00
Mark Rushakoff caa4539d0e fix(task): fix data race in scheduler 2018-08-28 08:11:16 -07:00
Nathaniel Cook 5b9b111166 Merged pull request #714 from influxdata/nc-fix-query-panic
fix: Fixes panic in query from sharing builtin decls
2018-08-28 09:09:34 -06:00
Chris Goller bb7d80e7bd
Merge pull request #692 from influxdata/feature/write-swagger
docs(http): add write endpoint documentation
2018-08-27 16:25:09 -07:00
Chris Goller 878ca0f95b docs(http): add further description for 401 on /write 2018-08-27 18:21:31 -05:00
Chris Goller eb443cad53 docs(http): remove outside of retention duration 2018-08-27 18:01:22 -05:00
Chris Goller b136d75af3
Merge pull request #699 from influxdata/feature/authorization-enable-disable
docs(http): add disabled boolean for authorization tokens
2018-08-27 15:39:58 -07:00
Adam 05a2feb1fc
Added default signature generators for Selector and Aggregate configs and update the functions that need them (#690)
* Added default signature generators for Selector and Aggregate configs and update the functions that need them

* fix to percentile to collect the correct arguments for both aggregate and selector
2018-08-27 17:20:18 -04:00
Nathaniel Cook 796fd7217e Merged pull request #685 from influxdata/nc-hist-quantile
feat: Add histogramQuantile function
2018-08-27 14:25:35 -06:00
Nathaniel Cook 937158f63a Merged pull request #715 from influxdata/nc-data-race
fix: Fixes #697 data race in execute test
2018-08-27 14:19:59 -06:00
Jonathan A. Sternberg cbea2b9bee
Merge pull request #708 from influxdata/js-disable-influxql-join
fix(query/influxql): disable the join behavior in the transpiler
2018-08-27 15:06:30 -05:00
Nathaniel Cook 575c8138cc fix: Fixes #697 data race in execute test 2018-08-27 13:57:51 -06:00
Nathaniel Cook c6567a9ed1 fix: Fixes panic in query from sharing builtin decls 2018-08-27 13:48:13 -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
Chris Goller 6b6aad3478 docs(http): add org parameter to writes 2018-08-27 11:58:14 -05:00
Nathaniel Cook cf072cbd4d fix: Add end to end test for histogramQuantile 2018-08-27 10:15:59 -06:00
Nathaniel Cook a2e7ba3422 Merged pull request #701 from influxdata/nc-builtins
fix: Fix missing builtins in REPL
2018-08-27 09:52:31 -06:00
Nathaniel Cook 61bc6df75b fix: Fix missing builtins in REPL
The REPL's use of the interpreter was causing it to not get the builtins
defined in builtin scripts. For example the `top` function was missing.

This change fixes the issues by ensuring the builtins are only evaluated
once and that there is only one way to get the query Interpreter that is
guaranteed to have the proper builtins.
2018-08-27 09:46:13 -06:00
lukevmorris 7e9f90dbce
chore(ci): parallelize js and go tests (#670)
This PR teases apart the golang and js build steps so that they can be run in parallel in circleci, or locally with make test -j2.

Closes #599
2018-08-27 08:34:17 -07:00
Mark Rushakoff f72ed76a47 feat(task): handle manual runs in scheduler 2018-08-26 20:34:05 -07:00
Mark Rushakoff ac03771c62 feat(task): handle manual runs in StoreTaskMeta.CreateNextRun 2018-08-26 20:34:05 -07:00
Mark Rushakoff 4573c16367 feat(task): add ManuallyRunTimeRange to Store 2018-08-26 20:34:05 -07:00
Chris Goller 42f6b278e4 docs(http): add 422 response for writes where points outside of RP 2018-08-26 12:54:12 -05:00
Chris Goller 957e3f72ae docs(http): remove minutes and hours from precision on write 2018-08-26 10:23:34 -05:00
Chris Goller 48107600f2 docs(http): fix swagger formatting for /write route 2018-08-26 10:20:58 -05:00
Chris Goller 4fd19c0054 docs(http): add content-type, content-length, and accept to /write 2018-08-26 10:18:05 -05:00
Chris Goller c85517fcdf docs(http): fix header in write to be content-encoding 2018-08-26 10:01:30 -05:00
Chris Goller 52e71f9592 docs(http): add identity support in Accept-Encoding for write 2018-08-26 09:54:09 -05:00
Chris Goller 0da3fa9122 docs(http): document write over quota response 2018-08-26 09:49:54 -05:00
Chris Goller d4c95ccc5f docs(http): update database to bucket 2018-08-26 09:42:21 -05:00
Adam Perlin 015afb74db
Materialize Empty Windows (#689)
Update window to materialize all windows within bounds
2018-08-24 17:13:31 -07:00
Stuart Carnie 2cf8145789
Merge pull request #700 from influxdata/sgc-influxdb
chore: Update influxdata/influxdb:platform vendor dependency
2018-08-24 15:42:08 -07:00
Stuart Carnie e96091b211 chore: Update influxdata/influxdb:platform vendor dependency 2018-08-24 15:36:56 -07:00
Chris Goller 54999f3207 docs(http): add disabled boolean for authorization tokens 2018-08-24 14:20:19 -07:00
Stuart Carnie ef5f42a03a
Merge pull request #695 from influxdata/sgc-read
refactor(pb): Consolidate and use refactored storage APIs from influxdb
2018-08-24 12:33:10 -07:00
Stuart Carnie cc88c2f608 refactor(pb): Consolidate to use refactored storage APIs from influxdb
* updated influxdata/influxdb:platform vendor dependency
2018-08-24 12:26:45 -07:00