@@ -37,7 +37,6 @@ import (
37
37
"github.com/pkg/errors"
38
38
ostats "go.opencensus.io/stats"
39
39
"go.opencensus.io/tag"
40
- "go.opencensus.io/trace"
41
40
otrace "go.opencensus.io/trace"
42
41
"google.golang.org/grpc"
43
42
"google.golang.org/grpc/codes"
@@ -255,8 +254,9 @@ func validateAlterOperation(ctx context.Context, op *api.Operation) error {
255
254
256
255
// parseSchemaFromAlterOperation parses the string schema given in input operation to a Go
257
256
// struct, and performs some checks to make sure that the schema is valid.
258
- func parseSchemaFromAlterOperation (ctx context.Context , op * api.Operation ) (* schema.ParsedSchema ,
259
- error ) {
257
+ func parseSchemaFromAlterOperation (ctx context.Context , op * api.Operation ) (
258
+ * schema.ParsedSchema , error ) {
259
+
260
260
// If a background task is already running, we should reject all the new alter requests.
261
261
if schema .State ().IndexingInProgress () {
262
262
return nil , errIndexingInProgress
@@ -980,7 +980,7 @@ type queryContext struct {
980
980
// l stores latency numbers
981
981
latency * query.Latency
982
982
// span stores a opencensus span used throughout the query processing
983
- span * trace .Span
983
+ span * otrace .Span
984
984
// graphql indicates whether the given request is from graphql admin or not.
985
985
graphql bool
986
986
// gqlField stores the GraphQL field for which the query is being processed.
@@ -1228,7 +1228,7 @@ func (s *Server) doQuery(ctx context.Context, req *Request) (resp *api.Response,
1228
1228
return nil , errors .Errorf ("empty request" )
1229
1229
}
1230
1230
1231
- span .AddAttributes (trace .StringAttribute ("Query" , req .req .Query ))
1231
+ span .AddAttributes (otrace .StringAttribute ("Query" , req .req .Query ))
1232
1232
span .Annotatef (nil , "Request received: %v" , req .req )
1233
1233
if isQuery {
1234
1234
ostats .Record (ctx , x .PendingQueries .M (1 ), x .NumQueries .M (1 ))
0 commit comments