misc: initial layout

This commit is contained in:
hdbg
2026-02-09 14:06:53 +01:00
commit 284f997cbe
78 changed files with 4917 additions and 0 deletions

1706
server/Cargo.lock generated Normal file

File diff suppressed because it is too large Load Diff

32
server/Cargo.toml Normal file
View File

@@ -0,0 +1,32 @@
[workspace]
members = [
"crates/arbiter-client",
"crates/arbiter-proto",
"crates/arbiter-server",
]
resolver = "3"
[workspace.dependencies]
prost = "0.14.3"
tonic = "0.14.3"
tracing = "0.1.44"
tokio = { version = "1.49.0", features = ["full"] }
chrono = { version = "0.4.43", features = ["serde"] }
rand = "0.10.0"
uuid = "1.20.0"
[package]
name = "arbiter"
version = "0.1.0"
edition = "2024"
repository = "https://git.markettakers.org/MarketTakers/arbiter"
[dependencies]

View File

@@ -0,0 +1,6 @@
[package]
name = "arbiter-client"
version = "0.1.0"
edition = "2024"
[dependencies]

View File

@@ -0,0 +1,14 @@
pub fn add(left: u64, right: u64) -> u64 {
left + right
}
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn it_works() {
let result = add(2, 2);
assert_eq!(result, 4);
}
}

View File

@@ -0,0 +1,11 @@
[package]
name = "arbiter-proto"
version = "0.1.0"
edition = "2024"
[dependencies]
tonic.workspace = true
prost.workspace = true
[build-dependencies]
tonic-prost-build = "0.14.3"

View File

@@ -0,0 +1,4 @@
fn main() -> Result<(), Box<dyn std::error::Error>> {
// tonic_prost_build::compile_protos("../../protobufs/")?;
Ok(())
}

View File

@@ -0,0 +1,14 @@
pub fn add(left: u64, right: u64) -> u64 {
left + right
}
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn it_works() {
let result = add(2, 2);
assert_eq!(result, 4);
}
}

View File

@@ -0,0 +1 @@
testdb.sqlite

View File

@@ -0,0 +1,11 @@
[package]
name = "arbiter-server"
version = "0.1.0"
edition = "2024"
[dependencies]
diesel = { version = "2.3.6", features = ["sqlite", "uuid", "time", "chrono", "serde_json"] }
diesel-async = { version = "0.7.4", features = ["sqlite", "tokio", "migrations", "pool", "deadpool"] }
tracing.workspace = true
tonic.workspace = true
tokio.workspace = true

View File

@@ -0,0 +1,9 @@
# For documentation on how to configure this file,
# see https://diesel.rs/guides/configuring-diesel-cli
[print_schema]
file = "src/schema.rs"
custom_type_derives = ["diesel::query_builder::QueryId", "Clone"]
[migrations_directory]
dir = "migrations"

View File

@@ -0,0 +1 @@
-- This file should undo anything in `up.sql`

View File

@@ -0,0 +1 @@
-- Your SQL goes here

View File

@@ -0,0 +1,5 @@
#[tokio::main]
pub async fn main() {
}

9
server/diesel.toml Normal file
View File

@@ -0,0 +1,9 @@
# For documentation on how to configure this file,
# see https://diesel.rs/guides/configuring-diesel-cli
[print_schema]
file = "src/schema.rs"
custom_type_derives = ["diesel::query_builder::QueryId", "Clone"]
[migrations_directory]
dir = "migrations"

0
server/migrations/.keep Normal file
View File

3
server/src/main.rs Normal file
View File

@@ -0,0 +1,3 @@
fn main() {
println!("Hello, world!");
}

View File

@@ -0,0 +1,4 @@
# cargo-vet audits file
[audits]

View File

@@ -0,0 +1,5 @@
# cargo-vet config file
[cargo-vet]
version = "0.10"

View File

@@ -0,0 +1,2 @@
# cargo-vet imports lock