我在access-graph-gremlin-dotnet 上关注 Amazon 的文档,
并尝试在本地 Windows 机器上运行它,该机器通过 EC2 实例通过 SSH 隧道连接到 Neptune。
我已经使用 gremlin 控制台测试了 SSH 隧道,它工作正常。
在 EC2 实例上运行该程序也可以,但是在本地 Windows 机器上运行该程序时,我收到以下异常,因为需要将 Neptune 的证书添加到受信任的证书中:
System.Net.WebSockets.WebSocketException (0x80004005): Unable to connect to the remote server --->
System.Net.Http.HttpRequestException: The SSL connection could not be established, see inner
exception. ---> System.Security.Authentication.AuthenticationException: The remote certificate is
invalid according to the validation procedure.
Run Code Online (Sandbox Code Playgroud)
我正在寻找如何在 Gremlin.Net 3.4.6(首选 C#)中执行此操作。
我有一个创建顶点和边“创建”的查询。边缘有一个属性“on”,它是 unix datetime 长。当我在 Azure Cosmos DB 终端中使用以下段执行查询时,它按预期工作 - 返回一个带有“On”属性的对象,该属性是一个数字。
.project('Id', 'CreatedOn')
.by('id')
.by(
select('createdEdge')
.by('on')
)
Run Code Online (Sandbox Code Playgroud)
当我使用 Gremlin.NET 从我的应用程序代码执行此查询时,它失败并显示错误:
不支持 JSON 类型。
我在源代码中看到Gremlin.NET 的反序列化逻辑似乎不处理任何数字类型。真的是这样吗?有没有办法使用 long、float、int 属性类型?