diff --git a/extensions/mongodb-client/deployment/src/main/java/io/quarkus/mongodb/deployment/DevServicesMongoProcessor.java b/extensions/mongodb-client/deployment/src/main/java/io/quarkus/mongodb/deployment/DevServicesMongoProcessor.java index 73d850467eab5d..4307cedcca7c39 100644 --- a/extensions/mongodb-client/deployment/src/main/java/io/quarkus/mongodb/deployment/DevServicesMongoProcessor.java +++ b/extensions/mongodb-client/deployment/src/main/java/io/quarkus/mongodb/deployment/DevServicesMongoProcessor.java @@ -189,14 +189,16 @@ private RunningDevService startMongo(DockerStatusBuildItem dockerStatusBuildItem timeout.ifPresent(mongoDBContainer::withStartupTimeout); mongoDBContainer.withEnv(capturedProperties.containerEnv); mongoDBContainer.start(); - final String effectiveUrl = getEffectiveUrl(configPrefix, mongoDBContainer.getHost(), mongoDBContainer.getMappedPort(MONGO_EXPOSED_PORT), capturedProperties); + final String effectiveUrl = getEffectiveUrl(configPrefix, mongoDBContainer.getHost(), + mongoDBContainer.getMappedPort(MONGO_EXPOSED_PORT), capturedProperties); return new RunningDevService(Feature.MONGODB_CLIENT.getName(), mongoDBContainer.getContainerId(), mongoDBContainer::close, getConfigPrefix(connectionName) + "connection-string", effectiveUrl); }; return mongoContainerLocator.locateContainer(capturedProperties.serviceName(), capturedProperties.shared(), launchMode) .map(containerAddress -> { - final String effectiveUrl = getEffectiveUrl(configPrefix, containerAddress.getHost(), containerAddress.getPort(), capturedProperties); + final String effectiveUrl = getEffectiveUrl(configPrefix, containerAddress.getHost(), + containerAddress.getPort(), capturedProperties); return new RunningDevService(Feature.MONGODB_CLIENT.getName(), containerAddress.getId(), null, getConfigPrefix(connectionName) + "connection-string", effectiveUrl); @@ -212,10 +214,10 @@ private String getEffectiveUrl(String configPrefix, String host, int port, Captu if ((capturedProperties.connectionProperties != null) && !capturedProperties.connectionProperties.isEmpty()) { effectiveUrl = effectiveUrl + "?" + URLEncodedUtils.format( - capturedProperties.connectionProperties.entrySet().stream() - .map(e -> new BasicNameValuePair(e.getKey(), e.getValue())) - .collect(Collectors.toList()), - StandardCharsets.UTF_8); + capturedProperties.connectionProperties.entrySet().stream() + .map(e -> new BasicNameValuePair(e.getKey(), e.getValue())) + .collect(Collectors.toList()), + StandardCharsets.UTF_8); } return effectiveUrl; }