Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ability to embed Resource declaration also when embedding Tasks in TaskRuns #313

Closed
bobcatfish opened this issue Dec 5, 2018 · 10 comments
Labels
design This task is about creating and discussing a design help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. meaty-juicy-coding-work This task is mostly about implementation!!! And docs and tests of course but that's a given

Comments

@bobcatfish
Copy link
Collaborator

bobcatfish commented Dec 5, 2018

Expected Behavior

In #262 @pivotal-nader-ziada made it possible to embed a Task Spec into a TaskRun - this way you can create a TaskRun without needing to create a Task first - the goals here are:

  1. Make it easy to migrate from knative/build to Task/TaskRun
  2. Support the use case where Builds are embedded into specs in knative/serving and are self contained

It should be possbile to put all of the info required for a TaskRun into a TaskRun.spec without requiring any additional resources to exist first.

Actual Behavior

You can embed a Task spec in a TaskRun, but the Resources the TaskRun refers to must exist at the time of the TaskRun creation.

This means if you embedded a TaskRun in a knative/serving spec, you'd have to have created the required Resources beforehand.

Additional Info

Discussion about resources in the PR

@bobcatfish bobcatfish added this to the Build -> Task Migration milestone Dec 5, 2018
@bobcatfish bobcatfish added help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. design This task is about creating and discussing a design labels Dec 6, 2018
@bobcatfish
Copy link
Collaborator Author

(Build functionality needs specifically GCS + Git Resource types)

Can make sense to work on alongside migrating yaml tests (#302)

@bobcatfish bobcatfish changed the title Investigate Resource declaration when embedding Tasks in TaskRuns Add ability to embed Resource declaration also when embedding Tasks in TaskRuns Jan 10, 2019
@shashwathi
Copy link
Contributor

@bobcatfish : I have added a design doc to discuss proposed solutions. Please comment on it and we can get better alignment 👍

https://drive.google.com/open?id=1BQDfihryPT25_kyBX0pmilBaFsASkZBlbRsUDF1RUew

@bobcatfish
Copy link
Collaborator Author

Great write up @shashwathi ! I'm having trouble picking one approach over the other, so I'm interested to hear what other ppl (particularly @imjasonh ) think.

Also would like to understand more about whether we intend to support this indefinitely or if it's more of a temporary stepping stone @imjasonh .

@imjasonh
Copy link
Member

@bobcatfish I think we should assume Serving will want the feature for the foreseeable future. Left comments on the doc. I like resourceSpec. 👍

@bobcatfish
Copy link
Collaborator Author

I was definitely thinking only about migration and not thinking about the serving use case at all 🤦‍♀️ I'm on board with the resourceSpec solution, especially if this is long term!

For handling the GCS type, I'm leaning toward adding a new resource type specifically for the build GCS functionality.

@shashwathi
Copy link
Contributor

I'm on board with the resourceSpec solution, especially if this is long term!

I think @imjasonh @bobcatfish @pivotal-nader-ziada and I are okay with this solution so we can go ahead with this approach unless there is any objection. I will probably tackle this first.

For handling the GCS type, I'm leaning toward adding a new resource type specifically for the build GCS functionality.

I like this solution too. @pivotal-nader-ziada @bobcatfish and I are okay with this solution so lets go ahead with approach unless there is any objection. I will probably do this in follow up PR (in case we change our minds with another approach).

@bobcatfish bobcatfish added the meaty-juicy-coding-work This task is mostly about implementation!!! And docs and tests of course but that's a given label Jan 22, 2019
@bobcatfish
Copy link
Collaborator Author

@tejal29 to tackle the new GCS resource, maybe in a separate issue

@bobcatfish
Copy link
Collaborator Author

Looks like we've to a separate issue for the GCS resource in #415, any objections to closing this one @shashwathi ? :D

@shashwathi
Copy link
Contributor

Feel free to close this issue @bobcatfish

@bobcatfish
Copy link
Collaborator Author

awesome :D 🎉

@bobcatfish bobcatfish added okr This is for some internal Google project tracking and removed okr This is for some internal Google project tracking labels Feb 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
design This task is about creating and discussing a design help wanted Denotes an issue that needs help from a contributor. Must meet "help wanted" guidelines. meaty-juicy-coding-work This task is mostly about implementation!!! And docs and tests of course but that's a given
Projects
None yet
Development

No branches or pull requests

3 participants