[ https://issues.apache.org/jira/browse/GEODE-10144?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17510954#comment-17510954 ]
Barrett Oglesby commented on GEODE-10144: ----------------------------------------- Here is why this test passes with the previous server code. In the previous server code, after the Client Message Dispatcher caught an AuthenticationExpiredException, it slept for 200 ms before trying again. It does this for up to 5 seconds before giving up. Each time it retries, it asks for authorization again. Here is a case where SimulatedExpirationSecurityManager.authorize throws an AuthenticationExpiredException: {noformat} [warn 2022/03/22 14:59:04.110 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher about to dispatchMessage operation=AFTER_CREATE; key=key130 [warn 2022/03/22 14:59:04.110 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX SimulatedExpirationSecurityManager.authorize about to throw AuthenticationExpiredException [warn 2022/03/22 14:59:04.110 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher caught AuthenticationExpiredException [warn 2022/03/22 14:59:04.110 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher skipped sending ClientReAuthenticateMessage clientVersion=GFE 9.0 {noformat} The Client Message Dispatcher sleeps for 200 ms: {noformat} [warn 2022/03/22 14:59:04.110 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher about to sleep 1 for 200 ms [warn 2022/03/22 14:59:04.311 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher done sleep 1 {noformat} When it wakes up, it checks for authorization again. This time, the SimulatedExpirationSecurityManager returns true, so the message is sent: {noformat} [warn 2022/03/22 14:59:04.311 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher about to dispatchMessage operation=AFTER_CREATE; key=key130 [warn 2022/03/22 14:59:04.311 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX SimulatedExpirationSecurityManager.authorize about to return true [warn 2022/03/22 14:59:04.311 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher done dispatchMessage operation=AFTER_CREATE; key=key130 {noformat} This path is not relying on outside operations to notify the Client Message Dispatcher. The SimulatedExpirationSecurityManager authorizes the operation after the sleep. So at the end of the run where there are no client operations, the Client Message Dispatcher is most likely only going to sleep 200 ms. There is never going to be a 5 second wait. I did see a few times where the Client Message Dispatcher slept twice through the loop (so 400 ms): {noformat} [warn 2022/03/22 14:59:23.924 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher about to dispatchMessage operation=AFTER_UPDATE; key=key4820 [warn 2022/03/22 14:59:23.924 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX SimulatedExpirationSecurityManager.authorize about to throw AuthenticationExpiredException [warn 2022/03/22 14:59:23.924 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher caught AuthenticationExpiredException [warn 2022/03/22 14:59:23.924 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher skipped sending ClientReAuthenticateMessage clientVersion=GFE 9.0 [warn 2022/03/22 14:59:23.924 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher about to sleep 1 for 200 ms [warn 2022/03/22 14:59:24.124 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher done sleep 1 [warn 2022/03/22 14:59:24.124 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher about to dispatchMessage operation=AFTER_UPDATE; key=key4820 [warn 2022/03/22 14:59:24.124 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX SimulatedExpirationSecurityManager.authorize about to throw AuthenticationExpiredException [warn 2022/03/22 14:59:24.124 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher caught AuthenticationExpiredException [warn 2022/03/22 14:59:24.124 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher about to sleep 2 for 200 ms [warn 2022/03/22 14:59:24.325 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher done sleep 2 [warn 2022/03/22 14:59:24.325 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher about to dispatchMessage operation=AFTER_UPDATE; key=key4820 [warn 2022/03/22 14:59:24.325 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX SimulatedExpirationSecurityManager.authorize about to return true [warn 2022/03/22 14:59:24.325 PDT CqPlusAuthInitializeTest_reAuthenticateWithDurable_server_0 <Client Message Dispatcher for boglesbymac(default_GeodeDS:68789:loner):2:Native_yVJjpmSbhw68789:default_GeodeDS (DurableClient-1111_gem_default)> tid=0x51] XXX MessageDispatcher.runDispatcher done dispatchMessage operation=AFTER_UPDATE; key=key4820 {noformat} > Regression in geode-native test > CqPlusAuthInitializeTest.reAuthenticateWithDurable > ---------------------------------------------------------------------------------- > > Key: GEODE-10144 > URL: https://issues.apache.org/jira/browse/GEODE-10144 > Project: Geode > Issue Type: Bug > Components: client/server > Affects Versions: 1.15.0 > Reporter: Blake Bender > Assignee: Jinmei Liao > Priority: Major > Labels: blocks-1.15.0, needsTriage > Fix For: 1.15.0 > > > This test is failing across the board in the `geode-native` PR pipeline. > Main develop pipeline is green only because nothing can get through the PR > pipeline to clear checkin gates. We have green CI runs with 1.15. build 918, > then it started failing when we picked up build 924. > > [~moleske] tracked this back to this commit: > [https://github.com/apache/geode/commit/2554f42b925f2b9b8ca7eee14c7a887436b1d9db|https://github.com/apache/geode/commit/2554f42b925f2b9b8ca7eee14c7a887436b1d9db]. > See his notes in `geode-native` PR # 947 > ([https://github.com/apache/geode-native/pull/947]) -- This message was sent by Atlassian Jira (v8.20.1#820001)