Skip to content

[TINKERPOP-2841] Fix Per-Request Settings in Go GLV 3.5#1968

Merged
xiazcy merged 1 commit intoapache:3.5-devfrom
Bit-Quill:cole/go-request-options-3.5
Feb 22, 2023
Merged

[TINKERPOP-2841] Fix Per-Request Settings in Go GLV 3.5#1968
xiazcy merged 1 commit intoapache:3.5-devfrom
Bit-Quill:cole/go-request-options-3.5

Conversation

@Cole-Greer
Copy link
Contributor

https://issues.apache.org/jira/browse/TINKERPOP-2841

This PR is cherry picking the changes introduced in #1939 back to 3.5.x with the socket server based tests removed for compatibility. There are no changes to the existing external interface (other than adding a new SubmitWithOptions() method). This is not a breaking change for any users.

@vkagamlyk
Copy link
Contributor

VOTE +1

@codecov-commenter
Copy link

codecov-commenter commented Feb 9, 2023

Codecov Report

Merging #1968 (5e269ac) into 3.5-dev (cd70be2) will increase coverage by 0.10%.
The diff coverage is 93.44%.

@@              Coverage Diff              @@
##             3.5-dev    #1968      +/-   ##
=============================================
+ Coverage      69.26%   69.36%   +0.10%     
- Complexity      8940     8952      +12     
=============================================
  Files            865      866       +1     
  Lines          41095    41145      +50     
  Branches        5418     5418              
=============================================
+ Hits           28466    28542      +76     
+ Misses         10712    10689      -23     
+ Partials        1917     1914       -3     
Impacted Files Coverage Δ
gremlin-go/driver/driverRemoteConnection.go 85.10% <0.00%> (-1.23%) ⬇️
gremlin-go/driver/client.go 80.80% <100.00%> (+1.23%) ⬆️
gremlin-go/driver/request.go 80.83% <100.00%> (+1.93%) ⬆️
gremlin-go/driver/requestOptions.go 100.00% <100.00%> (ø)
...emlin/process/computer/util/VertexProgramPool.java 42.85% <0.00%> (-9.53%) ⬇️
...in/process/traversal/dsl/graph/GraphTraversal.java 90.27% <0.00%> (-0.55%) ⬇️
...nkerpop/gremlin/groovy/engine/GremlinExecutor.java 87.71% <0.00%> (+0.42%) ⬆️
...pache/tinkerpop/gremlin/driver/ConnectionPool.java 29.28% <0.00%> (+0.62%) ⬆️
...apache/tinkerpop/gremlin/server/GremlinServer.java 57.07% <0.00%> (+0.97%) ⬆️
... and 6 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Go was previously not sending per-request options correctly to the server.
Go was passing request options inside the gremlin script bindings map instead of
within the args portion of the request message.

This commit resolves this issue by encapsulating all per-request settings as well as
script bindings into a new RequestOptions struct which has an accompanying RequestOptionsBuilder.

This can now be passed in through new Client.SubmitWithOptions() and DriverRemoteConnection.SubmitWithOptions() methods.
Both original Submit() methods are unchanged in their behavior so this will not break any users.
@Cole-Greer Cole-Greer force-pushed the cole/go-request-options-3.5 branch from 5e269ac to f6879ba Compare February 10, 2023 19:27
@xiazcy xiazcy merged commit a5142ee into apache:3.5-dev Feb 22, 2023
@Cole-Greer Cole-Greer deleted the cole/go-request-options-3.5 branch May 19, 2023 16:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants