Skip to content

Commit

Permalink
bug: service name being unknown (#1202)
Browse files Browse the repository at this point in the history
  • Loading branch information
chesedo committed Sep 6, 2023
1 parent 7ab8d11 commit d661143
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
1 change: 1 addition & 0 deletions common/src/log.rs
Expand Up @@ -31,6 +31,7 @@ pub enum Backend {
Logger,
Provisioner,
ResourceRecorder,
Runtime(String),
}

#[derive(Clone, Debug, Deserialize, Serialize)]
Expand Down
7 changes: 5 additions & 2 deletions deployer/src/runtime_manager.rs
Expand Up @@ -3,7 +3,10 @@ use std::{collections::HashMap, path::PathBuf, sync::Arc};
use anyhow::Context;
use chrono::Utc;
use prost_types::Timestamp;
use shuttle_common::claims::{ClaimService, InjectPropagation};
use shuttle_common::{
claims::{ClaimService, InjectPropagation},
log::Backend,
};
use shuttle_proto::{
logger::{logger_client::LoggerClient, Batcher, LogItem, LogLine},
runtime::{self, runtime_client::RuntimeClient, StopRequest},
Expand Down Expand Up @@ -154,7 +157,7 @@ impl RuntimeManager {
let log = LogItem {
deployment_id: id.to_string(),
log_line: Some(LogLine {
service_name: service_name.to_string(),
service_name: Backend::Runtime(service_name.clone()).to_string(),
tx_timestamp: Some(Timestamp {
seconds: utc.timestamp(),
nanos: utc.timestamp_subsec_nanos().try_into().unwrap_or_default(),
Expand Down

0 comments on commit d661143

Please sign in to comment.