This exposes metrics for the properties available through [here](https://godoc.org/runtime#MemStats) so that we can get some better visibility into things like GC pressure.
* Remove caching in test logger setup
* Revert "Remove caching in test logger setup"
This reverts commit e3c5349e3c.
* Don't create new logger in SetupFakeContextWithCancel
* Revert "Don't create new logger in SetupFakeContextWithCancel"
This reverts commit 2d57ccf028.
* Remove test logger cache, and leave an empty shell for ClearAll()
By default raised SIGPIPE signal will cause the program to exit immediately[1]
and bypass any shutdown logic.
Add syscall.SIGPIPE to the signals we get notified to disable this behavior.
[1] https://golang.org/pkg/os/signal/#hdr-SIGPIPE
Signed-off-by: Slavomir Kaslev <kaslevs@vmware.com>
* make slack config file accessible from benchmarks
* refactor config for Mako test
* fix unit test
* fix the name
* remove the config file for slack
* revert some changes
* Add autoscaling to cluster creation
* Apply suggestions from code review
Co-Authored-By: Adriano Cunha <35786489+adrcunha@users.noreply.github.com>
* fixing a test failure
The 1.14 K8s test libs introduce changes that broke how we were testing this, but it still works in the cases we care about, so this adjusts the test to more accurately test the reactor in the way we actually care about.
* Create cluster with addon
* Apply suggestions from code review
Co-Authored-By: Victor Agababov <vagababov@gmail.com>
Co-Authored-By: Adriano Cunha <35786489+adrcunha@users.noreply.github.com>
This adds logic to hook into two other metric systems:
1. `cache.SetReflectorMetricsProvider`, which doesn't seem hooked up in Kubernetes yet, but would theoretically give us metrics about the mechanisms underpinning informers.
2. `metrics.Register`, which hooks us into the rest client infrastructure to give us metrics about low-level API server calls.
Fixes: https://github.com/knative/pkg/issues/679
Fixes: https://github.com/knative/pkg/issues/680
We have been maintaining a copy of this helper function in the Knative
Serving tests. Moving it here and adding tests so it can be used more
generally. The function allows creating a []byte patch without having to
check two levels of error conditions.
* renaming source_name and source_resource_group to name and resource_group,
as they will be used in other resources
* updating
* updates based on code review
* update
* fix
* source stats reporter... should be used by well-behaved sources
* public fields
* moving serialization/deserialization of metrics and logging maps to pkg
* nits
* adding UT
* same order
* updates
* sock-puppet
* unregistration problem?
* removing base64 encoding
* removing TODO
* removing config changes... done in another PR
* to properly address the comment
* changing importer to source
* moving stats_reporter to new source folder
* fixing UT
* Introduce error util ErrInvalidCombination for invalid combination
Sometimes valid value becomes invalid value by combination.
example 1. https://github.com/knative/serving/issues/5382
example 2. following combination in `spec.traffic`.
```
traffic:
- latestRevision: true
revisionName: hello-example-dk7nd
percent: 100
```
But there are no error util for them, so we need to create
custom error like c1583f3045
or `ErrInvalidValue`.
The custom error will make code complicated and `ErrInvalidValue` is
not debug friendly.
To solve it, this patch introduces an util func `ErrInvalidCombination`.
* Introduce ErrGeneric instead of ErrInvalidCombination
* 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.
* add slack operations and the main alerter
* function renaming
* solve the codereview issues
* address feedbacks
* add unit test and fix some old unit tests
* source stats reporter... should be used by well-behaved sources
* public fields
* moving serialization/deserialization of metrics and logging maps to pkg
* nits
* adding UT
* same order
* updates
* sock-puppet
* unregistration problem?
* removing base64 encoding
* removing TODO
* removing config changes... done in another PR
* to properly address the comment
* changing importer to source
* moving stats_reporter to new source folder
* source stats reporter... should be used by well-behaved sources
* public fields
* moving serialization/deserialization of metrics and logging maps to pkg
* nits
* adding UT
* same order
* updates
* sock-puppet
* unregistration problem?
* removing base64 encoding
* removing TODO
* removing config changes... done in another PR
* to properly address the comment
* changing importer to source