Merge pull request #2965 from influxdata/crepererum/workspace_cleanups

chore: flatten workspace
pull/24376/head
kodiakhq[bot] 2021-10-26 09:35:48 +00:00 committed by GitHub
commit f19d53c714
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
99 changed files with 169 additions and 167 deletions

View File

@ -1,41 +1,17 @@
[package]
name = "influxdb_iox"
version = "0.1.0"
authors = ["Paul Dix <paul@pauldix.net>"]
edition = "2021"
default-run = "influxdb_iox"
readme = "README.md"
exclude = [
"*.md",
"*.txt",
".circleci/",
".editorconfig",
".git*",
".github/",
".kodiak.toml",
"Dockerfile*",
"LICENSE*",
"buf.yaml",
"docker/",
"docs/",
"massif.out.*",
"perf/",
"scripts/",
"tools/",
]
[workspace] # In alphabetical order
[workspace]
# In alphabetical order
members = [
"arrow_util",
"data_types",
"client_util",
"data_types",
"datafusion",
"datafusion_util",
"entry",
"generated_types",
"grpc-router",
"grpc-router-test-gen",
"influxdb2_client",
"influxdb_iox",
"influxdb_iox_client",
"influxdb_line_protocol",
"influxdb_storage_client",
@ -62,6 +38,7 @@ members = [
"query",
"query_tests",
"read_buffer",
"schema",
"server",
"server_benchmarks",
"test_helpers",
@ -71,130 +48,32 @@ members = [
"trace_http",
"tracker",
"trogging",
"schema",
"grpc-router",
"grpc-router/grpc-router-test-gen",
"write_buffer",
]
default-members = ["influxdb_iox"]
exclude = [
"*.md",
"*.txt",
".circleci/",
".editorconfig",
".git*",
".github/",
".kodiak.toml",
"Dockerfile*",
"LICENSE*",
"buf.yaml",
"docker/",
"docs/",
"massif.out.*",
"perf/",
"scripts/",
"test_fixtures/",
"tools/",
]
[profile.release]
debug = true
[profile.bench]
debug = true
[dependencies]
# Workspace dependencies, in alphabetical order
datafusion = { path = "datafusion" }
data_types = { path = "data_types" }
entry = { path = "entry" }
generated_types = { path = "generated_types" }
influxdb_iox_client = { path = "influxdb_iox_client", features = ["flight", "format"] }
influxdb_line_protocol = { path = "influxdb_line_protocol" }
internal_types = { path = "internal_types" }
iox_object_store = { path = "iox_object_store" }
logfmt = { path = "logfmt" }
metric = { path = "metric" }
metric_exporters = { path = "metric_exporters" }
mutable_buffer = { path = "mutable_buffer" }
num_cpus = "1.13.0"
object_store = { path = "object_store" }
observability_deps = { path = "observability_deps" }
panic_logging = { path = "panic_logging" }
parquet_catalog = { path = "parquet_catalog" }
parquet_file = { path = "parquet_file" }
predicate = { path = "predicate" }
query = { path = "query" }
read_buffer = { path = "read_buffer" }
server = { path = "server" }
trace = { path = "trace" }
trace_exporters = { path = "trace_exporters" }
trace_http = { path = "trace_http" }
tracker = { path = "tracker" }
trogging = { path = "trogging", default-features = false, features = ["structopt"] }
time = { path = "time" }
# Crates.io dependencies, in alphabetical order
arrow = { version = "6.0", features = ["prettyprint"] }
arrow-flight = "6.0"
backtrace = "0.3"
byteorder = "1.3.4"
bytes = "1.0"
chrono = "0.4"
clap = "2.33.1"
csv = "1.1"
dirs = "4.0.0"
dotenv = "0.15.0"
flate2 = "1.0"
futures = "0.3"
hashbrown = "0.11"
http = "0.2.0"
humantime = "2.1.0"
hyper = "0.14"
libc = { version = "0.2" }
log = "0.4"
once_cell = { version = "1.4.0", features = ["parking_lot"] }
parking_lot = "0.11.2"
itertools = "0.10.1"
parquet = "6.0"
pin-project = "1.0"
# used by arrow/datafusion anyway
comfy-table = { version = "4.0", default-features = false }
pprof = { version = "^0.5", default-features = false, features = ["flamegraph", "protobuf"], optional = true }
prost = "0.8"
rustyline = { version = "9.0", default-features = false }
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0.67"
serde_urlencoded = "0.7.0"
snafu = "0.6.9"
structopt = "0.3.25"
thiserror = "1.0.30"
tikv-jemalloc-ctl = { version = "0.4.0" }
tokio = { version = "1.11", features = ["macros", "rt-multi-thread", "parking_lot", "signal"] }
tokio-stream = { version = "0.1.2", features = ["net"] }
tokio-util = { version = "0.6.3" }
tonic = "0.5.0"
tonic-health = "0.4.0"
tonic-reflection = "0.2.0"
tower = "0.4"
uuid = { version = "0.8", features = ["v4"] }
# jemalloc-sys with unprefixed_malloc_on_supported_platforms feature and heappy are mutually exclusive
tikv-jemalloc-sys = { version = "0.4.0", optional = true, features = ["unprefixed_malloc_on_supported_platforms"] }
heappy = { git = "https://github.com/mkmik/heappy", rev = "20aa466524ac9ce34a4bae29f27ec11869b50e21", features = ["enable_heap_profiler", "jemalloc_shim", "measure_free"], optional = true }
[dev-dependencies]
# Workspace dependencies, in alphabetical order
arrow_util = { path = "arrow_util" }
entry = { path = "entry" }
influxdb2_client = { path = "influxdb2_client" }
influxdb_storage_client = { path = "influxdb_storage_client" }
influxdb_iox_client = { path = "influxdb_iox_client", features = ["flight"] }
test_helpers = { path = "test_helpers" }
parking_lot = "0.11.2"
write_buffer = { path = "write_buffer" }
# Crates.io dependencies, in alphabetical order
assert_cmd = "2.0.2"
flate2 = "1.0"
hex = "0.4.2"
predicates = "2.0.3"
rand = "0.8.3"
reqwest = "0.11"
tempfile = "3.1.0"
[features]
default = ["jemalloc_replacing_malloc"]
azure = ["object_store/azure"] # Optional Azure Object store support
gcp = ["object_store/gcp"] # Optional GCP object store support
aws = ["object_store/aws"] # Optional AWS / S3 object store support
# pprof is an optional feature for pprof support
# heappy is an optional feature; Not on by default as it
# runtime overhead on all allocations (calls to malloc).
# Cargo cannot currently implement mutually exclusive features so let's force every build
# to pick either heappy or jemalloc_replacing_malloc feature at least until we figure out something better.
jemalloc_replacing_malloc = ["tikv-jemalloc-sys"]

View File

@ -25,4 +25,4 @@ prost-build = "0.8"
tonic-build = "0.5"
[dev-dependencies]
grpc-router-test-gen = { path = "./grpc-router-test-gen" }
grpc-router-test-gen = { path = "../grpc-router-test-gen" }

122
influxdb_iox/Cargo.toml Normal file
View File

@ -0,0 +1,122 @@
[package]
name = "influxdb_iox"
version = "0.1.0"
authors = ["Paul Dix <paul@pauldix.net>"]
edition = "2021"
default-run = "influxdb_iox"
[dependencies]
# Workspace dependencies, in alphabetical order
datafusion = { path = "../datafusion" }
data_types = { path = "../data_types" }
entry = { path = "../entry" }
generated_types = { path = "../generated_types" }
influxdb_iox_client = { path = "../influxdb_iox_client", features = ["flight", "format"] }
influxdb_line_protocol = { path = "../influxdb_line_protocol" }
internal_types = { path = "../internal_types" }
iox_object_store = { path = "../iox_object_store" }
logfmt = { path = "../logfmt" }
metric = { path = "../metric" }
metric_exporters = { path = "../metric_exporters" }
mutable_buffer = { path = "../mutable_buffer" }
num_cpus = "1.13.0"
object_store = { path = "../object_store" }
observability_deps = { path = "../observability_deps" }
panic_logging = { path = "../panic_logging" }
parquet_catalog = { path = "../parquet_catalog" }
parquet_file = { path = "../parquet_file" }
predicate = { path = "../predicate" }
query = { path = "../query" }
read_buffer = { path = "../read_buffer" }
server = { path = "../server" }
trace = { path = "../trace" }
trace_exporters = { path = "../trace_exporters" }
trace_http = { path = "../trace_http" }
tracker = { path = "../tracker" }
trogging = { path = "../trogging", default-features = false, features = ["structopt"] }
time = { path = "../time" }
# Crates.io dependencies, in alphabetical order
arrow = { version = "6.0", features = ["prettyprint"] }
arrow-flight = "6.0"
backtrace = "0.3"
byteorder = "1.3.4"
bytes = "1.0"
chrono = "0.4"
clap = "2.33.1"
csv = "1.1"
dirs = "4.0.0"
dotenv = "0.15.0"
flate2 = "1.0"
futures = "0.3"
hashbrown = "0.11"
http = "0.2.0"
humantime = "2.1.0"
hyper = "0.14"
libc = { version = "0.2" }
log = "0.4"
once_cell = { version = "1.4.0", features = ["parking_lot"] }
parking_lot = "0.11.2"
itertools = "0.10.1"
parquet = "6.0"
pin-project = "1.0"
# used by arrow/datafusion anyway
comfy-table = { version = "4.0", default-features = false }
pprof = { version = "^0.5", default-features = false, features = ["flamegraph", "protobuf"], optional = true }
prost = "0.8"
rustyline = { version = "9.0", default-features = false }
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0.67"
serde_urlencoded = "0.7.0"
snafu = "0.6.9"
structopt = "0.3.25"
thiserror = "1.0.30"
tikv-jemalloc-ctl = { version = "0.4.0" }
tokio = { version = "1.11", features = ["macros", "rt-multi-thread", "parking_lot", "signal"] }
tokio-stream = { version = "0.1.2", features = ["net"] }
tokio-util = { version = "0.6.3" }
tonic = "0.5.0"
tonic-health = "0.4.0"
tonic-reflection = "0.2.0"
tower = "0.4"
uuid = { version = "0.8", features = ["v4"] }
# jemalloc-sys with unprefixed_malloc_on_supported_platforms feature and heappy are mutually exclusive
tikv-jemalloc-sys = { version = "0.4.0", optional = true, features = ["unprefixed_malloc_on_supported_platforms"] }
heappy = { git = "https://github.com/mkmik/heappy", rev = "20aa466524ac9ce34a4bae29f27ec11869b50e21", features = ["enable_heap_profiler", "jemalloc_shim", "measure_free"], optional = true }
[dev-dependencies]
# Workspace dependencies, in alphabetical order
arrow_util = { path = "../arrow_util" }
entry = { path = "../entry" }
influxdb2_client = { path = "../influxdb2_client" }
influxdb_storage_client = { path = "../influxdb_storage_client" }
influxdb_iox_client = { path = "../influxdb_iox_client", features = ["flight"] }
test_helpers = { path = "../test_helpers" }
parking_lot = "0.11.2"
write_buffer = { path = "../write_buffer" }
# Crates.io dependencies, in alphabetical order
assert_cmd = "2.0.2"
flate2 = "1.0"
hex = "0.4.2"
predicates = "2.0.3"
rand = "0.8.3"
reqwest = "0.11"
tempfile = "3.1.0"
[features]
default = ["jemalloc_replacing_malloc"]
azure = ["object_store/azure"] # Optional Azure Object store support
gcp = ["object_store/gcp"] # Optional GCP object store support
aws = ["object_store/aws"] # Optional AWS / S3 object store support
# pprof is an optional feature for pprof support
# heappy is an optional feature; Not on by default as it
# runtime overhead on all allocations (calls to malloc).
# Cargo cannot currently implement mutually exclusive features so let's force every build
# to pick either heappy or jemalloc_replacing_malloc feature at least until we figure out something better.
jemalloc_replacing_malloc = ["tikv-jemalloc-sys"]

View File

@ -1725,7 +1725,8 @@ mod tests {
// Note we don't include the actual line / column in the
// expected panic message to avoid needing to update the test
// whenever the source code file changed.
let expected_error = "panicked at 'This is a test panic', src/influxdb_ioxd/rpc/testing.rs";
let expected_error =
"panicked at 'This is a test panic', influxdb_iox/src/influxdb_ioxd/rpc/testing.rs";
assert_contains!(captured_logs, expected_error);
// Ensure that panics don't exhaust the tokio executor by

View File

@ -655,7 +655,7 @@ mod tests {
#[test]
fn map_tsm_index() {
let file = File::open("../tests/fixtures/000000000000005-000000002.tsm.gz");
let file = File::open("../test_fixtures/000000000000005-000000002.tsm.gz");
let mut decoder = GzDecoder::new(file.unwrap());
let mut buf = Vec::new();
decoder.read_to_end(&mut buf).unwrap();
@ -671,7 +671,7 @@ mod tests {
#[test]
fn map_field_columns_file() {
let file = File::open("../tests/fixtures/000000000000005-000000002.tsm.gz");
let file = File::open("../test_fixtures/000000000000005-000000002.tsm.gz");
let mut decoder = GzDecoder::new(file.unwrap());
let mut buf = Vec::new();
decoder.read_to_end(&mut buf).unwrap();
@ -714,7 +714,7 @@ mod tests {
#[test]
fn measurement_table_columns() {
let file = File::open("../tests/fixtures/000000000000005-000000002.tsm.gz");
let file = File::open("../test_fixtures/000000000000005-000000002.tsm.gz");
let mut decoder = GzDecoder::new(file.unwrap());
let mut buf = Vec::new();
decoder.read_to_end(&mut buf).unwrap();

View File

@ -19,7 +19,7 @@ use std::u64;
/// # use std::io::BufReader;
/// # use std::io::Cursor;
/// # use std::io::Read;
/// # let file = File::open("../tests/fixtures/000000000000005-000000002.tsm.gz");
/// # let file = File::open("../test_fixtures/000000000000005-000000002.tsm.gz");
/// # let mut decoder = GzDecoder::new(file.unwrap());
/// # let mut buf = Vec::new();
/// # decoder.read_to_end(&mut buf).unwrap();
@ -687,7 +687,7 @@ mod tests {
#[test]
fn read_tsm_index() {
let file = File::open("../tests/fixtures/000000000000005-000000002.tsm.gz");
let file = File::open("../test_fixtures/000000000000005-000000002.tsm.gz");
let mut decoder = GzDecoder::new(file.unwrap());
let mut buf = Vec::new();
decoder.read_to_end(&mut buf).unwrap();
@ -700,7 +700,7 @@ mod tests {
#[test]
fn read_tsm_block() {
let file = File::open("../tests/fixtures/000000000000005-000000002.tsm.gz");
let file = File::open("../test_fixtures/000000000000005-000000002.tsm.gz");
let mut decoder = GzDecoder::new(file.unwrap());
let mut buf = Vec::new();
decoder.read_to_end(&mut buf).unwrap();
@ -754,7 +754,7 @@ mod tests {
#[test]
fn decode_tsm_blocks() {
let file = File::open("../tests/fixtures/000000000000005-000000002.tsm.gz");
let file = File::open("../test_fixtures/000000000000005-000000002.tsm.gz");
let mut decoder = GzDecoder::new(file.unwrap());
let mut buf = Vec::new();
decoder.read_to_end(&mut buf).unwrap();
@ -833,12 +833,12 @@ mod tests {
#[test]
fn check_tsm_cpu_usage() {
walk_index_and_check_for_errors("../tests/fixtures/cpu_usage.tsm.gz");
walk_index_and_check_for_errors("../test_fixtures/cpu_usage.tsm.gz");
}
#[test]
fn check_tsm_000000000000005_000000002() {
walk_index_and_check_for_errors("../tests/fixtures/000000000000005-000000002.tsm.gz");
walk_index_and_check_for_errors("../test_fixtures/000000000000005-000000002.tsm.gz");
}
#[test]

View File

@ -7,7 +7,7 @@ use flate2::read::GzDecoder;
use mutable_batch_lp::lines_to_batches;
fn generate_lp_bytes() -> Bytes {
let raw = include_bytes!("../../tests/fixtures/lineproto/read_filter.lp.gz");
let raw = include_bytes!("../../test_fixtures/lineproto/read_filter.lp.gz");
let mut gz = GzDecoder::new(&raw[..]);
let mut buffer = Vec::new();

View File

@ -1,7 +1,7 @@
use criterion::{criterion_group, criterion_main, Criterion, Throughput};
use std::time::Duration;
static LINES: &str = include_str!("../../tests/fixtures/lineproto/prometheus.lp");
static LINES: &str = include_str!("../../test_fixtures/lineproto/prometheus.lp");
fn line_parser(c: &mut Criterion) {
let mut group = c.benchmark_group("line_parser");

View File

@ -40,7 +40,7 @@ use server::db::Db;
// In total there are 10K rows. The timespan of the points in the line
// protocol is around 1m of wall-clock time.
async fn setup_scenarios() -> Vec<DbScenario> {
let raw = include_bytes!("../../tests/fixtures/lineproto/read_filter.lp.gz");
let raw = include_bytes!("../../test_fixtures/lineproto/read_filter.lp.gz");
let mut gz = GzDecoder::new(&raw[..]);
let mut lp = String::new();
gz.read_to_string(&mut lp).unwrap();

View File

@ -41,7 +41,7 @@ use server::db::Db;
// In total there are 10K rows. The timespan of the points in the line
// protocol is around 1m of wall-clock time.
async fn setup_scenarios() -> Vec<DbScenario> {
let raw = include_bytes!("../../tests/fixtures/lineproto/read_filter.lp.gz");
let raw = include_bytes!("../../test_fixtures/lineproto/read_filter.lp.gz");
let mut gz = GzDecoder::new(&raw[..]);
let mut lp = String::new();
gz.read_to_string(&mut lp).unwrap();

View File

@ -12,7 +12,7 @@ fn snapshot_chunk(chunk: &MBChunk) {
fn chunk(count: usize) -> MBChunk {
let mut chunk: Option<MBChunk> = None;
let raw = include_bytes!("../../tests/fixtures/lineproto/tag_values.lp.gz");
let raw = include_bytes!("../../test_fixtures/lineproto/tag_values.lp.gz");
let mut gz = GzDecoder::new(&raw[..]);
let mut lp = String::new();
gz.read_to_string(&mut lp).unwrap();

View File

@ -38,7 +38,7 @@ use server::db::Db;
// The timespan of the points in the line protocol is around 1m or wall-clock
// time.
async fn setup_scenarios() -> Vec<DbScenario> {
let raw = include_bytes!("../../tests/fixtures/lineproto/tag_values.lp.gz");
let raw = include_bytes!("../../test_fixtures/lineproto/tag_values.lp.gz");
let mut gz = GzDecoder::new(&raw[..]);
let mut lp = String::new();
gz.read_to_string(&mut lp).unwrap();

View File

@ -33,7 +33,7 @@ fn write_chunk(count: usize, entries: &[Entry]) {
}
fn load_entries() -> Vec<Entry> {
let raw = include_bytes!("../../tests/fixtures/lineproto/tag_values.lp.gz");
let raw = include_bytes!("../../test_fixtures/lineproto/tag_values.lp.gz");
let mut gz = GzDecoder::new(&raw[..]);
let mut lp = String::new();
gz.read_to_string(&mut lp).unwrap();