Add logging to improve maintainability (#1117)

Signed-off-by: Alexander Garagatyi <agaragatyi@codenvy.com>
6.19.x
Alexander Garagatyi 2016-04-22 16:34:00 +03:00
parent 0780b1f84e
commit eb55f0cd4b
2 changed files with 3 additions and 0 deletions

View File

@ -444,6 +444,8 @@ public class DockerInstanceProvider implements InstanceProvider {
final DockerNode node = dockerMachineFactory.createNode(machine.getWorkspaceId(), containerId);
if (machine.getConfig().isDev()) {
node.bindWorkspace();
LOG.info("Machine with id '{}' backed by container '{}' has been deployed on node '{}'",
machine.getId(), containerId, node.getHost());
}
dockerInstanceStopDetector.startDetection(containerId, machine.getId());

View File

@ -128,6 +128,7 @@ public class DockerInstanceStopDetector {
if (containersOomTimestamps.getIfPresent(message.getId()) != null) {
instanceStateChangeType = InstanceStateEvent.Type.OOM;
containersOomTimestamps.invalidate(message.getId());
LOG.info("OOM of container '{}' has been detected", message.getId());
} else {
instanceStateChangeType = InstanceStateEvent.Type.DIE;
}