Test-infra: Make plank an actual Kubernetes controller

Created on 8 Sep 2019  路  20Comments  路  Source: kubernetes/test-infra

What would you like to be added:

Plank to be changed to be an actual Kubernetes controller

Why is this needed:

Plank is currently implemented as a CronJob with a 30 seconds interval. It would be great if it was an actual controller instead that gets notified whenever a ProwJob or Pod resource changes, because that would allow it to instantly react which would be a nicer user experience.

Also, having a sync loop that acts on one ProwJob rather than a huge list of ProwJobs will most likely simplify the code and make it more efficient, as we will stop looping over outdated ProwJobs CRs.

/area prow
/area prow/plank

areprow areproplank kinfeature lifecyclrotten

Most helpful comment

I would imagine the whole transition to roughly go like this:

  • Plank gets updated to use Listers for ProwJobs
  • Plank gets updated to use Listers for Pods
  • A featuregated "PlankV2" implementation gets added that is an actual controller. All existing tests get executed and pass against it
  • Interested parties try out PlankV2 and provide feedback
  • We start being confident in PlankV2, make it the default and delete the current implementation

All 20 comments

I would imagine the whole transition to roughly go like this:

  • Plank gets updated to use Listers for ProwJobs
  • Plank gets updated to use Listers for Pods
  • A featuregated "PlankV2" implementation gets added that is an actual controller. All existing tests get executed and pass against it
  • Interested parties try out PlankV2 and provide feedback
  • We start being confident in PlankV2, make it the default and delete the current implementation

In a perfect world this happens after GitHub work is removed from plank and resides squarely in sinker. @krzyzacy what's the final status of that?

@stevekuznetsov you are talking about the reporting and mean [...] and resides squarely in crier or not?

The "Plank reports to GitHub" part is deprecated and redundant with what crier does, so we can just not add it to a PlankV2

Yep, agreed, but IIRC we've had some small issues with rollout and OpenShift's deployment is not on crier yet so I'd hope we all migrate to using it before plank-2:1.0.0 is ready

in a perfect world this happens after GitHub work is removed from plank

I have no idea with the status for all the prow deployments in wild, but at least our deployments are on crier now.

Sweet, and we have fixed all the weird PATCH issues? Is there any concise doc on how to switch over?

@stevekuznetsov It does PATCH and we have apparently multiple redundant fixes, namely both the crier controller doing wait.Poll to make sure it doesn't act on an outdated cache _and_ hardcoding the GitHub reporter to max one worker.

And it seems we are also using Plank for GitHub and crier only for Slack reporting

I am ready to move once someone shows me how!

I still need to get https://github.com/kubernetes/test-infra/pull/13952 in... (It's hard to work on OSS and internal at the same time, different dev envs, but let me rebase that PR)

For doc, there is https://github.com/kubernetes/test-infra/tree/master/prow/crier#migration-from-plank-for-github-report, I'm not too up to date with all the controllers, I can read it again.

/assign

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.

If this issue is safe to close now please do so with /close.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle stale

Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.

If this issue is safe to close now please do so with /close.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle rotten

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/close

@fejta-bot: Closing this issue.

In response to this:

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

/reopen

@alvaroaleman: Reopened this issue.

In response to this:

/reopen

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/close

@fejta-bot: Closing this issue.

In response to this:

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

/reopen
This is actively being worked on in https://github.com/kubernetes/test-infra/pull/17626

@alvaroaleman: Reopened this issue.

In response to this:

/reopen
This is actively being worked on in https://github.com/kubernetes/test-infra/pull/17626

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

BenTheElder picture BenTheElder  路  4Comments

spiffxp picture spiffxp  路  3Comments

lavalamp picture lavalamp  路  3Comments

BenTheElder picture BenTheElder  路  3Comments

cjwagner picture cjwagner  路  3Comments