Commit Graph

10 Commits (96321ff8bd9a8c63ad7efb4278bbc442e654bb33)

Author SHA1 Message Date
Jacob Marble 26ca766459
refactor(tsdb): move series file to its own package (#17224)
* refactor(storage): move type ByTagKey to the only package that uses it

* refactor(tsdb): use types in tsdb/cursors

* refactor(tsdb): remove unused type SeriesIDElems

* refactor(tsdb): inline only use of tsdb.ReadAllSeriesIDIterator

* refactor(tsdb): move series file to its own package

* refactor(storage): remove platform->influxdb aliases
2020-03-12 11:32:52 -07:00
Jacob Marble 83818e9592
fix(storage): incremental improvments (#17011)
* fix(storage): simplify storage/seriesCursor

storage/seriesCursor releases series file and TSI references sooner.

Remove unhelpful request object, inherited from 1.x

* chore(storage): replace SeriesCursor interface with sole implementation
2020-02-28 11:12:43 -08:00
Stuart Carnie fb39ac39ce
fix(storage): Store.Read behavior changed to return unsorted series keys
Closes #13581
2019-04-26 10:38:59 -07:00
Jeff Wendling 0fae44e219 storage: fix problems with keeping resources alive
This commit adds the pkg/lifecycle.Resource to help manage opening,
closing, and leasing out references to some resource. A resource
cannot be closed until all acquired references have been released.
If the debug_ref tag is enabled, all resource acquisitions keep
track of the stack trace that created them and have a finalizer
associated with them to print on stderr if they are leaked. It also
registers a handler on SIGUSR2 to dump all of the currently live
resources.

Having resources tracked in a uniform way with a data type allows us
to do more sophisticated tracking with the debug_ref tag, as well.
For example, we could panic the process if a resource cannot be
closed within a certain time frame, or attempt to figure out the
DAG of resource ownership dynamically.

This commit also fixes many issues around resources, correctness
during error scenarios, reporting of errors, idempotency of
close, tracking of memory for some data structures, resource leaks
in tests, and out of order dependency closes in tests.
2019-02-28 10:22:01 -07:00
Stuart Carnie 662887c679 feedback: Simplify reader; use constants from influxdb package 2019-02-21 11:18:08 -08:00
Stuart Carnie 01b5fccfbe feat(storage): Enforce single org for series key reads 2019-02-21 11:18:08 -08:00
Mark Rushakoff d73d73c0d4 chore: rename imports from platform to influxdb
I did this with a dumb editor macro, so some comments changed too.

Also rename root package from platform to influxdb.

In interest of minimizing risk, anyone importing the root package has
now aliased it to "platform" so that no changes beyond imports were
necessary in those files.

Lastly, replace the old platform module to local path /dev/null so that
nobody can accidentally reintroduce a platform dependency while
migrating platform code to influxdb.
2019-01-09 20:51:47 -08:00
Chris Goller d8548d41e1 chore(fmt): update formating with make fmt 2018-10-30 07:40:28 -05:00
zhulongcheng 28fecc1f6f replace tsdb.IndexSet with tsi1.Index
This fix is to remove tsdb.IndexSet to resolve #886.
2018-10-27 02:08:31 +08:00
Edd Robinson cfb3df203a Working storage engine 2018-10-04 10:24:43 +01:00