private HttpResponse serviceStateV1(ApplicationId applicationId, String service, String hostname, HttpURL.Path rest, HttpRequest request) {
        Query query = Query.empty().add(request.getJDiscRequest().parameters());
        String forwardedUrl = query.lastEntries().get("forwarded-url");
        return applicationRepository.proxyServiceHostnameRequest(applicationId, hostname, service,
                                                                 HttpURL.Path.parse("/state/v1").append(rest),
                                                                 query.remove("forwarded-url"),
                                                                 forwardedUrl == null ? null : HttpURL.from(URI.create(forwardedUrl)));
    }
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