fix: Reduce CPU pricing for total_units calculation in AppContract

This commit is contained in:
Noor 2025-03-13 06:27:38 +00:00
parent 0aa484f79e
commit 68e03a25e5
Signed by: noormohammedb
GPG Key ID: E424C39E19EFD7DF

@ -202,7 +202,7 @@ pub struct AppContract {
impl AppContract { impl AppContract {
fn total_units(&self) -> f64 { fn total_units(&self) -> f64 {
// TODO: Optimize this based on price of hardware. // TODO: Optimize this based on price of hardware.
(self.vcpus as f64 * 10f64) (self.vcpus as f64 * 5f64)
+ (self.memory_mb as f64 / 200f64) + (self.memory_mb as f64 / 200f64)
+ (self.disk_size_mb as f64 / 10000f64) + (self.disk_size_mb as f64 / 10000f64)
} }