You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@geode.apache.org by GitBox <gi...@apache.org> on 2022/02/07 21:57:17 UTC

[GitHub] [geode] pivotal-jbarrett opened a new pull request #7346: GEODE-9982: Pin server version to 1.14 for 1.0.0 and older clients.

pivotal-jbarrett opened a new pull request #7346:
URL: https://github.com/apache/geode/pull/7346


   <!-- Thank you for submitting a contribution to Apache Geode. -->
   
   <!-- In order to streamline the review of the contribution we ask you
   to ensure the following steps have been taken: 
   -->
   
   ### For all changes:
   - [ ] Is there a JIRA ticket associated with this PR? Is it referenced in the commit message?
   
   - [ ] Has your PR been rebased against the latest commit within the target branch (typically `develop`)?
   
   - [ ] Is your initial contribution a single, squashed commit?
   
   - [ ] Does `gradlew build` run cleanly?
   
   - [ ] Have you written or updated unit tests to verify your changes?
   
   - [ ] If adding new dependencies to the code, are these dependencies licensed in a way that is compatible for inclusion under [ASF 2.0](http://www.apache.org/legal/resolved.html#category-a)?
   
   <!-- Note:
   Please ensure that once the PR is submitted, check Concourse for build issues and
   submit an update to your PR as soon as possible. If you need help, please send an
   email to dev@geode.apache.org.
   -->
   


-- 
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-unsubscribe@geode.apache.org

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



[GitHub] [geode] upthewaterspout commented on a change in pull request #7346: GEODE-9982: Pin server version to 1.14 for 1.0.0 and older clients.

Posted by GitBox <gi...@apache.org>.
upthewaterspout commented on a change in pull request #7346:
URL: https://github.com/apache/geode/pull/7346#discussion_r801175701



##########
File path: geode-membership/src/main/java/org/apache/geode/distributed/internal/membership/gms/MemberIdentifierImpl.java
##########
@@ -676,7 +675,14 @@ public void toDataPre_GFE_9_0_0_0(DataOutput out, SerializationContext context)
         durableId == null ? 300 : memberData.getDurableTimeout(),
         out);
 
-    short version = memberData.getVersionOrdinal();
+    final short version;
+    if (context.getSerializationVersion().isNewerThan(KnownVersion.GFE_90)) {
+      version = memberData.getVersionOrdinal();
+    } else {
+      // This version of geode-native could not parse the longer version ordinals.
+      // Let's make these older clients think the server is still 1.14.
+      version = KnownVersion.GEODE_1_14_0.ordinal();

Review comment:
       The version here is the version of this MemberIdentifierImpl object, which may or may not be the member currently executing this code. It could be a MemberIdentifierImpl from a peer, or even from a client or WAN site. 




-- 
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-unsubscribe@geode.apache.org

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



[GitHub] [geode] pivotal-jbarrett commented on pull request #7346: GEODE-9982: Pin server version to 1.14 for 1.0.0 and older clients.

Posted by GitBox <gi...@apache.org>.
pivotal-jbarrett commented on pull request #7346:
URL: https://github.com/apache/geode/pull/7346#issuecomment-1032181412


   > Note that this doesn't just affect clients, it is also WAN sites and peers that are running Geode 1.0. Peers before Geode 1.0 couldn't be in the same system as a current version peer, but 1.0 could be. I believe we test that, it will be interesting to see if our rolling upgrade tests catch anything.
   
   Yeah, I fully expect to fail in spectacular ways.


-- 
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-unsubscribe@geode.apache.org

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



[GitHub] [geode] pivotal-jbarrett closed pull request #7346: GEODE-9982: Pin server version to 1.14 for 1.0.0 and older clients.

Posted by GitBox <gi...@apache.org>.
pivotal-jbarrett closed pull request #7346:
URL: https://github.com/apache/geode/pull/7346


   


-- 
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-unsubscribe@geode.apache.org

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



[GitHub] [geode] pivotal-jbarrett commented on a change in pull request #7346: GEODE-9982: Pin server version to 1.14 for 1.0.0 and older clients.

Posted by GitBox <gi...@apache.org>.
pivotal-jbarrett commented on a change in pull request #7346:
URL: https://github.com/apache/geode/pull/7346#discussion_r801238947



##########
File path: geode-membership/src/main/java/org/apache/geode/distributed/internal/membership/gms/MemberIdentifierImpl.java
##########
@@ -676,7 +675,14 @@ public void toDataPre_GFE_9_0_0_0(DataOutput out, SerializationContext context)
         durableId == null ? 300 : memberData.getDurableTimeout(),
         out);
 
-    short version = memberData.getVersionOrdinal();
+    final short version;
+    if (context.getSerializationVersion().isNewerThan(KnownVersion.GFE_90)) {
+      version = memberData.getVersionOrdinal();
+    } else {
+      // This version of geode-native could not parse the longer version ordinals.
+      // Let's make these older clients think the server is still 1.14.
+      version = KnownVersion.GEODE_1_14_0.ordinal();

Review comment:
       I see what you are saying now. Yeah, I can make that change and see if it affects tests.




-- 
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-unsubscribe@geode.apache.org

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



[GitHub] [geode] pivotal-jbarrett commented on a change in pull request #7346: GEODE-9982: Pin server version to 1.14 for 1.0.0 and older clients.

Posted by GitBox <gi...@apache.org>.
pivotal-jbarrett commented on a change in pull request #7346:
URL: https://github.com/apache/geode/pull/7346#discussion_r801174255



##########
File path: geode-membership/src/main/java/org/apache/geode/distributed/internal/membership/gms/MemberIdentifierImpl.java
##########
@@ -676,7 +675,14 @@ public void toDataPre_GFE_9_0_0_0(DataOutput out, SerializationContext context)
         durableId == null ? 300 : memberData.getDurableTimeout(),
         out);
 
-    short version = memberData.getVersionOrdinal();
+    final short version;
+    if (context.getSerializationVersion().isNewerThan(KnownVersion.GFE_90)) {
+      version = memberData.getVersionOrdinal();
+    } else {
+      // This version of geode-native could not parse the longer version ordinals.
+      // Let's make these older clients think the server is still 1.14.
+      version = KnownVersion.GEODE_1_14_0.ordinal();

Review comment:
       This code will only be in 1.15+, so 1.14.0 will always be the older.




-- 
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-unsubscribe@geode.apache.org

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



[GitHub] [geode] upthewaterspout commented on pull request #7346: GEODE-9982: Pin server version to 1.14 for 1.0.0 and older clients.

Posted by GitBox <gi...@apache.org>.
upthewaterspout commented on pull request #7346:
URL: https://github.com/apache/geode/pull/7346#issuecomment-1032032615


   Note that this doesn't just affect clients, it is also WAN sites and peers that are running Geode 1.0. Peers before Geode 1.0 couldn't be in the same system as a current version peer, but 1.0 could be. I believe we test that, it will be interesting to see if our rolling upgrade tests catch anything.


-- 
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-unsubscribe@geode.apache.org

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



[GitHub] [geode] upthewaterspout commented on a change in pull request #7346: GEODE-9982: Pin server version to 1.14 for 1.0.0 and older clients.

Posted by GitBox <gi...@apache.org>.
upthewaterspout commented on a change in pull request #7346:
URL: https://github.com/apache/geode/pull/7346#discussion_r801148989



##########
File path: geode-membership/src/main/java/org/apache/geode/distributed/internal/membership/gms/MemberIdentifierImpl.java
##########
@@ -676,7 +675,14 @@ public void toDataPre_GFE_9_0_0_0(DataOutput out, SerializationContext context)
         durableId == null ? 300 : memberData.getDurableTimeout(),
         out);
 
-    short version = memberData.getVersionOrdinal();
+    final short version;
+    if (context.getSerializationVersion().isNewerThan(KnownVersion.GFE_90)) {
+      version = memberData.getVersionOrdinal();
+    } else {
+      // This version of geode-native could not parse the longer version ordinals.
+      // Let's make these older clients think the server is still 1.14.
+      version = KnownVersion.GEODE_1_14_0.ordinal();

Review comment:
       This probably should use the actual member version, or 1.14.0, whichever is older. As it is, this is going to make some ids (maybe from a client, or a peer, or a WAN site) look NEWER than they actually are.




-- 
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-unsubscribe@geode.apache.org

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