Skip to content

Commit 4cf0f2a

Browse files
committed
Debug log
1 parent 5f8b964 commit 4cf0f2a

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

src/epsilon/server/instance.rs

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,21 +129,39 @@ impl Instance {
129129
pub fn get_state(&self) -> EpsilonState {
130130
let status = self.pod.status.as_ref().unwrap();
131131

132+
info!("1");
133+
132134
let metadata = &self.pod.metadata;
135+
136+
info!("2");
137+
133138
let labels = metadata.labels.as_ref().unwrap();
134139

140+
info!("3");
141+
135142
let conditions = status.conditions.as_ref().unwrap();
136143

144+
info!("4");
145+
137146
let is_ready = conditions
138147
.iter()
139148
.any(|condition| condition.type_ == "Ready" && condition.status == "True")
140149
&& status.phase.as_ref().unwrap() == "Running";
141150

151+
info!("5");
152+
142153
let label = &labels.get(Label::IN_GAME_LABEL);
154+
155+
info!("6");
156+
143157
let is_in_game = label.is_some() && label.unwrap() == "true";
144158

159+
info!("7");
160+
145161
let is_stopping = metadata.deletion_timestamp.is_some() || self.is_succeeded();
146162

163+
info!("8");
164+
147165
if is_ready && is_in_game {
148166
EpsilonState::InGame
149167
} else if is_stopping {

0 commit comments

Comments
 (0)