jinmeiliao commented on code in PR #7598:
URL: https://github.com/apache/geode/pull/7598#discussion_r852236684


##########
geode-old-client-support/src/main/java/com/gemstone/gemfire/OldClientSupportProvider.java:
##########
@@ -121,19 +124,23 @@ public String processOutgoingClassName(String name, 
DataOutput out) {
   }
 
   @Override
-  public Throwable getThrowable(Throwable theThrowable, KnownVersion 
clientVersion) {
+  public Throwable getThrowable(Throwable theThrowable, KnownVersion 
clientVersion,
+      ClientProxyMembershipID clientId) {
 
     if (theThrowable == null) {
       return theThrowable;
     }
 
     // backward compatibility for authentication expiration
-    if 
(clientVersion.isOlderThan(ClientReAuthenticateMessage.RE_AUTHENTICATION_START_VERSION))
 {
-      if (theThrowable instanceof AuthenticationExpiredException) {
-        return new AuthenticationRequiredException(USER_NOT_FOUND);
-      }
-      Throwable cause = theThrowable.getCause();
-      if (cause instanceof AuthenticationExpiredException) {
+    if (clientVersion.isOlderThan(RE_AUTHENTICATION_START_VERSION)) {
+      if (theThrowable instanceof AuthenticationExpiredException
+          || theThrowable.getCause() instanceof 
AuthenticationExpiredException) {
+        if (CacheClientNotifier.getInstance().getClientProxy(clientId) != 
null) {
+          // Re-authentication with Server->Client queues is not supported
+          return new IllegalStateException(OLD_CLIENT_AUTHENTICATION_EXPIRED);

Review Comment:
   Then this change would require the "user" to handle it. Users probably will 
have a catch call "exception" case, is this sufficient? 
   
   This has caused some client tests to fail that only sets the subscription 
enabled to be "true", but never uses a CQ/RI. 
   
   I still don't think this is necessary. As I have discussed in the slack 
channel, the queue would find out the exception soon enough to close all 
connections. 



-- 
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: notifications-unsubscr...@geode.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to