public static HttpServiceResponse createResponse(ConfigConvergenceChecker.ServiceResponse serviceResponse, String hostAndPort, URI uri) {
            return switch (serviceResponse.status) {
                case ok ->
                        createOkResponse(uri, hostAndPort, serviceResponse.wantedGeneration, serviceResponse.currentGeneration, serviceResponse.converged);
                case hostNotFound ->
                        createHostNotFoundInAppResponse(uri, hostAndPort, serviceResponse.wantedGeneration);
                case notFound ->
                        createNotFoundResponse(uri, hostAndPort, serviceResponse.wantedGeneration, serviceResponse.errorMessage.orElse(""));
                case error ->
                        createErrorResponse(uri, hostAndPort, serviceResponse.wantedGeneration, serviceResponse.errorMessage.orElse(""));
            };
        }
Operations on applications (delete, wait for config convergence, restart, application content etc.)

@author hmusum
configserver/src/main/java/com/yahoo/vespa/config/server/http/v2/ApplicationHandler.java