APISonar


com.yahoo.vespa.hosted.controller.api.integration.configserver.Log.Log

> com > yahoo > vespa > hosted > controller > api > integration > configserver > Log > Log
com APIs yahoo APIs vespa APIs hosted APIs controller APIs api APIs integration APIs configserver APIs Log APIs Log APIs

Example 1
public void generateWarnings(DeploymentId deployment, int count) {
        List<Log> logs = new ArrayList<>(count);
        for (int i = 0; i < count; i++) {
            Log log = new Log();
            log.time = Instant.now().toEpochMilli();
            log.level = Level.WARNING.getName();
            log.message = "log message " + (count + 1) + " generated by unit test";
            logs.add(log);
        }
        warnings.put(deployment, List.copyOf(logs));
    }
Example 2
private ActivateResult unexpectedDeployment(ApplicationId application, ZoneId zone) {
        Log logEntry = new Log();
        logEntry.level = "WARNING";
        logEntry.time = clock.instant().toEpochMilli();
        logEntry.message = "Ignoring deployment of application '" + application + "' to " + zone +
                           " as a deployment is not currently expected";
        PrepareResponse prepareResponse = new PrepareResponse();
        prepareResponse.log = List.of(logEntry);
        prepareResponse.configChangeActions = new ConfigChangeActions(List.of(), List.of());
        return new ActivateResult(new RevisionId("0"), prepareResponse, 0);
    }