From 72d8ad8b32fc8e167eb4595c5e2dbf9ff97236e3 Mon Sep 17 00:00:00 2001 From: schwartzmx Date: Thu, 27 Jun 2019 20:28:37 -0500 Subject: [PATCH] update uuid library, fix test file naming --- go.mod | 4 +--- go.sum | 11 ++--------- ...eptune_test_util.go => gremgo_neptune_util_test.go | 0 request.go | 6 +++--- 4 files changed, 6 insertions(+), 15 deletions(-) rename gremgo_neptune_test_util.go => gremgo_neptune_util_test.go (100%) diff --git a/go.mod b/go.mod index a9a3ea2..6b5630c 100644 --- a/go.mod +++ b/go.mod @@ -1,9 +1,7 @@ module gremgo require ( + github.com/gofrs/uuid v3.2.0+incompatible github.com/gorilla/websocket v1.2.0 - github.com/kr/pretty v0.1.0 // indirect github.com/pkg/errors v0.8.1 - github.com/satori/go.uuid v1.2.0 - gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127 // indirect ) diff --git a/go.sum b/go.sum index 5368830..b0b3a27 100644 --- a/go.sum +++ b/go.sum @@ -1,13 +1,6 @@ +github.com/gofrs/uuid v3.2.0+incompatible h1:y12jRkkFxsd7GpqdSZ+/KCs/fJbqpEXSGd4+jfEaewE= +github.com/gofrs/uuid v3.2.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/gorilla/websocket v1.2.0 h1:VJtLvh6VQym50czpZzx07z/kw9EgAxI3x1ZB8taTMQQ= github.com/gorilla/websocket v1.2.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= -github.com/kr/pretty v0.1.0 h1:L/CwN0zerZDmRFUapSPitk6f+Q3+0za1rQkzVuMiMFI= -github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= -github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= -github.com/kr/text v0.1.0 h1:45sCR5RtlFHMR4UwH9sdQ5TC8v0qDQCHnXt+kaKSTVE= -github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/pkg/errors v0.8.1 h1:iURUrRGxPUNPdy5/HRSm+Yj6okJ6UtLINN0Q9M4+h3I= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/satori/go.uuid v1.2.0 h1:0uYX9dsZ2yD7q2RtLRtPSdGDWzjeM3TbMJP9utgA0ww= -github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= -gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127 h1:qIbj1fsPNlZgppZ+VLlY7N33q108Sa+fhmuc+sWQYwY= -gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= diff --git a/gremgo_neptune_test_util.go b/gremgo_neptune_util_test.go similarity index 100% rename from gremgo_neptune_test_util.go rename to gremgo_neptune_util_test.go diff --git a/request.go b/request.go index de4cd86..12e35cc 100644 --- a/request.go +++ b/request.go @@ -4,7 +4,7 @@ import ( "encoding/base64" "encoding/json" - uuid "github.com/satori/go.uuid" + "github.com/gofrs/uuid" ) type requester interface { @@ -24,7 +24,7 @@ type request struct { // prepareRequest packages a query and binding into the format that Gremlin Server accepts func prepareRequest(query string) (req request, id string, err error) { var uuID uuid.UUID - uuID = uuid.NewV4() + uuID, _ = uuid.NewV4() id = uuID.String() req.RequestID = id @@ -41,7 +41,7 @@ func prepareRequest(query string) (req request, id string, err error) { // prepareRequest packages a query and binding into the format that Gremlin Server accepts func prepareRequestWithBindings(query string, bindings, rebindings map[string]string) (req request, id string, err error) { var uuID uuid.UUID - uuID = uuid.NewV4() + uuID, _ = uuid.NewV4() id = uuID.String() req.RequestID = id