updater #1
| @ -54,7 +54,6 @@ message UpdateVMReq { | ||||
| 
 | ||||
| message UpdateVMResp { | ||||
|   string uuid = 1; | ||||
|   string timestamp = 2; | ||||
|   string error = 3; | ||||
| } | ||||
| 
 | ||||
| @ -72,6 +71,7 @@ message VMContract { | ||||
|   string kernel_sha = 11; | ||||
|   string dtrfs_sha = 12; | ||||
|   string created_at = 13; | ||||
|   string updated_at = 14; | ||||
| } | ||||
| 
 | ||||
| message ListVMContractsReq { | ||||
| @ -127,4 +127,4 @@ service BrainCliService { | ||||
|   rpc ListNodes (NodeFilters) returns (stream NodeListResp); | ||||
|   rpc DeleteVM (DeleteVMReq) returns (Empty); | ||||
|   rpc UpdateVM (UpdateVMReq) returns (UpdateVMResp); | ||||
| } | ||||
| } | ||||
|  | ||||
| @ -54,7 +54,6 @@ message UpdateVMReq { | ||||
| 
 | ||||
| message UpdateVMResp { | ||||
|   string uuid = 1; | ||||
|   string timestamp = 2; | ||||
|   string error = 3; | ||||
| } | ||||
| 
 | ||||
| @ -72,6 +71,7 @@ message VMContract { | ||||
|   string kernel_sha = 11; | ||||
|   string dtrfs_sha = 12; | ||||
|   string created_at = 13; | ||||
|   string updated_at = 14; | ||||
| } | ||||
| 
 | ||||
| message ListVMContractsReq { | ||||
| @ -127,4 +127,4 @@ service BrainCliService { | ||||
|   rpc ListNodes (NodeFilters) returns (stream NodeListResp); | ||||
|   rpc DeleteVM (DeleteVMReq) returns (Empty); | ||||
|   rpc UpdateVM (UpdateVMReq) returns (UpdateVMResp); | ||||
| } | ||||
| } | ||||
|  | ||||
| @ -148,7 +148,6 @@ async fn handle_update_vm_requests( | ||||
|     while let Some(update_vm) = req.recv().await { | ||||
|         let confirmation = UpdateVmResp { | ||||
|             uuid: update_vm.uuid, | ||||
|             timestamp: "brain's job".to_string(), | ||||
|             error: "No errors yet".to_string(), | ||||
|         }; | ||||
| 
					
					ghe0 marked this conversation as resolved
					
						
						
							Outdated
						
					
				 | ||||
|         info!("Sending UpdateVmResp: {confirmation:?}"); | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	
The timestamp must be set from the brain, for security reasons.
Also, this does not require chrono.
Check this: