-
Bug
-
Resolution: Fixed
-
Medium
-
3.6.1
Under certain circumstances, the number of concurrent connections to the Crowd server will fall to the default of 2 instead of the configured 20. This can cause a bottleneck for authentication attempts to the Stash server.
Steps to reproduce
- Configure a User Directory to connect to the Crowd server over the default port for either HTTP or HTTPS.
- Attempt to login after turning on Crowd debug logging in Stash
- curl -X PUT -u USER https://server.com/stash/rest/api/latest/logs/logger/com.atlassian.crowd/DEBUG
- The logs will show that a maximum of 2 connections are allowed for the route.
@8CUIBPx573x1141x0 0:0:0:0:0:0:0:1 "POST /j_stash_security_check HTTP/1.1" c.a.c.i.rest.service.RestExecutor Constructed https://server.com/crowd/rest/usermanagement/1/authentication?username=jeffcrowd 2015-02-12 09:33:33,708 DEBUG [http-nio-7990-exec-1] @8CUIBPx573x1141x0 0:0:0:0:0:0:0:1 "POST /j_stash_security_check HTTP/1.1" c.a.c.i.r.s.u.ShutdownIgnoringMultiThreadedHttpConnectionManager Connection request: [route: {s}->https://server.com:443][total kept alive: 1; route allocated: 1 of 2; total allocated: 1 of 20] 2015-02-12 09:33:33,708 DEBUG [http-nio-7990-exec-1] @8CUIBPx573x1141x0 0:0:0:0:0:0:0:1 "POST /j_stash_security_check HTTP/1.1" c.a.c.i.r.s.u.ShutdownIgnoringMultiThreadedHttpConnectionManager Connection leased: [id: 4][route: {s}->https://server.com:443][total kept alive: 0; route allocated: 1 of 2; total allocated: 1 of 20] 2015-02-12 09:33:34,222 DEBUG [http-nio-7990-exec-1] @8CUIBPx573x1141x0 0:0:0:0:0:0:0:1 "POST /j_stash_security_check HTTP/1.1" c.a.c.i.rest.service.RestExecutor Cache response for POST https://server.com/crowd/rest/usermanagement/1/authentication?username=jeffcrowd was CACHE_MISS 2015-02-12 09:33:34,223 DEBUG [http-nio-7990-exec-1] @8CUIBPx573x1141x0 0:0:0:0:0:0:0:1 "POST /j_stash_security_check HTTP/1.1" c.a.c.i.r.s.u.ShutdownIgnoringMultiThreadedHttpConnectionManager Connection [id: 4][route: {s}->https://server.com:443] can be kept alive indefinitely 2015-02-12 09:33:34,223 DEBUG [http-nio-7990-exec-1] @8CUIBPx573x1141x0 0:0:0:0:0:0:0:1 "POST /j_stash_security_check HTTP/1.1" c.a.c.i.r.s.u.ShutdownIgnoringMultiThreadedHttpConnectionManager Connection released: [id: 4][route: {s}->https://server.com:443][total kept alive: 1; route allocated: 1 of 2; total allocated: 1 of 20]
Expected result
20 connections should be allowed for a route:
2015-02-10 17:38:23,619 DEBUG [http-nio-7990-exec-3] @HDCY0Px1058x22359x0 0:0:0:0:0:0:0:1 "POST /j_stash_security_check HTTP/1.1" c.a.c.i.r.s.u.ShutdownIgnoringMultiThreadedHttpConnectionManager Connection request: [route: {}->http://localhost:8095][total kept alive: 0; route allocated: 0 of 20; total allocated: 0 of 20]
Workaround
Use a port other than 80 or 443 to connect to the Crowd server.