diff --git a/node/src/integration-test/kotlin/net/corda/node/jmx/NodeStatus.kt b/node/src/integration-test/kotlin/net/corda/node/jmx/NodeStatus.kt index 24116f6fe1..c889c1e14d 100644 --- a/node/src/integration-test/kotlin/net/corda/node/jmx/NodeStatus.kt +++ b/node/src/integration-test/kotlin/net/corda/node/jmx/NodeStatus.kt @@ -19,7 +19,12 @@ class NodeStatusTest { driver(DriverParameters(notarySpecs = emptyList(), jmxPolicy = JmxPolicy.defaultEnabled())) { val jmxAddress = startNode().get().jmxAddress.toString() val nodeStatusURL = URL("http://$jmxAddress/jolokia/read/net.corda:name=Status,type=Node") - var jmxInfo = "" + val jmxInfo = with(nodeStatusURL.openConnection() as HttpURLConnection) { + requestMethod = "GET" + inputStream.bufferedReader().use { + it.lines().collect(Collectors.toList()).joinToString() + } + } with(nodeStatusURL.openConnection() as HttpURLConnection) { requestMethod = "GET"