Commit Graph

13923 Commits (4e62c3f795a61c99647477464329cac59bdf0628)

Author SHA1 Message Date
Jeff Wendling 4e62c3f795 fix(tsm1): return boolean array iterator for booleans
booleans are still not strings.
2018-08-27 11:32:15 -06:00
Stuart Carnie badc1d8ed3 fix(storage): Fix potential panic if nil is returned 2018-08-24 15:05:48 -07:00
Stuart Carnie 59bd822af9 refactor(storage): Export subset of APIs to facilitate reuse
* the protocol service definition, ReadRequest and ReadResponse is
  reused across projects, rather than requiring redefinition.

* the ReadRequest protocol buffer definition removes the concept of a
  database and retention policy, replacing it with a field named
  ReadSource of type google.protobuf.Any. OSS requests will use the
  ReadSource message structure defined in local to this package, which
  defines fields to represent a Database and RetentionPolicy. Other
  implementations can provide their own data structure allowing the
  remainder of the ReadRequest to be reused.

* The RPC service and Store are expected to be redefined to handle their
  specific requirements for resolving a ReadSource

* ResultSet and GroupResultSet are interfaces representing non-grouping
  and grouping read behavior respectively. Calling NewResultSet or
  NewGroupResultSet will construct instances of these types

* The ResponseWriter type is exported to deal with serialization of
  the ResultSet and GroupResultSet types
2018-08-24 11:56:04 -07:00
Stuart Carnie 2f4fcd8255 chore: Remove BatchCursor references 2018-08-24 11:56:04 -07:00
Edd Robinson 74185d29e6
Merge pull request #10226 from influxdata/er-tsl-unmap
Unmap LogFile on successful open
2018-08-24 12:12:14 +01:00
Hercules Mango Churchill cfd4b0d35d Update changelog 2018-08-23 17:17:43 +00:00
David Norton 05d979d6b1
Merge pull request #10215 from influxdata/dn-snappy-digests
Switch digests to use snappy compression
2018-08-23 13:17:28 -04:00
David Norton 2f6a1fc03b switch digests to use snappy compression 2018-08-23 13:02:12 -04:00
Edd Robinson 9970620ee0 Unmap LogFile on successful open
Since we append to the file itself, once we have read the file in, we
can be done with the mmap'd data.

Ideally we can rework UnmarshalBinary and do away with the mmap
completely. That is future work.
2018-08-23 17:24:22 +01:00
Stuart Carnie e685556c81 fix(tsm1): Fix panic when calling Close twice on a descending cursor. 2018-08-22 13:49:59 -07:00
Jeff Wendling 6150bc1eea
Merge pull request #10217 from influxdata/jmw-cursor-iterator-fix
fix(tsm1): return boolean iterator for booleans
2018-08-21 14:31:38 -06:00
Jeff Wendling d258361fb4 fix(tsm1): return boolean iterator for booleans 2018-08-21 13:51:35 -06:00
Hercules Mango Churchill a8fd8d787d Update changelog 2018-08-21 17:27:43 +00:00
Edd Robinson 61a11c1b64
Merge pull request #10212 from influxdata/er-retention-index
Ensure orhpaned series cleaned up with shard drop
2018-08-21 18:20:07 +01:00
Edd Robinson ca1b780906
Merge pull request #10213 from influxdata/er-test-go1.11
Test InfluxDB on Go 1.11rc1
2018-08-21 18:19:25 +01:00
Edd Robinson 663566e3e0 Ensure go fmt passes on 1.10/11 2018-08-21 17:39:42 +01:00
tmgordeeva df001c117c
Merge pull request #10200 from influxdata/tg-auth
httpd/meta: use open auth when unrestricted
2018-08-21 08:40:23 -07:00
Edd Robinson 1a5bcd29da Test InfluxDB on Go 1.11rc1 2018-08-21 15:49:14 +01:00
Edd Robinson f52de2d1e7 Ensure orphaned series removed from inmem index
This commit ensures that any orphaned series (series that are to be
removed and no longer are referenced anywhere in the database) are
removed from the `inmem` index when a shard is dropped.
2018-08-21 15:00:35 +01:00
Edd Robinson dece5b847f Refactor index names 2018-08-21 14:32:30 +01:00
Tanya Gordeeva 9d711d9417 httpd/meta: use open auth when unrestricted
This changes adds additional auth shortcutting, primarily for enterprise
usecases with simple FGA setups. OSS users won't see any changes.
2018-08-20 12:55:40 -07:00
Edd Robinson a67f15fad4 Promote DropSeriesGlobal to Index interface 2018-08-20 17:57:16 +01:00
Edd Robinson 035b26cadd Refactor DropSeriesGlobal 2018-08-20 16:37:55 +01:00
Ben Johnson 2d266ca186
Merge pull request #9801 from influxdata/bj-validate-write
Add option for unicode validation.
2018-08-20 03:44:41 -10:00
Edd Robinson 5536493f51
Merge pull request #10209 from liukun4515/fix_typos
fix the comments error
2018-08-20 12:17:32 +01:00
liukun ee9892dea5 fix the comments error 2018-08-20 17:19:35 +08:00
Jeff Wendling c314fc494e
Merge pull request #10202 from influxdata/jmw-snowflake-improvements
pkg/snowflake: be more robust against sequence rollover
2018-08-16 13:59:07 -06:00
Jeff Wendling 35645a67f5 pkg/snowflake: be more robust against sequence rollover
it's slightly slower, but the safety is worth it i think.

```
name            old time/op  new time/op  delta
Next-8          30.0ns ± 2%  31.0ns ± 3%   +3.56%  (p=0.002 n=7+8)
NextParallel-8  79.4ns ± 1%  92.5ns ± 1%  +16.58%  (p=0.000 n=8+8)
```
2018-08-16 11:18:06 -06:00
Jeff Wendling 5c38332fa2
Merge pull request #10197 from influxdata/jmw-snowflake-contention
pkg/snowflake: reduce contention in Next calls
2018-08-15 19:50:58 -06:00
Jeff Wendling d4a08ce5c1 pkg/snowflake: reduce contention in Next calls
use atomics rather than mutexes to synchronize state between calls.

```
name            old time/op  new time/op  delta
Next-8           244ns ± 0%    30ns ± 2%  -87.70%  (p=0.000 n=8+7)
NextParallel-8   215µs ±60%     0µs ± 1%  -99.96%  (p=0.000 n=8+8)
```

The results for NextParallel are around ~80ns/op, but that doesn't
show up in the benchstat output.
2018-08-15 15:12:21 -06:00
Tim Brooks fee13d0150 Minor fix for legacy restore (#9978)
Restore would fail when file paths contained extra periods.
Taking the basename of the files fixes this.
2018-08-15 09:06:44 -04:00
Hercules Mango Churchill ccc4fae0b5 Update changelog 2018-08-10 15:52:39 +00:00
Edd Robinson b7f1097176
Merge pull request #10190 from influxdata/er-tagsets
Reduce allocations in TSI TagSets implementation
2018-08-10 16:52:23 +01:00
Edd Robinson 6b3860e9a1 Reduce allocations in TSI TagSets implementation
Since all tag sets are materialised to strings before this method
returns, a large number of allocations can be avoided by carefully
resuing buffers and containers.

This commit reduces allocations by about 75%, which can be very
significant for high cardinality workloads.

The benchmark results shown below are for a benchmark that asks for all
series keys matching `tag5=value0'.

name                                               old time/op    new time/op    delta
Index_ConcurrentWriteQuery/inmem/queries_100000-8     5.66s ± 4%     5.70s ± 5%     ~     (p=0.739 n=10+10)
Index_ConcurrentWriteQuery/tsi1/queries_100000-8      26.5s ± 8%     26.8s ±12%     ~     (p=0.579 n=10+10)
IndexSet_TagSets/1M_series/inmem-8                   11.9ms ±18%    10.4ms ± 2%  -12.81%  (p=0.000 n=10+10)
IndexSet_TagSets/1M_series/tsi1-8                    23.4ms ± 5%    18.9ms ± 1%  -19.07%  (p=0.000 n=10+9)

name                                               old alloc/op   new alloc/op   delta
Index_ConcurrentWriteQuery/inmem/queries_100000-8    2.50GB ± 0%    2.50GB ± 0%     ~     (p=0.315 n=10+10)
Index_ConcurrentWriteQuery/tsi1/queries_100000-8     32.6GB ± 0%    32.6GB ± 0%     ~     (p=0.247 n=10+10)
IndexSet_TagSets/1M_series/inmem-8                   3.56MB ± 0%    3.56MB ± 0%     ~     (all equal)
IndexSet_TagSets/1M_series/tsi1-8                    12.7MB ± 0%     5.2MB ± 0%  -59.02%  (p=0.000 n=10+10)

name                                               old allocs/op  new allocs/op  delta
Index_ConcurrentWriteQuery/inmem/queries_100000-8     24.0M ± 0%     24.0M ± 0%     ~     (p=0.353 n=10+10)
Index_ConcurrentWriteQuery/tsi1/queries_100000-8      96.6M ± 0%     96.7M ± 0%     ~     (p=0.579 n=10+10)
IndexSet_TagSets/1M_series/inmem-8                     51.0 ± 0%      51.0 ± 0%     ~     (all equal)
IndexSet_TagSets/1M_series/tsi1-8                     80.4k ± 0%     20.4k ± 0%  -74.65%  (p=0.000 n=10+10)
2018-08-10 16:01:49 +01:00
Edd Robinson 9f883c8dee Add benchmark for TagSets across indexes 2018-08-10 16:01:49 +01:00
Jonathan A. Sternberg 73798764c4
Merge pull request #10149 from influxdata/js-dep-0.5
Run dep ensure with dep 0.5.0
2018-08-10 09:49:18 -05:00
Jonathan A. Sternberg 16dd24bbb2 Run dep ensure with dep 0.5.0 2018-08-10 09:29:10 -05:00
Hercules Mango Churchill 0c724f1ce4 Update changelog 2018-08-10 13:50:59 +00:00
David Norton 91d55b98e1
Merge pull request #10181 from influxdata/dn-fix-line-proto-panic
Fix line protocol parsing panic
2018-08-10 09:48:42 -04:00
Stuart Carnie 12f7f45707 feat(tsdb): Add CursorType to enable selection of batch cursors 2018-08-10 06:39:14 -07:00
Hercules Mango Churchill 1320c09edd Update changelog 2018-08-09 18:21:02 +00:00
Jacob Marble f1fc1b0264
Merge pull request #10175 from influxdata/jgm-copy-byte-slices
tsdb: Copy return value of IndexSet.MeasurementNamesByExpr
2018-08-09 11:20:45 -07:00
Stuart Carnie 990824ceca fix(tsdb): Fix panic, don't add nil iterator to slice
fixes #10171
2018-08-09 10:12:49 -07:00
David Norton 01d5805952 fix line protocol parsing panic 2018-08-09 10:56:34 -04:00
Jacob Marble 7bd9b2a627 tsdb: Copy return value of IndexSet.MeasurementNamesByExpr 2018-08-08 23:48:06 -07:00
Stuart Carnie f70fb7a631 test(stress): Fix flaky test 2018-08-08 13:31:23 -07:00
Jonathan A. Sternberg beae42a090
Merge pull request #10151 from influxdata/js-480-config-flux-section
Modify the `ifql` section to `flux`
2018-08-08 11:26:33 -05:00
Jonathan A. Sternberg ebd77d1b3d
Merge pull request #10170 from influxdata/js-create-series-cursor-panic
Prevent a panic from occuring when CreateSeriesCursor fails
2018-08-08 08:19:40 -05:00
Jacob Marble 3dab795f69
Merge pull request #10166 from influxdata/jgm-throughput-cleanup
tsdb: Cleanup compaction throughput code
2018-08-07 22:29:32 -07:00
Jonathan A. Sternberg fe996612eb Prevent a panic from occuring when CreateSeriesCursor fails
The internals of `newSeriesCursor` returned a struct pointer that
implicitly got turned into the interface. Unfortunately, Go treats this
type of interface conversion as a nil pointer to the struct rather than
as just nil so if you attempted to compare the returned cursor to nil,
they would not be equal and it would think it was non-nil and attempt to
use the cursor.
2018-08-07 22:55:02 -05:00