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

ASF GitHub Bot commented on TINKERPOP-1600:
-------------------------------------------

Github user spmallette commented on the issue:

    https://github.com/apache/tinkerpop/pull/533
  
    The driver shouldn't crash by sending a byte array in the results, because 
it is only the SASL authentication process that was expecting `byte[]`. When it 
would find a `String` that's when we'd get the failure as it tried to cast a 
`byte[]` from that.  A `byte[]` as a normal result from a script evaluation 
should not have any problems. Please let me know if I'm missing something.
    
    `serializeResultToString` is used by the Gremlin Console. It presents a 
cheap way for the console to interact with the server by making the console 
more of a dummy terminal that just prints the results from the server without 
having to get a giant body of fully serialized results back. It also allows for 
you to work with classes that aren't necessarily serializable as they will 
simply be toString'd on the way back to the console.


> Consistent use of base 64 encoded bytes for SASL negotiation
> ------------------------------------------------------------
>
>                 Key: TINKERPOP-1600
>                 URL: https://issues.apache.org/jira/browse/TINKERPOP-1600
>             Project: TinkerPop
>          Issue Type: Improvement
>          Components: driver, server
>    Affects Versions: 3.2.3
>            Reporter: stephen mallette
>            Assignee: stephen mallette
>             Fix For: 3.2.4
>
>
> Gremlin Server currently uses a mix of base 64 encoded bytes and byte arrays 
> for SASL negotiation. This can cause problems for certain serializers (like 
> toString serialization with gryo) as the byte array won't be respected. In an 
> effort to easily support virtually any serializer a switch to using just base 
> 64 string is probably best. 
> This can be done in such a way as to be backward compatible. The base64 SASL 
> value will be returned in the response message status attributes map in a key 
> called "sasl". The original byte array will continue to be returned in the 
> response message result. Eventually, we could phase out the byte array in the 
> result - perhaps with 3.3.0.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to