PrepareParams { public List<ContainerEndpoint> containerEndpoints() { return containerEndpoints; } private  PrepareParams(ApplicationId applicationId, TimeoutBudget timeoutBudget, boolean ignoreValidationErrors,
                          boolean dryRun, boolean verbose, boolean isBootstrap, Optional<Version> vespaVersion,
                          List<ContainerEndpoint> containerEndpoints, Optional<String> tlsSecretsKeyName,
                          Optional<EndpointCertificateMetadata> endpointCertificateMetadata,
                          Optional<DockerImage> dockerImageRepository, Optional<AthenzDomain> athenzDomain,
                          Optional<ApplicationRoles> applicationRoles, Optional<Quota> quota, boolean force,
                          boolean internalRestart); static PrepareParams fromHttpRequest(HttpRequest request, TenantName tenant, Duration barrierTimeout); String getApplicationName(); ApplicationId getApplicationId(); Optional<Version> vespaVersion(); List<ContainerEndpoint> containerEndpoints(); boolean ignoreValidationErrors(); boolean isDryRun(); boolean isVerbose(); boolean isBootstrap(); boolean force(); boolean internalRestart(); TimeoutBudget getTimeoutBudget(); Optional<String> tlsSecretsKeyName(); Optional<EndpointCertificateMetadata> endpointCertificateMetadata(); Optional<DockerImage> dockerImageRepository(); Optional<AthenzDomain> athenzDomain(); Optional<ApplicationRoles> applicationRoles(); Optional<Quota> quota();  }
@Test public void testCorrectParsingWithContainerEndpoints() { var endpoints = List.of(new ContainerEndpoint("qrs1", List.of("c1.example.com", "c2.example.com")), new ContainerEndpoint("qrs2", List.of("c3.example.com", "c4.example.com"))); var param = "[\n" + " {\n" + " \"clusterId\": \"qrs1\",\n" + " \"names\": [\"c1.example.com\", \"c2.example.com\"]\n" + " },\n" + " {\n" + " \"clusterId\": \"qrs2\",\n" + " \"names\": [\"c3.example.com\", \"c4.example.com\"]\n" + " }\n" + "]"; var encoded = URLEncoder.encode(param, StandardCharsets.UTF_8); var prepareParams = createParams(request + "&" + PrepareParams.CONTAINER_ENDPOINTS_PARAM_NAME + "=" + encoded, TenantName.from("foo")); assertEquals(endpoints, prepareParams.containerEndpoints()); }