From fad27b6792bdbe04cd9d2e4e2f0c64ba873afc0c Mon Sep 17 00:00:00 2001 From: Quaternions Date: Tue, 3 Dec 2024 17:36:02 -0800 Subject: [PATCH] do not reply with nats --- validation/src/nats_types.rs | 19 +------------------ validation/src/validator.rs | 2 +- 2 files changed, 2 insertions(+), 19 deletions(-) diff --git a/validation/src/nats_types.rs b/validation/src/nats_types.rs index 29dc20f..edf269f 100644 --- a/validation/src/nats_types.rs +++ b/validation/src/nats_types.rs @@ -2,7 +2,7 @@ // to perform the operation, not necessarily the over-the-wire format // Requests are sent from maps-service to validator -// Responses are sent from validator to maps-service +// Validation invokes the REST api to update the submissions #[derive(serde::Deserialize)] pub struct ValidateRequest{ @@ -12,18 +12,6 @@ pub struct ValidateRequest{ pub model_version:u64, } -pub struct ValidateResponse{ - pub submission_id:u64, - // model id will be changed if scripts were replaced - pub model_id:u64, - pub model_version:u64, -} - -// an invalidate is sent instead if validation fails -pub struct InvalidateResponse{ - pub submission_id:u64, -} - // Create a new map pub struct PublishNewRequest{ pub submission_id:u64, @@ -40,8 +28,3 @@ pub struct PublishFixRequest{ pub model_version:u64, pub target_asset_id:u64, } - -pub struct PublishResponse{ - pub submission_id:u64, - pub success:bool, -} diff --git a/validation/src/validator.rs b/validation/src/validator.rs index 600b866..ebb250f 100644 --- a/validation/src/validator.rs +++ b/validation/src/validator.rs @@ -51,7 +51,7 @@ impl Validator{ match self.validate(message).await{ Ok(valid)=>{ unimplemented!(); - // self.nats.publish("validated","yo it validated".into()).await.unwrap(); + // self.api.validate(validate_response).await.unwrap(); }, Err(e)=>{ println!("there was an error, oopsie! {e}");