Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
58432: tracing: remove tracing.AnnotateTrace r=tbg a=irfansharif

This code seems to have died years ago.

Release note: None

Co-authored-by: irfan sharif <irfanmahmoudsharif@gmail.com>
  • Loading branch information
craig[bot] and irfansharif committed Jan 5, 2021
2 parents d887df7 + 838fa0c commit f868736
Show file tree
Hide file tree
Showing 13 changed files with 0 additions and 73 deletions.
2 changes: 0 additions & 2 deletions pkg/kv/db.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import (
"github.com/cockroachdb/cockroach/pkg/util/protoutil"
"github.com/cockroachdb/cockroach/pkg/util/retry"
"github.com/cockroachdb/cockroach/pkg/util/stop"
"github.com/cockroachdb/cockroach/pkg/util/tracing"
"github.com/cockroachdb/errors"
)

Expand Down Expand Up @@ -792,7 +791,6 @@ func (db *DB) sendUsingSender(
ba.UserPriority = db.ctx.UserPriority
}

tracing.AnnotateTrace()
br, pErr := sender.Send(ctx, ba)
if pErr != nil {
if log.V(1) {
Expand Down
1 change: 0 additions & 1 deletion pkg/kv/kvclient/kvcoord/dist_sender.go
Original file line number Diff line number Diff line change
Expand Up @@ -717,7 +717,6 @@ func unsetCanForwardReadTimestampFlag(ctx context.Context, ba *roachpb.BatchRequ
func (ds *DistSender) Send(
ctx context.Context, ba roachpb.BatchRequest,
) (*roachpb.BatchResponse, *roachpb.Error) {
tracing.AnnotateTrace()
ds.incrementBatchCounters(&ba)

// TODO(nvanbenschoten): This causes ba to escape to the heap. Either
Expand Down
3 changes: 0 additions & 3 deletions pkg/kv/txn.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ import (
"github.com/cockroachdb/cockroach/pkg/util/log"
"github.com/cockroachdb/cockroach/pkg/util/protoutil"
"github.com/cockroachdb/cockroach/pkg/util/syncutil"
"github.com/cockroachdb/cockroach/pkg/util/tracing"
"github.com/cockroachdb/cockroach/pkg/util/uuid"
"github.com/cockroachdb/errors"
)
Expand Down Expand Up @@ -582,8 +581,6 @@ func (txn *Txn) DelRange(ctx context.Context, begin, end interface{}) error {
// operation. The order of the results matches the order the operations were
// added to the batch.
func (txn *Txn) Run(ctx context.Context, b *Batch) error {
tracing.AnnotateTrace()
defer tracing.AnnotateTrace()
if err := b.prepare(); err != nil {
return err
}
Expand Down
3 changes: 0 additions & 3 deletions pkg/sql/delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ import (
"github.com/cockroachdb/cockroach/pkg/sql/row"
"github.com/cockroachdb/cockroach/pkg/sql/rowcontainer"
"github.com/cockroachdb/cockroach/pkg/sql/sem/tree"
"github.com/cockroachdb/cockroach/pkg/util/tracing"
)

var deleteNodePool = sync.Pool{
Expand Down Expand Up @@ -91,8 +90,6 @@ func (d *deleteNode) BatchedNext(params runParams) (bool, error) {
return false, nil
}

tracing.AnnotateTrace()

// Advance one batch. First, clear the last batch.
d.run.td.clearLastBatch(params.ctx)
// Now consume/accumulate the rows for this batch.
Expand Down
3 changes: 0 additions & 3 deletions pkg/sql/insert.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ import (
"github.com/cockroachdb/cockroach/pkg/sql/row"
"github.com/cockroachdb/cockroach/pkg/sql/rowcontainer"
"github.com/cockroachdb/cockroach/pkg/sql/sem/tree"
"github.com/cockroachdb/cockroach/pkg/util/tracing"
)

var insertNodePool = sync.Pool{
Expand Down Expand Up @@ -206,8 +205,6 @@ func (n *insertNode) BatchedNext(params runParams) (bool, error) {
return false, nil
}

tracing.AnnotateTrace()

// Advance one batch. First, clear the last batch.
n.run.ti.clearLastBatch(params.ctx)

Expand Down
3 changes: 0 additions & 3 deletions pkg/sql/insert_fast_path.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ import (
"github.com/cockroachdb/cockroach/pkg/sql/sem/tree"
"github.com/cockroachdb/cockroach/pkg/sql/span"
"github.com/cockroachdb/cockroach/pkg/util/log"
"github.com/cockroachdb/cockroach/pkg/util/tracing"
"github.com/cockroachdb/errors"
)

Expand Down Expand Up @@ -268,8 +267,6 @@ func (n *insertFastPathNode) BatchedNext(params runParams) (bool, error) {
return false, nil
}

tracing.AnnotateTrace()

// The fast path node does everything in one batch.

for rowIdx, tupleRow := range n.input {
Expand Down
1 change: 0 additions & 1 deletion pkg/sql/pgwire/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ go_library(
"//pkg/util/timeofday",
"//pkg/util/timetz",
"//pkg/util/timeutil",
"//pkg/util/tracing",
"@com_github_cockroachdb_apd_v2//:apd",
"@com_github_cockroachdb_errors//:errors",
"@com_github_cockroachdb_logtags//:logtags",
Expand Down
3 changes: 0 additions & 3 deletions pkg/sql/pgwire/conn.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ import (
"github.com/cockroachdb/cockroach/pkg/util/log"
"github.com/cockroachdb/cockroach/pkg/util/mon"
"github.com/cockroachdb/cockroach/pkg/util/timeutil"
"github.com/cockroachdb/cockroach/pkg/util/tracing"
"github.com/cockroachdb/errors"
"github.com/cockroachdb/logtags"
"github.com/lib/pq/oid"
Expand Down Expand Up @@ -705,8 +704,6 @@ func (c *conn) handleSimpleQuery(
return c.stmtBuf.Push(ctx, sql.SendError{Err: err})
}

tracing.AnnotateTrace()

startParse := timeutil.Now()
stmts, err := c.parser.ParseWithInt(query, unqualifiedIntSize)
if err != nil {
Expand Down
3 changes: 0 additions & 3 deletions pkg/sql/update.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ import (
"github.com/cockroachdb/cockroach/pkg/sql/rowcontainer"
"github.com/cockroachdb/cockroach/pkg/sql/sem/tree"
"github.com/cockroachdb/cockroach/pkg/sql/sqlerrors"
"github.com/cockroachdb/cockroach/pkg/util/tracing"
"github.com/cockroachdb/errors"
)

Expand Down Expand Up @@ -149,8 +148,6 @@ func (u *updateNode) BatchedNext(params runParams) (bool, error) {
return false, nil
}

tracing.AnnotateTrace()

// Advance one batch. First, clear the last batch.
u.run.tu.clearLastBatch(params.ctx)

Expand Down
3 changes: 0 additions & 3 deletions pkg/sql/upsert.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ import (
"github.com/cockroachdb/cockroach/pkg/sql/catalog/descpb"
"github.com/cockroachdb/cockroach/pkg/sql/row"
"github.com/cockroachdb/cockroach/pkg/sql/sem/tree"
"github.com/cockroachdb/cockroach/pkg/util/tracing"
)

var upsertNodePool = sync.Pool{
Expand Down Expand Up @@ -77,8 +76,6 @@ func (n *upsertNode) BatchedNext(params runParams) (bool, error) {
return false, nil
}

tracing.AnnotateTrace()

// Advance one batch. First, clear the last batch.
n.run.tw.clearLastBatch(params.ctx)

Expand Down
3 changes: 0 additions & 3 deletions pkg/util/tracing/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")
go_library(
name = "tracing",
srcs = [
"annotate.go",
"annotate_nocgo.go",
"context.go",
"grpc_interceptor.go",
"recording.go",
Expand All @@ -15,7 +13,6 @@ go_library(
"test_utils.go",
"tracer.go",
],
cgo = True,
importpath = "github.com/cockroachdb/cockroach/pkg/util/tracing",
visibility = ["//visibility:public"],
deps = [
Expand Down
27 changes: 0 additions & 27 deletions pkg/util/tracing/annotate.go

This file was deleted.

18 changes: 0 additions & 18 deletions pkg/util/tracing/annotate_nocgo.go

This file was deleted.

0 comments on commit f868736

Please sign in to comment.