Closed dsimansk closed 4 years ago
I managed to reproduce the behaviour with plain yamls also:
kubectl create ns test
kubectl label namespace test knative-eventing-injection=enabled
kubens test
--> wait a bit for broker pods to start
kubectl apply -f https://raw.githubusercontent.com/matzew/knative-eventing-samples/master/03-source_broker/000-ksvc2.yaml kubectl apply -f https://raw.githubusercontent.com/matzew/knative-eventing-samples/master/03-source_broker/030-trigger2.yaml
kubectl delete ns test --> delete op won't finish
3. Check `kubectl get all` that there's only `sub` resource left ([whole yaml](https://gist.github.com/dsimansk/cdab1faac0a580886b9da4e7061b7b1e))
NAME READY REASON AGE subscription.messaging.knative.dev/default-testevents-trigger-6a42b605-6e45-4b56-a08e-47ea08f0d55e Unknown ChannelReferenceFailed 40m
4. `kubectl get ns` will display test ns in `Terminating` state
5. After removing the finalizer the stuck subscription is removed and subsequently the namespace also
kubectl patch subscription.messaging.knative.dev/default-testevents-trigger-6a42b605-6e45-4b56-a08e-47ea08f0d55e -p '{"metadata":{"finalizers": []}}' --type=merge
I wonder if that might be related to apiVersion disprepancy from [recent change](https://github.com/knative/eventing/pull/2595), that seems similar to [the following issue](https://github.com/knative/eventing/issues/2464). Or a more generic problem related to switch to generated reconciler for subscription.
Thanks! It seems to me it's a duplicate of https://github.com/knative/eventing/issues/2633.
Subscriptions cannot be deleted when its associated channel is deleted first. The finalizer is not removed.
Indeed this issue is just another manifestation of the above problem.
@lionelvillard thanks for pointing that out and sorry I should have used search first. :)
/close duplicate
/close
@matzew: Closing this issue.
How do you work around this issue?
no work ariund, but this is a dup
see comments above.
On Fri 28. Feb 2020 at 20:21, Aaron Stainback notifications@github.com wrote:
How do you work around this issue?
— You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub https://github.com/knative/eventing/issues/2668?email_source=notifications&email_token=AABGPTQZODYGCJ3MIK4E34LRFFP4FA5CNFSM4K45REVKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOENJ2SWY#issuecomment-592685403, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABGPTTFLRY77M44ZG3EINDRFFP4FANCNFSM4K45REVA .
-- Sent from Gmail Mobile
@AceHack The most straightforward workaround is to remove finalizer, e.g.:
kubectl patch <stale-subscription-name> -p '{"metadata":{"finalizers": []}}' --type=merge
@AceHack The most straightforward workaround is to remove finalizer, e.g.:
kubectl patch <stale-subscription-name> -p '{"metadata":{"finalizers": []}}' --type=merge
This was fixed last friday here: https://github.com/knative/eventing/pull/2676. Pull latest master and it should work
Describe the bug The issue started to manifest itself in knative/client E2E tests running against nightly releases. The tests prepare namespace with labe to inject broker, create, update, delete triggers and finally teardown method deletes the testing namespace. However, the namespace is stuck in terminating state with
subscription
resources left there.E2E tests log dump, look for
kne2etests8
.Eventing controller log:
The exact steps test is going through: https://github.com/knative/client/blob/master/test/e2e/trigger_test.go#L30
Expected behavior When namespace is deleted, all belonging resources are successfully deleted.
To Reproduce
./test/e2e-tests-local.sh -run ^TestBrokerTrigger$
Look for namespace
kne2etests0
in terminating stateKnative release version Eventing nightly -
v20200227-598d52ae