[workspace] members = [ "misc/bazel/cargo-gazelle", "src/adapter", "src/adapter-types", "src/alloc", "src/alloc-default", "src/arrow-util", "src/audit-log", "src/auth", "src/authenticator", "src/avro", "src/aws-secrets-controller", "src/aws-util", "src/balancerd", "src/build-info", "src/build-tools", "src/catalog", "src/catalog-debug", "src/catalog-protos", "src/ccsr", "src/cloud-api", "src/cloud-provider", "src/cloud-resources", "src/cluster", "src/cluster-client", "src/clusterd", "src/compute", "src/compute-client", "src/compute-types", "src/controller", "src/controller-types", "src/durable-cache", "src/dyncfg", "src/dyncfg-launchdarkly", "src/dyncfg-file", "src/dyncfgs", "src/environmentd", "src/expr", "src/expr-derive", "src/expr-derive-impl", "src/expr-parser", "src/expr-test-util", "src/fivetran-destination", "src/frontegg-auth", "src/frontegg-client", "src/frontegg-mock", "src/http-util", "src/interchange", "src/kafka-util", "src/license-keys", "src/lowertest", "src/lowertest-derive", "src/lsp-server", "src/materialized", "src/materialized", "src/metabase", "src/metrics", "src/mysql-util", "src/mz", "src/mz-debug", "src/npm", "src/orchestrator", "src/orchestrator-kubernetes", "src/orchestrator-process", "src/orchestrator-tracing", "src/orchestratord", "src/ore", "src/ore-build", "src/ore-proc", "src/persist", "src/persist-cli", "src/persist-client", "src/persist-proc", "src/persist-types", "src/pgcopy", "src/pgrepr", "src/pgrepr-consts", "src/pgtest", "src/pgtz", "src/pgwire", "src/pgwire-common", "src/postgres-client", "src/postgres-util", "src/prof", "src/prof-http", "src/proto", "src/regexp", "src/repr", "src/repr-test-util", "src/rocksdb", "src/rocksdb-types", "src/s3-datagen", "src/secrets", "src/segment", "src/server-core", "src/service", "src/sql", "src/sql-lexer", "src/sql-parser", "src/sql-pretty", "src/sql-server-util", "src/sqllogictest", "src/ssh-util", "src/storage", "src/storage-client", "src/storage-controller", "src/storage-operators", "src/storage-types", "src/testdrive", "src/timely-util", "src/timestamp-oracle", "src/tls-util", "src/tracing", "src/transform", "src/txn-wal", "src/walkabout", "src/workspace-hack", "test/metabase/smoketest", "test/test-util", ] # We make all members of the workspace default members, *except* for a few # specifically chosen exceptions. This is enforced by the linter. See # misc/python/materialize/cli/lint-cargo.py for the list of exceptions. # # Unfortunately Cargo does not provide a more elegant way to express exclusions # from the workspace's default members. default-members = [ "misc/bazel/cargo-gazelle", "src/adapter", "src/adapter-types", "src/alloc", "src/arrow-util", "src/audit-log", "src/auth", "src/authenticator", "src/avro", "src/aws-secrets-controller", "src/aws-util", "src/balancerd", "src/build-info", "src/build-tools", "src/catalog", "src/catalog-debug", "src/catalog-protos", "src/ccsr", "src/cloud-api", "src/cloud-provider", "src/cloud-resources", "src/cluster", "src/cluster-client", "src/clusterd", "src/compute", "src/compute-client", "src/compute-types", "src/controller", "src/controller-types", "src/durable-cache", "src/dyncfg", "src/dyncfg-launchdarkly", "src/dyncfg-file", "src/dyncfgs", "src/environmentd", "src/expr", "src/expr-derive", "src/expr-derive-impl", "src/expr-parser", "src/expr-test-util", "src/frontegg-auth", "src/frontegg-client", "src/frontegg-mock", "src/http-util", "src/interchange", "src/kafka-util", "src/license-keys", "src/lowertest", "src/lowertest-derive", "src/lsp-server", "src/materialized", "src/metabase", "src/metrics", "src/mysql-util", "src/mz", "src/mz-debug", "src/npm", "src/orchestrator", "src/orchestrator-kubernetes", "src/orchestrator-process", "src/orchestrator-tracing", "src/orchestratord", "src/ore", "src/ore-build", "src/ore-proc", "src/persist", "src/persist-cli", "src/persist-client", "src/persist-proc", "src/persist-types", "src/pgcopy", "src/pgrepr", "src/pgrepr-consts", "src/pgtest", "src/pgtz", "src/pgwire", "src/pgwire-common", "src/postgres-client", "src/postgres-util", "src/prof", "src/prof-http", "src/proto", "src/regexp", "src/repr", "src/repr-test-util", "src/rocksdb", "src/rocksdb-types", "src/s3-datagen", "src/secrets", "src/segment", "src/server-core", "src/service", "src/sql", "src/sql-lexer", "src/sql-parser", "src/sql-pretty", "src/sql-server-util", "src/sqllogictest", "src/ssh-util", "src/storage", "src/storage-client", "src/storage-controller", "src/storage-operators", "src/storage-types", "src/testdrive", "src/timely-util", "src/timestamp-oracle", "src/tls-util", "src/tracing", "src/transform", "src/txn-wal", "src/walkabout", "src/workspace-hack", "test/metabase/smoketest", "test/test-util", ] exclude = [ # All WASM crates are split into their own workspace to avoid needles cache # invalidations for the core Mz crates. "misc/wasm/*", # Ignore any Rust dependencies that python packages might pull in. "misc/python/venv/*", ] # Use Cargo's new feature resolver, which can handle target-specific features. # Explicit opt-in is required even with the 2021 edition because we use a # virtual workspace. # See: https://blog.rust-lang.org/2021/03/25/Rust-1.51.0.html#cargos-new-feature-resolver resolver = "2" [workspace.package] edition = "2024" rust-version = "1.88.0" [profile.dev] split-debuginfo = "unpacked" [profile.dev.package] # Compile the backtrace crate and its dependencies with all optimizations, even # in dev builds, since otherwise backtraces can take 20s+ to symbolize. With # optimizations enabled, symbolizing a backtrace takes less than 1s. addr2line = { opt-level = 3 } adler2 = { opt-level = 3 } backtrace = { opt-level = 3 } gimli = { opt-level = 3 } miniz_oxide = { opt-level = 3 } object = { opt-level = 3 } rustc-demangle = { opt-level = 3 } timely = { opt-level = 3 } differential-dataflow = { opt-level = 3 } mz-compute = { opt-level = 3 } mz-transform = { opt-level = 3 } # Recommended by insta insta = { opt-level = 3 } similar = { opt-level = 3 } [profile.release] # Compile time seems similar to "lto = false", runtime ~10% faster lto = "thin" # Emit full debug info, allowing us to easily analyze core dumps from # staging (and, in an emergency, also prod). # # This does not negatively impact the sizes of the main binaries # (clusterd and environmentd), since we split the debuginfo from those # and ship it separately to an s3 bucket before building their # docker containers. debug = 2 [profile.optimized] inherits = "release" lto = "off" debug = 1 incremental = true [profile.ci] inherits = "optimized" debug = "line-tables-only" debug-assertions = true # IMPORTANT: when patching a dependency, you should only depend on "main", # "master", or an upstream release branch (e.g., "v7.x"). Do *not* depend on a # feature/patch branch (e.g., "fix-thing" or "pr-1234"). Feature/patch branches # tend to get rewritten or disappear (e.g., because a PR is force pushed or gets # merged), after which point it becomes impossible to build that historical # version of Materialize. [patch.crates-io] # Waiting on https://github.com/sfackler/rust-postgres/pull/752. postgres = { git = "https://github.com/MaterializeInc/rust-postgres" } tokio-postgres = { git = "https://github.com/MaterializeInc/rust-postgres" } postgres-protocol = { git = "https://github.com/MaterializeInc/rust-postgres" } postgres-replication = { git = "https://github.com/MaterializeInc/rust-postgres" } postgres-types = { git = "https://github.com/MaterializeInc/rust-postgres" } postgres-openssl = { git = "https://github.com/MaterializeInc/rust-postgres" } postgres_array = { git = "https://github.com/MaterializeInc/rust-postgres-array" } # Waiting on https://github.com/MaterializeInc/serde-value/pull/35. serde-value = { git = "https://github.com/MaterializeInc/serde-value.git" } # Waiting on https://github.com/MaterializeInc/tracing/pull/1 to be submitted # upstream. tracing-opentelemetry = { git = "https://github.com/MaterializeInc/tracing-opentelemetry.git" } # Waiting for resolution of https://github.com/launchdarkly/rust-server-sdk/issues/116 launchdarkly-server-sdk = { git = "https://github.com/MaterializeInc/rust-server-sdk", rev = "23666d095c39adc53a151969c1aa1e1ec484f3e6" } # Waiting on https://github.com/edenhill/librdkafka/pull/4051. rdkafka = { git = "https://github.com/MaterializeInc/rust-rdkafka.git" } rdkafka-sys = { git = "https://github.com/MaterializeInc/rust-rdkafka.git" } # Removes dependencies required for WASM support that create duplicated deps. reqwest-middleware = { git = "https://github.com/MaterializeInc/reqwest-middleware.git" } reqwest-retry = { git = "https://github.com/MaterializeInc/reqwest-middleware.git" } # Need to upstream a few PRs related to test builders. # # Note: All changes in our fork of tiberius should be pushed to the `mz_changes` branch. tiberius = { git = "https://github.com/MaterializeInc/tiberius", rev="64ca594cc22ed67d072c2d0110455da50539e1cd" } # BEGIN LINT CONFIG # DO NOT EDIT. Automatically generated by bin/gen-lints. [workspace.lints.rust] unknown_lints = "allow" non_local_definitions = "allow" unexpected_cfgs = { level = "warn", check-cfg = ['cfg(bazel, stamped, coverage, nightly_doc_features, release, tokio_unstable)'] } [workspace.lints.rustdoc] [workspace.lints.clippy] style = { level = "allow", priority = -1 } complexity = { level = "allow", priority = -1 } large_enum_variant = { level = "allow", priority = 0 } result_large_err = { level = "allow", priority = 0 } mutable_key_type = { level = "allow", priority = 0 } stable_sort_primitive = { level = "allow", priority = 0 } map_entry = { level = "allow", priority = 0 } box_default = { level = "allow", priority = 0 } drain_collect = { level = "allow", priority = 0 } bool_comparison = "warn" clone_on_ref_ptr = "warn" no_effect = "warn" unnecessary_unwrap = "warn" dbg_macro = "warn" todo = "warn" zero_prefixed_literal = "warn" borrowed_box = "warn" deref_addrof = "warn" double_must_use = "warn" double_parens = "warn" extra_unused_lifetimes = "warn" needless_borrow = "warn" needless_question_mark = "warn" needless_return = "warn" redundant_pattern = "warn" redundant_slicing = "warn" redundant_static_lifetimes = "warn" single_component_path_imports = "warn" unnecessary_cast = "warn" useless_asref = "warn" useless_conversion = "warn" builtin_type_shadow = "warn" duplicate_underscore_argument = "warn" double_negations = "warn" unnecessary_mut_passed = "warn" wildcard_in_or_patterns = "warn" crosspointer_transmute = "warn" excessive_precision = "warn" panicking_overflow_checks = "warn" as_conversions = "warn" match_overlapping_arm = "warn" zero_divided_by_zero = "warn" must_use_unit = "warn" suspicious_assignment_formatting = "warn" suspicious_else_formatting = "warn" suspicious_unary_op_formatting = "warn" mut_mutex_lock = "warn" print_literal = "warn" same_item_push = "warn" useless_format = "warn" write_literal = "warn" redundant_closure = "warn" redundant_closure_call = "warn" unnecessary_lazy_evaluations = "warn" partialeq_ne_impl = "warn" redundant_field_names = "warn" transmutes_expressible_as_ptr_casts = "warn" unused_async = "warn" disallowed_methods = "warn" disallowed_macros = "warn" disallowed_types = "warn" from_over_into = "warn" mod_module_files = "warn" needless_pass_by_ref_mut = "warn" borrow_interior_mutable_const = "warn" or_fun_call = "warn" # END LINT CONFIG