Commit Graph

32 Commits

Author SHA1 Message Date
Kenjiro Nakayama c11003ae6d
Use go sync/atomic instead of go.uber.org/atomic (#2777)
* wip

* tiny fix

* Fix controller/controller_test.go

* fix metrics.go

* Fix profiling/server.go

* Fix reconciler/testing

* update ./test/spoof/spoof_test.go

* Fix ./test/zipkin/util.go

* update go.uber.org/atomic
2023-08-02 16:26:48 +00:00
Martin Gencur f65eba5009
Make ZipkinTracingEnabled flag thread safe (#2690)
* Use atomic.Bool for TracingEnabled flag

* Expose IsTracingEnabled and make tracingEnabled package-scoped

* Fix

* Only keep ZipkingTracingEnabled but do not use it
2023-02-22 13:32:29 +00:00
Dave Protasowski 44d1d7d978
Go1.19 changes (#2631)
* run goimports

* ignore linter errors for now

* fix boilerplate
2022-11-03 22:34:05 +00:00
Dave Protasowski 3d24b8416b
fix lint warnings (#2589)
* resolve deprecation warnings

* drop use of ioutil

* fix license

* run hack/update-codegen.sh
2022-09-12 18:15:45 +00:00
Markus Thömmes 40488532be
Drop master references to knative repos (#2050) 2021-03-11 09:48:26 -08:00
Matt Moore a37d20384b
Support short suffix in zipkin config (#1840) 2020-10-26 09:28:41 -07:00
Scott Nichols 5a5f68637e
use k8s.interface (#1808)
* use k8s.interface

* start to remove test client

* don't use test/KubeClient
2020-10-14 09:51:31 -07:00
Victor Agababov 1e373a9e5d
take 2 (#1755) 2020-09-29 14:10:29 -07:00
Victor Agababov a371418524
v2 (#1754) 2020-09-29 13:18:29 -07:00
Markus Thömmes 5fbbde31b3
Align linters with serving (enables stylecheck and asciicheck) (#1738) 2020-09-23 07:37:40 -07:00
Zbynek Roubalik 2d4efecc6b
bump to k8s 1.18 (#1428)
* bump to k8s 1.18.8

Signed-off-by: Zbynek Roubalik <zroubali@redhat.com>

* plumbing ctx through

Signed-off-by: Zbynek Roubalik <zroubali@redhat.com>

* add more ctx plumbing

Signed-off-by: Zbynek Roubalik <zroubali@redhat.com>

* ctx WithCancel()

Signed-off-by: Zbynek Roubalik <zroubali@redhat.com>
2020-09-11 07:54:00 -07:00
Francesco Guardiani ba0f3cb7cf
Revert port forward logging (#1537)
* Revert "Fixed error with #1531 (#1533)"

This reverts commit d7498436

Signed-off-by: Francesco Guardiani <francescoguard@gmail.com>

* Revert "Added logging of port forwarding stdout (#1531)"

This reverts commit 3b7ca76a

Signed-off-by: Francesco Guardiani <francescoguard@gmail.com>
2020-07-22 01:53:54 -07:00
Francesco Guardiani d749843685
Fixed error with #1531 (#1533)
Signed-off-by: Francesco Guardiani <francescoguard@gmail.com>
2020-07-21 23:38:53 -07:00
Francesco Guardiani 3b7ca76a63
Added logging of port forwarding stdout (#1531)
Signed-off-by: Francesco Guardiani <francescoguard@gmail.com>
2020-07-21 02:16:35 -07:00
Francesco Guardiani caecfb7585
Removed zipkin hardcoded values (#1448)
* Removed zipkin hardcoded values

Signed-off-by: Francesco Guardiani <francescoguard@gmail.com>

* Applied suggestions

Signed-off-by: Francesco Guardiani <francescoguard@gmail.com>

* Applied suggestions

Signed-off-by: Francesco Guardiani <francescoguard@gmail.com>
2020-06-29 10:08:29 -07:00
Victor Agababov 5ba6c1d101
Change %v to %w in errors and other nits (#1252)
* Change %v to %w in errors and other nits
Other are things I noticed when fixing the main %v->%w conversion

* fold
2020-04-27 15:04:51 -07:00
ian-mi 7cbd0bcc1a
Add JSONTracePred to the zipkin testing package (#1157)
Allows the use of an arbitrary predicate when polling a zipkin trace
ID. Enables the creation of tests in which the number of trace spans
may vary.
2020-03-13 17:04:29 -07:00
mattmoor-sockpuppet 2d54fc909d golang format tools (#791)
Produced via:
  `gofmt -s -w $(find -path './vendor' -prune -o -type f -name '*.go' -print))`
  `goimports -w $(find -name '*.go' | grep -v vendor)`
/assign mattmoor
2019-10-23 13:37:29 -07:00
Adam Harwayne e76e90e464 jsonTrace errors are retried until the timeout. (#760)
* jsonTrace errors are retried until the timeout.

* Update test/zipkin/util.go

Co-Authored-By: Chi Zhang <chizhg@google.com>
2019-10-15 10:42:17 -07:00
Adam Harwayne e0149df35c Remove CheckZipkinPortAvailability. (#693)
The check did not work well on Macs, where calling JSONTrace would fail immediately because the check failed.
2019-09-18 10:31:47 -07:00
mattmoor-sockpuppet 2b5e8011b8 golang format tools (#672)
Produced via:
  `gofmt -s -w $(find -path './vendor' -prune -o -type f -name '*.go' -print))`
  `goimports -w $(find -name '*.go' | grep -v vendor)`
/assign mattmoor
2019-09-13 07:40:34 -07:00
Adam Harwayne 343f1649fe JSONTrace returns a structured object, not just a string. (#658)
* JSONTrace returns a structured object, not just a string.

* Fix usage in spoof.go.

* Update test/zipkin/util.go

Co-Authored-By: Victor Agababov <vagababov@gmail.com>

* Update test/zipkin/util.go

Co-Authored-By: Victor Agababov <vagababov@gmail.com>

* PR comments.
2019-09-12 10:48:38 -07:00
mattmoor-sockpuppet 1864f499dc golang format tools (#497)
Produced via:
  `gofmt -s -w $(find -path './vendor' -prune -o -type f -name '*.go' -print))`
  `goimports -w $(find -name '*.go' | grep -v vendor)`
/assign @mattmoor
2019-06-27 07:37:08 -07:00
Matt Moore 222dd25986 Migrate pkg to use the knative.dev/pkg import path (#489)
* Manual changes.

* scripted changes.
2019-06-26 13:02:06 -07:00
srinivashegde86 c35005418b Refactor zipkin to add ability to get trace from traceId (#348) 2019-03-28 11:42:55 -07:00
srinivashegde86 684620ff81 Make monitoring components take namespace arg instead of defaulting to istio namespace (#316) 2019-03-12 11:23:43 -07:00
srinivashegde86 e5c43dce06 Separate common monitoring methods into monitoring package (#302)
* Separate common monitoring methods into monitoring package

* Add doc.go to monitoring

* Update doc.go to add information about the public methods

* Fix build tests
2019-03-02 18:20:38 -08:00
srinivashegde86 cccc0604d0 Use FormatLogger instead of func parameter (#297) 2019-02-27 15:47:49 -08:00
dushyanthsc 41761b2c81 Adding default zipkin tracing support to SpoofClient (#273)
Existing support for Zipkin tracing pushes the
responsibility of logging zipkin traces to
individual tests. This change moves the responsibility
to SpoofClient, so that all tests get it by default.
Traces are logged only for requests that have
encountered Server errors i.e if the
http.Response.StatusCode between 500 to 599.

For SpoofingClient.Poll calls we only log trace of the
final SpoofingClient.Do made.
2019-02-25 10:40:48 -08:00
Victor Agababov a330baa9b0 Grep fix formatting issues (#233)
* Some fixes to the spoof.go and exporter.go

While reviewing some other CL, I saw some avenues for improving
spoof.go, to log the URL that's being fetched, which would help in test
debugging and to use switch construct, rather than nested if's.

While testing the change, I noticed some shifty loggin from the
exporter, so I fixed that as well while I was there.

* Continuation of the previous cleanups.

* Fix the issues with formatting by executing a grep

* and fix compilation error

* lowercase error

* fix the newly changed unit test
2019-01-18 14:33:32 -08:00
mattmoor-sockpuppet d99eb0732f Run gofmt (#171)
Produced via: `gofmt -s -w $(find -name '*.go' | grep -v vendor)`
2018-11-26 07:18:22 -08:00
dushyanthsc 083969f9a0 Adding Zipkin tracing support for SpoofingClient (#119) 2018-10-31 09:06:37 -07:00