@Test public void build_time_reporting() { var tester = new DeploymentTester(); var applicationPackage = new ApplicationPackageBuilder().region("us-west-1").build(); var context = tester.newDeploymentContext() .submit(applicationPackage) .deploy(); assertEquals(1000, context.lastSubmission().get().buildTime().get().toEpochMilli()); MetricsReporter reporter = createReporter(tester.controller()); reporter.maintain(); assertEquals(tester.clock().instant().getEpochSecond() - 1, getMetric(MetricsReporter.DEPLOYMENT_BUILD_AGE_SECONDS, context.instanceId())); }
@Override public boolean maintain() { reportDeploymentMetrics(); reportRemainingRotations(); reportQueuedNameServiceRequests(); reportInfrastructureUpgradeMetrics(); reportAuditLog(); return true; }
MetricsReporter extends ControllerMaintainer { @Override public boolean maintain() { reportDeploymentMetrics(); reportRemainingRotations(); reportQueuedNameServiceRequests(); reportInfrastructureUpgradeMetrics(); reportAuditLog(); return true; } }
MetricsReporter extends ControllerMaintainer { @Override public boolean maintain() { reportDeploymentMetrics(); reportRemainingRotations(); reportQueuedNameServiceRequests(); reportInfrastructureUpgradeMetrics(); reportAuditLog(); return true; } MetricsReporter(Controller controller, Metric metric); }
MetricsReporter extends ControllerMaintainer { @Override public boolean maintain() { reportDeploymentMetrics(); reportRemainingRotations(); reportQueuedNameServiceRequests(); reportInfrastructureUpgradeMetrics(); reportAuditLog(); return true; } MetricsReporter(Controller controller, Metric metric); @Override boolean maintain(); }
MetricsReporter extends ControllerMaintainer { @Override public boolean maintain() { reportDeploymentMetrics(); reportRemainingRotations(); reportQueuedNameServiceRequests(); reportInfrastructureUpgradeMetrics(); reportAuditLog(); return true; } MetricsReporter(Controller controller, Metric metric); @Override boolean maintain(); static final String DEPLOYMENT_FAIL_METRIC; static final String DEPLOYMENT_AVERAGE_DURATION; static final String DEPLOYMENT_FAILING_UPGRADES; static final String DEPLOYMENT_BUILD_AGE_SECONDS; static final String DEPLOYMENT_WARNINGS; static final String OS_CHANGE_DURATION; static final String PLATFORM_CHANGE_DURATION; static final String OS_NODE_COUNT; static final String PLATFORM_NODE_COUNT; static final String REMAINING_ROTATIONS; static final String NAME_SERVICE_REQUESTS_QUEUED; static final String OPERATION_PREFIX; }