treewide: Migrate to clean-architecture

Signed-off-by: supercmmetry <vishaals2000@gmail.com>
This commit is contained in:
supercmmetry committed 2020-06-24 13:45:35 +05:30
1 parent 810af687c6
commit da21eb1189
13 files changed
+42 -7

No files matched your search

View File
Whitespace-only changes.
View File
Whitespace-only changes.
View File
Whitespace-only changes.
+5
View File
@@ -0,0 +1,5 @@
pub mod routes;
pub mod catchers;
mod guards;
mod misc;
+11
View File
@@ -0,0 +1,11 @@
use rocket::Rocket;
#[get("/check")]
fn check() -> &'static str {
"OK"
}
pub fn fuel(rocket: Rocket) -> Rocket {
rocket.mount("/api/health", routes![check])
}
+12
View File
@@ -0,0 +1,12 @@
use rocket::Rocket;
pub mod health;
pub fn fuel(rocket: Rocket) -> Rocket {
let mut rocket = rocket;
rocket = health::fuel(rocket);
rocket
}
+1
View File
@@ -0,0 +1 @@
pub mod paste;
View File
Whitespace-only changes.
View File
Whitespace-only changes.
+4
View File
@@ -0,0 +1,4 @@
pub mod entity;
pub mod repository;
pub mod diesel;
pub mod service;
View File
Whitespace-only changes.
View File
Whitespace-only changes.
+9 -7
View File
@@ -3,13 +3,15 @@
#[macro_use] #[macro_use]
extern crate rocket; extern crate rocket;
#[get("/alive")] pub mod api;
fn alive() -> &'static str { pub mod core;
"OK"
}
fn main() { fn main() {
rocket::ignite() let mut rocket = rocket::ignite();
.mount("/", routes![index])
.launch(); rocket = api::routes::fuel(rocket);
rocket.launch();
} }