Commit Graph

1216 Commits

Author SHA1 Message Date
Victor Agababov c30ec2ffd4
Fix the flaky test. (#1632)
The test assumes the threads would schedule in particular way, but they don't.
But what we really care to check is that we thread in the proper RL and it works.
We don't need to check that underlying queue impl works, that's done in its own tests.
So just verify these two things.
2020-08-18 17:06:13 -07:00
Yanwei Guo c53747eef4
Document repos without deps on seving or eventing (#1633) 2020-08-18 15:36:13 -07:00
Matt Moore 9949da0736
[master] Auto-update dependencies (#1631)
Produced via:
  `./hack/update-deps.sh --upgrade && ./hack/update-codegen.sh`
/assign n3wscott vagababov
/cc n3wscott vagababov
2020-08-18 09:12:14 -07:00
Victor Agababov c451e3c37f
Various cleanups around the codebase (#1630)
* Various cleanups around the codebase

- unindent the else after return
- make things private that are not used anywhere
- rearrange params
- etc

* add
2020-08-17 19:11:13 -07:00
Matt Moore c4535cf5bf
[master] Format markdown (#1629)
Produced via:
  `prettier --write --prose-wrap=always $(find -name '*.md' | grep -v vendor | grep -v .github | grep -v docs/cmd/)`
/assign n3wscott vagababov
/cc n3wscott vagababov
2020-08-17 08:53:07 -07:00
Matt Moore 6d1b0e9062
Make the match about smarter about filtering its own tests. (#1624)
I see this in Serving:
```
=== CONT  TestSecretVolume
    kubelogs.go:197: I 11:01:04.358 controller-79bd7dbf6b-d4fkg [revision-controller] [serving-tests/secret-volume-dgqznzoi-jq457] Reconcile succeeded. Time taken: 21.144µs
    kubelogs.go:197: I 11:01:04.621 webhook-59bb47db88-wpwbw [conversion/conversion.go:133] [serving-tests/projected-secret-volume-ogqtvwfy] Converting [kind=Service group=serving.knative.dev version=v1] to version serving.knative.dev/v1alpha1
```

The projected volume inclusion is clearly a collision due to matching suffix.

Since we expect this to be a resource name prefix, expect to see the `/` delimiter prior to is in the key.
2020-08-16 12:06:06 -07:00
Matt Moore 3ac62a93ca
Fix the logkey.Key tagging in Enqueue. (#1627)
Debugging https://github.com/knative-sandbox/net-contour/issues/214 I noticed the logging was showing up as:

```
"knative.dev/key":{"knative.dev/key":"serving-tests/service-create-and-update-teaoccuu"}
```
2020-08-16 11:49:06 -07:00
Weston Haught 2eaf40292b
don't pre/post process if skipstatusupdate (#1625) 2020-08-15 08:51:06 -07:00
Matt Moore 0e023a2069
Assorted tweaks to actions. (#1623)
Drop GOPATH from all except verify (codegen needs it), and change directories to just use workspace.

Switch to Go 1.15 (go.mod actually controls what's used IIUC).
2020-08-14 20:01:06 -07:00
Scott Nichols 7dec722e26
found another way to get repo name in gh actions (#1622)
* foiund another way to get repo name

* fix vet errors

* did not mean 14
2020-08-14 18:48:06 -07:00
Scott Nichols 3cc3a54f71
adding build, unit test, style and verify github actions (#1621)
* adding build, unit test, style and verify github actions

* don't turn off gomod

* adding copyright header

* fetch depth 1
2020-08-14 10:45:06 -07:00
Pierangelo Di Pilato bab2f360d1
Add eventing-kafka-broker to released repositories (#1612) 2020-08-14 10:21:06 -07:00
Matt Moore 8cc790c308
Write a little guide on using logstream. (#1620) 2020-08-14 09:55:06 -07:00
Matt Moore 2d4147a2fb
[master] Auto-update dependencies (#1619)
Produced via:
  `./hack/update-deps.sh --upgrade && ./hack/update-codegen.sh`
/assign n3wscott vagababov
/cc n3wscott vagababov
2020-08-14 09:40:07 -07:00
Yanwei Guo c9f9284521
hasbucket (#1618) 2020-08-13 08:56:05 -07:00
Matt Moore c4576fd38e
[master] Auto-update dependencies (#1614)
Produced via:
  `./hack/update-deps.sh --upgrade && ./hack/update-codegen.sh`
/assign n3wscott vagababov
/cc n3wscott vagababov
2020-08-12 11:35:06 -07:00
Matt Moore 6e86cc9e9f
[master] Format markdown (#1613)
Produced via:
  `prettier --write --prose-wrap=always $(find -name '*.md' | grep -v vendor | grep -v .github | grep -v docs/cmd/)`
/assign n3wscott vagababov
/cc n3wscott vagababov
2020-08-12 11:22:06 -07:00
Markus Thömmes 5ecc046747
Replace error return with logging to all tests in an error case. (#1616) 2020-08-12 08:31:05 -07:00
Adam Harwayne 530eac8757
Inject the config into the context. (#1610) 2020-08-11 16:18:05 -07:00
Victor Agababov 0ecf6f86c1
Fix the debug->debugf (#1609)
this is a shame cube situation
2020-08-11 14:58:05 -07:00
Nghia Tran f97925ab85
Add a release leads rotation. (#1584)
* Add a release master rotation.

* Update markdown links.

* Update Markdown links.

* Update per PR feedbacks

* Update roster info.

* Update to include Peribolos instructions.
2020-08-11 11:21:06 -07:00
Dave Protasowski 2f05039198
fix nil pointer (#1604) 2020-08-11 09:29:06 -07:00
Matt Moore f9904deb32
[master] Auto-update dependencies (#1605)
Produced via:
  `./hack/update-deps.sh --upgrade && ./hack/update-codegen.sh`
/assign n3wscott vagababov
/cc n3wscott vagababov
2020-08-11 08:22:06 -07:00
Victor Agababov 473bba04ee
Fix comment to ensure we tell the truth to the world (#1601)
* Make sure GetCondition actually returns the condition

otherwise we return the temp object that loop variable points at.

* comment

* fix

* meh

* update
2020-08-10 15:35:05 -07:00
Dave Protasowski 20e1d27cd6
add helper to parse namespaced names (#1600)
* add helper to parse namespaced names

* address feedback

* drop comment & re-order checks

* address vagababov feedback

* add optional method and include note about namespace being required
2020-08-10 15:00:05 -07:00
Markus Thömmes c903170f41
Completely skip metric reporting if backend is 'none'. (#1599) 2020-08-10 10:22:30 -07:00
Julian Friedman 095ff27da6
Automatically set GOMAXPROCS using automaxprocs library (#1585) 2020-08-10 02:00:30 -07:00
Matt Moore 3a98b0671c
Have codegen log status diffs at debug level (#1598)
Fixes: https://github.com/knative/pkg/issues/1597
2020-08-08 11:49:29 -07:00
Victor Agababov 5f6cb70257
Switch to the atomic bool from uber package (#1595)
- makes code easier to follow
- hides the int32->bool conversions inside the library
2020-08-07 22:31:28 -07:00
Scott Nichols 7b92ffa783
filter "control-plane" labeled namespaces out of our webhooks (#1592)
* include a filter on control plane namespaces for defaulting and validation webhooks from knative/pkg

* Update unit tests to include control-plane

* adding a comment to explain why we are adding 'control-plane' to the webhook config
2020-08-07 14:23:29 -07:00
Evan Anderson e487a47312
Use real synchronization to make sure we get four exports in the OpenCensus test (#1591)
* Use real synchronization to make sure we get four exports in the OpenCensus test.

* Fix a few bugs in the metrics implementation:

1. We could create two OpenCensus exporters for the empty resource, which would cause double-reporting
2. Add a mechanism to clear out background Meter threads to to prevent them exporting in subsequent tests.
2020-08-07 11:51:29 -07:00
Yanwei Guo 2ca3559ae9
delete (#1589) 2020-08-07 09:29:29 -07:00
Victor Agababov 62f2560aa7
Also log the key we're enqueueing when printing debug info (#1594) 2020-08-06 16:07:28 -07:00
Yanwei Guo ec67865ad3
timeout (#1593) 2020-08-06 15:02:28 -07:00
Victor Agababov b009e03f9c
Remove ErrGroup from kubelogs altogether (#1588)
* Remove ErrGroup from kubelogs altogether

The latest change makes eg never to exit. In reality we don't really need EG there at all
and can just store the error.
This will return the _latest_ error, but 🤷

* fix
2020-08-06 12:01:29 -07:00
Matt Moore 0942cfc0f9
Replace init with sync.Once (#1587)
* Replace init with sync.Once

This makes things insensitive to link ordering.

* Add clarity when we use the null logstream.

* fold namespace into if
2020-08-06 10:48:29 -07:00
Matt Moore 2aae6f373d
Fixes a race in the logstream. (#1586)
`eg.Wait` cannot be called before `eg.Go` without tripping Go's race detection.

Internally errgroup uses sync.Wait, which has [the following](https://godoc.org/sync#WaitGroup.Add) warning:

> Note that calls with a positive delta that occur when the counter is zero must happen before a Wait

When `eg.Go` isn't clearly called prior to `eg.Wait` the read of the error field in `eg.Wait` races with the
assignment of the error field in the once of `eg.Go`.
2020-08-05 19:22:28 -07:00
Stavros Kontopoulos 23ef76f986
Add field to observability config for enabling request logging (#1577)
* add field for enabling request logging

* fixes

* update logic

* add unit tests

* add comment
2020-08-05 09:19:28 -07:00
Matt Moore bb91a15b1a
Add Cleanup to our weird test interface. (#1582) 2020-08-04 21:56:28 -07:00
jjzeng-seattle bac0302109
Set reporting period for all meters (#1575)
* Set reporting period for all meters

* using switch statement to simplify

* Change 60 seconds to a minute

* Add a test case for openCencus customed reporting period
2020-08-04 15:06:28 -07:00
Victor Agababov f1e8ecbf78
Disable GC to reduce test flakiness (#1581)
At least twice I saw this report +1 over what we expect, which I attribute
to actual GC being collected.
E.g. https://prow.knative.dev/view/gs/knative-prow/pr-logs/pull/knative_pkg/1580/pull-knative-pkg-unit-tests/1290650655098146816
So disable GC for the duration of this test
2020-08-04 12:12:28 -07:00
Matt Moore c44d6dd98e
[master] Auto-update dependencies (#1580)
Produced via:
  `./hack/update-deps.sh --upgrade && ./hack/update-codegen.sh`
/assign n3wscott vagababov
/cc n3wscott vagababov
2020-08-04 11:39:28 -07:00
Ian Milligan c3c869a344
Remove resourceToKey map (#1579)
There is currently no mechanism to resolve a resource to a unique pointer causing this map to leak
memory.
2020-08-03 22:12:27 -07:00
Jon Donovan 7be5c0a87b
Allow creating controller with custom RateLimiter. (#1546)
* Allow creating controller with custom RateLimiter.

Which was possible before via field modification.
Not switching to a builder pattern mostly for speed of resolution.
Happy to consider alternatives.

* Add tests for new functionality.

Specifically, these test that the Wait() function is notified about
the item, and that the RateLimiter is passed through to the queue.

* Add Options. Gophers love Options.

* Even moar controller GenericOptions.

* Attempt to appease lint, don't create struct for typecheck.

* GenericOptions -> ControllerOptions

* Public struct fields.
2020-08-03 14:31:28 -07:00
Kenjiro Nakayama ba855eb0ac
Allow to specify service name and endpoint IP respectively for zipkin tracing (#1353)
* Allow to specify service name and hostPort for zipkin tracing

This patch allows to specify service name and hostPort for zipkin tracing.

Currently the serviceName(display in the console) and
hostPort(endpoint) must be same name.
To make matters worse, the hostPort only supports `80` port.

This patch allows to specify both serviceName and hostPort. Also,
hostPort can be `IP:PORT` format for port customization.

* Fix review comments

* Remove port
2020-08-03 10:35:02 -07:00
Markus Thömmes 175d8bd926
Print loglines from chaosduck to all tests. (#1576)
* Print loglines from chaosduck to all tests.

* Review.
2020-08-03 10:23:02 -07:00
Matt Moore 33faa4a540
[master] Auto-update dependencies (#1578)
Produced via:
  `./hack/update-deps.sh --upgrade && ./hack/update-codegen.sh`
/assign n3wscott vagababov
/cc n3wscott vagababov
2020-08-03 09:48:02 -07:00
Victor Agababov 6940870178
Fix the test for go 1.15 (#1574)
The duration parsing errors are now quoted, so check for prefix
2020-07-30 17:51:01 -07:00
Weston Haught 921b663d17
add a json tag to volatile_time (#1572) 2020-07-30 17:14:00 -07:00
Victor Agababov 845edf5423
Give table test some love it sorely misses (#1573)
Precache cmp opts, replace unnecessary diffs with equals.
Some string and formatting improvements.
2020-07-30 16:14:00 -07:00