class CloudFoundryContainerPlatform extends CloudFoundryPlatform implements SshBasedExperiment<CloudFoundryContainer> {

    Instant getTimeInState (CloudFoundryContainer container) {
        log.debug("Looking for time in state of {}", v(DataDogConstants.DATADOG_CONTAINER_KEY, container));
        String applicationId = container.getApplicationId();
        String instanceIndex = container.getInstance().toString();
        final ApplicationInstanceInfo applicationInstanceInfo = cloudFoundryClient.applicationsV2()
                                                                                  .instances(ApplicationInstancesRequest
                                                                                          .builder()
                                                                                          .applicationId(applicationId)
                                                                                          .build())
                                                                                  .blockOptional()
                                                                                  .orElseThrow(EMPTY_RESPONSE.asChaosException())
                                                                                  .getInstances()
                                                                                  .get(instanceIndex);
        log.debug("Time in state from Application Instance Info: {}", v("applicationInstanceInfo", applicationInstanceInfo));
        Double since = applicationInstanceInfo.getSince();
        return since == null ? null : Instant.ofEpochSecond(since.longValue());
    }

    @Autowired public  CloudFoundryContainerPlatform();

}