Commit Graph

179 Commits (1a79bf7e99fed4ebe20338c650830d7b9ad279cf)

Author SHA1 Message Date
Paul Dix e41fd2a821 refactor: remove unused mutable_minimum_age_seconds lifecycle setting
Closes #1878
2021-07-08 18:34:01 -04:00
Andrew Lamb 72928aab3d
refactor: Move ChunkLifecycleAction to the data_types crate (#1939) 2021-07-08 20:18:33 +00:00
Carol (Nichols || Goulding) e5de73133c feat: Change write buffer connection rule to take either Writing or Reading connection info
A database on one IOx server can, exclusively:

- Not interact with Kafka at all
- Send writes to Kafka
- Read writes from Kafka

Notably, a database on a particular server will never write *and* read from Kafka at the same time.
2021-07-08 09:28:34 -04:00
Carol (Nichols || Goulding) 83e50cfba4 refactor: Rename field to not contain the type 2021-07-08 09:28:34 -04:00
Edd Robinson 86372c8818 refactor: remove unused method 2021-07-08 12:48:41 +01:00
Andrew Lamb 33bc85ad18
feat: Infrastructure for persistence (#1925)
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-07-08 11:14:38 +00:00
Marko Mikulicic 7059f16b9e
refactor: Turn mutable_linger_seconds into a non-optional (#1917) 2021-07-08 11:25:57 +02:00
Andrew Lamb 090b0aba11
refactor: remove unused `mutable_size_threshold` lifecycle setting (#1909)
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-07-07 17:03:15 +00:00
Marco Neumann 3d644b63a1 feat: add `Replay` state to DB init 2021-07-06 14:24:39 +02:00
Marco Neumann 54fbb60740 feat: expose DB state in gRPC interface 2021-07-02 11:24:36 +02:00
Paul Dix 91f5478012 feat: remove MUB size threshold
Removes the MUB chunk close based on size. Also add a check in lifecycle policy to move if the MUB chunk crosses a default row count threshold.
2021-07-01 14:58:29 -04:00
Raphael Taylor-Davies f1a100c6ae
refactor: remove now unused chunk sort order (#1854)
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-07-01 16:39:45 +00:00
Jacob Marble 0779b0d9bd
feat: add gRPC listener for new write protocol (#1842)
* feat: add gRPC listener for new write protocol

* chore: clippy happy

* chore: lint

* chore: cargo fmt --all

* chore: cargo clippy

* chore: protobuf-lint

* chore: more formatting

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-07-01 16:15:12 +00:00
Raphael Taylor-Davies cc038010cd
feat: add persist_age_threshold to LifecycleRules (#1853)
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-06-30 21:27:06 +00:00
Paul Dix 435b4b6a94 feat: add persistence windows to partition and update on write
This brings the persistence windows into the catalog partition. It adds a helper method on TableBatch to get the min and max times for a given write. Finally, it adds this logic to the db to update persistence windows on every write while the partition write lock is being held.
2021-06-25 15:34:11 -04:00
Raphael Taylor-Davies 297fc12db8
feat: compact chunks (#1776)
* feat: compact chunks

* chore: review feedback

* chore: clippy lints

* chore: document sort key algorithm

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-06-24 16:49:10 +00:00
Marco Neumann d17b5710a8 feat: add server functionality to wipe preserved catalogs 2021-06-21 09:31:23 +02:00
Andrew Lamb 6559a9e997
refactor: use Schema to compute InfluxDB primary keys (#1757)
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-06-18 21:15:31 +00:00
Raphael Taylor-Davies f6dbc8d6f2
refactor: add ChunkAddr to describe location of chunk in catalog (#1745)
* refactor: add ChunkPath to describe location of chunk in catalog

* refactor: rename ChunkPath to ChunkAddr

* chore: further renames

* chore: even more renames

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-06-17 12:04:37 +00:00
Andrew Lamb 0d8d32fd8f
chore: Update deps to get latest arrow (#1708)
* chore: Update deps to get latest arrow

* fix: Update to rust 1.52

* fix: clippy
2021-06-14 11:08:09 +00:00
Marco Neumann f4693e36c0 refactor: `catalog_checkpoint_interval` => `catalog_transactions_until_checkpoint` 2021-06-14 10:34:32 +02:00
Marco Neumann eae73591f3 feat: add `catalog_checkpoint_interval` lifecycle config 2021-06-14 10:04:50 +02:00
kodiakhq[bot] 16b268402e
Merge branch 'main' into ntran/dedup_merge_exec 2021-06-10 17:13:49 +00:00
Nga Tran 46d4ab1f2a refactor: address review comments 2021-06-10 13:13:02 -04:00
Raphael Taylor-Davies 11b25b3aaf
refactor: swap order of partition and table in in-memory catalog (#1678)
* refactor: swap order of partition and table in in-memory catalog

* chore: review feedback

* chore: validate panic message

* chore: review feedback

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-06-10 16:40:30 +00:00
Nga Tran 4cf05df35b feat: hook SortPreservingMergeExec into deduplication framework 2021-06-09 23:29:44 -04:00
Andrew Lamb 62e8675737
refactor: move primary_key calculaton to TableSummary (#1659) 2021-06-08 17:06:37 +00:00
Andrew Lamb 34ba268cf1
feat: Group chunks by potential overlap (#1654)
* feat: Group chunks by potential overlap

* docs: clarify in what way the calculation is conservative

* fix: Add test for mixed nulls
2021-06-08 16:55:29 +00:00
Carol (Nichols || Goulding) 50a69a7f18 fix: Don't mention Kafka unless it's absolutely necessary 2021-06-07 13:01:04 -04:00
Carol (Nichols || Goulding) 2418e91001 feat: Add a DatabaseRule field for an optional Kafka write buffer connection string 2021-06-07 09:56:23 -04:00
Carol (Nichols || Goulding) f4a9a5ae56 fix: Remove write buffer 2021-06-04 14:40:17 -04:00
Andrew Lamb ff3215e6a9
feat: Implement Chunk Pruning (#1567) 2021-06-04 13:05:22 +00:00
Marco Neumann 2afa8fa89a docs: fix typo and mention default 2021-06-03 11:23:29 +02:00
Marco Neumann bbd73e59be feat: jitter background clean-up job + wait on first job 2021-06-03 11:23:29 +02:00
Raphael Taylor-Davies db432de137
feat: add distinct count to StatValues (#1568) 2021-05-28 17:41:34 +00:00
Raphael Taylor-Davies 792bff07d1
feat: only store ChunkSnapshot in Closed state (#1560)
* feat: only store ChunkSnapshot in Closed state

* chore: review feedback

* feat: record MUB size as closed size

* chore: document column ordering assumption

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-05-27 10:36:47 +00:00
Marko Mikulicic bae5e5aee3
feat: Add simpler RoutingConfig 2021-05-25 21:51:54 +02:00
Carol (Nichols || Goulding) 5c5064bdac
fix: Set default line timestamp and default partition time to same value (#1512)
* refactor: Rearrange to allow injection of the current time in tests

* test: Failing test showing a point can be in the wrong partition

* fix: Only get the default time once per ShardedEntry creation, in router
2021-05-24 14:55:11 +00:00
Andrew Lamb c1ea6be101
fix: Add context to panic error on tools (#1501)
* fix: Add context to panic error on tools

* fix: log new unwrap that has snuck in

Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-05-17 21:05:01 +00:00
Andrew Lamb 07db4932ee
refactor: rename data_types/src/chunk.rs -> data_types/src/chunk_metadata.rs (#1500) 2021-05-15 10:18:01 +00:00
Marco Neumann 795f5bfcb7 refactor: make `StatValues::{min,max}` optional + handle NaNs
This will allow us to:

- handle all-NULL columns correctly
- be in-line with Parquet (where min/max are optional)
- handle NaNs at least somewhat sane (they do not "poison" stats
  anymore)
2021-05-10 17:12:25 +02:00
Andrew Lamb b5ea71f45f
feat: Expose the storage usage for each column in system.chunk_columns (#1441)
* feat: Expose the storage usage for each column in system.chunk_columns

* fix: fixup logical conflicts

* refactor: move coalsce logic into the read buffer

* fix: Update system_tables to not use coalese

* fix: Improve comments

Co-authored-by: Carol (Nichols || Goulding) <193874+carols10cents@users.noreply.github.com>

Co-authored-by: Carol (Nichols || Goulding) <193874+carols10cents@users.noreply.github.com>
2021-05-07 12:36:49 +00:00
Raphael Taylor-Davies 9320f59de0
feat: add shard sink indirection (#1447)
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-05-07 11:04:51 +00:00
Raphael Taylor-Davies 44de42906f
refactor: use Arc<str> instead of Arc<String> (#1442) 2021-05-06 17:05:08 +00:00
Raphael Taylor-Davies 216903a949
refactor: move protobuf conversion logic to generated_types (#1437)
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-05-06 15:49:27 +00:00
Andrew Lamb 884baf7329
feat: add column_type and influxdb_column_type, remove row_count from system.columns (#1415)
* feat: add column_type and influxdb_column_type, remove row_count from system.columns

* fix: update tests

* fix: more test update

* fix: Apply suggestions from code review

Co-authored-by: Carol (Nichols || Goulding) <193874+carols10cents@users.noreply.github.com>

* fix: fmt

* fix: copy/paste type conversion to avoid cross dependency between data_types and internal_types

Co-authored-by: Carol (Nichols || Goulding) <193874+carols10cents@users.noreply.github.com>
2021-05-06 12:59:30 +00:00
Dom 14127ca13b docs: fix greater than / less than comment
Segments will always be less-than-or-equal-to the configured maximum
size, not greater-than-or-equal-to.
2021-05-05 15:24:09 +01:00
Paul Dix 979f5f9347 refactor: write buffer to use sequenced entry and new segment
This refactors the write buffer to use the sequenced entry structure and the new segment definition. It removes the old replicated write and write_buffer.fbs.

Finally, it updates the SequencedEntry wrapper type around the Flatbuffer structure to be a trait so that SequencedEntry can be initialized from a borrowed Flatbuffer or an owned Vec<u8>.

How writes go into segments in the buffer and any kind of validation will likely have to be updated based on what kinds of guarantees we want to make in the buffer. However, that should probably come after we've rethought the design a bit around the new layout of chunks in the Parquet persistence.
2021-04-30 17:00:23 -04:00
Raphael Taylor-Davies a967ebfabd
refactor: rename closing to closed (#1396)
* refactor: rename closing to closed

* refactor: further renames
2021-04-30 20:59:45 +00:00
Andrew Lamb 0788892413
feat: add row_count to system.chunks and Chunk managment API (#1373)
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2021-04-29 13:53:25 +00:00