* refactor: ensure sequencers are unique
Adds a unique constraint to ensure only one sequencer record exists for
each Kafka (topic, partition).
* test: use DSN from env for integration tests
Removes the hard-coded DSN, instead sourcing it from the DATABASE_URL
environment variable.
* docs: integration testing for iox_catalog
Documents the required steps in order to run the Postgres integration
tests for the iox_catalog crate.
* feat(iox_catalog): create & list sequencers
Adds support for interacting with the "sequencer" table.
* chore: update lockfile
Running cargo in iox_catalog generates a lockfile diff.
Instead of converting the set of MutableBatches into a DmlOperation to
shard into more DmlOperation instances, the sharder can operate directly
on the MutableBatches.
Defines the DmlHandler trait responsible for processing a request in
some abstract way, decoupling the HTTP/gRPC request handlers from the
underlying routing logic.
* refactor: Extract JobRegistry from the server crate
Both the server crate and a db crate that I'm about to extract depend on
JobRegistry, so to avoid making circular dependencies, extract the
JobRegistry to its own crate.
* refactor: Move db out of server into its own crate
Fixes#2821.
This adds the ability to specify a regex to match against database names when specifying what agents should write to which buckets in the data generator.
A default has also been added for ratio so that it doesn't need to be specified if only a single database writer is defined.
Otherwise the whole thing blows up when starting a server that has many
DBs registerd, because we potentially create 1 connection per DB (e.g.
to read out the preserved catalog).
Fixes#3336.
I think this didn't fail before because influxdb_iox used to use
influxdb2_client, which turned on the json feature. Then the workspace
hack crate also turned on the json feature, so when influxdb_iox stopped
using influxdb2_client, it *still* worked. But excluding the object
store crates from hakari analysis that also turned on the json feature
meant nothing turned it on anymore, so now influxdb_iox needs to turn it
on itself.
Aha! cargo-hakari turns on all features, but usually in development all
the specific object storage implementation crates are off.
Excluding them in the hakari config reduces the workspace crate a bit.
Connects to #3117.
This removes nom from the workspace-hack crate. I'm not sure what's
going on here as cexpr is setting default-features false but then
explicitly setting the features to be the same as nom's default
features, and cargo-hakari seems to be resolving that differently than
using nom's default features. I think this might be a bug in
cargo-hakari, going to investigate.
Connects to #3117.
This was made possible by upgrading nom, which was using the deprecated
feature name. This will save us from pain in the future when the
deprecated feature is removed.
Unfortunately, this adds nom to the workspace hack crate, but we'll see
if it needs to stay there :)
Connects to #3117.
The `futures-util` crate's `proc-macro-hack` and `proc-macro-nested`
features used to be part of `futures-util`'s default feature sets, so
the workspace-hack crate listed them.
`futures-util` 0.3.18 removed those features entirely.
Cargo won't update to versions of crates that don't have features that
have been specified, so the workspace-hack crate was blocking Cargo from
updating `futures-util` and a few other crates to 0.3.18.
Cargo's docs recommend against removing features in semver-compatible
releases, but nothing really prevents crate authors from doing this.
Connects to #3117.
Connects to #3117.
Criterion builds clap without default features, which causes clap to be
listed in the workspace hack crate with its default features. In
general, actually building criterion will be rare (and we should move
all benches to separate crates that can be excluded) so it should be
fine to rebuild clap when building benchmarks anyway.