Closed navidsh closed 4 years ago
We need a way to track "claims" on an Application CR. Each resource that specifies to auto-create an Application of a given name, places a claim on that Application. The claims must be tracked such that the Application is deleted only after the final claimant is deleted.
Implementationally:
"kappnav.app.auto-created.from.name" needs to essentially be array .
E.g. after first claim, made by Deployment dep-1:
kappnav.app.auto-created.from.name: [ dep-1 ]
After second claim, made by Deployment dep-2:
kappnav.app.auto-created.from.name: [ dep-1, dep-2 ]
After dep-1 is deleted:
kappnav.app.auto-created.from.name: [ dep-2 ]
After dep-2 is deleted:
kappnav.app.auto-created.from.name: ---> delete Application CR
Bug Report
What did you do?
app-1
andapp-2
) in the same namespace and added the following labels and annotations to both deployments:kAppNav create an
Application
CR with the following annotations:I deleted
app-1
and the automatically generatedApplication
CR got deleted.What did you expect to see?
I expected an
Application
CR to be available.What did you see instead?
The automatically generated
Application
CR got deleted and never got recreated.Environment
v0.6.0
4.3