turboFei commented on code in PR #3233:
URL: https://github.com/apache/incubator-kyuubi/pull/3233#discussion_r948576377
##########
kyuubi-server/src/test/scala/org/apache/kyuubi/server/api/v1/SessionsResourceSuite.scala:
##########
@@ -127,6 +130,13 @@ class SessionsResourceSuite extends KyuubiFunSuite with
RestFrontendTestHelper {
}
test("get infoType") {
+ val totalConnections =
+
MetricsSystem.counterValue(MetricsConstants.REST_CONN_TOTAL).getOrElse(0L)
+ val openConnections =
Review Comment:
just remove it
##########
kyuubi-server/src/test/scala/org/apache/kyuubi/server/api/v1/SessionsResourceSuite.scala:
##########
@@ -160,6 +170,15 @@ class SessionsResourceSuite extends KyuubiFunSuite with
RestFrontendTestHelper {
response = webTarget.path(s"api/v1/sessions/$sessionHandle/info/str")
.request().get()
assert(404 == response.getStatus)
+
+ eventually(timeout(3.seconds), interval(200.milliseconds)) {
+ assert(MetricsSystem.counterValue(
+ MetricsConstants.REST_CONN_TOTAL).getOrElse(0L) - totalConnections ===
6)
+ assert(MetricsSystem.counterValue(
+ MetricsConstants.REST_CONN_OPEN).getOrElse(0L) - openConnections === 0)
Review Comment:
```
assert(MetricsSystem.counterValue(MetricsConstants.REST_CONN_OPEN).getOrElse(0L)
=== 0)
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]