[ 
https://issues.apache.org/jira/browse/GEODE-8870?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17271845#comment-17271845
 ] 

ASF GitHub Bot commented on GEODE-8870:
---------------------------------------

echobravopapa commented on a change in pull request #5947:
URL: https://github.com/apache/geode/pull/5947#discussion_r564036242



##########
File path: 
geode-core/src/main/java/org/apache/geode/internal/cache/persistence/DiskInitFileParser.java
##########
@@ -615,10 +611,9 @@ public static void dump(File file) throws IOException, 
ClassNotFoundException {
 
   private static DiskInitFileInterpreter createPrintingInterpreter(
       DiskInitFileInterpreter wrapped) {
-    DiskInitFileInterpreter interpreter = (DiskInitFileInterpreter) 
Proxy.newProxyInstance(
+    return (DiskInitFileInterpreter) Proxy.newProxyInstance(

Review comment:
       nice

##########
File path: 
geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/BaseCommand.java
##########
@@ -1347,14 +1304,10 @@ private static void handleRegEx(LocalRegion region, 
String regex, InterestResult
    */
   private static void handleRegExPR(final PartitionedRegion region, final 
String regex,
       final InterestResultPolicy policy, final ServerConnection servConn) 
throws IOException {
-    final List keyList = new ArrayList(MAXIMUM_CHUNK_SIZE);
+    final List<Object> keyList = new ArrayList<>(MAXIMUM_CHUNK_SIZE);
     region.getKeysWithRegEx(regex, sendTombstonesInRIResults(servConn, policy),
-        new PartitionedRegion.SetCollector() {
-          @Override
-          public void receiveSet(Set theSet) throws IOException {
-            appendInterestResponseKeys(region, regex, theSet, keyList, 
servConn);
-          }
-        });
+        theSet -> appendInterestResponseKeys(region, regex, 
uncheckedCast(theSet), keyList,

Review comment:
       what does the `receiveSet` clean up have to do with Versions?
   

##########
File path: 
geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/CacheClientNotifier.java
##########
@@ -481,8 +483,7 @@ private boolean initializeProxy(CacheClientProxy l_proxy) 
throws CacheException
         removeClientInitProxy(l_proxy);
       }
     }
-    boolean status = false;
-    return status;
+    return false;

Review comment:
       💯 

##########
File path: 
geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/BaseCommandQuery.java
##########
@@ -177,20 +169,15 @@ protected boolean processQueryUsingParams(final Message 
msg,
 
         // Get the collection type (which includes the element type)
         // (used to generate the appropriate instance on the client)
-        collectionType = getCollectionType(selectResults);
-        isStructs = collectionType.getElementType().isStructType();
+        CollectionType collectionType = getCollectionType(selectResults);
+        boolean isStructs = collectionType.getElementType().isStructType();
 
         // Check if the Query is from CQ execution.
         if (cqQuery != null) {
-          // Check if the key can be sent to the client based on its version.
-          sendCqResultsWithKey = sendCqResultsWithKey(servConn);
-
-          if (sendCqResultsWithKey) {
-            // Update the collection type to include key info.
-            collectionType = new CollectionTypeImpl(Collection.class,
-                new StructTypeImpl(new String[] {"key", "value"}));
-            isStructs = collectionType.getElementType().isStructType();
-          }
+          // Update the collection type to include key info.

Review comment:
       presume this means all existing/supported client versions can handle the 
key...

##########
File path: 
geode-core/src/main/java/org/apache/geode/internal/cache/persistence/DiskInitFileParser.java
##########
@@ -469,15 +465,15 @@ public DiskStoreID parse() throws IOException, 
ClassNotFoundException {
           readEndOfRecord(dis);
           if (logger.isTraceEnabled(LogMarker.PERSIST_RECOVERY_VERBOSE)) {
             logger.trace(LogMarker.PERSIST_RECOVERY_VERBOSE,
-                "IFREC_REVOKE_DISK_STORE_ID id={}" + pattern);
+                "IFREC_REVOKE_DISK_STORE_ID id={}", pattern);
           }
           interpreter.cmnRevokeDiskStoreId(pattern);
         }
           break;
         default:
           throw new DiskAccessException(
               String.format("Unknown opCode %s found in disk initialization 
file.", opCode),
-              this.interpreter.getNameForError());
+              interpreter.getNameForError());

Review comment:
       not a fan of `this` i see...

##########
File path: 
geode-core/src/main/java/org/apache/geode/internal/cache/tier/sockets/BaseCommandQuery.java
##########
@@ -287,13 +273,6 @@ protected boolean processQueryUsingParams(final Message 
msg,
       }
       writeQueryResponseException(msg, e, servConn);
       return false;
-    } finally {

Review comment:
       those must have been considered VERY important comments ... I mean nice 
deletion...




----------------------------------------------------------------
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.

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


> Remove obsolete version compatibility code
> ------------------------------------------
>
>                 Key: GEODE-8870
>                 URL: https://issues.apache.org/jira/browse/GEODE-8870
>             Project: Geode
>          Issue Type: Improvement
>            Reporter: Jacob Barrett
>            Assignee: Jacob Barrett
>            Priority: Major
>              Labels: pull-request-available
>
> As a followup to GEODE-8837 remove all obsolete backwards compatibility code.
> This ticket will catch all changes to remove the obsolete code.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to