You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by GitBox <gi...@apache.org> on 2020/02/19 08:29:28 UTC

[GitHub] [tinkerpop] dzmitry-lahoda opened a new pull request #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

dzmitry-lahoda opened a new pull request #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250
 
 
   fix null reference for https://issues.apache.org/jira/browse/TINKERPOP-2192

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] FlorianHockmann commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
FlorianHockmann commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-594631143
 
 
   I agree with the points you made, @spmallette. I simply forgot to check those during the review.
   
   > This change targets master - should it target an earlier branch? I'd guess it should at least target 3.4-dev but perhaps it should even go back to 3.3-dev?
   
   Yes, you're right. It should target `3.4-dev` in my opinion. `3.3-dev` would also be possible, but would require a different PR as this part of the driver has changed a lot between 3.3 and 3.4. Since the download numbers for 3.3 releases are very low for Gremlin.Net (only 67 downloads for 3.3.10 and 107 for 3.3.9 right now), I don't think it's worth the effort to backport a small fix like this to `3.3-dev`.
   @dzmitry-lahoda We'll merge the change into `3.4-dev` and then merge that branch into `master` if you change the target branch here to `3.4-dev`. That way, the change will land in the next 3.4 release (probably 3.4.7) and also in 3.5.0, whenever that will be released.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] dzmitry-lahoda edited a comment on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
dzmitry-lahoda edited a comment on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-589379332
 
 
   @FlorianHockmann reproduced NullReference (with my fix it is InvalidOperation) for message under:
   
   ![image](https://user-images.githubusercontent.com/757125/74984996-ae2fc980-5447-11ea-918d-5e296360ca96.png)
   
   I use my stability branch stress tool again Azure Cosmos DB. I will ask if have time to run Gremlin Server. Or may be capture whole traffic via Wireshark. Or run property based test on deserialization to detect when we have null (and see upper stack how we get such a byte array).

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] dzmitry-lahoda edited a comment on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
dzmitry-lahoda edited a comment on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-589374674
 
 
   ```
   Gremlin Information: 0 : Start call 26421
   Gremlin Information: 0 : Got result for call 26264
   Gremlin Information: 0 : Not handled error Gremlin.Net.Driver.Exceptions.ServerUnavailableException: No connection to the server available which most likely means that the server is completely unavailable.
      at Gremlin.Net.Driver.ConnectionPool.GetConnectionFromPool() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\ConnectionPool.cs:line 115
      at Gremlin.Net.Driver.ConnectionPool.GetAvailableConnectionAsync() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\ConnectionPool.cs:line 59
      at Gremlin.Net.Driver.GremlinClient.SubmitAsync[T](RequestMessage requestMessage) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClient.cs:line 83
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
   Gremlin Information: 0 : Start call 26422
   Gremlin Information: 0 : Error(from aggregate) 26421 Gremlin.Net.Driver.Exceptions.ServerUnavailableException: No connection to the server available which most likely means that the server is completely unavailable.
      at <StartupCode$Gremlin-Net-FSharp>.$Library.Gremlin-Net-Driver-IGremlinClient-SubmitAsync@90-2.Invoke(Exception _arg2) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net.FSharp\Library.fs:line 106
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
      at FSharp.Control.Tasks.TaskBuilder.StepStateMachine`1.nextAwaitable()
   --- End of stack trace from previous location where exception was thrown ---
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync[T](IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 137
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync(IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 98
   Gremlin Information: 0 : Not handled error Gremlin.Net.Driver.Exceptions.ServerUnavailableException: No connection to the server available which most likely means that the server is completely unavailable.
      at Gremlin.Net.Driver.ConnectionPool.GetConnectionFromPool() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\ConnectionPool.cs:line 115
      at Gremlin.Net.Driver.ConnectionPool.GetAvailableConnectionAsync() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\ConnectionPool.cs:line 59
      at Gremlin.Net.Driver.GremlinClient.SubmitAsync[T](RequestMessage requestMessage) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClient.cs:line 83
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
   Gremlin Information: 0 : Error(from aggregate) 26416 Gremlin.Net.Driver.Exceptions.ServerUnavailableException: No connection to the server available which most likely means that the server is completely unavailable.
      at <StartupCode$Gremlin-Net-FSharp>.$Library.Gremlin-Net-Driver-IGremlinClient-SubmitAsync@90-2.Invoke(Exception _arg2) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net.FSharp\Library.fs:line 106
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
      at FSharp.Control.Tasks.TaskBuilder.StepStateMachine`1.nextAwaitable()
   --- End of stack trace from previous location where exception was thrown ---
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync[T](IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 137
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync(IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 98
   Gremlin Information: 0 : Not handled error System.InvalidOperationException: Recevied data deserialized into null object message. Cannot operated on it.
      at Gremlin.Net.Driver.Connection.ThrowMessageDeserializedNull() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\Connection.cs:line 140
      at Gremlin.Net.Driver.Connection.Parse(Byte[] received) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\Connection.cs:line 122
      at Gremlin.Net.Driver.Connection.ReceiveMessagesAsync() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\Connection.cs:line 107
      at Gremlin.Net.Driver.ProxyConnection.SubmitAsync[T](RequestMessage requestMessage) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\ProxyConnection.cs:line 44
      at Gremlin.Net.Driver.GremlinClient.SubmitAsync[T](RequestMessage requestMessage) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClient.cs:line 85
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
   Gremlin Information: 0 : Got result for call 26288
   Run 26424                               
   Gremlin Information: 0 : Start call 26424
   Gremlin Information: 0 : Error(from aggregate) 26418 Gremlin.Net.Driver.Exceptions.ServerUnavailableException: No connection to the server available which most likely means that the server is completely unavailable.
      at <StartupCode$Gremlin-Net-FSharp>.$Library.Gremlin-Net-Driver-IGremlinClient-SubmitAsync@90-2.Invoke(Exception _arg2) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net.FSharp\Library.fs:line 106
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
      at FSharp.Control.Tasks.TaskBuilder.StepStateMachine`1.nextAwaitable()
   --- End of stack trace from previous location where exception was thrown ---
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync[T](IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 137
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync(IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 98
   Gremlin Information: 0 : Got result for call 26313
   Gremlin Information: 0 : Error(from aggregate) 26420 Gremlin.Net.Driver.Exceptions.ServerUnavailableException: No connection to the server available which most likely means that the server is completely unavailable.
      at <StartupCode$Gremlin-Net-FSharp>.$Library.Gremlin-Net-Driver-IGremlinClient-SubmitAsync@90-2.Invoke(Exception _arg2) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net.FSharp\Library.fs:line 106
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
      at FSharp.Control.Tasks.TaskBuilder.StepStateMachine`1.nextAwaitable()
   --- End of stack trace from previous location where exception was thrown ---
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync[T](IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 137
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync(IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 98
   Gremlin Information: 0 : Got result for call 26327
   Run 26425                               
   Gremlin Information: 0 : Start call 26425
   Gremlin Information: 0 : Got result for call 26325
   ```

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] FlorianHockmann commented on a change in pull request #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
FlorianHockmann commented on a change in pull request #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#discussion_r386451673
 
 

 ##########
 File path: gremlin-dotnet/test/Gremlin.Net.UnitTest/Driver/JsonMessageSerializerTests.cs
 ##########
 @@ -0,0 +1,66 @@
+#region License
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+#endregion
+
+using Gremlin.Net.Driver;
+using Gremlin.Net.Driver.Messages;
+using Newtonsoft.Json;
+using Newtonsoft.Json.Linq;
+using System;
+using System.Text;
+using Xunit;
+
+namespace Gremlin.Net.UnitTest.Driver
+{
+    // Will be used in future to switch to new .NET Core Json deserializer
+    public class JsonMessageSerializerTests
 
 Review comment:
   I'm not sure about the value these tests add as they are basically just asserting how a JSON deserializer should treat edge cases, but OK, they could become useful when we try out the new .NET JSON serializer, so I'm also not against adding them.
   Could you however please refactor the tests a bit if you want to add them to Gremlin.Net? Each test should only test a single case, should have a clear name that reflects what the expected behaviour is and it should ideally be split into the three phases _arrange_, _act_, and _assert_, separated by newlines (see for example [here](http://wiki.c2.com/?ArrangeActAssert) for a reference).
   The [GremlinServerTests](https://github.com/apache/tinkerpop/blob/master/gremlin-dotnet/test/Gremlin.Net.UnitTest/Driver/GremlinServerTests.cs#L29) also show this nicely.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-590323561
 
 
   will do updates with in couple of hours

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] spmallette commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
spmallette commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-595321989
 
 
   thanks @dzmitry-lahoda 
   
   VOTE +1 - assuming changelog entry on merge.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] FlorianHockmann commented on a change in pull request #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
FlorianHockmann commented on a change in pull request #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#discussion_r386452437
 
 

 ##########
 File path: gremlin-dotnet/src/Gremlin.Net/Driver/Connection.cs
 ##########
 @@ -126,11 +130,14 @@ private void Parse(byte[] received)
             {
                 if (_callbackByRequestId.TryRemove(receivedMsg.RequestId, out var responseHandler))
                 {
-                    responseHandler.HandleFailure(e);
+                    responseHandler?.HandleFailure(e);
                 }
             }
         }
 
+        private static void ThrowMessageDeserializedNull() =>
+            throw new InvalidOperationException("Received data deserialized into null object message. Cannot operated on it.");
 
 Review comment:
   Just a small grammatical nitpick, but it should be _operate on it_ (without a "d") afaik.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] dzmitry-lahoda edited a comment on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
dzmitry-lahoda edited a comment on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-590035073
 
 
   Seems in there is need for multi region connectivity. As for now, connection is fire and forget to client, while  could be made part of explicit API if I want, based on some metrics, to reconnect and await that to happen (in flight calls would await). With proper error types which are more indicative than others to region switch. Work cannot be done without modification of gremlin client and patches accepted.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-589379332
 
 
   @FlorianHockmann reproduced NullReference (with my fix it is InvalidOperation) for message under:
   
   ![image](https://user-images.githubusercontent.com/757125/74984996-ae2fc980-5447-11ea-918d-5e296360ca96.png)
   
   I use my stability branch stress tool again Azure Cosmos DB. I will ask if have time to run Gremlin Server. Or may be capture whole traffic via Wireshark.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-589377046
 
 
   ```
   Run 30210                               
   Gremlin Information: 0 : Not handled error Gremlin.Net.Driver.Exceptions.ServerUnavailableException: No connection to the server available which most likely means that the server is completely unavailable.
      at Gremlin.Net.Driver.ConnectionPool.GetConnectionFromPool() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\ConnectionPool.cs:line 115
      at Gremlin.Net.Driver.ConnectionPool.GetAvailableConnectionAsync() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\ConnectionPool.cs:line 59
      at Gremlin.Net.Driver.GremlinClient.SubmitAsync[T](RequestMessage requestMessage) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClient.cs:line 83
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
   Gremlin Information: 0 : Start call 30207
   Gremlin Information: 0 : Not handled error Gremlin.Net.Driver.Exceptions.ServerUnavailableException: No connection to the server available which most likely means that the server is completely unavailable.
      at Gremlin.Net.Driver.ConnectionPool.GetConnectionFromPool() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\ConnectionPool.cs:line 115
      at Gremlin.Net.Driver.ConnectionPool.GetAvailableConnectionAsync() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\ConnectionPool.cs:line 59
      at Gremlin.Net.Driver.GremlinClient.SubmitAsync[T](RequestMessage requestMessage) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClient.cs:line 83
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
   Gremlin Information: 0 : Error(from aggregate) 30202 Gremlin.Net.Driver.Exceptions.ServerUnavailableException: No connection to the server available which most likely means that the server is completely unavailable.
      at <StartupCode$Gremlin-Net-FSharp>.$Library.Gremlin-Net-Driver-IGremlinClient-SubmitAsync@90-2.Invoke(Exception _arg2) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net.FSharp\Library.fs:line 106
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
      at FSharp.Control.Tasks.TaskBuilder.StepStateMachine`1.nextAwaitable()
   --- End of stack trace from previous location where exception was thrown ---
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync[T](IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 137
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync(IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 98
   Gremlin Information: 0 : Not handled error System.InvalidOperationException: Recevied data deserialized into null object message. Cannot operated on it.
      at Gremlin.Net.Driver.Connection.ThrowMessageDeserializedNull() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\Connection.cs:line 140
      at Gremlin.Net.Driver.Connection.Parse(Byte[] received) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\Connection.cs:line 122
      at Gremlin.Net.Driver.Connection.ReceiveMessagesAsync() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\Connection.cs:line 107
      at Gremlin.Net.Driver.ProxyConnection.SubmitAsync[T](RequestMessage requestMessage) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\ProxyConnection.cs:line 44
      at Gremlin.Net.Driver.GremlinClient.SubmitAsync[T](RequestMessage requestMessage) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClient.cs:line 85
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
   Gremlin Information: 0 : Error(from aggregate) 30197 Gremlin.Net.Driver.Exceptions.ServerUnavailableException: No connection to the server available which most likely means that the server is completely unavailable.
      at <StartupCode$Gremlin-Net-FSharp>.$Library.Gremlin-Net-Driver-IGremlinClient-SubmitAsync@90-2.Invoke(Exception _arg2) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net.FSharp\Library.fs:line 106
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
      at FSharp.Control.Tasks.TaskBuilder.StepStateMachine`1.nextAwaitable()
   --- End of stack trace from previous location where exception was thrown ---
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync[T](IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 137
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync(IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 98
   Run 30211                               
   Gremlin Information: 0 : Error(from aggregate) 30204 Gremlin.Net.Driver.Exceptions.ServerUnavailableException: No connection to the server available which most likely means that the server is completely unavailable.
      at <StartupCode$Gremlin-Net-FSharp>.$Library.Gremlin-Net-Driver-IGremlinClient-SubmitAsync@90-2.Invoke(Exception _arg2) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net.FSharp\Library.fs:line 106
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
      at FSharp.Control.Tasks.TaskBuilder.StepStateMachine`1.nextAwaitable()
   --- End of stack trace from previous location where exception was thrown ---
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync[T](IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 137
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync(IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 98
   Run 30212                               
   Gremlin Information: 0 : Error(from aggregate) 30193 Gremlin.Net.Driver.Exceptions.ServerUnavailableException: No connection to the server available which most likely means that the server is completely unavailable.
      at <StartupCode$Gremlin-Net-FSharp>.$Library.Gremlin-Net-Driver-IGremlinClient-SubmitAsync@90-2.Invoke(Exception _arg2) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net.FSharp\Library.fs:line 106
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
      at FSharp.Control.Tasks.TaskBuilder.StepStateMachine`1.nextAwaitable()
   --- End of stack trace from previous location where exception was thrown ---
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync[T](IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 137
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync(IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 98
   Run 30213                               
   ```

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-588651209
 
 
   Previously if message was null:
   
   1. First line in try fails.
   2. Catch fail on first line with null.
   3. No handling at all.
   
   Current:
   1. First line fails  with reasonable error.
   
   Result:
   Exactly same exception handling behavior, but more clean message we can work with.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] FlorianHockmann commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
FlorianHockmann commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-588100950
 
 
   Thanks for your first contribution to TinkerPop, @dzmitry-lahoda, but we already have an open PR for this issue: #1247 which additionally adds another null check for the `receivedMsg` in that method.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] spmallette commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
spmallette commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-594573696
 
 
   Since I see an initial vote on this one, I'll just add a few administrative points in relation to the review:
   
   1. a CHANGELOG entry would be nice though whoever merges this could simply add that in
   2. This change targets `master` - should it target an earlier branch? I'd guess it should at least target `3.4-dev` but perhaps it should even go back to `3.3-dev`? Thoughts @FlorianHockmann ?
   3. Not sure why travis didn't like the last build - I've restarted the .NET body of tests.
   4. Finally, @dzmitry-lahoda would you mind cleaning up the commit history a bit. It seems like this is a simple enough change that all of your commits on this PR could be squashed into one now that the review/feedback work is all done.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-589374674
 
 
   ```
   Gremlin Information: 0 : Error(from aggregate) 26416 Gremlin.Net.Driver.Exceptions.ServerUnavailableException: No connection to the server available which most likely means that the server is completely unavailable.
      at <StartupCode$Gremlin-Net-FSharp>.$Library.Gremlin-Net-Driver-IGremlinClient-SubmitAsync@90-2.Invoke(Exception _arg2) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net.FSharp\Library.fs:line 106
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
      at FSharp.Control.Tasks.TaskBuilder.StepStateMachine`1.nextAwaitable()
   --- End of stack trace from previous location where exception was thrown ---
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync[T](IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 137
      at Gremlin.Net.Driver.GremlinClientExtensions.SubmitAsync(IGremlinClient gremlinClient, String requestScript, Dictionary`2 bindings) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClientExtensions.cs:line 98
   Gremlin Information: 0 : Not handled error System.InvalidOperationException: Recevied data deserialized into null object message. Cannot operated on it.
      at Gremlin.Net.Driver.Connection.ThrowMessageDeserializedNull() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\Connection.cs:line 140
      at Gremlin.Net.Driver.Connection.Parse(Byte[] received) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\Connection.cs:line 122
      at Gremlin.Net.Driver.Connection.ReceiveMessagesAsync() in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\Connection.cs:line 107
      at Gremlin.Net.Driver.ProxyConnection.SubmitAsync[T](RequestMessage requestMessage) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\ProxyConnection.cs:line 44
      at Gremlin.Net.Driver.GremlinClient.SubmitAsync[T](RequestMessage requestMessage) in E:\src\tinkerpop\gremlin-dotnet\src\Gremlin.Net\Driver\GremlinClient.cs:line 85
      at FSharp.Control.Tasks.TaskBuilder.tryWith@169.Invoke(Unit unitVar0)
   Gremlin Information: 0 : Got result for call 26288
   Run 26424                               
   Gremlin Information: 0 : Start call 26424
   ```

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] FlorianHockmann commented on a change in pull request #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
FlorianHockmann commented on a change in pull request #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#discussion_r383262777
 
 

 ##########
 File path: gremlin-dotnet/src/Gremlin.Net/Driver/ConnectionPool.cs
 ##########
 @@ -131,7 +131,15 @@ private Connection TryGetAvailableConnection(Connection[] connections)
                 }
                 return connection;
             }
-            throw new ConnectionPoolBusyException(_poolSize, _maxInProcessPerConnection);
+
+            if (connections.Length > 0) 
 
 Review comment:
   This improvement definitely also makes sense, but it is not really related to TINKERPOP-2192. So, could you please create a different PR and ideally an issue in JIRA for this?

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-588105793
 
 
   Please merge my absolutely safe PR:) I mean another null check in PR you referenced may be more than really needed and hide errors.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-590035073
 
 
   seems in there is need of multi region connectivity. as for no connection is fire and forget to client, while  could be made part of explicit api if I want, based on some metrics, to reconnect and await that to happen (in flight calls would await). with proper error types which are more indicative than others to region swich. i.e. work cannot be done without modification of gremlin client.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] FlorianHockmann merged pull request #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
FlorianHockmann merged pull request #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250
 
 
   

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [tinkerpop] dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192

Posted by GitBox <gi...@apache.org>.
dzmitry-lahoda commented on issue #1250: fix for https://issues.apache.org/jira/browse/TINKERPOP-2192
URL: https://github.com/apache/tinkerpop/pull/1250#issuecomment-589872512
 
 
   ```
   #region License
   
   /*
    * Licensed to the Apache Software Foundation (ASF) under one
    * or more contributor license agreements.  See the NOTICE file
    * distributed with this work for additional information
    * regarding copyright ownership.  The ASF licenses this file
    * to you under the Apache License, Version 2.0 (the
    * "License"); you may not use this file except in compliance
    * with the License.  You may obtain a copy of the License at
    *
    *     http://www.apache.org/licenses/LICENSE-2.0
    *
    * Unless required by applicable law or agreed to in writing,
    * software distributed under the License is distributed on an
    * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
    * KIND, either express or implied.  See the License for the
    * specific language governing permissions and limitations
    * under the License.
    */
   
   #endregion
   
   using Gremlin.Net.Driver;
   using Gremlin.Net.Driver.Messages;
   using Newtonsoft.Json;
   using Newtonsoft.Json.Linq;
   using System;
   using System.Text;
   using Xunit;
   
   namespace Gremlin.Net.UnitTest.Driver
   {
       // Will be used in future to switch to new .NET Core Json deserializer
       public class JsonMessageSerializerTests
       {
           [Fact]
           public void NullError()
           {
               var sut = new JsonMessageSerializer(GremlinClient.DefaultMimeType);
               Assert.Throws<ArgumentNullException>(()=> sut.DeserializeMessage<ResponseMessage<JToken>>(null));
           }
   
           [Fact]
           public void EmptyToNull()
           {
               var sut = new JsonMessageSerializer(GremlinClient.DefaultMimeType);
               Assert.Null(sut.DeserializeMessage<ResponseMessage<JToken>>(new byte[0]));
               var ofEmpty = Encoding.UTF8.GetBytes("");
               Assert.Null(sut.DeserializeMessage<ResponseMessage<JToken>>(ofEmpty));
               var ofNull = Encoding.UTF8.GetBytes("null");
               Assert.Null(sut.DeserializeMessage<ResponseMessage<JToken>>(ofNull));
           }
   
           [Fact]
           public void Any()
           {
               var sut = new JsonMessageSerializer(GremlinClient.DefaultMimeType);
               var obj = Encoding.UTF8.GetBytes("{}");
               Assert.NotNull(sut.DeserializeMessage<ResponseMessage<JToken>>(obj));
               var arr = Encoding.UTF8.GetBytes("[]");
   
               Assert.Throws<JsonSerializationException>(()=> sut.DeserializeMessage<ResponseMessage<JToken>>(arr));
           }
       }
   }
   ```
   
   Seem happend when data lost over network.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services