Merge pull request #36355 from soltysh/deprecate_extensionsjob

Automatic merge from submit-queue

 Deprecate extensions/v1beta1.Jobs related stuff

This PR supersedes https://github.com/kubernetes/kubernetes/pull/33861, it's a pre-req for removing `extensions/v1beta1.Jobs` (#32763) in the next release. 

@kubernetes/kubectl @kubernetes/api-review-team ptal
@bgrant0607 @erictune @janetkuo fyi

```release-note
Deprecate extensions/v1beta1.Jobs
```
This commit is contained in:
Kubernetes Submit Queue 2016-11-08 07:18:40 -08:00 committed by GitHub
commit 3b31c9f019
8 changed files with 18 additions and 11 deletions

View File

@ -33555,7 +33555,7 @@
} }
}, },
"v1beta1.Job": { "v1beta1.Job": {
"description": "Job represents the configuration of a single job.", "description": "Job represents the configuration of a single job. DEPRECATED: extensions/v1beta1.Job is deprecated, use batch/v1.Job instead.",
"properties": { "properties": {
"metadata": { "metadata": {
"description": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", "description": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
@ -33605,7 +33605,7 @@
} }
}, },
"v1beta1.JobList": { "v1beta1.JobList": {
"description": "JobList is a collection of jobs.", "description": "JobList is a collection of jobs. DEPRECATED: extensions/v1beta1.JobList is deprecated, use batch/v1.JobList instead.",
"required": [ "required": [
"items" "items"
], ],

View File

@ -10194,7 +10194,7 @@
}, },
"v1beta1.JobList": { "v1beta1.JobList": {
"id": "v1beta1.JobList", "id": "v1beta1.JobList",
"description": "JobList is a collection of jobs.", "description": "JobList is a collection of jobs. DEPRECATED: extensions/v1beta1.JobList is deprecated, use batch/v1.JobList instead.",
"required": [ "required": [
"items" "items"
], ],
@ -10222,7 +10222,7 @@
}, },
"v1beta1.Job": { "v1beta1.Job": {
"id": "v1beta1.Job", "id": "v1beta1.Job",
"description": "Job represents the configuration of a single job.", "description": "Job represents the configuration of a single job. DEPRECATED: extensions/v1beta1.Job is deprecated, use batch/v1.Job instead.",
"properties": { "properties": {
"kind": { "kind": {
"type": "string", "type": "string",

View File

@ -557,7 +557,7 @@ span.icon > [class^="icon-"], span.icon > [class*=" icon-"] { cursor: default; }
<div class="sect2"> <div class="sect2">
<h3 id="_v1beta1_job">v1beta1.Job</h3> <h3 id="_v1beta1_job">v1beta1.Job</h3>
<div class="paragraph"> <div class="paragraph">
<p>Job represents the configuration of a single job.</p> <p>Job represents the configuration of a single job. DEPRECATED: extensions/v1beta1.Job is deprecated, use batch/v1.Job instead.</p>
</div> </div>
<table class="tableblock frame-all grid-all" style="width:100%; "> <table class="tableblock frame-all grid-all" style="width:100%; ">
<colgroup> <colgroup>
@ -4942,7 +4942,7 @@ Both these may change in the future. Incoming requests are matched against the h
<div class="sect2"> <div class="sect2">
<h3 id="_v1beta1_joblist">v1beta1.JobList</h3> <h3 id="_v1beta1_joblist">v1beta1.JobList</h3>
<div class="paragraph"> <div class="paragraph">
<p>JobList is a collection of jobs.</p> <p>JobList is a collection of jobs. DEPRECATED: extensions/v1beta1.JobList is deprecated, use batch/v1.JobList instead.</p>
</div> </div>
<table class="tableblock frame-all grid-all" style="width:100%; "> <table class="tableblock frame-all grid-all" style="width:100%; ">
<colgroup> <colgroup>
@ -6770,7 +6770,7 @@ Both these may change in the future. Incoming requests are matched against the h
</div> </div>
<div id="footer"> <div id="footer">
<div id="footer-text"> <div id="footer-text">
Last updated 2016-11-03 15:10:21 UTC Last updated 2016-11-07 11:40:35 UTC
</div> </div>
</div> </div>
</body> </body>

View File

@ -550,6 +550,7 @@ message IngressTLS {
} }
// Job represents the configuration of a single job. // Job represents the configuration of a single job.
// DEPRECATED: extensions/v1beta1.Job is deprecated, use batch/v1.Job instead.
message Job { message Job {
// Standard object's metadata. // Standard object's metadata.
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
@ -593,6 +594,7 @@ message JobCondition {
} }
// JobList is a collection of jobs. // JobList is a collection of jobs.
// DEPRECATED: extensions/v1beta1.JobList is deprecated, use batch/v1.JobList instead.
message JobList { message JobList {
// Standard list metadata // Standard list metadata
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata

View File

@ -617,6 +617,7 @@ type ThirdPartyResourceDataList struct {
// +genclient=true // +genclient=true
// Job represents the configuration of a single job. // Job represents the configuration of a single job.
// DEPRECATED: extensions/v1beta1.Job is deprecated, use batch/v1.Job instead.
type Job struct { type Job struct {
unversioned.TypeMeta `json:",inline"` unversioned.TypeMeta `json:",inline"`
// Standard object's metadata. // Standard object's metadata.
@ -636,6 +637,7 @@ type Job struct {
} }
// JobList is a collection of jobs. // JobList is a collection of jobs.
// DEPRECATED: extensions/v1beta1.JobList is deprecated, use batch/v1.JobList instead.
type JobList struct { type JobList struct {
unversioned.TypeMeta `json:",inline"` unversioned.TypeMeta `json:",inline"`
// Standard list metadata // Standard list metadata

View File

@ -377,7 +377,7 @@ func (IngressTLS) SwaggerDoc() map[string]string {
} }
var map_Job = map[string]string{ var map_Job = map[string]string{
"": "Job represents the configuration of a single job.", "": "Job represents the configuration of a single job. DEPRECATED: extensions/v1beta1.Job is deprecated, use batch/v1.Job instead.",
"metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
"spec": "Spec is a structure defining the expected behavior of a job. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", "spec": "Spec is a structure defining the expected behavior of a job. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
"status": "Status is a structure describing current status of a job. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", "status": "Status is a structure describing current status of a job. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status",
@ -402,7 +402,7 @@ func (JobCondition) SwaggerDoc() map[string]string {
} }
var map_JobList = map[string]string{ var map_JobList = map[string]string{
"": "JobList is a collection of jobs.", "": "JobList is a collection of jobs. DEPRECATED: extensions/v1beta1.JobList is deprecated, use batch/v1.JobList instead.",
"metadata": "Standard list metadata More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", "metadata": "Standard list metadata More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata",
"items": "Items is the list of Job.", "items": "Items is the list of Job.",
} }

View File

@ -16436,7 +16436,7 @@ var OpenAPIDefinitions *common.OpenAPIDefinitions = &common.OpenAPIDefinitions{
"v1beta1.Job": { "v1beta1.Job": {
Schema: spec.Schema{ Schema: spec.Schema{
SchemaProps: spec.SchemaProps{ SchemaProps: spec.SchemaProps{
Description: "Job represents the configuration of a single job.", Description: "Job represents the configuration of a single job. DEPRECATED: extensions/v1beta1.Job is deprecated, use batch/v1.Job instead.",
Properties: map[string]spec.Schema{ Properties: map[string]spec.Schema{
"metadata": { "metadata": {
SchemaProps: spec.SchemaProps{ SchemaProps: spec.SchemaProps{
@ -16517,7 +16517,7 @@ var OpenAPIDefinitions *common.OpenAPIDefinitions = &common.OpenAPIDefinitions{
"v1beta1.JobList": { "v1beta1.JobList": {
Schema: spec.Schema{ Schema: spec.Schema{
SchemaProps: spec.SchemaProps{ SchemaProps: spec.SchemaProps{
Description: "JobList is a collection of jobs.", Description: "JobList is a collection of jobs. DEPRECATED: extensions/v1beta1.JobList is deprecated, use batch/v1.JobList instead.",
Properties: map[string]spec.Schema{ Properties: map[string]spec.Schema{
"metadata": { "metadata": {
SchemaProps: spec.SchemaProps{ SchemaProps: spec.SchemaProps{

View File

@ -228,6 +228,9 @@ func Run(f cmdutil.Factory, cmdIn io.Reader, cmdOut, cmdErr io.Writer, cmd *cobr
generatorName = "run-pod/v1" generatorName = "run-pod/v1"
} }
} }
if generatorName == "job/v1beta1" {
fmt.Fprintf(cmdErr, "DEPRECATED: --generator=job/v1beta1 is deprecated, use job/v1 instead.\n")
}
generators := f.Generators("run") generators := f.Generators("run")
generator, found := generators[generatorName] generator, found := generators[generatorName]
if !found { if !found {