Commit Graph

222 Commits (e5b2f8c11fbef1a99b449edbf65ba1531b950c31)

Author SHA1 Message Date
Ben Johnson 9237ee6a40
fix(tsi1): Remove TSI cardinality stats cache 2019-09-04 14:48:22 -06:00
George 8109d161bb
perf(storage): expose ability to peek on stream readers (#14901) 2019-09-04 13:57:36 +00:00
Nathaniel Cook dfc28335ea refactor(query/dependencies): update to new Flux dependencies defaults 2019-08-26 16:46:17 -06:00
Adam 945b68b8fd fix(query): finish refactoring the repl and inject the secret service as a dependency 2019-08-26 16:46:17 -06:00
Nathaniel Cook 6303e2dcc5 test(query): skip holt_winters_panic test
added executor dependencies where needed
2019-08-26 16:46:17 -06:00
Adam Perlin 76dbc44e3c
feat(storage): Add influxd inspect dumpwal tool (#14237)
* feat(storage/wal/dump): initial influxd inspect dumptsmwal implementation

* feat(storage/wal/dump): add org bucket formatting to dumpwal tool; improve test cases

* refactor(storage/wal/dump): add long description for dumpstmwal tool

* refactor(storage/wal/dump): rename dumptsmwal flag

* chore(storage/wal/dump): gofmt

* refactor(storage/wal/dump): update error printing in dumptsmwal tool

* refactor(storage/wal/dump): address review comments

* refactor(storage/wal/dump): rename dumpwal command source file

* refactor(storage/wal/dump): clarify print flag comment

* refactor(inspect): remote unnecessary for-loop in influxd inspect command
2019-08-23 13:05:06 -07:00
Jacob Marble 851279b71f
chore(storage): bring back storage_retention_checks_total (#14735) 2019-08-22 10:47:27 -07:00
Edd Robinson d160585a34 refactor(storage): add deeper tracing around deletes 2019-08-22 11:08:33 +01:00
Jacob Marble 26d29f7aa5
chore(storage): remove metric storage_retention_checks_total (#14719) 2019-08-20 14:39:08 -07:00
Stuart Carnie f60c2ec3ba
fix(reads): Remove issue reference from test per feedbakc 2019-08-16 13:00:06 -07:00
Stuart Carnie 3ca751cfd6
fix(reads): ResponseWriter truncates values for last series
The ResponseWriter would truncate the last series if the byte size of
the points frames exceeded the writeSize constant, causing a Flush to
occur and the cumulative ResponseWriter.sz to reset to zero. Because
ResponseWriter.sz was not incremented for each frame, it remained at
zero, which resulted in the final Flush short circuiting.

This commit implements the Size method for the cursors.Array types
to be used to estimate the size of frame. This is in place of calling
the Protocol Buffer `Size` function, which can be very expensive.
2019-08-16 10:36:40 -07:00
Stuart Carnie 0b20c227b4
feat(reads): A series of helpers to produce a SeriesCursor
This allows the data/gen package to be used to produce a SeriesCursor
for generated data that can be used in testing by the reads package.
2019-08-16 10:36:30 -07:00
Jonathan A. Sternberg 3d747b4fb1
fix(storage/reads): remove duplicate tables from the stream (#14601)
If the reader produces more than one table with the same group key, we
discard the later ones because the stream should never give us more than
one table with the same group key.

This is an error and it indicates the server sent us a bad set of data.
This change makes it so that the client is tolerant of that data and
will discard it if it exists.
2019-08-15 10:20:35 -05:00
Edd Robinson 5aead27e8b refactor(storage): remove commented code 2019-08-12 13:49:26 +01:00
j. Emrys Landivar (docmerlin) 7bd481d829 respond to pr comments 2019-08-05 13:16:51 -05:00
j. Emrys Landivar (docmerlin) 24c1f21e4e WIP 2019-08-05 13:16:51 -05:00
Christopher M. Wolff 42bb664aaf
feat(query): add storage request duration metric (#14534)
influxdata/idpe#4126
2019-08-02 08:53:14 -07:00
tmgordeeva 48ee7ada04
fix(storage): move retention snapshot out of per bucket calls (#14420)
* fix(storage): move retention snapshot out of per bucket calls

Also adds tracking for snapshots from retention and full compactions.
2019-07-23 11:40:05 -07:00
tmgordeeva 871f5466fe
fix(storage): run snapshot before retention deletes (#14400)
Deleting from the cache takes a lock which blocks writes. Snapshot to clear the
cache before deleting to reduce the lock contention.
2019-07-22 16:22:42 -07:00
Edd Robinson abbe795fa5 docs(storage): update PB doc to reflect new domain 2019-07-05 17:10:56 +01:00
Jonathan A. Sternberg 8cf3453d5c
fix(storage/reads): storage table implementation passes table tests (#14234) 2019-07-03 09:26:08 -05:00
Adam Perlin 24baec9e6d Gofmt verify-wal files 2019-06-27 16:28:28 -07:00
Adam Perlin fba4326c72 feat(storage): remove unnecessary lines from verify-wal test 2019-06-27 16:28:28 -07:00
Adam Perlin f4faa9b2f5 feat(storage): Small verify-wal output and test tweaks 2019-06-27 16:28:28 -07:00
Adam Perlin c868ece4f6 feat(storage): Initial 2.x verify-wal tool functionality 2019-06-27 16:28:28 -07:00
Tanya Gordeeva 6428cdbce6 fix(storage): initialize tsm file metrics, update after compaction
These metrics weren't being properly intialized on opening the file store, and
weren't being properly updated on compaction.
2019-06-20 14:37:53 -07:00
Ben Johnson 14980d55b8
fix(storage): Add WithCurrentGenerationFunc() for generation injection.
Adds the ability to set the current generation to use when compacting
the cache only. Previously, we used the current generation for all
files but this causes issues and we should only use the current
generation for level 1 compaction.
2019-06-20 08:54:38 -06:00
Jonathan A. Sternberg eeb32beb49
fix(storage/reads): ensure that the column reader gets its length set (#14065)
When a buffered column reader was used, the length was not reset to
whatever the requested length was for the buffer so it was possible for
the length to be longer than the actual columns.
2019-06-05 15:09:37 -05:00
Jonathan A. Sternberg 2b1c1ec143
fix(storage/reads): fix the storage tables to work correctly with multiple transformations (#14016)
The storage table reader will now work correctly when there are multiple
outputs. The table interface now implements the new table and column
reader interfaces and works properly with `execute.CopyTable`. The
source uses `execute.CopyTable` to buffer the table in memory when there
are multiple output transformations.
2019-05-30 12:31:54 -05:00
Mark Rushakoff 4b3d57c06d fix(storage): add missing RUnlock in Engine.Close
I don't see anywhere obvious that an engine would be closed twice, but
if it was, the RLock would have been held permanently, such that a Lock
could not be taken later.

Running go test ./storage/... did not trigger a double-close.
2019-05-29 08:40:40 -07:00
Jonathan A. Sternberg 21c80f3e93
refactor(query/control): move the controller from flux to influxdb (#13991)
The controller implementation is primarily used by influxdb so it
shouldn't be part of the flux repository. This copies the code from flux
to influxdb so it can be removed from the next flux release.
2019-05-29 09:04:34 -05:00
Jonathan A. Sternberg ebdbc394fc
chore(flux): update to Flux v0.31.0 (#14002)
* refactor(storage/reads): update the table implementation for the interface change (#13994)

* chore(flux): update to Flux v0.31.0
2019-05-28 17:24:26 -05:00
Jonathan A. Sternberg c98a40db14
fix(storage/reads): stop copying the values to an unnecessary buffer in the storage reader (#13933)
The copy was unnecessary since it was just going to be copied
immediately afterwards into an Arrow buffer. In the future, we will want
to have storage directly send the arrow buffer, but right now we are
putting it in an array and copying it anyway.

Even when we send an arrow buffer, the underlying sequence of bytes is
probably going to be different and we will rely on the allocator to
reuse bytes so let's remove the extra copy.
2019-05-15 20:40:29 -05:00
Christopher Wolff 90a5d88fc5 fix(query): skip failing end to end tests 2019-05-14 12:52:37 -07:00
jlapacik faab75968b refactor(storage): remove Read method from Store interface 2019-05-03 11:02:20 -07:00
Jeff Wendling ef0768db31
tsm1: predicate deletes (#13371)
tsm1: predicate deletes
2019-05-03 14:27:25 +00:00
Lorenzo Affetti 26d327ef9d
Merge pull request #13752 from influxdata/fix/read-filter
fix(readservice): normalize special tag keys after reducing request p…
2019-05-02 20:13:32 +02:00
Stuart Carnie bf774b66ce
fix(storage): Ensure Tag(Keys|Values) APIs never return (nil, nil)
Formalized this post condition in the documentation and added additional
unit tests.

Added a nil guard and unit test to WriteStringIterator.
2019-05-02 09:45:38 -07:00
Lorenzo Affetti 0993a9f15b fix(readservice): normalize special tag keys after reducing request predicate 2019-05-02 16:55:08 +02:00
Stuart Carnie d858bd6f77
fix(storage): Sort keys were incorrectly sorted when concatenated
This manifested as incorrect sort ordering when serialized via RPC,
resulting in an `invalid partition key order` error.

This fix introduces a delimiter to ensure sort keys cannot collide.
2019-05-01 13:37:28 -07:00
Jeff Wendling 16e9eb4cb9 tsdb: respond to feedback and improve test coverage
predicate.go:
	UnmarshalPredicate       100.0%
	NewProtobufPredicate     100.0%
	Matches                  100.0%
	Marshal                  100.0%
	walkPredicateNodes       100.0%
	buildPredicateNode       100.0%
	newPredicateState        100.0%
	Reset                    100.0%
	Set                      100.0%
	newPredicateCache        100.0%
	Cached                   100.0%
	Store                    100.0%
	Update                   100.0%
	Update                   92.9%
	Update                   94.1%
	predicateEval            90.9%
	predicatePopTag          100.0%
	predicatePopTagEscape    100.0%
2019-05-01 13:40:40 -06:00
Jeff Wendling 4b4a814d7d storage: fix predicate matching on field tags 2019-05-01 13:40:40 -06:00
Jeff Wendling e84d4625a5 storage: add predicate deletes to the engine interface 2019-05-01 13:40:40 -06:00
Jeff Wendling e10939b8af storage: add predicate tracking to the WAL 2019-05-01 13:40:40 -06:00
Jeff Wendling 7403fd8aa9 tsm1: rename engine method to DeletePrefixRange
The storage/engine knows about buckets, but the tsm1/engine doesn't, so
name the tsm1/engine method Prefix and keep the storage/engine named
Bucket.
2019-05-01 13:40:40 -06:00
jlapacik 5d90683b07 refactor(storage): remove no points tables and streamReader interface
These tables were previously used to perform meta queries.
Meta queries are now answered using a specific API, and as
a result, these tables can go away.
2019-05-01 10:35:10 -07:00
jlapacik 95aa194498 feat(storage): ReadGroup RPC definitions and storage reader 2019-05-01 10:35:10 -07:00
Stuart Carnie f56b4ef020
Merge pull request #13723 from influxdata/sgc/fix/merge
Ensure GroupCursor Keys is union of keys from all GroupCursors of current partition key
2019-05-01 09:07:53 -07:00
Jacob Marble 8c269e0153
chore(log): Put trace_id back in logs (#13712)
* chore(log): Put trace_id back in logs

* fix tests
2019-04-30 18:51:22 -07:00
Stuart Carnie 96c2282aab
fix(query): Keys must be union of all keys from all GroupCursors 2019-04-30 15:49:36 -07:00