You've already forked opentelemetry-go
mirror of
https://github.com/open-telemetry/opentelemetry-go.git
synced 2025-11-23 22:34:47 +02:00
Remove the experimental SDK (#221)
* Remove the experimental SDK * Remove the experimental SDK from README.md * Remove the experimental SDK from Makefile
This commit is contained in:
3
Makefile
3
Makefile
@@ -5,8 +5,7 @@ export GO111MODULE=on
|
||||
EXAMPLES := \
|
||||
./example/basic \
|
||||
./example/http/client \
|
||||
./example/http/server \
|
||||
./experimental/streaming/example/basic
|
||||
./example/http/server
|
||||
|
||||
# All source code and documents. Used in spell check.
|
||||
ALL_DOCS := $(shell find . -name '*.md' -type f | sort)
|
||||
|
||||
@@ -105,12 +105,3 @@ attempt to maintain backwards compatibility with the alpha release.
|
||||
| Trace Context Propagation | Alpha | Unknown |
|
||||
| OpenTracing Bridge | Alpha | October |
|
||||
| OpenCensus Bridge | Alpha | Unknown |
|
||||
|
||||
## Experimental streaming SDK
|
||||
|
||||
The `experimental/streaming` directory contains an experimental SDK
|
||||
that supports a low-level exporter.
|
||||
|
||||
```
|
||||
go run experimental/streaming/example/basic/main.go
|
||||
```
|
||||
|
||||
@@ -1,7 +0,0 @@
|
||||
module github.com/open-telemetry/opentelemetry-go/experimental/streaming/example/basic
|
||||
|
||||
go 1.12
|
||||
|
||||
replace go.opentelemetry.io => ../../../..
|
||||
|
||||
require go.opentelemetry.io v0.0.0-00010101000000-000000000000
|
||||
@@ -1,367 +0,0 @@
|
||||
cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
|
||||
cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
|
||||
cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU=
|
||||
cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU=
|
||||
cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY=
|
||||
cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc=
|
||||
cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0=
|
||||
cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o=
|
||||
cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE=
|
||||
cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I=
|
||||
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
|
||||
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
|
||||
github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU=
|
||||
github.com/OpenPeeDeeP/depguard v1.0.1/go.mod h1:xsIw86fROiiwelg+jB2uM9PiKihMMmUx/1V+TNhjQvM=
|
||||
github.com/StackExchange/wmi v0.0.0-20180116203802-5d049714c4a6/go.mod h1:3eOhrUMpNV+6aFIbp5/iudMxNCF27Vw2OZgy4xEx0Fg=
|
||||
github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc=
|
||||
github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0=
|
||||
github.com/apache/thrift v0.12.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ=
|
||||
github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8=
|
||||
github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q=
|
||||
github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8=
|
||||
github.com/bombsimon/wsl v1.2.5/go.mod h1:43lEF/i0kpXbLCeDXL9LMT8c92HyBywXb0AsgMHYngM=
|
||||
github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc=
|
||||
github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw=
|
||||
github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk=
|
||||
github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
|
||||
github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk=
|
||||
github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
|
||||
github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
|
||||
github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA=
|
||||
github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE=
|
||||
github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY=
|
||||
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
|
||||
github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no=
|
||||
github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
|
||||
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
|
||||
github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
|
||||
github.com/go-critic/go-critic v0.3.5-0.20190904082202-d79a9f0c64db/go.mod h1:+sE8vrLDS2M0pZkBk0wy6+nLdKexVDrl/jBqQOTDThA=
|
||||
github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
|
||||
github.com/go-lintpack/lintpack v0.5.2/go.mod h1:NwZuYi2nUHho8XEIZ6SIxihrnPoqBTDqfpXvXAN0sXM=
|
||||
github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE=
|
||||
github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk=
|
||||
github.com/go-ole/go-ole v1.2.1/go.mod h1:7FAglXiTm7HKlQRDeOQ6ZNUHidzCWXuZWq/1dTyBNF8=
|
||||
github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY=
|
||||
github.com/go-toolsmith/astcast v1.0.0/go.mod h1:mt2OdQTeAQcY4DQgPSArJjHCcOwlX+Wl/kwN+LbLGQ4=
|
||||
github.com/go-toolsmith/astcopy v1.0.0/go.mod h1:vrgyG+5Bxrnz4MZWPF+pI4R8h3qKRjjyvV/DSez4WVQ=
|
||||
github.com/go-toolsmith/astequal v0.0.0-20180903214952-dcb477bfacd6/go.mod h1:H+xSiq0+LtiDC11+h1G32h7Of5O3CYFJ99GVbS5lDKY=
|
||||
github.com/go-toolsmith/astequal v1.0.0/go.mod h1:H+xSiq0+LtiDC11+h1G32h7Of5O3CYFJ99GVbS5lDKY=
|
||||
github.com/go-toolsmith/astfmt v0.0.0-20180903215011-8f8ee99c3086/go.mod h1:mP93XdblcopXwlyN4X4uodxXQhldPGZbcEJIimQHrkg=
|
||||
github.com/go-toolsmith/astfmt v1.0.0/go.mod h1:cnWmsOAuq4jJY6Ct5YWlVLmcmLMn1JUPuQIHCY7CJDw=
|
||||
github.com/go-toolsmith/astinfo v0.0.0-20180906194353-9809ff7efb21/go.mod h1:dDStQCHtmZpYOmjRP/8gHHnCCch3Zz3oEgCdZVdtweU=
|
||||
github.com/go-toolsmith/astp v0.0.0-20180903215135-0af7e3c24f30/go.mod h1:SV2ur98SGypH1UjcPpCatrV5hPazG6+IfNHbkDXBRrk=
|
||||
github.com/go-toolsmith/astp v1.0.0/go.mod h1:RSyrtpVlfTFGDYRbrjyWP1pYu//tSFcvdYrA8meBmLI=
|
||||
github.com/go-toolsmith/pkgload v0.0.0-20181119091011-e9e65178eee8/go.mod h1:WoMrjiy4zvdS+Bg6z9jZH82QXwkcgCBX6nOfnmdaHks=
|
||||
github.com/go-toolsmith/pkgload v1.0.0/go.mod h1:5eFArkbO80v7Z0kdngIxsRXRMTaX4Ilcwuh3clNrQJc=
|
||||
github.com/go-toolsmith/strparse v1.0.0/go.mod h1:YI2nUKP9YGZnL/L1/DLFBfixrcjslWct4wyljWhSRy8=
|
||||
github.com/go-toolsmith/typep v1.0.0/go.mod h1:JSQCQMUPdRlMZFswiq3TGpNp1GMktqkR2Ns5AIQkATU=
|
||||
github.com/gobwas/glob v0.2.3/go.mod h1:d3Ez4x06l9bZtSvzIay5+Yzi0fmZzPgnTbPcKjJAkT8=
|
||||
github.com/gofrs/flock v0.0.0-20190320160742-5135e617513b/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU=
|
||||
github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ=
|
||||
github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4=
|
||||
github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o=
|
||||
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
|
||||
github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
|
||||
github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
|
||||
github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
|
||||
github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y=
|
||||
github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
|
||||
github.com/golang/protobuf v1.3.1 h1:YF8+flBXS5eO826T4nzqPrxfhQThhXl0YzfuUPu4SBg=
|
||||
github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
|
||||
github.com/golang/protobuf v1.3.2 h1:6nsPYzhq5kReh6QImI3k5qWzO4PEbvbIW2cwSfR/6xs=
|
||||
github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
|
||||
github.com/golangci/check v0.0.0-20180506172741-cfe4005ccda2/go.mod h1:k9Qvh+8juN+UKMCS/3jFtGICgW8O96FVaZsaxdzDkR4=
|
||||
github.com/golangci/dupl v0.0.0-20180902072040-3e9179ac440a/go.mod h1:ryS0uhF+x9jgbj/N71xsEqODy9BN81/GonCZiOzirOk=
|
||||
github.com/golangci/errcheck v0.0.0-20181223084120-ef45e06d44b6/go.mod h1:DbHgvLiFKX1Sh2T1w8Q/h4NAI8MHIpzCdnBUDTXU3I0=
|
||||
github.com/golangci/go-misc v0.0.0-20180628070357-927a3d87b613/go.mod h1:SyvUF2NxV+sN8upjjeVYr5W7tyxaT1JVtvhKhOn2ii8=
|
||||
github.com/golangci/goconst v0.0.0-20180610141641-041c5f2b40f3/go.mod h1:JXrF4TWy4tXYn62/9x8Wm/K/dm06p8tCKwFRDPZG/1o=
|
||||
github.com/golangci/gocyclo v0.0.0-20180528134321-2becd97e67ee/go.mod h1:ozx7R9SIwqmqf5pRP90DhR2Oay2UIjGuKheCBCNwAYU=
|
||||
github.com/golangci/gocyclo v0.0.0-20180528144436-0a533e8fa43d/go.mod h1:ozx7R9SIwqmqf5pRP90DhR2Oay2UIjGuKheCBCNwAYU=
|
||||
github.com/golangci/gofmt v0.0.0-20190930125516-244bba706f1a/go.mod h1:9qCChq59u/eW8im404Q2WWTrnBUQKjpNYKMbU4M7EFU=
|
||||
github.com/golangci/golangci-lint v1.21.0/go.mod h1:phxpHK52q7SE+5KpPnti4oZTdFCEsn/tKN+nFvCKXfk=
|
||||
github.com/golangci/ineffassign v0.0.0-20190609212857-42439a7714cc/go.mod h1:e5tpTHCfVze+7EpLEozzMB3eafxo2KT5veNg1k6byQU=
|
||||
github.com/golangci/lint-1 v0.0.0-20191013205115-297bf364a8e0/go.mod h1:66R6K6P6VWk9I95jvqGxkqJxVWGFy9XlDwLwVz1RCFg=
|
||||
github.com/golangci/maligned v0.0.0-20180506175553-b1d89398deca/go.mod h1:tvlJhZqDe4LMs4ZHD0oMUlt9G2LWuDGoisJTBzLMV9o=
|
||||
github.com/golangci/misspell v0.0.0-20180809174111-950f5d19e770/go.mod h1:dEbvlSfYbMQDtrpRMQU675gSDLDNa8sCPPChZ7PhiVA=
|
||||
github.com/golangci/prealloc v0.0.0-20180630174525-215b22d4de21/go.mod h1:tf5+bzsHdTM0bsB7+8mt0GUMvjCgwLpTapNZHU8AajI=
|
||||
github.com/golangci/revgrep v0.0.0-20180526074752-d9c87f5ffaf0/go.mod h1:qOQCunEYvmd/TLamH+7LlVccLvUH5kZNhbCgTHoBbp4=
|
||||
github.com/golangci/revgrep v0.0.0-20180812185044-276a5c0a1039/go.mod h1:qOQCunEYvmd/TLamH+7LlVccLvUH5kZNhbCgTHoBbp4=
|
||||
github.com/golangci/unconvert v0.0.0-20180507085042-28b1c447d1f4/go.mod h1:Izgrg8RkN3rCIMLGE9CyYmU9pY2Jer6DgANEnZ/L/cQ=
|
||||
github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
|
||||
github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ=
|
||||
github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M=
|
||||
github.com/google/go-cmp v0.3.0 h1:crn/baboCvb5fXaQ0IJ1SGTsTVrWpDsCWC8EGETZijY=
|
||||
github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
|
||||
github.com/google/go-cmp v0.3.1 h1:Xye71clBPdm5HgqGwUkwhbynsUJZhDbS20FvLhQ2izg=
|
||||
github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
|
||||
github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs=
|
||||
github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc=
|
||||
github.com/google/pprof v0.0.0-20190515194954-54271f7e092f/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc=
|
||||
github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI=
|
||||
github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg=
|
||||
github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk=
|
||||
github.com/gorilla/websocket v1.4.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ=
|
||||
github.com/gostaticanalysis/analysisutil v0.0.0-20190318220348-4088753ea4d3/go.mod h1:eEOZF4jCKGi+aprrirO9e7WKB3beBRtWgqGunKl6pKE=
|
||||
github.com/gostaticanalysis/analysisutil v0.0.3/go.mod h1:eEOZF4jCKGi+aprrirO9e7WKB3beBRtWgqGunKl6pKE=
|
||||
github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs=
|
||||
github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk=
|
||||
github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY=
|
||||
github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
|
||||
github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8=
|
||||
github.com/hashicorp/golang-lru v0.5.3/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4=
|
||||
github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ=
|
||||
github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU=
|
||||
github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8=
|
||||
github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo=
|
||||
github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU=
|
||||
github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w=
|
||||
github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q=
|
||||
github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00=
|
||||
github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
|
||||
github.com/klauspost/compress v1.4.0/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A=
|
||||
github.com/klauspost/compress v1.4.1/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A=
|
||||
github.com/klauspost/cpuid v0.0.0-20180405133222-e7e905edc00e/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek=
|
||||
github.com/klauspost/cpuid v1.2.0/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek=
|
||||
github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
|
||||
github.com/konsorten/go-windows-terminal-sequences v1.0.2/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
|
||||
github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc=
|
||||
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
|
||||
github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
|
||||
github.com/kr/pty v1.1.8/go.mod h1:O1sed60cT9XZ5uDucP5qwvh+TE3NnUj51EiZO/lmSfw=
|
||||
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
|
||||
github.com/lib/pq v1.2.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo=
|
||||
github.com/logrusorgru/aurora v0.0.0-20181002194514-a7b3b318ed4e/go.mod h1:7rIyQOR62GCctdiQpZ/zOJlFyk6y+94wXzv6RNZgaR4=
|
||||
github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
|
||||
github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ=
|
||||
github.com/matoous/godox v0.0.0-20190911065817-5d6d842e92eb/go.mod h1:1BELzlh859Sh1c6+90blK8lbYy0kwQf1bYlBhBysy1s=
|
||||
github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE=
|
||||
github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s=
|
||||
github.com/mattn/go-isatty v0.0.10/go.mod h1:qgIWMr58cqv1PHHyhnkY9lrL7etaEgOFcMEpPG5Rm84=
|
||||
github.com/mattn/goveralls v0.0.2/go.mod h1:8d1ZMHsd7fW6IRPKQh46F2WRpyib5/X4FOpevwGNQEw=
|
||||
github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0=
|
||||
github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
|
||||
github.com/mitchellh/go-ps v0.0.0-20190716172923-621e5597135b/go.mod h1:r1VsdOzOPt1ZSrGZWFoNhsAedKnEd6r9Np1+5blZCWk=
|
||||
github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y=
|
||||
github.com/mozilla/tls-observatory v0.0.0-20190404164649-a3c1b6cfecfd/go.mod h1:SrKMQvPiws7F7iqYp8/TX+IhxCYhzr6N/1yb8cwHsGk=
|
||||
github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U=
|
||||
github.com/nbutton23/zxcvbn-go v0.0.0-20180912185939-ae427f1e4c1d/go.mod h1:o96djdrsSGy3AWPyBgZMAGfxZNfgntdJG+11KU4QvbU=
|
||||
github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U=
|
||||
github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/ginkgo v1.10.1/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
github.com/onsi/gomega v1.7.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY=
|
||||
github.com/opentracing/opentracing-go v1.1.1-0.20190913142402-a7454ce5950e/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o=
|
||||
github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic=
|
||||
github.com/pelletier/go-toml v1.5.0/go.mod h1:5N711Q9dKgbdkxHL+MEfF31hpT7l0S0s/t2kKREewys=
|
||||
github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
|
||||
github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
|
||||
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
|
||||
github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw=
|
||||
github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso=
|
||||
github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo=
|
||||
github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
|
||||
github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro=
|
||||
github.com/prometheus/common v0.4.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4=
|
||||
github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk=
|
||||
github.com/prometheus/procfs v0.0.0-20190507164030-5867b95ac084/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA=
|
||||
github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU=
|
||||
github.com/quasilyte/go-consistent v0.0.0-20190521200055-c6f3937de18c/go.mod h1:5STLWrekHfjyYwxBRVRXNOSewLJ3PWfDJd1VyTS21fI=
|
||||
github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg=
|
||||
github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
|
||||
github.com/rogpeppe/go-internal v1.3.2/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc=
|
||||
github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g=
|
||||
github.com/securego/gosec v0.0.0-20191002120514-e680875ea14d/go.mod h1:w5+eXa0mYznDkHaMCXA4XYffjlH+cy1oyKbfzJXa2Do=
|
||||
github.com/securego/gosec v0.0.0-20191008095658-28c1128b7336/go.mod h1:w5+eXa0mYznDkHaMCXA4XYffjlH+cy1oyKbfzJXa2Do=
|
||||
github.com/shirou/gopsutil v0.0.0-20190901111213-e4ec7b275ada/go.mod h1:WWnYX4lzhCH5h/3YBfyVA3VbLYjlMZZAQcW9ojMexNc=
|
||||
github.com/shirou/w32 v0.0.0-20160930032740-bb4de0191aa4/go.mod h1:qsXQc7+bwAM3Q1u/4XEfrquwF8Lw7D7y5cD8CuHnfIc=
|
||||
github.com/shurcooL/go v0.0.0-20180423040247-9e1955d9fb6e/go.mod h1:TDJrrUr11Vxrven61rcy3hJMUqaf/CLWYhHNPmT14Lk=
|
||||
github.com/shurcooL/go-goon v0.0.0-20170922171312-37c2f522c041/go.mod h1:N5mDOmsrJOB+vfqUK+7DmDyjhSLIIBnXo9lvZJj3MWQ=
|
||||
github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo=
|
||||
github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE=
|
||||
github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM=
|
||||
github.com/sourcegraph/go-diff v0.5.1/go.mod h1:j2dHj3m8aZgQO8lMTcTnBcXkRRRqi34cd2MNlA9u1mE=
|
||||
github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA=
|
||||
github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ=
|
||||
github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk=
|
||||
github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE=
|
||||
github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU=
|
||||
github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo=
|
||||
github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo=
|
||||
github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4=
|
||||
github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg=
|
||||
github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s=
|
||||
github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE=
|
||||
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
|
||||
github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE=
|
||||
github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
|
||||
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
|
||||
github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
|
||||
github.com/timakin/bodyclose v0.0.0-20190930140734-f7f2e9bca95e/go.mod h1:Qimiffbc6q9tBWlVV6x0P9sat/ao1xEkREYPPj9hphk=
|
||||
github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U=
|
||||
github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc=
|
||||
github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0=
|
||||
github.com/ultraware/funlen v0.0.2/go.mod h1:Dp4UiAus7Wdb9KUZsYWZEWiRzGuM2kXM1lPbfaF6xhA=
|
||||
github.com/ultraware/whitespace v0.0.4/go.mod h1:aVMh/gQve5Maj9hQ/hg+F75lr/X5A89uZnzAmWSineA=
|
||||
github.com/uudashr/gocognit v0.0.0-20190926065955-1655d0de0517/go.mod h1:j44Ayx2KW4+oB6SWMv8KsmHzZrOInQav7D3cQMJ5JUM=
|
||||
github.com/uudashr/gocognit v1.0.0/go.mod h1:j44Ayx2KW4+oB6SWMv8KsmHzZrOInQav7D3cQMJ5JUM=
|
||||
github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc=
|
||||
github.com/valyala/fasthttp v1.2.0/go.mod h1:4vX61m6KN+xDduDNwXrhIAVZaZaZiQ1luJk8LWSxF3s=
|
||||
github.com/valyala/quicktemplate v1.2.0/go.mod h1:EH+4AkTd43SvgIbQHYu59/cJyxDoOVRUAfrukLPuGJ4=
|
||||
github.com/valyala/tcplisten v0.0.0-20161114210144-ceec8f93295a/go.mod h1:v3UYOV9WzVtRmSR+PDvWpU/qWl4Wa5LApYYX4ZtKbio=
|
||||
github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU=
|
||||
github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q=
|
||||
go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU=
|
||||
go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
|
||||
go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
|
||||
go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
|
||||
go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0=
|
||||
go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q=
|
||||
golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20190923035154-9ee001bba392/go.mod h1:/lpIB1dKB+9EgE3H3cr1v9wB50oz8l4C4h62xy7jSTY=
|
||||
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
|
||||
golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
|
||||
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8=
|
||||
golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek=
|
||||
golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js=
|
||||
golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0=
|
||||
golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
|
||||
golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU=
|
||||
golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
|
||||
golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
|
||||
golang.org/x/lint v0.0.0-20190409202823-959b441ac422/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
|
||||
golang.org/x/lint v0.0.0-20190909230951-414d861bb4ac/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
|
||||
golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE=
|
||||
golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o=
|
||||
golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc=
|
||||
golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY=
|
||||
golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20180911220305-26e67e76b6c3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
|
||||
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
|
||||
golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
|
||||
golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
|
||||
golang.org/x/net v0.0.0-20190522155817-f3200d17e092/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks=
|
||||
golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks=
|
||||
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20190923162816-aa69164e4478/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
|
||||
golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
|
||||
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw=
|
||||
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
|
||||
golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/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-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190922100055-0a153f010e69/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20191008105621-543471e840be/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20191010194322-b09406accb47/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk=
|
||||
golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
|
||||
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ=
|
||||
golang.org/x/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20180525024113-a5b4c53f6e8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20181117154741-2ddaf7f79a09/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190110163146-51295c7ec13a/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
|
||||
golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY=
|
||||
golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
|
||||
golang.org/x/tools v0.0.0-20190311215038-5c2858a9cfe5/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
|
||||
golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
|
||||
golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
|
||||
golang.org/x/tools v0.0.0-20190322203728-c1a832b0ad89/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs=
|
||||
golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
||||
golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
||||
golang.org/x/tools v0.0.0-20190521203540-521d6ed310dd/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
||||
golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q=
|
||||
golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||
golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||
golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc=
|
||||
golang.org/x/tools v0.0.0-20190719005602-e377ae9d6386/go.mod h1:jcCCGcm9btYwXyDqrUWc6MKQKKGJCWEQ3AfLSRIbEuI=
|
||||
golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.0.0-20190910044552-dd2b5c81c578/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.0.0-20190911151314-feee8acb394c/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.0.0-20190930201159-7c411dea38b0/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.0.0-20191010075000-0337d82405ff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/tools v0.0.0-20191015211201-9c6d90b5a7d0/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
|
||||
golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
|
||||
google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE=
|
||||
google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M=
|
||||
google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg=
|
||||
google.golang.org/api v0.9.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg=
|
||||
google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM=
|
||||
google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4=
|
||||
google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0=
|
||||
google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc=
|
||||
google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
|
||||
google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
|
||||
google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
|
||||
google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873 h1:nfPFGzJkUDX6uBmpN/pSw7MbOAWegH5QDQuoXFHedLg=
|
||||
google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
|
||||
google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc=
|
||||
google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc=
|
||||
google.golang.org/genproto v0.0.0-20190911173649-1774047e7e51/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8=
|
||||
google.golang.org/genproto v0.0.0-20190925194540-b8fbc687dcfb h1:KyQ8P4ITs8M0jBWofeXBAlng8kJVbXKyliNX5w2w/ng=
|
||||
google.golang.org/genproto v0.0.0-20190925194540-b8fbc687dcfb/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8=
|
||||
google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
|
||||
google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38=
|
||||
google.golang.org/grpc v1.21.0/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=
|
||||
google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM=
|
||||
google.golang.org/grpc v1.24.0 h1:vb/1TCsVn3DcJlQ0Gs1yB1pKI6Do2/QNwxdKqmc/b0s=
|
||||
google.golang.org/grpc v1.24.0/go.mod h1:XDChyiUovWa60DnaeDeZmSW86xtLtjtZbwvSiRnRtcA=
|
||||
gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw=
|
||||
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
|
||||
gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
|
||||
gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
|
||||
gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo=
|
||||
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw=
|
||||
gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74=
|
||||
gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
|
||||
honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
|
||||
honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg=
|
||||
mvdan.cc/interfacer v0.0.0-20180901003855-c20040233aed/go.mod h1:Xkxe497xwlCKkIaQYRfC7CSLworTXY9RMqwhhCm+8Nc=
|
||||
mvdan.cc/lint v0.0.0-20170908181259-adc824a0674b/go.mod h1:2odslEg/xrtNQqCYg2/jCoyKnw3vv5biOc3JnIcYfL4=
|
||||
mvdan.cc/unparam v0.0.0-20190720180237-d51796306d8f/go.mod h1:4G1h5nDURzA3bwVMZIVpwbkw+04kSxk3rAtzlimaUJw=
|
||||
mvdan.cc/unparam v0.0.0-20190917161559-b83a221c10a2/go.mod h1:rCqoQrfAmpTX/h2APczwM7UymU/uvaOluiVPIYCSY/k=
|
||||
rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8=
|
||||
sourcegraph.com/sqs/pbtypes v0.0.0-20180604144634-d3ebe8f20ae4/go.mod h1:ketZ/q3QxT9HOBeFhu6RdvsftgpsbFHBF5Cas6cDKZ0=
|
||||
sourcegraph.com/sqs/pbtypes v1.0.0/go.mod h1:3AciMUv4qUuRHRHhOG4TZOB+72GdPVz5k+c648qsFS4=
|
||||
@@ -1,99 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package main
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"go.opentelemetry.io/api/distributedcontext"
|
||||
"go.opentelemetry.io/api/key"
|
||||
"go.opentelemetry.io/api/metric"
|
||||
"go.opentelemetry.io/api/trace"
|
||||
|
||||
"go.opentelemetry.io/experimental/streaming/exporter/spanlog"
|
||||
"go.opentelemetry.io/experimental/streaming/sdk"
|
||||
)
|
||||
|
||||
var (
|
||||
streaming = sdk.New(spanlog.New())
|
||||
tracer trace.Tracer = streaming
|
||||
meter metric.Meter = streaming
|
||||
|
||||
fooKey = key.New("ex.com/foo")
|
||||
barKey = key.New("ex.com/bar")
|
||||
lemonsKey = key.New("ex.com/lemons")
|
||||
anotherKey = key.New("ex.com/another")
|
||||
|
||||
oneMetric = metric.NewFloat64Gauge("ex.com/one",
|
||||
metric.WithKeys(fooKey, barKey, lemonsKey),
|
||||
metric.WithDescription("A gauge set to 1.0"),
|
||||
)
|
||||
|
||||
measureTwo = metric.NewFloat64Measure("ex.com/two")
|
||||
)
|
||||
|
||||
func main() {
|
||||
ctx := context.Background()
|
||||
|
||||
ctx = distributedcontext.NewContext(ctx,
|
||||
distributedcontext.Insert(fooKey.String("foo1")),
|
||||
distributedcontext.Insert(barKey.String("bar1")),
|
||||
)
|
||||
|
||||
commonLabels := meter.DefineLabels(ctx, lemonsKey.Int(10))
|
||||
|
||||
gauge := oneMetric.GetHandle(commonLabels)
|
||||
|
||||
measure := measureTwo.GetHandle(commonLabels)
|
||||
|
||||
err := tracer.WithSpan(ctx, "operation", func(ctx context.Context) error {
|
||||
|
||||
trace.CurrentSpan(ctx).AddEvent(ctx, "Nice operation!", key.New("bogons").Int(100))
|
||||
|
||||
trace.CurrentSpan(ctx).SetAttributes(anotherKey.String("yes"))
|
||||
|
||||
gauge.Set(ctx, 1)
|
||||
|
||||
meter.RecordBatch(
|
||||
// Note: call-site variables added as context entries:
|
||||
distributedcontext.NewContext(ctx,
|
||||
distributedcontext.Insert(anotherKey.String("xyz"))),
|
||||
commonLabels,
|
||||
|
||||
oneMetric.Measurement(1.0),
|
||||
measureTwo.Measurement(2.0),
|
||||
)
|
||||
|
||||
return tracer.WithSpan(
|
||||
ctx,
|
||||
"Sub operation...",
|
||||
func(ctx context.Context) error {
|
||||
trace.CurrentSpan(ctx).SetAttribute(lemonsKey.String("five"))
|
||||
|
||||
trace.CurrentSpan(ctx).AddEvent(ctx, "Sub span event")
|
||||
|
||||
measure.Record(ctx, 1.3)
|
||||
|
||||
return nil
|
||||
},
|
||||
)
|
||||
})
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
// TODO: How to flush?
|
||||
// loader.Flush()
|
||||
}
|
||||
@@ -1,74 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package buffer
|
||||
|
||||
import (
|
||||
"sync"
|
||||
"sync/atomic"
|
||||
|
||||
"go.opentelemetry.io/experimental/streaming/exporter"
|
||||
)
|
||||
|
||||
type Buffer struct {
|
||||
observers []exporter.Observer
|
||||
events chan exporter.Event
|
||||
dropped uint64
|
||||
wait sync.WaitGroup
|
||||
close chan struct{}
|
||||
}
|
||||
|
||||
func NewBuffer(size int, observers ...exporter.Observer) *Buffer {
|
||||
b := &Buffer{
|
||||
observers: observers,
|
||||
events: make(chan exporter.Event, size),
|
||||
close: make(chan struct{}),
|
||||
}
|
||||
b.wait.Add(1)
|
||||
go b.run()
|
||||
return b
|
||||
}
|
||||
|
||||
func (b *Buffer) Observe(data exporter.Event) {
|
||||
select {
|
||||
case b.events <- data:
|
||||
default:
|
||||
atomic.AddUint64(&b.dropped, 1)
|
||||
}
|
||||
}
|
||||
|
||||
func (b *Buffer) Close() {
|
||||
close(b.close)
|
||||
b.wait.Wait()
|
||||
}
|
||||
|
||||
func (b *Buffer) run() {
|
||||
defer func() {
|
||||
_ = recover()
|
||||
b.wait.Done()
|
||||
}()
|
||||
|
||||
for {
|
||||
select {
|
||||
case <-b.close:
|
||||
return
|
||||
case ev := <-b.events:
|
||||
// TODO: This has to ensure ordered arrival,
|
||||
// e.g., put into a heap and delay observations.
|
||||
for _, obs := range b.observers {
|
||||
obs.Observe(ev)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package buffer // import "go.opentelemetry.io/experimental/streaming/exporter/buffer"
|
||||
@@ -1,32 +0,0 @@
|
||||
// Code generated by "stringer -type=EventType"; DO NOT EDIT.
|
||||
|
||||
package exporter
|
||||
|
||||
import "strconv"
|
||||
|
||||
func _() {
|
||||
// An "invalid array index" compiler error signifies that the constant values have changed.
|
||||
// Re-run the stringer command to generate them again.
|
||||
var x [1]struct{}
|
||||
_ = x[INVALID-0]
|
||||
_ = x[START_SPAN-1]
|
||||
_ = x[END_SPAN-2]
|
||||
_ = x[ADD_EVENT-3]
|
||||
_ = x[NEW_SCOPE-4]
|
||||
_ = x[MODIFY_ATTR-5]
|
||||
_ = x[SET_STATUS-6]
|
||||
_ = x[SET_NAME-7]
|
||||
_ = x[SINGLE_METRIC-8]
|
||||
_ = x[BATCH_METRIC-9]
|
||||
}
|
||||
|
||||
const _EventType_name = "INVALIDSTART_SPANEND_SPANADD_EVENTNEW_SCOPEMODIFY_ATTRSET_STATUSSET_NAMESINGLE_METRICBATCH_METRIC"
|
||||
|
||||
var _EventType_index = [...]uint8{0, 7, 17, 25, 34, 43, 54, 64, 72, 85, 97}
|
||||
|
||||
func (i EventType) String() string {
|
||||
if i < 0 || i >= EventType(len(_EventType_index)-1) {
|
||||
return "EventType(" + strconv.FormatInt(int64(i), 10) + ")"
|
||||
}
|
||||
return _EventType_name[_EventType_index[i]:_EventType_index[i+1]]
|
||||
}
|
||||
@@ -1,115 +0,0 @@
|
||||
package exporter
|
||||
|
||||
import (
|
||||
"context"
|
||||
"sync/atomic"
|
||||
"time"
|
||||
|
||||
"google.golang.org/grpc/codes"
|
||||
|
||||
"go.opentelemetry.io/api/core"
|
||||
"go.opentelemetry.io/api/distributedcontext"
|
||||
"go.opentelemetry.io/api/metric"
|
||||
)
|
||||
|
||||
type EventType int
|
||||
|
||||
type EventID uint64
|
||||
|
||||
type ScopeID struct {
|
||||
EventID
|
||||
core.SpanContext
|
||||
}
|
||||
|
||||
type Event struct {
|
||||
// Automatic fields
|
||||
Sequence EventID // Auto-filled
|
||||
Time time.Time // Auto-filled
|
||||
|
||||
// Type, Scope, Context
|
||||
Type EventType // All events
|
||||
Scope ScopeID // All events
|
||||
Context context.Context // core.FromContext() and scope.Active()
|
||||
|
||||
// Arguments (type-specific)
|
||||
Attribute core.KeyValue // SET_ATTRIBUTE
|
||||
Attributes []core.KeyValue // SET_ATTRIBUTES
|
||||
Mutator distributedcontext.Mutator // SET_ATTRIBUTE
|
||||
Mutators []distributedcontext.Mutator // SET_ATTRIBUTES
|
||||
Recovered interface{} // END_SPAN
|
||||
Status codes.Code // SET_STATUS
|
||||
|
||||
// Values
|
||||
String string // START_SPAN, EVENT, SET_NAME, ...
|
||||
Parent ScopeID // START_SPAN
|
||||
Measurement metric.Measurement
|
||||
Measurements []metric.Measurement
|
||||
}
|
||||
|
||||
type Observer interface {
|
||||
Observe(data Event)
|
||||
}
|
||||
|
||||
//go:generate stringer -type=EventType
|
||||
// nolint:golint
|
||||
const (
|
||||
INVALID EventType = iota
|
||||
START_SPAN
|
||||
END_SPAN
|
||||
ADD_EVENT
|
||||
NEW_SCOPE
|
||||
MODIFY_ATTR
|
||||
SET_STATUS
|
||||
SET_NAME
|
||||
SINGLE_METRIC // A metric Set(), Add(), Record()
|
||||
BATCH_METRIC // A RecordBatch()
|
||||
)
|
||||
|
||||
type Exporter struct {
|
||||
sequence uint64
|
||||
observers []Observer
|
||||
}
|
||||
|
||||
func NewExporter(observers ...Observer) *Exporter {
|
||||
return &Exporter{
|
||||
observers: observers,
|
||||
}
|
||||
}
|
||||
|
||||
func (e *Exporter) NextEventID() EventID {
|
||||
return EventID(atomic.AddUint64(&e.sequence, 1))
|
||||
}
|
||||
|
||||
func (e *Exporter) Record(event Event) EventID {
|
||||
if event.Sequence == 0 {
|
||||
event.Sequence = e.NextEventID()
|
||||
}
|
||||
if event.Time.IsZero() {
|
||||
event.Time = time.Now()
|
||||
}
|
||||
for _, observer := range e.observers {
|
||||
observer.Observe(event)
|
||||
}
|
||||
return event.Sequence
|
||||
}
|
||||
|
||||
func (e *Exporter) Foreach(f func(Observer)) {
|
||||
for _, observer := range e.observers {
|
||||
f(observer)
|
||||
}
|
||||
}
|
||||
|
||||
func (e *Exporter) NewScope(parent ScopeID, attributes ...core.KeyValue) ScopeID {
|
||||
if len(attributes) == 0 {
|
||||
return parent
|
||||
}
|
||||
eventID := e.Record(Event{
|
||||
Type: NEW_SCOPE,
|
||||
Scope: parent,
|
||||
Attributes: attributes,
|
||||
})
|
||||
return ScopeID{
|
||||
EventID: eventID,
|
||||
SpanContext: parent.SpanContext,
|
||||
}
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package reader // import "go.opentelemetry.io/experimental/streaming/exporter/reader"
|
||||
@@ -1,165 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package format
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"strings"
|
||||
|
||||
"go.opentelemetry.io/api/core"
|
||||
"go.opentelemetry.io/api/distributedcontext"
|
||||
"go.opentelemetry.io/api/key"
|
||||
"go.opentelemetry.io/api/metric"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter/reader"
|
||||
|
||||
// TODO this should not be an SDK dependency; move conventional tags into the API.
|
||||
"go.opentelemetry.io/experimental/streaming/sdk"
|
||||
)
|
||||
|
||||
var (
|
||||
parentSpanIDKey = key.New("parent_span_id")
|
||||
)
|
||||
|
||||
func AppendEvent(buf *strings.Builder, data reader.Event) {
|
||||
|
||||
f := func(skipIf bool) func(kv core.KeyValue) bool {
|
||||
return func(kv core.KeyValue) bool {
|
||||
if skipIf && data.Attributes.HasValue(kv.Key) {
|
||||
return true
|
||||
}
|
||||
buf.WriteString(" ")
|
||||
buf.WriteString(string(kv.Key))
|
||||
buf.WriteString("=")
|
||||
buf.WriteString(kv.Value.Emit())
|
||||
return true
|
||||
}
|
||||
}
|
||||
|
||||
buf.WriteString(data.Time.Format("2006/01/02 15-04-05.000000"))
|
||||
buf.WriteString(" ")
|
||||
|
||||
switch data.Type {
|
||||
case exporter.START_SPAN:
|
||||
buf.WriteString("start ")
|
||||
buf.WriteString(data.Name)
|
||||
|
||||
if !data.Parent.HasSpanID() {
|
||||
buf.WriteString(", a root span")
|
||||
} else {
|
||||
buf.WriteString(" <")
|
||||
f(false)(parentSpanIDKey.String(data.Parent.SpanIDString()))
|
||||
if data.ParentAttributes.Len() > 0 {
|
||||
data.ParentAttributes.Foreach(f(false))
|
||||
}
|
||||
buf.WriteString(" >")
|
||||
}
|
||||
|
||||
case exporter.END_SPAN:
|
||||
buf.WriteString("end ")
|
||||
buf.WriteString(data.Name)
|
||||
|
||||
buf.WriteString(" (")
|
||||
buf.WriteString(data.Duration.String())
|
||||
buf.WriteString(")")
|
||||
|
||||
case exporter.ADD_EVENT:
|
||||
buf.WriteString("event: ")
|
||||
buf.WriteString(data.Message)
|
||||
buf.WriteString(" (")
|
||||
data.Attributes.Foreach(func(kv core.KeyValue) bool {
|
||||
buf.WriteString(" ")
|
||||
buf.WriteString(string(kv.Key))
|
||||
buf.WriteString("=")
|
||||
buf.WriteString(kv.Value.Emit())
|
||||
return true
|
||||
})
|
||||
buf.WriteString(")")
|
||||
|
||||
case exporter.MODIFY_ATTR:
|
||||
buf.WriteString("modify attr ")
|
||||
buf.WriteString(data.Type.String())
|
||||
|
||||
case exporter.SINGLE_METRIC:
|
||||
formatMetricUpdate(buf, data.Measurement)
|
||||
formatMetricLabels(buf, data.Attributes)
|
||||
|
||||
case exporter.BATCH_METRIC:
|
||||
buf.WriteString("BATCH")
|
||||
formatMetricLabels(buf, data.Attributes)
|
||||
for _, m := range data.Measurements {
|
||||
formatMetricUpdate(buf, m)
|
||||
buf.WriteString(" ")
|
||||
}
|
||||
|
||||
case exporter.SET_STATUS:
|
||||
buf.WriteString("set status ")
|
||||
buf.WriteString(data.Status.String())
|
||||
|
||||
case exporter.SET_NAME:
|
||||
buf.WriteString("set name ")
|
||||
buf.WriteString(data.Name)
|
||||
|
||||
default:
|
||||
buf.WriteString(fmt.Sprintf("WAT? %d", data.Type))
|
||||
}
|
||||
|
||||
// Attach the scope (span) attributes and context entries.
|
||||
buf.WriteString(" [")
|
||||
if data.Attributes.Len() > 0 {
|
||||
data.Attributes.Foreach(f(false))
|
||||
}
|
||||
if data.Entries.Len() > 0 {
|
||||
data.Entries.Foreach(f(true))
|
||||
}
|
||||
if data.SpanContext.HasSpanID() {
|
||||
f(false)(sdk.SpanIDKey.String(data.SpanContext.SpanIDString()))
|
||||
}
|
||||
if data.SpanContext.HasTraceID() {
|
||||
f(false)(sdk.TraceIDKey.String(data.SpanContext.TraceIDString()))
|
||||
}
|
||||
|
||||
buf.WriteString(" ]\n")
|
||||
}
|
||||
|
||||
func formatMetricUpdate(buf *strings.Builder, m metric.Measurement) {
|
||||
buf.WriteString(m.Descriptor.Kind().String())
|
||||
buf.WriteString(" ")
|
||||
buf.WriteString(m.Descriptor.Name())
|
||||
buf.WriteString("=")
|
||||
buf.WriteString(m.Value.Emit(m.Descriptor.ValueKind()))
|
||||
}
|
||||
|
||||
func formatMetricLabels(buf *strings.Builder, l distributedcontext.Map) {
|
||||
buf.WriteString(" {")
|
||||
i := 0
|
||||
l.Foreach(func(kv core.KeyValue) bool {
|
||||
if i != 0 {
|
||||
buf.WriteString(",")
|
||||
}
|
||||
i++
|
||||
buf.WriteString(string(kv.Key))
|
||||
buf.WriteString("=")
|
||||
buf.WriteString(kv.Value.Emit())
|
||||
return true
|
||||
})
|
||||
buf.WriteString("}")
|
||||
}
|
||||
|
||||
func EventToString(data reader.Event) string {
|
||||
var buf strings.Builder
|
||||
AppendEvent(&buf, data)
|
||||
return buf.String()
|
||||
}
|
||||
@@ -1,303 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package reader
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"sync"
|
||||
"time"
|
||||
|
||||
"google.golang.org/grpc/codes"
|
||||
|
||||
"go.opentelemetry.io/api/core"
|
||||
"go.opentelemetry.io/api/distributedcontext"
|
||||
"go.opentelemetry.io/api/metric"
|
||||
"go.opentelemetry.io/api/trace"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter"
|
||||
)
|
||||
|
||||
type Reader interface {
|
||||
Read(Event)
|
||||
}
|
||||
|
||||
type Event struct {
|
||||
Type exporter.EventType
|
||||
Time time.Time
|
||||
Sequence exporter.EventID
|
||||
SpanContext core.SpanContext
|
||||
Entries distributedcontext.Map // context entries
|
||||
Attributes distributedcontext.Map // span attributes, metric labels
|
||||
Measurement metric.Measurement
|
||||
Measurements []metric.Measurement
|
||||
|
||||
Parent core.SpanContext
|
||||
ParentAttributes distributedcontext.Map
|
||||
|
||||
Duration time.Duration
|
||||
Name string
|
||||
Message string
|
||||
Status codes.Code
|
||||
}
|
||||
|
||||
type readerObserver struct {
|
||||
readers []Reader
|
||||
|
||||
// core.EventID -> *readerSpan or *readerScope
|
||||
scopes sync.Map
|
||||
}
|
||||
|
||||
type readerSpan struct {
|
||||
name string
|
||||
start time.Time
|
||||
startEntries distributedcontext.Map
|
||||
spanContext core.SpanContext
|
||||
status codes.Code
|
||||
|
||||
*readerScope
|
||||
}
|
||||
|
||||
type readerScope struct {
|
||||
span *readerSpan
|
||||
parent exporter.EventID
|
||||
attributes distributedcontext.Map
|
||||
}
|
||||
|
||||
// NewReaderObserver returns an implementation that computes the
|
||||
// necessary state needed by a reader to process events in memory.
|
||||
// Practically, this means tracking live metric handles and scope
|
||||
// attribute sets.
|
||||
func NewReaderObserver(readers ...Reader) exporter.Observer {
|
||||
return &readerObserver{
|
||||
readers: readers,
|
||||
}
|
||||
}
|
||||
|
||||
func (ro *readerObserver) Observe(event exporter.Event) {
|
||||
// TODO this should check for out-of-order events and buffer.
|
||||
ro.orderedObserve(event)
|
||||
}
|
||||
|
||||
func (ro *readerObserver) orderedObserve(event exporter.Event) {
|
||||
read := Event{
|
||||
Time: event.Time,
|
||||
Sequence: event.Sequence,
|
||||
Attributes: distributedcontext.NewEmptyMap(),
|
||||
Entries: distributedcontext.NewEmptyMap(),
|
||||
}
|
||||
|
||||
if event.Context != nil {
|
||||
read.Entries = distributedcontext.FromContext(event.Context)
|
||||
}
|
||||
|
||||
switch event.Type {
|
||||
case exporter.START_SPAN:
|
||||
// Save the span context entries, initial attributes, start time, and name.
|
||||
span := &readerSpan{
|
||||
name: event.String,
|
||||
start: event.Time,
|
||||
startEntries: distributedcontext.FromContext(event.Context),
|
||||
spanContext: event.Scope.SpanContext,
|
||||
readerScope: &readerScope{},
|
||||
}
|
||||
|
||||
rattrs, _ := ro.readScope(event.Scope)
|
||||
|
||||
span.readerScope.span = span
|
||||
span.readerScope.attributes = rattrs
|
||||
|
||||
read.Name = span.name
|
||||
read.Type = exporter.START_SPAN
|
||||
read.SpanContext = span.spanContext
|
||||
read.Attributes = rattrs
|
||||
|
||||
if event.Parent.EventID == 0 && event.Parent.HasTraceID() {
|
||||
// Remote parent
|
||||
read.Parent = event.Parent.SpanContext
|
||||
|
||||
// Note: No parent attributes in the event for remote parents.
|
||||
} else {
|
||||
pattrs, pspan := ro.readScope(event.Parent)
|
||||
|
||||
if pspan != nil {
|
||||
// Local parent
|
||||
read.Parent = pspan.spanContext
|
||||
read.ParentAttributes = pattrs
|
||||
}
|
||||
}
|
||||
|
||||
ro.scopes.Store(event.Sequence, span)
|
||||
|
||||
case exporter.END_SPAN:
|
||||
attrs, span := ro.readScope(event.Scope)
|
||||
if span == nil {
|
||||
panic(fmt.Sprint("span not found", event.Scope))
|
||||
}
|
||||
|
||||
read.Name = span.name
|
||||
read.Type = exporter.END_SPAN
|
||||
|
||||
read.Attributes = attrs
|
||||
read.Duration = event.Time.Sub(span.start)
|
||||
read.Entries = span.startEntries
|
||||
read.SpanContext = span.spanContext
|
||||
|
||||
// TODO: recovered
|
||||
|
||||
case exporter.NEW_SCOPE, exporter.MODIFY_ATTR:
|
||||
var span *readerSpan
|
||||
var m distributedcontext.Map
|
||||
|
||||
sid := event.Scope
|
||||
|
||||
if sid.EventID == 0 {
|
||||
m = distributedcontext.NewEmptyMap()
|
||||
} else {
|
||||
parentI, has := ro.scopes.Load(sid.EventID)
|
||||
if !has {
|
||||
panic("parent scope not found")
|
||||
}
|
||||
if parent, ok := parentI.(*readerScope); ok {
|
||||
m = parent.attributes
|
||||
span = parent.span
|
||||
} else if parent, ok := parentI.(*readerSpan); ok {
|
||||
m = parent.attributes
|
||||
span = parent
|
||||
}
|
||||
}
|
||||
|
||||
sc := &readerScope{
|
||||
span: span,
|
||||
parent: sid.EventID,
|
||||
attributes: m.Apply(
|
||||
distributedcontext.MapUpdate{
|
||||
SingleKV: event.Attribute,
|
||||
MultiKV: event.Attributes,
|
||||
SingleMutator: event.Mutator,
|
||||
MultiMutator: event.Mutators,
|
||||
},
|
||||
),
|
||||
}
|
||||
|
||||
ro.scopes.Store(event.Sequence, sc)
|
||||
|
||||
if event.Type == exporter.NEW_SCOPE {
|
||||
return
|
||||
}
|
||||
|
||||
read.Type = exporter.MODIFY_ATTR
|
||||
read.Attributes = sc.attributes
|
||||
|
||||
if span != nil {
|
||||
read.SpanContext = span.spanContext
|
||||
read.Entries = span.startEntries
|
||||
}
|
||||
|
||||
case exporter.ADD_EVENT:
|
||||
read.Type = exporter.ADD_EVENT
|
||||
read.Message = event.String
|
||||
|
||||
attrs, span := ro.readScope(event.Scope)
|
||||
read.Attributes = attrs.Apply(distributedcontext.MapUpdate{
|
||||
MultiKV: event.Attributes,
|
||||
})
|
||||
if span != nil {
|
||||
read.SpanContext = span.spanContext
|
||||
}
|
||||
|
||||
case exporter.SINGLE_METRIC:
|
||||
read.Type = exporter.SINGLE_METRIC
|
||||
|
||||
if event.Context != nil {
|
||||
span := trace.CurrentSpan(event.Context)
|
||||
if span != nil {
|
||||
read.SpanContext = span.SpanContext()
|
||||
}
|
||||
}
|
||||
attrs, _ := ro.readScope(event.Scope)
|
||||
read.Attributes = attrs
|
||||
read.Measurement = event.Measurement
|
||||
|
||||
case exporter.BATCH_METRIC:
|
||||
read.Type = event.Type
|
||||
|
||||
if event.Context != nil {
|
||||
span := trace.CurrentSpan(event.Context)
|
||||
if span != nil {
|
||||
read.SpanContext = span.SpanContext()
|
||||
}
|
||||
}
|
||||
|
||||
attrs, _ := ro.readScope(event.Scope)
|
||||
read.Attributes = attrs
|
||||
read.Measurements = make([]metric.Measurement, len(event.Measurements))
|
||||
copy(read.Measurements, event.Measurements)
|
||||
|
||||
case exporter.SET_STATUS:
|
||||
read.Type = exporter.SET_STATUS
|
||||
read.Status = event.Status
|
||||
_, span := ro.readScope(event.Scope)
|
||||
if span != nil {
|
||||
span.status = event.Status
|
||||
read.SpanContext = span.spanContext
|
||||
}
|
||||
|
||||
case exporter.SET_NAME:
|
||||
read.Type = exporter.SET_NAME
|
||||
read.Name = event.String
|
||||
|
||||
default:
|
||||
panic(fmt.Sprint("Unhandled case: ", event.Type))
|
||||
}
|
||||
|
||||
for _, reader := range ro.readers {
|
||||
reader.Read(read)
|
||||
}
|
||||
|
||||
if event.Type == exporter.END_SPAN {
|
||||
ro.cleanupSpan(event.Scope.EventID)
|
||||
}
|
||||
}
|
||||
|
||||
func (ro *readerObserver) readScope(id exporter.ScopeID) (distributedcontext.Map, *readerSpan) {
|
||||
if id.EventID == 0 {
|
||||
return distributedcontext.NewEmptyMap(), nil
|
||||
}
|
||||
ev, has := ro.scopes.Load(id.EventID)
|
||||
if !has {
|
||||
panic(fmt.Sprintln("scope not found", id.EventID))
|
||||
}
|
||||
if sp, ok := ev.(*readerScope); ok {
|
||||
return sp.attributes, sp.span
|
||||
} else if sp, ok := ev.(*readerSpan); ok {
|
||||
return sp.attributes, sp
|
||||
}
|
||||
return distributedcontext.NewEmptyMap(), nil
|
||||
}
|
||||
|
||||
func (ro *readerObserver) cleanupSpan(id exporter.EventID) {
|
||||
for id != 0 {
|
||||
ev, has := ro.scopes.Load(id)
|
||||
if !has {
|
||||
panic(fmt.Sprintln("scope not found", id))
|
||||
}
|
||||
ro.scopes.Delete(id)
|
||||
|
||||
if sp, ok := ev.(*readerScope); ok {
|
||||
id = sp.parent
|
||||
} else if sp, ok := ev.(*readerSpan); ok {
|
||||
id = sp.parent
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package spandata // import "go.opentelemetry.io/experimental/streaming/exporter/spandata"
|
||||
@@ -1,15 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package format // import "go.opentelemetry.io/experimental/streaming/exporter/spandata/format"
|
||||
@@ -1,34 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package format
|
||||
|
||||
import (
|
||||
"strings"
|
||||
|
||||
"go.opentelemetry.io/experimental/streaming/exporter/reader/format"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter/spandata"
|
||||
)
|
||||
|
||||
func AppendSpan(buf *strings.Builder, data *spandata.Span) {
|
||||
for _, event := range data.Events {
|
||||
format.AppendEvent(buf, event)
|
||||
}
|
||||
}
|
||||
|
||||
func SpanToString(data *spandata.Span) string {
|
||||
var buf strings.Builder
|
||||
AppendSpan(&buf, data)
|
||||
return buf.String()
|
||||
}
|
||||
@@ -1,78 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package spandata
|
||||
|
||||
import (
|
||||
"go.opentelemetry.io/api/core"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter/reader"
|
||||
)
|
||||
|
||||
type Reader interface {
|
||||
Read(*Span)
|
||||
}
|
||||
|
||||
type Span struct {
|
||||
Events []reader.Event
|
||||
Aggregates map[string]float64
|
||||
}
|
||||
|
||||
type spanReader struct {
|
||||
spans map[core.SpanContext]*Span
|
||||
readers []Reader
|
||||
}
|
||||
|
||||
func NewReaderObserver(readers ...Reader) exporter.Observer {
|
||||
return reader.NewReaderObserver(&spanReader{
|
||||
spans: map[core.SpanContext]*Span{},
|
||||
readers: readers,
|
||||
})
|
||||
}
|
||||
|
||||
func (s *spanReader) Read(data reader.Event) {
|
||||
var span *Span
|
||||
if data.SpanContext.HasSpanID() {
|
||||
if data.Type == exporter.START_SPAN {
|
||||
span = &Span{Events: make([]reader.Event, 0, 4)}
|
||||
s.spans[data.SpanContext] = span
|
||||
} else {
|
||||
span = s.spans[data.SpanContext]
|
||||
if span == nil {
|
||||
// TODO count and report this.
|
||||
return
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
switch data.Type {
|
||||
case exporter.SINGLE_METRIC:
|
||||
s.updateMetric(data)
|
||||
return
|
||||
}
|
||||
|
||||
if span != nil {
|
||||
span.Events = append(span.Events, data)
|
||||
if data.Type == exporter.END_SPAN {
|
||||
for _, r := range s.readers {
|
||||
r.Read(span)
|
||||
}
|
||||
delete(s.spans, data.SpanContext)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func (s *spanReader) updateMetric(data reader.Event) {
|
||||
// TODO aggregate
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package spanlog // import "go.opentelemetry.io/experimental/streaming/exporter/spanlog"
|
||||
@@ -1,37 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package spanlog
|
||||
|
||||
import (
|
||||
"os"
|
||||
"strings"
|
||||
|
||||
"go.opentelemetry.io/experimental/streaming/exporter"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter/spandata"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter/spandata/format"
|
||||
)
|
||||
|
||||
type spanLog struct{}
|
||||
|
||||
func New() exporter.Observer {
|
||||
return spandata.NewReaderObserver(&spanLog{})
|
||||
}
|
||||
|
||||
func (s *spanLog) Read(data *spandata.Span) {
|
||||
var buf strings.Builder
|
||||
buf.WriteString("----------------------------------------------------------------------\n")
|
||||
format.AppendSpan(&buf, data)
|
||||
os.Stdout.WriteString(buf.String())
|
||||
}
|
||||
@@ -1,33 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package stderr // import "go.opentelemetry.io/experimental/streaming/exporter/stderr"
|
||||
|
||||
import (
|
||||
"os"
|
||||
|
||||
"go.opentelemetry.io/experimental/streaming/exporter"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter/reader"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter/reader/format"
|
||||
)
|
||||
|
||||
type stderrLog struct{}
|
||||
|
||||
func New() exporter.Observer {
|
||||
return reader.NewReaderObserver(&stderrLog{})
|
||||
}
|
||||
|
||||
func (s *stderrLog) Read(data reader.Event) {
|
||||
os.Stderr.WriteString(format.EventToString(data))
|
||||
}
|
||||
@@ -1,33 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package stdout // import "go.opentelemetry.io/experimental/streaming/exporter/stdout"
|
||||
|
||||
import (
|
||||
"os"
|
||||
|
||||
"go.opentelemetry.io/experimental/streaming/exporter"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter/reader"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter/reader/format"
|
||||
)
|
||||
|
||||
type stdoutLog struct{}
|
||||
|
||||
func New() exporter.Observer {
|
||||
return reader.NewReaderObserver(&stdoutLog{})
|
||||
}
|
||||
|
||||
func (s *stdoutLog) Read(data reader.Event) {
|
||||
os.Stdout.WriteString(format.EventToString(data))
|
||||
}
|
||||
@@ -1,43 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package internal // import "go.opentelemetry.io/experimental/streaming/sdk/internal"
|
||||
|
||||
import "go.opentelemetry.io/experimental/streaming/exporter"
|
||||
|
||||
type eventsMap map[exporter.EventType][]exporter.Event
|
||||
|
||||
type TestObserver struct {
|
||||
events eventsMap
|
||||
}
|
||||
|
||||
var _ exporter.Observer = &TestObserver{}
|
||||
|
||||
func NewTestObserver() *TestObserver {
|
||||
return &TestObserver{}
|
||||
}
|
||||
|
||||
func (o *TestObserver) Observe(e exporter.Event) {
|
||||
if o.events == nil {
|
||||
o.events = make(eventsMap)
|
||||
}
|
||||
o.events[e.Type] = append(o.events[e.Type], e)
|
||||
}
|
||||
|
||||
func (o *TestObserver) Events(eType exporter.EventType) []exporter.Event {
|
||||
if o.events == nil {
|
||||
return nil
|
||||
}
|
||||
return o.events[eType]
|
||||
}
|
||||
@@ -1,175 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package sdk
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
"go.opentelemetry.io/api/core"
|
||||
"go.opentelemetry.io/api/metric"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter"
|
||||
)
|
||||
|
||||
type metricHandle struct {
|
||||
descriptor *metric.Descriptor
|
||||
labels metricLabels
|
||||
}
|
||||
|
||||
var _ metric.Handle = &metricHandle{}
|
||||
|
||||
type metricLabels struct {
|
||||
sdk *sdk
|
||||
scope exporter.ScopeID
|
||||
}
|
||||
|
||||
var _ metric.LabelSet = &metricLabels{}
|
||||
|
||||
func (h *metricHandle) RecordOne(ctx context.Context, value metric.MeasurementValue) {
|
||||
h.labels.sdk.exporter.Record(exporter.Event{
|
||||
Type: exporter.SINGLE_METRIC,
|
||||
Context: ctx,
|
||||
Scope: h.labels.scope,
|
||||
Measurement: metric.Measurement{
|
||||
Descriptor: h.descriptor,
|
||||
Value: value,
|
||||
},
|
||||
})
|
||||
}
|
||||
|
||||
func (m metricLabels) Meter() metric.Meter {
|
||||
return m.sdk
|
||||
}
|
||||
|
||||
func (s *sdk) DefineLabels(ctx context.Context, labels ...core.KeyValue) metric.LabelSet {
|
||||
return metricLabels{
|
||||
sdk: s,
|
||||
scope: s.exporter.NewScope(exporter.ScopeID{}, labels...),
|
||||
}
|
||||
}
|
||||
|
||||
func (s *sdk) NewHandle(erm metric.ExplicitReportingMetric, labels metric.LabelSet) metric.Handle {
|
||||
mlabels, _ := labels.(metricLabels)
|
||||
|
||||
return &metricHandle{
|
||||
descriptor: erm.Descriptor(),
|
||||
labels: mlabels,
|
||||
}
|
||||
}
|
||||
|
||||
func (s *sdk) DeleteHandle(handle metric.Handle) {
|
||||
}
|
||||
|
||||
func (s *sdk) RecordBatch(ctx context.Context, labels metric.LabelSet, ms ...metric.Measurement) {
|
||||
eventType := exporter.BATCH_METRIC
|
||||
if len(ms) == 1 {
|
||||
eventType = exporter.SINGLE_METRIC
|
||||
}
|
||||
oms := make([]metric.Measurement, len(ms))
|
||||
mlabels, _ := labels.(metricLabels)
|
||||
|
||||
copy(oms, ms)
|
||||
|
||||
s.exporter.Record(exporter.Event{
|
||||
Type: eventType,
|
||||
Context: ctx,
|
||||
Scope: mlabels.scope,
|
||||
Measurements: oms,
|
||||
})
|
||||
}
|
||||
|
||||
func (s *sdk) RegisterObserver(observer metric.Observer, callback metric.ObserverCallback) {
|
||||
if s.insertNewObserver(observer, callback) {
|
||||
go s.observersRoutine()
|
||||
}
|
||||
}
|
||||
|
||||
func (s *sdk) insertNewObserver(observer metric.Observer, callback metric.ObserverCallback) bool {
|
||||
s.observersLock.Lock()
|
||||
defer s.observersLock.Unlock()
|
||||
old := s.loadObserversMap()
|
||||
id := observer.Descriptor().ID()
|
||||
if _, ok := old[id]; ok {
|
||||
return false
|
||||
}
|
||||
observers := make(observersMap)
|
||||
for oid, data := range old {
|
||||
observers[oid] = data
|
||||
}
|
||||
observers[id] = observerData{
|
||||
observer: observer,
|
||||
callback: callback,
|
||||
}
|
||||
s.storeObserversMap(observers)
|
||||
return old == nil
|
||||
}
|
||||
|
||||
func (s *sdk) UnregisterObserver(observer metric.Observer) {
|
||||
s.observersLock.Lock()
|
||||
defer s.observersLock.Unlock()
|
||||
old := s.loadObserversMap()
|
||||
id := observer.Descriptor().ID()
|
||||
if _, ok := old[id]; !ok {
|
||||
return
|
||||
}
|
||||
if len(old) == 1 {
|
||||
s.storeObserversMap(nil)
|
||||
return
|
||||
}
|
||||
observers := make(observersMap)
|
||||
for oid, data := range old {
|
||||
if oid != id {
|
||||
observers[oid] = data
|
||||
}
|
||||
}
|
||||
s.storeObserversMap(observers)
|
||||
}
|
||||
|
||||
func (s *sdk) observersRoutine() {
|
||||
ticker := time.NewTicker(time.Second)
|
||||
defer ticker.Stop()
|
||||
for range ticker.C {
|
||||
m := s.loadObserversMap()
|
||||
if m == nil {
|
||||
return
|
||||
}
|
||||
for _, data := range m {
|
||||
ocb := s.getObservationCallback(data.observer.Descriptor())
|
||||
data.callback(s, data.observer, ocb)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func (s *sdk) getObservationCallback(descriptor *metric.Descriptor) metric.ObservationCallback {
|
||||
return func(l metric.LabelSet, v metric.MeasurementValue) {
|
||||
s.RecordBatch(context.Background(), l, metric.Measurement{
|
||||
Descriptor: descriptor,
|
||||
Value: v,
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
func (s *sdk) loadObserversMap() observersMap {
|
||||
i := s.observers.Load()
|
||||
if i == nil {
|
||||
return nil
|
||||
}
|
||||
m := i.(observersMap)
|
||||
return m
|
||||
}
|
||||
|
||||
func (s *sdk) storeObserversMap(m observersMap) {
|
||||
s.observers.Store(m)
|
||||
}
|
||||
@@ -1,52 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package sdk
|
||||
|
||||
import (
|
||||
"sync"
|
||||
"sync/atomic"
|
||||
|
||||
"go.opentelemetry.io/api/metric"
|
||||
"go.opentelemetry.io/api/trace"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter"
|
||||
)
|
||||
|
||||
type observerData struct {
|
||||
observer metric.Observer
|
||||
callback metric.ObserverCallback
|
||||
}
|
||||
|
||||
type observersMap map[metric.DescriptorID]observerData
|
||||
|
||||
type sdk struct {
|
||||
exporter *exporter.Exporter
|
||||
resources exporter.EventID
|
||||
|
||||
observersLock sync.Mutex
|
||||
observers atomic.Value // observersMap
|
||||
}
|
||||
|
||||
type SDK interface {
|
||||
trace.Tracer
|
||||
metric.Meter
|
||||
}
|
||||
|
||||
var _ SDK = &sdk{}
|
||||
|
||||
func New(observers ...exporter.Observer) SDK {
|
||||
return &sdk{
|
||||
exporter: exporter.NewExporter(observers...),
|
||||
}
|
||||
}
|
||||
@@ -1,141 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package sdk
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
"google.golang.org/grpc/codes"
|
||||
|
||||
"go.opentelemetry.io/api/core"
|
||||
"go.opentelemetry.io/api/distributedcontext"
|
||||
"go.opentelemetry.io/api/trace"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter"
|
||||
)
|
||||
|
||||
type span struct {
|
||||
sdk *sdk
|
||||
initial exporter.ScopeID
|
||||
}
|
||||
|
||||
// SpanContext returns span context of the span. Returned SpanContext is usable
|
||||
// even after the span is finished.
|
||||
func (sp *span) SpanContext() core.SpanContext {
|
||||
return sp.initial.SpanContext
|
||||
}
|
||||
|
||||
// IsRecording returns true is the span is active and recording events is enabled.
|
||||
func (sp *span) IsRecording() bool {
|
||||
return false
|
||||
}
|
||||
|
||||
// SetStatus sets the status of the span.
|
||||
func (sp *span) SetStatus(status codes.Code) {
|
||||
sp.sdk.exporter.Record(exporter.Event{
|
||||
Type: exporter.SET_STATUS,
|
||||
Scope: sp.ScopeID(),
|
||||
Status: status,
|
||||
})
|
||||
}
|
||||
|
||||
func (sp *span) ScopeID() exporter.ScopeID {
|
||||
return sp.initial
|
||||
}
|
||||
|
||||
func (sp *span) SetAttribute(attribute core.KeyValue) {
|
||||
sp.sdk.exporter.Record(exporter.Event{
|
||||
Type: exporter.MODIFY_ATTR,
|
||||
Scope: sp.ScopeID(),
|
||||
Attribute: attribute,
|
||||
})
|
||||
}
|
||||
|
||||
func (sp *span) SetAttributes(attributes ...core.KeyValue) {
|
||||
sp.sdk.exporter.Record(exporter.Event{
|
||||
Type: exporter.MODIFY_ATTR,
|
||||
Scope: sp.ScopeID(),
|
||||
Attributes: attributes,
|
||||
})
|
||||
}
|
||||
|
||||
func (sp *span) ModifyAttribute(mutator distributedcontext.Mutator) {
|
||||
sp.sdk.exporter.Record(exporter.Event{
|
||||
Type: exporter.MODIFY_ATTR,
|
||||
Scope: sp.ScopeID(),
|
||||
Mutator: mutator,
|
||||
})
|
||||
}
|
||||
|
||||
func (sp *span) ModifyAttributes(mutators ...distributedcontext.Mutator) {
|
||||
sp.sdk.exporter.Record(exporter.Event{
|
||||
Type: exporter.MODIFY_ATTR,
|
||||
Scope: sp.ScopeID(),
|
||||
Mutators: mutators,
|
||||
})
|
||||
}
|
||||
|
||||
func (sp *span) End(options ...trace.EndOption) {
|
||||
recovered := recover()
|
||||
opts := trace.EndOptions{}
|
||||
for _, opt := range options {
|
||||
opt(&opts)
|
||||
}
|
||||
sp.sdk.exporter.Record(exporter.Event{
|
||||
Time: opts.EndTime,
|
||||
Type: exporter.END_SPAN,
|
||||
Scope: sp.ScopeID(),
|
||||
Recovered: recovered,
|
||||
})
|
||||
if recovered != nil {
|
||||
panic(recovered)
|
||||
}
|
||||
}
|
||||
|
||||
func (sp *span) Tracer() trace.Tracer {
|
||||
return sp.sdk
|
||||
}
|
||||
|
||||
func (sp *span) AddEvent(ctx context.Context, msg string, attrs ...core.KeyValue) {
|
||||
sp.addEventWithTime(ctx, time.Time{}, msg, attrs...)
|
||||
}
|
||||
|
||||
func (sp *span) AddEventWithTimestamp(ctx context.Context, timestamp time.Time, msg string, attrs ...core.KeyValue) {
|
||||
sp.addEventWithTime(ctx, timestamp, msg, attrs...)
|
||||
}
|
||||
|
||||
func (sp *span) addEventWithTime(ctx context.Context, timestamp time.Time, msg string, attrs ...core.KeyValue) {
|
||||
sp.sdk.exporter.Record(exporter.Event{
|
||||
Time: timestamp,
|
||||
Type: exporter.ADD_EVENT,
|
||||
Scope: sp.ScopeID(),
|
||||
String: msg,
|
||||
Attributes: attrs,
|
||||
Context: ctx,
|
||||
})
|
||||
}
|
||||
|
||||
func (sp *span) SetName(name string) {
|
||||
sp.sdk.exporter.Record(exporter.Event{
|
||||
Type: exporter.SET_NAME,
|
||||
String: name,
|
||||
})
|
||||
}
|
||||
|
||||
func (sp *span) AddLink(link trace.Link) {
|
||||
}
|
||||
|
||||
func (sp *span) Link(sc core.SpanContext, attrs ...core.KeyValue) {
|
||||
}
|
||||
@@ -1,174 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package sdk
|
||||
|
||||
import (
|
||||
"context"
|
||||
"reflect"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/google/go-cmp/cmp"
|
||||
|
||||
"go.opentelemetry.io/api/core"
|
||||
"go.opentelemetry.io/api/key"
|
||||
"go.opentelemetry.io/api/metric"
|
||||
"go.opentelemetry.io/api/trace"
|
||||
|
||||
"go.opentelemetry.io/experimental/streaming/exporter"
|
||||
"go.opentelemetry.io/experimental/streaming/sdk/internal"
|
||||
)
|
||||
|
||||
func TestEvents(t *testing.T) {
|
||||
obs := internal.NewTestObserver()
|
||||
_ = New(obs).WithSpan(context.Background(), "test", func(ctx context.Context) error {
|
||||
type test1Type struct{}
|
||||
type test2Type struct{}
|
||||
sp := trace.CurrentSpan(ctx)
|
||||
k1v1 := key.New("k1").String("v1")
|
||||
k2v2 := key.New("k2").String("v2")
|
||||
k3v3 := key.New("k3").String("v3")
|
||||
ctx1 := context.WithValue(ctx, test1Type{}, 42)
|
||||
sp.AddEvent(ctx1, "one two three", k1v1)
|
||||
ctx2 := context.WithValue(ctx1, test2Type{}, "foo")
|
||||
sp.AddEvent(ctx2, "testing", k2v2, k3v3)
|
||||
|
||||
got := obs.Events(exporter.ADD_EVENT)
|
||||
for idx := range got {
|
||||
if got[idx].Time.IsZero() {
|
||||
t.Errorf("Event %d has zero timestamp", idx)
|
||||
}
|
||||
got[idx].Time = time.Time{}
|
||||
}
|
||||
if len(got) != 2 {
|
||||
t.Errorf("Expected two events, got %d", len(got))
|
||||
}
|
||||
sdkSpan := sp.(*span)
|
||||
want := []exporter.Event{
|
||||
{
|
||||
Type: exporter.ADD_EVENT,
|
||||
String: "one two three",
|
||||
Attributes: []core.KeyValue{k1v1},
|
||||
Scope: sdkSpan.ScopeID(),
|
||||
},
|
||||
{
|
||||
Type: exporter.ADD_EVENT,
|
||||
String: "testing",
|
||||
Attributes: []core.KeyValue{k2v2, k3v3},
|
||||
Scope: sdkSpan.ScopeID(),
|
||||
},
|
||||
}
|
||||
if diffEvents(t, got, want) {
|
||||
checkContext(t, got[0].Context, test1Type{}, 42)
|
||||
checkContextMissing(t, got[0].Context, test2Type{})
|
||||
checkContext(t, got[1].Context, test1Type{}, 42)
|
||||
checkContext(t, got[1].Context, test2Type{}, "foo")
|
||||
}
|
||||
return nil
|
||||
})
|
||||
}
|
||||
|
||||
func TestCustomStartEndTime(t *testing.T) {
|
||||
startTime := time.Date(2019, time.August, 27, 14, 42, 0, 0, time.UTC)
|
||||
endTime := startTime.Add(time.Second * 20)
|
||||
obs := internal.NewTestObserver()
|
||||
tracer := New(obs)
|
||||
_, span := tracer.Start(
|
||||
context.Background(),
|
||||
"testspan",
|
||||
trace.WithStartTime(startTime),
|
||||
)
|
||||
span.End(trace.WithEndTime(endTime))
|
||||
want := []exporter.Event{
|
||||
{
|
||||
Type: exporter.START_SPAN,
|
||||
Time: startTime,
|
||||
String: "testspan",
|
||||
},
|
||||
{
|
||||
Type: exporter.END_SPAN,
|
||||
Time: endTime,
|
||||
},
|
||||
}
|
||||
got := append(obs.Events(exporter.START_SPAN), obs.Events(exporter.END_SPAN)...)
|
||||
diffEvents(t, got, want, "Scope")
|
||||
}
|
||||
|
||||
func checkContextMissing(t *testing.T, ctx context.Context, key interface{}) bool {
|
||||
gotValue := ctx.Value(key)
|
||||
if gotValue != nil {
|
||||
keyType := reflect.TypeOf(key)
|
||||
t.Errorf("Expected %s to be missing in context", keyType)
|
||||
return false
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
func checkContext(t *testing.T, ctx context.Context, key, wantValue interface{}) bool {
|
||||
gotValue := ctx.Value(key)
|
||||
if gotValue == nil {
|
||||
keyType := reflect.TypeOf(key)
|
||||
t.Errorf("Expected %s to exist in context", keyType)
|
||||
return false
|
||||
}
|
||||
if diff := cmp.Diff(gotValue, wantValue); diff != "" {
|
||||
keyType := reflect.TypeOf(key)
|
||||
t.Errorf("Context value for key %s: -got +want %s", keyType, diff)
|
||||
return false
|
||||
}
|
||||
return true
|
||||
}
|
||||
|
||||
func measurementCompare(m1, m2 metric.Measurement) bool {
|
||||
// Nil descriptor normally shouldn't happen, unless there is
|
||||
// some struct with the Measurement field that didn't get
|
||||
// initialized.
|
||||
m1Nil := m1.Descriptor == nil
|
||||
m2Nil := m2.Descriptor == nil
|
||||
if m1Nil != m2Nil {
|
||||
return false
|
||||
}
|
||||
if m1Nil {
|
||||
return m1.Value.AsRaw() == m2.Value.AsRaw()
|
||||
}
|
||||
if m1.Descriptor.ID() != m2.Descriptor.ID() {
|
||||
return false
|
||||
}
|
||||
m2Raw := m2.Value.AsRaw()
|
||||
kind := m1.Descriptor.ValueKind()
|
||||
return m1.Value.RawCompare(m2Raw, kind) == 0
|
||||
}
|
||||
|
||||
func diffEvents(t *testing.T, got, want []exporter.Event, extraIgnoredFields ...string) bool {
|
||||
ignoredPaths := map[string]struct{}{
|
||||
"Sequence": {},
|
||||
"Context": {},
|
||||
}
|
||||
for _, field := range extraIgnoredFields {
|
||||
ignoredPaths[field] = struct{}{}
|
||||
}
|
||||
opts := []cmp.Option{
|
||||
cmp.FilterPath(func(path cmp.Path) bool {
|
||||
_, found := ignoredPaths[path.String()]
|
||||
return found
|
||||
}, cmp.Ignore()),
|
||||
cmp.Comparer(measurementCompare),
|
||||
}
|
||||
if diff := cmp.Diff(got, want, opts...); diff != "" {
|
||||
t.Errorf("Events: -got +want %s", diff)
|
||||
return false
|
||||
}
|
||||
return true
|
||||
}
|
||||
@@ -1,98 +0,0 @@
|
||||
// Copyright 2019, OpenTelemetry Authors
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package sdk
|
||||
|
||||
import (
|
||||
"context"
|
||||
"math/rand"
|
||||
|
||||
"go.opentelemetry.io/api/core"
|
||||
"go.opentelemetry.io/api/key"
|
||||
"go.opentelemetry.io/api/trace"
|
||||
"go.opentelemetry.io/experimental/streaming/exporter"
|
||||
)
|
||||
|
||||
// TODO These should move somewhere in the api, right?
|
||||
var (
|
||||
ErrorKey = key.New("error")
|
||||
SpanIDKey = key.New("span_id")
|
||||
TraceIDKey = key.New("trace_id")
|
||||
MessageKey = key.New("message")
|
||||
)
|
||||
|
||||
func (s *sdk) WithSpan(ctx context.Context, name string, body func(context.Context) error) error {
|
||||
// TODO: use runtime/trace.WithRegion for execution sdk support
|
||||
// TODO: use runtime/pprof.Do for profile tags support
|
||||
ctx, span := s.Start(ctx, name)
|
||||
defer span.End()
|
||||
|
||||
if err := body(ctx); err != nil {
|
||||
span.SetAttribute(ErrorKey.Bool(true))
|
||||
span.AddEvent(ctx, "span error", MessageKey.String(err.Error()))
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (s *sdk) Start(ctx context.Context, name string, opts ...trace.SpanOption) (context.Context, trace.Span) {
|
||||
var child core.SpanContext
|
||||
|
||||
child.SpanID = rand.Uint64()
|
||||
|
||||
o := &trace.SpanOptions{}
|
||||
|
||||
for _, opt := range opts {
|
||||
opt(o)
|
||||
}
|
||||
|
||||
var parentScope exporter.ScopeID
|
||||
|
||||
if o.Reference.HasTraceID() {
|
||||
parentScope.SpanContext = o.Reference.SpanContext
|
||||
} else {
|
||||
parentScope.SpanContext = trace.CurrentSpan(ctx).SpanContext()
|
||||
}
|
||||
|
||||
if parentScope.HasTraceID() {
|
||||
parent := parentScope.SpanContext
|
||||
child.TraceID.High = parent.TraceID.High
|
||||
child.TraceID.Low = parent.TraceID.Low
|
||||
} else {
|
||||
child.TraceID.High = rand.Uint64()
|
||||
child.TraceID.Low = rand.Uint64()
|
||||
}
|
||||
|
||||
childScope := exporter.ScopeID{
|
||||
SpanContext: child,
|
||||
EventID: s.resources,
|
||||
}
|
||||
|
||||
span := &span{
|
||||
sdk: s,
|
||||
initial: exporter.ScopeID{
|
||||
SpanContext: child,
|
||||
EventID: s.exporter.Record(exporter.Event{
|
||||
Time: o.StartTime,
|
||||
Type: exporter.START_SPAN,
|
||||
Scope: s.exporter.NewScope(childScope, o.Attributes...),
|
||||
Context: ctx,
|
||||
Parent: parentScope,
|
||||
String: name,
|
||||
},
|
||||
),
|
||||
},
|
||||
}
|
||||
return trace.SetCurrentSpan(ctx, span), span
|
||||
}
|
||||
Reference in New Issue
Block a user