Skip to content

Commit

Permalink
chore: refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
isaidsari committed May 26, 2024
1 parent 2ab1434 commit f5f22e2
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
7 changes: 3 additions & 4 deletions src/api.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
use hyper::{Body, Request, Response};
use serde::{Deserialize, Serialize};

pub mod _404;
pub mod get_cpu_status;
Expand All @@ -7,22 +8,20 @@ pub mod get_disk_status;
pub mod get_hardware_info;
pub mod get_mem_status;
pub mod get_otp_qr;
pub mod get_processes;
pub mod healthcheck;
pub mod hello;
pub mod kill_process;
pub mod login;
pub mod teapot;
pub mod update_info;
pub mod validate_token_test;
pub mod get_processes;
pub mod kill_process;

pub mod logs {
pub mod get_app_ids;
pub mod get_app_logs;
}

use serde::{Deserialize, Serialize};

#[derive(Serialize, Deserialize)]
#[serde(rename_all = "lowercase")]
pub enum ResponseBody {
Expand Down
9 changes: 5 additions & 4 deletions src/monitor/config_exceeds.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
use chrono::Duration;
use log::{error, info, warn};
use std::collections::HashMap;
use std::vec;

use crate::monitor::models::get_cpu_status::CpuFrameStatusTrait;

use crate::logs::persistence::{
Expand All @@ -7,10 +12,6 @@ use crate::monitor::models::get_hardware_info::{HardwareDiskInfo, HardwareMemInf
use crate::monitor::models::get_mem_status::MemStatusData;
use crate::monitor::persistence::fetch_monitor_configs;
use crate::notification_service::{self, NotificationMessage};
use chrono::Duration;
use log::{error, info, warn};
use std::collections::HashMap;
use std::vec;

use super::models::get_cpu_status::CpuStatusData;
use super::models::get_disk_status::{DiskStatusData, DiskStatusDataTrait};
Expand Down

0 comments on commit f5f22e2

Please sign in to comment.