Commit Graph

12222 Commits (91e7aaee09a4c086164ca1058221f7249d6c584c)

Author SHA1 Message Date
Stuart Carnie 91e7aaee09 fixes a memory leak when NewReaderIterator creates a nilFloatIterator 2017-08-09 14:46:44 -07:00
Edd Robinson 392fa03cf3 Merge pull request #8660 from influxdata/er-8640-show-tag-values
Improve performance of SHOW TAG VALUES
2017-08-03 17:25:59 +01:00
Edd Robinson 0f648e5170 Remove unsafe shenanigans 2017-08-03 16:38:05 +01:00
Edd Robinson 7c67718d60 Update CHANGELOG 2017-08-02 18:19:04 +01:00
Edd Robinson 2d57b599e9 Remove debugging statement 2017-08-02 17:24:00 +01:00
Edd Robinson da676a79ae Implement TSI iterator 2017-08-02 16:29:14 +01:00
Edd Robinson befae864bd Add tests for merge function 2017-08-02 14:10:52 +01:00
Edd Robinson aa7095be5a Use a merge-based approach for TagValues 2017-08-02 14:10:52 +01:00
Jason Wilder 94a48774b7 Pull in new index filter 2017-08-02 14:10:52 +01:00
Edd Robinson 1e9ce8e0a7 Add test for TagValues 2017-08-02 14:10:52 +01:00
Jonathan A. Sternberg f5345fbaf2 Merge pull request #8557 from influxdata/js-dynamic-influxql
Introduce a new dynamic language mechanism
2017-08-01 15:59:46 -05:00
Stuart Carnie 5449285c4c Merge pull request #8652 from influxdata/sgc-literal-cursor
Reduce allocations using nil cursors and literal value cursors
2017-08-01 10:20:24 -07:00
Stuart Carnie 6311a19ad4 update CHANGELOG 2017-08-01 10:20:05 -07:00
Jason Wilder 68340c208c Merge pull request #8657 from influxdata/jw-key-cursor
Remove unused filestore reference
2017-08-01 11:07:35 -06:00
Jason Wilder 173276a409 Remove unused filestore reference
Reduces cursor struct size from 119 bytes to 111.
2017-08-01 09:41:16 -06:00
Stuart Carnie ff65f0f24d Reduce allocations using nil cursors and literal value cursors
```
benchmark                           old ns/op     new ns/op     delta
BenchmarkIntegerIterator_Next-8     82.8          22.7          -72.58%

benchmark                           old allocs     new allocs     delta
BenchmarkIntegerIterator_Next-8     3              0              -100.00%

benchmark                           old bytes     new bytes     delta
BenchmarkIntegerIterator_Next-8     32            0             -100.00%
```
2017-07-30 09:15:34 -07:00
Jason Wilder de666db481 Merge pull request #8645 from influxdata/jw-cursors
Reduce memory usage when running queries
2017-07-28 11:47:16 -06:00
Jonathan A. Sternberg fcc5184a81 Merge pull request #8642 from influxdata/js-8639-parse-time-literals-with-location
Parse time literals using the time zone in the select statement
2017-07-28 12:35:50 -05:00
Jason Wilder 3d12c62121 Avoid repeatedly growning decoded values slices 2017-07-28 11:00:56 -06:00
Jason Wilder 778000435a Conver all keys from string to []byte in TSM engine
This switches all the interfaces that take string series key to
take a []byte.  This eliminates many small allocations where we
convert between to two repeatedly.  Eventually, this change should
propogate futher up the stack.
2017-07-28 11:00:50 -06:00
Jason Wilder 8009da0187 Remove some extra cursor buffers that are not needed 2017-07-28 10:53:07 -06:00
Jason Wilder 6582caa78b Reduce allocations when creating KeyCursors
The refs map was to increment the file references one time each.
It doesn't hurt to increment them multiple times though.

We also do not need to copy the files slice as we are accessing it
under a read lock so it can't be changed.
2017-07-28 10:53:07 -06:00
Jason Wilder e1ec73d08f Fix struct alignment to avoid wasting space
Reduces size from 95 to 87.
2017-07-28 10:53:07 -06:00
Jonathan A. Sternberg f541cff2b2 Merge pull request #8646 from influxdata/js-tsdb-shard-group-tests
Improve test cases in the tsdb package for the ShardGroup interface
2017-07-28 10:22:14 -05:00
Ryan Betts 709a19dd39 Merge pull request #8648 from influxdata/ryan-changelog-updates
Update CHANGELOG with 1.3 release dates.
2017-07-27 16:41:46 -07:00
Ryan Betts df88fa3736 Update CHANGELOG with 1.3 release dates. 2017-07-27 16:23:22 -07:00
Jason Wilder 85642e2831 Merge pull request #8630 from influxdata/jw-drop-oom
Prevent excessive memory usage when dropping series
2017-07-27 16:24:52 -06:00
Jonathan A. Sternberg 02d9649be4 Improve test cases in the tsdb package for the ShardGroup interface
tsdb.Shard and tsdb.Shards both implement tsdb.ShardGroup and neither
were tested within the tsdb package itself. This adds tests for those
methods which are used by the query engine.
2017-07-27 17:19:22 -05:00
Jason Wilder 6e6cc991ee Merge pull request #8629 from influxdata/jw-compaction-abort
Interrupt in progress TSM compactions
2017-07-27 16:12:40 -06:00
Jason Wilder c75ac3076f Limit delete to run one shard at a time
There was a change to speed up deleting and dropping measurements
that executed the deletes in parallel for all shards at once. #7015

When TSI was merged in #7618, the series keys passed into Shard.DeleteMeasurement
were removed and were expanded lower down.  This causes memory to blow up
when a delete across many shards occurs as we now expand the set of series
keys N times instead of just once as before.

While running the deletes in parallel would be ideal, there have been a number
of optimizations in the delete path that make running deletes serially pretty
good.  This change just limits the concurrency of the deletes which keeps memory
more stable.
2017-07-27 16:01:47 -06:00
Jason Wilder 18a02d50d7 Interrupt in progress TSM compactions
When snapshots and compactions are disabled, the check to see if
the compaction should be aborted occurs in between writing to the
next TSM file.  If a large compaction is running, it might take
a while for the file to be finished writing causing long delays.

This now interrupts compactions while iterating over the blocks to
write which allows them to abort immediately.
2017-07-27 15:58:56 -06:00
Jonathan A. Sternberg 950753d036 Parse time literals using the time zone in the select statement 2017-07-27 13:05:51 -05:00
Jonathan A. Sternberg ac2a9690a1 Merge pull request #8610 from influxdata/js-8607-time-zone-shifts
Fix time zone shifts when the shift happens on a time zone boundary
2017-07-27 13:05:29 -05:00
Jonathan A. Sternberg 2ac0dc98c6 Merge pull request #8641 from jheusser/patch-1
Update udp port in README to be in valid range
2017-07-27 13:02:57 -05:00
Jonathan Heusser c38d0de99d Update udp port to be in valid range
`80891` is not a valid port, changed to `8189`.
2017-07-27 13:26:37 +01:00
Stuart Carnie c86e94af37 Merge pull request #8635 from influxdata/sgc-xxhash
update xxhash and use Sum64String to avoid allocs
2017-07-26 14:01:37 -07:00
Stuart Carnie 0c79ec6f17 update xxhash and use Sum64String to avoid allocs
```
± benchcmp ring_before.txt ring_after.txt
benchmark                             old ns/op     new ns/op     delta
BenchmarkRing_getPartition_100-8      108           48.1          -55.46%
BenchmarkRing_getPartition_1000-8     113           48.9          -56.73%

benchmark                             old allocs     new allocs     delta
BenchmarkRing_getPartition_100-8      1              0              -100.00%
BenchmarkRing_getPartition_1000-8     1              0              -100.00%

benchmark                             old bytes     new bytes     delta
BenchmarkRing_getPartition_100-8      192           0             -100.00%
BenchmarkRing_getPartition_1000-8     192           0             -100.00%
```
2017-07-26 10:16:54 -07:00
Jonathan A. Sternberg 343cd2e120 Fix time zone shifts when the shift happens on a time zone boundary
When a time zone shift happened at the edge of a time bucket, the logic
was incorrect. When we added an hour to the day with a time grouping of
2 hours, we took the hour away from the previous bucket instead of the
next bucket so the first bucket of the day would be from midnight to 1
AM and the second bucket would include 1 AM to 4 AM (2 AM to 3 AM does
not exist when shifting forwards). The correct buckets should have been
12 AM to 2 AM for the first bucket of the day and 3 AM to 4 AM for the
second (since 2 AM to 3 AM does not exist).

This also modifies the tests to use table tests and sub tests.
2017-07-25 23:36:03 -05:00
Jonathan A. Sternberg fe1167cc44 Merge pull request #8097 from connor4312/return-errors-in-csv
Return errors in CSV responses
2017-07-25 10:05:12 -05:00
Connor Peet 4459e1e8d8 Return errors in CSV responses 2017-07-25 09:44:02 -05:00
Jonathan A. Sternberg 6b616d57c6 Merge pull request #8616 from influxdata/js-influxql-google-cmp
Switch influxql to use google/go-cmp to compare the point structs
2017-07-24 14:48:03 -05:00
Stuart Carnie 6e1f830ecb Merge pull request #8615 from influxdata/sgc-uint-engine
uint64 support for storage layer
2017-07-24 10:07:07 -07:00
Stuart Carnie d243df5ca3 simplify loop 2017-07-24 09:03:22 -07:00
Stuart Carnie eec80692c4 Taught tsm1 storage engine how to read and write uint64 values
* introduced UnsignedValue type
  * leveraged existing int64 compression algorithms (RLE, Simple 8B)
* tsm and WAL can read and write UnsignedValue
* compaction is aware of UnsignedValue
* unsigned support to model, cursors and write points

NOTE: there is no support to create unsigned points, as the line
protocol has not been modified.
2017-07-24 09:03:22 -07:00
Edd Robinson 4a87662d60 Merge pull request #8621 from influxdata/er-go1.8-appveyor
Ensure Windows builds tested with Go 1.8
2017-07-24 16:28:43 +01:00
Edd Robinson e7f4b556fa Ensure Windows builds tested with Go 1.8 2017-07-24 13:56:19 +01:00
Jonathan A. Sternberg 8609c2c02a Switch influxql to use google/go-cmp to compare the point structs
The diff will improve the debug message when a test fails. Right now,
the message is unreadable. The diff message from go-cmp is much better.
2017-07-21 14:05:27 -05:00
Jason Wilder 62534ce5c1 Merge pull request #8617 from influxdata/jw-go-19
Add go1.9 and tsi builders to circle
2017-07-21 13:03:49 -06:00
Jason Wilder 2c33919f9c Add build for go 1.9 2017-07-21 12:37:52 -06:00
Jason Wilder 01145d4e7e Add builder for tsi tests 2017-07-21 11:48:51 -06:00