* split and update
* bug fixed
* change the copyright year
* use fake metadata in tests
* exclude test coverage for gcp_metadata
* add record
* add tests
* revert 2019 and add a new var
* change documents
* address comment
* change line
* 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
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.
* Add a variant of wait for status with explicit timeout.
This permits setting higher timeouts in the performance tests,
which it seems take longer to come to life.
* revert the default timeout change
* split and update
* bug fixed
* change the copyright year
* use fake metadata in tests
* exclude test coverage for gcp_metadata
* revert 2019 change on existing files
This is a breaking change, that can be fixed up by replacing `logger,` with `logger.Infof,` in the argument lists for these functions.
This is part of a larger cleanup to allow us to use alternate log methods like `t.Logf` in place of `BaseLogger`.
* Simplify and comment AppenRandomString
Port and rewrite the comment from the original.
Remove the sync.Once(). Initializing during package initialization is just as good.
Mutex doesn't have to be a pointer
* remove fancy rnd, remove mutex, add example, which would also check compilation
* actually commit the example
* add licence
* Metrics logging fix in pkg/test: Issue-3150
https://github.com/knative/serving/issues/3150 describes the issue
that currently exists in our test logging framework. This change
fixes the problem by prefixing metrics that needs to be emited by
a constant which the logging.ExpoxtSpan method then uses to identify
the spans that needs to be emitted as logs
Note this only fixes part of the issue:
https://github.com/knative/serving/issues/3150
this change needs to be ported to knative serving before the issue
can be closed.
* Update test/logging/logging.go
Adding required lines.
Co-Authored-By: dushyanthsc <43390008+dushyanthsc@users.noreply.github.com>
* Drop webhook logic to increment spec.generation
With Kubernetes 1.11+ metadata.generation now increments properly
when the status subresource is enabled on CRDs
For more details see: https://github.com/knative/serving/issues/643
* Drop the generational duck type
* Initial commit for the webhook to set the annotations about mutator.
The user that created or updated the resource will be set in the
annotations.
* update comments
* remove debug logging
* logging :/
* logging :/, returns
* logging :/ III
* error wrap
* simplify test
* rename the test
* add pkg/errors to the deps for better errors
* do not require CRD to implement Annotatable
* review issues
* fix interface as required by review
* Cleanup the webhook code.
- add more tests
- fix formatting
- fix logging and errors
- use shorthands
- some optimizations in types
- make code more Go'ey from C'ey.
* raise test coverage
* Add ping message verification to the websocket connection.
* Recycle ticker.
* Add comment.
* Fix datarace by waiting for goroutines to finish on Shutdown.
* fix very annoying logging in the integration tests
* Add clean test loggers method.
This would help us run the tests over-and-over again.
Currently the test hogs `t` and that object is not reusable.
* Add static endpoint override to test/spoof
When testing locally its common to use a cluster which both does not
have resolvable dns for ksvcs and does not have public IPs. Support
overriding the endpoint for knative's ingress controller to a static
value which can be set to e.g. the knative-ingressgateway nodeport.
* Fix 2 broken links
* Cleanup websocket connection, actually test reconnects.
* Some more cleanup.
* Locally define connFactory to avoid races.
* Move locks around, harden test.
* Add logging.
* Drop redundant target.
* Move message encoding outside of the writerLock.
* Fix assignment nit.
* Remove named return value.
* Add close signal to long-running loops.
* Add todo for returning a messageType.
* Bump header to 2019.
* Add note on draining the messageChan.
* Drop target from signature.
* Drop target from test.
* Add a more speaking example to draining the messageChan.
* Fix typo.
* Relax read lock, improve test.
* Bump test coverage.
* Add double shutdown test.
* Remove code duplication in test.
* Webhook creates a patch for all fields generated by round tripping the JSON through Golang types.
* Add unit tests for InnerDefaultResource.
* Linter errors.
* PR comments - test changes
* t.Helper()
* PR comments.