1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
//! Opsqueue: A lightweight batch processing queue for heavy loads
//!
//! Simple 'getting started' instructions can be found [in the repository README](https://github.com/channable/opsqueue/).
//!
//! The Rust codebase defines both the 'server', which makes up the bulk of the Opsqueue binary itself,
//! and the 'client', which is the common part of functionality that clients written in different other programming languages
//! can all use.
//!
//! Many datatypes are shared between this server and client, and therefore their code lives together in the same crate.
//! Instead, we use feature-flags (`client-logic` and `server-logic`) to decide what concrete parts to include when building.
//! The set of dependencies is based on these same feature-flags.
//! Most interestingly, in the test suite we enable both feature-flags so we're able to do a bunch of round-trip testing
//! immediately in Rust code.
//!
//! # Module setup
//! - The basic logic is divided in the `producer` and `consumer` modules. These both have their own `db` submodule.
//! - Common functionality and datatypes exists in the `common` module
//! - Common database helpers live in the `db` module.
//! - Reading/writing to object stores like GCS or S3 is abstracted in the `object_store` module.
//! - Finally, extra modules to have a single source of truth for configuration of the queue, and to nicely do tracing and expose metrics exist.
/// The Opsqueue library's semantic version
/// as written in the Rust packages's `Cargo.toml`
pub const VERSION_CARGO_SEMVER: &str = env!;