From b2a1760c687c65fdb039452377738a5c59da3ee4 Mon Sep 17 00:00:00 2001 From: Joshua MacDonald Date: Wed, 8 Sep 2021 14:50:02 -0700 Subject: [PATCH] Upgrade to release v1.0.0-RC3 (trace) and v0.23 (metrics) (#1091) * WIP metrics update Signed-off-by: Anthony J Mirabella * fix cortex * one dogstatsd test * fix tests w/ an ordered reader * checkpoint * checkpoint2 * checkpoint3 * tests pass * precommit * OC lint Co-authored-by: Anthony J Mirabella --- exporters/metric/cortex/cortex.go | 83 +++--- exporters/metric/cortex/cortex_test.go | 18 +- exporters/metric/cortex/example/go.mod | 8 +- exporters/metric/cortex/example/go.sum | 20 +- exporters/metric/cortex/example/main.go | 10 +- exporters/metric/cortex/go.mod | 6 +- exporters/metric/cortex/go.sum | 20 +- exporters/metric/cortex/testutil_test.go | 208 ++++++++------ exporters/metric/cortex/utils/go.mod | 2 +- exporters/metric/cortex/utils/go.sum | 20 +- exporters/metric/datadog/datadog.go | 6 +- exporters/metric/datadog/example_test.go | 2 +- exporters/metric/datadog/go.mod | 7 +- exporters/metric/datadog/go.sum | 25 +- exporters/metric/dogstatsd/dogstatsd_test.go | 40 +-- exporters/metric/dogstatsd/example_test.go | 2 +- exporters/metric/dogstatsd/go.mod | 6 +- exporters/metric/dogstatsd/go.sum | 20 +- .../metric/dogstatsd/internal/statsd/conn.go | 7 +- .../dogstatsd/internal/statsd/conn_test.go | 266 +++++++++++------- .../Shopify/sarama/otelsarama/example/go.mod | 2 +- .../Shopify/sarama/otelsarama/go.mod | 2 +- .../Shopify/sarama/otelsarama/test/go.mod | 4 +- .../Shopify/sarama/otelsarama/test/go.sum | 2 - .../astaxie/beego/otelbeego/example/go.mod | 2 +- .../astaxie/beego/otelbeego/example/go.sum | 11 +- .../github.com/astaxie/beego/otelbeego/go.mod | 4 +- .../github.com/astaxie/beego/otelbeego/go.sum | 11 +- .../astaxie/beego/otelbeego/test/go.mod | 15 +- .../astaxie/beego/otelbeego/test/go.sum | 19 +- .../aws/aws-sdk-go-v2/otelaws/example/go.mod | 2 +- .../aws/aws-sdk-go-v2/otelaws/go.mod | 2 +- .../aws/aws-sdk-go-v2/otelaws/test/go.mod | 6 +- .../aws/aws-sdk-go-v2/otelaws/test/go.sum | 12 - .../memcache/otelmemcache/example/go.mod | 2 +- .../gomemcache/memcache/otelmemcache/go.mod | 2 +- .../memcache/otelmemcache/test/go.mod | 4 +- .../go-restful/otelrestful/example/go.mod | 2 +- .../emicklei/go-restful/otelrestful/go.mod | 4 +- .../go-restful/otelrestful/test/go.mod | 10 +- .../go-restful/otelrestful/test/go.sum | 2 - .../gin-gonic/gin/otelgin/example/go.mod | 2 +- .../github.com/gin-gonic/gin/otelgin/go.mod | 4 +- .../gin-gonic/gin/otelgin/test/go.mod | 4 +- .../gin-gonic/gin/otelgin/test/go.sum | 2 - .../go-kit/kit/otelkit/example/go.mod | 2 +- .../github.com/go-kit/kit/otelkit/go.mod | 2 +- .../github.com/go-kit/kit/otelkit/test/go.mod | 4 +- .../github.com/go-kit/kit/otelkit/test/go.sum | 2 - .../gocql/gocql/otelgocql/example/go.mod | 10 +- .../gocql/gocql/otelgocql/example/go.sum | 24 +- .../github.com/gocql/gocql/otelgocql/go.mod | 4 +- .../github.com/gocql/gocql/otelgocql/go.sum | 11 +- .../gocql/gocql/otelgocql/instrument.go | 8 +- .../gocql/gocql/otelgocql/test/go.mod | 8 +- .../gocql/gocql/otelgocql/test/go.sum | 13 +- .../gorilla/mux/otelmux/example/go.mod | 2 +- .../github.com/gorilla/mux/otelmux/go.mod | 2 +- .../gorilla/mux/otelmux/test/go.mod | 7 +- .../gorilla/mux/otelmux/test/go.sum | 10 - .../labstack/echo/otelecho/example/go.mod | 2 +- .../github.com/labstack/echo/otelecho/go.mod | 4 +- .../labstack/echo/otelecho/test/go.mod | 10 +- .../labstack/echo/otelecho/test/go.sum | 2 - .../mongo-driver/mongo/otelmongo/go.mod | 2 +- .../mongo-driver/mongo/otelmongo/test/go.mod | 4 +- .../grpc/otelgrpc/example/go.mod | 2 +- .../google.golang.org/grpc/otelgrpc/go.mod | 2 +- .../grpc/otelgrpc/test/go.mod | 7 +- .../grpc/otelgrpc/test/go.sum | 2 - .../macaron.v1/otelmacaron/example/go.mod | 2 +- .../gopkg.in/macaron.v1/otelmacaron/go.mod | 4 +- .../macaron.v1/otelmacaron/test/go.mod | 10 +- .../macaron.v1/otelmacaron/test/go.sum | 2 - instrumentation/host/example/go.mod | 8 +- instrumentation/host/example/go.sum | 30 +- instrumentation/host/go.mod | 4 +- instrumentation/host/go.sum | 11 +- instrumentation/host/host.go | 20 +- .../httptrace/otelhttptrace/example/go.mod | 4 +- .../httptrace/otelhttptrace/example/go.sum | 11 +- .../net/http/httptrace/otelhttptrace/go.mod | 2 +- .../http/httptrace/otelhttptrace/test/go.mod | 7 +- .../http/httptrace/otelhttptrace/test/go.sum | 2 - .../net/http/otelhttp/example/go.mod | 2 +- .../net/http/otelhttp/example/go.sum | 11 +- instrumentation/net/http/otelhttp/go.mod | 4 +- instrumentation/net/http/otelhttp/go.sum | 11 +- instrumentation/net/http/otelhttp/handler.go | 6 +- instrumentation/net/http/otelhttp/test/go.mod | 9 +- instrumentation/net/http/otelhttp/test/go.sum | 13 +- instrumentation/runtime/example/go.mod | 8 +- instrumentation/runtime/example/go.sum | 36 +-- instrumentation/runtime/go.mod | 4 +- instrumentation/runtime/go.sum | 18 +- instrumentation/runtime/runtime.go | 54 ++-- propagators/opencensus/binary.go | 6 +- propagators/opencensus/examples/go.mod | 4 +- propagators/opencensus/examples/go.sum | 17 +- propagators/opencensus/go.mod | 2 +- propagators/opencensus/go.sum | 21 +- 101 files changed, 728 insertions(+), 669 deletions(-) diff --git a/exporters/metric/cortex/cortex.go b/exporters/metric/cortex/cortex.go index e6fb04d156a..73c2cd87cca 100644 --- a/exporters/metric/cortex/cortex.go +++ b/exporters/metric/cortex/cortex.go @@ -38,6 +38,7 @@ import ( controller "go.opentelemetry.io/otel/sdk/metric/controller/basic" processor "go.opentelemetry.io/otel/sdk/metric/processor/basic" "go.opentelemetry.io/otel/sdk/metric/selector/simple" + "go.opentelemetry.io/otel/sdk/resource" ) // Exporter forwards metrics to a Cortex instance @@ -45,14 +46,20 @@ type Exporter struct { config Config } +type exportData struct { + export.Record + + Resource *resource.Resource +} + // ExportKindFor returns CumulativeExporter so the Processor correctly aggregates data func (e *Exporter) ExportKindFor(*apimetric.Descriptor, aggregation.Kind) metric.ExportKind { return metric.CumulativeExportKind } // Export forwards metrics to Cortex from the SDK -func (e *Exporter) Export(_ context.Context, checkpointSet metric.CheckpointSet) error { - timeseries, err := e.ConvertToTimeSeries(checkpointSet) +func (e *Exporter) Export(_ context.Context, res *resource.Resource, checkpointSet metric.CheckpointSet) error { + timeseries, err := e.ConvertToTimeSeries(res, checkpointSet) if err != nil { return err } @@ -121,13 +128,17 @@ func InstallNewPipeline(config Config, options ...controller.Option) (*controlle // ConvertToTimeSeries converts a CheckpointSet to a slice of TimeSeries pointers // Based on the aggregation type, ConvertToTimeSeries will call helper functions like // convertFromSum to generate the correct number of TimeSeries. -func (e *Exporter) ConvertToTimeSeries(checkpointSet export.CheckpointSet) ([]*prompb.TimeSeries, error) { +func (e *Exporter) ConvertToTimeSeries(res *resource.Resource, checkpointSet export.CheckpointSet) ([]*prompb.TimeSeries, error) { var aggError error var timeSeries []*prompb.TimeSeries // Iterate over each record in the checkpoint set and convert to TimeSeries aggError = checkpointSet.ForEach(e, func(record metric.Record) error { // Convert based on aggregation type + edata := exportData{ + Resource: res, + Record: record, + } agg := record.Aggregation() // The following section uses loose type checking to determine how to @@ -137,33 +148,33 @@ func (e *Exporter) ConvertToTimeSeries(checkpointSet export.CheckpointSet) ([]*p // See the Aggregator Kind for more information // https://github.com/open-telemetry/opentelemetry-go/blob/main/sdk/export/metric/aggregation/aggregation.go#L123-L138 if histogram, ok := agg.(aggregation.Histogram); ok { - tSeries, err := convertFromHistogram(record, histogram) + tSeries, err := convertFromHistogram(edata, histogram) if err != nil { return err } timeSeries = append(timeSeries, tSeries...) } else if sum, ok := agg.(aggregation.Sum); ok { - tSeries, err := convertFromSum(record, sum) + tSeries, err := convertFromSum(edata, sum) if err != nil { return err } timeSeries = append(timeSeries, tSeries) if minMaxSumCount, ok := agg.(aggregation.MinMaxSumCount); ok { - tSeries, err := convertFromMinMaxSumCount(record, minMaxSumCount) + tSeries, err := convertFromMinMaxSumCount(edata, minMaxSumCount) if err != nil { return err } timeSeries = append(timeSeries, tSeries...) } } else if lastValue, ok := agg.(aggregation.LastValue); ok { - tSeries, err := convertFromLastValue(record, lastValue) + tSeries, err := convertFromLastValue(edata, lastValue) if err != nil { return err } timeSeries = append(timeSeries, tSeries) } else { // Report to the user when no conversion was found - fmt.Printf("No conversion found for record: %s\n", record.Descriptor().Name()) + fmt.Printf("No conversion found for record: %s\n", edata.Descriptor().Name()) } return nil @@ -178,13 +189,13 @@ func (e *Exporter) ConvertToTimeSeries(checkpointSet export.CheckpointSet) ([]*p } // createTimeSeries is a helper function to create a timeseries from a value and attributes -func createTimeSeries(record metric.Record, value number.Number, valueNumberKind number.Kind, extraAttributes ...attribute.KeyValue) *prompb.TimeSeries { +func createTimeSeries(edata exportData, value number.Number, valueNumberKind number.Kind, extraAttributes ...attribute.KeyValue) *prompb.TimeSeries { sample := prompb.Sample{ Value: value.CoerceToFloat64(valueNumberKind), - Timestamp: int64(time.Nanosecond) * record.EndTime().UnixNano() / int64(time.Millisecond), + Timestamp: int64(time.Nanosecond) * edata.EndTime().UnixNano() / int64(time.Millisecond), } - attributes := createLabelSet(record, extraAttributes...) + attributes := createLabelSet(edata, extraAttributes...) return &prompb.TimeSeries{ Samples: []prompb.Sample{sample}, @@ -193,7 +204,7 @@ func createTimeSeries(record metric.Record, value number.Number, valueNumberKind } // convertFromSum returns a single TimeSeries based on a Record with a Sum aggregation -func convertFromSum(record metric.Record, sum aggregation.Sum) (*prompb.TimeSeries, error) { +func convertFromSum(edata exportData, sum aggregation.Sum) (*prompb.TimeSeries, error) { // Get Sum value value, err := sum.Sum() if err != nil { @@ -202,15 +213,15 @@ func convertFromSum(record metric.Record, sum aggregation.Sum) (*prompb.TimeSeri // Create TimeSeries. Note that Cortex requires the name attribute to be in the format // "__name__". This is the case for all time series created by this exporter. - name := sanitize(record.Descriptor().Name()) - numberKind := record.Descriptor().NumberKind() - tSeries := createTimeSeries(record, value, numberKind, attribute.String("__name__", name)) + name := sanitize(edata.Descriptor().Name()) + numberKind := edata.Descriptor().NumberKind() + tSeries := createTimeSeries(edata, value, numberKind, attribute.String("__name__", name)) return tSeries, nil } // convertFromLastValue returns a single TimeSeries based on a Record with a LastValue aggregation -func convertFromLastValue(record metric.Record, lastValue aggregation.LastValue) (*prompb.TimeSeries, error) { +func convertFromLastValue(edata exportData, lastValue aggregation.LastValue) (*prompb.TimeSeries, error) { // Get value value, _, err := lastValue.LastValue() if err != nil { @@ -218,40 +229,40 @@ func convertFromLastValue(record metric.Record, lastValue aggregation.LastValue) } // Create TimeSeries - name := sanitize(record.Descriptor().Name()) - numberKind := record.Descriptor().NumberKind() - tSeries := createTimeSeries(record, value, numberKind, attribute.String("__name__", name)) + name := sanitize(edata.Descriptor().Name()) + numberKind := edata.Descriptor().NumberKind() + tSeries := createTimeSeries(edata, value, numberKind, attribute.String("__name__", name)) return tSeries, nil } // convertFromMinMaxSumCount returns 4 TimeSeries for the min, max, sum, and count from the mmsc aggregation -func convertFromMinMaxSumCount(record metric.Record, minMaxSumCount aggregation.MinMaxSumCount) ([]*prompb.TimeSeries, error) { - numberKind := record.Descriptor().NumberKind() +func convertFromMinMaxSumCount(edata exportData, minMaxSumCount aggregation.MinMaxSumCount) ([]*prompb.TimeSeries, error) { + numberKind := edata.Descriptor().NumberKind() // Convert Min min, err := minMaxSumCount.Min() if err != nil { return nil, err } - name := sanitize(record.Descriptor().Name() + "_min") - minTimeSeries := createTimeSeries(record, min, numberKind, attribute.String("__name__", name)) + name := sanitize(edata.Descriptor().Name() + "_min") + minTimeSeries := createTimeSeries(edata, min, numberKind, attribute.String("__name__", name)) // Convert Max max, err := minMaxSumCount.Max() if err != nil { return nil, err } - name = sanitize(record.Descriptor().Name() + "_max") - maxTimeSeries := createTimeSeries(record, max, numberKind, attribute.String("__name__", name)) + name = sanitize(edata.Descriptor().Name() + "_max") + maxTimeSeries := createTimeSeries(edata, max, numberKind, attribute.String("__name__", name)) // Convert Count count, err := minMaxSumCount.Count() if err != nil { return nil, err } - name = sanitize(record.Descriptor().Name() + "_count") - countTimeSeries := createTimeSeries(record, number.NewInt64Number(int64(count)), number.Int64Kind, attribute.String("__name__", name)) + name = sanitize(edata.Descriptor().Name() + "_count") + countTimeSeries := createTimeSeries(edata, number.NewInt64Number(int64(count)), number.Int64Kind, attribute.String("__name__", name)) // Return all timeSeries tSeries := []*prompb.TimeSeries{ @@ -262,17 +273,17 @@ func convertFromMinMaxSumCount(record metric.Record, minMaxSumCount aggregation. } // convertFromHistogram returns len(histogram.Buckets) timeseries for a histogram aggregation -func convertFromHistogram(record metric.Record, histogram aggregation.Histogram) ([]*prompb.TimeSeries, error) { +func convertFromHistogram(edata exportData, histogram aggregation.Histogram) ([]*prompb.TimeSeries, error) { var timeSeries []*prompb.TimeSeries - metricName := sanitize(record.Descriptor().Name()) - numberKind := record.Descriptor().NumberKind() + metricName := sanitize(edata.Descriptor().Name()) + numberKind := edata.Descriptor().NumberKind() // Create Sum TimeSeries sum, err := histogram.Sum() if err != nil { return nil, err } - sumTimeSeries := createTimeSeries(record, sum, numberKind, attribute.String("__name__", metricName+"_sum")) + sumTimeSeries := createTimeSeries(edata, sum, numberKind, attribute.String("__name__", metricName+"_sum")) timeSeries = append(timeSeries, sumTimeSeries) // Handle Histogram buckets @@ -294,7 +305,7 @@ func convertFromHistogram(record metric.Record, histogram aggregation.Histogram) boundaryStr := strconv.FormatFloat(boundary, 'f', -1, 64) // Create timeSeries and append - boundaryTimeSeries := createTimeSeries(record, number.NewFloat64Number(totalCount), number.Float64Kind, attribute.String("__name__", metricName), attribute.String("le", boundaryStr)) + boundaryTimeSeries := createTimeSeries(edata, number.NewFloat64Number(totalCount), number.Float64Kind, attribute.String("__name__", metricName), attribute.String("le", boundaryStr)) timeSeries = append(timeSeries, boundaryTimeSeries) } @@ -304,9 +315,9 @@ func convertFromHistogram(record metric.Record, histogram aggregation.Histogram) // Create a timeSeries for the +inf bucket and total count // These are the same and are both required by Prometheus-based backends - upperBoundTimeSeries := createTimeSeries(record, number.NewFloat64Number(totalCount), number.Float64Kind, attribute.String("__name__", metricName), attribute.String("le", "+inf")) + upperBoundTimeSeries := createTimeSeries(edata, number.NewFloat64Number(totalCount), number.Float64Kind, attribute.String("__name__", metricName), attribute.String("le", "+inf")) - countTimeSeries := createTimeSeries(record, number.NewFloat64Number(totalCount), number.Float64Kind, attribute.String("__name__", metricName+"_count")) + countTimeSeries := createTimeSeries(edata, number.NewFloat64Number(totalCount), number.Float64Kind, attribute.String("__name__", metricName+"_count")) timeSeries = append(timeSeries, upperBoundTimeSeries) timeSeries = append(timeSeries, countTimeSeries) @@ -316,13 +327,13 @@ func convertFromHistogram(record metric.Record, histogram aggregation.Histogram) // createLabelSet combines attributes from a Record, resource, and extra attributes to create a // slice of prompb.Label. -func createLabelSet(record metric.Record, extraAttributes ...attribute.KeyValue) []*prompb.Label { +func createLabelSet(edata exportData, extraAttributes ...attribute.KeyValue) []*prompb.Label { // Map ensure no duplicate label names. labelMap := map[string]prompb.Label{} // mergeAttributes merges Record and Resource attributes into a single set, giving precedence // to the record's attributes. - mi := attribute.NewMergeIterator(record.Labels(), record.Resource().Set()) + mi := attribute.NewMergeIterator(edata.Labels(), edata.Resource.Set()) for mi.Next() { attribute := mi.Label() key := string(attribute.Key) diff --git a/exporters/metric/cortex/cortex_test.go b/exporters/metric/cortex/cortex_test.go index f7383389420..f84b32193d8 100644 --- a/exporters/metric/cortex/cortex_test.go +++ b/exporters/metric/cortex/cortex_test.go @@ -39,6 +39,8 @@ import ( semconv "go.opentelemetry.io/otel/semconv/v1.4.0" ) +var testResource = resource.NewWithAttributes(semconv.SchemaURL, attribute.String("R", "V")) + // ValidConfig is a Config struct that should cause no errors. var validConfig = Config{ Endpoint: "/api/prom/push", @@ -67,9 +69,6 @@ var validConfig = Config{ Quantiles: []float64{0, 0.25, 0.5, 0.75, 1}, } -var testResource = resource.NewWithAttributes(semconv.SchemaURL, attribute.String("R", "V")) -var mockTime = int64(time.Nanosecond) * time.Time{}.UnixNano() / int64(time.Millisecond) - func TestExportKindFor(t *testing.T) { exporter := Exporter{} got := exporter.ExportKindFor(nil, aggregation.Kind(rune(0))) @@ -88,6 +87,8 @@ func TestConvertToTimeSeries(t *testing.T) { }, } + startTime := time.Now() + // Test conversions based on aggregation type tests := []struct { name string @@ -121,9 +122,11 @@ func TestConvertToTimeSeries(t *testing.T) { }, } + endTime := time.Now() + for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { - got, err := exporter.ConvertToTimeSeries(tt.input) + got, err := exporter.ConvertToTimeSeries(testResource, tt.input) want := tt.want // Check for errors and for the correct number of timeseries. @@ -148,10 +151,13 @@ func TestConvertToTimeSeries(t *testing.T) { wantAttributes[attribute.String()] = true } for _, sample := range got[i].Samples { - gotSamples[sample.String()] = true + gotSamples[fmt.Sprint(sample.Value)] = true + + assert.LessOrEqual(t, toMillis(startTime), sample.Timestamp) + assert.GreaterOrEqual(t, toMillis(endTime), sample.Timestamp) } for _, sample := range want[i].Samples { - wantSamples[sample.String()] = true + wantSamples[fmt.Sprint(sample.Value)] = true } } assert.Equal(t, wantAttributes, gotAttributes) diff --git a/exporters/metric/cortex/example/go.mod b/exporters/metric/cortex/example/go.mod index e5eec727470..473800ac6d7 100644 --- a/exporters/metric/cortex/example/go.mod +++ b/exporters/metric/cortex/example/go.mod @@ -8,10 +8,10 @@ replace ( ) require ( - go.opentelemetry.io/contrib/exporters/metric/cortex v0.22.0 - go.opentelemetry.io/contrib/exporters/metric/cortex/utils v0.22.0 + go.opentelemetry.io/contrib/exporters/metric/cortex v0.23.0 + go.opentelemetry.io/contrib/exporters/metric/cortex/utils v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 - go.opentelemetry.io/otel/metric v0.22.0 + go.opentelemetry.io/otel/metric v0.23.0 go.opentelemetry.io/otel/sdk v1.0.0-RC3 - go.opentelemetry.io/otel/sdk/metric v0.22.0 + go.opentelemetry.io/otel/sdk/metric v0.23.0 ) diff --git a/exporters/metric/cortex/example/go.sum b/exporters/metric/cortex/example/go.sum index 70d58232e45..39e75f7973b 100644 --- a/exporters/metric/cortex/example/go.sum +++ b/exporters/metric/cortex/example/go.sum @@ -255,22 +255,18 @@ go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/sdk v1.0.0-RC1/go.mod h1:kj6yPn7Pgt5ByRuwesbaWcRLA+V7BSDg3Hf8xRvsvf8= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0 h1:6huidwh9LZi/+lvFw7EQ+m+pVmlfhOMd9s9PmTXAgeo= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0/go.mod h1:a14rf2CiHSn9xjB6cHuv0HoZGl5C4w2PAgl+Lja1VzU= -go.opentelemetry.io/otel/sdk/metric v0.22.0 h1:ZBagqeLlTgEmvxtaN3GkvmbmG+XWKDwS+amr8EsSMDo= -go.opentelemetry.io/otel/sdk/metric v0.22.0/go.mod h1:LzkI0G0z6KhEagqmzgk3bw/dglE2Tk2OXs455UMcI0s= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0 h1:7NeoKPPx6NdZBVHLEp/LY5Lq85Ff1WNZnuJkuRy+azw= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0/go.mod h1:SuMiREmKVRIwFKq73zvGTvwFpxb/ZAYkMfyqMoOtDqs= +go.opentelemetry.io/otel/sdk/metric v0.23.0 h1:xlZhPbiue1+jjSFEth94q9QCmX8Q24mOtue9IAmlVyI= +go.opentelemetry.io/otel/sdk/metric v0.23.0/go.mod h1:wa0sKK13eeIFW+0OFjcC3S1i7FTRRiLAXe1kjBVbhwg= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= diff --git a/exporters/metric/cortex/example/main.go b/exporters/metric/cortex/example/main.go index 09ea41f165f..e41500e185c 100644 --- a/exporters/metric/cortex/example/main.go +++ b/exporters/metric/cortex/example/main.go @@ -55,8 +55,8 @@ func main() { meter := pusher.MeterProvider().Meter("example") // Create instruments. - recorder := metric.Must(meter).NewInt64ValueRecorder( - "example.valuerecorder", + histogram := metric.Must(meter).NewInt64Histogram( + "example.histogram", metric.WithDescription("Records values"), ) @@ -64,7 +64,7 @@ func main() { "example.counter", metric.WithDescription("Counts things"), ) - fmt.Println("Success: Created Int64ValueRecorder and Int64Counter instruments!") + fmt.Println("Success: Created Int64Histogram and Int64Counter instruments!") // Record random values to the instruments in a loop fmt.Println("Starting to write data to the instruments!") @@ -74,9 +74,9 @@ func main() { time.Sleep(1 * time.Second) randomValue := random.Intn(100) value := int64(randomValue * 10) - recorder.Record(ctx, value, attribute.String("key", "value")) + histogram.Record(ctx, value, attribute.String("key", "value")) counter.Add(ctx, int64(randomValue), attribute.String("key", "value")) - fmt.Printf("Adding %d to counter and recording %d in recorder\n", randomValue, value) + fmt.Printf("Adding %d to counter and recording %d in histogram\n", randomValue, value) } } diff --git a/exporters/metric/cortex/go.mod b/exporters/metric/cortex/go.mod index 069d02b848c..83eb01aa5d3 100644 --- a/exporters/metric/cortex/go.mod +++ b/exporters/metric/cortex/go.mod @@ -10,8 +10,8 @@ require ( github.com/prometheus/prometheus v2.5.0+incompatible github.com/stretchr/testify v1.7.0 go.opentelemetry.io/otel v1.0.0-RC3 - go.opentelemetry.io/otel/metric v0.22.0 + go.opentelemetry.io/otel/metric v0.23.0 go.opentelemetry.io/otel/sdk v1.0.0-RC3 - go.opentelemetry.io/otel/sdk/export/metric v0.22.0 - go.opentelemetry.io/otel/sdk/metric v0.22.0 + go.opentelemetry.io/otel/sdk/export/metric v0.23.0 + go.opentelemetry.io/otel/sdk/metric v0.23.0 ) diff --git a/exporters/metric/cortex/go.sum b/exporters/metric/cortex/go.sum index 87e45291014..f937b9f12d7 100644 --- a/exporters/metric/cortex/go.sum +++ b/exporters/metric/cortex/go.sum @@ -42,22 +42,18 @@ github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5Cc github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/sdk v1.0.0-RC1/go.mod h1:kj6yPn7Pgt5ByRuwesbaWcRLA+V7BSDg3Hf8xRvsvf8= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0 h1:6huidwh9LZi/+lvFw7EQ+m+pVmlfhOMd9s9PmTXAgeo= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0/go.mod h1:a14rf2CiHSn9xjB6cHuv0HoZGl5C4w2PAgl+Lja1VzU= -go.opentelemetry.io/otel/sdk/metric v0.22.0 h1:ZBagqeLlTgEmvxtaN3GkvmbmG+XWKDwS+amr8EsSMDo= -go.opentelemetry.io/otel/sdk/metric v0.22.0/go.mod h1:LzkI0G0z6KhEagqmzgk3bw/dglE2Tk2OXs455UMcI0s= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0 h1:7NeoKPPx6NdZBVHLEp/LY5Lq85Ff1WNZnuJkuRy+azw= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0/go.mod h1:SuMiREmKVRIwFKq73zvGTvwFpxb/ZAYkMfyqMoOtDqs= +go.opentelemetry.io/otel/sdk/metric v0.23.0 h1:xlZhPbiue1+jjSFEth94q9QCmX8Q24mOtue9IAmlVyI= +go.opentelemetry.io/otel/sdk/metric v0.23.0/go.mod h1:wa0sKK13eeIFW+0OFjcC3S1i7FTRRiLAXe1kjBVbhwg= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= diff --git a/exporters/metric/cortex/testutil_test.go b/exporters/metric/cortex/testutil_test.go index 3772ab46f13..415dfaacc47 100644 --- a/exporters/metric/cortex/testutil_test.go +++ b/exporters/metric/cortex/testutil_test.go @@ -15,89 +15,133 @@ package cortex import ( + "context" + "fmt" + "strings" "testing" + "time" "github.com/prometheus/prometheus/prompb" "github.com/stretchr/testify/require" "go.opentelemetry.io/otel/metric" - "go.opentelemetry.io/otel/metric/number" export "go.opentelemetry.io/otel/sdk/export/metric" - "go.opentelemetry.io/otel/sdk/export/metric/metrictest" - "go.opentelemetry.io/otel/sdk/metric/aggregator/aggregatortest" "go.opentelemetry.io/otel/sdk/metric/aggregator/histogram" "go.opentelemetry.io/otel/sdk/metric/aggregator/lastvalue" "go.opentelemetry.io/otel/sdk/metric/aggregator/minmaxsumcount" "go.opentelemetry.io/otel/sdk/metric/aggregator/sum" + controller "go.opentelemetry.io/otel/sdk/metric/controller/basic" + processor "go.opentelemetry.io/otel/sdk/metric/processor/basic" ) +// AggregatorFor is copied from the SDK's processortest package, the +// only difference is it uses explicit histogram boundaries for the +// test. TODO: If the API supported Hints, this code could be retired +// and the code below could use the hint to set the boundaries, this is +// obnoxious. +type testAggregatorSelector struct { +} + +var testHistogramBoundaries = []float64{ + 100, 500, 900, +} + +func (testAggregatorSelector) AggregatorFor(desc *metric.Descriptor, aggPtrs ...*export.Aggregator) { + switch { + case strings.HasSuffix(desc.Name(), "_sum"): + aggs := sum.New(len(aggPtrs)) + for i := range aggPtrs { + *aggPtrs[i] = &aggs[i] + } + case strings.HasSuffix(desc.Name(), "_mmsc"): + aggs := minmaxsumcount.New(len(aggPtrs), desc) + for i := range aggPtrs { + *aggPtrs[i] = &aggs[i] + } + case strings.HasSuffix(desc.Name(), "_lastvalue"): + aggs := lastvalue.New(len(aggPtrs)) + for i := range aggPtrs { + *aggPtrs[i] = &aggs[i] + } + case strings.HasSuffix(desc.Name(), "_histogram"): + aggs := histogram.New(len(aggPtrs), desc, histogram.WithExplicitBoundaries(testHistogramBoundaries)) + for i := range aggPtrs { + *aggPtrs[i] = &aggs[i] + } + default: + panic(fmt.Sprint("Invalid instrument name for test AggregatorSelector: ", desc.Name())) + } +} + +func testMeter(t *testing.T) (context.Context, metric.Meter, *processor.Processor, *controller.Controller) { + aggSel := testAggregatorSelector{} + proc := processor.New(aggSel, export.CumulativeExportKindSelector()) + cont := controller.New(proc, + controller.WithResource(testResource), + ) + ctx := context.Background() + + return ctx, cont.MeterProvider().Meter("test"), proc, cont +} + // getSumCheckpoint returns a checkpoint set with a sum aggregation record func getSumCheckpoint(t *testing.T, values ...int64) export.CheckpointSet { - // Create checkpoint set with resource and descriptor - checkpointSet := metrictest.NewCheckpointSet(testResource) - desc := metric.NewDescriptor("metric_name", metric.CounterInstrumentKind, number.Int64Kind) + ctx, meter, proc, cont := testMeter(t) + counter := metric.Must(meter).NewInt64Counter("metric_sum") - // Create aggregation, add value, and update checkpointset - agg, ckpt := metrictest.Unslice2(sum.New(2)) for _, value := range values { - aggregatortest.CheckedUpdate(t, agg, number.NewInt64Number(value), &desc) + counter.Add(ctx, value) } - require.NoError(t, agg.SynchronizedMove(ckpt, &desc)) - checkpointSet.Add(&desc, ckpt) - return checkpointSet + require.NoError(t, cont.Collect(ctx)) + + return proc.CheckpointSet() } // getLastValueCheckpoint returns a checkpoint set with a last value aggregation record func getLastValueCheckpoint(t *testing.T, values ...int64) export.CheckpointSet { - // Create checkpoint set with resource and descriptor - checkpointSet := metrictest.NewCheckpointSet(testResource) - desc := metric.NewDescriptor("metric_name", metric.ValueObserverInstrumentKind, number.Int64Kind) + ctx, meter, proc, cont := testMeter(t) - // Create aggregation, add value, and update checkpointset - agg, ckpt := metrictest.Unslice2(lastvalue.New(2)) - for _, value := range values { - aggregatortest.CheckedUpdate(t, agg, number.NewInt64Number(value), &desc) - } - require.NoError(t, agg.SynchronizedMove(ckpt, &desc)) - checkpointSet.Add(&desc, ckpt) + _ = metric.Must(meter).NewInt64GaugeObserver("metric_lastvalue", func(ctx context.Context, res metric.Int64ObserverResult) { + for _, value := range values { + res.Observe(value) + } + }) + + require.NoError(t, cont.Collect(ctx)) - return checkpointSet + return proc.CheckpointSet() } // getMMSCCheckpoint returns a checkpoint set with a minmaxsumcount aggregation record func getMMSCCheckpoint(t *testing.T, values ...float64) export.CheckpointSet { - // Create checkpoint set with resource and descriptor - checkpointSet := metrictest.NewCheckpointSet(testResource) - desc := metric.NewDescriptor("metric_name", metric.ValueRecorderInstrumentKind, number.Float64Kind) + ctx, meter, proc, cont := testMeter(t) + + histo := metric.Must(meter).NewFloat64Histogram("metric_mmsc") - // Create aggregation, add value, and update checkpointset - agg, ckpt := metrictest.Unslice2(minmaxsumcount.New(2, &desc)) for _, value := range values { - aggregatortest.CheckedUpdate(t, agg, number.NewFloat64Number(value), &desc) + histo.Record(ctx, value) } - require.NoError(t, agg.SynchronizedMove(ckpt, &desc)) - checkpointSet.Add(&desc, ckpt) - return checkpointSet + require.NoError(t, cont.Collect(ctx)) + + return proc.CheckpointSet() } // getHistogramCheckpoint returns a checkpoint set with a histogram aggregation record func getHistogramCheckpoint(t *testing.T) export.CheckpointSet { - // Create checkpoint set with resource and descriptor - checkpointSet := metrictest.NewCheckpointSet(testResource) - desc := metric.NewDescriptor("metric_name", metric.ValueRecorderInstrumentKind, number.Float64Kind) - - // Create aggregation, add value, and update checkpointset - boundaries := []float64{100, 500, 900} - agg, ckpt := metrictest.Unslice2(histogram.New(2, &desc, histogram.WithExplicitBoundaries(boundaries))) - for i := 0; i < 1000; i++ { - aggregatortest.CheckedUpdate(t, agg, number.NewFloat64Number(float64(i)+0.5), &desc) + ctx, meter, proc, cont := testMeter(t) + + // Uses default boundaries + histo := metric.Must(meter).NewFloat64Histogram("metric_histogram") + + for value := 0.; value < 1000; value++ { + histo.Record(ctx, value+0.5) } - require.NoError(t, agg.SynchronizedMove(ckpt, &desc)) - checkpointSet.Add(&desc, ckpt) - return checkpointSet + require.NoError(t, cont.Collect(ctx)) + + return proc.CheckpointSet() } // The following variables hold expected TimeSeries values to be used in @@ -111,12 +155,12 @@ var wantSumCheckpointSet = []*prompb.TimeSeries{ }, { Name: "__name__", - Value: "metric_name", + Value: "metric_sum", }, }, Samples: []prompb.Sample{{ - Value: 15, - Timestamp: mockTime, + Value: 15, + // Timestamp: this test verifies real timestamps }}, }, } @@ -130,12 +174,12 @@ var wantLastValueCheckpointSet = []*prompb.TimeSeries{ }, { Name: "__name__", - Value: "metric_name", + Value: "metric_lastvalue", }, }, Samples: []prompb.Sample{{ - Value: 5, - Timestamp: mockTime, + Value: 5, + // Timestamp: this test verifies real timestamps }}, }, } @@ -149,12 +193,12 @@ var wantMMSCCheckpointSet = []*prompb.TimeSeries{ }, { Name: "__name__", - Value: "metric_name", + Value: "metric_mmsc", }, }, Samples: []prompb.Sample{{ - Value: 999.999, - Timestamp: mockTime, + Value: 999.999, + // Timestamp: this test verifies real timestamps }}, }, { @@ -165,12 +209,12 @@ var wantMMSCCheckpointSet = []*prompb.TimeSeries{ }, { Name: "__name__", - Value: "metric_name_min", + Value: "metric_mmsc_min", }, }, Samples: []prompb.Sample{{ - Value: 123.456, - Timestamp: mockTime, + Value: 123.456, + // Timestamp: this test verifies real timestamps }}, }, { @@ -181,12 +225,12 @@ var wantMMSCCheckpointSet = []*prompb.TimeSeries{ }, { Name: "__name__", - Value: "metric_name_max", + Value: "metric_mmsc_max", }, }, Samples: []prompb.Sample{{ - Value: 876.543, - Timestamp: mockTime, + Value: 876.543, + // Timestamp: this test verifies real timestamps }}, }, { @@ -197,12 +241,12 @@ var wantMMSCCheckpointSet = []*prompb.TimeSeries{ }, { Name: "__name__", - Value: "metric_name_count", + Value: "metric_mmsc_count", }, }, Samples: []prompb.Sample{{ - Value: 2, - Timestamp: mockTime, + Value: 2, + // Timestamp: this test verifies real timestamps }}, }, } @@ -216,12 +260,12 @@ var wantHistogramCheckpointSet = []*prompb.TimeSeries{ }, { Name: "__name__", - Value: "metric_name_sum", + Value: "metric_histogram_sum", }, }, Samples: []prompb.Sample{{ - Value: 500000, - Timestamp: mockTime, + Value: 500000, + // Timestamp: this test verifies real timestamps }}, }, { @@ -232,12 +276,12 @@ var wantHistogramCheckpointSet = []*prompb.TimeSeries{ }, { Name: "__name__", - Value: "metric_name_count", + Value: "metric_histogram_count", }, }, Samples: []prompb.Sample{{ - Value: 1000, - Timestamp: mockTime, + Value: 1000, + // Timestamp: this test verifies real timestamps }}, }, { @@ -248,7 +292,7 @@ var wantHistogramCheckpointSet = []*prompb.TimeSeries{ }, { Name: "__name__", - Value: "metric_name", + Value: "metric_histogram", }, { Name: "le", @@ -256,8 +300,8 @@ var wantHistogramCheckpointSet = []*prompb.TimeSeries{ }, }, Samples: []prompb.Sample{{ - Value: 100, - Timestamp: mockTime, + Value: 100, + // Timestamp: this test verifies real timestamps }}, }, { @@ -268,7 +312,7 @@ var wantHistogramCheckpointSet = []*prompb.TimeSeries{ }, { Name: "__name__", - Value: "metric_name", + Value: "metric_histogram", }, { Name: "le", @@ -276,8 +320,8 @@ var wantHistogramCheckpointSet = []*prompb.TimeSeries{ }, }, Samples: []prompb.Sample{{ - Value: 500, - Timestamp: mockTime, + Value: 500, + // Timestamp: this test verifies real timestamps }}, }, { @@ -288,7 +332,7 @@ var wantHistogramCheckpointSet = []*prompb.TimeSeries{ }, { Name: "__name__", - Value: "metric_name", + Value: "metric_histogram", }, { Name: "le", @@ -296,8 +340,8 @@ var wantHistogramCheckpointSet = []*prompb.TimeSeries{ }, }, Samples: []prompb.Sample{{ - Value: 900, - Timestamp: mockTime, + Value: 900, + // Timestamp: this test verifies real timestamps }}, }, { @@ -308,7 +352,7 @@ var wantHistogramCheckpointSet = []*prompb.TimeSeries{ }, { Name: "__name__", - Value: "metric_name", + Value: "metric_histogram", }, { Name: "le", @@ -316,8 +360,12 @@ var wantHistogramCheckpointSet = []*prompb.TimeSeries{ }, }, Samples: []prompb.Sample{{ - Value: 1000, - Timestamp: mockTime, + Value: 1000, + // Timestamp: this test verifies real timestamps }}, }, } + +func toMillis(t time.Time) int64 { + return t.UnixNano() / int64(time.Millisecond) +} diff --git a/exporters/metric/cortex/utils/go.mod b/exporters/metric/cortex/utils/go.mod index 1bfbb876f8b..2a350b0f633 100644 --- a/exporters/metric/cortex/utils/go.mod +++ b/exporters/metric/cortex/utils/go.mod @@ -8,5 +8,5 @@ require ( github.com/spf13/afero v1.6.0 github.com/spf13/viper v1.8.1 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/exporters/metric/cortex v0.22.0 + go.opentelemetry.io/contrib/exporters/metric/cortex v0.23.0 ) diff --git a/exporters/metric/cortex/utils/go.sum b/exporters/metric/cortex/utils/go.sum index 70d58232e45..39e75f7973b 100644 --- a/exporters/metric/cortex/utils/go.sum +++ b/exporters/metric/cortex/utils/go.sum @@ -255,22 +255,18 @@ go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/sdk v1.0.0-RC1/go.mod h1:kj6yPn7Pgt5ByRuwesbaWcRLA+V7BSDg3Hf8xRvsvf8= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0 h1:6huidwh9LZi/+lvFw7EQ+m+pVmlfhOMd9s9PmTXAgeo= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0/go.mod h1:a14rf2CiHSn9xjB6cHuv0HoZGl5C4w2PAgl+Lja1VzU= -go.opentelemetry.io/otel/sdk/metric v0.22.0 h1:ZBagqeLlTgEmvxtaN3GkvmbmG+XWKDwS+amr8EsSMDo= -go.opentelemetry.io/otel/sdk/metric v0.22.0/go.mod h1:LzkI0G0z6KhEagqmzgk3bw/dglE2Tk2OXs455UMcI0s= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0 h1:7NeoKPPx6NdZBVHLEp/LY5Lq85Ff1WNZnuJkuRy+azw= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0/go.mod h1:SuMiREmKVRIwFKq73zvGTvwFpxb/ZAYkMfyqMoOtDqs= +go.opentelemetry.io/otel/sdk/metric v0.23.0 h1:xlZhPbiue1+jjSFEth94q9QCmX8Q24mOtue9IAmlVyI= +go.opentelemetry.io/otel/sdk/metric v0.23.0/go.mod h1:wa0sKK13eeIFW+0OFjcC3S1i7FTRRiLAXe1kjBVbhwg= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= diff --git a/exporters/metric/datadog/datadog.go b/exporters/metric/datadog/datadog.go index 4f5d1a8ab67..cfa1a35f597 100644 --- a/exporters/metric/datadog/datadog.go +++ b/exporters/metric/datadog/datadog.go @@ -21,6 +21,8 @@ import ( "github.com/DataDog/datadog-go/statsd" + "go.opentelemetry.io/otel/sdk/resource" + "go.opentelemetry.io/otel/attribute" "go.opentelemetry.io/otel/metric" "go.opentelemetry.io/otel/metric/number" @@ -93,12 +95,12 @@ func (e *Exporter) ExportKindFor(*metric.Descriptor, aggregation.Kind) export.Ex return export.DeltaExportKind } -func (e *Exporter) Export(ctx context.Context, cs export.CheckpointSet) error { +func (e *Exporter) Export(ctx context.Context, res *resource.Resource, cs export.CheckpointSet) error { return cs.ForEach(e, func(r export.Record) error { // TODO: Use the Resource() method agg := r.Aggregation() name := e.sanitizeMetricName(r.Descriptor().InstrumentationName(), r.Descriptor().Name()) - itr := attribute.NewMergeIterator(r.Labels(), r.Resource().Set()) + itr := attribute.NewMergeIterator(r.Labels(), res.Set()) tags := append([]string{}, e.opts.Tags...) for itr.Next() { attribute := itr.Label() diff --git a/exporters/metric/datadog/example_test.go b/exporters/metric/datadog/example_test.go index 328f6c405e9..2b741f2cacd 100644 --- a/exporters/metric/datadog/example_test.go +++ b/exporters/metric/datadog/example_test.go @@ -66,7 +66,7 @@ func ExampleExporter() { defer func() { handleErr(pusher.Stop(ctx)) }() global.SetMeterProvider(pusher.MeterProvider()) meter := global.Meter("marwandist") - m := metric.Must(meter).NewInt64ValueRecorder("myrecorder") + m := metric.Must(meter).NewInt64Histogram("myrecorder") meter.RecordBatch(context.Background(), []attribute.KeyValue{attribute.Int("l", 1)}, m.Measurement(1), m.Measurement(50), m.Measurement(100)) }() diff --git a/exporters/metric/datadog/go.mod b/exporters/metric/datadog/go.mod index b0b600a8fa0..d2d372942fc 100644 --- a/exporters/metric/datadog/go.mod +++ b/exporters/metric/datadog/go.mod @@ -5,7 +5,8 @@ go 1.15 require ( github.com/DataDog/datadog-go v3.7.2+incompatible go.opentelemetry.io/otel v1.0.0-RC3 - go.opentelemetry.io/otel/metric v0.22.0 - go.opentelemetry.io/otel/sdk/export/metric v0.22.0 - go.opentelemetry.io/otel/sdk/metric v0.22.0 + go.opentelemetry.io/otel/metric v0.23.0 + go.opentelemetry.io/otel/sdk v1.0.0-RC3 + go.opentelemetry.io/otel/sdk/export/metric v0.23.0 + go.opentelemetry.io/otel/sdk/metric v0.23.0 ) diff --git a/exporters/metric/datadog/go.sum b/exporters/metric/datadog/go.sum index 3a0cb85bb21..31f55c18056 100644 --- a/exporters/metric/datadog/go.sum +++ b/exporters/metric/datadog/go.sum @@ -12,23 +12,22 @@ github.com/stretchr/objx v0.1.0 h1:4G4v2dO3VZwixGIRoQ5Lfboy6nUhCyYzaqnIAPPhYs4= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/sdk v1.0.0-RC1 h1:Sy2VLOOg24bipyC29PhuMXYNJrLsxkie8hyI7kUlG9Q= -go.opentelemetry.io/otel/sdk v1.0.0-RC1/go.mod h1:kj6yPn7Pgt5ByRuwesbaWcRLA+V7BSDg3Hf8xRvsvf8= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0 h1:6huidwh9LZi/+lvFw7EQ+m+pVmlfhOMd9s9PmTXAgeo= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0/go.mod h1:a14rf2CiHSn9xjB6cHuv0HoZGl5C4w2PAgl+Lja1VzU= -go.opentelemetry.io/otel/sdk/metric v0.22.0 h1:ZBagqeLlTgEmvxtaN3GkvmbmG+XWKDwS+amr8EsSMDo= -go.opentelemetry.io/otel/sdk/metric v0.22.0/go.mod h1:LzkI0G0z6KhEagqmzgk3bw/dglE2Tk2OXs455UMcI0s= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= +go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= +go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0 h1:7NeoKPPx6NdZBVHLEp/LY5Lq85Ff1WNZnuJkuRy+azw= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0/go.mod h1:SuMiREmKVRIwFKq73zvGTvwFpxb/ZAYkMfyqMoOtDqs= +go.opentelemetry.io/otel/sdk/metric v0.23.0 h1:xlZhPbiue1+jjSFEth94q9QCmX8Q24mOtue9IAmlVyI= +go.opentelemetry.io/otel/sdk/metric v0.23.0/go.mod h1:wa0sKK13eeIFW+0OFjcC3S1i7FTRRiLAXe1kjBVbhwg= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= +golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7 h1:iGu644GcxtEcrInvDsQRCwJjtCIOlT2V7IRt6ah2Whw= +golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= diff --git a/exporters/metric/dogstatsd/dogstatsd_test.go b/exporters/metric/dogstatsd/dogstatsd_test.go index f48f4b26c44..a58d8774eb8 100644 --- a/exporters/metric/dogstatsd/dogstatsd_test.go +++ b/exporters/metric/dogstatsd/dogstatsd_test.go @@ -21,12 +21,14 @@ import ( "github.com/stretchr/testify/require" + export "go.opentelemetry.io/otel/sdk/export/metric" + controller "go.opentelemetry.io/otel/sdk/metric/controller/basic" + processor "go.opentelemetry.io/otel/sdk/metric/processor/basic" + "go.opentelemetry.io/otel/sdk/metric/processor/processortest" + "go.opentelemetry.io/contrib/exporters/metric/dogstatsd" "go.opentelemetry.io/otel/attribute" "go.opentelemetry.io/otel/metric" - "go.opentelemetry.io/otel/metric/number" - "go.opentelemetry.io/otel/sdk/export/metric/metrictest" - "go.opentelemetry.io/otel/sdk/metric/aggregator/sum" "go.opentelemetry.io/otel/sdk/resource" semconv "go.opentelemetry.io/otel/semconv/v1.4.0" ) @@ -48,44 +50,36 @@ func TestDogstatsAttributes(t *testing.T) { name: "no attributes", resources: nil, attributes: nil, - expected: "test.name:123|c\n", + expected: "test.sum:123|c\n", }, { name: "only resources", resources: attributes(attribute.String("R", "S")), attributes: nil, - expected: "test.name:123|c|#R:S\n", + expected: "test.sum:123|c|#R:S\n", }, { name: "only attributes", resources: nil, attributes: attributes(attribute.String("A", "B")), - expected: "test.name:123|c|#A:B\n", + expected: "test.sum:123|c|#A:B\n", }, { name: "both resources and attributes", resources: attributes(attribute.String("R", "S")), attributes: attributes(attribute.String("A", "B")), - expected: "test.name:123|c|#R:S,A:B\n", + expected: "test.sum:123|c|#R:S,A:B\n", }, { resources: attributes(attribute.String("A", "R")), attributes: attributes(attribute.String("A", "B")), - expected: "test.name:123|c|#A:R,A:B\n", + expected: "test.sum:123|c|#A:R,A:B\n", }, } for _, tc := range cases { t.Run(tc.name, func(t *testing.T) { res := resource.NewWithAttributes(semconv.SchemaURL, tc.resources...) ctx := context.Background() - checkpointSet := metrictest.NewCheckpointSet(res) - - desc := metric.NewDescriptor("test.name", metric.CounterInstrumentKind, number.Int64Kind) - cagg, cckpt := metrictest.Unslice2(sum.New(2)) - require.NoError(t, cagg.Update(ctx, number.NewInt64Number(123), &desc)) - require.NoError(t, cagg.SynchronizedMove(cckpt, &desc)) - - checkpointSet.Add(&desc, cckpt, tc.attributes...) var buf bytes.Buffer exp, err := dogstatsd.NewRawExporter(dogstatsd.Config{ @@ -93,8 +87,18 @@ func TestDogstatsAttributes(t *testing.T) { }) require.Nil(t, err) - err = exp.Export(ctx, checkpointSet) - require.Nil(t, err) + aggSel := processortest.AggregatorSelector() + proc := processor.New(aggSel, export.StatelessExportKindSelector()) + cont := controller.New(proc, + controller.WithExporter(exp), + controller.WithResource(res), + ) + require.NoError(t, cont.Start(ctx)) + meter := cont.MeterProvider().Meter("test") + counter := metric.Must(meter).NewInt64Counter("test.sum") + counter.Add(ctx, 123, tc.attributes...) + + require.NoError(t, cont.Stop(ctx)) require.Equal(t, tc.expected, buf.String()) }) diff --git a/exporters/metric/dogstatsd/example_test.go b/exporters/metric/dogstatsd/example_test.go index c7575399693..3502a0c838c 100644 --- a/exporters/metric/dogstatsd/example_test.go +++ b/exporters/metric/dogstatsd/example_test.go @@ -82,7 +82,7 @@ func ExampleNew() { // Create and update a single counter: counter := metric.Must(meter).NewInt64Counter("a.counter") - values := metric.Must(meter).NewInt64ValueRecorder("a.values") + values := metric.Must(meter).NewInt64Histogram("a.values") values.Record(ctx, 50, key.String("value")) counter.Add(ctx, 100, key.String("value")) diff --git a/exporters/metric/dogstatsd/go.mod b/exporters/metric/dogstatsd/go.mod index 48c890d02d4..eb241c27854 100644 --- a/exporters/metric/dogstatsd/go.mod +++ b/exporters/metric/dogstatsd/go.mod @@ -5,8 +5,8 @@ go 1.15 require ( github.com/stretchr/testify v1.7.0 go.opentelemetry.io/otel v1.0.0-RC3 - go.opentelemetry.io/otel/metric v0.22.0 + go.opentelemetry.io/otel/metric v0.23.0 go.opentelemetry.io/otel/sdk v1.0.0-RC3 - go.opentelemetry.io/otel/sdk/export/metric v0.22.0 - go.opentelemetry.io/otel/sdk/metric v0.22.0 + go.opentelemetry.io/otel/sdk/export/metric v0.23.0 + go.opentelemetry.io/otel/sdk/metric v0.23.0 ) diff --git a/exporters/metric/dogstatsd/go.sum b/exporters/metric/dogstatsd/go.sum index 59ed05c952b..1f278111cfd 100644 --- a/exporters/metric/dogstatsd/go.sum +++ b/exporters/metric/dogstatsd/go.sum @@ -9,22 +9,18 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/sdk v1.0.0-RC1/go.mod h1:kj6yPn7Pgt5ByRuwesbaWcRLA+V7BSDg3Hf8xRvsvf8= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0 h1:6huidwh9LZi/+lvFw7EQ+m+pVmlfhOMd9s9PmTXAgeo= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0/go.mod h1:a14rf2CiHSn9xjB6cHuv0HoZGl5C4w2PAgl+Lja1VzU= -go.opentelemetry.io/otel/sdk/metric v0.22.0 h1:ZBagqeLlTgEmvxtaN3GkvmbmG+XWKDwS+amr8EsSMDo= -go.opentelemetry.io/otel/sdk/metric v0.22.0/go.mod h1:LzkI0G0z6KhEagqmzgk3bw/dglE2Tk2OXs455UMcI0s= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0 h1:7NeoKPPx6NdZBVHLEp/LY5Lq85Ff1WNZnuJkuRy+azw= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0/go.mod h1:SuMiREmKVRIwFKq73zvGTvwFpxb/ZAYkMfyqMoOtDqs= +go.opentelemetry.io/otel/sdk/metric v0.23.0 h1:xlZhPbiue1+jjSFEth94q9QCmX8Q24mOtue9IAmlVyI= +go.opentelemetry.io/otel/sdk/metric v0.23.0/go.mod h1:wa0sKK13eeIFW+0OFjcC3S1i7FTRRiLAXe1kjBVbhwg= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7 h1:iGu644GcxtEcrInvDsQRCwJjtCIOlT2V7IRt6ah2Whw= diff --git a/exporters/metric/dogstatsd/internal/statsd/conn.go b/exporters/metric/dogstatsd/internal/statsd/conn.go index a764b99f661..8d500b85da1 100644 --- a/exporters/metric/dogstatsd/internal/statsd/conn.go +++ b/exporters/metric/dogstatsd/internal/statsd/conn.go @@ -170,7 +170,7 @@ func (e *Exporter) ExportKindFor(*metric.Descriptor, aggregation.Kind) export.Ex } // Export is common code for any statsd-based metric.Exporter implementation. -func (e *Exporter) Export(_ context.Context, checkpointSet export.CheckpointSet) error { +func (e *Exporter) Export(_ context.Context, res *resource.Resource, checkpointSet export.CheckpointSet) error { buf := &e.buffer buf.Reset() @@ -185,7 +185,7 @@ func (e *Exporter) Export(_ context.Context, checkpointSet export.CheckpointSet) for pt := 0; pt < pts; pt++ { before := buf.Len() - if err := e.formatMetric(rec, pt, buf); err != nil { + if err := e.formatMetric(rec, res, pt, buf); err != nil { return err } @@ -253,10 +253,9 @@ func (e *Exporter) countPoints(rec export.Record) (int, error) { // formatMetric formats an individual export record. For some records // this will emit a single statistic, for some it will emit more than // one. -func (e *Exporter) formatMetric(rec export.Record, pos int, buf *bytes.Buffer) error { +func (e *Exporter) formatMetric(rec export.Record, res *resource.Resource, pos int, buf *bytes.Buffer) error { desc := rec.Descriptor() agg := rec.Aggregation() - res := rec.Resource() // TODO handle non-Points Distribution/MaxSumCount by // formatting individual quantiles, the sum, and the count as // single statistics. For the dogstatsd variation, assuming diff --git a/exporters/metric/dogstatsd/internal/statsd/conn_test.go b/exporters/metric/dogstatsd/internal/statsd/conn_test.go index b7c22681181..e0c12406bd6 100644 --- a/exporters/metric/dogstatsd/internal/statsd/conn_test.go +++ b/exporters/metric/dogstatsd/internal/statsd/conn_test.go @@ -17,9 +17,10 @@ package statsd_test import ( "bytes" "context" + "errors" "fmt" - "strconv" "strings" + "sync" "testing" "github.com/stretchr/testify/require" @@ -28,17 +29,55 @@ import ( "go.opentelemetry.io/otel/attribute" "go.opentelemetry.io/otel/metric" "go.opentelemetry.io/otel/metric/number" - "go.opentelemetry.io/otel/metric/unit" export "go.opentelemetry.io/otel/sdk/export/metric" - "go.opentelemetry.io/otel/sdk/export/metric/metrictest" - aggtest "go.opentelemetry.io/otel/sdk/metric/aggregator/aggregatortest" + "go.opentelemetry.io/otel/sdk/export/metric/aggregation" "go.opentelemetry.io/otel/sdk/metric/aggregator/exact" "go.opentelemetry.io/otel/sdk/metric/aggregator/lastvalue" "go.opentelemetry.io/otel/sdk/metric/aggregator/sum" + controller "go.opentelemetry.io/otel/sdk/metric/controller/basic" + processor "go.opentelemetry.io/otel/sdk/metric/processor/basic" "go.opentelemetry.io/otel/sdk/resource" semconv "go.opentelemetry.io/otel/semconv/v1.4.0" ) +func testMeter(t *testing.T, exp export.Exporter) (context.Context, metric.Meter, *processor.Processor, *controller.Controller) { + aggSel := testAggregatorSelector{} + proc := processor.New(aggSel, export.CumulativeExportKindSelector()) + cont := controller.New(proc, + controller.WithResource(testResource), + controller.WithExporter(exp), + ) + ctx := context.Background() + + return ctx, cont.MeterProvider().Meter("test"), proc, cont +} + +type testAggregatorSelector struct { +} + +func (testAggregatorSelector) AggregatorFor(desc *metric.Descriptor, aggPtrs ...*export.Aggregator) { + switch { + case strings.HasSuffix(desc.Name(), "counter"): + aggs := sum.New(len(aggPtrs)) + for i := range aggPtrs { + *aggPtrs[i] = &aggs[i] + } + case strings.HasSuffix(desc.Name(), "gauge"): + aggs := lastvalue.New(len(aggPtrs)) + for i := range aggPtrs { + *aggPtrs[i] = &aggs[i] + } + case strings.HasSuffix(desc.Name(), "histogram") || + strings.HasSuffix(desc.Name(), "timer"): + aggs := exact.New(len(aggPtrs)) + for i := range aggPtrs { + *aggPtrs[i] = &aggs[i] + } + default: + panic(fmt.Sprint("Invalid instrument name for test AggregatorSelector: ", desc.Name())) + } +} + var testResource = resource.NewWithAttributes(semconv.SchemaURL, attribute.String("host", "value")) // withTagsAdapter tests a dogstatsd-style statsd exporter. @@ -97,22 +136,28 @@ func (w *testWriter) Write(b []byte) (int, error) { func TestBasicFormat(t *testing.T) { type adapterOutput struct { adapter statsd.Adapter - expected string + expected []string } - for _, ao := range []adapterOutput{{ - adapter: newWithTagsAdapter(), - expected: `counter:%s|c|#A=B,C=D -observer:%s|g|#A=B,C=D -measure:%s|h|#A=B,C=D -timer:%s|ms|#A=B,C=D -`}, { - adapter: newNoTagsAdapter(), - expected: `counter.B.D:%s|c -observer.B.D:%s|g -measure.B.D:%s|h -timer.B.D:%s|ms -`}, + for _, ao := range []adapterOutput{ + { + adapter: newWithTagsAdapter(), + expected: []string{ + "counter:%s|c|#A=B,C=D", + "gauge:%s|g|#A=B,C=D", + "histogram:%s|h|#A=B,C=D", + "timer:%s|ms|#A=B,C=D", + }, + }, + { + adapter: newNoTagsAdapter(), + expected: []string{ + "counter.B.D:%s|c", + "gauge.B.D:%s|g", + "histogram.B.D:%s|h", + "timer.B.D:%s|ms", + }, + }, } { adapter := ao.adapter expected := ao.expected @@ -122,7 +167,6 @@ timer.B.D:%s|ms number.Int64Kind, } { t.Run(nkind.String(), func(t *testing.T) { - ctx := context.Background() writer := &testWriter{} config := statsd.Config{ Writer: writer, @@ -132,72 +176,89 @@ timer.B.D:%s|ms if err != nil { t.Fatal("New error: ", err) } - - checkpointSet := metrictest.NewCheckpointSet(testResource) - cdesc := metric.NewDescriptor( - "counter", metric.CounterInstrumentKind, nkind) - gdesc := metric.NewDescriptor( - "observer", metric.ValueObserverInstrumentKind, nkind) - mdesc := metric.NewDescriptor( - "measure", metric.ValueRecorderInstrumentKind, nkind) - tdesc := metric.NewDescriptor( - "timer", metric.ValueRecorderInstrumentKind, nkind, metric.WithUnit(unit.Milliseconds)) + ctx, meter, _, cont := testMeter(t, exp) + require.NoError(t, cont.Start(ctx)) attributes := []attribute.KeyValue{ attribute.String("A", "B"), attribute.String("C", "D"), } - const value = 123.456 - val := newNumber(t, nkind, value) - - cagg, cckpt := metrictest.Unslice2(sum.New(2)) - gagg, gckpt := metrictest.Unslice2(lastvalue.New(2)) - magg, mckpt := metrictest.Unslice2(exact.New(2)) - tagg, tckpt := metrictest.Unslice2(exact.New(2)) - - aggtest.CheckedUpdate(t, cagg, val, &cdesc) - aggtest.CheckedUpdate(t, gagg, val, &gdesc) - aggtest.CheckedUpdate(t, magg, val, &mdesc) - aggtest.CheckedUpdate(t, tagg, val, &tdesc) - - require.NoError(t, cagg.SynchronizedMove(cckpt, &cdesc)) - require.NoError(t, gagg.SynchronizedMove(gckpt, &gdesc)) - require.NoError(t, magg.SynchronizedMove(mckpt, &mdesc)) - require.NoError(t, tagg.SynchronizedMove(tckpt, &tdesc)) - checkpointSet.Add(&cdesc, cckpt, attributes...) - checkpointSet.Add(&gdesc, gckpt, attributes...) - checkpointSet.Add(&mdesc, mckpt, attributes...) - checkpointSet.Add(&tdesc, tckpt, attributes...) - - err = exp.Export(ctx, checkpointSet) - require.Nil(t, err) - - var vfmt string if nkind == number.Int64Kind { - fv := value - vfmt = strconv.FormatInt(int64(fv), 10) + counter := metric.Must(meter).NewInt64Counter("counter") + _ = metric.Must(meter).NewInt64GaugeObserver("gauge", + func(_ context.Context, res metric.Int64ObserverResult) { + res.Observe(2, attributes...) + }) + histo := metric.Must(meter).NewInt64Histogram("histogram") + timer := metric.Must(meter).NewInt64Histogram("timer", metric.WithUnit("ms")) + counter.Add(ctx, 2, attributes...) + histo.Record(ctx, 2, attributes...) + timer.Record(ctx, 2, attributes...) } else { - vfmt = strconv.FormatFloat(value, 'g', -1, 64) + counter := metric.Must(meter).NewFloat64Counter("counter") + _ = metric.Must(meter).NewFloat64GaugeObserver("gauge", + func(_ context.Context, res metric.Float64ObserverResult) { + res.Observe(2, attributes...) + }) + histo := metric.Must(meter).NewFloat64Histogram("histogram") + timer := metric.Must(meter).NewFloat64Histogram("timer", metric.WithUnit("ms")) + counter.Add(ctx, 2, attributes...) + histo.Record(ctx, 2, attributes...) + timer.Record(ctx, 2, attributes...) } + require.NoError(t, cont.Stop(ctx)) require.Equal(t, 1, len(writer.vec)) - require.Equal(t, fmt.Sprintf(expected, vfmt, vfmt, vfmt, vfmt), writer.vec[0]) + + // Note we do not know the order metrics will be sent. + wantStrings := map[string]bool{} + haveStrings := map[string]bool{} + + for _, wt := range expected { + wantStrings[fmt.Sprintf(wt, "2")] = true + } + for _, hv := range strings.Split(writer.vec[0], "\n") { + if len(hv) != 0 { + haveStrings[hv] = true + } + } + + require.EqualValues(t, wantStrings, haveStrings) + }) } }) } } -func newNumber(t *testing.T, kind number.Kind, value float64) number.Number { - t.Helper() - switch kind { - case number.Int64Kind: - return number.NewInt64Number(int64(value)) - case number.Float64Kind: - return number.NewFloat64Number(value) +// Note: this test requires an reader interface with ordered delivery, +// which the SDK does not provide. these test helpers could become +// part of "processortest" after +// https://github.com/open-telemetry/opentelemetry-go/pull/2197 +// merges. + +type orderedReader struct { + // RWMutex implements locking for the `CheckpointSet` interface. + sync.RWMutex + ordered []export.CheckpointSet +} + +func newOrderedReader() *orderedReader { + return &orderedReader{} +} + +func (p *orderedReader) add(c export.CheckpointSet) { + p.ordered = append(p.ordered, c) +} + +func (p *orderedReader) ForEach(k export.ExportKindSelector, f func(export.Record) error) error { + for _, r := range p.ordered { + if err := r.ForEach(k, f); err != nil && !errors.Is(err, aggregation.ErrNoData) { + return err + } } - panic("invalid number kind") + return nil } func makeAttributes(offset, nkeys int) []attribute.KeyValue { @@ -214,13 +275,15 @@ type splitTestCase struct { check func(expected, got []string, t *testing.T) } +const large = 1000 + var splitTestCases = []splitTestCase{ // These test use the number of keys to control where packets // are split. {"Simple", func(add func(int)) { add(1) - add(1000) + add(large) add(1) }, func(expected, got []string, t *testing.T) { @@ -231,7 +294,7 @@ var splitTestCases = []splitTestCase{ func(add func(int)) { add(1) add(1) - add(1000) + add(large) }, func(expected, got []string, t *testing.T) { require.Equal(t, 2, len(got)) @@ -243,10 +306,10 @@ var splitTestCases = []splitTestCase{ }, {"FirstBig", func(add func(int)) { - add(1000) + add(large) add(1) add(1) - add(1000) + add(large) add(1) add(1) }, @@ -262,7 +325,7 @@ var splitTestCases = []splitTestCase{ }, {"OneBig", func(add func(int)) { - add(1000) + add(large) }, func(expected, got []string, t *testing.T) { require.EqualValues(t, expected, got) @@ -270,7 +333,7 @@ var splitTestCases = []splitTestCase{ }, {"LastSmall", func(add func(int)) { - add(1000) + add(large) add(1) }, func(expected, got []string, t *testing.T) { @@ -279,7 +342,7 @@ var splitTestCases = []splitTestCase{ }, {"Overflow", func(add func(int)) { - for i := 0; i < 1000; i++ { + for i := 0; i < large; i++ { add(1) } }, @@ -297,9 +360,9 @@ var splitTestCases = []splitTestCase{ }, {"AllBig", func(add func(int)) { - add(1000) - add(1000) - add(1000) + add(large) + add(large) + add(large) }, func(expected, got []string, t *testing.T) { require.EqualValues(t, expected, got) @@ -322,8 +385,7 @@ func TestPacketSplit(t *testing.T) { t.Fatal("New error: ", err) } - checkpointSet := metrictest.NewCheckpointSet(testResource) - desc := metric.NewDescriptor("counter", metric.CounterInstrumentKind, number.Int64Kind) + orderedReader := newOrderedReader() var expected []string @@ -335,13 +397,18 @@ func TestPacketSplit(t *testing.T) { encoded := adapter.Encoder.Encode(eattributes.Iter()) expect := fmt.Sprint("counter:100|c|#", encoded, "\n") expected = append(expected, expect) - agg, ckpt := metrictest.Unslice2(sum.New(2)) - aggtest.CheckedUpdate(t, agg, number.NewInt64Number(100), &desc) - require.NoError(t, agg.SynchronizedMove(ckpt, &desc)) - checkpointSet.Add(&desc, ckpt, attributes...) + + ctx, meter, proc, cont := testMeter(t, nil) + + counter := metric.Must(meter).NewInt64Counter("counter") + counter.Add(ctx, 100, attributes...) + + require.NoError(t, cont.Collect(ctx)) + + orderedReader.add(proc.CheckpointSet()) }) - err = exp.Export(ctx, checkpointSet) + err = exp.Export(ctx, testResource, orderedReader) require.Nil(t, err) tcase.check(expected, writer.vec, t) @@ -350,7 +417,6 @@ func TestPacketSplit(t *testing.T) { } func TestExactSplit(t *testing.T) { - ctx := context.Background() writer := &testWriter{} config := statsd.Config{ Writer: writer, @@ -362,19 +428,15 @@ func TestExactSplit(t *testing.T) { t.Fatal("New error: ", err) } - checkpointSet := metrictest.NewCheckpointSet(testResource) - desc := metric.NewDescriptor("measure", metric.ValueRecorderInstrumentKind, number.Int64Kind) - - agg, ckpt := metrictest.Unslice2(exact.New(2)) + ctx, meter, _, cont := testMeter(t, exp) + histo := metric.Must(meter).NewInt64Histogram("histogram") + require.NoError(t, cont.Start(ctx)) for i := 0; i < 1024; i++ { - aggtest.CheckedUpdate(t, agg, number.NewInt64Number(100), &desc) + histo.Record(ctx, 100) } - require.NoError(t, agg.SynchronizedMove(ckpt, &desc)) - checkpointSet.Add(&desc, ckpt) - err = exp.Export(ctx, checkpointSet) - require.Nil(t, err) + require.NoError(t, cont.Stop(ctx)) require.Greater(t, len(writer.vec), 1) @@ -384,7 +446,6 @@ func TestExactSplit(t *testing.T) { } func TestPrefix(t *testing.T) { - ctx := context.Background() writer := &testWriter{} config := statsd.Config{ Writer: writer, @@ -397,17 +458,14 @@ func TestPrefix(t *testing.T) { t.Fatal("New error: ", err) } - checkpointSet := metrictest.NewCheckpointSet(testResource) - desc := metric.NewDescriptor("measure", metric.ValueRecorderInstrumentKind, number.Int64Kind) + ctx, meter, _, cont := testMeter(t, exp) + histo := metric.Must(meter).NewInt64Histogram("histogram") + require.NoError(t, cont.Start(ctx)) - agg, ckpt := metrictest.Unslice2(exact.New(2)) - aggtest.CheckedUpdate(t, agg, number.NewInt64Number(100), &desc) - require.NoError(t, agg.SynchronizedMove(ckpt, &desc)) - checkpointSet.Add(&desc, ckpt) + histo.Record(ctx, 100) - err = exp.Export(ctx, checkpointSet) - require.Nil(t, err) + require.NoError(t, cont.Stop(ctx)) - require.Equal(t, `veryspecial.measure:100|h|# + require.Equal(t, `veryspecial.histogram:100|h|# `, strings.Join(writer.vec, "")) } diff --git a/instrumentation/github.com/Shopify/sarama/otelsarama/example/go.mod b/instrumentation/github.com/Shopify/sarama/otelsarama/example/go.mod index b57f3a71fe7..ca0b5cc3104 100644 --- a/instrumentation/github.com/Shopify/sarama/otelsarama/example/go.mod +++ b/instrumentation/github.com/Shopify/sarama/otelsarama/example/go.mod @@ -9,7 +9,7 @@ replace ( require ( github.com/Shopify/sarama v1.29.1 - go.opentelemetry.io/contrib/instrumentation/github.com/Shopify/sarama/otelsarama v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/Shopify/sarama/otelsarama v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 diff --git a/instrumentation/github.com/Shopify/sarama/otelsarama/go.mod b/instrumentation/github.com/Shopify/sarama/otelsarama/go.mod index 00d5cc2b165..b984c10fa56 100644 --- a/instrumentation/github.com/Shopify/sarama/otelsarama/go.mod +++ b/instrumentation/github.com/Shopify/sarama/otelsarama/go.mod @@ -7,7 +7,7 @@ replace go.opentelemetry.io/contrib => ../../../../.. require ( github.com/Shopify/sarama v1.28.0 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib v0.22.0 + go.opentelemetry.io/contrib v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) diff --git a/instrumentation/github.com/Shopify/sarama/otelsarama/test/go.mod b/instrumentation/github.com/Shopify/sarama/otelsarama/test/go.mod index c7ba574f094..2c9016b571e 100644 --- a/instrumentation/github.com/Shopify/sarama/otelsarama/test/go.mod +++ b/instrumentation/github.com/Shopify/sarama/otelsarama/test/go.mod @@ -5,10 +5,12 @@ go 1.15 require ( github.com/Shopify/sarama v1.29.1 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/instrumentation/github.com/Shopify/sarama/otelsarama v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/Shopify/sarama/otelsarama v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) replace go.opentelemetry.io/contrib/instrumentation/github.com/Shopify/sarama/otelsarama => ../ + +replace go.opentelemetry.io/contrib => ../../../../../../ diff --git a/instrumentation/github.com/Shopify/sarama/otelsarama/test/go.sum b/instrumentation/github.com/Shopify/sarama/otelsarama/test/go.sum index ca285c4aa74..4aa22882192 100644 --- a/instrumentation/github.com/Shopify/sarama/otelsarama/test/go.sum +++ b/instrumentation/github.com/Shopify/sarama/otelsarama/test/go.sum @@ -65,8 +65,6 @@ github.com/xdg/scram v0.0.0-20180814205039-7eeb5667e42c/go.mod h1:lB8K/P019DLNhe github.com/xdg/scram v1.0.3/go.mod h1:lB8K/P019DLNhemzwFU4jHLhdvlE6uDZjXFejJXr49I= github.com/xdg/stringprep v1.0.0/go.mod h1:Jhud4/sHMO4oL310DaZAKk9ZaJ08SJfe+sJh0HrGL1Y= github.com/xdg/stringprep v1.0.3/go.mod h1:Jhud4/sHMO4oL310DaZAKk9ZaJ08SJfe+sJh0HrGL1Y= -go.opentelemetry.io/contrib v0.22.0 h1:0F7gDEjgb1WGn4ODIjaCAg75hmqF+UN0LiVgwxsCodc= -go.opentelemetry.io/contrib v0.22.0/go.mod h1:EH4yDYeNoaTqn/8yCWQmfNB78VHfGX2Jt2bvnvzBlGM= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= diff --git a/instrumentation/github.com/astaxie/beego/otelbeego/example/go.mod b/instrumentation/github.com/astaxie/beego/otelbeego/example/go.mod index 2e6eca7318b..97e55b567de 100644 --- a/instrumentation/github.com/astaxie/beego/otelbeego/example/go.mod +++ b/instrumentation/github.com/astaxie/beego/otelbeego/example/go.mod @@ -11,7 +11,7 @@ replace ( require ( github.com/astaxie/beego v1.12.3 - go.opentelemetry.io/contrib/instrumentation/github.com/astaxie/beego/otelbeego v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/astaxie/beego/otelbeego v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 diff --git a/instrumentation/github.com/astaxie/beego/otelbeego/example/go.sum b/instrumentation/github.com/astaxie/beego/otelbeego/example/go.sum index 3a30ca4cdde..0b8a0da5b1e 100644 --- a/instrumentation/github.com/astaxie/beego/otelbeego/example/go.sum +++ b/instrumentation/github.com/astaxie/beego/otelbeego/example/go.sum @@ -142,19 +142,16 @@ github.com/syndtr/goleveldb v0.0.0-20181127023241-353a9fca669c/go.mod h1:Z4AUp2K github.com/ugorji/go v0.0.0-20171122102828-84cb69a8af83/go.mod h1:hnLbHMwcvSihnDhEfx2/BzKp2xb0Y+ErdfYcrs9tkJQ= github.com/wendal/errors v0.0.0-20130201093226-f66c77a7882b/go.mod h1:Q12BUT7DqIlHRmgv3RskH+UCM/4eqVMgI0EMmlSpAXc= github.com/yuin/gopher-lua v0.0.0-20171031051903-609c9cd26973/go.mod h1:aEV29XrmTYFr3CiRxZeGHpkvbwq+prZduBqMaascyCU= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 h1:ewSzc2SagdOx0up5xZPigXh1n3SLsNEslc5edHRBVcs= go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3/go.mod h1:Oxmrmpdvm6lM3tkYmHKGWAhi9+9c2rrAEbwSDn0Bvv8= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= diff --git a/instrumentation/github.com/astaxie/beego/otelbeego/go.mod b/instrumentation/github.com/astaxie/beego/otelbeego/go.mod index 27a4a6f58b1..ff9c17678aa 100644 --- a/instrumentation/github.com/astaxie/beego/otelbeego/go.mod +++ b/instrumentation/github.com/astaxie/beego/otelbeego/go.mod @@ -11,9 +11,9 @@ replace ( require ( github.com/astaxie/beego v1.12.3 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.22.0 + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 - go.opentelemetry.io/otel/metric v0.22.0 + go.opentelemetry.io/otel/metric v0.23.0 go.opentelemetry.io/otel/trace v1.0.0-RC3 golang.org/x/net v0.0.0-20200707034311-ab3426394381 // indirect golang.org/x/sys v0.0.0-20200803210538-64077c9b5642 // indirect diff --git a/instrumentation/github.com/astaxie/beego/otelbeego/go.sum b/instrumentation/github.com/astaxie/beego/otelbeego/go.sum index 4f3e2b825a6..ec430b1a8cc 100644 --- a/instrumentation/github.com/astaxie/beego/otelbeego/go.sum +++ b/instrumentation/github.com/astaxie/beego/otelbeego/go.sum @@ -142,15 +142,12 @@ github.com/syndtr/goleveldb v0.0.0-20181127023241-353a9fca669c/go.mod h1:Z4AUp2K github.com/ugorji/go v0.0.0-20171122102828-84cb69a8af83/go.mod h1:hnLbHMwcvSihnDhEfx2/BzKp2xb0Y+ErdfYcrs9tkJQ= github.com/wendal/errors v0.0.0-20130201093226-f66c77a7882b/go.mod h1:Q12BUT7DqIlHRmgv3RskH+UCM/4eqVMgI0EMmlSpAXc= github.com/yuin/gopher-lua v0.0.0-20171031051903-609c9cd26973/go.mod h1:aEV29XrmTYFr3CiRxZeGHpkvbwq+prZduBqMaascyCU= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= diff --git a/instrumentation/github.com/astaxie/beego/otelbeego/test/go.mod b/instrumentation/github.com/astaxie/beego/otelbeego/test/go.mod index 7a3aec3010d..399470025ac 100644 --- a/instrumentation/github.com/astaxie/beego/otelbeego/test/go.mod +++ b/instrumentation/github.com/astaxie/beego/otelbeego/test/go.mod @@ -5,13 +5,16 @@ go 1.15 require ( github.com/astaxie/beego v1.12.3 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/instrumentation/github.com/astaxie/beego/otelbeego v0.22.0 - go.opentelemetry.io/contrib/propagators/b3 v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/astaxie/beego/otelbeego v0.23.0 + go.opentelemetry.io/contrib/propagators/b3 v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 - go.opentelemetry.io/otel/metric v0.22.0 + go.opentelemetry.io/otel/metric v0.23.0 go.opentelemetry.io/otel/sdk v1.0.0-RC3 ) -replace go.opentelemetry.io/contrib/instrumentation/github.com/astaxie/beego/otelbeego => ../ - -replace go.opentelemetry.io/contrib/propagators/b3 => ../../../../../../propagators/b3 +replace ( + go.opentelemetry.io/contrib => ../../../../../../ + go.opentelemetry.io/contrib/instrumentation/github.com/astaxie/beego/otelbeego => ../ + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp => ../../../../../net/http/otelhttp + go.opentelemetry.io/contrib/propagators/b3 => ../../../../../../propagators/b3 +) diff --git a/instrumentation/github.com/astaxie/beego/otelbeego/test/go.sum b/instrumentation/github.com/astaxie/beego/otelbeego/test/go.sum index 48f955d443b..b1930dfa531 100644 --- a/instrumentation/github.com/astaxie/beego/otelbeego/test/go.sum +++ b/instrumentation/github.com/astaxie/beego/otelbeego/test/go.sum @@ -142,25 +142,14 @@ github.com/syndtr/goleveldb v0.0.0-20181127023241-353a9fca669c/go.mod h1:Z4AUp2K github.com/ugorji/go v0.0.0-20171122102828-84cb69a8af83/go.mod h1:hnLbHMwcvSihnDhEfx2/BzKp2xb0Y+ErdfYcrs9tkJQ= github.com/wendal/errors v0.0.0-20130201093226-f66c77a7882b/go.mod h1:Q12BUT7DqIlHRmgv3RskH+UCM/4eqVMgI0EMmlSpAXc= github.com/yuin/gopher-lua v0.0.0-20171031051903-609c9cd26973/go.mod h1:aEV29XrmTYFr3CiRxZeGHpkvbwq+prZduBqMaascyCU= -go.opentelemetry.io/contrib v0.22.0 h1:0F7gDEjgb1WGn4ODIjaCAg75hmqF+UN0LiVgwxsCodc= -go.opentelemetry.io/contrib v0.22.0/go.mod h1:EH4yDYeNoaTqn/8yCWQmfNB78VHfGX2Jt2bvnvzBlGM= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.22.0 h1:WHjZguqT+3UjTgFum33hWZYybDVnx8u9q5/kQDfaGTs= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.22.0/go.mod h1:o3MuU25bYroYnc2TOKe8mTk8f9X1oPFO6C5RCoPKtSU= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= -go.opentelemetry.io/otel v1.0.0-RC2/go.mod h1:w1thVQ7qbAy8MHb0IFj8a5Q2QU0l2ksf8u/CN8m3NOM= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/oteltest v1.0.0-RC2 h1:xNKqMhlZYkASSyvF4JwObZFMq0jhFN3c3SP+2rCzVPk= -go.opentelemetry.io/otel/oteltest v1.0.0-RC2/go.mod h1:kiQ4tw5tAL4JLTbcOYwK1CWI1HkT5aiLzHovgOVnz/A= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= -go.opentelemetry.io/otel/trace v1.0.0-RC2/go.mod h1:JPQ+z6nNw9mqEGT8o3eoPTdnNI+Aj5JcxEsVGREIAy4= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= diff --git a/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/example/go.mod b/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/example/go.mod index c7b3a982b0e..056f11eb1b9 100644 --- a/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/example/go.mod +++ b/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/example/go.mod @@ -12,7 +12,7 @@ require ( github.com/aws/aws-sdk-go-v2/config v1.7.0 github.com/aws/aws-sdk-go-v2/service/dynamodb v1.5.0 github.com/aws/aws-sdk-go-v2/service/s3 v1.14.0 - go.opentelemetry.io/contrib/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 diff --git a/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/go.mod b/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/go.mod index e96a30e671c..b954d893269 100644 --- a/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/go.mod +++ b/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/go.mod @@ -7,7 +7,7 @@ replace go.opentelemetry.io/contrib => ../../../../../ require ( github.com/aws/aws-sdk-go-v2 v1.9.0 github.com/aws/smithy-go v1.8.0 - go.opentelemetry.io/contrib v0.22.0 + go.opentelemetry.io/contrib v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) diff --git a/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/test/go.mod b/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/test/go.mod index d7b113b456c..02d0589bcfe 100644 --- a/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/test/go.mod +++ b/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/test/go.mod @@ -6,10 +6,12 @@ require ( github.com/aws/aws-sdk-go-v2 v1.9.0 github.com/aws/aws-sdk-go-v2/service/route53 v1.11.0 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) -replace go.opentelemetry.io/contrib/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/test => ../ +replace go.opentelemetry.io/contrib/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws => ../ + +replace go.opentelemetry.io/contrib => ../../../../../../ diff --git a/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/test/go.sum b/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/test/go.sum index b4d4832ea3e..0db867cce51 100644 --- a/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/test/go.sum +++ b/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/test/go.sum @@ -1,15 +1,11 @@ -github.com/aws/aws-sdk-go-v2 v1.2.0/go.mod h1:zEQs02YRBw1DjK0PoJv3ygDYOFTre1ejlJWl8FwAuQo= github.com/aws/aws-sdk-go-v2 v1.9.0 h1:+S+dSqQCN3MSU5vJRu1HqHrq00cJn6heIMU7X9hcsoo= github.com/aws/aws-sdk-go-v2 v1.9.0/go.mod h1:cK/D0BBs0b/oWPIcX/Z/obahJK1TT7IPVjy53i/mX/4= -github.com/aws/aws-sdk-go-v2/service/route53 v1.1.1/go.mod h1:rLiOUrPLW/Er5kRcQ7NkwbjlijluLsrIbu/iyl35RO4= github.com/aws/aws-sdk-go-v2/service/route53 v1.11.0 h1:ln96cDRu9EQ3eimO+f/uoRFYmlrDKobg9ZuGaQnySPA= github.com/aws/aws-sdk-go-v2/service/route53 v1.11.0/go.mod h1:Cg8YePMd3RWeYrH77tXlIfUdbaEXPsjlCaWYkfByj2I= -github.com/aws/smithy-go v1.1.0/go.mod h1:EzMw8dbp/YJL4A5/sbhGddag+NPT7q084agLbB9LgIw= github.com/aws/smithy-go v1.8.0 h1:AEwwwXQZtUwP5Mz506FeXXrKBe0jA8gVM+1gEcSRooc= github.com/aws/smithy-go v1.8.0/go.mod h1:SObp3lf9smib00L/v3U2eAKG8FyQ7iLrJnQiAmR5n+E= github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/google/go-cmp v0.4.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ= github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= @@ -22,18 +18,10 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/contrib v0.22.0 h1:0F7gDEjgb1WGn4ODIjaCAg75hmqF+UN0LiVgwxsCodc= -go.opentelemetry.io/contrib v0.22.0/go.mod h1:EH4yDYeNoaTqn/8yCWQmfNB78VHfGX2Jt2bvnvzBlGM= -go.opentelemetry.io/contrib/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws v0.22.0 h1:yvHsET05+W6mGbiBmpzeSNfguFl7wdGc7wnZzL6oXZg= -go.opentelemetry.io/contrib/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws v0.22.0/go.mod h1:SYNRbn31XulM3soVaBCla9PC47il0lxsiIVPGVDdJLE= -go.opentelemetry.io/otel v1.0.0-RC2/go.mod h1:w1thVQ7qbAy8MHb0IFj8a5Q2QU0l2ksf8u/CN8m3NOM= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/oteltest v1.0.0-RC2 h1:xNKqMhlZYkASSyvF4JwObZFMq0jhFN3c3SP+2rCzVPk= -go.opentelemetry.io/otel/oteltest v1.0.0-RC2/go.mod h1:kiQ4tw5tAL4JLTbcOYwK1CWI1HkT5aiLzHovgOVnz/A= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/trace v1.0.0-RC2/go.mod h1:JPQ+z6nNw9mqEGT8o3eoPTdnNI+Aj5JcxEsVGREIAy4= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7 h1:iGu644GcxtEcrInvDsQRCwJjtCIOlT2V7IRt6ah2Whw= diff --git a/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache/example/go.mod b/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache/example/go.mod index dcba533a1c0..1163720bec8 100644 --- a/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache/example/go.mod +++ b/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache/example/go.mod @@ -9,7 +9,7 @@ replace ( require ( github.com/bradfitz/gomemcache v0.0.0-20190913173617-a41fca850d0b - go.opentelemetry.io/contrib/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache v0.23.0 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 ) diff --git a/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache/go.mod b/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache/go.mod index e471a22bf0b..9963592bb65 100644 --- a/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache/go.mod +++ b/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache/go.mod @@ -7,7 +7,7 @@ replace go.opentelemetry.io/contrib => ../../../../../../ require ( github.com/bradfitz/gomemcache v0.0.0-20190913173617-a41fca850d0b github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib v0.22.0 + go.opentelemetry.io/contrib v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) diff --git a/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache/test/go.mod b/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache/test/go.mod index 53858850350..b867d2f1e7a 100644 --- a/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache/test/go.mod +++ b/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache/test/go.mod @@ -5,8 +5,8 @@ go 1.15 require ( github.com/bradfitz/gomemcache v0.0.0-20190913173617-a41fca850d0b github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib v0.22.0 - go.opentelemetry.io/contrib/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache v0.22.0 + go.opentelemetry.io/contrib v0.23.0 + go.opentelemetry.io/contrib/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 diff --git a/instrumentation/github.com/emicklei/go-restful/otelrestful/example/go.mod b/instrumentation/github.com/emicklei/go-restful/otelrestful/example/go.mod index 6245d5e1357..30caaf63df2 100644 --- a/instrumentation/github.com/emicklei/go-restful/otelrestful/example/go.mod +++ b/instrumentation/github.com/emicklei/go-restful/otelrestful/example/go.mod @@ -10,7 +10,7 @@ replace ( require ( github.com/emicklei/go-restful/v3 v3.5.2 - go.opentelemetry.io/contrib/instrumentation/github.com/emicklei/go-restful/otelrestful v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/emicklei/go-restful/otelrestful v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 diff --git a/instrumentation/github.com/emicklei/go-restful/otelrestful/go.mod b/instrumentation/github.com/emicklei/go-restful/otelrestful/go.mod index 286bae3fd64..3f435a9901a 100644 --- a/instrumentation/github.com/emicklei/go-restful/otelrestful/go.mod +++ b/instrumentation/github.com/emicklei/go-restful/otelrestful/go.mod @@ -11,8 +11,8 @@ require ( github.com/emicklei/go-restful/v3 v3.5.2 github.com/json-iterator/go v1.1.10 // indirect github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib v0.22.0 - go.opentelemetry.io/contrib/propagators/b3 v0.22.0 + go.opentelemetry.io/contrib v0.23.0 + go.opentelemetry.io/contrib/propagators/b3 v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) diff --git a/instrumentation/github.com/emicklei/go-restful/otelrestful/test/go.mod b/instrumentation/github.com/emicklei/go-restful/otelrestful/test/go.mod index ae8a650c582..b5ae95ba0dc 100644 --- a/instrumentation/github.com/emicklei/go-restful/otelrestful/test/go.mod +++ b/instrumentation/github.com/emicklei/go-restful/otelrestful/test/go.mod @@ -5,12 +5,14 @@ go 1.15 require ( github.com/emicklei/go-restful/v3 v3.5.2 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/instrumentation/github.com/emicklei/go-restful/otelrestful v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/emicklei/go-restful/otelrestful v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) -replace go.opentelemetry.io/contrib/instrumentation/github.com/emicklei/go-restful/otelrestful => ../ - -replace go.opentelemetry.io/contrib/propagators/b3 => ../../../../../../propagators/b3 +replace ( + go.opentelemetry.io/contrib => ../../../../../../ + go.opentelemetry.io/contrib/instrumentation/github.com/emicklei/go-restful/otelrestful => ../ + go.opentelemetry.io/contrib/propagators/b3 => ../../../../../../propagators/b3 +) diff --git a/instrumentation/github.com/emicklei/go-restful/otelrestful/test/go.sum b/instrumentation/github.com/emicklei/go-restful/otelrestful/test/go.sum index b7c0180a077..07d93df0e22 100644 --- a/instrumentation/github.com/emicklei/go-restful/otelrestful/test/go.sum +++ b/instrumentation/github.com/emicklei/go-restful/otelrestful/test/go.sum @@ -18,8 +18,6 @@ github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+ github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/contrib v0.22.0 h1:0F7gDEjgb1WGn4ODIjaCAg75hmqF+UN0LiVgwxsCodc= -go.opentelemetry.io/contrib v0.22.0/go.mod h1:EH4yDYeNoaTqn/8yCWQmfNB78VHfGX2Jt2bvnvzBlGM= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= diff --git a/instrumentation/github.com/gin-gonic/gin/otelgin/example/go.mod b/instrumentation/github.com/gin-gonic/gin/otelgin/example/go.mod index 7f86938e9fc..297aafe974e 100644 --- a/instrumentation/github.com/gin-gonic/gin/otelgin/example/go.mod +++ b/instrumentation/github.com/gin-gonic/gin/otelgin/example/go.mod @@ -10,7 +10,7 @@ replace ( require ( github.com/gin-gonic/gin v1.7.4 - go.opentelemetry.io/contrib/instrumentation/github.com/gin-gonic/gin/otelgin v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/gin-gonic/gin/otelgin v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 diff --git a/instrumentation/github.com/gin-gonic/gin/otelgin/go.mod b/instrumentation/github.com/gin-gonic/gin/otelgin/go.mod index deea5336471..47047bc62a4 100644 --- a/instrumentation/github.com/gin-gonic/gin/otelgin/go.mod +++ b/instrumentation/github.com/gin-gonic/gin/otelgin/go.mod @@ -10,8 +10,8 @@ replace ( require ( github.com/gin-gonic/gin v1.7.4 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib v0.22.0 - go.opentelemetry.io/contrib/propagators/b3 v0.22.0 + go.opentelemetry.io/contrib v0.23.0 + go.opentelemetry.io/contrib/propagators/b3 v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) diff --git a/instrumentation/github.com/gin-gonic/gin/otelgin/test/go.mod b/instrumentation/github.com/gin-gonic/gin/otelgin/test/go.mod index 35b03232bde..0b22411b3a7 100644 --- a/instrumentation/github.com/gin-gonic/gin/otelgin/test/go.mod +++ b/instrumentation/github.com/gin-gonic/gin/otelgin/test/go.mod @@ -5,7 +5,7 @@ go 1.15 require ( github.com/gin-gonic/gin v1.7.4 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/instrumentation/github.com/gin-gonic/gin/otelgin v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/gin-gonic/gin/otelgin v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 @@ -14,3 +14,5 @@ require ( replace go.opentelemetry.io/contrib/instrumentation/github.com/gin-gonic/gin/otelgin => ../ replace go.opentelemetry.io/contrib/propagators/b3 => ../../../../../../propagators/b3 + +replace go.opentelemetry.io/contrib => ../../../../../../ diff --git a/instrumentation/github.com/gin-gonic/gin/otelgin/test/go.sum b/instrumentation/github.com/gin-gonic/gin/otelgin/test/go.sum index 5d5bebdfea0..adef23a4e21 100644 --- a/instrumentation/github.com/gin-gonic/gin/otelgin/test/go.sum +++ b/instrumentation/github.com/gin-gonic/gin/otelgin/test/go.sum @@ -39,8 +39,6 @@ github.com/ugorji/go v1.1.7 h1:/68gy2h+1mWMrwZFeD1kQialdSzAb432dtpeJ42ovdo= github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVMw= github.com/ugorji/go/codec v1.1.7 h1:2SvQaVZ1ouYrrKKwoSk2pzd4A9evlKJb9oTL+OaLUSs= github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY= -go.opentelemetry.io/contrib v0.22.0 h1:0F7gDEjgb1WGn4ODIjaCAg75hmqF+UN0LiVgwxsCodc= -go.opentelemetry.io/contrib v0.22.0/go.mod h1:EH4yDYeNoaTqn/8yCWQmfNB78VHfGX2Jt2bvnvzBlGM= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= diff --git a/instrumentation/github.com/go-kit/kit/otelkit/example/go.mod b/instrumentation/github.com/go-kit/kit/otelkit/example/go.mod index e6846e0c41b..bf3e8a2427a 100644 --- a/instrumentation/github.com/go-kit/kit/otelkit/example/go.mod +++ b/instrumentation/github.com/go-kit/kit/otelkit/example/go.mod @@ -4,7 +4,7 @@ go 1.15 require ( github.com/gorilla/mux v1.8.0 - go.opentelemetry.io/contrib/instrumentation/github.com/go-kit/kit/otelkit v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/go-kit/kit/otelkit v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 diff --git a/instrumentation/github.com/go-kit/kit/otelkit/go.mod b/instrumentation/github.com/go-kit/kit/otelkit/go.mod index b3abc5e4254..f2a690b2a39 100644 --- a/instrumentation/github.com/go-kit/kit/otelkit/go.mod +++ b/instrumentation/github.com/go-kit/kit/otelkit/go.mod @@ -4,7 +4,7 @@ go 1.15 require ( github.com/go-kit/kit v0.11.0 - go.opentelemetry.io/contrib v0.22.0 + go.opentelemetry.io/contrib v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) diff --git a/instrumentation/github.com/go-kit/kit/otelkit/test/go.mod b/instrumentation/github.com/go-kit/kit/otelkit/test/go.mod index ea4c0169c33..bae7880c35c 100644 --- a/instrumentation/github.com/go-kit/kit/otelkit/test/go.mod +++ b/instrumentation/github.com/go-kit/kit/otelkit/test/go.mod @@ -5,10 +5,12 @@ go 1.15 require ( github.com/go-kit/kit v0.11.0 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/instrumentation/github.com/go-kit/kit/otelkit v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/go-kit/kit/otelkit v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) replace go.opentelemetry.io/contrib/instrumentation/github.com/go-kit/kit/otelkit => ../ + +replace go.opentelemetry.io/contrib => ../../../../../../ diff --git a/instrumentation/github.com/go-kit/kit/otelkit/test/go.sum b/instrumentation/github.com/go-kit/kit/otelkit/test/go.sum index 5006982034a..f9cb95360a4 100644 --- a/instrumentation/github.com/go-kit/kit/otelkit/test/go.sum +++ b/instrumentation/github.com/go-kit/kit/otelkit/test/go.sum @@ -243,8 +243,6 @@ go.etcd.io/etcd/client/pkg/v3 v3.5.0/go.mod h1:IJHfcCEKxYu1Os13ZdwCwIUTUVGYTSAM3 go.etcd.io/etcd/client/v2 v2.305.0/go.mod h1:h9puh54ZTgAKtEbut2oe9P4L/oqKCVB6xsXlzd7alYQ= go.etcd.io/etcd/client/v3 v3.5.0/go.mod h1:AIKXXVX/DQXtfTEqBryiLTUXwON+GuvO6Z7lLS/oTh0= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= -go.opentelemetry.io/contrib v0.22.0 h1:0F7gDEjgb1WGn4ODIjaCAg75hmqF+UN0LiVgwxsCodc= -go.opentelemetry.io/contrib v0.22.0/go.mod h1:EH4yDYeNoaTqn/8yCWQmfNB78VHfGX2Jt2bvnvzBlGM= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= diff --git a/instrumentation/github.com/gocql/gocql/otelgocql/example/go.mod b/instrumentation/github.com/gocql/gocql/otelgocql/example/go.mod index cdea7e4e5a3..81b5a7886fc 100644 --- a/instrumentation/github.com/gocql/gocql/otelgocql/example/go.mod +++ b/instrumentation/github.com/gocql/gocql/otelgocql/example/go.mod @@ -9,12 +9,12 @@ replace ( require ( github.com/gocql/gocql v0.0.0-20200624222514-34081eda590e - go.opentelemetry.io/contrib/instrumentation/github.com/gocql/gocql/otelgocql v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/gocql/gocql/otelgocql v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 - go.opentelemetry.io/otel/exporters/prometheus v0.22.0 + go.opentelemetry.io/otel/exporters/prometheus v0.23.0 go.opentelemetry.io/otel/exporters/zipkin v1.0.0-RC3 - go.opentelemetry.io/otel/metric v0.22.0 + go.opentelemetry.io/otel/metric v0.23.0 go.opentelemetry.io/otel/sdk v1.0.0-RC3 - go.opentelemetry.io/otel/sdk/export/metric v0.22.0 - go.opentelemetry.io/otel/sdk/metric v0.22.0 + go.opentelemetry.io/otel/sdk/export/metric v0.23.0 + go.opentelemetry.io/otel/sdk/metric v0.23.0 ) diff --git a/instrumentation/github.com/gocql/gocql/otelgocql/example/go.sum b/instrumentation/github.com/gocql/gocql/otelgocql/example/go.sum index 00a66f4d8f3..1548706d694 100644 --- a/instrumentation/github.com/gocql/gocql/otelgocql/example/go.sum +++ b/instrumentation/github.com/gocql/gocql/otelgocql/example/go.sum @@ -143,26 +143,22 @@ github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UV github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/exporters/prometheus v0.22.0 h1:p5DsHaSF61E0CwRRKmd8t9ril5KjbjIyu6mBoQ2SO28= -go.opentelemetry.io/otel/exporters/prometheus v0.22.0/go.mod h1:fnolxp61wIq3NvflpkKH7asSqU/tpXPcTZiPhL1+JzE= +go.opentelemetry.io/otel/exporters/prometheus v0.23.0 h1:ZFx1kUjUSBF7H1mTPHHOqglEDQsxYBrDnYZ8i41v3iE= +go.opentelemetry.io/otel/exporters/prometheus v0.23.0/go.mod h1:kjCXbxQnnEm5l3HrUw4IPyuALu7Uqb/bEK7vWQnbd8s= go.opentelemetry.io/otel/exporters/zipkin v1.0.0-RC3 h1:NcjZQwPFW0V2OvasQQJWSOTGA6R+4SLLgcPGIiDC3fk= go.opentelemetry.io/otel/exporters/zipkin v1.0.0-RC3/go.mod h1:3ASq7NNNoDb2P6dIBEBuurzogYO3Jo+wfbeonxBc11Y= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/sdk v1.0.0-RC1/go.mod h1:kj6yPn7Pgt5ByRuwesbaWcRLA+V7BSDg3Hf8xRvsvf8= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0 h1:6huidwh9LZi/+lvFw7EQ+m+pVmlfhOMd9s9PmTXAgeo= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0/go.mod h1:a14rf2CiHSn9xjB6cHuv0HoZGl5C4w2PAgl+Lja1VzU= -go.opentelemetry.io/otel/sdk/metric v0.22.0 h1:ZBagqeLlTgEmvxtaN3GkvmbmG+XWKDwS+amr8EsSMDo= -go.opentelemetry.io/otel/sdk/metric v0.22.0/go.mod h1:LzkI0G0z6KhEagqmzgk3bw/dglE2Tk2OXs455UMcI0s= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0 h1:7NeoKPPx6NdZBVHLEp/LY5Lq85Ff1WNZnuJkuRy+azw= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0/go.mod h1:SuMiREmKVRIwFKq73zvGTvwFpxb/ZAYkMfyqMoOtDqs= +go.opentelemetry.io/otel/sdk/metric v0.23.0 h1:xlZhPbiue1+jjSFEth94q9QCmX8Q24mOtue9IAmlVyI= +go.opentelemetry.io/otel/sdk/metric v0.23.0/go.mod h1:wa0sKK13eeIFW+0OFjcC3S1i7FTRRiLAXe1kjBVbhwg= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= diff --git a/instrumentation/github.com/gocql/gocql/otelgocql/go.mod b/instrumentation/github.com/gocql/gocql/otelgocql/go.mod index 6d1a357b3ab..27951fa99ca 100644 --- a/instrumentation/github.com/gocql/gocql/otelgocql/go.mod +++ b/instrumentation/github.com/gocql/gocql/otelgocql/go.mod @@ -8,8 +8,8 @@ require ( github.com/gocql/gocql v0.0.0-20200624222514-34081eda590e github.com/golang/snappy v0.0.1 // indirect github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib v0.22.0 + go.opentelemetry.io/contrib v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 - go.opentelemetry.io/otel/metric v0.22.0 + go.opentelemetry.io/otel/metric v0.23.0 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) diff --git a/instrumentation/github.com/gocql/gocql/otelgocql/go.sum b/instrumentation/github.com/gocql/gocql/otelgocql/go.sum index e677a0e5de2..ee490ee0cb6 100644 --- a/instrumentation/github.com/gocql/gocql/otelgocql/go.sum +++ b/instrumentation/github.com/gocql/gocql/otelgocql/go.sum @@ -24,15 +24,12 @@ github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+ github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= diff --git a/instrumentation/github.com/gocql/gocql/otelgocql/instrument.go b/instrumentation/github.com/gocql/gocql/otelgocql/instrument.go index 71f851d62c7..9263c429f56 100644 --- a/instrumentation/github.com/gocql/gocql/otelgocql/instrument.go +++ b/instrumentation/github.com/gocql/gocql/otelgocql/instrument.go @@ -28,7 +28,7 @@ type instruments struct { queryCount metric.Int64Counter // queryRows is the number of rows returned by a query. - queryRows metric.Int64ValueRecorder + queryRows metric.Int64Histogram // batchCount is the number of batch queries executed. batchCount metric.Int64Counter @@ -38,7 +38,7 @@ type instruments struct { connectionCount metric.Int64Counter // latency is the sum of attempt latencies. - latency metric.Int64ValueRecorder + latency metric.Int64Histogram } // newInstruments will create instruments using a meter @@ -58,7 +58,7 @@ func newInstruments(p metric.MeterProvider) *instruments { log.Printf("failed to create iQueryCount instrument, %v", err) } - if instruments.queryRows, err = meter.NewInt64ValueRecorder( + if instruments.queryRows, err = meter.NewInt64Histogram( "db.cassandra.rows", metric.WithDescription("Number of rows returned from query"), ); err != nil { @@ -79,7 +79,7 @@ func newInstruments(p metric.MeterProvider) *instruments { log.Printf("failed to create iConnectionCount instrument, %v", err) } - if instruments.latency, err = meter.NewInt64ValueRecorder( + if instruments.latency, err = meter.NewInt64Histogram( "db.cassandra.latency", metric.WithDescription("Sum of latency to host in milliseconds"), metric.WithUnit(unit.Milliseconds), diff --git a/instrumentation/github.com/gocql/gocql/otelgocql/test/go.mod b/instrumentation/github.com/gocql/gocql/otelgocql/test/go.mod index 1ec7e986535..d6fc404cf82 100644 --- a/instrumentation/github.com/gocql/gocql/otelgocql/test/go.mod +++ b/instrumentation/github.com/gocql/gocql/otelgocql/test/go.mod @@ -5,12 +5,14 @@ go 1.15 require ( github.com/gocql/gocql v0.0.0-20210707082121-9a3953d1826d github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib v0.22.0 - go.opentelemetry.io/contrib/instrumentation/github.com/gocql/gocql/otelgocql v0.22.0 + go.opentelemetry.io/contrib v0.23.0 + go.opentelemetry.io/contrib/instrumentation/github.com/gocql/gocql/otelgocql v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 - go.opentelemetry.io/otel/metric v0.22.0 + go.opentelemetry.io/otel/metric v0.23.0 go.opentelemetry.io/otel/sdk v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) replace go.opentelemetry.io/contrib/instrumentation/github.com/gocql/gocql/otelgocql => ../ + +replace go.opentelemetry.io/contrib => ../../../../../../ diff --git a/instrumentation/github.com/gocql/gocql/otelgocql/test/go.sum b/instrumentation/github.com/gocql/gocql/otelgocql/test/go.sum index 9ca417271bc..3bd7c1925b7 100644 --- a/instrumentation/github.com/gocql/gocql/otelgocql/test/go.sum +++ b/instrumentation/github.com/gocql/gocql/otelgocql/test/go.sum @@ -26,19 +26,14 @@ github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+ github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/contrib v0.22.0 h1:0F7gDEjgb1WGn4ODIjaCAg75hmqF+UN0LiVgwxsCodc= -go.opentelemetry.io/contrib v0.22.0/go.mod h1:EH4yDYeNoaTqn/8yCWQmfNB78VHfGX2Jt2bvnvzBlGM= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7 h1:iGu644GcxtEcrInvDsQRCwJjtCIOlT2V7IRt6ah2Whw= diff --git a/instrumentation/github.com/gorilla/mux/otelmux/example/go.mod b/instrumentation/github.com/gorilla/mux/otelmux/example/go.mod index 3cc8c86055e..e52a0bd5263 100644 --- a/instrumentation/github.com/gorilla/mux/otelmux/example/go.mod +++ b/instrumentation/github.com/gorilla/mux/otelmux/example/go.mod @@ -9,7 +9,7 @@ replace ( require ( github.com/gorilla/mux v1.8.0 - go.opentelemetry.io/contrib/instrumentation/github.com/gorilla/mux/otelmux v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/gorilla/mux/otelmux v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 diff --git a/instrumentation/github.com/gorilla/mux/otelmux/go.mod b/instrumentation/github.com/gorilla/mux/otelmux/go.mod index d89ea0b108b..a8b74942246 100644 --- a/instrumentation/github.com/gorilla/mux/otelmux/go.mod +++ b/instrumentation/github.com/gorilla/mux/otelmux/go.mod @@ -8,7 +8,7 @@ require ( github.com/felixge/httpsnoop v1.0.2 github.com/gorilla/mux v1.8.0 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib v0.22.0 + go.opentelemetry.io/contrib v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) diff --git a/instrumentation/github.com/gorilla/mux/otelmux/test/go.mod b/instrumentation/github.com/gorilla/mux/otelmux/test/go.mod index cb554317a47..55bfe559a54 100644 --- a/instrumentation/github.com/gorilla/mux/otelmux/test/go.mod +++ b/instrumentation/github.com/gorilla/mux/otelmux/test/go.mod @@ -5,8 +5,13 @@ go 1.15 require ( github.com/gorilla/mux v1.8.0 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/instrumentation/github.com/gorilla/mux/otelmux v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/gorilla/mux/otelmux v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) + +replace ( + go.opentelemetry.io/contrib => ../../../../../../ + go.opentelemetry.io/contrib/instrumentation/github.com/gorilla/mux/otelmux => ../ +) diff --git a/instrumentation/github.com/gorilla/mux/otelmux/test/go.sum b/instrumentation/github.com/gorilla/mux/otelmux/test/go.sum index 6166881a543..c517f773eb5 100644 --- a/instrumentation/github.com/gorilla/mux/otelmux/test/go.sum +++ b/instrumentation/github.com/gorilla/mux/otelmux/test/go.sum @@ -11,20 +11,10 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/contrib v0.22.0 h1:0F7gDEjgb1WGn4ODIjaCAg75hmqF+UN0LiVgwxsCodc= -go.opentelemetry.io/contrib v0.22.0/go.mod h1:EH4yDYeNoaTqn/8yCWQmfNB78VHfGX2Jt2bvnvzBlGM= -go.opentelemetry.io/contrib/instrumentation/github.com/gorilla/mux/otelmux v0.22.0 h1:Mfz1DMQ43mhQePKqiny6kUTnUrtin+395V67yAIyYhg= -go.opentelemetry.io/contrib/instrumentation/github.com/gorilla/mux/otelmux v0.22.0/go.mod h1:jpoprhHaffWHQ1KBpL0jI+w7979p4ijAL2auucLUj1E= -go.opentelemetry.io/contrib/propagators v0.22.0 h1:KGdv58M2//veiYLIhb31mofaI2LgkIPXXAZVeYVyfd8= -go.opentelemetry.io/contrib/propagators v0.22.0/go.mod h1:xGOuXr6lLIF9BXipA4pm6UuOSI0M98U6tsI3khbOiwU= -go.opentelemetry.io/otel v1.0.0-RC2/go.mod h1:w1thVQ7qbAy8MHb0IFj8a5Q2QU0l2ksf8u/CN8m3NOM= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/oteltest v1.0.0-RC2 h1:xNKqMhlZYkASSyvF4JwObZFMq0jhFN3c3SP+2rCzVPk= -go.opentelemetry.io/otel/oteltest v1.0.0-RC2/go.mod h1:kiQ4tw5tAL4JLTbcOYwK1CWI1HkT5aiLzHovgOVnz/A= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/trace v1.0.0-RC2/go.mod h1:JPQ+z6nNw9mqEGT8o3eoPTdnNI+Aj5JcxEsVGREIAy4= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7 h1:iGu644GcxtEcrInvDsQRCwJjtCIOlT2V7IRt6ah2Whw= diff --git a/instrumentation/github.com/labstack/echo/otelecho/example/go.mod b/instrumentation/github.com/labstack/echo/otelecho/example/go.mod index 6b1699ec023..9a38b398c44 100644 --- a/instrumentation/github.com/labstack/echo/otelecho/example/go.mod +++ b/instrumentation/github.com/labstack/echo/otelecho/example/go.mod @@ -10,7 +10,7 @@ replace ( require ( github.com/labstack/echo/v4 v4.5.0 - go.opentelemetry.io/contrib/instrumentation/github.com/labstack/echo/otelecho v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/labstack/echo/otelecho v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 diff --git a/instrumentation/github.com/labstack/echo/otelecho/go.mod b/instrumentation/github.com/labstack/echo/otelecho/go.mod index 69d0d4a4a9c..3cd464a30a9 100644 --- a/instrumentation/github.com/labstack/echo/otelecho/go.mod +++ b/instrumentation/github.com/labstack/echo/otelecho/go.mod @@ -10,8 +10,8 @@ replace ( require ( github.com/labstack/echo/v4 v4.5.0 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib v0.22.0 - go.opentelemetry.io/contrib/propagators/b3 v0.22.0 + go.opentelemetry.io/contrib v0.23.0 + go.opentelemetry.io/contrib/propagators/b3 v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) diff --git a/instrumentation/github.com/labstack/echo/otelecho/test/go.mod b/instrumentation/github.com/labstack/echo/otelecho/test/go.mod index c6096ed9c08..f1222312007 100644 --- a/instrumentation/github.com/labstack/echo/otelecho/test/go.mod +++ b/instrumentation/github.com/labstack/echo/otelecho/test/go.mod @@ -5,12 +5,14 @@ go 1.15 require ( github.com/labstack/echo/v4 v4.5.0 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/instrumentation/github.com/labstack/echo/otelecho v0.22.0 + go.opentelemetry.io/contrib/instrumentation/github.com/labstack/echo/otelecho v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) -replace go.opentelemetry.io/contrib/instrumentation/github.com/labstack/echo/otelecho => ../ - -replace go.opentelemetry.io/contrib/propagators/b3 => ../../../../../../propagators/b3 +replace ( + go.opentelemetry.io/contrib => ../../../../../../ + go.opentelemetry.io/contrib/instrumentation/github.com/labstack/echo/otelecho => ../ + go.opentelemetry.io/contrib/propagators/b3 => ../../../../../../propagators/b3 +) diff --git a/instrumentation/github.com/labstack/echo/otelecho/test/go.sum b/instrumentation/github.com/labstack/echo/otelecho/test/go.sum index f8e945197a9..9886a6d9f7d 100644 --- a/instrumentation/github.com/labstack/echo/otelecho/test/go.sum +++ b/instrumentation/github.com/labstack/echo/otelecho/test/go.sum @@ -26,8 +26,6 @@ github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyC github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= github.com/valyala/fasttemplate v1.2.1 h1:TVEnxayobAdVkhQfrfes2IzOB6o+z4roRkPF52WA1u4= github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= -go.opentelemetry.io/contrib v0.22.0 h1:0F7gDEjgb1WGn4ODIjaCAg75hmqF+UN0LiVgwxsCodc= -go.opentelemetry.io/contrib v0.22.0/go.mod h1:EH4yDYeNoaTqn/8yCWQmfNB78VHfGX2Jt2bvnvzBlGM= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= diff --git a/instrumentation/go.mongodb.org/mongo-driver/mongo/otelmongo/go.mod b/instrumentation/go.mongodb.org/mongo-driver/mongo/otelmongo/go.mod index 6959c43de06..d6b7faf50e9 100644 --- a/instrumentation/go.mongodb.org/mongo-driver/mongo/otelmongo/go.mod +++ b/instrumentation/go.mongodb.org/mongo-driver/mongo/otelmongo/go.mod @@ -6,7 +6,7 @@ replace go.opentelemetry.io/contrib => ../../../../.. require ( go.mongodb.org/mongo-driver v1.7.1 - go.opentelemetry.io/contrib v0.22.0 + go.opentelemetry.io/contrib v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) diff --git a/instrumentation/go.mongodb.org/mongo-driver/mongo/otelmongo/test/go.mod b/instrumentation/go.mongodb.org/mongo-driver/mongo/otelmongo/test/go.mod index 1cd4bfa49a0..1544bc4135d 100644 --- a/instrumentation/go.mongodb.org/mongo-driver/mongo/otelmongo/test/go.mod +++ b/instrumentation/go.mongodb.org/mongo-driver/mongo/otelmongo/test/go.mod @@ -5,8 +5,8 @@ go 1.15 require ( github.com/stretchr/testify v1.7.0 go.mongodb.org/mongo-driver v1.7.1 - go.opentelemetry.io/contrib v0.22.0 - go.opentelemetry.io/contrib/instrumentation/go.mongodb.org/mongo-driver/mongo/otelmongo v0.22.0 + go.opentelemetry.io/contrib v0.23.0 + go.opentelemetry.io/contrib/instrumentation/go.mongodb.org/mongo-driver/mongo/otelmongo v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 diff --git a/instrumentation/google.golang.org/grpc/otelgrpc/example/go.mod b/instrumentation/google.golang.org/grpc/otelgrpc/example/go.mod index 545717eda08..d624d7d618b 100644 --- a/instrumentation/google.golang.org/grpc/otelgrpc/example/go.mod +++ b/instrumentation/google.golang.org/grpc/otelgrpc/example/go.mod @@ -9,7 +9,7 @@ replace ( require ( github.com/golang/protobuf v1.5.2 - go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.22.0 + go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 diff --git a/instrumentation/google.golang.org/grpc/otelgrpc/go.mod b/instrumentation/google.golang.org/grpc/otelgrpc/go.mod index e578815b2ee..84f666ab511 100644 --- a/instrumentation/google.golang.org/grpc/otelgrpc/go.mod +++ b/instrumentation/google.golang.org/grpc/otelgrpc/go.mod @@ -6,7 +6,7 @@ replace go.opentelemetry.io/contrib => ../../../../ require ( github.com/golang/protobuf v1.5.2 - go.opentelemetry.io/contrib v0.22.0 + go.opentelemetry.io/contrib v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 google.golang.org/grpc v1.40.0 diff --git a/instrumentation/google.golang.org/grpc/otelgrpc/test/go.mod b/instrumentation/google.golang.org/grpc/otelgrpc/test/go.mod index 8c562401060..087bd4558e3 100644 --- a/instrumentation/google.golang.org/grpc/otelgrpc/test/go.mod +++ b/instrumentation/google.golang.org/grpc/otelgrpc/test/go.mod @@ -5,11 +5,14 @@ go 1.15 require ( github.com/golang/protobuf v1.5.2 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.22.0 + go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 go.uber.org/goleak v1.1.10 google.golang.org/grpc v1.40.0 ) -replace go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc => ../ +replace ( + go.opentelemetry.io/contrib => ../../../../../ + go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc => ../ +) diff --git a/instrumentation/google.golang.org/grpc/otelgrpc/test/go.sum b/instrumentation/google.golang.org/grpc/otelgrpc/test/go.sum index 0de4b7028d4..78f19c14fb9 100644 --- a/instrumentation/google.golang.org/grpc/otelgrpc/test/go.sum +++ b/instrumentation/google.golang.org/grpc/otelgrpc/test/go.sum @@ -60,8 +60,6 @@ github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81P github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/contrib v0.22.0 h1:0F7gDEjgb1WGn4ODIjaCAg75hmqF+UN0LiVgwxsCodc= -go.opentelemetry.io/contrib v0.22.0/go.mod h1:EH4yDYeNoaTqn/8yCWQmfNB78VHfGX2Jt2bvnvzBlGM= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= diff --git a/instrumentation/gopkg.in/macaron.v1/otelmacaron/example/go.mod b/instrumentation/gopkg.in/macaron.v1/otelmacaron/example/go.mod index e8fc7097d01..4e487253ba2 100644 --- a/instrumentation/gopkg.in/macaron.v1/otelmacaron/example/go.mod +++ b/instrumentation/gopkg.in/macaron.v1/otelmacaron/example/go.mod @@ -9,7 +9,7 @@ replace ( ) require ( - go.opentelemetry.io/contrib/instrumentation/gopkg.in/macaron.v1/otelmacaron v0.22.0 + go.opentelemetry.io/contrib/instrumentation/gopkg.in/macaron.v1/otelmacaron v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 diff --git a/instrumentation/gopkg.in/macaron.v1/otelmacaron/go.mod b/instrumentation/gopkg.in/macaron.v1/otelmacaron/go.mod index 359722dd411..ca108ccee28 100644 --- a/instrumentation/gopkg.in/macaron.v1/otelmacaron/go.mod +++ b/instrumentation/gopkg.in/macaron.v1/otelmacaron/go.mod @@ -9,8 +9,8 @@ replace ( require ( github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib v0.22.0 - go.opentelemetry.io/contrib/propagators/b3 v0.22.0-00010101000000-000000000000 + go.opentelemetry.io/contrib v0.23.0 + go.opentelemetry.io/contrib/propagators/b3 v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 gopkg.in/macaron.v1 v1.4.0 diff --git a/instrumentation/gopkg.in/macaron.v1/otelmacaron/test/go.mod b/instrumentation/gopkg.in/macaron.v1/otelmacaron/test/go.mod index bbf8130e01c..cc54893f678 100644 --- a/instrumentation/gopkg.in/macaron.v1/otelmacaron/test/go.mod +++ b/instrumentation/gopkg.in/macaron.v1/otelmacaron/test/go.mod @@ -4,13 +4,15 @@ go 1.15 require ( github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/instrumentation/gopkg.in/macaron.v1/otelmacaron v0.22.0 + go.opentelemetry.io/contrib/instrumentation/gopkg.in/macaron.v1/otelmacaron v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 gopkg.in/macaron.v1 v1.4.0 ) -replace go.opentelemetry.io/contrib/instrumentation/gopkg.in/macaron.v1/otelmacaron => ../ - -replace go.opentelemetry.io/contrib/propagators/b3 => ../../../../../propagators/b3 +replace ( + go.opentelemetry.io/contrib => ../../../../../ + go.opentelemetry.io/contrib/instrumentation/gopkg.in/macaron.v1/otelmacaron => ../ + go.opentelemetry.io/contrib/propagators/b3 => ../../../../../propagators/b3 +) diff --git a/instrumentation/gopkg.in/macaron.v1/otelmacaron/test/go.sum b/instrumentation/gopkg.in/macaron.v1/otelmacaron/test/go.sum index db6335dd2f5..697b598281c 100644 --- a/instrumentation/gopkg.in/macaron.v1/otelmacaron/test/go.sum +++ b/instrumentation/gopkg.in/macaron.v1/otelmacaron/test/go.sum @@ -25,8 +25,6 @@ github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5Cc github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/unknwon/com v0.0.0-20190804042917-757f69c95f3e h1:GSGeB9EAKY2spCABz6xOX5DbxZEXolK+nBSvmsQwRjM= github.com/unknwon/com v0.0.0-20190804042917-757f69c95f3e/go.mod h1:tOOxU81rwgoCLoOVVPHb6T/wt8HZygqH5id+GNnlCXM= -go.opentelemetry.io/contrib v0.22.0 h1:0F7gDEjgb1WGn4ODIjaCAg75hmqF+UN0LiVgwxsCodc= -go.opentelemetry.io/contrib v0.22.0/go.mod h1:EH4yDYeNoaTqn/8yCWQmfNB78VHfGX2Jt2bvnvzBlGM= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= diff --git a/instrumentation/host/example/go.mod b/instrumentation/host/example/go.mod index 4b10df924b0..39638669a6c 100644 --- a/instrumentation/host/example/go.mod +++ b/instrumentation/host/example/go.mod @@ -8,8 +8,8 @@ replace ( ) require ( - go.opentelemetry.io/contrib/instrumentation/host v0.22.0 - go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.22.0 - go.opentelemetry.io/otel/metric v0.22.0 - go.opentelemetry.io/otel/sdk/metric v0.22.0 + go.opentelemetry.io/contrib/instrumentation/host v0.23.0 + go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.23.0 + go.opentelemetry.io/otel/metric v0.23.0 + go.opentelemetry.io/otel/sdk/metric v0.23.0 ) diff --git a/instrumentation/host/example/go.sum b/instrumentation/host/example/go.sum index 0a3e3380914..2a9bd9838ab 100644 --- a/instrumentation/host/example/go.sum +++ b/instrumentation/host/example/go.sum @@ -15,27 +15,25 @@ github.com/shirou/gopsutil v2.20.9+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.22.0 h1:80zr1fmoIZBBEOcVnAIHdwgOhh0K03RMYTJWIoCCiM4= -go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.22.0/go.mod h1:Rr5CP504/kg8q8PXzBUBqfJDRlDtK/TQuQm0Y7mU1QE= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/sdk v1.0.0-RC1 h1:Sy2VLOOg24bipyC29PhuMXYNJrLsxkie8hyI7kUlG9Q= -go.opentelemetry.io/otel/sdk v1.0.0-RC1/go.mod h1:kj6yPn7Pgt5ByRuwesbaWcRLA+V7BSDg3Hf8xRvsvf8= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0 h1:6huidwh9LZi/+lvFw7EQ+m+pVmlfhOMd9s9PmTXAgeo= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0/go.mod h1:a14rf2CiHSn9xjB6cHuv0HoZGl5C4w2PAgl+Lja1VzU= -go.opentelemetry.io/otel/sdk/metric v0.22.0 h1:ZBagqeLlTgEmvxtaN3GkvmbmG+XWKDwS+amr8EsSMDo= -go.opentelemetry.io/otel/sdk/metric v0.22.0/go.mod h1:LzkI0G0z6KhEagqmzgk3bw/dglE2Tk2OXs455UMcI0s= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.23.0 h1:18DBDmxn/HbsKvkU715C5zJA2Nz+5m72GfvE1Km7x0Q= +go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.23.0/go.mod h1:JhWmMa+W0p7dWrH5aiZY5c+pi5E1/gR1gv+L+8lDW1E= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= +go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= +go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0 h1:7NeoKPPx6NdZBVHLEp/LY5Lq85Ff1WNZnuJkuRy+azw= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0/go.mod h1:SuMiREmKVRIwFKq73zvGTvwFpxb/ZAYkMfyqMoOtDqs= +go.opentelemetry.io/otel/sdk/metric v0.23.0 h1:xlZhPbiue1+jjSFEth94q9QCmX8Q24mOtue9IAmlVyI= +go.opentelemetry.io/otel/sdk/metric v0.23.0/go.mod h1:wa0sKK13eeIFW+0OFjcC3S1i7FTRRiLAXe1kjBVbhwg= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= -golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a h1:1BGLXjeY4akVXGgbC9HugT3Jv3hCI0z56oJR5vAMgBU= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7 h1:iGu644GcxtEcrInvDsQRCwJjtCIOlT2V7IRt6ah2Whw= +golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= diff --git a/instrumentation/host/go.mod b/instrumentation/host/go.mod index c6f6da4eb95..239ce59bb8a 100644 --- a/instrumentation/host/go.mod +++ b/instrumentation/host/go.mod @@ -9,8 +9,8 @@ require ( github.com/go-ole/go-ole v1.2.4 // indirect github.com/shirou/gopsutil v2.20.9+incompatible github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib v0.22.0 + go.opentelemetry.io/contrib v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 - go.opentelemetry.io/otel/metric v0.22.0 + go.opentelemetry.io/otel/metric v0.23.0 golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a // indirect ) diff --git a/instrumentation/host/go.sum b/instrumentation/host/go.sum index 13dcda618a3..e31ff9b4ab3 100644 --- a/instrumentation/host/go.sum +++ b/instrumentation/host/go.sum @@ -13,15 +13,12 @@ github.com/shirou/gopsutil v2.20.9+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a h1:1BGLXjeY4akVXGgbC9HugT3Jv3hCI0z56oJR5vAMgBU= diff --git a/instrumentation/host/host.go b/instrumentation/host/host.go index 4454e389608..2bea91f84ce 100644 --- a/instrumentation/host/host.go +++ b/instrumentation/host/host.go @@ -115,13 +115,13 @@ func (h *host) register() error { var ( err error - processCPUTime metric.Float64SumObserver - hostCPUTime metric.Float64SumObserver + processCPUTime metric.Float64UpDownCounterObserver + hostCPUTime metric.Float64UpDownCounterObserver - hostMemoryUsage metric.Int64UpDownSumObserver - hostMemoryUtilization metric.Float64UpDownSumObserver + hostMemoryUsage metric.Int64UpDownCounterObserver + hostMemoryUtilization metric.Float64UpDownCounterObserver - networkIOUsage metric.Int64SumObserver + networkIOUsage metric.Int64UpDownCounterObserver // lock prevents a race between batch observer and instrument registration. lock sync.Mutex @@ -227,7 +227,7 @@ func (h *host) register() error { // TODO: .time units are in seconds, but "unit" package does // not include this string. // https://github.com/open-telemetry/opentelemetry-specification/issues/705 - if processCPUTime, err = batchObserver.NewFloat64SumObserver( + if processCPUTime, err = batchObserver.NewFloat64UpDownCounterObserver( "process.cpu.time", metric.WithUnit("s"), metric.WithDescription( @@ -237,7 +237,7 @@ func (h *host) register() error { return err } - if hostCPUTime, err = batchObserver.NewFloat64SumObserver( + if hostCPUTime, err = batchObserver.NewFloat64UpDownCounterObserver( "system.cpu.time", metric.WithUnit("s"), metric.WithDescription( @@ -247,7 +247,7 @@ func (h *host) register() error { return err } - if hostMemoryUsage, err = batchObserver.NewInt64UpDownSumObserver( + if hostMemoryUsage, err = batchObserver.NewInt64UpDownCounterObserver( "system.memory.usage", metric.WithUnit(unit.Bytes), metric.WithDescription( @@ -257,7 +257,7 @@ func (h *host) register() error { return err } - if hostMemoryUtilization, err = batchObserver.NewFloat64UpDownSumObserver( + if hostMemoryUtilization, err = batchObserver.NewFloat64UpDownCounterObserver( "system.memory.utilization", metric.WithUnit(unit.Dimensionless), metric.WithDescription( @@ -267,7 +267,7 @@ func (h *host) register() error { return err } - if networkIOUsage, err = batchObserver.NewInt64SumObserver( + if networkIOUsage, err = batchObserver.NewInt64UpDownCounterObserver( "system.network.io", metric.WithUnit(unit.Bytes), metric.WithDescription( diff --git a/instrumentation/net/http/httptrace/otelhttptrace/example/go.mod b/instrumentation/net/http/httptrace/otelhttptrace/example/go.mod index 4bcc2b65a0c..b1205246ddb 100644 --- a/instrumentation/net/http/httptrace/otelhttptrace/example/go.mod +++ b/instrumentation/net/http/httptrace/otelhttptrace/example/go.mod @@ -9,8 +9,8 @@ replace ( ) require ( - go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.22.0 - go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.22.0 + go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.23.0 + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 diff --git a/instrumentation/net/http/httptrace/otelhttptrace/example/go.sum b/instrumentation/net/http/httptrace/otelhttptrace/example/go.sum index a7074468b45..82ebabee7c7 100644 --- a/instrumentation/net/http/httptrace/otelhttptrace/example/go.sum +++ b/instrumentation/net/http/httptrace/otelhttptrace/example/go.sum @@ -9,19 +9,16 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 h1:ewSzc2SagdOx0up5xZPigXh1n3SLsNEslc5edHRBVcs= go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3/go.mod h1:Oxmrmpdvm6lM3tkYmHKGWAhi9+9c2rrAEbwSDn0Bvv8= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7 h1:iGu644GcxtEcrInvDsQRCwJjtCIOlT2V7IRt6ah2Whw= diff --git a/instrumentation/net/http/httptrace/otelhttptrace/go.mod b/instrumentation/net/http/httptrace/otelhttptrace/go.mod index 73506fb55c3..42ede680ce9 100644 --- a/instrumentation/net/http/httptrace/otelhttptrace/go.mod +++ b/instrumentation/net/http/httptrace/otelhttptrace/go.mod @@ -6,7 +6,7 @@ replace go.opentelemetry.io/contrib => ../../../../.. require ( github.com/google/go-cmp v0.5.6 - go.opentelemetry.io/contrib v0.22.0 + go.opentelemetry.io/contrib v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) diff --git a/instrumentation/net/http/httptrace/otelhttptrace/test/go.mod b/instrumentation/net/http/httptrace/otelhttptrace/test/go.mod index 90275e78b2f..2848c1ba3d3 100644 --- a/instrumentation/net/http/httptrace/otelhttptrace/test/go.mod +++ b/instrumentation/net/http/httptrace/otelhttptrace/test/go.mod @@ -4,9 +4,12 @@ go 1.15 require ( github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.22.0 + go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 ) -replace go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace => ../ +replace ( + go.opentelemetry.io/contrib => ../../../../../.. + go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace => ../ +) diff --git a/instrumentation/net/http/httptrace/otelhttptrace/test/go.sum b/instrumentation/net/http/httptrace/otelhttptrace/test/go.sum index 659a6b22167..1d8e85c25c7 100644 --- a/instrumentation/net/http/httptrace/otelhttptrace/test/go.sum +++ b/instrumentation/net/http/httptrace/otelhttptrace/test/go.sum @@ -7,8 +7,6 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/contrib v0.22.0 h1:0F7gDEjgb1WGn4ODIjaCAg75hmqF+UN0LiVgwxsCodc= -go.opentelemetry.io/contrib v0.22.0/go.mod h1:EH4yDYeNoaTqn/8yCWQmfNB78VHfGX2Jt2bvnvzBlGM= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= diff --git a/instrumentation/net/http/otelhttp/example/go.mod b/instrumentation/net/http/otelhttp/example/go.mod index b6b485fd09d..c2102223558 100644 --- a/instrumentation/net/http/otelhttp/example/go.mod +++ b/instrumentation/net/http/otelhttp/example/go.mod @@ -8,7 +8,7 @@ replace ( ) require ( - go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.22.0 + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 diff --git a/instrumentation/net/http/otelhttp/example/go.sum b/instrumentation/net/http/otelhttp/example/go.sum index a7074468b45..82ebabee7c7 100644 --- a/instrumentation/net/http/otelhttp/example/go.sum +++ b/instrumentation/net/http/otelhttp/example/go.sum @@ -9,19 +9,16 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 h1:ewSzc2SagdOx0up5xZPigXh1n3SLsNEslc5edHRBVcs= go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3/go.mod h1:Oxmrmpdvm6lM3tkYmHKGWAhi9+9c2rrAEbwSDn0Bvv8= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7 h1:iGu644GcxtEcrInvDsQRCwJjtCIOlT2V7IRt6ah2Whw= diff --git a/instrumentation/net/http/otelhttp/go.mod b/instrumentation/net/http/otelhttp/go.mod index 195287315ae..a44760b7934 100644 --- a/instrumentation/net/http/otelhttp/go.mod +++ b/instrumentation/net/http/otelhttp/go.mod @@ -7,8 +7,8 @@ replace go.opentelemetry.io/contrib => ../../../.. require ( github.com/felixge/httpsnoop v1.0.2 github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib v0.22.0 + go.opentelemetry.io/contrib v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 - go.opentelemetry.io/otel/metric v0.22.0 + go.opentelemetry.io/otel/metric v0.23.0 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) diff --git a/instrumentation/net/http/otelhttp/go.sum b/instrumentation/net/http/otelhttp/go.sum index a64d225a13d..935f7905029 100644 --- a/instrumentation/net/http/otelhttp/go.sum +++ b/instrumentation/net/http/otelhttp/go.sum @@ -9,15 +9,12 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= diff --git a/instrumentation/net/http/otelhttp/handler.go b/instrumentation/net/http/otelhttp/handler.go index 305c4d7661d..99ff30acc38 100644 --- a/instrumentation/net/http/otelhttp/handler.go +++ b/instrumentation/net/http/otelhttp/handler.go @@ -48,7 +48,7 @@ type Handler struct { filters []Filter spanNameFormatter func(string, *http.Request) string counters map[string]metric.Int64Counter - valueRecorders map[string]metric.Int64ValueRecorder + valueRecorders map[string]metric.Int64Histogram } func defaultHandlerFormatter(operation string, _ *http.Request) string { @@ -94,7 +94,7 @@ func handleErr(err error) { func (h *Handler) createMeasures() { h.counters = make(map[string]metric.Int64Counter) - h.valueRecorders = make(map[string]metric.Int64ValueRecorder) + h.valueRecorders = make(map[string]metric.Int64Histogram) requestBytesCounter, err := h.meter.NewInt64Counter(RequestContentLength) handleErr(err) @@ -102,7 +102,7 @@ func (h *Handler) createMeasures() { responseBytesCounter, err := h.meter.NewInt64Counter(ResponseContentLength) handleErr(err) - serverLatencyMeasure, err := h.meter.NewInt64ValueRecorder(ServerLatency) + serverLatencyMeasure, err := h.meter.NewInt64Histogram(ServerLatency) handleErr(err) h.counters[RequestContentLength] = requestBytesCounter diff --git a/instrumentation/net/http/otelhttp/test/go.mod b/instrumentation/net/http/otelhttp/test/go.mod index b92015934e5..e45cee1a55f 100644 --- a/instrumentation/net/http/otelhttp/test/go.mod +++ b/instrumentation/net/http/otelhttp/test/go.mod @@ -4,11 +4,14 @@ go 1.15 require ( github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.22.0 + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 - go.opentelemetry.io/otel/metric v0.22.0 + go.opentelemetry.io/otel/metric v0.23.0 go.opentelemetry.io/otel/sdk v1.0.0-RC3 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) -replace go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.22.0 => ../ +replace ( + go.opentelemetry.io/contrib => ../../../../../ + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp => ../ +) diff --git a/instrumentation/net/http/otelhttp/test/go.sum b/instrumentation/net/http/otelhttp/test/go.sum index 1bc228dae41..56d4dff5848 100644 --- a/instrumentation/net/http/otelhttp/test/go.sum +++ b/instrumentation/net/http/otelhttp/test/go.sum @@ -9,19 +9,14 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/contrib v0.22.0 h1:0F7gDEjgb1WGn4ODIjaCAg75hmqF+UN0LiVgwxsCodc= -go.opentelemetry.io/contrib v0.22.0/go.mod h1:EH4yDYeNoaTqn/8yCWQmfNB78VHfGX2Jt2bvnvzBlGM= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7 h1:iGu644GcxtEcrInvDsQRCwJjtCIOlT2V7IRt6ah2Whw= diff --git a/instrumentation/runtime/example/go.mod b/instrumentation/runtime/example/go.mod index 7226a14bde1..2f0c5e384c3 100644 --- a/instrumentation/runtime/example/go.mod +++ b/instrumentation/runtime/example/go.mod @@ -8,8 +8,8 @@ replace ( ) require ( - go.opentelemetry.io/contrib/instrumentation/runtime v0.22.0 - go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.22.0 - go.opentelemetry.io/otel/metric v0.22.0 - go.opentelemetry.io/otel/sdk/metric v0.22.0 + go.opentelemetry.io/contrib/instrumentation/runtime v0.23.0 + go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.23.0 + go.opentelemetry.io/otel/metric v0.23.0 + go.opentelemetry.io/otel/sdk/metric v0.23.0 ) diff --git a/instrumentation/runtime/example/go.sum b/instrumentation/runtime/example/go.sum index 5388e0e9250..018c0566708 100644 --- a/instrumentation/runtime/example/go.sum +++ b/instrumentation/runtime/example/go.sum @@ -9,24 +9,24 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/otel v1.0.0-RC1 h1:4CeoX93DNTWt8awGK9JmNXzF9j7TyOu9upscEdtcdXc= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= -go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.22.0 h1:80zr1fmoIZBBEOcVnAIHdwgOhh0K03RMYTJWIoCCiM4= -go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.22.0/go.mod h1:Rr5CP504/kg8q8PXzBUBqfJDRlDtK/TQuQm0Y7mU1QE= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1 h1:G685iP3XiskCwk/z0eIabL55XUl2gk0cljhGk9sB0Yk= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/sdk v1.0.0-RC1 h1:Sy2VLOOg24bipyC29PhuMXYNJrLsxkie8hyI7kUlG9Q= -go.opentelemetry.io/otel/sdk v1.0.0-RC1/go.mod h1:kj6yPn7Pgt5ByRuwesbaWcRLA+V7BSDg3Hf8xRvsvf8= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0 h1:6huidwh9LZi/+lvFw7EQ+m+pVmlfhOMd9s9PmTXAgeo= -go.opentelemetry.io/otel/sdk/export/metric v0.22.0/go.mod h1:a14rf2CiHSn9xjB6cHuv0HoZGl5C4w2PAgl+Lja1VzU= -go.opentelemetry.io/otel/sdk/metric v0.22.0 h1:ZBagqeLlTgEmvxtaN3GkvmbmG+XWKDwS+amr8EsSMDo= -go.opentelemetry.io/otel/sdk/metric v0.22.0/go.mod h1:LzkI0G0z6KhEagqmzgk3bw/dglE2Tk2OXs455UMcI0s= -go.opentelemetry.io/otel/trace v1.0.0-RC1 h1:jrjqKJZEibFrDz+umEASeU3LvdVyWKlnTh7XEfwrT58= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= +go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= +go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.23.0 h1:18DBDmxn/HbsKvkU715C5zJA2Nz+5m72GfvE1Km7x0Q= +go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v0.23.0/go.mod h1:JhWmMa+W0p7dWrH5aiZY5c+pi5E1/gR1gv+L+8lDW1E= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= +go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= +go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0 h1:7NeoKPPx6NdZBVHLEp/LY5Lq85Ff1WNZnuJkuRy+azw= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0/go.mod h1:SuMiREmKVRIwFKq73zvGTvwFpxb/ZAYkMfyqMoOtDqs= +go.opentelemetry.io/otel/sdk/metric v0.23.0 h1:xlZhPbiue1+jjSFEth94q9QCmX8Q24mOtue9IAmlVyI= +go.opentelemetry.io/otel/sdk/metric v0.23.0/go.mod h1:wa0sKK13eeIFW+0OFjcC3S1i7FTRRiLAXe1kjBVbhwg= +go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= +go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= +golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7 h1:iGu644GcxtEcrInvDsQRCwJjtCIOlT2V7IRt6ah2Whw= +golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= diff --git a/instrumentation/runtime/go.mod b/instrumentation/runtime/go.mod index a4406c1d35c..f5f01b532c7 100644 --- a/instrumentation/runtime/go.mod +++ b/instrumentation/runtime/go.mod @@ -6,6 +6,6 @@ replace go.opentelemetry.io/contrib => ../.. require ( github.com/stretchr/testify v1.7.0 - go.opentelemetry.io/contrib v0.22.0 - go.opentelemetry.io/otel/metric v0.22.0 + go.opentelemetry.io/contrib v0.23.0 + go.opentelemetry.io/otel/metric v0.23.0 ) diff --git a/instrumentation/runtime/go.sum b/instrumentation/runtime/go.sum index 171e97c44f3..415dd8bc3ad 100644 --- a/instrumentation/runtime/go.sum +++ b/instrumentation/runtime/go.sum @@ -7,16 +7,14 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -go.opentelemetry.io/otel v1.0.0-RC1 h1:4CeoX93DNTWt8awGK9JmNXzF9j7TyOu9upscEdtcdXc= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= -go.opentelemetry.io/otel/internal/metric v0.22.0 h1:Q9bS02XRykSRIbggaU4hVF9oWOP9PyILu26zJWoKmk0= -go.opentelemetry.io/otel/internal/metric v0.22.0/go.mod h1:7qVuMihW/ktMonEfOvBXuh6tfMvvEyoIDgeJNRloYbQ= -go.opentelemetry.io/otel/metric v0.22.0 h1:/qv10BzznqEifrXBwsTT370OCN1PRgt+mnjzMwxJKrQ= -go.opentelemetry.io/otel/metric v0.22.0/go.mod h1:KcsUkBiYGW003DJ+ugd2aqIRIfjabD9jeOUXqsAtrq0= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1 h1:G685iP3XiskCwk/z0eIabL55XUl2gk0cljhGk9sB0Yk= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/trace v1.0.0-RC1 h1:jrjqKJZEibFrDz+umEASeU3LvdVyWKlnTh7XEfwrT58= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= +go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= +go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= +go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= diff --git a/instrumentation/runtime/runtime.go b/instrumentation/runtime/runtime.go index 459371da5ec..3558f2d414a 100644 --- a/instrumentation/runtime/runtime.go +++ b/instrumentation/runtime/runtime.go @@ -116,7 +116,7 @@ func Start(opts ...Option) error { func (r *runtime) register() error { startTime := time.Now() - if _, err := r.meter.NewInt64SumObserver( + if _, err := r.meter.NewInt64CounterObserver( "runtime.uptime", func(_ context.Context, result metric.Int64ObserverResult) { result.Observe(time.Since(startTime).Milliseconds()) @@ -127,7 +127,7 @@ func (r *runtime) register() error { return err } - if _, err := r.meter.NewInt64UpDownSumObserver( + if _, err := r.meter.NewInt64UpDownCounterObserver( "runtime.go.goroutines", func(_ context.Context, result metric.Int64ObserverResult) { result.Observe(int64(goruntime.NumGoroutine())) @@ -137,7 +137,7 @@ func (r *runtime) register() error { return err } - if _, err := r.meter.NewInt64SumObserver( + if _, err := r.meter.NewInt64CounterObserver( "runtime.go.cgo.calls", func(_ context.Context, result metric.Int64ObserverResult) { result.Observe(goruntime.NumCgoCall()) @@ -154,21 +154,21 @@ func (r *runtime) registerMemStats() error { var ( err error - heapAlloc metric.Int64UpDownSumObserver - heapIdle metric.Int64UpDownSumObserver - heapInuse metric.Int64UpDownSumObserver - heapObjects metric.Int64UpDownSumObserver - heapReleased metric.Int64UpDownSumObserver - heapSys metric.Int64UpDownSumObserver - liveObjects metric.Int64UpDownSumObserver + heapAlloc metric.Int64UpDownCounterObserver + heapIdle metric.Int64UpDownCounterObserver + heapInuse metric.Int64UpDownCounterObserver + heapObjects metric.Int64UpDownCounterObserver + heapReleased metric.Int64UpDownCounterObserver + heapSys metric.Int64UpDownCounterObserver + liveObjects metric.Int64UpDownCounterObserver // TODO: is ptrLookups useful? I've not seen a value // other than zero. - ptrLookups metric.Int64SumObserver + ptrLookups metric.Int64CounterObserver - gcCount metric.Int64SumObserver - pauseTotalNs metric.Int64SumObserver - gcPauseNs metric.Int64ValueRecorder + gcCount metric.Int64CounterObserver + pauseTotalNs metric.Int64CounterObserver + gcPauseNs metric.Int64Histogram lastNumGC uint32 lastMemStats time.Time @@ -210,7 +210,7 @@ func (r *runtime) registerMemStats() error { lastNumGC = memStats.NumGC }) - if heapAlloc, err = batchObserver.NewInt64UpDownSumObserver( + if heapAlloc, err = batchObserver.NewInt64UpDownCounterObserver( "runtime.go.mem.heap_alloc", metric.WithUnit(unit.Bytes), metric.WithDescription("Bytes of allocated heap objects"), @@ -218,7 +218,7 @@ func (r *runtime) registerMemStats() error { return err } - if heapIdle, err = batchObserver.NewInt64UpDownSumObserver( + if heapIdle, err = batchObserver.NewInt64UpDownCounterObserver( "runtime.go.mem.heap_idle", metric.WithUnit(unit.Bytes), metric.WithDescription("Bytes in idle (unused) spans"), @@ -226,7 +226,7 @@ func (r *runtime) registerMemStats() error { return err } - if heapInuse, err = batchObserver.NewInt64UpDownSumObserver( + if heapInuse, err = batchObserver.NewInt64UpDownCounterObserver( "runtime.go.mem.heap_inuse", metric.WithUnit(unit.Bytes), metric.WithDescription("Bytes in in-use spans"), @@ -234,7 +234,7 @@ func (r *runtime) registerMemStats() error { return err } - if heapObjects, err = batchObserver.NewInt64UpDownSumObserver( + if heapObjects, err = batchObserver.NewInt64UpDownCounterObserver( "runtime.go.mem.heap_objects", metric.WithDescription("Number of allocated heap objects"), ); err != nil { @@ -243,7 +243,7 @@ func (r *runtime) registerMemStats() error { // FYI see https://github.com/golang/go/issues/32284 to help // understand the meaning of this value. - if heapReleased, err = batchObserver.NewInt64UpDownSumObserver( + if heapReleased, err = batchObserver.NewInt64UpDownCounterObserver( "runtime.go.mem.heap_released", metric.WithUnit(unit.Bytes), metric.WithDescription("Bytes of idle spans whose physical memory has been returned to the OS"), @@ -251,7 +251,7 @@ func (r *runtime) registerMemStats() error { return err } - if heapSys, err = batchObserver.NewInt64UpDownSumObserver( + if heapSys, err = batchObserver.NewInt64UpDownCounterObserver( "runtime.go.mem.heap_sys", metric.WithUnit(unit.Bytes), metric.WithDescription("Bytes of heap memory obtained from the OS"), @@ -259,21 +259,21 @@ func (r *runtime) registerMemStats() error { return err } - if ptrLookups, err = batchObserver.NewInt64SumObserver( + if ptrLookups, err = batchObserver.NewInt64CounterObserver( "runtime.go.mem.lookups", metric.WithDescription("Number of pointer lookups performed by the runtime"), ); err != nil { return err } - if liveObjects, err = batchObserver.NewInt64UpDownSumObserver( + if liveObjects, err = batchObserver.NewInt64UpDownCounterObserver( "runtime.go.mem.live_objects", metric.WithDescription("Number of live objects is the number of cumulative Mallocs - Frees"), ); err != nil { return err } - if gcCount, err = batchObserver.NewInt64SumObserver( + if gcCount, err = batchObserver.NewInt64CounterObserver( "runtime.go.gc.count", metric.WithDescription("Number of completed garbage collection cycles"), ); err != nil { @@ -283,7 +283,7 @@ func (r *runtime) registerMemStats() error { // Note that the following could be derived as a sum of // individual pauses, but we may lose individual pauses if the // observation interval is too slow. - if pauseTotalNs, err = batchObserver.NewInt64SumObserver( + if pauseTotalNs, err = batchObserver.NewInt64CounterObserver( "runtime.go.gc.pause_total_ns", // TODO: nanoseconds units metric.WithDescription("Cumulative nanoseconds in GC stop-the-world pauses since the program started"), @@ -291,7 +291,7 @@ func (r *runtime) registerMemStats() error { return err } - if gcPauseNs, err = r.meter.NewInt64ValueRecorder( + if gcPauseNs, err = r.meter.NewInt64Histogram( "runtime.go.gc.pause_ns", // TODO: nanoseconds units metric.WithDescription("Amount of nanoseconds in GC stop-the-world pauses"), @@ -304,7 +304,7 @@ func (r *runtime) registerMemStats() error { func computeGCPauses( ctx context.Context, - recorder *metric.Int64ValueRecorder, + recorder *metric.Int64Histogram, circular []uint64, lastNumGC, currentNumGC uint32, ) { @@ -336,7 +336,7 @@ func computeGCPauses( func recordGCPauses( ctx context.Context, - recorder *metric.Int64ValueRecorder, + recorder *metric.Int64Histogram, pauses []uint64, ) { for _, pause := range pauses { diff --git a/propagators/opencensus/binary.go b/propagators/opencensus/binary.go index 493ceeb0612..ae355c0dfe4 100644 --- a/propagators/opencensus/binary.go +++ b/propagators/opencensus/binary.go @@ -19,7 +19,7 @@ import ( ocpropagation "go.opencensus.io/trace/propagation" - "go.opentelemetry.io/otel/bridge/opencensus/utils" + "go.opentelemetry.io/otel/bridge/opencensus" "go.opentelemetry.io/otel/propagation" "go.opentelemetry.io/otel/trace" ) @@ -50,7 +50,7 @@ func (b Binary) Inject(ctx context.Context, carrier propagation.TextMapCarrier) if !sc.IsValid() { return } - h := ocpropagation.Binary(utils.OTelSpanContextToOC(sc)) + h := ocpropagation.Binary(opencensus.OTelSpanContextToOC(sc)) carrier.Set(binaryHeader, string(h)) } @@ -77,7 +77,7 @@ func (b Binary) extract(carrier propagation.TextMapCarrier) trace.SpanContext { if !ok { return trace.SpanContext{} } - return utils.OCSpanContextToOTel(ocContext) + return opencensus.OCSpanContextToOTel(ocContext) } // Fields returns the fields that this propagator modifies. diff --git a/propagators/opencensus/examples/go.mod b/propagators/opencensus/examples/go.mod index 9acc309e445..b4cb283068c 100644 --- a/propagators/opencensus/examples/go.mod +++ b/propagators/opencensus/examples/go.mod @@ -4,8 +4,8 @@ go 1.15 require ( go.opencensus.io v0.22.6-0.20201102222123-380f4078db9f - go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.22.0 - go.opentelemetry.io/contrib/propagators/opencensus v0.22.0 + go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.23.0 + go.opentelemetry.io/contrib/propagators/opencensus v0.23.0 go.opentelemetry.io/otel v1.0.0-RC3 go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 go.opentelemetry.io/otel/sdk v1.0.0-RC3 diff --git a/propagators/opencensus/examples/go.sum b/propagators/opencensus/examples/go.sum index c1db8711119..3198b94ee14 100644 --- a/propagators/opencensus/examples/go.sum +++ b/propagators/opencensus/examples/go.sum @@ -60,21 +60,20 @@ github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5Cc github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= go.opencensus.io v0.22.6-0.20201102222123-380f4078db9f h1:IUmbcoP9XyEXW+R9AbrZgDvaYVfTbISN92Y5RIV+Mx4= go.opencensus.io v0.22.6-0.20201102222123-380f4078db9f/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/bridge/opencensus v0.21.0 h1:nh1dbfqtYg9C2iAzwz+0Tu/pcwcdfCzDsjjeC9wPzK4= -go.opentelemetry.io/otel/bridge/opencensus v0.21.0/go.mod h1:n+nul581SULmC+SOj3cX3I+Dwt7ZCfgeDLaj5haLAAs= +go.opentelemetry.io/otel/bridge/opencensus v0.23.0 h1:j1OcDOE9ZI+WEXrYaeUMY81cOjlu6H2lebPAm9xYK5Y= +go.opentelemetry.io/otel/bridge/opencensus v0.23.0/go.mod h1:gJfSkAyFGyqmC9y9DNws07HDetzMYAdxtvr26uWmI4E= go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3 h1:ewSzc2SagdOx0up5xZPigXh1n3SLsNEslc5edHRBVcs= go.opentelemetry.io/otel/exporters/stdout/stdouttrace v1.0.0-RC3/go.mod h1:Oxmrmpdvm6lM3tkYmHKGWAhi9+9c2rrAEbwSDn0Bvv8= -go.opentelemetry.io/otel/internal/metric v0.21.0/go.mod h1:iOfAaY2YycsXfYD4kaRSbLx2LKmfpKObWBEv9QK5zFo= -go.opentelemetry.io/otel/metric v0.21.0/go.mod h1:JWCt1bjivC4iCrz/aCrM1GSw+ZcvY44KCbaeeRhzHnc= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/sdk v1.0.0-RC1/go.mod h1:kj6yPn7Pgt5ByRuwesbaWcRLA+V7BSDg3Hf8xRvsvf8= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= -go.opentelemetry.io/otel/sdk/export/metric v0.21.0/go.mod h1:gTaOMSQmL4zfsTL47desIPbPla5MyMG29lN3PzcibVg= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0 h1:7NeoKPPx6NdZBVHLEp/LY5Lq85Ff1WNZnuJkuRy+azw= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0/go.mod h1:SuMiREmKVRIwFKq73zvGTvwFpxb/ZAYkMfyqMoOtDqs= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= diff --git a/propagators/opencensus/go.mod b/propagators/opencensus/go.mod index 74e4b45233a..cab4a6ce883 100644 --- a/propagators/opencensus/go.mod +++ b/propagators/opencensus/go.mod @@ -6,6 +6,6 @@ require ( github.com/google/go-cmp v0.5.6 go.opencensus.io v0.22.6-0.20201102222123-380f4078db9f go.opentelemetry.io/otel v1.0.0-RC3 - go.opentelemetry.io/otel/bridge/opencensus v0.21.0 + go.opentelemetry.io/otel/bridge/opencensus v0.23.0 go.opentelemetry.io/otel/trace v1.0.0-RC3 ) diff --git a/propagators/opencensus/go.sum b/propagators/opencensus/go.sum index 4d7610dc225..eeb52d2f789 100644 --- a/propagators/opencensus/go.sum +++ b/propagators/opencensus/go.sum @@ -20,17 +20,18 @@ github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5Cc github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= go.opencensus.io v0.22.6-0.20201102222123-380f4078db9f h1:IUmbcoP9XyEXW+R9AbrZgDvaYVfTbISN92Y5RIV+Mx4= go.opencensus.io v0.22.6-0.20201102222123-380f4078db9f/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= -go.opentelemetry.io/otel v1.0.0-RC1/go.mod h1:x9tRa9HK4hSSq7jf2TKbqFbtt58/TGk0f9XiEYISI1I= go.opentelemetry.io/otel v1.0.0-RC3 h1:kvwiyEkiUT/JaadXzVLI/R1wDO934A7r3Bs2wEe6wqA= go.opentelemetry.io/otel v1.0.0-RC3/go.mod h1:Ka5j3ua8tZs4Rkq4Ex3hwgBgOchyPVq5S6P2lz//nKQ= -go.opentelemetry.io/otel/bridge/opencensus v0.21.0 h1:nh1dbfqtYg9C2iAzwz+0Tu/pcwcdfCzDsjjeC9wPzK4= -go.opentelemetry.io/otel/bridge/opencensus v0.21.0/go.mod h1:n+nul581SULmC+SOj3cX3I+Dwt7ZCfgeDLaj5haLAAs= -go.opentelemetry.io/otel/internal/metric v0.21.0/go.mod h1:iOfAaY2YycsXfYD4kaRSbLx2LKmfpKObWBEv9QK5zFo= -go.opentelemetry.io/otel/metric v0.21.0/go.mod h1:JWCt1bjivC4iCrz/aCrM1GSw+ZcvY44KCbaeeRhzHnc= -go.opentelemetry.io/otel/oteltest v1.0.0-RC1/go.mod h1:+eoIG0gdEOaPNftuy1YScLr1Gb4mL/9lpDkZ0JjMRq4= -go.opentelemetry.io/otel/sdk v1.0.0-RC1/go.mod h1:kj6yPn7Pgt5ByRuwesbaWcRLA+V7BSDg3Hf8xRvsvf8= -go.opentelemetry.io/otel/sdk/export/metric v0.21.0/go.mod h1:gTaOMSQmL4zfsTL47desIPbPla5MyMG29lN3PzcibVg= -go.opentelemetry.io/otel/trace v1.0.0-RC1/go.mod h1:86UHmyHWFEtWjfWPSbu0+d0Pf9Q6e1U+3ViBOc+NXAg= +go.opentelemetry.io/otel/bridge/opencensus v0.23.0 h1:j1OcDOE9ZI+WEXrYaeUMY81cOjlu6H2lebPAm9xYK5Y= +go.opentelemetry.io/otel/bridge/opencensus v0.23.0/go.mod h1:gJfSkAyFGyqmC9y9DNws07HDetzMYAdxtvr26uWmI4E= +go.opentelemetry.io/otel/internal/metric v0.23.0 h1:mPfzm9Iqhw7G2nDBmUAjFTfPqLZPbOW2k7QI57ITbaI= +go.opentelemetry.io/otel/internal/metric v0.23.0/go.mod h1:z+RPiDJe30YnCrOhFGivwBS+DU1JU/PiLKkk4re2DNY= +go.opentelemetry.io/otel/metric v0.23.0 h1:mYCcDxi60P4T27/0jchIDFa1WHEfQeU3zH9UEMpnj2c= +go.opentelemetry.io/otel/metric v0.23.0/go.mod h1:G/Nn9InyNnIv7J6YVkQfpc0JCfKBNJaERBGw08nqmVQ= +go.opentelemetry.io/otel/sdk v1.0.0-RC3 h1:iRMkET+EmJUn5mW0hJzygBraXRmrUwzbOtNvTCh/oKs= +go.opentelemetry.io/otel/sdk v1.0.0-RC3/go.mod h1:78H6hyg2fka0NYT9fqGuFLvly2yCxiBXDJAgLKo/2Us= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0 h1:7NeoKPPx6NdZBVHLEp/LY5Lq85Ff1WNZnuJkuRy+azw= +go.opentelemetry.io/otel/sdk/export/metric v0.23.0/go.mod h1:SuMiREmKVRIwFKq73zvGTvwFpxb/ZAYkMfyqMoOtDqs= go.opentelemetry.io/otel/trace v1.0.0-RC3 h1:9F0ayEvlxv8BmNmPbU005WK7hC+7KbOazCPZjNa1yME= go.opentelemetry.io/otel/trace v1.0.0-RC3/go.mod h1:VUt2TUYd8S2/ZRX09ZDFZQwn2RqfMB5MzO17jBojGxo= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= @@ -50,6 +51,8 @@ golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7 h1:iGu644GcxtEcrInvDsQRCwJjtCIOlT2V7IRt6ah2Whw= +golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=