[ https://issues.apache.org/jira/browse/TINKERPOP-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16459927#comment-16459927 ]
Kai Walter edited comment on TINKERPOP-1952 at 5/1/18 5:52 PM: --------------------------------------------------------------- corrected endpoint to CosmosDB Gremlin This error {color:#FF0000}WebSocketException: The server returned status code '200' when status code '101' was expected.{color} results from using the DocmentDB and not the Gremlin endpoint was (Author: kaiwalter): corrected endpoint to CosmosDB Gremlin > using Gremlin.Net in .NET Framework 4.61 sample console app GremlinSampleNet > results in exception > ------------------------------------------------------------------------------------------------- > > Key: TINKERPOP-1952 > URL: https://issues.apache.org/jira/browse/TINKERPOP-1952 > Project: TinkerPop > Issue Type: Bug > Components: dotnet > Affects Versions: 3.3.2 > Environment: Windows Server 2016 1607 > Reporter: Kai Walter > Priority: Major > > I wanted to use Gremlin.Net in Azure Functions and stumbled over [this > problem|https://stackoverflow.com/questions/49923888/could-not-load-file-or-assembly-system-reflection-typeextensions-version-4-0-0]. > When downloading and running the sample > > [https://github.com/Azure-Samples/azure-cosmos-db-graph-gremlindotnet-getting-started] > on my machine I run into this error in {{program.cs}} line 64: > System.AggregateException > HResult=0x80131500 > Message=One or more errors occurred. > Source=mscorlib > StackTrace: > at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean > includeTaskCanceledExceptions) > at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, > CancellationToken cancellationToken) > at System.Threading.Tasks.Task.Wait() > at GremlinNetSample.Program.Main(String[] args) in > C:\Users\Y1WLE\src\Microsoft\azure-cosmos-db-graph-gremlindotnet-getting-started\GremlinNetSample\Program.cs:line > 65 > {color:#ff0000}Inner Exception 1: > NullReferenceException: Object reference not set to an instance of an > object.{color}{color:#ff0000} {color} > When cloning Gremlin.Net and referencing it in the sample app, I can narrow > it down to {{Connection.cs}} line 89, where {{received}} gets returned null. > My settings: > private static string hostname = > "{mycosmosdbaccount}.gremlin.cosmosdb.azure.com"; > private static int port = 443; > private static string authKey = "{mycosmosdbprimarykey}"; > private static string database = "graph1"; > private static string collection = "customer360"; > I also tried with a adding a basic statement in {{program.cs}} line 29: > { "Simple", "1=1" }, > { "Cleanup", "g.V().drop()" }, > > -- This message was sent by Atlassian JIRA (v7.6.3#76005)