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

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

PivotalSarge commented on a change in pull request #1137: GEODE-4059: Changing 
protobuf handshake to not need communication mod…
URL: https://github.com/apache/geode/pull/1137#discussion_r155577390
 
 

 ##########
 File path: 
geode-core/src/main/java/org/apache/geode/internal/cache/tier/CommunicationMode.java
 ##########
 @@ -22,6 +22,19 @@
  * query methods must be updated.
  */
 public enum CommunicationMode {
+  /**
+   * The first byte of any locator connection will be the high order byte of 
its gossip version,
+   * which will always be 0. Communication modes should not collide with this 
value.
+   */
+  ReservedForGossip((byte) 0, "Locator gossip version"),
+  /**
+   * For the new client-server protocol.
+   *
+   * Protobuf handshake messages are specially constructed so that this value 
will match the first
+   * byte sent, allowing clients to start protobuf connections with a 
handshake instead of
+   * communication mode bytes.
+   */
+  ProtobufClientServerProtocol((byte) 10, "Protobuf client"),
 
 Review comment:
   Will this require coordination with the C# and Go drivers?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


> Stop using magic bytes in protobuf connection establishment
> -----------------------------------------------------------
>
>                 Key: GEODE-4059
>                 URL: https://issues.apache.org/jira/browse/GEODE-4059
>             Project: Geode
>          Issue Type: New Feature
>          Components: client/server
>            Reporter: Brian Rowe
>
> When connection to the server, the client currently uses some magic bytes to 
> identify the protocol being used.  This is non-intuitive and problematic for 
> client developers, and should not be necessary if we make clever use of a 
> magic protobuf connection establishing message.  This should also serve as 
> our handshake.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to