mirror of
https://github.com/YGGverse/aquatic.git
synced 2026-04-02 10:45:30 +00:00
WIP: start work on aquatic_http_private
This commit is contained in:
parent
f0a662e474
commit
11829f98eb
11 changed files with 2821 additions and 22 deletions
24
aquatic_http_private/src/main.rs
Normal file
24
aquatic_http_private/src/main.rs
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
mod workers;
|
||||
use dotenv::dotenv;
|
||||
|
||||
fn main() -> anyhow::Result<()> {
|
||||
dotenv().ok();
|
||||
|
||||
let mut handles = Vec::new();
|
||||
|
||||
for _ in 0..2 {
|
||||
let handle = ::std::thread::Builder::new()
|
||||
.name("socket".into())
|
||||
.spawn(move || workers::socket::run_socket_worker())?;
|
||||
|
||||
handles.push(handle);
|
||||
}
|
||||
|
||||
for handle in handles {
|
||||
handle
|
||||
.join()
|
||||
.map_err(|err| anyhow::anyhow!("thread join error: {:?}", err))??;
|
||||
}
|
||||
|
||||
Ok(())
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue