Initial protobuf generated files
This commit is contained in:
373
pkg/api/resource/generated.pb.go
Normal file
373
pkg/api/resource/generated.pb.go
Normal file
@@ -0,0 +1,373 @@
|
|||||||
|
/*
|
||||||
|
Copyright 2016 The Kubernetes Authors All rights reserved.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by protoc-gen-gogo.
|
||||||
|
// source: k8s.io/kubernetes/pkg/api/resource/generated.proto
|
||||||
|
// DO NOT EDIT!
|
||||||
|
|
||||||
|
/*
|
||||||
|
Package resource is a generated protocol buffer package.
|
||||||
|
|
||||||
|
It is generated from these files:
|
||||||
|
k8s.io/kubernetes/pkg/api/resource/generated.proto
|
||||||
|
|
||||||
|
It has these top-level messages:
|
||||||
|
Quantity
|
||||||
|
QuantityProto
|
||||||
|
*/
|
||||||
|
package resource
|
||||||
|
|
||||||
|
import proto "github.com/gogo/protobuf/proto"
|
||||||
|
import fmt "fmt"
|
||||||
|
import math "math"
|
||||||
|
import _ "github.com/gogo/protobuf/gogoproto"
|
||||||
|
import _ "k8s.io/kubernetes/pkg/util/intstr"
|
||||||
|
|
||||||
|
import io "io"
|
||||||
|
|
||||||
|
// Reference imports to suppress errors if they are not otherwise used.
|
||||||
|
var _ = proto.Marshal
|
||||||
|
var _ = fmt.Errorf
|
||||||
|
var _ = math.Inf
|
||||||
|
|
||||||
|
func (m *Quantity) Reset() { *m = Quantity{} }
|
||||||
|
func (*Quantity) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (m *QuantityProto) Reset() { *m = QuantityProto{} }
|
||||||
|
func (m *QuantityProto) String() string { return proto.CompactTextString(m) }
|
||||||
|
func (*QuantityProto) ProtoMessage() {}
|
||||||
|
|
||||||
|
func init() {
|
||||||
|
proto.RegisterType((*Quantity)(nil), "k8s.io.kubernetes.pkg.api.resource.Quantity")
|
||||||
|
proto.RegisterType((*QuantityProto)(nil), "k8s.io.kubernetes.pkg.api.resource.QuantityProto")
|
||||||
|
}
|
||||||
|
func (m *QuantityProto) Marshal() (data []byte, err error) {
|
||||||
|
size := m.Size()
|
||||||
|
data = make([]byte, size)
|
||||||
|
n, err := m.MarshalTo(data)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
return data[:n], nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *QuantityProto) MarshalTo(data []byte) (int, error) {
|
||||||
|
var i int
|
||||||
|
_ = i
|
||||||
|
var l int
|
||||||
|
_ = l
|
||||||
|
data[i] = 0xa
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(len(m.Format)))
|
||||||
|
i += copy(data[i:], m.Format)
|
||||||
|
data[i] = 0x10
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(m.Scale))
|
||||||
|
if m.Bigint != nil {
|
||||||
|
data[i] = 0x1a
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(len(m.Bigint)))
|
||||||
|
i += copy(data[i:], m.Bigint)
|
||||||
|
}
|
||||||
|
return i, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func encodeFixed64Generated(data []byte, offset int, v uint64) int {
|
||||||
|
data[offset] = uint8(v)
|
||||||
|
data[offset+1] = uint8(v >> 8)
|
||||||
|
data[offset+2] = uint8(v >> 16)
|
||||||
|
data[offset+3] = uint8(v >> 24)
|
||||||
|
data[offset+4] = uint8(v >> 32)
|
||||||
|
data[offset+5] = uint8(v >> 40)
|
||||||
|
data[offset+6] = uint8(v >> 48)
|
||||||
|
data[offset+7] = uint8(v >> 56)
|
||||||
|
return offset + 8
|
||||||
|
}
|
||||||
|
func encodeFixed32Generated(data []byte, offset int, v uint32) int {
|
||||||
|
data[offset] = uint8(v)
|
||||||
|
data[offset+1] = uint8(v >> 8)
|
||||||
|
data[offset+2] = uint8(v >> 16)
|
||||||
|
data[offset+3] = uint8(v >> 24)
|
||||||
|
return offset + 4
|
||||||
|
}
|
||||||
|
func encodeVarintGenerated(data []byte, offset int, v uint64) int {
|
||||||
|
for v >= 1<<7 {
|
||||||
|
data[offset] = uint8(v&0x7f | 0x80)
|
||||||
|
v >>= 7
|
||||||
|
offset++
|
||||||
|
}
|
||||||
|
data[offset] = uint8(v)
|
||||||
|
return offset + 1
|
||||||
|
}
|
||||||
|
func (m *QuantityProto) Size() (n int) {
|
||||||
|
var l int
|
||||||
|
_ = l
|
||||||
|
l = len(m.Format)
|
||||||
|
n += 1 + l + sovGenerated(uint64(l))
|
||||||
|
n += 1 + sovGenerated(uint64(m.Scale))
|
||||||
|
if m.Bigint != nil {
|
||||||
|
l = len(m.Bigint)
|
||||||
|
n += 1 + l + sovGenerated(uint64(l))
|
||||||
|
}
|
||||||
|
return n
|
||||||
|
}
|
||||||
|
|
||||||
|
func sovGenerated(x uint64) (n int) {
|
||||||
|
for {
|
||||||
|
n++
|
||||||
|
x >>= 7
|
||||||
|
if x == 0 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return n
|
||||||
|
}
|
||||||
|
func sozGenerated(x uint64) (n int) {
|
||||||
|
return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63))))
|
||||||
|
}
|
||||||
|
func (m *QuantityProto) Unmarshal(data []byte) error {
|
||||||
|
l := len(data)
|
||||||
|
iNdEx := 0
|
||||||
|
for iNdEx < l {
|
||||||
|
preIndex := iNdEx
|
||||||
|
var wire uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
wire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
fieldNum := int32(wire >> 3)
|
||||||
|
wireType := int(wire & 0x7)
|
||||||
|
if wireType == 4 {
|
||||||
|
return fmt.Errorf("proto: QuantityProto: wiretype end group for non-group")
|
||||||
|
}
|
||||||
|
if fieldNum <= 0 {
|
||||||
|
return fmt.Errorf("proto: QuantityProto: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||||
|
}
|
||||||
|
switch fieldNum {
|
||||||
|
case 1:
|
||||||
|
if wireType != 2 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field Format", wireType)
|
||||||
|
}
|
||||||
|
var stringLen uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
stringLen |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
intStringLen := int(stringLen)
|
||||||
|
if intStringLen < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
postIndex := iNdEx + intStringLen
|
||||||
|
if postIndex > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
m.Format = Format(data[iNdEx:postIndex])
|
||||||
|
iNdEx = postIndex
|
||||||
|
case 2:
|
||||||
|
if wireType != 0 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field Scale", wireType)
|
||||||
|
}
|
||||||
|
m.Scale = 0
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
m.Scale |= (int32(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
case 3:
|
||||||
|
if wireType != 2 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field Bigint", wireType)
|
||||||
|
}
|
||||||
|
var byteLen int
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
byteLen |= (int(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if byteLen < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
postIndex := iNdEx + byteLen
|
||||||
|
if postIndex > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
m.Bigint = append(m.Bigint[:0], data[iNdEx:postIndex]...)
|
||||||
|
if m.Bigint == nil {
|
||||||
|
m.Bigint = []byte{}
|
||||||
|
}
|
||||||
|
iNdEx = postIndex
|
||||||
|
default:
|
||||||
|
iNdEx = preIndex
|
||||||
|
skippy, err := skipGenerated(data[iNdEx:])
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
if skippy < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
if (iNdEx + skippy) > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
iNdEx += skippy
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if iNdEx > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
func skipGenerated(data []byte) (n int, err error) {
|
||||||
|
l := len(data)
|
||||||
|
iNdEx := 0
|
||||||
|
for iNdEx < l {
|
||||||
|
var wire uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
wire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
wireType := int(wire & 0x7)
|
||||||
|
switch wireType {
|
||||||
|
case 0:
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
iNdEx++
|
||||||
|
if data[iNdEx-1] < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return iNdEx, nil
|
||||||
|
case 1:
|
||||||
|
iNdEx += 8
|
||||||
|
return iNdEx, nil
|
||||||
|
case 2:
|
||||||
|
var length int
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
length |= (int(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
iNdEx += length
|
||||||
|
if length < 0 {
|
||||||
|
return 0, ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
return iNdEx, nil
|
||||||
|
case 3:
|
||||||
|
for {
|
||||||
|
var innerWire uint64
|
||||||
|
var start int = iNdEx
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
innerWire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
innerWireType := int(innerWire & 0x7)
|
||||||
|
if innerWireType == 4 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
next, err := skipGenerated(data[start:])
|
||||||
|
if err != nil {
|
||||||
|
return 0, err
|
||||||
|
}
|
||||||
|
iNdEx = start + next
|
||||||
|
}
|
||||||
|
return iNdEx, nil
|
||||||
|
case 4:
|
||||||
|
return iNdEx, nil
|
||||||
|
case 5:
|
||||||
|
iNdEx += 4
|
||||||
|
return iNdEx, nil
|
||||||
|
default:
|
||||||
|
return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
panic("unreachable")
|
||||||
|
}
|
||||||
|
|
||||||
|
var (
|
||||||
|
ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling")
|
||||||
|
ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow")
|
||||||
|
)
|
109
pkg/api/resource/generated.proto
Normal file
109
pkg/api/resource/generated.proto
Normal file
@@ -0,0 +1,109 @@
|
|||||||
|
/*
|
||||||
|
Copyright 2016 The Kubernetes Authors All rights reserved.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
// This file was autogenerated by go-to-protobuf. Do not edit it manually!
|
||||||
|
|
||||||
|
syntax = 'proto2';
|
||||||
|
|
||||||
|
package k8s.io.kubernetes.pkg.api.resource;
|
||||||
|
|
||||||
|
import "k8s.io/kubernetes/pkg/util/intstr/generated.proto";
|
||||||
|
|
||||||
|
// Package-wide variables from generator "generated".
|
||||||
|
option go_package = "resource";
|
||||||
|
|
||||||
|
// Quantity is a fixed-point representation of a number.
|
||||||
|
// It provides convenient marshaling/unmarshaling in JSON and YAML,
|
||||||
|
// in addition to String() and Int64() accessors.
|
||||||
|
//
|
||||||
|
// The serialization format is:
|
||||||
|
//
|
||||||
|
// <quantity> ::= <signedNumber><suffix>
|
||||||
|
// (Note that <suffix> may be empty, from the "" case in <decimalSI>.)
|
||||||
|
// <digit> ::= 0 | 1 | ... | 9
|
||||||
|
// <digits> ::= <digit> | <digit><digits>
|
||||||
|
// <number> ::= <digits> | <digits>.<digits> | <digits>. | .<digits>
|
||||||
|
// <sign> ::= "+" | "-"
|
||||||
|
// <signedNumber> ::= <number> | <sign><number>
|
||||||
|
// <suffix> ::= <binarySI> | <decimalExponent> | <decimalSI>
|
||||||
|
// <binarySI> ::= Ki | Mi | Gi | Ti | Pi | Ei
|
||||||
|
// (International System of units; See: http://physics.nist.gov/cuu/Units/binary.html)
|
||||||
|
// <decimalSI> ::= m | "" | k | M | G | T | P | E
|
||||||
|
// (Note that 1024 = 1Ki but 1000 = 1k; I didn't choose the capitalization.)
|
||||||
|
// <decimalExponent> ::= "e" <signedNumber> | "E" <signedNumber>
|
||||||
|
//
|
||||||
|
// No matter which of the three exponent forms is used, no quantity may represent
|
||||||
|
// a number greater than 2^63-1 in magnitude, nor may it have more than 3 decimal
|
||||||
|
// places. Numbers larger or more precise will be capped or rounded up.
|
||||||
|
// (E.g.: 0.1m will rounded up to 1m.)
|
||||||
|
// This may be extended in the future if we require larger or smaller quantities.
|
||||||
|
//
|
||||||
|
// When a Quantity is parsed from a string, it will remember the type of suffix
|
||||||
|
// it had, and will use the same type again when it is serialized.
|
||||||
|
//
|
||||||
|
// Before serializing, Quantity will be put in "canonical form".
|
||||||
|
// This means that Exponent/suffix will be adjusted up or down (with a
|
||||||
|
// corresponding increase or decrease in Mantissa) such that:
|
||||||
|
// a. No precision is lost
|
||||||
|
// b. No fractional digits will be emitted
|
||||||
|
// c. The exponent (or suffix) is as large as possible.
|
||||||
|
// The sign will be omitted unless the number is negative.
|
||||||
|
//
|
||||||
|
// Examples:
|
||||||
|
// 1.5 will be serialized as "1500m"
|
||||||
|
// 1.5Gi will be serialized as "1536Mi"
|
||||||
|
//
|
||||||
|
// NOTE: We reserve the right to amend this canonical format, perhaps to
|
||||||
|
// allow 1.5 to be canonical.
|
||||||
|
// TODO: Remove above disclaimer after all bikeshedding about format is over,
|
||||||
|
// or after March 2015.
|
||||||
|
//
|
||||||
|
// Note that the quantity will NEVER be internally represented by a
|
||||||
|
// floating point number. That is the whole point of this exercise.
|
||||||
|
//
|
||||||
|
// Non-canonical values will still parse as long as they are well formed,
|
||||||
|
// but will be re-emitted in their canonical form. (So always use canonical
|
||||||
|
// form, or don't diff.)
|
||||||
|
//
|
||||||
|
// This format is intended to make it difficult to use these numbers without
|
||||||
|
// writing some sort of special handling code in the hopes that that will
|
||||||
|
// cause implementors to also use a fixed point implementation.
|
||||||
|
//
|
||||||
|
// +protobuf=true
|
||||||
|
// +protobuf.embed=QuantityProto
|
||||||
|
// +protobuf.options.marshal=false
|
||||||
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
|
message Quantity {
|
||||||
|
optional QuantityProto QuantityProto = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// QuantityProto is a struct that is equivalent to Quantity, but intended for
|
||||||
|
// protobuf marshalling/unmarshalling. It is generated into a serialization
|
||||||
|
// that matches Quantity. Do not use in Go structs.
|
||||||
|
//
|
||||||
|
// +protobuf=true
|
||||||
|
message QuantityProto {
|
||||||
|
// The format of the quantity
|
||||||
|
optional string format = 1;
|
||||||
|
|
||||||
|
// The scale dimension of the value
|
||||||
|
optional int32 scale = 2;
|
||||||
|
|
||||||
|
// Bigint is serialized as a raw bytes array
|
||||||
|
optional bytes bigint = 3;
|
||||||
|
}
|
||||||
|
|
@@ -29,11 +29,11 @@ import (
|
|||||||
// +protobuf=true
|
// +protobuf=true
|
||||||
type QuantityProto struct {
|
type QuantityProto struct {
|
||||||
// The format of the quantity
|
// The format of the quantity
|
||||||
Format Format
|
Format Format `protobuf:"bytes,1,opt,name=format,casttype=Format"`
|
||||||
// The scale dimension of the value
|
// The scale dimension of the value
|
||||||
Scale int32
|
Scale int32 `protobuf:"varint,2,opt,name=scale"`
|
||||||
// Bigint is serialized as a raw bytes array
|
// Bigint is serialized as a raw bytes array
|
||||||
Bigint []byte
|
Bigint []byte `protobuf:"bytes,3,opt,name=bigint"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ProtoTime returns the Time as a new ProtoTime value.
|
// ProtoTime returns the Time as a new ProtoTime value.
|
||||||
|
@@ -25,7 +25,7 @@ import (
|
|||||||
// marshaling to YAML and JSON. In particular, it marshals into strings, which
|
// marshaling to YAML and JSON. In particular, it marshals into strings, which
|
||||||
// can be used as map keys in json.
|
// can be used as map keys in json.
|
||||||
type Duration struct {
|
type Duration struct {
|
||||||
time.Duration
|
time.Duration `protobuf:"varint,1,opt,name=duration,casttype=time.Duration"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// UnmarshalJSON implements the json.Unmarshaller interface.
|
// UnmarshalJSON implements the json.Unmarshaller interface.
|
||||||
|
4214
pkg/api/unversioned/generated.pb.go
Normal file
4214
pkg/api/unversioned/generated.pb.go
Normal file
File diff suppressed because it is too large
Load Diff
376
pkg/api/unversioned/generated.proto
Normal file
376
pkg/api/unversioned/generated.proto
Normal file
@@ -0,0 +1,376 @@
|
|||||||
|
/*
|
||||||
|
Copyright 2016 The Kubernetes Authors All rights reserved.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
// This file was autogenerated by go-to-protobuf. Do not edit it manually!
|
||||||
|
|
||||||
|
syntax = 'proto2';
|
||||||
|
|
||||||
|
package k8s.io.kubernetes.pkg.api.unversioned;
|
||||||
|
|
||||||
|
import "k8s.io/kubernetes/pkg/util/intstr/generated.proto";
|
||||||
|
|
||||||
|
// Package-wide variables from generator "generated".
|
||||||
|
option go_package = "unversioned";
|
||||||
|
|
||||||
|
// APIGroup contains the name, the supported versions, and the preferred version
|
||||||
|
// of a group.
|
||||||
|
message APIGroup {
|
||||||
|
// name is the name of the group.
|
||||||
|
optional string name = 1;
|
||||||
|
|
||||||
|
// versions are the versions supported in this group.
|
||||||
|
repeated GroupVersionForDiscovery versions = 2;
|
||||||
|
|
||||||
|
// preferredVersion is the version preferred by the API server, which
|
||||||
|
// probably is the storage version.
|
||||||
|
optional GroupVersionForDiscovery preferredVersion = 3;
|
||||||
|
|
||||||
|
// a map of client CIDR to server address that is serving this group.
|
||||||
|
// This is to help clients reach servers in the most network-efficient way possible.
|
||||||
|
// Clients can use the appropriate server address as per the CIDR that they match.
|
||||||
|
// In case of multiple matches, clients should use the longest matching CIDR.
|
||||||
|
// The server returns only those CIDRs that it thinks that the client can match.
|
||||||
|
// For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP.
|
||||||
|
// Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.
|
||||||
|
repeated ServerAddressByClientCIDR serverAddressByClientCIDRs = 4;
|
||||||
|
}
|
||||||
|
|
||||||
|
// APIGroupList is a list of APIGroup, to allow clients to discover the API at
|
||||||
|
// /apis.
|
||||||
|
message APIGroupList {
|
||||||
|
// groups is a list of APIGroup.
|
||||||
|
repeated APIGroup groups = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// APIResource specifies the name of a resource and whether it is namespaced.
|
||||||
|
message APIResource {
|
||||||
|
// name is the name of the resource.
|
||||||
|
optional string name = 1;
|
||||||
|
|
||||||
|
// namespaced indicates if a resource is namespaced or not.
|
||||||
|
optional bool namespaced = 2;
|
||||||
|
|
||||||
|
// kind is the kind for the resource (e.g. 'Foo' is the kind for a resource 'foo')
|
||||||
|
optional string kind = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// APIResourceList is a list of APIResource, it is used to expose the name of the
|
||||||
|
// resources supported in a specific group and version, and if the resource
|
||||||
|
// is namespaced.
|
||||||
|
message APIResourceList {
|
||||||
|
// groupVersion is the group and version this APIResourceList is for.
|
||||||
|
optional string groupVersion = 1;
|
||||||
|
|
||||||
|
// resources contains the name of the resources and if they are namespaced.
|
||||||
|
repeated APIResource resources = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// APIVersions lists the versions that are available, to allow clients to
|
||||||
|
// discover the API at /api, which is the root path of the legacy v1 API.
|
||||||
|
//
|
||||||
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
|
message APIVersions {
|
||||||
|
// versions are the api versions that are available.
|
||||||
|
repeated string versions = 1;
|
||||||
|
|
||||||
|
// a map of client CIDR to server address that is serving this group.
|
||||||
|
// This is to help clients reach servers in the most network-efficient way possible.
|
||||||
|
// Clients can use the appropriate server address as per the CIDR that they match.
|
||||||
|
// In case of multiple matches, clients should use the longest matching CIDR.
|
||||||
|
// The server returns only those CIDRs that it thinks that the client can match.
|
||||||
|
// For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP.
|
||||||
|
// Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.
|
||||||
|
repeated ServerAddressByClientCIDR serverAddressByClientCIDRs = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Duration is a wrapper around time.Duration which supports correct
|
||||||
|
// marshaling to YAML and JSON. In particular, it marshals into strings, which
|
||||||
|
// can be used as map keys in json.
|
||||||
|
message Duration {
|
||||||
|
optional int64 duration = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ExportOptions is the query options to the standard REST get call.
|
||||||
|
message ExportOptions {
|
||||||
|
// Should this value be exported. Export strips fields that a user can not specify.`
|
||||||
|
optional bool export = 1;
|
||||||
|
|
||||||
|
// Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'
|
||||||
|
optional bool exact = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// GroupKind specifies a Group and a Kind, but does not force a version. This is useful for identifying
|
||||||
|
// concepts during lookup stages without having partially valid types
|
||||||
|
//
|
||||||
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
|
message GroupKind {
|
||||||
|
optional string group = 1;
|
||||||
|
|
||||||
|
optional string kind = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// GroupResource specifies a Group and a Resource, but does not force a version. This is useful for identifying
|
||||||
|
// concepts during lookup stages without having partially valid types
|
||||||
|
//
|
||||||
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
|
message GroupResource {
|
||||||
|
optional string group = 1;
|
||||||
|
|
||||||
|
optional string resource = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// GroupVersion contains the "group" and the "version", which uniquely identifies the API.
|
||||||
|
//
|
||||||
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
|
message GroupVersion {
|
||||||
|
optional string group = 1;
|
||||||
|
|
||||||
|
optional string version = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// GroupVersion contains the "group/version" and "version" string of a version.
|
||||||
|
// It is made a struct to keep extensiblity.
|
||||||
|
message GroupVersionForDiscovery {
|
||||||
|
// groupVersion specifies the API group and version in the form "group/version"
|
||||||
|
optional string groupVersion = 1;
|
||||||
|
|
||||||
|
// version specifies the version in the form of "version". This is to save
|
||||||
|
// the clients the trouble of splitting the GroupVersion.
|
||||||
|
optional string version = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// GroupVersionKind unambiguously identifies a kind. It doesn't anonymously include GroupVersion
|
||||||
|
// to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling
|
||||||
|
//
|
||||||
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
|
message GroupVersionKind {
|
||||||
|
optional string group = 1;
|
||||||
|
|
||||||
|
optional string version = 2;
|
||||||
|
|
||||||
|
optional string kind = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// GroupVersionResource unambiguously identifies a resource. It doesn't anonymously include GroupVersion
|
||||||
|
// to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling
|
||||||
|
//
|
||||||
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
|
message GroupVersionResource {
|
||||||
|
optional string group = 1;
|
||||||
|
|
||||||
|
optional string version = 2;
|
||||||
|
|
||||||
|
optional string resource = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// A label selector is a label query over a set of resources. The result of matchLabels and
|
||||||
|
// matchExpressions are ANDed. An empty label selector matches all objects. A null
|
||||||
|
// label selector matches no objects.
|
||||||
|
message LabelSelector {
|
||||||
|
// matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
|
||||||
|
// map is equivalent to an element of matchExpressions, whose key field is "key", the
|
||||||
|
// operator is "In", and the values array contains only "value". The requirements are ANDed.
|
||||||
|
map<string, string> matchLabels = 1;
|
||||||
|
|
||||||
|
// matchExpressions is a list of label selector requirements. The requirements are ANDed.
|
||||||
|
repeated LabelSelectorRequirement matchExpressions = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// A label selector requirement is a selector that contains values, a key, and an operator that
|
||||||
|
// relates the key and values.
|
||||||
|
message LabelSelectorRequirement {
|
||||||
|
// key is the label key that the selector applies to.
|
||||||
|
optional string key = 1;
|
||||||
|
|
||||||
|
// operator represents a key's relationship to a set of values.
|
||||||
|
// Valid operators ard In, NotIn, Exists and DoesNotExist.
|
||||||
|
optional string operator = 2;
|
||||||
|
|
||||||
|
// values is an array of string values. If the operator is In or NotIn,
|
||||||
|
// the values array must be non-empty. If the operator is Exists or DoesNotExist,
|
||||||
|
// the values array must be empty. This array is replaced during a strategic
|
||||||
|
// merge patch.
|
||||||
|
repeated string values = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ListMeta describes metadata that synthetic resources must have, including lists and
|
||||||
|
// various status objects. A resource may have only one of {ObjectMeta, ListMeta}.
|
||||||
|
message ListMeta {
|
||||||
|
// SelfLink is a URL representing this object.
|
||||||
|
// Populated by the system.
|
||||||
|
// Read-only.
|
||||||
|
optional string selfLink = 1;
|
||||||
|
|
||||||
|
// String that identifies the server's internal version of this object that
|
||||||
|
// can be used by clients to determine when objects have changed.
|
||||||
|
// Value must be treated as opaque by clients and passed unmodified back to the server.
|
||||||
|
// Populated by the system.
|
||||||
|
// Read-only.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency
|
||||||
|
optional string resourceVersion = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// RootPaths lists the paths available at root.
|
||||||
|
// For example: "/healthz", "/apis".
|
||||||
|
message RootPaths {
|
||||||
|
// paths are the paths available at root.
|
||||||
|
repeated string paths = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ServerAddressByClientCIDR helps the client to determine the server address that they should use, depending on the clientCIDR that they match.
|
||||||
|
message ServerAddressByClientCIDR {
|
||||||
|
// The CIDR with which clients can match their IP to figure out the server address that they should use.
|
||||||
|
optional string clientCIDR = 1;
|
||||||
|
|
||||||
|
// Address of this server, suitable for a client that matches the above CIDR.
|
||||||
|
// This can be a hostname, hostname:port, IP or IP:port.
|
||||||
|
optional string serverAddress = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Status is a return value for calls that don't return other objects.
|
||||||
|
message Status {
|
||||||
|
// Standard list metadata.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
|
||||||
|
optional ListMeta metadata = 1;
|
||||||
|
|
||||||
|
// Status of the operation.
|
||||||
|
// One of: "Success" or "Failure".
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
|
optional string status = 2;
|
||||||
|
|
||||||
|
// A human-readable description of the status of this operation.
|
||||||
|
optional string message = 3;
|
||||||
|
|
||||||
|
// A machine-readable description of why this operation is in the
|
||||||
|
// "Failure" status. If this value is empty there
|
||||||
|
// is no information available. A Reason clarifies an HTTP status
|
||||||
|
// code but does not override it.
|
||||||
|
optional string reason = 4;
|
||||||
|
|
||||||
|
// Extended data associated with the reason. Each reason may define its
|
||||||
|
// own extended details. This field is optional and the data returned
|
||||||
|
// is not guaranteed to conform to any schema except that defined by
|
||||||
|
// the reason type.
|
||||||
|
optional StatusDetails details = 5;
|
||||||
|
|
||||||
|
// Suggested HTTP return code for this status, 0 if not set.
|
||||||
|
optional int32 code = 6;
|
||||||
|
}
|
||||||
|
|
||||||
|
// StatusCause provides more information about an api.Status failure, including
|
||||||
|
// cases when multiple errors are encountered.
|
||||||
|
message StatusCause {
|
||||||
|
// A machine-readable description of the cause of the error. If this value is
|
||||||
|
// empty there is no information available.
|
||||||
|
optional string reason = 1;
|
||||||
|
|
||||||
|
// A human-readable description of the cause of the error. This field may be
|
||||||
|
// presented as-is to a reader.
|
||||||
|
optional string message = 2;
|
||||||
|
|
||||||
|
// The field of the resource that has caused this error, as named by its JSON
|
||||||
|
// serialization. May include dot and postfix notation for nested attributes.
|
||||||
|
// Arrays are zero-indexed. Fields may appear more than once in an array of
|
||||||
|
// causes due to fields having multiple errors.
|
||||||
|
// Optional.
|
||||||
|
//
|
||||||
|
// Examples:
|
||||||
|
// "name" - the field "name" on the current resource
|
||||||
|
// "items[0].name" - the field "name" on the first array entry in "items"
|
||||||
|
optional string field = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// StatusDetails is a set of additional properties that MAY be set by the
|
||||||
|
// server to provide additional information about a response. The Reason
|
||||||
|
// field of a Status object defines what attributes will be set. Clients
|
||||||
|
// must ignore fields that do not match the defined type of each attribute,
|
||||||
|
// and should assume that any attribute may be empty, invalid, or under
|
||||||
|
// defined.
|
||||||
|
message StatusDetails {
|
||||||
|
// The name attribute of the resource associated with the status StatusReason
|
||||||
|
// (when there is a single name which can be described).
|
||||||
|
optional string name = 1;
|
||||||
|
|
||||||
|
// The group attribute of the resource associated with the status StatusReason.
|
||||||
|
optional string group = 2;
|
||||||
|
|
||||||
|
// The kind attribute of the resource associated with the status StatusReason.
|
||||||
|
// On some operations may differ from the requested resource Kind.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
|
||||||
|
optional string kind = 3;
|
||||||
|
|
||||||
|
// The Causes array includes more details associated with the StatusReason
|
||||||
|
// failure. Not all StatusReasons may provide detailed causes.
|
||||||
|
repeated StatusCause causes = 4;
|
||||||
|
|
||||||
|
// If specified, the time in seconds before the operation should be retried.
|
||||||
|
optional int32 retryAfterSeconds = 5;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Time is a wrapper around time.Time which supports correct
|
||||||
|
// marshaling to YAML and JSON. Wrappers are provided for many
|
||||||
|
// of the factory methods that the time package offers.
|
||||||
|
//
|
||||||
|
// +protobuf.options.marshal=false
|
||||||
|
// +protobuf.as=Timestamp
|
||||||
|
message Time {
|
||||||
|
// Represents seconds of UTC time since Unix epoch
|
||||||
|
// 1970-01-01T00:00:00Z. Must be from from 0001-01-01T00:00:00Z to
|
||||||
|
// 9999-12-31T23:59:59Z inclusive.
|
||||||
|
optional int64 seconds = 1;
|
||||||
|
|
||||||
|
// Non-negative fractions of a second at nanosecond resolution. Negative
|
||||||
|
// second values with fractions must still have non-negative nanos values
|
||||||
|
// that count forward in time. Must be from 0 to 999,999,999
|
||||||
|
// inclusive. This field may be limited in precision depending on context.
|
||||||
|
optional int32 nanos = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Timestamp is a struct that is equivalent to Time, but intended for
|
||||||
|
// protobuf marshalling/unmarshalling. It is generated into a serialization
|
||||||
|
// that matches Time. Do not use in Go structs.
|
||||||
|
message Timestamp {
|
||||||
|
// Represents seconds of UTC time since Unix epoch
|
||||||
|
// 1970-01-01T00:00:00Z. Must be from from 0001-01-01T00:00:00Z to
|
||||||
|
// 9999-12-31T23:59:59Z inclusive.
|
||||||
|
optional int64 seconds = 1;
|
||||||
|
|
||||||
|
// Non-negative fractions of a second at nanosecond resolution. Negative
|
||||||
|
// second values with fractions must still have non-negative nanos values
|
||||||
|
// that count forward in time. Must be from 0 to 999,999,999
|
||||||
|
// inclusive. This field may be limited in precision depending on context.
|
||||||
|
optional int32 nanos = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// TypeMeta describes an individual object in an API response or request
|
||||||
|
// with strings representing the type of the object and its API schema version.
|
||||||
|
// Structures that are versioned or persisted should inline TypeMeta.
|
||||||
|
message TypeMeta {
|
||||||
|
// Kind is a string value representing the REST resource this object represents.
|
||||||
|
// Servers may infer this from the endpoint the client submits requests to.
|
||||||
|
// Cannot be updated.
|
||||||
|
// In CamelCase.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
|
||||||
|
optional string kind = 1;
|
||||||
|
|
||||||
|
// APIVersion defines the versioned schema of this representation of an object.
|
||||||
|
// Servers should convert recognized schemas to the latest internal value, and
|
||||||
|
// may reject unrecognized values.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources
|
||||||
|
optional string apiVersion = 2;
|
||||||
|
}
|
||||||
|
|
@@ -42,8 +42,8 @@ func ParseResourceArg(arg string) (*GroupVersionResource, GroupResource) {
|
|||||||
//
|
//
|
||||||
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
type GroupResource struct {
|
type GroupResource struct {
|
||||||
Group string
|
Group string `protobuf:"bytes,1,opt,name=group"`
|
||||||
Resource string
|
Resource string `protobuf:"bytes,2,opt,name=resource"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (gr GroupResource) WithVersion(version string) GroupVersionResource {
|
func (gr GroupResource) WithVersion(version string) GroupVersionResource {
|
||||||
@@ -77,9 +77,9 @@ func ParseGroupResource(gr string) GroupResource {
|
|||||||
//
|
//
|
||||||
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
type GroupVersionResource struct {
|
type GroupVersionResource struct {
|
||||||
Group string
|
Group string `protobuf:"bytes,1,opt,name=group"`
|
||||||
Version string
|
Version string `protobuf:"bytes,2,opt,name=version"`
|
||||||
Resource string
|
Resource string `protobuf:"bytes,3,opt,name=resource"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (gvr GroupVersionResource) IsEmpty() bool {
|
func (gvr GroupVersionResource) IsEmpty() bool {
|
||||||
@@ -103,8 +103,8 @@ func (gvr *GroupVersionResource) String() string {
|
|||||||
//
|
//
|
||||||
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
type GroupKind struct {
|
type GroupKind struct {
|
||||||
Group string
|
Group string `protobuf:"bytes,1,opt,name=group"`
|
||||||
Kind string
|
Kind string `protobuf:"bytes,2,opt,name=kind"`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (gk GroupKind) IsEmpty() bool {
|
func (gk GroupKind) IsEmpty() bool {
|
||||||
@@ -127,9 +127,9 @@ func (gk *GroupKind) String() string {
|
|||||||
//
|
//
|
||||||
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
type GroupVersionKind struct {
|
type GroupVersionKind struct {
|
||||||
Group string
|
Group string `protobuf:"bytes,1,opt,name=group"`
|
||||||
Version string
|
Version string `protobuf:"bytes,2,opt,name=version"`
|
||||||
Kind string
|
Kind string `protobuf:"bytes,3,opt,name=kind"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// IsEmpty returns true if group, version, and kind are empty
|
// IsEmpty returns true if group, version, and kind are empty
|
||||||
@@ -153,8 +153,8 @@ func (gvk GroupVersionKind) String() string {
|
|||||||
//
|
//
|
||||||
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
type GroupVersion struct {
|
type GroupVersion struct {
|
||||||
Group string
|
Group string `protobuf:"bytes,1,opt,name=group"`
|
||||||
Version string
|
Version string `protobuf:"bytes,2,opt,name=version"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// IsEmpty returns true if group and version are empty
|
// IsEmpty returns true if group and version are empty
|
||||||
|
@@ -27,12 +27,12 @@ type Timestamp struct {
|
|||||||
// Represents seconds of UTC time since Unix epoch
|
// Represents seconds of UTC time since Unix epoch
|
||||||
// 1970-01-01T00:00:00Z. Must be from from 0001-01-01T00:00:00Z to
|
// 1970-01-01T00:00:00Z. Must be from from 0001-01-01T00:00:00Z to
|
||||||
// 9999-12-31T23:59:59Z inclusive.
|
// 9999-12-31T23:59:59Z inclusive.
|
||||||
Seconds int64 `json:"seconds"`
|
Seconds int64 `json:"seconds" protobuf:"varint,1,opt,name=seconds"`
|
||||||
// Non-negative fractions of a second at nanosecond resolution. Negative
|
// Non-negative fractions of a second at nanosecond resolution. Negative
|
||||||
// second values with fractions must still have non-negative nanos values
|
// second values with fractions must still have non-negative nanos values
|
||||||
// that count forward in time. Must be from 0 to 999,999,999
|
// that count forward in time. Must be from 0 to 999,999,999
|
||||||
// inclusive. This field may be limited in precision depending on context.
|
// inclusive. This field may be limited in precision depending on context.
|
||||||
Nanos int32 `json:"nanos"`
|
Nanos int32 `json:"nanos" protobuf:"varint,2,opt,name=nanos"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Timestamp returns the Time as a new Timestamp value.
|
// Timestamp returns the Time as a new Timestamp value.
|
||||||
|
@@ -36,13 +36,13 @@ type TypeMeta struct {
|
|||||||
// Cannot be updated.
|
// Cannot be updated.
|
||||||
// In CamelCase.
|
// In CamelCase.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
|
||||||
Kind string `json:"kind,omitempty"`
|
Kind string `json:"kind,omitempty" protobuf:"bytes,1,opt,name=kind"`
|
||||||
|
|
||||||
// APIVersion defines the versioned schema of this representation of an object.
|
// APIVersion defines the versioned schema of this representation of an object.
|
||||||
// Servers should convert recognized schemas to the latest internal value, and
|
// Servers should convert recognized schemas to the latest internal value, and
|
||||||
// may reject unrecognized values.
|
// may reject unrecognized values.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources
|
||||||
APIVersion string `json:"apiVersion,omitempty"`
|
APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,2,opt,name=apiVersion"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ListMeta describes metadata that synthetic resources must have, including lists and
|
// ListMeta describes metadata that synthetic resources must have, including lists and
|
||||||
@@ -51,7 +51,7 @@ type ListMeta struct {
|
|||||||
// SelfLink is a URL representing this object.
|
// SelfLink is a URL representing this object.
|
||||||
// Populated by the system.
|
// Populated by the system.
|
||||||
// Read-only.
|
// Read-only.
|
||||||
SelfLink string `json:"selfLink,omitempty"`
|
SelfLink string `json:"selfLink,omitempty" protobuf:"bytes,1,opt,name=selfLink"`
|
||||||
|
|
||||||
// String that identifies the server's internal version of this object that
|
// String that identifies the server's internal version of this object that
|
||||||
// can be used by clients to determine when objects have changed.
|
// can be used by clients to determine when objects have changed.
|
||||||
@@ -59,16 +59,16 @@ type ListMeta struct {
|
|||||||
// Populated by the system.
|
// Populated by the system.
|
||||||
// Read-only.
|
// Read-only.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency
|
||||||
ResourceVersion string `json:"resourceVersion,omitempty"`
|
ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,2,opt,name=resourceVersion"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ExportOptions is the query options to the standard REST get call.
|
// ExportOptions is the query options to the standard REST get call.
|
||||||
type ExportOptions struct {
|
type ExportOptions struct {
|
||||||
TypeMeta `json:",inline"`
|
TypeMeta `json:",inline"`
|
||||||
// Should this value be exported. Export strips fields that a user can not specify.`
|
// Should this value be exported. Export strips fields that a user can not specify.`
|
||||||
Export bool `json:"export"`
|
Export bool `json:"export" protobuf:"varint,1,opt,name=export"`
|
||||||
// Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'
|
// Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'
|
||||||
Exact bool `json:"exact"`
|
Exact bool `json:"exact" protobuf:"varint,2,opt,name=exact"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Status is a return value for calls that don't return other objects.
|
// Status is a return value for calls that don't return other objects.
|
||||||
@@ -76,26 +76,26 @@ type Status struct {
|
|||||||
TypeMeta `json:",inline"`
|
TypeMeta `json:",inline"`
|
||||||
// Standard list metadata.
|
// Standard list metadata.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
|
||||||
ListMeta `json:"metadata,omitempty"`
|
ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Status of the operation.
|
// Status of the operation.
|
||||||
// One of: "Success" or "Failure".
|
// One of: "Success" or "Failure".
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
Status string `json:"status,omitempty"`
|
Status string `json:"status,omitempty" protobuf:"bytes,2,opt,name=status"`
|
||||||
// A human-readable description of the status of this operation.
|
// A human-readable description of the status of this operation.
|
||||||
Message string `json:"message,omitempty"`
|
Message string `json:"message,omitempty" protobuf:"bytes,3,opt,name=message"`
|
||||||
// A machine-readable description of why this operation is in the
|
// A machine-readable description of why this operation is in the
|
||||||
// "Failure" status. If this value is empty there
|
// "Failure" status. If this value is empty there
|
||||||
// is no information available. A Reason clarifies an HTTP status
|
// is no information available. A Reason clarifies an HTTP status
|
||||||
// code but does not override it.
|
// code but does not override it.
|
||||||
Reason StatusReason `json:"reason,omitempty"`
|
Reason StatusReason `json:"reason,omitempty" protobuf:"bytes,4,opt,name=reason,casttype=StatusReason"`
|
||||||
// Extended data associated with the reason. Each reason may define its
|
// Extended data associated with the reason. Each reason may define its
|
||||||
// own extended details. This field is optional and the data returned
|
// own extended details. This field is optional and the data returned
|
||||||
// is not guaranteed to conform to any schema except that defined by
|
// is not guaranteed to conform to any schema except that defined by
|
||||||
// the reason type.
|
// the reason type.
|
||||||
Details *StatusDetails `json:"details,omitempty"`
|
Details *StatusDetails `json:"details,omitempty" protobuf:"bytes,5,opt,name=details"`
|
||||||
// Suggested HTTP return code for this status, 0 if not set.
|
// Suggested HTTP return code for this status, 0 if not set.
|
||||||
Code int32 `json:"code,omitempty"`
|
Code int32 `json:"code,omitempty" protobuf:"varint,6,opt,name=code"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// StatusDetails is a set of additional properties that MAY be set by the
|
// StatusDetails is a set of additional properties that MAY be set by the
|
||||||
@@ -107,18 +107,18 @@ type Status struct {
|
|||||||
type StatusDetails struct {
|
type StatusDetails struct {
|
||||||
// The name attribute of the resource associated with the status StatusReason
|
// The name attribute of the resource associated with the status StatusReason
|
||||||
// (when there is a single name which can be described).
|
// (when there is a single name which can be described).
|
||||||
Name string `json:"name,omitempty"`
|
Name string `json:"name,omitempty" protobuf:"bytes,1,opt,name=name"`
|
||||||
// The group attribute of the resource associated with the status StatusReason.
|
// The group attribute of the resource associated with the status StatusReason.
|
||||||
Group string `json:"group,omitempty"`
|
Group string `json:"group,omitempty" protobuf:"bytes,2,opt,name=group"`
|
||||||
// The kind attribute of the resource associated with the status StatusReason.
|
// The kind attribute of the resource associated with the status StatusReason.
|
||||||
// On some operations may differ from the requested resource Kind.
|
// On some operations may differ from the requested resource Kind.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
|
||||||
Kind string `json:"kind,omitempty"`
|
Kind string `json:"kind,omitempty" protobuf:"bytes,3,opt,name=kind"`
|
||||||
// The Causes array includes more details associated with the StatusReason
|
// The Causes array includes more details associated with the StatusReason
|
||||||
// failure. Not all StatusReasons may provide detailed causes.
|
// failure. Not all StatusReasons may provide detailed causes.
|
||||||
Causes []StatusCause `json:"causes,omitempty"`
|
Causes []StatusCause `json:"causes,omitempty" protobuf:"bytes,4,rep,name=causes"`
|
||||||
// If specified, the time in seconds before the operation should be retried.
|
// If specified, the time in seconds before the operation should be retried.
|
||||||
RetryAfterSeconds int32 `json:"retryAfterSeconds,omitempty"`
|
RetryAfterSeconds int32 `json:"retryAfterSeconds,omitempty" protobuf:"varint,5,opt,name=retryAfterSeconds"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Values of Status.Status
|
// Values of Status.Status
|
||||||
@@ -257,10 +257,10 @@ const (
|
|||||||
type StatusCause struct {
|
type StatusCause struct {
|
||||||
// A machine-readable description of the cause of the error. If this value is
|
// A machine-readable description of the cause of the error. If this value is
|
||||||
// empty there is no information available.
|
// empty there is no information available.
|
||||||
Type CauseType `json:"reason,omitempty"`
|
Type CauseType `json:"reason,omitempty" protobuf:"bytes,1,opt,name=reason,casttype=CauseType"`
|
||||||
// A human-readable description of the cause of the error. This field may be
|
// A human-readable description of the cause of the error. This field may be
|
||||||
// presented as-is to a reader.
|
// presented as-is to a reader.
|
||||||
Message string `json:"message,omitempty"`
|
Message string `json:"message,omitempty" protobuf:"bytes,2,opt,name=message"`
|
||||||
// The field of the resource that has caused this error, as named by its JSON
|
// The field of the resource that has caused this error, as named by its JSON
|
||||||
// serialization. May include dot and postfix notation for nested attributes.
|
// serialization. May include dot and postfix notation for nested attributes.
|
||||||
// Arrays are zero-indexed. Fields may appear more than once in an array of
|
// Arrays are zero-indexed. Fields may appear more than once in an array of
|
||||||
@@ -270,7 +270,7 @@ type StatusCause struct {
|
|||||||
// Examples:
|
// Examples:
|
||||||
// "name" - the field "name" on the current resource
|
// "name" - the field "name" on the current resource
|
||||||
// "items[0].name" - the field "name" on the first array entry in "items"
|
// "items[0].name" - the field "name" on the first array entry in "items"
|
||||||
Field string `json:"field,omitempty"`
|
Field string `json:"field,omitempty" protobuf:"bytes,3,opt,name=field"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// CauseType is a machine readable value providing more detail about what
|
// CauseType is a machine readable value providing more detail about what
|
||||||
@@ -307,7 +307,7 @@ const (
|
|||||||
type APIVersions struct {
|
type APIVersions struct {
|
||||||
TypeMeta `json:",inline"`
|
TypeMeta `json:",inline"`
|
||||||
// versions are the api versions that are available.
|
// versions are the api versions that are available.
|
||||||
Versions []string `json:"versions"`
|
Versions []string `json:"versions" protobuf:"bytes,1,rep,name=versions"`
|
||||||
// a map of client CIDR to server address that is serving this group.
|
// a map of client CIDR to server address that is serving this group.
|
||||||
// This is to help clients reach servers in the most network-efficient way possible.
|
// This is to help clients reach servers in the most network-efficient way possible.
|
||||||
// Clients can use the appropriate server address as per the CIDR that they match.
|
// Clients can use the appropriate server address as per the CIDR that they match.
|
||||||
@@ -315,7 +315,7 @@ type APIVersions struct {
|
|||||||
// The server returns only those CIDRs that it thinks that the client can match.
|
// The server returns only those CIDRs that it thinks that the client can match.
|
||||||
// For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP.
|
// For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP.
|
||||||
// Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.
|
// Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.
|
||||||
ServerAddressByClientCIDRs []ServerAddressByClientCIDR `json:"serverAddressByClientCIDRs"`
|
ServerAddressByClientCIDRs []ServerAddressByClientCIDR `json:"serverAddressByClientCIDRs" protobuf:"bytes,2,rep,name=serverAddressByClientCIDRs"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// APIGroupList is a list of APIGroup, to allow clients to discover the API at
|
// APIGroupList is a list of APIGroup, to allow clients to discover the API at
|
||||||
@@ -323,7 +323,7 @@ type APIVersions struct {
|
|||||||
type APIGroupList struct {
|
type APIGroupList struct {
|
||||||
TypeMeta `json:",inline"`
|
TypeMeta `json:",inline"`
|
||||||
// groups is a list of APIGroup.
|
// groups is a list of APIGroup.
|
||||||
Groups []APIGroup `json:"groups"`
|
Groups []APIGroup `json:"groups" protobuf:"bytes,1,rep,name=groups"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// APIGroup contains the name, the supported versions, and the preferred version
|
// APIGroup contains the name, the supported versions, and the preferred version
|
||||||
@@ -331,12 +331,12 @@ type APIGroupList struct {
|
|||||||
type APIGroup struct {
|
type APIGroup struct {
|
||||||
TypeMeta `json:",inline"`
|
TypeMeta `json:",inline"`
|
||||||
// name is the name of the group.
|
// name is the name of the group.
|
||||||
Name string `json:"name"`
|
Name string `json:"name" protobuf:"bytes,1,opt,name=name"`
|
||||||
// versions are the versions supported in this group.
|
// versions are the versions supported in this group.
|
||||||
Versions []GroupVersionForDiscovery `json:"versions"`
|
Versions []GroupVersionForDiscovery `json:"versions" protobuf:"bytes,2,rep,name=versions"`
|
||||||
// preferredVersion is the version preferred by the API server, which
|
// preferredVersion is the version preferred by the API server, which
|
||||||
// probably is the storage version.
|
// probably is the storage version.
|
||||||
PreferredVersion GroupVersionForDiscovery `json:"preferredVersion,omitempty"`
|
PreferredVersion GroupVersionForDiscovery `json:"preferredVersion,omitempty" protobuf:"bytes,3,opt,name=preferredVersion"`
|
||||||
// a map of client CIDR to server address that is serving this group.
|
// a map of client CIDR to server address that is serving this group.
|
||||||
// This is to help clients reach servers in the most network-efficient way possible.
|
// This is to help clients reach servers in the most network-efficient way possible.
|
||||||
// Clients can use the appropriate server address as per the CIDR that they match.
|
// Clients can use the appropriate server address as per the CIDR that they match.
|
||||||
@@ -344,36 +344,36 @@ type APIGroup struct {
|
|||||||
// The server returns only those CIDRs that it thinks that the client can match.
|
// The server returns only those CIDRs that it thinks that the client can match.
|
||||||
// For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP.
|
// For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP.
|
||||||
// Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.
|
// Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.
|
||||||
ServerAddressByClientCIDRs []ServerAddressByClientCIDR `json:"serverAddressByClientCIDRs"`
|
ServerAddressByClientCIDRs []ServerAddressByClientCIDR `json:"serverAddressByClientCIDRs" protobuf:"bytes,4,rep,name=serverAddressByClientCIDRs"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ServerAddressByClientCIDR helps the client to determine the server address that they should use, depending on the clientCIDR that they match.
|
// ServerAddressByClientCIDR helps the client to determine the server address that they should use, depending on the clientCIDR that they match.
|
||||||
type ServerAddressByClientCIDR struct {
|
type ServerAddressByClientCIDR struct {
|
||||||
// The CIDR with which clients can match their IP to figure out the server address that they should use.
|
// The CIDR with which clients can match their IP to figure out the server address that they should use.
|
||||||
ClientCIDR string `json:"clientCIDR"`
|
ClientCIDR string `json:"clientCIDR" protobuf:"bytes,1,opt,name=clientCIDR"`
|
||||||
// Address of this server, suitable for a client that matches the above CIDR.
|
// Address of this server, suitable for a client that matches the above CIDR.
|
||||||
// This can be a hostname, hostname:port, IP or IP:port.
|
// This can be a hostname, hostname:port, IP or IP:port.
|
||||||
ServerAddress string `json:"serverAddress"`
|
ServerAddress string `json:"serverAddress" protobuf:"bytes,2,opt,name=serverAddress"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// GroupVersion contains the "group/version" and "version" string of a version.
|
// GroupVersion contains the "group/version" and "version" string of a version.
|
||||||
// It is made a struct to keep extensiblity.
|
// It is made a struct to keep extensiblity.
|
||||||
type GroupVersionForDiscovery struct {
|
type GroupVersionForDiscovery struct {
|
||||||
// groupVersion specifies the API group and version in the form "group/version"
|
// groupVersion specifies the API group and version in the form "group/version"
|
||||||
GroupVersion string `json:"groupVersion"`
|
GroupVersion string `json:"groupVersion" protobuf:"bytes,1,opt,name=groupVersion"`
|
||||||
// version specifies the version in the form of "version". This is to save
|
// version specifies the version in the form of "version". This is to save
|
||||||
// the clients the trouble of splitting the GroupVersion.
|
// the clients the trouble of splitting the GroupVersion.
|
||||||
Version string `json:"version"`
|
Version string `json:"version" protobuf:"bytes,2,opt,name=version"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// APIResource specifies the name of a resource and whether it is namespaced.
|
// APIResource specifies the name of a resource and whether it is namespaced.
|
||||||
type APIResource struct {
|
type APIResource struct {
|
||||||
// name is the name of the resource.
|
// name is the name of the resource.
|
||||||
Name string `json:"name"`
|
Name string `json:"name" protobuf:"bytes,1,opt,name=name"`
|
||||||
// namespaced indicates if a resource is namespaced or not.
|
// namespaced indicates if a resource is namespaced or not.
|
||||||
Namespaced bool `json:"namespaced"`
|
Namespaced bool `json:"namespaced" protobuf:"varint,2,opt,name=namespaced"`
|
||||||
// kind is the kind for the resource (e.g. 'Foo' is the kind for a resource 'foo')
|
// kind is the kind for the resource (e.g. 'Foo' is the kind for a resource 'foo')
|
||||||
Kind string `json:"kind"`
|
Kind string `json:"kind" protobuf:"bytes,3,opt,name=kind"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// APIResourceList is a list of APIResource, it is used to expose the name of the
|
// APIResourceList is a list of APIResource, it is used to expose the name of the
|
||||||
@@ -382,16 +382,16 @@ type APIResource struct {
|
|||||||
type APIResourceList struct {
|
type APIResourceList struct {
|
||||||
TypeMeta `json:",inline"`
|
TypeMeta `json:",inline"`
|
||||||
// groupVersion is the group and version this APIResourceList is for.
|
// groupVersion is the group and version this APIResourceList is for.
|
||||||
GroupVersion string `json:"groupVersion"`
|
GroupVersion string `json:"groupVersion" protobuf:"bytes,1,opt,name=groupVersion"`
|
||||||
// resources contains the name of the resources and if they are namespaced.
|
// resources contains the name of the resources and if they are namespaced.
|
||||||
APIResources []APIResource `json:"resources"`
|
APIResources []APIResource `json:"resources" protobuf:"bytes,2,rep,name=resources"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// RootPaths lists the paths available at root.
|
// RootPaths lists the paths available at root.
|
||||||
// For example: "/healthz", "/apis".
|
// For example: "/healthz", "/apis".
|
||||||
type RootPaths struct {
|
type RootPaths struct {
|
||||||
// paths are the paths available at root.
|
// paths are the paths available at root.
|
||||||
Paths []string `json:"paths"`
|
Paths []string `json:"paths" protobuf:"bytes,1,rep,name=paths"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: remove me when watch is refactored
|
// TODO: remove me when watch is refactored
|
||||||
@@ -429,24 +429,24 @@ type LabelSelector struct {
|
|||||||
// matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
|
// matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
|
||||||
// map is equivalent to an element of matchExpressions, whose key field is "key", the
|
// map is equivalent to an element of matchExpressions, whose key field is "key", the
|
||||||
// operator is "In", and the values array contains only "value". The requirements are ANDed.
|
// operator is "In", and the values array contains only "value". The requirements are ANDed.
|
||||||
MatchLabels map[string]string `json:"matchLabels,omitempty"`
|
MatchLabels map[string]string `json:"matchLabels,omitempty" protobuf:"bytes,1,rep,name=matchLabels"`
|
||||||
// matchExpressions is a list of label selector requirements. The requirements are ANDed.
|
// matchExpressions is a list of label selector requirements. The requirements are ANDed.
|
||||||
MatchExpressions []LabelSelectorRequirement `json:"matchExpressions,omitempty"`
|
MatchExpressions []LabelSelectorRequirement `json:"matchExpressions,omitempty" protobuf:"bytes,2,rep,name=matchExpressions"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// A label selector requirement is a selector that contains values, a key, and an operator that
|
// A label selector requirement is a selector that contains values, a key, and an operator that
|
||||||
// relates the key and values.
|
// relates the key and values.
|
||||||
type LabelSelectorRequirement struct {
|
type LabelSelectorRequirement struct {
|
||||||
// key is the label key that the selector applies to.
|
// key is the label key that the selector applies to.
|
||||||
Key string `json:"key" patchStrategy:"merge" patchMergeKey:"key"`
|
Key string `json:"key" patchStrategy:"merge" patchMergeKey:"key" protobuf:"bytes,1,opt,name=key"`
|
||||||
// operator represents a key's relationship to a set of values.
|
// operator represents a key's relationship to a set of values.
|
||||||
// Valid operators ard In, NotIn, Exists and DoesNotExist.
|
// Valid operators ard In, NotIn, Exists and DoesNotExist.
|
||||||
Operator LabelSelectorOperator `json:"operator"`
|
Operator LabelSelectorOperator `json:"operator" protobuf:"bytes,2,opt,name=operator,casttype=LabelSelectorOperator"`
|
||||||
// values is an array of string values. If the operator is In or NotIn,
|
// values is an array of string values. If the operator is In or NotIn,
|
||||||
// the values array must be non-empty. If the operator is Exists or DoesNotExist,
|
// the values array must be non-empty. If the operator is Exists or DoesNotExist,
|
||||||
// the values array must be empty. This array is replaced during a strategic
|
// the values array must be empty. This array is replaced during a strategic
|
||||||
// merge patch.
|
// merge patch.
|
||||||
Values []string `json:"values,omitempty"`
|
Values []string `json:"values,omitempty" protobuf:"bytes,3,rep,name=values"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// A label selector operator is the set of operators that can be used in a selector requirement.
|
// A label selector operator is the set of operators that can be used in a selector requirement.
|
||||||
|
31918
pkg/api/v1/generated.pb.go
Normal file
31918
pkg/api/v1/generated.pb.go
Normal file
File diff suppressed because it is too large
Load Diff
2651
pkg/api/v1/generated.proto
Normal file
2651
pkg/api/v1/generated.proto
Normal file
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
1615
pkg/apis/autoscaling/v1/generated.pb.go
Normal file
1615
pkg/apis/autoscaling/v1/generated.pb.go
Normal file
File diff suppressed because it is too large
Load Diff
131
pkg/apis/autoscaling/v1/generated.proto
Normal file
131
pkg/apis/autoscaling/v1/generated.proto
Normal file
@@ -0,0 +1,131 @@
|
|||||||
|
/*
|
||||||
|
Copyright 2016 The Kubernetes Authors All rights reserved.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
// This file was autogenerated by go-to-protobuf. Do not edit it manually!
|
||||||
|
|
||||||
|
syntax = 'proto2';
|
||||||
|
|
||||||
|
package k8s.io.kubernetes.pkg.apis.autoscaling.v1;
|
||||||
|
|
||||||
|
import "k8s.io/kubernetes/pkg/api/resource/generated.proto";
|
||||||
|
import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto";
|
||||||
|
import "k8s.io/kubernetes/pkg/api/v1/generated.proto";
|
||||||
|
import "k8s.io/kubernetes/pkg/util/intstr/generated.proto";
|
||||||
|
|
||||||
|
// Package-wide variables from generator "generated".
|
||||||
|
option go_package = "v1";
|
||||||
|
|
||||||
|
// CrossVersionObjectReference contains enough information to let you identify the referred resource.
|
||||||
|
message CrossVersionObjectReference {
|
||||||
|
// Kind of the referent; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds"
|
||||||
|
optional string kind = 1;
|
||||||
|
|
||||||
|
// Name of the referent; More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
|
||||||
|
optional string name = 2;
|
||||||
|
|
||||||
|
// API version of the referent
|
||||||
|
optional string apiVersion = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// configuration of a horizontal pod autoscaler.
|
||||||
|
message HorizontalPodAutoscaler {
|
||||||
|
// Standard object metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1;
|
||||||
|
|
||||||
|
// behaviour of autoscaler. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.
|
||||||
|
optional HorizontalPodAutoscalerSpec spec = 2;
|
||||||
|
|
||||||
|
// current information about the autoscaler.
|
||||||
|
optional HorizontalPodAutoscalerStatus status = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// list of horizontal pod autoscaler objects.
|
||||||
|
message HorizontalPodAutoscalerList {
|
||||||
|
// Standard list metadata.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
|
||||||
|
|
||||||
|
// list of horizontal pod autoscaler objects.
|
||||||
|
repeated HorizontalPodAutoscaler items = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// specification of a horizontal pod autoscaler.
|
||||||
|
message HorizontalPodAutoscalerSpec {
|
||||||
|
// reference to scaled resource; horizontal pod autoscaler will learn the current resource consumption
|
||||||
|
// and will set the desired number of pods by using its Scale subresource.
|
||||||
|
optional CrossVersionObjectReference scaleTargetRef = 1;
|
||||||
|
|
||||||
|
// lower limit for the number of pods that can be set by the autoscaler, default 1.
|
||||||
|
optional int32 minReplicas = 2;
|
||||||
|
|
||||||
|
// upper limit for the number of pods that can be set by the autoscaler; cannot be smaller than MinReplicas.
|
||||||
|
optional int32 maxReplicas = 3;
|
||||||
|
|
||||||
|
// target average CPU utilization (represented as a percentage of requested CPU) over all the pods;
|
||||||
|
// if not specified the default autoscaling policy will be used.
|
||||||
|
optional int32 targetCPUUtilizationPercentage = 4;
|
||||||
|
}
|
||||||
|
|
||||||
|
// current status of a horizontal pod autoscaler
|
||||||
|
message HorizontalPodAutoscalerStatus {
|
||||||
|
// most recent generation observed by this autoscaler.
|
||||||
|
optional int64 observedGeneration = 1;
|
||||||
|
|
||||||
|
// last time the HorizontalPodAutoscaler scaled the number of pods;
|
||||||
|
// used by the autoscaler to control how often the number of pods is changed.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.Time lastScaleTime = 2;
|
||||||
|
|
||||||
|
// current number of replicas of pods managed by this autoscaler.
|
||||||
|
optional int32 currentReplicas = 3;
|
||||||
|
|
||||||
|
// desired number of replicas of pods managed by this autoscaler.
|
||||||
|
optional int32 desiredReplicas = 4;
|
||||||
|
|
||||||
|
// current average CPU utilization over all pods, represented as a percentage of requested CPU,
|
||||||
|
// e.g. 70 means that an average pod is using now 70% of its requested CPU.
|
||||||
|
optional int32 currentCPUUtilizationPercentage = 5;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Scale represents a scaling request for a resource.
|
||||||
|
message Scale {
|
||||||
|
// Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1;
|
||||||
|
|
||||||
|
// defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.
|
||||||
|
optional ScaleSpec spec = 2;
|
||||||
|
|
||||||
|
// current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only.
|
||||||
|
optional ScaleStatus status = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ScaleSpec describes the attributes of a scale subresource.
|
||||||
|
message ScaleSpec {
|
||||||
|
// desired number of instances for the scaled object.
|
||||||
|
optional int32 replicas = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ScaleStatus represents the current status of a scale subresource.
|
||||||
|
message ScaleStatus {
|
||||||
|
// actual number of observed instances of the scaled object.
|
||||||
|
optional int32 replicas = 1;
|
||||||
|
|
||||||
|
// label query over pods that should match the replicas count. This is same
|
||||||
|
// as the label selector but in the string format to avoid introspection
|
||||||
|
// by clients. The string will be in the same format as the query-param syntax.
|
||||||
|
// More info about label selectors: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
|
optional string selector = 2;
|
||||||
|
}
|
||||||
|
|
@@ -24,97 +24,97 @@ import (
|
|||||||
// CrossVersionObjectReference contains enough information to let you identify the referred resource.
|
// CrossVersionObjectReference contains enough information to let you identify the referred resource.
|
||||||
type CrossVersionObjectReference struct {
|
type CrossVersionObjectReference struct {
|
||||||
// Kind of the referent; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds"
|
// Kind of the referent; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds"
|
||||||
Kind string `json:"kind"`
|
Kind string `json:"kind" protobuf:"bytes,1,opt,name=kind"`
|
||||||
// Name of the referent; More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
|
// Name of the referent; More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
|
||||||
Name string `json:"name"`
|
Name string `json:"name" protobuf:"bytes,2,opt,name=name"`
|
||||||
// API version of the referent
|
// API version of the referent
|
||||||
APIVersion string `json:"apiVersion,omitempty"`
|
APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,3,opt,name=apiVersion"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// specification of a horizontal pod autoscaler.
|
// specification of a horizontal pod autoscaler.
|
||||||
type HorizontalPodAutoscalerSpec struct {
|
type HorizontalPodAutoscalerSpec struct {
|
||||||
// reference to scaled resource; horizontal pod autoscaler will learn the current resource consumption
|
// reference to scaled resource; horizontal pod autoscaler will learn the current resource consumption
|
||||||
// and will set the desired number of pods by using its Scale subresource.
|
// and will set the desired number of pods by using its Scale subresource.
|
||||||
ScaleTargetRef CrossVersionObjectReference `json:"scaleTargetRef"`
|
ScaleTargetRef CrossVersionObjectReference `json:"scaleTargetRef" protobuf:"bytes,1,opt,name=scaleTargetRef"`
|
||||||
// lower limit for the number of pods that can be set by the autoscaler, default 1.
|
// lower limit for the number of pods that can be set by the autoscaler, default 1.
|
||||||
MinReplicas *int32 `json:"minReplicas,omitempty"`
|
MinReplicas *int32 `json:"minReplicas,omitempty" protobuf:"varint,2,opt,name=minReplicas"`
|
||||||
// upper limit for the number of pods that can be set by the autoscaler; cannot be smaller than MinReplicas.
|
// upper limit for the number of pods that can be set by the autoscaler; cannot be smaller than MinReplicas.
|
||||||
MaxReplicas int32 `json:"maxReplicas"`
|
MaxReplicas int32 `json:"maxReplicas" protobuf:"varint,3,opt,name=maxReplicas"`
|
||||||
// target average CPU utilization (represented as a percentage of requested CPU) over all the pods;
|
// target average CPU utilization (represented as a percentage of requested CPU) over all the pods;
|
||||||
// if not specified the default autoscaling policy will be used.
|
// if not specified the default autoscaling policy will be used.
|
||||||
TargetCPUUtilizationPercentage *int32 `json:"targetCPUUtilizationPercentage,omitempty"`
|
TargetCPUUtilizationPercentage *int32 `json:"targetCPUUtilizationPercentage,omitempty" protobuf:"varint,4,opt,name=targetCPUUtilizationPercentage"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// current status of a horizontal pod autoscaler
|
// current status of a horizontal pod autoscaler
|
||||||
type HorizontalPodAutoscalerStatus struct {
|
type HorizontalPodAutoscalerStatus struct {
|
||||||
// most recent generation observed by this autoscaler.
|
// most recent generation observed by this autoscaler.
|
||||||
ObservedGeneration *int64 `json:"observedGeneration,omitempty"`
|
ObservedGeneration *int64 `json:"observedGeneration,omitempty" protobuf:"varint,1,opt,name=observedGeneration"`
|
||||||
|
|
||||||
// last time the HorizontalPodAutoscaler scaled the number of pods;
|
// last time the HorizontalPodAutoscaler scaled the number of pods;
|
||||||
// used by the autoscaler to control how often the number of pods is changed.
|
// used by the autoscaler to control how often the number of pods is changed.
|
||||||
LastScaleTime *unversioned.Time `json:"lastScaleTime,omitempty"`
|
LastScaleTime *unversioned.Time `json:"lastScaleTime,omitempty" protobuf:"bytes,2,opt,name=lastScaleTime"`
|
||||||
|
|
||||||
// current number of replicas of pods managed by this autoscaler.
|
// current number of replicas of pods managed by this autoscaler.
|
||||||
CurrentReplicas int32 `json:"currentReplicas"`
|
CurrentReplicas int32 `json:"currentReplicas" protobuf:"varint,3,opt,name=currentReplicas"`
|
||||||
|
|
||||||
// desired number of replicas of pods managed by this autoscaler.
|
// desired number of replicas of pods managed by this autoscaler.
|
||||||
DesiredReplicas int32 `json:"desiredReplicas"`
|
DesiredReplicas int32 `json:"desiredReplicas" protobuf:"varint,4,opt,name=desiredReplicas"`
|
||||||
|
|
||||||
// current average CPU utilization over all pods, represented as a percentage of requested CPU,
|
// current average CPU utilization over all pods, represented as a percentage of requested CPU,
|
||||||
// e.g. 70 means that an average pod is using now 70% of its requested CPU.
|
// e.g. 70 means that an average pod is using now 70% of its requested CPU.
|
||||||
CurrentCPUUtilizationPercentage *int32 `json:"currentCPUUtilizationPercentage,omitempty"`
|
CurrentCPUUtilizationPercentage *int32 `json:"currentCPUUtilizationPercentage,omitempty" protobuf:"varint,5,opt,name=currentCPUUtilizationPercentage"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// configuration of a horizontal pod autoscaler.
|
// configuration of a horizontal pod autoscaler.
|
||||||
type HorizontalPodAutoscaler struct {
|
type HorizontalPodAutoscaler struct {
|
||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// Standard object metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
// Standard object metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
v1.ObjectMeta `json:"metadata,omitempty"`
|
v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// behaviour of autoscaler. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.
|
// behaviour of autoscaler. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.
|
||||||
Spec HorizontalPodAutoscalerSpec `json:"spec,omitempty"`
|
Spec HorizontalPodAutoscalerSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
||||||
|
|
||||||
// current information about the autoscaler.
|
// current information about the autoscaler.
|
||||||
Status HorizontalPodAutoscalerStatus `json:"status,omitempty"`
|
Status HorizontalPodAutoscalerStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// list of horizontal pod autoscaler objects.
|
// list of horizontal pod autoscaler objects.
|
||||||
type HorizontalPodAutoscalerList struct {
|
type HorizontalPodAutoscalerList struct {
|
||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// Standard list metadata.
|
// Standard list metadata.
|
||||||
unversioned.ListMeta `json:"metadata,omitempty"`
|
unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// list of horizontal pod autoscaler objects.
|
// list of horizontal pod autoscaler objects.
|
||||||
Items []HorizontalPodAutoscaler `json:"items"`
|
Items []HorizontalPodAutoscaler `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Scale represents a scaling request for a resource.
|
// Scale represents a scaling request for a resource.
|
||||||
type Scale struct {
|
type Scale struct {
|
||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.
|
// Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.
|
||||||
v1.ObjectMeta `json:"metadata,omitempty"`
|
v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.
|
// defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.
|
||||||
Spec ScaleSpec `json:"spec,omitempty"`
|
Spec ScaleSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
||||||
|
|
||||||
// current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only.
|
// current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only.
|
||||||
Status ScaleStatus `json:"status,omitempty"`
|
Status ScaleStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ScaleSpec describes the attributes of a scale subresource.
|
// ScaleSpec describes the attributes of a scale subresource.
|
||||||
type ScaleSpec struct {
|
type ScaleSpec struct {
|
||||||
// desired number of instances for the scaled object.
|
// desired number of instances for the scaled object.
|
||||||
Replicas int32 `json:"replicas,omitempty"`
|
Replicas int32 `json:"replicas,omitempty" protobuf:"varint,1,opt,name=replicas"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ScaleStatus represents the current status of a scale subresource.
|
// ScaleStatus represents the current status of a scale subresource.
|
||||||
type ScaleStatus struct {
|
type ScaleStatus struct {
|
||||||
// actual number of observed instances of the scaled object.
|
// actual number of observed instances of the scaled object.
|
||||||
Replicas int32 `json:"replicas"`
|
Replicas int32 `json:"replicas" protobuf:"varint,1,opt,name=replicas"`
|
||||||
|
|
||||||
// label query over pods that should match the replicas count. This is same
|
// label query over pods that should match the replicas count. This is same
|
||||||
// as the label selector but in the string format to avoid introspection
|
// as the label selector but in the string format to avoid introspection
|
||||||
// by clients. The string will be in the same format as the query-param syntax.
|
// by clients. The string will be in the same format as the query-param syntax.
|
||||||
// More info about label selectors: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
// More info about label selectors: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
Selector string `json:"selector,omitempty"`
|
Selector string `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"`
|
||||||
}
|
}
|
||||||
|
1903
pkg/apis/batch/v1/generated.pb.go
Normal file
1903
pkg/apis/batch/v1/generated.pb.go
Normal file
File diff suppressed because it is too large
Load Diff
177
pkg/apis/batch/v1/generated.proto
Normal file
177
pkg/apis/batch/v1/generated.proto
Normal file
@@ -0,0 +1,177 @@
|
|||||||
|
/*
|
||||||
|
Copyright 2016 The Kubernetes Authors All rights reserved.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
// This file was autogenerated by go-to-protobuf. Do not edit it manually!
|
||||||
|
|
||||||
|
syntax = 'proto2';
|
||||||
|
|
||||||
|
package k8s.io.kubernetes.pkg.apis.batch.v1;
|
||||||
|
|
||||||
|
import "k8s.io/kubernetes/pkg/api/resource/generated.proto";
|
||||||
|
import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto";
|
||||||
|
import "k8s.io/kubernetes/pkg/api/v1/generated.proto";
|
||||||
|
import "k8s.io/kubernetes/pkg/util/intstr/generated.proto";
|
||||||
|
|
||||||
|
// Package-wide variables from generator "generated".
|
||||||
|
option go_package = "v1";
|
||||||
|
|
||||||
|
// Job represents the configuration of a single job.
|
||||||
|
message Job {
|
||||||
|
// Standard object's metadata.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1;
|
||||||
|
|
||||||
|
// 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
|
||||||
|
optional JobSpec spec = 2;
|
||||||
|
|
||||||
|
// 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
|
||||||
|
optional JobStatus status = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// JobCondition describes current state of a job.
|
||||||
|
message JobCondition {
|
||||||
|
// Type of job condition, Complete or Failed.
|
||||||
|
optional string type = 1;
|
||||||
|
|
||||||
|
// Status of the condition, one of True, False, Unknown.
|
||||||
|
optional string status = 2;
|
||||||
|
|
||||||
|
// Last time the condition was checked.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.Time lastProbeTime = 3;
|
||||||
|
|
||||||
|
// Last time the condition transit from one status to another.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTransitionTime = 4;
|
||||||
|
|
||||||
|
// (brief) reason for the condition's last transition.
|
||||||
|
optional string reason = 5;
|
||||||
|
|
||||||
|
// Human readable message indicating details about last transition.
|
||||||
|
optional string message = 6;
|
||||||
|
}
|
||||||
|
|
||||||
|
// JobList is a collection of jobs.
|
||||||
|
message JobList {
|
||||||
|
// Standard list metadata
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
|
||||||
|
|
||||||
|
// Items is the list of Job.
|
||||||
|
repeated Job items = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// JobSpec describes how the job execution will look like.
|
||||||
|
message JobSpec {
|
||||||
|
// Parallelism specifies the maximum desired number of pods the job should
|
||||||
|
// run at any given time. The actual number of pods running in steady state will
|
||||||
|
// be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism),
|
||||||
|
// i.e. when the work left to do is less than max parallelism.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
|
optional int32 parallelism = 1;
|
||||||
|
|
||||||
|
// Completions specifies the desired number of successfully finished pods the
|
||||||
|
// job should be run with. Setting to nil means that the success of any
|
||||||
|
// pod signals the success of all pods, and allows parallelism to have any positive
|
||||||
|
// value. Setting to 1 means that parallelism is limited to 1 and the success of that
|
||||||
|
// pod signals the success of the job.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
|
optional int32 completions = 2;
|
||||||
|
|
||||||
|
// Optional duration in seconds relative to the startTime that the job may be active
|
||||||
|
// before the system tries to terminate it; value must be positive integer
|
||||||
|
optional int64 activeDeadlineSeconds = 3;
|
||||||
|
|
||||||
|
// Selector is a label query over pods that should match the pod count.
|
||||||
|
// Normally, the system sets this field for you.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
|
optional LabelSelector selector = 4;
|
||||||
|
|
||||||
|
// ManualSelector controls generation of pod labels and pod selectors.
|
||||||
|
// Leave `manualSelector` unset unless you are certain what you are doing.
|
||||||
|
// When false or unset, the system pick labels unique to this job
|
||||||
|
// and appends those labels to the pod template. When true,
|
||||||
|
// the user is responsible for picking unique labels and specifying
|
||||||
|
// the selector. Failure to pick a unique label may cause this
|
||||||
|
// and other jobs to not function correctly. However, You may see
|
||||||
|
// `manualSelector=true` in jobs that were created with the old `extensions/v1beta1`
|
||||||
|
// API.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md
|
||||||
|
optional bool manualSelector = 5;
|
||||||
|
|
||||||
|
// Template is the object that describes the pod that will be created when
|
||||||
|
// executing a job.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 6;
|
||||||
|
}
|
||||||
|
|
||||||
|
// JobStatus represents the current state of a Job.
|
||||||
|
message JobStatus {
|
||||||
|
// Conditions represent the latest available observations of an object's current state.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
|
repeated JobCondition conditions = 1;
|
||||||
|
|
||||||
|
// StartTime represents time when the job was acknowledged by the Job Manager.
|
||||||
|
// It is not guaranteed to be set in happens-before order across separate operations.
|
||||||
|
// It is represented in RFC3339 form and is in UTC.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.Time startTime = 2;
|
||||||
|
|
||||||
|
// CompletionTime represents time when the job was completed. It is not guaranteed to
|
||||||
|
// be set in happens-before order across separate operations.
|
||||||
|
// It is represented in RFC3339 form and is in UTC.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.Time completionTime = 3;
|
||||||
|
|
||||||
|
// Active is the number of actively running pods.
|
||||||
|
optional int32 active = 4;
|
||||||
|
|
||||||
|
// Succeeded is the number of pods which reached Phase Succeeded.
|
||||||
|
optional int32 succeeded = 5;
|
||||||
|
|
||||||
|
// Failed is the number of pods which reached Phase Failed.
|
||||||
|
optional int32 failed = 6;
|
||||||
|
}
|
||||||
|
|
||||||
|
// A label selector is a label query over a set of resources. The result of matchLabels and
|
||||||
|
// matchExpressions are ANDed. An empty label selector matches all objects. A null
|
||||||
|
// label selector matches no objects.
|
||||||
|
message LabelSelector {
|
||||||
|
// matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
|
||||||
|
// map is equivalent to an element of matchExpressions, whose key field is "key", the
|
||||||
|
// operator is "In", and the values array contains only "value". The requirements are ANDed.
|
||||||
|
map<string, string> matchLabels = 1;
|
||||||
|
|
||||||
|
// matchExpressions is a list of label selector requirements. The requirements are ANDed.
|
||||||
|
repeated LabelSelectorRequirement matchExpressions = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// A label selector requirement is a selector that contains values, a key, and an operator that
|
||||||
|
// relates the key and values.
|
||||||
|
message LabelSelectorRequirement {
|
||||||
|
// key is the label key that the selector applies to.
|
||||||
|
optional string key = 1;
|
||||||
|
|
||||||
|
// operator represents a key's relationship to a set of values.
|
||||||
|
// Valid operators ard In, NotIn, Exists and DoesNotExist.
|
||||||
|
optional string operator = 2;
|
||||||
|
|
||||||
|
// values is an array of string values. If the operator is In or NotIn,
|
||||||
|
// the values array must be non-empty. If the operator is Exists or DoesNotExist,
|
||||||
|
// the values array must be empty. This array is replaced during a strategic
|
||||||
|
// merge patch.
|
||||||
|
repeated string values = 3;
|
||||||
|
}
|
||||||
|
|
@@ -26,15 +26,15 @@ type Job struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// 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
|
||||||
v1.ObjectMeta `json:"metadata,omitempty"`
|
v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Spec is a structure defining the expected behavior of a job.
|
// 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
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
Spec JobSpec `json:"spec,omitempty"`
|
Spec JobSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
||||||
|
|
||||||
// Status is a structure describing current status of a job.
|
// 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
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
Status JobStatus `json:"status,omitempty"`
|
Status JobStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// JobList is a collection of jobs.
|
// JobList is a collection of jobs.
|
||||||
@@ -42,10 +42,10 @@ type JobList struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// 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
|
||||||
unversioned.ListMeta `json:"metadata,omitempty"`
|
unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Items is the list of Job.
|
// Items is the list of Job.
|
||||||
Items []Job `json:"items"`
|
Items []Job `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// JobSpec describes how the job execution will look like.
|
// JobSpec describes how the job execution will look like.
|
||||||
@@ -56,7 +56,7 @@ type JobSpec struct {
|
|||||||
// be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism),
|
// be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism),
|
||||||
// i.e. when the work left to do is less than max parallelism.
|
// i.e. when the work left to do is less than max parallelism.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
Parallelism *int32 `json:"parallelism,omitempty"`
|
Parallelism *int32 `json:"parallelism,omitempty" protobuf:"varint,1,opt,name=parallelism"`
|
||||||
|
|
||||||
// Completions specifies the desired number of successfully finished pods the
|
// Completions specifies the desired number of successfully finished pods the
|
||||||
// job should be run with. Setting to nil means that the success of any
|
// job should be run with. Setting to nil means that the success of any
|
||||||
@@ -64,16 +64,16 @@ type JobSpec struct {
|
|||||||
// value. Setting to 1 means that parallelism is limited to 1 and the success of that
|
// value. Setting to 1 means that parallelism is limited to 1 and the success of that
|
||||||
// pod signals the success of the job.
|
// pod signals the success of the job.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
Completions *int32 `json:"completions,omitempty"`
|
Completions *int32 `json:"completions,omitempty" protobuf:"varint,2,opt,name=completions"`
|
||||||
|
|
||||||
// Optional duration in seconds relative to the startTime that the job may be active
|
// Optional duration in seconds relative to the startTime that the job may be active
|
||||||
// before the system tries to terminate it; value must be positive integer
|
// before the system tries to terminate it; value must be positive integer
|
||||||
ActiveDeadlineSeconds *int64 `json:"activeDeadlineSeconds,omitempty"`
|
ActiveDeadlineSeconds *int64 `json:"activeDeadlineSeconds,omitempty" protobuf:"varint,3,opt,name=activeDeadlineSeconds"`
|
||||||
|
|
||||||
// Selector is a label query over pods that should match the pod count.
|
// Selector is a label query over pods that should match the pod count.
|
||||||
// Normally, the system sets this field for you.
|
// Normally, the system sets this field for you.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
Selector *LabelSelector `json:"selector,omitempty"`
|
Selector *LabelSelector `json:"selector,omitempty" protobuf:"bytes,4,opt,name=selector"`
|
||||||
|
|
||||||
// ManualSelector controls generation of pod labels and pod selectors.
|
// ManualSelector controls generation of pod labels and pod selectors.
|
||||||
// Leave `manualSelector` unset unless you are certain what you are doing.
|
// Leave `manualSelector` unset unless you are certain what you are doing.
|
||||||
@@ -85,12 +85,12 @@ type JobSpec struct {
|
|||||||
// `manualSelector=true` in jobs that were created with the old `extensions/v1beta1`
|
// `manualSelector=true` in jobs that were created with the old `extensions/v1beta1`
|
||||||
// API.
|
// API.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md
|
// More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md
|
||||||
ManualSelector *bool `json:"manualSelector,omitempty"`
|
ManualSelector *bool `json:"manualSelector,omitempty" protobuf:"varint,5,opt,name=manualSelector"`
|
||||||
|
|
||||||
// Template is the object that describes the pod that will be created when
|
// Template is the object that describes the pod that will be created when
|
||||||
// executing a job.
|
// executing a job.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
Template v1.PodTemplateSpec `json:"template"`
|
Template v1.PodTemplateSpec `json:"template" protobuf:"bytes,6,opt,name=template"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// JobStatus represents the current state of a Job.
|
// JobStatus represents the current state of a Job.
|
||||||
@@ -98,26 +98,26 @@ type JobStatus struct {
|
|||||||
|
|
||||||
// Conditions represent the latest available observations of an object's current state.
|
// Conditions represent the latest available observations of an object's current state.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
Conditions []JobCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type"`
|
Conditions []JobCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,1,rep,name=conditions"`
|
||||||
|
|
||||||
// StartTime represents time when the job was acknowledged by the Job Manager.
|
// StartTime represents time when the job was acknowledged by the Job Manager.
|
||||||
// It is not guaranteed to be set in happens-before order across separate operations.
|
// It is not guaranteed to be set in happens-before order across separate operations.
|
||||||
// It is represented in RFC3339 form and is in UTC.
|
// It is represented in RFC3339 form and is in UTC.
|
||||||
StartTime *unversioned.Time `json:"startTime,omitempty"`
|
StartTime *unversioned.Time `json:"startTime,omitempty" protobuf:"bytes,2,opt,name=startTime"`
|
||||||
|
|
||||||
// CompletionTime represents time when the job was completed. It is not guaranteed to
|
// CompletionTime represents time when the job was completed. It is not guaranteed to
|
||||||
// be set in happens-before order across separate operations.
|
// be set in happens-before order across separate operations.
|
||||||
// It is represented in RFC3339 form and is in UTC.
|
// It is represented in RFC3339 form and is in UTC.
|
||||||
CompletionTime *unversioned.Time `json:"completionTime,omitempty"`
|
CompletionTime *unversioned.Time `json:"completionTime,omitempty" protobuf:"bytes,3,opt,name=completionTime"`
|
||||||
|
|
||||||
// Active is the number of actively running pods.
|
// Active is the number of actively running pods.
|
||||||
Active int32 `json:"active,omitempty"`
|
Active int32 `json:"active,omitempty" protobuf:"varint,4,opt,name=active"`
|
||||||
|
|
||||||
// Succeeded is the number of pods which reached Phase Succeeded.
|
// Succeeded is the number of pods which reached Phase Succeeded.
|
||||||
Succeeded int32 `json:"succeeded,omitempty"`
|
Succeeded int32 `json:"succeeded,omitempty" protobuf:"varint,5,opt,name=succeeded"`
|
||||||
|
|
||||||
// Failed is the number of pods which reached Phase Failed.
|
// Failed is the number of pods which reached Phase Failed.
|
||||||
Failed int32 `json:"failed,omitempty"`
|
Failed int32 `json:"failed,omitempty" protobuf:"varint,6,opt,name=failed"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type JobConditionType string
|
type JobConditionType string
|
||||||
@@ -133,17 +133,17 @@ const (
|
|||||||
// JobCondition describes current state of a job.
|
// JobCondition describes current state of a job.
|
||||||
type JobCondition struct {
|
type JobCondition struct {
|
||||||
// Type of job condition, Complete or Failed.
|
// Type of job condition, Complete or Failed.
|
||||||
Type JobConditionType `json:"type"`
|
Type JobConditionType `json:"type" protobuf:"bytes,1,opt,name=type,casttype=JobConditionType"`
|
||||||
// Status of the condition, one of True, False, Unknown.
|
// Status of the condition, one of True, False, Unknown.
|
||||||
Status v1.ConditionStatus `json:"status"`
|
Status v1.ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=k8s.io/kubernetes/pkg/api/v1.ConditionStatus"`
|
||||||
// Last time the condition was checked.
|
// Last time the condition was checked.
|
||||||
LastProbeTime unversioned.Time `json:"lastProbeTime,omitempty"`
|
LastProbeTime unversioned.Time `json:"lastProbeTime,omitempty" protobuf:"bytes,3,opt,name=lastProbeTime"`
|
||||||
// Last time the condition transit from one status to another.
|
// Last time the condition transit from one status to another.
|
||||||
LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty"`
|
LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,4,opt,name=lastTransitionTime"`
|
||||||
// (brief) reason for the condition's last transition.
|
// (brief) reason for the condition's last transition.
|
||||||
Reason string `json:"reason,omitempty"`
|
Reason string `json:"reason,omitempty" protobuf:"bytes,5,opt,name=reason"`
|
||||||
// Human readable message indicating details about last transition.
|
// Human readable message indicating details about last transition.
|
||||||
Message string `json:"message,omitempty"`
|
Message string `json:"message,omitempty" protobuf:"bytes,6,opt,name=message"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// A label selector is a label query over a set of resources. The result of matchLabels and
|
// A label selector is a label query over a set of resources. The result of matchLabels and
|
||||||
@@ -153,24 +153,24 @@ type LabelSelector struct {
|
|||||||
// matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
|
// matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
|
||||||
// map is equivalent to an element of matchExpressions, whose key field is "key", the
|
// map is equivalent to an element of matchExpressions, whose key field is "key", the
|
||||||
// operator is "In", and the values array contains only "value". The requirements are ANDed.
|
// operator is "In", and the values array contains only "value". The requirements are ANDed.
|
||||||
MatchLabels map[string]string `json:"matchLabels,omitempty"`
|
MatchLabels map[string]string `json:"matchLabels,omitempty" protobuf:"bytes,1,rep,name=matchLabels"`
|
||||||
// matchExpressions is a list of label selector requirements. The requirements are ANDed.
|
// matchExpressions is a list of label selector requirements. The requirements are ANDed.
|
||||||
MatchExpressions []LabelSelectorRequirement `json:"matchExpressions,omitempty"`
|
MatchExpressions []LabelSelectorRequirement `json:"matchExpressions,omitempty" protobuf:"bytes,2,rep,name=matchExpressions"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// A label selector requirement is a selector that contains values, a key, and an operator that
|
// A label selector requirement is a selector that contains values, a key, and an operator that
|
||||||
// relates the key and values.
|
// relates the key and values.
|
||||||
type LabelSelectorRequirement struct {
|
type LabelSelectorRequirement struct {
|
||||||
// key is the label key that the selector applies to.
|
// key is the label key that the selector applies to.
|
||||||
Key string `json:"key" patchStrategy:"merge" patchMergeKey:"key"`
|
Key string `json:"key" patchStrategy:"merge" patchMergeKey:"key" protobuf:"bytes,1,opt,name=key"`
|
||||||
// operator represents a key's relationship to a set of values.
|
// operator represents a key's relationship to a set of values.
|
||||||
// Valid operators ard In, NotIn, Exists and DoesNotExist.
|
// Valid operators ard In, NotIn, Exists and DoesNotExist.
|
||||||
Operator LabelSelectorOperator `json:"operator"`
|
Operator LabelSelectorOperator `json:"operator" protobuf:"bytes,2,opt,name=operator,casttype=LabelSelectorOperator"`
|
||||||
// values is an array of string values. If the operator is In or NotIn,
|
// values is an array of string values. If the operator is In or NotIn,
|
||||||
// the values array must be non-empty. If the operator is Exists or DoesNotExist,
|
// the values array must be non-empty. If the operator is Exists or DoesNotExist,
|
||||||
// the values array must be empty. This array is replaced during a strategic
|
// the values array must be empty. This array is replaced during a strategic
|
||||||
// merge patch.
|
// merge patch.
|
||||||
Values []string `json:"values,omitempty"`
|
Values []string `json:"values,omitempty" protobuf:"bytes,3,rep,name=values"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// A label selector operator is the set of operators that can be used in a selector requirement.
|
// A label selector operator is the set of operators that can be used in a selector requirement.
|
||||||
|
11451
pkg/apis/extensions/v1beta1/generated.pb.go
Normal file
11451
pkg/apis/extensions/v1beta1/generated.pb.go
Normal file
File diff suppressed because it is too large
Load Diff
878
pkg/apis/extensions/v1beta1/generated.proto
Normal file
878
pkg/apis/extensions/v1beta1/generated.proto
Normal file
@@ -0,0 +1,878 @@
|
|||||||
|
/*
|
||||||
|
Copyright 2016 The Kubernetes Authors All rights reserved.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
// This file was autogenerated by go-to-protobuf. Do not edit it manually!
|
||||||
|
|
||||||
|
syntax = 'proto2';
|
||||||
|
|
||||||
|
package k8s.io.kubernetes.pkg.apis.extensions.v1beta1;
|
||||||
|
|
||||||
|
import "k8s.io/kubernetes/pkg/api/resource/generated.proto";
|
||||||
|
import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto";
|
||||||
|
import "k8s.io/kubernetes/pkg/api/v1/generated.proto";
|
||||||
|
import "k8s.io/kubernetes/pkg/util/intstr/generated.proto";
|
||||||
|
|
||||||
|
// Package-wide variables from generator "generated".
|
||||||
|
option go_package = "v1beta1";
|
||||||
|
|
||||||
|
// An APIVersion represents a single concrete version of an object model.
|
||||||
|
message APIVersion {
|
||||||
|
// Name of this version (e.g. 'v1').
|
||||||
|
optional string name = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
message CPUTargetUtilization {
|
||||||
|
// fraction of the requested CPU that should be utilized/used,
|
||||||
|
// e.g. 70 means that 70% of the requested CPU should be in use.
|
||||||
|
optional int32 targetPercentage = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
message CustomMetricCurrentStatus {
|
||||||
|
// Custom Metric name.
|
||||||
|
optional string name = 1;
|
||||||
|
|
||||||
|
// Custom Metric value (average).
|
||||||
|
optional k8s.io.kubernetes.pkg.api.resource.Quantity value = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
message CustomMetricCurrentStatusList {
|
||||||
|
repeated CustomMetricCurrentStatus items = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Alpha-level support for Custom Metrics in HPA (as annotations).
|
||||||
|
message CustomMetricTarget {
|
||||||
|
// Custom Metric name.
|
||||||
|
optional string name = 1;
|
||||||
|
|
||||||
|
// Custom Metric value (average).
|
||||||
|
optional k8s.io.kubernetes.pkg.api.resource.Quantity value = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
message CustomMetricTargetList {
|
||||||
|
repeated CustomMetricTarget items = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// DaemonSet represents the configuration of a daemon set.
|
||||||
|
message DaemonSet {
|
||||||
|
// Standard object's metadata.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1;
|
||||||
|
|
||||||
|
// Spec defines the desired behavior of this daemon set.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
|
optional DaemonSetSpec spec = 2;
|
||||||
|
|
||||||
|
// Status is the current status of this daemon set. This data may be
|
||||||
|
// out of date by some window of time.
|
||||||
|
// Populated by the system.
|
||||||
|
// Read-only.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
|
optional DaemonSetStatus status = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// DaemonSetList is a collection of daemon sets.
|
||||||
|
message DaemonSetList {
|
||||||
|
// Standard list metadata.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
|
||||||
|
|
||||||
|
// Items is a list of daemon sets.
|
||||||
|
repeated DaemonSet items = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// DaemonSetSpec is the specification of a daemon set.
|
||||||
|
message DaemonSetSpec {
|
||||||
|
// Selector is a label query over pods that are managed by the daemon set.
|
||||||
|
// Must match in order to be controlled.
|
||||||
|
// If empty, defaulted to labels on Pod template.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
|
optional LabelSelector selector = 1;
|
||||||
|
|
||||||
|
// Template is the object that describes the pod that will be created.
|
||||||
|
// The DaemonSet will create exactly one copy of this pod on every node
|
||||||
|
// that matches the template's node selector (or on every node if no node
|
||||||
|
// selector is specified).
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#pod-template
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// DaemonSetStatus represents the current status of a daemon set.
|
||||||
|
message DaemonSetStatus {
|
||||||
|
// CurrentNumberScheduled is the number of nodes that are running at least 1
|
||||||
|
// daemon pod and are supposed to run the daemon pod.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md
|
||||||
|
optional int32 currentNumberScheduled = 1;
|
||||||
|
|
||||||
|
// NumberMisscheduled is the number of nodes that are running the daemon pod, but are
|
||||||
|
// not supposed to run the daemon pod.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md
|
||||||
|
optional int32 numberMisscheduled = 2;
|
||||||
|
|
||||||
|
// DesiredNumberScheduled is the total number of nodes that should be running the daemon
|
||||||
|
// pod (including nodes correctly running the daemon pod).
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md
|
||||||
|
optional int32 desiredNumberScheduled = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Deployment enables declarative updates for Pods and ReplicaSets.
|
||||||
|
message Deployment {
|
||||||
|
// Standard object metadata.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1;
|
||||||
|
|
||||||
|
// Specification of the desired behavior of the Deployment.
|
||||||
|
optional DeploymentSpec spec = 2;
|
||||||
|
|
||||||
|
// Most recently observed status of the Deployment.
|
||||||
|
optional DeploymentStatus status = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeploymentList is a list of Deployments.
|
||||||
|
message DeploymentList {
|
||||||
|
// Standard list metadata.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
|
||||||
|
|
||||||
|
// Items is the list of Deployments.
|
||||||
|
repeated Deployment items = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeploymentRollback stores the information required to rollback a deployment.
|
||||||
|
message DeploymentRollback {
|
||||||
|
// Required: This must match the Name of a deployment.
|
||||||
|
optional string name = 1;
|
||||||
|
|
||||||
|
// The annotations to be updated to a deployment
|
||||||
|
map<string, string> updatedAnnotations = 2;
|
||||||
|
|
||||||
|
// The config of this deployment rollback.
|
||||||
|
optional RollbackConfig rollbackTo = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeploymentSpec is the specification of the desired behavior of the Deployment.
|
||||||
|
message DeploymentSpec {
|
||||||
|
// Number of desired pods. This is a pointer to distinguish between explicit
|
||||||
|
// zero and not specified. Defaults to 1.
|
||||||
|
optional int32 replicas = 1;
|
||||||
|
|
||||||
|
// Label selector for pods. Existing ReplicaSets whose pods are
|
||||||
|
// selected by this will be the ones affected by this deployment.
|
||||||
|
optional LabelSelector selector = 2;
|
||||||
|
|
||||||
|
// Template describes the pods that will be created.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 3;
|
||||||
|
|
||||||
|
// The deployment strategy to use to replace existing pods with new ones.
|
||||||
|
optional DeploymentStrategy strategy = 4;
|
||||||
|
|
||||||
|
// Minimum number of seconds for which a newly created pod should be ready
|
||||||
|
// without any of its container crashing, for it to be considered available.
|
||||||
|
// Defaults to 0 (pod will be considered available as soon as it is ready)
|
||||||
|
optional int32 minReadySeconds = 5;
|
||||||
|
|
||||||
|
// The number of old ReplicaSets to retain to allow rollback.
|
||||||
|
// This is a pointer to distinguish between explicit zero and not specified.
|
||||||
|
optional int32 revisionHistoryLimit = 6;
|
||||||
|
|
||||||
|
// Indicates that the deployment is paused and will not be processed by the
|
||||||
|
// deployment controller.
|
||||||
|
optional bool paused = 7;
|
||||||
|
|
||||||
|
// The config this deployment is rolling back to. Will be cleared after rollback is done.
|
||||||
|
optional RollbackConfig rollbackTo = 8;
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeploymentStatus is the most recently observed status of the Deployment.
|
||||||
|
message DeploymentStatus {
|
||||||
|
// The generation observed by the deployment controller.
|
||||||
|
optional int64 observedGeneration = 1;
|
||||||
|
|
||||||
|
// Total number of non-terminated pods targeted by this deployment (their labels match the selector).
|
||||||
|
optional int32 replicas = 2;
|
||||||
|
|
||||||
|
// Total number of non-terminated pods targeted by this deployment that have the desired template spec.
|
||||||
|
optional int32 updatedReplicas = 3;
|
||||||
|
|
||||||
|
// Total number of available pods (ready for at least minReadySeconds) targeted by this deployment.
|
||||||
|
optional int32 availableReplicas = 4;
|
||||||
|
|
||||||
|
// Total number of unavailable pods targeted by this deployment.
|
||||||
|
optional int32 unavailableReplicas = 5;
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeploymentStrategy describes how to replace existing pods with new ones.
|
||||||
|
message DeploymentStrategy {
|
||||||
|
// Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate.
|
||||||
|
optional string type = 1;
|
||||||
|
|
||||||
|
// Rolling update config params. Present only if DeploymentStrategyType =
|
||||||
|
// RollingUpdate.
|
||||||
|
// ---
|
||||||
|
// TODO: Update this to follow our convention for oneOf, whatever we decide it
|
||||||
|
// to be.
|
||||||
|
optional RollingUpdateDeployment rollingUpdate = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ExportOptions is the query options to the standard REST get call.
|
||||||
|
message ExportOptions {
|
||||||
|
// Should this value be exported. Export strips fields that a user can not specify.
|
||||||
|
optional bool export = 1;
|
||||||
|
|
||||||
|
// Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'
|
||||||
|
optional bool exact = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// HTTPIngressPath associates a path regex with a backend. Incoming urls matching
|
||||||
|
// the path are forwarded to the backend.
|
||||||
|
message HTTPIngressPath {
|
||||||
|
// Path is a extended POSIX regex as defined by IEEE Std 1003.1,
|
||||||
|
// (i.e this follows the egrep/unix syntax, not the perl syntax)
|
||||||
|
// matched against the path of an incoming request. Currently it can
|
||||||
|
// contain characters disallowed from the conventional "path"
|
||||||
|
// part of a URL as defined by RFC 3986. Paths must begin with
|
||||||
|
// a '/'. If unspecified, the path defaults to a catch all sending
|
||||||
|
// traffic to the backend.
|
||||||
|
optional string path = 1;
|
||||||
|
|
||||||
|
// Backend defines the referenced service endpoint to which the traffic
|
||||||
|
// will be forwarded to.
|
||||||
|
optional IngressBackend backend = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// HTTPIngressRuleValue is a list of http selectors pointing to backends.
|
||||||
|
// In the example: http://<host>/<path>?<searchpart> -> backend where
|
||||||
|
// where parts of the url correspond to RFC 3986, this resource will be used
|
||||||
|
// to match against everything after the last '/' and before the first '?'
|
||||||
|
// or '#'.
|
||||||
|
message HTTPIngressRuleValue {
|
||||||
|
// A collection of paths that map requests to backends.
|
||||||
|
repeated HTTPIngressPath paths = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// configuration of a horizontal pod autoscaler.
|
||||||
|
message HorizontalPodAutoscaler {
|
||||||
|
// Standard object metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1;
|
||||||
|
|
||||||
|
// behaviour of autoscaler. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.
|
||||||
|
optional HorizontalPodAutoscalerSpec spec = 2;
|
||||||
|
|
||||||
|
// current information about the autoscaler.
|
||||||
|
optional HorizontalPodAutoscalerStatus status = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// list of horizontal pod autoscaler objects.
|
||||||
|
message HorizontalPodAutoscalerList {
|
||||||
|
// Standard list metadata.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
|
||||||
|
|
||||||
|
// list of horizontal pod autoscaler objects.
|
||||||
|
repeated HorizontalPodAutoscaler items = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// specification of a horizontal pod autoscaler.
|
||||||
|
message HorizontalPodAutoscalerSpec {
|
||||||
|
// reference to Scale subresource; horizontal pod autoscaler will learn the current resource consumption from its status,
|
||||||
|
// and will set the desired number of pods by modifying its spec.
|
||||||
|
optional SubresourceReference scaleRef = 1;
|
||||||
|
|
||||||
|
// lower limit for the number of pods that can be set by the autoscaler, default 1.
|
||||||
|
optional int32 minReplicas = 2;
|
||||||
|
|
||||||
|
// upper limit for the number of pods that can be set by the autoscaler; cannot be smaller than MinReplicas.
|
||||||
|
optional int32 maxReplicas = 3;
|
||||||
|
|
||||||
|
// target average CPU utilization (represented as a percentage of requested CPU) over all the pods;
|
||||||
|
// if not specified it defaults to the target CPU utilization at 80% of the requested resources.
|
||||||
|
optional CPUTargetUtilization cpuUtilization = 4;
|
||||||
|
}
|
||||||
|
|
||||||
|
// current status of a horizontal pod autoscaler
|
||||||
|
message HorizontalPodAutoscalerStatus {
|
||||||
|
// most recent generation observed by this autoscaler.
|
||||||
|
optional int64 observedGeneration = 1;
|
||||||
|
|
||||||
|
// last time the HorizontalPodAutoscaler scaled the number of pods;
|
||||||
|
// used by the autoscaler to control how often the number of pods is changed.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.Time lastScaleTime = 2;
|
||||||
|
|
||||||
|
// current number of replicas of pods managed by this autoscaler.
|
||||||
|
optional int32 currentReplicas = 3;
|
||||||
|
|
||||||
|
// desired number of replicas of pods managed by this autoscaler.
|
||||||
|
optional int32 desiredReplicas = 4;
|
||||||
|
|
||||||
|
// current average CPU utilization over all pods, represented as a percentage of requested CPU,
|
||||||
|
// e.g. 70 means that an average pod is using now 70% of its requested CPU.
|
||||||
|
optional int32 currentCPUUtilizationPercentage = 5;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Host Port Range defines a range of host ports that will be enabled by a policy
|
||||||
|
// for pods to use. It requires both the start and end to be defined.
|
||||||
|
message HostPortRange {
|
||||||
|
// min is the start of the range, inclusive.
|
||||||
|
optional int32 min = 1;
|
||||||
|
|
||||||
|
// max is the end of the range, inclusive.
|
||||||
|
optional int32 max = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ID Range provides a min/max of an allowed range of IDs.
|
||||||
|
message IDRange {
|
||||||
|
// Min is the start of the range, inclusive.
|
||||||
|
optional int64 min = 1;
|
||||||
|
|
||||||
|
// Max is the end of the range, inclusive.
|
||||||
|
optional int64 max = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Ingress is a collection of rules that allow inbound connections to reach the
|
||||||
|
// endpoints defined by a backend. An Ingress can be configured to give services
|
||||||
|
// externally-reachable urls, load balance traffic, terminate SSL, offer name
|
||||||
|
// based virtual hosting etc.
|
||||||
|
message Ingress {
|
||||||
|
// Standard object's metadata.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1;
|
||||||
|
|
||||||
|
// Spec is the desired state of the Ingress.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
|
optional IngressSpec spec = 2;
|
||||||
|
|
||||||
|
// Status is the current state of the Ingress.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
|
optional IngressStatus status = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// IngressBackend describes all endpoints for a given service and port.
|
||||||
|
message IngressBackend {
|
||||||
|
// Specifies the name of the referenced service.
|
||||||
|
optional string serviceName = 1;
|
||||||
|
|
||||||
|
// Specifies the port of the referenced service.
|
||||||
|
optional k8s.io.kubernetes.pkg.util.intstr.IntOrString servicePort = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// IngressList is a collection of Ingress.
|
||||||
|
message IngressList {
|
||||||
|
// Standard object's metadata.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
|
||||||
|
|
||||||
|
// Items is the list of Ingress.
|
||||||
|
repeated Ingress items = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// IngressRule represents the rules mapping the paths under a specified host to
|
||||||
|
// the related backend services. Incoming requests are first evaluated for a host
|
||||||
|
// match, then routed to the backend associated with the matching IngressRuleValue.
|
||||||
|
message IngressRule {
|
||||||
|
// Host is the fully qualified domain name of a network host, as defined
|
||||||
|
// by RFC 3986. Note the following deviations from the "host" part of the
|
||||||
|
// URI as defined in the RFC:
|
||||||
|
// 1. IPs are not allowed. Currently an IngressRuleValue can only apply to the
|
||||||
|
// IP in the Spec of the parent Ingress.
|
||||||
|
// 2. The `:` delimiter is not respected because ports are not allowed.
|
||||||
|
// Currently the port of an Ingress is implicitly :80 for http and
|
||||||
|
// :443 for https.
|
||||||
|
// Both these may change in the future.
|
||||||
|
// Incoming requests are matched against the host before the IngressRuleValue.
|
||||||
|
// If the host is unspecified, the Ingress routes all traffic based on the
|
||||||
|
// specified IngressRuleValue.
|
||||||
|
optional string host = 1;
|
||||||
|
|
||||||
|
// IngressRuleValue represents a rule to route requests for this IngressRule.
|
||||||
|
// If unspecified, the rule defaults to a http catch-all. Whether that sends
|
||||||
|
// just traffic matching the host to the default backend or all traffic to the
|
||||||
|
// default backend, is left to the controller fulfilling the Ingress. Http is
|
||||||
|
// currently the only supported IngressRuleValue.
|
||||||
|
optional IngressRuleValue ingressRuleValue = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// IngressRuleValue represents a rule to apply against incoming requests. If the
|
||||||
|
// rule is satisfied, the request is routed to the specified backend. Currently
|
||||||
|
// mixing different types of rules in a single Ingress is disallowed, so exactly
|
||||||
|
// one of the following must be set.
|
||||||
|
message IngressRuleValue {
|
||||||
|
optional HTTPIngressRuleValue http = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// IngressSpec describes the Ingress the user wishes to exist.
|
||||||
|
message IngressSpec {
|
||||||
|
// A default backend capable of servicing requests that don't match any
|
||||||
|
// rule. At least one of 'backend' or 'rules' must be specified. This field
|
||||||
|
// is optional to allow the loadbalancer controller or defaulting logic to
|
||||||
|
// specify a global default.
|
||||||
|
optional IngressBackend backend = 1;
|
||||||
|
|
||||||
|
// TLS configuration. Currently the Ingress only supports a single TLS
|
||||||
|
// port, 443. If multiple members of this list specify different hosts, they
|
||||||
|
// will be multiplexed on the same port according to the hostname specified
|
||||||
|
// through the SNI TLS extension, if the ingress controller fulfilling the
|
||||||
|
// ingress supports SNI.
|
||||||
|
repeated IngressTLS tls = 2;
|
||||||
|
|
||||||
|
// A list of host rules used to configure the Ingress. If unspecified, or
|
||||||
|
// no rule matches, all traffic is sent to the default backend.
|
||||||
|
repeated IngressRule rules = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// IngressStatus describe the current state of the Ingress.
|
||||||
|
message IngressStatus {
|
||||||
|
// LoadBalancer contains the current status of the load-balancer.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.LoadBalancerStatus loadBalancer = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// IngressTLS describes the transport layer security associated with an Ingress.
|
||||||
|
message IngressTLS {
|
||||||
|
// Hosts are a list of hosts included in the TLS certificate. The values in
|
||||||
|
// this list must match the name/s used in the tlsSecret. Defaults to the
|
||||||
|
// wildcard host setting for the loadbalancer controller fulfilling this
|
||||||
|
// Ingress, if left unspecified.
|
||||||
|
repeated string hosts = 1;
|
||||||
|
|
||||||
|
// SecretName is the name of the secret used to terminate SSL traffic on 443.
|
||||||
|
// Field is left optional to allow SSL routing based on SNI hostname alone.
|
||||||
|
// If the SNI host in a listener conflicts with the "Host" header field used
|
||||||
|
// by an IngressRule, the SNI host is used for termination and value of the
|
||||||
|
// Host header is used for routing.
|
||||||
|
optional string secretName = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Job represents the configuration of a single job.
|
||||||
|
message Job {
|
||||||
|
// Standard object's metadata.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1;
|
||||||
|
|
||||||
|
// 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
|
||||||
|
optional JobSpec spec = 2;
|
||||||
|
|
||||||
|
// 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
|
||||||
|
optional JobStatus status = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// JobCondition describes current state of a job.
|
||||||
|
message JobCondition {
|
||||||
|
// Type of job condition, Complete or Failed.
|
||||||
|
optional string type = 1;
|
||||||
|
|
||||||
|
// Status of the condition, one of True, False, Unknown.
|
||||||
|
optional string status = 2;
|
||||||
|
|
||||||
|
// Last time the condition was checked.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.Time lastProbeTime = 3;
|
||||||
|
|
||||||
|
// Last time the condition transit from one status to another.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTransitionTime = 4;
|
||||||
|
|
||||||
|
// (brief) reason for the condition's last transition.
|
||||||
|
optional string reason = 5;
|
||||||
|
|
||||||
|
// Human readable message indicating details about last transition.
|
||||||
|
optional string message = 6;
|
||||||
|
}
|
||||||
|
|
||||||
|
// JobList is a collection of jobs.
|
||||||
|
message JobList {
|
||||||
|
// Standard list metadata
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
|
||||||
|
|
||||||
|
// Items is the list of Job.
|
||||||
|
repeated Job items = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// JobSpec describes how the job execution will look like.
|
||||||
|
message JobSpec {
|
||||||
|
// Parallelism specifies the maximum desired number of pods the job should
|
||||||
|
// run at any given time. The actual number of pods running in steady state will
|
||||||
|
// be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism),
|
||||||
|
// i.e. when the work left to do is less than max parallelism.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
|
optional int32 parallelism = 1;
|
||||||
|
|
||||||
|
// Completions specifies the desired number of successfully finished pods the
|
||||||
|
// job should be run with. Setting to nil means that the success of any
|
||||||
|
// pod signals the success of all pods, and allows parallelism to have any positive
|
||||||
|
// value. Setting to 1 means that parallelism is limited to 1 and the success of that
|
||||||
|
// pod signals the success of the job.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
|
optional int32 completions = 2;
|
||||||
|
|
||||||
|
// Optional duration in seconds relative to the startTime that the job may be active
|
||||||
|
// before the system tries to terminate it; value must be positive integer
|
||||||
|
optional int64 activeDeadlineSeconds = 3;
|
||||||
|
|
||||||
|
// Selector is a label query over pods that should match the pod count.
|
||||||
|
// Normally, the system sets this field for you.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
|
optional LabelSelector selector = 4;
|
||||||
|
|
||||||
|
// AutoSelector controls generation of pod labels and pod selectors.
|
||||||
|
// It was not present in the original extensions/v1beta1 Job definition, but exists
|
||||||
|
// to allow conversion from batch/v1 Jobs, where it corresponds to, but has the opposite
|
||||||
|
// meaning as, ManualSelector.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md
|
||||||
|
optional bool autoSelector = 5;
|
||||||
|
|
||||||
|
// Template is the object that describes the pod that will be created when
|
||||||
|
// executing a job.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 6;
|
||||||
|
}
|
||||||
|
|
||||||
|
// JobStatus represents the current state of a Job.
|
||||||
|
message JobStatus {
|
||||||
|
// Conditions represent the latest available observations of an object's current state.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
|
repeated JobCondition conditions = 1;
|
||||||
|
|
||||||
|
// StartTime represents time when the job was acknowledged by the Job Manager.
|
||||||
|
// It is not guaranteed to be set in happens-before order across separate operations.
|
||||||
|
// It is represented in RFC3339 form and is in UTC.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.Time startTime = 2;
|
||||||
|
|
||||||
|
// CompletionTime represents time when the job was completed. It is not guaranteed to
|
||||||
|
// be set in happens-before order across separate operations.
|
||||||
|
// It is represented in RFC3339 form and is in UTC.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.Time completionTime = 3;
|
||||||
|
|
||||||
|
// Active is the number of actively running pods.
|
||||||
|
optional int32 active = 4;
|
||||||
|
|
||||||
|
// Succeeded is the number of pods which reached Phase Succeeded.
|
||||||
|
optional int32 succeeded = 5;
|
||||||
|
|
||||||
|
// Failed is the number of pods which reached Phase Failed.
|
||||||
|
optional int32 failed = 6;
|
||||||
|
}
|
||||||
|
|
||||||
|
// A label selector is a label query over a set of resources. The result of matchLabels and
|
||||||
|
// matchExpressions are ANDed. An empty label selector matches all objects. A null
|
||||||
|
// label selector matches no objects.
|
||||||
|
message LabelSelector {
|
||||||
|
// matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
|
||||||
|
// map is equivalent to an element of matchExpressions, whose key field is "key", the
|
||||||
|
// operator is "In", and the values array contains only "value". The requirements are ANDed.
|
||||||
|
map<string, string> matchLabels = 1;
|
||||||
|
|
||||||
|
// matchExpressions is a list of label selector requirements. The requirements are ANDed.
|
||||||
|
repeated LabelSelectorRequirement matchExpressions = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// A label selector requirement is a selector that contains values, a key, and an operator that
|
||||||
|
// relates the key and values.
|
||||||
|
message LabelSelectorRequirement {
|
||||||
|
// key is the label key that the selector applies to.
|
||||||
|
optional string key = 1;
|
||||||
|
|
||||||
|
// operator represents a key's relationship to a set of values.
|
||||||
|
// Valid operators ard In, NotIn, Exists and DoesNotExist.
|
||||||
|
optional string operator = 2;
|
||||||
|
|
||||||
|
// values is an array of string values. If the operator is In or NotIn,
|
||||||
|
// the values array must be non-empty. If the operator is Exists or DoesNotExist,
|
||||||
|
// the values array must be empty. This array is replaced during a strategic
|
||||||
|
// merge patch.
|
||||||
|
repeated string values = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ListOptions is the query options to a standard REST list call.
|
||||||
|
message ListOptions {
|
||||||
|
// A selector to restrict the list of returned objects by their labels.
|
||||||
|
// Defaults to everything.
|
||||||
|
optional string labelSelector = 1;
|
||||||
|
|
||||||
|
// A selector to restrict the list of returned objects by their fields.
|
||||||
|
// Defaults to everything.
|
||||||
|
optional string fieldSelector = 2;
|
||||||
|
|
||||||
|
// Watch for changes to the described resources and return them as a stream of
|
||||||
|
// add, update, and remove notifications. Specify resourceVersion.
|
||||||
|
optional bool watch = 3;
|
||||||
|
|
||||||
|
// When specified with a watch call, shows changes that occur after that particular version of a resource.
|
||||||
|
// Defaults to changes from the beginning of history.
|
||||||
|
optional string resourceVersion = 4;
|
||||||
|
|
||||||
|
// Timeout for the list/watch call.
|
||||||
|
optional int64 timeoutSeconds = 5;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Pod Security Policy governs the ability to make requests that affect the Security Context
|
||||||
|
// that will be applied to a pod and container.
|
||||||
|
message PodSecurityPolicy {
|
||||||
|
// Standard object's metadata.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1;
|
||||||
|
|
||||||
|
// spec defines the policy enforced.
|
||||||
|
optional PodSecurityPolicySpec spec = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Pod Security Policy List is a list of PodSecurityPolicy objects.
|
||||||
|
message PodSecurityPolicyList {
|
||||||
|
// Standard list metadata.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
|
||||||
|
|
||||||
|
// Items is a list of schema objects.
|
||||||
|
repeated PodSecurityPolicy items = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Pod Security Policy Spec defines the policy enforced.
|
||||||
|
message PodSecurityPolicySpec {
|
||||||
|
// privileged determines if a pod can request to be run as privileged.
|
||||||
|
optional bool privileged = 1;
|
||||||
|
|
||||||
|
// capabilities is a list of capabilities that can be added.
|
||||||
|
repeated string capabilities = 2;
|
||||||
|
|
||||||
|
// volumes is a white list of allowed volume plugins. Empty indicates that all plugins
|
||||||
|
// may be used.
|
||||||
|
repeated string volumes = 3;
|
||||||
|
|
||||||
|
// hostNetwork determines if the policy allows the use of HostNetwork in the pod spec.
|
||||||
|
optional bool hostNetwork = 4;
|
||||||
|
|
||||||
|
// hostPorts determines which host port ranges are allowed to be exposed.
|
||||||
|
repeated HostPortRange hostPorts = 5;
|
||||||
|
|
||||||
|
// hostPID determines if the policy allows the use of HostPID in the pod spec.
|
||||||
|
optional bool hostPID = 6;
|
||||||
|
|
||||||
|
// hostIPC determines if the policy allows the use of HostIPC in the pod spec.
|
||||||
|
optional bool hostIPC = 7;
|
||||||
|
|
||||||
|
// seLinux is the strategy that will dictate the allowable labels that may be set.
|
||||||
|
optional SELinuxStrategyOptions seLinux = 8;
|
||||||
|
|
||||||
|
// runAsUser is the strategy that will dictate the allowable RunAsUser values that may be set.
|
||||||
|
optional RunAsUserStrategyOptions runAsUser = 9;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ReplicaSet represents the configuration of a ReplicaSet.
|
||||||
|
message ReplicaSet {
|
||||||
|
// If the Labels of a ReplicaSet are empty, they are defaulted to
|
||||||
|
// be the same as the Pod(s) that the ReplicaSet manages.
|
||||||
|
// Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1;
|
||||||
|
|
||||||
|
// Spec defines the specification of the desired behavior of the ReplicaSet.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
|
optional ReplicaSetSpec spec = 2;
|
||||||
|
|
||||||
|
// Status is the most recently observed status of the ReplicaSet.
|
||||||
|
// This data may be out of date by some window of time.
|
||||||
|
// Populated by the system.
|
||||||
|
// Read-only.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
|
optional ReplicaSetStatus status = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ReplicaSetList is a collection of ReplicaSets.
|
||||||
|
message ReplicaSetList {
|
||||||
|
// Standard list metadata.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
|
||||||
|
|
||||||
|
// List of ReplicaSets.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md
|
||||||
|
repeated ReplicaSet items = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ReplicaSetSpec is the specification of a ReplicaSet.
|
||||||
|
message ReplicaSetSpec {
|
||||||
|
// Replicas is the number of desired replicas.
|
||||||
|
// This is a pointer to distinguish between explicit zero and unspecified.
|
||||||
|
// Defaults to 1.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#what-is-a-replication-controller
|
||||||
|
optional int32 replicas = 1;
|
||||||
|
|
||||||
|
// Selector is a label query over pods that should match the replica count.
|
||||||
|
// If the selector is empty, it is defaulted to the labels present on the pod template.
|
||||||
|
// Label keys and values that must match in order to be controlled by this replica set.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
|
optional LabelSelector selector = 2;
|
||||||
|
|
||||||
|
// Template is the object that describes the pod that will be created if
|
||||||
|
// insufficient replicas are detected.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#pod-template
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ReplicaSetStatus represents the current status of a ReplicaSet.
|
||||||
|
message ReplicaSetStatus {
|
||||||
|
// Replicas is the most recently oberved number of replicas.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#what-is-a-replication-controller
|
||||||
|
optional int32 replicas = 1;
|
||||||
|
|
||||||
|
// The number of pods that have labels matching the labels of the pod template of the replicaset.
|
||||||
|
optional int32 fullyLabeledReplicas = 2;
|
||||||
|
|
||||||
|
// ObservedGeneration reflects the generation of the most recently observed ReplicaSet.
|
||||||
|
optional int64 observedGeneration = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Dummy definition
|
||||||
|
message ReplicationControllerDummy {
|
||||||
|
}
|
||||||
|
|
||||||
|
message RollbackConfig {
|
||||||
|
// The revision to rollback to. If set to 0, rollbck to the last revision.
|
||||||
|
optional int64 revision = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Spec to control the desired behavior of rolling update.
|
||||||
|
message RollingUpdateDeployment {
|
||||||
|
// The maximum number of pods that can be unavailable during the update.
|
||||||
|
// Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%).
|
||||||
|
// Absolute number is calculated from percentage by rounding up.
|
||||||
|
// This can not be 0 if MaxSurge is 0.
|
||||||
|
// By default, a fixed value of 1 is used.
|
||||||
|
// Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods
|
||||||
|
// immediately when the rolling update starts. Once new pods are ready, old RC
|
||||||
|
// can be scaled down further, followed by scaling up the new RC, ensuring
|
||||||
|
// that the total number of pods available at all times during the update is at
|
||||||
|
// least 70% of desired pods.
|
||||||
|
optional k8s.io.kubernetes.pkg.util.intstr.IntOrString maxUnavailable = 1;
|
||||||
|
|
||||||
|
// The maximum number of pods that can be scheduled above the desired number of
|
||||||
|
// pods.
|
||||||
|
// Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%).
|
||||||
|
// This can not be 0 if MaxUnavailable is 0.
|
||||||
|
// Absolute number is calculated from percentage by rounding up.
|
||||||
|
// By default, a value of 1 is used.
|
||||||
|
// Example: when this is set to 30%, the new RC can be scaled up immediately when
|
||||||
|
// the rolling update starts, such that the total number of old and new pods do not exceed
|
||||||
|
// 130% of desired pods. Once old pods have been killed,
|
||||||
|
// new RC can be scaled up further, ensuring that total number of pods running
|
||||||
|
// at any time during the update is atmost 130% of desired pods.
|
||||||
|
optional k8s.io.kubernetes.pkg.util.intstr.IntOrString maxSurge = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Run A sUser Strategy Options defines the strategy type and any options used to create the strategy.
|
||||||
|
message RunAsUserStrategyOptions {
|
||||||
|
// Rule is the strategy that will dictate the allowable RunAsUser values that may be set.
|
||||||
|
optional string rule = 1;
|
||||||
|
|
||||||
|
// Ranges are the allowed ranges of uids that may be used.
|
||||||
|
repeated IDRange ranges = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// SELinux Strategy Options defines the strategy type and any options used to create the strategy.
|
||||||
|
message SELinuxStrategyOptions {
|
||||||
|
// type is the strategy that will dictate the allowable labels that may be set.
|
||||||
|
optional string rule = 1;
|
||||||
|
|
||||||
|
// seLinuxOptions required to run as; required for MustRunAs
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/design/security_context.md#security-context
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.SELinuxOptions seLinuxOptions = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// represents a scaling request for a resource.
|
||||||
|
message Scale {
|
||||||
|
// Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1;
|
||||||
|
|
||||||
|
// defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.
|
||||||
|
optional ScaleSpec spec = 2;
|
||||||
|
|
||||||
|
// current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only.
|
||||||
|
optional ScaleStatus status = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// describes the attributes of a scale subresource
|
||||||
|
message ScaleSpec {
|
||||||
|
// desired number of instances for the scaled object.
|
||||||
|
optional int32 replicas = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// represents the current status of a scale subresource.
|
||||||
|
message ScaleStatus {
|
||||||
|
// actual number of observed instances of the scaled object.
|
||||||
|
optional int32 replicas = 1;
|
||||||
|
|
||||||
|
// label query over pods that should match the replicas count. More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
|
map<string, string> selector = 2;
|
||||||
|
|
||||||
|
// label selector for pods that should match the replicas count. This is a serializated
|
||||||
|
// version of both map-based and more expressive set-based selectors. This is done to
|
||||||
|
// avoid introspection in the clients. The string will be in the same format as the
|
||||||
|
// query-param syntax. If the target type only supports map-based selectors, both this
|
||||||
|
// field and map-based selector field are populated.
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
|
optional string targetSelector = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// SubresourceReference contains enough information to let you inspect or modify the referred subresource.
|
||||||
|
message SubresourceReference {
|
||||||
|
// Kind of the referent; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds"
|
||||||
|
optional string kind = 1;
|
||||||
|
|
||||||
|
// Name of the referent; More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
|
||||||
|
optional string name = 2;
|
||||||
|
|
||||||
|
// API version of the referent
|
||||||
|
optional string apiVersion = 3;
|
||||||
|
|
||||||
|
// Subresource name of the referent
|
||||||
|
optional string subresource = 4;
|
||||||
|
}
|
||||||
|
|
||||||
|
// A ThirdPartyResource is a generic representation of a resource, it is used by add-ons and plugins to add new resource
|
||||||
|
// types to the API. It consists of one or more Versions of the api.
|
||||||
|
message ThirdPartyResource {
|
||||||
|
// Standard object metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1;
|
||||||
|
|
||||||
|
// Description is the description of this object.
|
||||||
|
optional string description = 2;
|
||||||
|
|
||||||
|
// Versions are versions for this third party object
|
||||||
|
repeated APIVersion versions = 3;
|
||||||
|
}
|
||||||
|
|
||||||
|
// An internal object, used for versioned storage in etcd. Not exposed to the end user.
|
||||||
|
message ThirdPartyResourceData {
|
||||||
|
// Standard object metadata.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1;
|
||||||
|
|
||||||
|
// Data is the raw JSON data for this data.
|
||||||
|
optional bytes data = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ThirdPartyResrouceDataList is a list of ThirdPartyResourceData.
|
||||||
|
message ThirdPartyResourceDataList {
|
||||||
|
// Standard list metadata
|
||||||
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
|
||||||
|
|
||||||
|
// Items is the list of ThirdpartyResourceData.
|
||||||
|
repeated ThirdPartyResourceData items = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ThirdPartyResourceList is a list of ThirdPartyResources.
|
||||||
|
message ThirdPartyResourceList {
|
||||||
|
// Standard list metadata.
|
||||||
|
optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1;
|
||||||
|
|
||||||
|
// Items is the list of ThirdPartyResources.
|
||||||
|
repeated ThirdPartyResource items = 2;
|
||||||
|
}
|
||||||
|
|
@@ -26,16 +26,16 @@ import (
|
|||||||
// describes the attributes of a scale subresource
|
// describes the attributes of a scale subresource
|
||||||
type ScaleSpec struct {
|
type ScaleSpec struct {
|
||||||
// desired number of instances for the scaled object.
|
// desired number of instances for the scaled object.
|
||||||
Replicas int32 `json:"replicas,omitempty"`
|
Replicas int32 `json:"replicas,omitempty" protobuf:"varint,1,opt,name=replicas"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// represents the current status of a scale subresource.
|
// represents the current status of a scale subresource.
|
||||||
type ScaleStatus struct {
|
type ScaleStatus struct {
|
||||||
// actual number of observed instances of the scaled object.
|
// actual number of observed instances of the scaled object.
|
||||||
Replicas int32 `json:"replicas"`
|
Replicas int32 `json:"replicas" protobuf:"varint,1,opt,name=replicas"`
|
||||||
|
|
||||||
// label query over pods that should match the replicas count. More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
// label query over pods that should match the replicas count. More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
Selector map[string]string `json:"selector,omitempty"`
|
Selector map[string]string `json:"selector,omitempty" protobuf:"bytes,2,rep,name=selector"`
|
||||||
|
|
||||||
// label selector for pods that should match the replicas count. This is a serializated
|
// label selector for pods that should match the replicas count. This is a serializated
|
||||||
// version of both map-based and more expressive set-based selectors. This is done to
|
// version of both map-based and more expressive set-based selectors. This is done to
|
||||||
@@ -43,7 +43,7 @@ type ScaleStatus struct {
|
|||||||
// query-param syntax. If the target type only supports map-based selectors, both this
|
// query-param syntax. If the target type only supports map-based selectors, both this
|
||||||
// field and map-based selector field are populated.
|
// field and map-based selector field are populated.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
TargetSelector string `json:"targetSelector,omitempty"`
|
TargetSelector string `json:"targetSelector,omitempty" protobuf:"bytes,3,opt,name=targetSelector"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient=true,noMethods=true
|
// +genclient=true,noMethods=true
|
||||||
@@ -52,13 +52,13 @@ type ScaleStatus struct {
|
|||||||
type Scale struct {
|
type Scale struct {
|
||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.
|
// Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.
|
||||||
v1.ObjectMeta `json:"metadata,omitempty"`
|
v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.
|
// defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.
|
||||||
Spec ScaleSpec `json:"spec,omitempty"`
|
Spec ScaleSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
||||||
|
|
||||||
// current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only.
|
// current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only.
|
||||||
Status ScaleStatus `json:"status,omitempty"`
|
Status ScaleStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Dummy definition
|
// Dummy definition
|
||||||
@@ -69,76 +69,76 @@ type ReplicationControllerDummy struct {
|
|||||||
// SubresourceReference contains enough information to let you inspect or modify the referred subresource.
|
// SubresourceReference contains enough information to let you inspect or modify the referred subresource.
|
||||||
type SubresourceReference struct {
|
type SubresourceReference struct {
|
||||||
// Kind of the referent; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds"
|
// Kind of the referent; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds"
|
||||||
Kind string `json:"kind,omitempty"`
|
Kind string `json:"kind,omitempty" protobuf:"bytes,1,opt,name=kind"`
|
||||||
// Name of the referent; More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
|
// Name of the referent; More info: http://releases.k8s.io/HEAD/docs/user-guide/identifiers.md#names
|
||||||
Name string `json:"name,omitempty"`
|
Name string `json:"name,omitempty" protobuf:"bytes,2,opt,name=name"`
|
||||||
// API version of the referent
|
// API version of the referent
|
||||||
APIVersion string `json:"apiVersion,omitempty"`
|
APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,3,opt,name=apiVersion"`
|
||||||
// Subresource name of the referent
|
// Subresource name of the referent
|
||||||
Subresource string `json:"subresource,omitempty"`
|
Subresource string `json:"subresource,omitempty" protobuf:"bytes,4,opt,name=subresource"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type CPUTargetUtilization struct {
|
type CPUTargetUtilization struct {
|
||||||
// fraction of the requested CPU that should be utilized/used,
|
// fraction of the requested CPU that should be utilized/used,
|
||||||
// e.g. 70 means that 70% of the requested CPU should be in use.
|
// e.g. 70 means that 70% of the requested CPU should be in use.
|
||||||
TargetPercentage int32 `json:"targetPercentage"`
|
TargetPercentage int32 `json:"targetPercentage" protobuf:"varint,1,opt,name=targetPercentage"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Alpha-level support for Custom Metrics in HPA (as annotations).
|
// Alpha-level support for Custom Metrics in HPA (as annotations).
|
||||||
type CustomMetricTarget struct {
|
type CustomMetricTarget struct {
|
||||||
// Custom Metric name.
|
// Custom Metric name.
|
||||||
Name string `json:"name"`
|
Name string `json:"name" protobuf:"bytes,1,opt,name=name"`
|
||||||
// Custom Metric value (average).
|
// Custom Metric value (average).
|
||||||
TargetValue resource.Quantity `json:"value"`
|
TargetValue resource.Quantity `json:"value" protobuf:"bytes,2,opt,name=value"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type CustomMetricTargetList struct {
|
type CustomMetricTargetList struct {
|
||||||
Items []CustomMetricTarget `json:"items"`
|
Items []CustomMetricTarget `json:"items" protobuf:"bytes,1,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type CustomMetricCurrentStatus struct {
|
type CustomMetricCurrentStatus struct {
|
||||||
// Custom Metric name.
|
// Custom Metric name.
|
||||||
Name string `json:"name"`
|
Name string `json:"name" protobuf:"bytes,1,opt,name=name"`
|
||||||
// Custom Metric value (average).
|
// Custom Metric value (average).
|
||||||
CurrentValue resource.Quantity `json:"value"`
|
CurrentValue resource.Quantity `json:"value" protobuf:"bytes,2,opt,name=value"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type CustomMetricCurrentStatusList struct {
|
type CustomMetricCurrentStatusList struct {
|
||||||
Items []CustomMetricCurrentStatus `json:"items"`
|
Items []CustomMetricCurrentStatus `json:"items" protobuf:"bytes,1,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// specification of a horizontal pod autoscaler.
|
// specification of a horizontal pod autoscaler.
|
||||||
type HorizontalPodAutoscalerSpec struct {
|
type HorizontalPodAutoscalerSpec struct {
|
||||||
// reference to Scale subresource; horizontal pod autoscaler will learn the current resource consumption from its status,
|
// reference to Scale subresource; horizontal pod autoscaler will learn the current resource consumption from its status,
|
||||||
// and will set the desired number of pods by modifying its spec.
|
// and will set the desired number of pods by modifying its spec.
|
||||||
ScaleRef SubresourceReference `json:"scaleRef"`
|
ScaleRef SubresourceReference `json:"scaleRef" protobuf:"bytes,1,opt,name=scaleRef"`
|
||||||
// lower limit for the number of pods that can be set by the autoscaler, default 1.
|
// lower limit for the number of pods that can be set by the autoscaler, default 1.
|
||||||
MinReplicas *int32 `json:"minReplicas,omitempty"`
|
MinReplicas *int32 `json:"minReplicas,omitempty" protobuf:"varint,2,opt,name=minReplicas"`
|
||||||
// upper limit for the number of pods that can be set by the autoscaler; cannot be smaller than MinReplicas.
|
// upper limit for the number of pods that can be set by the autoscaler; cannot be smaller than MinReplicas.
|
||||||
MaxReplicas int32 `json:"maxReplicas"`
|
MaxReplicas int32 `json:"maxReplicas" protobuf:"varint,3,opt,name=maxReplicas"`
|
||||||
// target average CPU utilization (represented as a percentage of requested CPU) over all the pods;
|
// target average CPU utilization (represented as a percentage of requested CPU) over all the pods;
|
||||||
// if not specified it defaults to the target CPU utilization at 80% of the requested resources.
|
// if not specified it defaults to the target CPU utilization at 80% of the requested resources.
|
||||||
CPUUtilization *CPUTargetUtilization `json:"cpuUtilization,omitempty"`
|
CPUUtilization *CPUTargetUtilization `json:"cpuUtilization,omitempty" protobuf:"bytes,4,opt,name=cpuUtilization"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// current status of a horizontal pod autoscaler
|
// current status of a horizontal pod autoscaler
|
||||||
type HorizontalPodAutoscalerStatus struct {
|
type HorizontalPodAutoscalerStatus struct {
|
||||||
// most recent generation observed by this autoscaler.
|
// most recent generation observed by this autoscaler.
|
||||||
ObservedGeneration *int64 `json:"observedGeneration,omitempty"`
|
ObservedGeneration *int64 `json:"observedGeneration,omitempty" protobuf:"varint,1,opt,name=observedGeneration"`
|
||||||
|
|
||||||
// last time the HorizontalPodAutoscaler scaled the number of pods;
|
// last time the HorizontalPodAutoscaler scaled the number of pods;
|
||||||
// used by the autoscaler to control how often the number of pods is changed.
|
// used by the autoscaler to control how often the number of pods is changed.
|
||||||
LastScaleTime *unversioned.Time `json:"lastScaleTime,omitempty"`
|
LastScaleTime *unversioned.Time `json:"lastScaleTime,omitempty" protobuf:"bytes,2,opt,name=lastScaleTime"`
|
||||||
|
|
||||||
// current number of replicas of pods managed by this autoscaler.
|
// current number of replicas of pods managed by this autoscaler.
|
||||||
CurrentReplicas int32 `json:"currentReplicas"`
|
CurrentReplicas int32 `json:"currentReplicas" protobuf:"varint,3,opt,name=currentReplicas"`
|
||||||
|
|
||||||
// desired number of replicas of pods managed by this autoscaler.
|
// desired number of replicas of pods managed by this autoscaler.
|
||||||
DesiredReplicas int32 `json:"desiredReplicas"`
|
DesiredReplicas int32 `json:"desiredReplicas" protobuf:"varint,4,opt,name=desiredReplicas"`
|
||||||
|
|
||||||
// current average CPU utilization over all pods, represented as a percentage of requested CPU,
|
// current average CPU utilization over all pods, represented as a percentage of requested CPU,
|
||||||
// e.g. 70 means that an average pod is using now 70% of its requested CPU.
|
// e.g. 70 means that an average pod is using now 70% of its requested CPU.
|
||||||
CurrentCPUUtilizationPercentage *int32 `json:"currentCPUUtilizationPercentage,omitempty"`
|
CurrentCPUUtilizationPercentage *int32 `json:"currentCPUUtilizationPercentage,omitempty" protobuf:"varint,5,opt,name=currentCPUUtilizationPercentage"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient=true
|
// +genclient=true
|
||||||
@@ -147,23 +147,23 @@ type HorizontalPodAutoscalerStatus struct {
|
|||||||
type HorizontalPodAutoscaler struct {
|
type HorizontalPodAutoscaler struct {
|
||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// Standard object metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
// Standard object metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
v1.ObjectMeta `json:"metadata,omitempty"`
|
v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// behaviour of autoscaler. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.
|
// behaviour of autoscaler. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.
|
||||||
Spec HorizontalPodAutoscalerSpec `json:"spec,omitempty"`
|
Spec HorizontalPodAutoscalerSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
||||||
|
|
||||||
// current information about the autoscaler.
|
// current information about the autoscaler.
|
||||||
Status HorizontalPodAutoscalerStatus `json:"status,omitempty"`
|
Status HorizontalPodAutoscalerStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// list of horizontal pod autoscaler objects.
|
// list of horizontal pod autoscaler objects.
|
||||||
type HorizontalPodAutoscalerList struct {
|
type HorizontalPodAutoscalerList struct {
|
||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// Standard list metadata.
|
// Standard list metadata.
|
||||||
unversioned.ListMeta `json:"metadata,omitempty"`
|
unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// list of horizontal pod autoscaler objects.
|
// list of horizontal pod autoscaler objects.
|
||||||
Items []HorizontalPodAutoscaler `json:"items"`
|
Items []HorizontalPodAutoscaler `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient=true
|
// +genclient=true
|
||||||
@@ -174,13 +174,13 @@ type ThirdPartyResource struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
|
|
||||||
// Standard object metadata
|
// Standard object metadata
|
||||||
v1.ObjectMeta `json:"metadata,omitempty"`
|
v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Description is the description of this object.
|
// Description is the description of this object.
|
||||||
Description string `json:"description,omitempty"`
|
Description string `json:"description,omitempty" protobuf:"bytes,2,opt,name=description"`
|
||||||
|
|
||||||
// Versions are versions for this third party object
|
// Versions are versions for this third party object
|
||||||
Versions []APIVersion `json:"versions,omitempty"`
|
Versions []APIVersion `json:"versions,omitempty" protobuf:"bytes,3,rep,name=versions"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ThirdPartyResourceList is a list of ThirdPartyResources.
|
// ThirdPartyResourceList is a list of ThirdPartyResources.
|
||||||
@@ -188,26 +188,26 @@ type ThirdPartyResourceList struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
|
|
||||||
// Standard list metadata.
|
// Standard list metadata.
|
||||||
unversioned.ListMeta `json:"metadata,omitempty"`
|
unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Items is the list of ThirdPartyResources.
|
// Items is the list of ThirdPartyResources.
|
||||||
Items []ThirdPartyResource `json:"items"`
|
Items []ThirdPartyResource `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// An APIVersion represents a single concrete version of an object model.
|
// An APIVersion represents a single concrete version of an object model.
|
||||||
type APIVersion struct {
|
type APIVersion struct {
|
||||||
// Name of this version (e.g. 'v1').
|
// Name of this version (e.g. 'v1').
|
||||||
Name string `json:"name,omitempty"`
|
Name string `json:"name,omitempty" protobuf:"bytes,1,opt,name=name"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// An internal object, used for versioned storage in etcd. Not exposed to the end user.
|
// An internal object, used for versioned storage in etcd. Not exposed to the end user.
|
||||||
type ThirdPartyResourceData struct {
|
type ThirdPartyResourceData struct {
|
||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// Standard object metadata.
|
// Standard object metadata.
|
||||||
v1.ObjectMeta `json:"metadata,omitempty"`
|
v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Data is the raw JSON data for this data.
|
// Data is the raw JSON data for this data.
|
||||||
Data []byte `json:"data,omitempty"`
|
Data []byte `json:"data,omitempty" protobuf:"bytes,2,opt,name=data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient=true
|
// +genclient=true
|
||||||
@@ -216,61 +216,61 @@ type ThirdPartyResourceData struct {
|
|||||||
type Deployment struct {
|
type Deployment struct {
|
||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// Standard object metadata.
|
// Standard object metadata.
|
||||||
v1.ObjectMeta `json:"metadata,omitempty"`
|
v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Specification of the desired behavior of the Deployment.
|
// Specification of the desired behavior of the Deployment.
|
||||||
Spec DeploymentSpec `json:"spec,omitempty"`
|
Spec DeploymentSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
||||||
|
|
||||||
// Most recently observed status of the Deployment.
|
// Most recently observed status of the Deployment.
|
||||||
Status DeploymentStatus `json:"status,omitempty"`
|
Status DeploymentStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// DeploymentSpec is the specification of the desired behavior of the Deployment.
|
// DeploymentSpec is the specification of the desired behavior of the Deployment.
|
||||||
type DeploymentSpec struct {
|
type DeploymentSpec struct {
|
||||||
// Number of desired pods. This is a pointer to distinguish between explicit
|
// Number of desired pods. This is a pointer to distinguish between explicit
|
||||||
// zero and not specified. Defaults to 1.
|
// zero and not specified. Defaults to 1.
|
||||||
Replicas *int32 `json:"replicas,omitempty"`
|
Replicas *int32 `json:"replicas,omitempty" protobuf:"varint,1,opt,name=replicas"`
|
||||||
|
|
||||||
// Label selector for pods. Existing ReplicaSets whose pods are
|
// Label selector for pods. Existing ReplicaSets whose pods are
|
||||||
// selected by this will be the ones affected by this deployment.
|
// selected by this will be the ones affected by this deployment.
|
||||||
Selector *LabelSelector `json:"selector,omitempty"`
|
Selector *LabelSelector `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"`
|
||||||
|
|
||||||
// Template describes the pods that will be created.
|
// Template describes the pods that will be created.
|
||||||
Template v1.PodTemplateSpec `json:"template"`
|
Template v1.PodTemplateSpec `json:"template" protobuf:"bytes,3,opt,name=template"`
|
||||||
|
|
||||||
// The deployment strategy to use to replace existing pods with new ones.
|
// The deployment strategy to use to replace existing pods with new ones.
|
||||||
Strategy DeploymentStrategy `json:"strategy,omitempty"`
|
Strategy DeploymentStrategy `json:"strategy,omitempty" protobuf:"bytes,4,opt,name=strategy"`
|
||||||
|
|
||||||
// Minimum number of seconds for which a newly created pod should be ready
|
// Minimum number of seconds for which a newly created pod should be ready
|
||||||
// without any of its container crashing, for it to be considered available.
|
// without any of its container crashing, for it to be considered available.
|
||||||
// Defaults to 0 (pod will be considered available as soon as it is ready)
|
// Defaults to 0 (pod will be considered available as soon as it is ready)
|
||||||
MinReadySeconds int32 `json:"minReadySeconds,omitempty"`
|
MinReadySeconds int32 `json:"minReadySeconds,omitempty" protobuf:"varint,5,opt,name=minReadySeconds"`
|
||||||
|
|
||||||
// The number of old ReplicaSets to retain to allow rollback.
|
// The number of old ReplicaSets to retain to allow rollback.
|
||||||
// This is a pointer to distinguish between explicit zero and not specified.
|
// This is a pointer to distinguish between explicit zero and not specified.
|
||||||
RevisionHistoryLimit *int32 `json:"revisionHistoryLimit,omitempty"`
|
RevisionHistoryLimit *int32 `json:"revisionHistoryLimit,omitempty" protobuf:"varint,6,opt,name=revisionHistoryLimit"`
|
||||||
|
|
||||||
// Indicates that the deployment is paused and will not be processed by the
|
// Indicates that the deployment is paused and will not be processed by the
|
||||||
// deployment controller.
|
// deployment controller.
|
||||||
Paused bool `json:"paused,omitempty"`
|
Paused bool `json:"paused,omitempty" protobuf:"varint,7,opt,name=paused"`
|
||||||
// The config this deployment is rolling back to. Will be cleared after rollback is done.
|
// The config this deployment is rolling back to. Will be cleared after rollback is done.
|
||||||
RollbackTo *RollbackConfig `json:"rollbackTo,omitempty"`
|
RollbackTo *RollbackConfig `json:"rollbackTo,omitempty" protobuf:"bytes,8,opt,name=rollbackTo"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// DeploymentRollback stores the information required to rollback a deployment.
|
// DeploymentRollback stores the information required to rollback a deployment.
|
||||||
type DeploymentRollback struct {
|
type DeploymentRollback struct {
|
||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// Required: This must match the Name of a deployment.
|
// Required: This must match the Name of a deployment.
|
||||||
Name string `json:"name"`
|
Name string `json:"name" protobuf:"bytes,1,opt,name=name"`
|
||||||
// The annotations to be updated to a deployment
|
// The annotations to be updated to a deployment
|
||||||
UpdatedAnnotations map[string]string `json:"updatedAnnotations,omitempty"`
|
UpdatedAnnotations map[string]string `json:"updatedAnnotations,omitempty" protobuf:"bytes,2,rep,name=updatedAnnotations"`
|
||||||
// The config of this deployment rollback.
|
// The config of this deployment rollback.
|
||||||
RollbackTo RollbackConfig `json:"rollbackTo"`
|
RollbackTo RollbackConfig `json:"rollbackTo" protobuf:"bytes,3,opt,name=rollbackTo"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type RollbackConfig struct {
|
type RollbackConfig struct {
|
||||||
// The revision to rollback to. If set to 0, rollbck to the last revision.
|
// The revision to rollback to. If set to 0, rollbck to the last revision.
|
||||||
Revision int64 `json:"revision,omitempty"`
|
Revision int64 `json:"revision,omitempty" protobuf:"varint,1,opt,name=revision"`
|
||||||
}
|
}
|
||||||
|
|
||||||
const (
|
const (
|
||||||
@@ -283,14 +283,14 @@ const (
|
|||||||
// DeploymentStrategy describes how to replace existing pods with new ones.
|
// DeploymentStrategy describes how to replace existing pods with new ones.
|
||||||
type DeploymentStrategy struct {
|
type DeploymentStrategy struct {
|
||||||
// Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate.
|
// Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate.
|
||||||
Type DeploymentStrategyType `json:"type,omitempty"`
|
Type DeploymentStrategyType `json:"type,omitempty" protobuf:"bytes,1,opt,name=type,casttype=DeploymentStrategyType"`
|
||||||
|
|
||||||
// Rolling update config params. Present only if DeploymentStrategyType =
|
// Rolling update config params. Present only if DeploymentStrategyType =
|
||||||
// RollingUpdate.
|
// RollingUpdate.
|
||||||
//---
|
//---
|
||||||
// TODO: Update this to follow our convention for oneOf, whatever we decide it
|
// TODO: Update this to follow our convention for oneOf, whatever we decide it
|
||||||
// to be.
|
// to be.
|
||||||
RollingUpdate *RollingUpdateDeployment `json:"rollingUpdate,omitempty"`
|
RollingUpdate *RollingUpdateDeployment `json:"rollingUpdate,omitempty" protobuf:"bytes,2,opt,name=rollingUpdate"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type DeploymentStrategyType string
|
type DeploymentStrategyType string
|
||||||
@@ -315,7 +315,7 @@ type RollingUpdateDeployment struct {
|
|||||||
// can be scaled down further, followed by scaling up the new RC, ensuring
|
// can be scaled down further, followed by scaling up the new RC, ensuring
|
||||||
// that the total number of pods available at all times during the update is at
|
// that the total number of pods available at all times during the update is at
|
||||||
// least 70% of desired pods.
|
// least 70% of desired pods.
|
||||||
MaxUnavailable *intstr.IntOrString `json:"maxUnavailable,omitempty"`
|
MaxUnavailable *intstr.IntOrString `json:"maxUnavailable,omitempty" protobuf:"bytes,1,opt,name=maxUnavailable"`
|
||||||
|
|
||||||
// The maximum number of pods that can be scheduled above the desired number of
|
// The maximum number of pods that can be scheduled above the desired number of
|
||||||
// pods.
|
// pods.
|
||||||
@@ -328,35 +328,35 @@ type RollingUpdateDeployment struct {
|
|||||||
// 130% of desired pods. Once old pods have been killed,
|
// 130% of desired pods. Once old pods have been killed,
|
||||||
// new RC can be scaled up further, ensuring that total number of pods running
|
// new RC can be scaled up further, ensuring that total number of pods running
|
||||||
// at any time during the update is atmost 130% of desired pods.
|
// at any time during the update is atmost 130% of desired pods.
|
||||||
MaxSurge *intstr.IntOrString `json:"maxSurge,omitempty"`
|
MaxSurge *intstr.IntOrString `json:"maxSurge,omitempty" protobuf:"bytes,2,opt,name=maxSurge"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// DeploymentStatus is the most recently observed status of the Deployment.
|
// DeploymentStatus is the most recently observed status of the Deployment.
|
||||||
type DeploymentStatus struct {
|
type DeploymentStatus struct {
|
||||||
// The generation observed by the deployment controller.
|
// The generation observed by the deployment controller.
|
||||||
ObservedGeneration int64 `json:"observedGeneration,omitempty"`
|
ObservedGeneration int64 `json:"observedGeneration,omitempty" protobuf:"varint,1,opt,name=observedGeneration"`
|
||||||
|
|
||||||
// Total number of non-terminated pods targeted by this deployment (their labels match the selector).
|
// Total number of non-terminated pods targeted by this deployment (their labels match the selector).
|
||||||
Replicas int32 `json:"replicas,omitempty"`
|
Replicas int32 `json:"replicas,omitempty" protobuf:"varint,2,opt,name=replicas"`
|
||||||
|
|
||||||
// Total number of non-terminated pods targeted by this deployment that have the desired template spec.
|
// Total number of non-terminated pods targeted by this deployment that have the desired template spec.
|
||||||
UpdatedReplicas int32 `json:"updatedReplicas,omitempty"`
|
UpdatedReplicas int32 `json:"updatedReplicas,omitempty" protobuf:"varint,3,opt,name=updatedReplicas"`
|
||||||
|
|
||||||
// Total number of available pods (ready for at least minReadySeconds) targeted by this deployment.
|
// Total number of available pods (ready for at least minReadySeconds) targeted by this deployment.
|
||||||
AvailableReplicas int32 `json:"availableReplicas,omitempty"`
|
AvailableReplicas int32 `json:"availableReplicas,omitempty" protobuf:"varint,4,opt,name=availableReplicas"`
|
||||||
|
|
||||||
// Total number of unavailable pods targeted by this deployment.
|
// Total number of unavailable pods targeted by this deployment.
|
||||||
UnavailableReplicas int32 `json:"unavailableReplicas,omitempty"`
|
UnavailableReplicas int32 `json:"unavailableReplicas,omitempty" protobuf:"varint,5,opt,name=unavailableReplicas"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// DeploymentList is a list of Deployments.
|
// DeploymentList is a list of Deployments.
|
||||||
type DeploymentList struct {
|
type DeploymentList struct {
|
||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// Standard list metadata.
|
// Standard list metadata.
|
||||||
unversioned.ListMeta `json:"metadata,omitempty"`
|
unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Items is the list of Deployments.
|
// Items is the list of Deployments.
|
||||||
Items []Deployment `json:"items"`
|
Items []Deployment `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO(madhusudancs): Uncomment while implementing DaemonSet updates.
|
// TODO(madhusudancs): Uncomment while implementing DaemonSet updates.
|
||||||
@@ -411,14 +411,14 @@ type DaemonSetSpec struct {
|
|||||||
// Must match in order to be controlled.
|
// Must match in order to be controlled.
|
||||||
// If empty, defaulted to labels on Pod template.
|
// If empty, defaulted to labels on Pod template.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
Selector *LabelSelector `json:"selector,omitempty"`
|
Selector *LabelSelector `json:"selector,omitempty" protobuf:"bytes,1,opt,name=selector"`
|
||||||
|
|
||||||
// Template is the object that describes the pod that will be created.
|
// Template is the object that describes the pod that will be created.
|
||||||
// The DaemonSet will create exactly one copy of this pod on every node
|
// The DaemonSet will create exactly one copy of this pod on every node
|
||||||
// that matches the template's node selector (or on every node if no node
|
// that matches the template's node selector (or on every node if no node
|
||||||
// selector is specified).
|
// selector is specified).
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#pod-template
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#pod-template
|
||||||
Template v1.PodTemplateSpec `json:"template"`
|
Template v1.PodTemplateSpec `json:"template" protobuf:"bytes,2,opt,name=template"`
|
||||||
|
|
||||||
// TODO(madhusudancs): Uncomment while implementing DaemonSet updates.
|
// TODO(madhusudancs): Uncomment while implementing DaemonSet updates.
|
||||||
/* Commenting out for v1.2. We are planning to bring these fields back with a more robust DaemonSet update implementation in v1.3, hence not deleting but just commenting these fields out.
|
/* Commenting out for v1.2. We are planning to bring these fields back with a more robust DaemonSet update implementation in v1.3, hence not deleting but just commenting these fields out.
|
||||||
@@ -448,17 +448,17 @@ type DaemonSetStatus struct {
|
|||||||
// CurrentNumberScheduled is the number of nodes that are running at least 1
|
// CurrentNumberScheduled is the number of nodes that are running at least 1
|
||||||
// daemon pod and are supposed to run the daemon pod.
|
// daemon pod and are supposed to run the daemon pod.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md
|
// More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md
|
||||||
CurrentNumberScheduled int32 `json:"currentNumberScheduled"`
|
CurrentNumberScheduled int32 `json:"currentNumberScheduled" protobuf:"varint,1,opt,name=currentNumberScheduled"`
|
||||||
|
|
||||||
// NumberMisscheduled is the number of nodes that are running the daemon pod, but are
|
// NumberMisscheduled is the number of nodes that are running the daemon pod, but are
|
||||||
// not supposed to run the daemon pod.
|
// not supposed to run the daemon pod.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md
|
// More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md
|
||||||
NumberMisscheduled int32 `json:"numberMisscheduled"`
|
NumberMisscheduled int32 `json:"numberMisscheduled" protobuf:"varint,2,opt,name=numberMisscheduled"`
|
||||||
|
|
||||||
// DesiredNumberScheduled is the total number of nodes that should be running the daemon
|
// DesiredNumberScheduled is the total number of nodes that should be running the daemon
|
||||||
// pod (including nodes correctly running the daemon pod).
|
// pod (including nodes correctly running the daemon pod).
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md
|
// More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md
|
||||||
DesiredNumberScheduled int32 `json:"desiredNumberScheduled"`
|
DesiredNumberScheduled int32 `json:"desiredNumberScheduled" protobuf:"varint,3,opt,name=desiredNumberScheduled"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient=true
|
// +genclient=true
|
||||||
@@ -468,18 +468,18 @@ type DaemonSet struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// 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
|
||||||
v1.ObjectMeta `json:"metadata,omitempty"`
|
v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Spec defines the desired behavior of this daemon set.
|
// Spec defines the desired behavior of this daemon set.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
Spec DaemonSetSpec `json:"spec,omitempty"`
|
Spec DaemonSetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
||||||
|
|
||||||
// Status is the current status of this daemon set. This data may be
|
// Status is the current status of this daemon set. This data may be
|
||||||
// out of date by some window of time.
|
// out of date by some window of time.
|
||||||
// Populated by the system.
|
// Populated by the system.
|
||||||
// Read-only.
|
// Read-only.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
Status DaemonSetStatus `json:"status,omitempty"`
|
Status DaemonSetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// DaemonSetList is a collection of daemon sets.
|
// DaemonSetList is a collection of daemon sets.
|
||||||
@@ -487,10 +487,10 @@ type DaemonSetList struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// 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
|
||||||
unversioned.ListMeta `json:"metadata,omitempty"`
|
unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Items is a list of daemon sets.
|
// Items is a list of daemon sets.
|
||||||
Items []DaemonSet `json:"items"`
|
Items []DaemonSet `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ThirdPartyResrouceDataList is a list of ThirdPartyResourceData.
|
// ThirdPartyResrouceDataList is a list of ThirdPartyResourceData.
|
||||||
@@ -498,10 +498,10 @@ type ThirdPartyResourceDataList struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// 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
|
||||||
unversioned.ListMeta `json:"metadata,omitempty"`
|
unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Items is the list of ThirdpartyResourceData.
|
// Items is the list of ThirdpartyResourceData.
|
||||||
Items []ThirdPartyResourceData `json:"items"`
|
Items []ThirdPartyResourceData `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient=true
|
// +genclient=true
|
||||||
@@ -511,15 +511,15 @@ type Job struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// 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
|
||||||
v1.ObjectMeta `json:"metadata,omitempty"`
|
v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Spec is a structure defining the expected behavior of a job.
|
// 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
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
Spec JobSpec `json:"spec,omitempty"`
|
Spec JobSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
||||||
|
|
||||||
// Status is a structure describing current status of a job.
|
// 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
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
Status JobStatus `json:"status,omitempty"`
|
Status JobStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// JobList is a collection of jobs.
|
// JobList is a collection of jobs.
|
||||||
@@ -527,10 +527,10 @@ type JobList struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// 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
|
||||||
unversioned.ListMeta `json:"metadata,omitempty"`
|
unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Items is the list of Job.
|
// Items is the list of Job.
|
||||||
Items []Job `json:"items"`
|
Items []Job `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// JobSpec describes how the job execution will look like.
|
// JobSpec describes how the job execution will look like.
|
||||||
@@ -541,7 +541,7 @@ type JobSpec struct {
|
|||||||
// be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism),
|
// be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism),
|
||||||
// i.e. when the work left to do is less than max parallelism.
|
// i.e. when the work left to do is less than max parallelism.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
Parallelism *int32 `json:"parallelism,omitempty"`
|
Parallelism *int32 `json:"parallelism,omitempty" protobuf:"varint,1,opt,name=parallelism"`
|
||||||
|
|
||||||
// Completions specifies the desired number of successfully finished pods the
|
// Completions specifies the desired number of successfully finished pods the
|
||||||
// job should be run with. Setting to nil means that the success of any
|
// job should be run with. Setting to nil means that the success of any
|
||||||
@@ -549,28 +549,28 @@ type JobSpec struct {
|
|||||||
// value. Setting to 1 means that parallelism is limited to 1 and the success of that
|
// value. Setting to 1 means that parallelism is limited to 1 and the success of that
|
||||||
// pod signals the success of the job.
|
// pod signals the success of the job.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
Completions *int32 `json:"completions,omitempty"`
|
Completions *int32 `json:"completions,omitempty" protobuf:"varint,2,opt,name=completions"`
|
||||||
|
|
||||||
// Optional duration in seconds relative to the startTime that the job may be active
|
// Optional duration in seconds relative to the startTime that the job may be active
|
||||||
// before the system tries to terminate it; value must be positive integer
|
// before the system tries to terminate it; value must be positive integer
|
||||||
ActiveDeadlineSeconds *int64 `json:"activeDeadlineSeconds,omitempty"`
|
ActiveDeadlineSeconds *int64 `json:"activeDeadlineSeconds,omitempty" protobuf:"varint,3,opt,name=activeDeadlineSeconds"`
|
||||||
|
|
||||||
// Selector is a label query over pods that should match the pod count.
|
// Selector is a label query over pods that should match the pod count.
|
||||||
// Normally, the system sets this field for you.
|
// Normally, the system sets this field for you.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
Selector *LabelSelector `json:"selector,omitempty"`
|
Selector *LabelSelector `json:"selector,omitempty" protobuf:"bytes,4,opt,name=selector"`
|
||||||
|
|
||||||
// AutoSelector controls generation of pod labels and pod selectors.
|
// AutoSelector controls generation of pod labels and pod selectors.
|
||||||
// It was not present in the original extensions/v1beta1 Job definition, but exists
|
// It was not present in the original extensions/v1beta1 Job definition, but exists
|
||||||
// to allow conversion from batch/v1 Jobs, where it corresponds to, but has the opposite
|
// to allow conversion from batch/v1 Jobs, where it corresponds to, but has the opposite
|
||||||
// meaning as, ManualSelector.
|
// meaning as, ManualSelector.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md
|
// More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md
|
||||||
AutoSelector *bool `json:"autoSelector,omitempty"`
|
AutoSelector *bool `json:"autoSelector,omitempty" protobuf:"varint,5,opt,name=autoSelector"`
|
||||||
|
|
||||||
// Template is the object that describes the pod that will be created when
|
// Template is the object that describes the pod that will be created when
|
||||||
// executing a job.
|
// executing a job.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
Template v1.PodTemplateSpec `json:"template"`
|
Template v1.PodTemplateSpec `json:"template" protobuf:"bytes,6,opt,name=template"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// JobStatus represents the current state of a Job.
|
// JobStatus represents the current state of a Job.
|
||||||
@@ -578,26 +578,26 @@ type JobStatus struct {
|
|||||||
|
|
||||||
// Conditions represent the latest available observations of an object's current state.
|
// Conditions represent the latest available observations of an object's current state.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/jobs.md
|
||||||
Conditions []JobCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type"`
|
Conditions []JobCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,1,rep,name=conditions"`
|
||||||
|
|
||||||
// StartTime represents time when the job was acknowledged by the Job Manager.
|
// StartTime represents time when the job was acknowledged by the Job Manager.
|
||||||
// It is not guaranteed to be set in happens-before order across separate operations.
|
// It is not guaranteed to be set in happens-before order across separate operations.
|
||||||
// It is represented in RFC3339 form and is in UTC.
|
// It is represented in RFC3339 form and is in UTC.
|
||||||
StartTime *unversioned.Time `json:"startTime,omitempty"`
|
StartTime *unversioned.Time `json:"startTime,omitempty" protobuf:"bytes,2,opt,name=startTime"`
|
||||||
|
|
||||||
// CompletionTime represents time when the job was completed. It is not guaranteed to
|
// CompletionTime represents time when the job was completed. It is not guaranteed to
|
||||||
// be set in happens-before order across separate operations.
|
// be set in happens-before order across separate operations.
|
||||||
// It is represented in RFC3339 form and is in UTC.
|
// It is represented in RFC3339 form and is in UTC.
|
||||||
CompletionTime *unversioned.Time `json:"completionTime,omitempty"`
|
CompletionTime *unversioned.Time `json:"completionTime,omitempty" protobuf:"bytes,3,opt,name=completionTime"`
|
||||||
|
|
||||||
// Active is the number of actively running pods.
|
// Active is the number of actively running pods.
|
||||||
Active int32 `json:"active,omitempty"`
|
Active int32 `json:"active,omitempty" protobuf:"varint,4,opt,name=active"`
|
||||||
|
|
||||||
// Succeeded is the number of pods which reached Phase Succeeded.
|
// Succeeded is the number of pods which reached Phase Succeeded.
|
||||||
Succeeded int32 `json:"succeeded,omitempty"`
|
Succeeded int32 `json:"succeeded,omitempty" protobuf:"varint,5,opt,name=succeeded"`
|
||||||
|
|
||||||
// Failed is the number of pods which reached Phase Failed.
|
// Failed is the number of pods which reached Phase Failed.
|
||||||
Failed int32 `json:"failed,omitempty"`
|
Failed int32 `json:"failed,omitempty" protobuf:"varint,6,opt,name=failed"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type JobConditionType string
|
type JobConditionType string
|
||||||
@@ -613,17 +613,17 @@ const (
|
|||||||
// JobCondition describes current state of a job.
|
// JobCondition describes current state of a job.
|
||||||
type JobCondition struct {
|
type JobCondition struct {
|
||||||
// Type of job condition, Complete or Failed.
|
// Type of job condition, Complete or Failed.
|
||||||
Type JobConditionType `json:"type"`
|
Type JobConditionType `json:"type" protobuf:"bytes,1,opt,name=type,casttype=JobConditionType"`
|
||||||
// Status of the condition, one of True, False, Unknown.
|
// Status of the condition, one of True, False, Unknown.
|
||||||
Status v1.ConditionStatus `json:"status"`
|
Status v1.ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=k8s.io/kubernetes/pkg/api/v1.ConditionStatus"`
|
||||||
// Last time the condition was checked.
|
// Last time the condition was checked.
|
||||||
LastProbeTime unversioned.Time `json:"lastProbeTime,omitempty"`
|
LastProbeTime unversioned.Time `json:"lastProbeTime,omitempty" protobuf:"bytes,3,opt,name=lastProbeTime"`
|
||||||
// Last time the condition transit from one status to another.
|
// Last time the condition transit from one status to another.
|
||||||
LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty"`
|
LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,4,opt,name=lastTransitionTime"`
|
||||||
// (brief) reason for the condition's last transition.
|
// (brief) reason for the condition's last transition.
|
||||||
Reason string `json:"reason,omitempty"`
|
Reason string `json:"reason,omitempty" protobuf:"bytes,5,opt,name=reason"`
|
||||||
// Human readable message indicating details about last transition.
|
// Human readable message indicating details about last transition.
|
||||||
Message string `json:"message,omitempty"`
|
Message string `json:"message,omitempty" protobuf:"bytes,6,opt,name=message"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient=true
|
// +genclient=true
|
||||||
@@ -636,15 +636,15 @@ type Ingress struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// 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
|
||||||
v1.ObjectMeta `json:"metadata,omitempty"`
|
v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Spec is the desired state of the Ingress.
|
// Spec is the desired state of the Ingress.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
Spec IngressSpec `json:"spec,omitempty"`
|
Spec IngressSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
||||||
|
|
||||||
// Status is the current state of the Ingress.
|
// Status is the current state of the Ingress.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
Status IngressStatus `json:"status,omitempty"`
|
Status IngressStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// IngressList is a collection of Ingress.
|
// IngressList is a collection of Ingress.
|
||||||
@@ -652,10 +652,10 @@ type IngressList struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// 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
|
||||||
unversioned.ListMeta `json:"metadata,omitempty"`
|
unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Items is the list of Ingress.
|
// Items is the list of Ingress.
|
||||||
Items []Ingress `json:"items"`
|
Items []Ingress `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// IngressSpec describes the Ingress the user wishes to exist.
|
// IngressSpec describes the Ingress the user wishes to exist.
|
||||||
@@ -664,18 +664,18 @@ type IngressSpec struct {
|
|||||||
// rule. At least one of 'backend' or 'rules' must be specified. This field
|
// rule. At least one of 'backend' or 'rules' must be specified. This field
|
||||||
// is optional to allow the loadbalancer controller or defaulting logic to
|
// is optional to allow the loadbalancer controller or defaulting logic to
|
||||||
// specify a global default.
|
// specify a global default.
|
||||||
Backend *IngressBackend `json:"backend,omitempty"`
|
Backend *IngressBackend `json:"backend,omitempty" protobuf:"bytes,1,opt,name=backend"`
|
||||||
|
|
||||||
// TLS configuration. Currently the Ingress only supports a single TLS
|
// TLS configuration. Currently the Ingress only supports a single TLS
|
||||||
// port, 443. If multiple members of this list specify different hosts, they
|
// port, 443. If multiple members of this list specify different hosts, they
|
||||||
// will be multiplexed on the same port according to the hostname specified
|
// will be multiplexed on the same port according to the hostname specified
|
||||||
// through the SNI TLS extension, if the ingress controller fulfilling the
|
// through the SNI TLS extension, if the ingress controller fulfilling the
|
||||||
// ingress supports SNI.
|
// ingress supports SNI.
|
||||||
TLS []IngressTLS `json:"tls,omitempty"`
|
TLS []IngressTLS `json:"tls,omitempty" protobuf:"bytes,2,rep,name=tls"`
|
||||||
|
|
||||||
// A list of host rules used to configure the Ingress. If unspecified, or
|
// A list of host rules used to configure the Ingress. If unspecified, or
|
||||||
// no rule matches, all traffic is sent to the default backend.
|
// no rule matches, all traffic is sent to the default backend.
|
||||||
Rules []IngressRule `json:"rules,omitempty"`
|
Rules []IngressRule `json:"rules,omitempty" protobuf:"bytes,3,rep,name=rules"`
|
||||||
// TODO: Add the ability to specify load-balancer IP through claims
|
// TODO: Add the ability to specify load-balancer IP through claims
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -685,20 +685,20 @@ type IngressTLS struct {
|
|||||||
// this list must match the name/s used in the tlsSecret. Defaults to the
|
// this list must match the name/s used in the tlsSecret. Defaults to the
|
||||||
// wildcard host setting for the loadbalancer controller fulfilling this
|
// wildcard host setting for the loadbalancer controller fulfilling this
|
||||||
// Ingress, if left unspecified.
|
// Ingress, if left unspecified.
|
||||||
Hosts []string `json:"hosts,omitempty"`
|
Hosts []string `json:"hosts,omitempty" protobuf:"bytes,1,rep,name=hosts"`
|
||||||
// SecretName is the name of the secret used to terminate SSL traffic on 443.
|
// SecretName is the name of the secret used to terminate SSL traffic on 443.
|
||||||
// Field is left optional to allow SSL routing based on SNI hostname alone.
|
// Field is left optional to allow SSL routing based on SNI hostname alone.
|
||||||
// If the SNI host in a listener conflicts with the "Host" header field used
|
// If the SNI host in a listener conflicts with the "Host" header field used
|
||||||
// by an IngressRule, the SNI host is used for termination and value of the
|
// by an IngressRule, the SNI host is used for termination and value of the
|
||||||
// Host header is used for routing.
|
// Host header is used for routing.
|
||||||
SecretName string `json:"secretName,omitempty"`
|
SecretName string `json:"secretName,omitempty" protobuf:"bytes,2,opt,name=secretName"`
|
||||||
// TODO: Consider specifying different modes of termination, protocols etc.
|
// TODO: Consider specifying different modes of termination, protocols etc.
|
||||||
}
|
}
|
||||||
|
|
||||||
// IngressStatus describe the current state of the Ingress.
|
// IngressStatus describe the current state of the Ingress.
|
||||||
type IngressStatus struct {
|
type IngressStatus struct {
|
||||||
// LoadBalancer contains the current status of the load-balancer.
|
// LoadBalancer contains the current status of the load-balancer.
|
||||||
LoadBalancer v1.LoadBalancerStatus `json:"loadBalancer,omitempty"`
|
LoadBalancer v1.LoadBalancerStatus `json:"loadBalancer,omitempty" protobuf:"bytes,1,opt,name=loadBalancer"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// IngressRule represents the rules mapping the paths under a specified host to
|
// IngressRule represents the rules mapping the paths under a specified host to
|
||||||
@@ -717,13 +717,13 @@ type IngressRule struct {
|
|||||||
// Incoming requests are matched against the host before the IngressRuleValue.
|
// Incoming requests are matched against the host before the IngressRuleValue.
|
||||||
// If the host is unspecified, the Ingress routes all traffic based on the
|
// If the host is unspecified, the Ingress routes all traffic based on the
|
||||||
// specified IngressRuleValue.
|
// specified IngressRuleValue.
|
||||||
Host string `json:"host,omitempty"`
|
Host string `json:"host,omitempty" protobuf:"bytes,1,opt,name=host"`
|
||||||
// IngressRuleValue represents a rule to route requests for this IngressRule.
|
// IngressRuleValue represents a rule to route requests for this IngressRule.
|
||||||
// If unspecified, the rule defaults to a http catch-all. Whether that sends
|
// If unspecified, the rule defaults to a http catch-all. Whether that sends
|
||||||
// just traffic matching the host to the default backend or all traffic to the
|
// just traffic matching the host to the default backend or all traffic to the
|
||||||
// default backend, is left to the controller fulfilling the Ingress. Http is
|
// default backend, is left to the controller fulfilling the Ingress. Http is
|
||||||
// currently the only supported IngressRuleValue.
|
// currently the only supported IngressRuleValue.
|
||||||
IngressRuleValue `json:",inline,omitempty"`
|
IngressRuleValue `json:",inline,omitempty" protobuf:"bytes,2,opt,name=ingressRuleValue"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// IngressRuleValue represents a rule to apply against incoming requests. If the
|
// IngressRuleValue represents a rule to apply against incoming requests. If the
|
||||||
@@ -737,7 +737,7 @@ type IngressRuleValue struct {
|
|||||||
// 2. Consider adding fields for ingress-type specific global options
|
// 2. Consider adding fields for ingress-type specific global options
|
||||||
// usable by a loadbalancer, like http keep-alive.
|
// usable by a loadbalancer, like http keep-alive.
|
||||||
|
|
||||||
HTTP *HTTPIngressRuleValue `json:"http,omitempty"`
|
HTTP *HTTPIngressRuleValue `json:"http,omitempty" protobuf:"bytes,1,opt,name=http"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// HTTPIngressRuleValue is a list of http selectors pointing to backends.
|
// HTTPIngressRuleValue is a list of http selectors pointing to backends.
|
||||||
@@ -747,7 +747,7 @@ type IngressRuleValue struct {
|
|||||||
// or '#'.
|
// or '#'.
|
||||||
type HTTPIngressRuleValue struct {
|
type HTTPIngressRuleValue struct {
|
||||||
// A collection of paths that map requests to backends.
|
// A collection of paths that map requests to backends.
|
||||||
Paths []HTTPIngressPath `json:"paths"`
|
Paths []HTTPIngressPath `json:"paths" protobuf:"bytes,1,rep,name=paths"`
|
||||||
// TODO: Consider adding fields for ingress-type specific global
|
// TODO: Consider adding fields for ingress-type specific global
|
||||||
// options usable by a loadbalancer, like http keep-alive.
|
// options usable by a loadbalancer, like http keep-alive.
|
||||||
}
|
}
|
||||||
@@ -762,29 +762,29 @@ type HTTPIngressPath struct {
|
|||||||
// part of a URL as defined by RFC 3986. Paths must begin with
|
// part of a URL as defined by RFC 3986. Paths must begin with
|
||||||
// a '/'. If unspecified, the path defaults to a catch all sending
|
// a '/'. If unspecified, the path defaults to a catch all sending
|
||||||
// traffic to the backend.
|
// traffic to the backend.
|
||||||
Path string `json:"path,omitempty"`
|
Path string `json:"path,omitempty" protobuf:"bytes,1,opt,name=path"`
|
||||||
|
|
||||||
// Backend defines the referenced service endpoint to which the traffic
|
// Backend defines the referenced service endpoint to which the traffic
|
||||||
// will be forwarded to.
|
// will be forwarded to.
|
||||||
Backend IngressBackend `json:"backend"`
|
Backend IngressBackend `json:"backend" protobuf:"bytes,2,opt,name=backend"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// IngressBackend describes all endpoints for a given service and port.
|
// IngressBackend describes all endpoints for a given service and port.
|
||||||
type IngressBackend struct {
|
type IngressBackend struct {
|
||||||
// Specifies the name of the referenced service.
|
// Specifies the name of the referenced service.
|
||||||
ServiceName string `json:"serviceName"`
|
ServiceName string `json:"serviceName" protobuf:"bytes,1,opt,name=serviceName"`
|
||||||
|
|
||||||
// Specifies the port of the referenced service.
|
// Specifies the port of the referenced service.
|
||||||
ServicePort intstr.IntOrString `json:"servicePort"`
|
ServicePort intstr.IntOrString `json:"servicePort" protobuf:"bytes,2,opt,name=servicePort"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ExportOptions is the query options to the standard REST get call.
|
// ExportOptions is the query options to the standard REST get call.
|
||||||
type ExportOptions struct {
|
type ExportOptions struct {
|
||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// Should this value be exported. Export strips fields that a user can not specify.
|
// Should this value be exported. Export strips fields that a user can not specify.
|
||||||
Export bool `json:"export"`
|
Export bool `json:"export" protobuf:"varint,1,opt,name=export"`
|
||||||
// Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'
|
// Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'
|
||||||
Exact bool `json:"exact"`
|
Exact bool `json:"exact" protobuf:"varint,2,opt,name=exact"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ListOptions is the query options to a standard REST list call.
|
// ListOptions is the query options to a standard REST list call.
|
||||||
@@ -793,18 +793,18 @@ type ListOptions struct {
|
|||||||
|
|
||||||
// A selector to restrict the list of returned objects by their labels.
|
// A selector to restrict the list of returned objects by their labels.
|
||||||
// Defaults to everything.
|
// Defaults to everything.
|
||||||
LabelSelector string `json:"labelSelector,omitempty"`
|
LabelSelector string `json:"labelSelector,omitempty" protobuf:"bytes,1,opt,name=labelSelector"`
|
||||||
// A selector to restrict the list of returned objects by their fields.
|
// A selector to restrict the list of returned objects by their fields.
|
||||||
// Defaults to everything.
|
// Defaults to everything.
|
||||||
FieldSelector string `json:"fieldSelector,omitempty"`
|
FieldSelector string `json:"fieldSelector,omitempty" protobuf:"bytes,2,opt,name=fieldSelector"`
|
||||||
// Watch for changes to the described resources and return them as a stream of
|
// Watch for changes to the described resources and return them as a stream of
|
||||||
// add, update, and remove notifications. Specify resourceVersion.
|
// add, update, and remove notifications. Specify resourceVersion.
|
||||||
Watch bool `json:"watch,omitempty"`
|
Watch bool `json:"watch,omitempty" protobuf:"varint,3,opt,name=watch"`
|
||||||
// When specified with a watch call, shows changes that occur after that particular version of a resource.
|
// When specified with a watch call, shows changes that occur after that particular version of a resource.
|
||||||
// Defaults to changes from the beginning of history.
|
// Defaults to changes from the beginning of history.
|
||||||
ResourceVersion string `json:"resourceVersion,omitempty"`
|
ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,4,opt,name=resourceVersion"`
|
||||||
// Timeout for the list/watch call.
|
// Timeout for the list/watch call.
|
||||||
TimeoutSeconds *int64 `json:"timeoutSeconds,omitempty"`
|
TimeoutSeconds *int64 `json:"timeoutSeconds,omitempty" protobuf:"varint,5,opt,name=timeoutSeconds"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// A label selector is a label query over a set of resources. The result of matchLabels and
|
// A label selector is a label query over a set of resources. The result of matchLabels and
|
||||||
@@ -814,24 +814,24 @@ type LabelSelector struct {
|
|||||||
// matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
|
// matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
|
||||||
// map is equivalent to an element of matchExpressions, whose key field is "key", the
|
// map is equivalent to an element of matchExpressions, whose key field is "key", the
|
||||||
// operator is "In", and the values array contains only "value". The requirements are ANDed.
|
// operator is "In", and the values array contains only "value". The requirements are ANDed.
|
||||||
MatchLabels map[string]string `json:"matchLabels,omitempty"`
|
MatchLabels map[string]string `json:"matchLabels,omitempty" protobuf:"bytes,1,rep,name=matchLabels"`
|
||||||
// matchExpressions is a list of label selector requirements. The requirements are ANDed.
|
// matchExpressions is a list of label selector requirements. The requirements are ANDed.
|
||||||
MatchExpressions []LabelSelectorRequirement `json:"matchExpressions,omitempty"`
|
MatchExpressions []LabelSelectorRequirement `json:"matchExpressions,omitempty" protobuf:"bytes,2,rep,name=matchExpressions"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// A label selector requirement is a selector that contains values, a key, and an operator that
|
// A label selector requirement is a selector that contains values, a key, and an operator that
|
||||||
// relates the key and values.
|
// relates the key and values.
|
||||||
type LabelSelectorRequirement struct {
|
type LabelSelectorRequirement struct {
|
||||||
// key is the label key that the selector applies to.
|
// key is the label key that the selector applies to.
|
||||||
Key string `json:"key" patchStrategy:"merge" patchMergeKey:"key"`
|
Key string `json:"key" patchStrategy:"merge" patchMergeKey:"key" protobuf:"bytes,1,opt,name=key"`
|
||||||
// operator represents a key's relationship to a set of values.
|
// operator represents a key's relationship to a set of values.
|
||||||
// Valid operators ard In, NotIn, Exists and DoesNotExist.
|
// Valid operators ard In, NotIn, Exists and DoesNotExist.
|
||||||
Operator LabelSelectorOperator `json:"operator"`
|
Operator LabelSelectorOperator `json:"operator" protobuf:"bytes,2,opt,name=operator,casttype=LabelSelectorOperator"`
|
||||||
// values is an array of string values. If the operator is In or NotIn,
|
// values is an array of string values. If the operator is In or NotIn,
|
||||||
// the values array must be non-empty. If the operator is Exists or DoesNotExist,
|
// the values array must be non-empty. If the operator is Exists or DoesNotExist,
|
||||||
// the values array must be empty. This array is replaced during a strategic
|
// the values array must be empty. This array is replaced during a strategic
|
||||||
// merge patch.
|
// merge patch.
|
||||||
Values []string `json:"values,omitempty"`
|
Values []string `json:"values,omitempty" protobuf:"bytes,3,rep,name=values"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// A label selector operator is the set of operators that can be used in a selector requirement.
|
// A label selector operator is the set of operators that can be used in a selector requirement.
|
||||||
@@ -853,18 +853,18 @@ type ReplicaSet struct {
|
|||||||
// If the Labels of a ReplicaSet are empty, they are defaulted to
|
// If the Labels of a ReplicaSet are empty, they are defaulted to
|
||||||
// be the same as the Pod(s) that the ReplicaSet manages.
|
// be the same as the Pod(s) that the ReplicaSet manages.
|
||||||
// Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
// Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata
|
||||||
v1.ObjectMeta `json:"metadata,omitempty"`
|
v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Spec defines the specification of the desired behavior of the ReplicaSet.
|
// Spec defines the specification of the desired behavior of the ReplicaSet.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
Spec ReplicaSetSpec `json:"spec,omitempty"`
|
Spec ReplicaSetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
||||||
|
|
||||||
// Status is the most recently observed status of the ReplicaSet.
|
// Status is the most recently observed status of the ReplicaSet.
|
||||||
// This data may be out of date by some window of time.
|
// This data may be out of date by some window of time.
|
||||||
// Populated by the system.
|
// Populated by the system.
|
||||||
// Read-only.
|
// Read-only.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status
|
||||||
Status ReplicaSetStatus `json:"status,omitempty"`
|
Status ReplicaSetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ReplicaSetList is a collection of ReplicaSets.
|
// ReplicaSetList is a collection of ReplicaSets.
|
||||||
@@ -872,11 +872,11 @@ type ReplicaSetList struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// Standard list metadata.
|
// Standard list metadata.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
|
// More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds
|
||||||
unversioned.ListMeta `json:"metadata,omitempty"`
|
unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// List of ReplicaSets.
|
// List of ReplicaSets.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md
|
||||||
Items []ReplicaSet `json:"items"`
|
Items []ReplicaSet `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ReplicaSetSpec is the specification of a ReplicaSet.
|
// ReplicaSetSpec is the specification of a ReplicaSet.
|
||||||
@@ -885,31 +885,31 @@ type ReplicaSetSpec struct {
|
|||||||
// This is a pointer to distinguish between explicit zero and unspecified.
|
// This is a pointer to distinguish between explicit zero and unspecified.
|
||||||
// Defaults to 1.
|
// Defaults to 1.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#what-is-a-replication-controller
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#what-is-a-replication-controller
|
||||||
Replicas *int32 `json:"replicas,omitempty"`
|
Replicas *int32 `json:"replicas,omitempty" protobuf:"varint,1,opt,name=replicas"`
|
||||||
|
|
||||||
// Selector is a label query over pods that should match the replica count.
|
// Selector is a label query over pods that should match the replica count.
|
||||||
// If the selector is empty, it is defaulted to the labels present on the pod template.
|
// If the selector is empty, it is defaulted to the labels present on the pod template.
|
||||||
// Label keys and values that must match in order to be controlled by this replica set.
|
// Label keys and values that must match in order to be controlled by this replica set.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/labels.md#label-selectors
|
||||||
Selector *LabelSelector `json:"selector,omitempty"`
|
Selector *LabelSelector `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"`
|
||||||
|
|
||||||
// Template is the object that describes the pod that will be created if
|
// Template is the object that describes the pod that will be created if
|
||||||
// insufficient replicas are detected.
|
// insufficient replicas are detected.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#pod-template
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#pod-template
|
||||||
Template v1.PodTemplateSpec `json:"template,omitempty"`
|
Template v1.PodTemplateSpec `json:"template,omitempty" protobuf:"bytes,3,opt,name=template"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ReplicaSetStatus represents the current status of a ReplicaSet.
|
// ReplicaSetStatus represents the current status of a ReplicaSet.
|
||||||
type ReplicaSetStatus struct {
|
type ReplicaSetStatus struct {
|
||||||
// Replicas is the most recently oberved number of replicas.
|
// Replicas is the most recently oberved number of replicas.
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#what-is-a-replication-controller
|
// More info: http://releases.k8s.io/HEAD/docs/user-guide/replication-controller.md#what-is-a-replication-controller
|
||||||
Replicas int32 `json:"replicas"`
|
Replicas int32 `json:"replicas" protobuf:"varint,1,opt,name=replicas"`
|
||||||
|
|
||||||
// The number of pods that have labels matching the labels of the pod template of the replicaset.
|
// The number of pods that have labels matching the labels of the pod template of the replicaset.
|
||||||
FullyLabeledReplicas int32 `json:"fullyLabeledReplicas,omitempty"`
|
FullyLabeledReplicas int32 `json:"fullyLabeledReplicas,omitempty" protobuf:"varint,2,opt,name=fullyLabeledReplicas"`
|
||||||
|
|
||||||
// ObservedGeneration reflects the generation of the most recently observed ReplicaSet.
|
// ObservedGeneration reflects the generation of the most recently observed ReplicaSet.
|
||||||
ObservedGeneration int64 `json:"observedGeneration,omitempty"`
|
ObservedGeneration int64 `json:"observedGeneration,omitempty" protobuf:"varint,3,opt,name=observedGeneration"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Pod Security Policy governs the ability to make requests that affect the Security Context
|
// Pod Security Policy governs the ability to make requests that affect the Security Context
|
||||||
@@ -918,33 +918,33 @@ type PodSecurityPolicy struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// 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
|
||||||
v1.ObjectMeta `json:"metadata,omitempty"`
|
v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// spec defines the policy enforced.
|
// spec defines the policy enforced.
|
||||||
Spec PodSecurityPolicySpec `json:"spec,omitempty"`
|
Spec PodSecurityPolicySpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Pod Security Policy Spec defines the policy enforced.
|
// Pod Security Policy Spec defines the policy enforced.
|
||||||
type PodSecurityPolicySpec struct {
|
type PodSecurityPolicySpec struct {
|
||||||
// privileged determines if a pod can request to be run as privileged.
|
// privileged determines if a pod can request to be run as privileged.
|
||||||
Privileged bool `json:"privileged,omitempty"`
|
Privileged bool `json:"privileged,omitempty" protobuf:"varint,1,opt,name=privileged"`
|
||||||
// capabilities is a list of capabilities that can be added.
|
// capabilities is a list of capabilities that can be added.
|
||||||
Capabilities []v1.Capability `json:"capabilities,omitempty"`
|
Capabilities []v1.Capability `json:"capabilities,omitempty" protobuf:"bytes,2,rep,name=capabilities,casttype=k8s.io/kubernetes/pkg/api/v1.Capability"`
|
||||||
// volumes is a white list of allowed volume plugins. Empty indicates that all plugins
|
// volumes is a white list of allowed volume plugins. Empty indicates that all plugins
|
||||||
// may be used.
|
// may be used.
|
||||||
Volumes []FSType `json:"volumes,omitempty"`
|
Volumes []FSType `json:"volumes,omitempty" protobuf:"bytes,3,rep,name=volumes,casttype=FSType"`
|
||||||
// hostNetwork determines if the policy allows the use of HostNetwork in the pod spec.
|
// hostNetwork determines if the policy allows the use of HostNetwork in the pod spec.
|
||||||
HostNetwork bool `json:"hostNetwork,omitempty"`
|
HostNetwork bool `json:"hostNetwork,omitempty" protobuf:"varint,4,opt,name=hostNetwork"`
|
||||||
// hostPorts determines which host port ranges are allowed to be exposed.
|
// hostPorts determines which host port ranges are allowed to be exposed.
|
||||||
HostPorts []HostPortRange `json:"hostPorts,omitempty"`
|
HostPorts []HostPortRange `json:"hostPorts,omitempty" protobuf:"bytes,5,rep,name=hostPorts"`
|
||||||
// hostPID determines if the policy allows the use of HostPID in the pod spec.
|
// hostPID determines if the policy allows the use of HostPID in the pod spec.
|
||||||
HostPID bool `json:"hostPID,omitempty"`
|
HostPID bool `json:"hostPID,omitempty" protobuf:"varint,6,opt,name=hostPID"`
|
||||||
// hostIPC determines if the policy allows the use of HostIPC in the pod spec.
|
// hostIPC determines if the policy allows the use of HostIPC in the pod spec.
|
||||||
HostIPC bool `json:"hostIPC,omitempty"`
|
HostIPC bool `json:"hostIPC,omitempty" protobuf:"varint,7,opt,name=hostIPC"`
|
||||||
// seLinux is the strategy that will dictate the allowable labels that may be set.
|
// seLinux is the strategy that will dictate the allowable labels that may be set.
|
||||||
SELinux SELinuxStrategyOptions `json:"seLinux,omitempty"`
|
SELinux SELinuxStrategyOptions `json:"seLinux,omitempty" protobuf:"bytes,8,opt,name=seLinux"`
|
||||||
// runAsUser is the strategy that will dictate the allowable RunAsUser values that may be set.
|
// runAsUser is the strategy that will dictate the allowable RunAsUser values that may be set.
|
||||||
RunAsUser RunAsUserStrategyOptions `json:"runAsUser,omitempty"`
|
RunAsUser RunAsUserStrategyOptions `json:"runAsUser,omitempty" protobuf:"bytes,9,opt,name=runAsUser"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// FS Type gives strong typing to different file systems that are used by volumes.
|
// FS Type gives strong typing to different file systems that are used by volumes.
|
||||||
@@ -972,18 +972,18 @@ var (
|
|||||||
// for pods to use. It requires both the start and end to be defined.
|
// for pods to use. It requires both the start and end to be defined.
|
||||||
type HostPortRange struct {
|
type HostPortRange struct {
|
||||||
// min is the start of the range, inclusive.
|
// min is the start of the range, inclusive.
|
||||||
Min int32 `json:"min"`
|
Min int32 `json:"min" protobuf:"varint,1,opt,name=min"`
|
||||||
// max is the end of the range, inclusive.
|
// max is the end of the range, inclusive.
|
||||||
Max int32 `json:"max"`
|
Max int32 `json:"max" protobuf:"varint,2,opt,name=max"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// SELinux Strategy Options defines the strategy type and any options used to create the strategy.
|
// SELinux Strategy Options defines the strategy type and any options used to create the strategy.
|
||||||
type SELinuxStrategyOptions struct {
|
type SELinuxStrategyOptions struct {
|
||||||
// type is the strategy that will dictate the allowable labels that may be set.
|
// type is the strategy that will dictate the allowable labels that may be set.
|
||||||
Rule SELinuxStrategy `json:"rule"`
|
Rule SELinuxStrategy `json:"rule" protobuf:"bytes,1,opt,name=rule,casttype=SELinuxStrategy"`
|
||||||
// seLinuxOptions required to run as; required for MustRunAs
|
// seLinuxOptions required to run as; required for MustRunAs
|
||||||
// More info: http://releases.k8s.io/HEAD/docs/design/security_context.md#security-context
|
// More info: http://releases.k8s.io/HEAD/docs/design/security_context.md#security-context
|
||||||
SELinuxOptions *v1.SELinuxOptions `json:"seLinuxOptions,omitempty"`
|
SELinuxOptions *v1.SELinuxOptions `json:"seLinuxOptions,omitempty" protobuf:"bytes,2,opt,name=seLinuxOptions"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// SELinuxStrategy denotes strategy types for generating SELinux options for a
|
// SELinuxStrategy denotes strategy types for generating SELinux options for a
|
||||||
@@ -1000,17 +1000,17 @@ const (
|
|||||||
// Run A sUser Strategy Options defines the strategy type and any options used to create the strategy.
|
// Run A sUser Strategy Options defines the strategy type and any options used to create the strategy.
|
||||||
type RunAsUserStrategyOptions struct {
|
type RunAsUserStrategyOptions struct {
|
||||||
// Rule is the strategy that will dictate the allowable RunAsUser values that may be set.
|
// Rule is the strategy that will dictate the allowable RunAsUser values that may be set.
|
||||||
Rule RunAsUserStrategy `json:"rule"`
|
Rule RunAsUserStrategy `json:"rule" protobuf:"bytes,1,opt,name=rule,casttype=RunAsUserStrategy"`
|
||||||
// Ranges are the allowed ranges of uids that may be used.
|
// Ranges are the allowed ranges of uids that may be used.
|
||||||
Ranges []IDRange `json:"ranges,omitempty"`
|
Ranges []IDRange `json:"ranges,omitempty" protobuf:"bytes,2,rep,name=ranges"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ID Range provides a min/max of an allowed range of IDs.
|
// ID Range provides a min/max of an allowed range of IDs.
|
||||||
type IDRange struct {
|
type IDRange struct {
|
||||||
// Min is the start of the range, inclusive.
|
// Min is the start of the range, inclusive.
|
||||||
Min int64 `json:"min"`
|
Min int64 `json:"min" protobuf:"varint,1,opt,name=min"`
|
||||||
// Max is the end of the range, inclusive.
|
// Max is the end of the range, inclusive.
|
||||||
Max int64 `json:"max"`
|
Max int64 `json:"max" protobuf:"varint,2,opt,name=max"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// RunAsUserStrategy denotes strategy types for generating RunAsUser values for a
|
// RunAsUserStrategy denotes strategy types for generating RunAsUser values for a
|
||||||
@@ -1031,8 +1031,8 @@ type PodSecurityPolicyList struct {
|
|||||||
unversioned.TypeMeta `json:",inline"`
|
unversioned.TypeMeta `json:",inline"`
|
||||||
// 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
|
||||||
unversioned.ListMeta `json:"metadata,omitempty"`
|
unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||||
|
|
||||||
// Items is a list of schema objects.
|
// Items is a list of schema objects.
|
||||||
Items []PodSecurityPolicy `json:"items"`
|
Items []PodSecurityPolicy `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
692
pkg/runtime/generated.pb.go
Normal file
692
pkg/runtime/generated.pb.go
Normal file
@@ -0,0 +1,692 @@
|
|||||||
|
/*
|
||||||
|
Copyright 2016 The Kubernetes Authors All rights reserved.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by protoc-gen-gogo.
|
||||||
|
// source: k8s.io/kubernetes/pkg/runtime/generated.proto
|
||||||
|
// DO NOT EDIT!
|
||||||
|
|
||||||
|
/*
|
||||||
|
Package runtime is a generated protocol buffer package.
|
||||||
|
|
||||||
|
It is generated from these files:
|
||||||
|
k8s.io/kubernetes/pkg/runtime/generated.proto
|
||||||
|
|
||||||
|
It has these top-level messages:
|
||||||
|
RawExtension
|
||||||
|
TypeMeta
|
||||||
|
Unknown
|
||||||
|
*/
|
||||||
|
package runtime
|
||||||
|
|
||||||
|
import proto "github.com/gogo/protobuf/proto"
|
||||||
|
import fmt "fmt"
|
||||||
|
import math "math"
|
||||||
|
import _ "github.com/gogo/protobuf/gogoproto"
|
||||||
|
import _ "k8s.io/kubernetes/pkg/api/resource"
|
||||||
|
import _ "k8s.io/kubernetes/pkg/util/intstr"
|
||||||
|
|
||||||
|
import io "io"
|
||||||
|
|
||||||
|
// Reference imports to suppress errors if they are not otherwise used.
|
||||||
|
var _ = proto.Marshal
|
||||||
|
var _ = fmt.Errorf
|
||||||
|
var _ = math.Inf
|
||||||
|
|
||||||
|
func (m *RawExtension) Reset() { *m = RawExtension{} }
|
||||||
|
func (m *RawExtension) String() string { return proto.CompactTextString(m) }
|
||||||
|
func (*RawExtension) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (m *TypeMeta) Reset() { *m = TypeMeta{} }
|
||||||
|
func (m *TypeMeta) String() string { return proto.CompactTextString(m) }
|
||||||
|
func (*TypeMeta) ProtoMessage() {}
|
||||||
|
|
||||||
|
func (m *Unknown) Reset() { *m = Unknown{} }
|
||||||
|
func (m *Unknown) String() string { return proto.CompactTextString(m) }
|
||||||
|
func (*Unknown) ProtoMessage() {}
|
||||||
|
|
||||||
|
func init() {
|
||||||
|
proto.RegisterType((*RawExtension)(nil), "k8s.io.kubernetes.pkg.runtime.RawExtension")
|
||||||
|
proto.RegisterType((*TypeMeta)(nil), "k8s.io.kubernetes.pkg.runtime.TypeMeta")
|
||||||
|
proto.RegisterType((*Unknown)(nil), "k8s.io.kubernetes.pkg.runtime.Unknown")
|
||||||
|
}
|
||||||
|
func (m *RawExtension) Marshal() (data []byte, err error) {
|
||||||
|
size := m.Size()
|
||||||
|
data = make([]byte, size)
|
||||||
|
n, err := m.MarshalTo(data)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
return data[:n], nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *RawExtension) MarshalTo(data []byte) (int, error) {
|
||||||
|
var i int
|
||||||
|
_ = i
|
||||||
|
var l int
|
||||||
|
_ = l
|
||||||
|
if m.Raw != nil {
|
||||||
|
data[i] = 0xa
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(len(m.Raw)))
|
||||||
|
i += copy(data[i:], m.Raw)
|
||||||
|
}
|
||||||
|
return i, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *TypeMeta) Marshal() (data []byte, err error) {
|
||||||
|
size := m.Size()
|
||||||
|
data = make([]byte, size)
|
||||||
|
n, err := m.MarshalTo(data)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
return data[:n], nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *TypeMeta) MarshalTo(data []byte) (int, error) {
|
||||||
|
var i int
|
||||||
|
_ = i
|
||||||
|
var l int
|
||||||
|
_ = l
|
||||||
|
data[i] = 0xa
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(len(m.APIVersion)))
|
||||||
|
i += copy(data[i:], m.APIVersion)
|
||||||
|
data[i] = 0x12
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(len(m.Kind)))
|
||||||
|
i += copy(data[i:], m.Kind)
|
||||||
|
return i, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *Unknown) Marshal() (data []byte, err error) {
|
||||||
|
size := m.Size()
|
||||||
|
data = make([]byte, size)
|
||||||
|
n, err := m.MarshalTo(data)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
return data[:n], nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *Unknown) MarshalTo(data []byte) (int, error) {
|
||||||
|
var i int
|
||||||
|
_ = i
|
||||||
|
var l int
|
||||||
|
_ = l
|
||||||
|
data[i] = 0xa
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(m.TypeMeta.Size()))
|
||||||
|
n1, err := m.TypeMeta.MarshalTo(data[i:])
|
||||||
|
if err != nil {
|
||||||
|
return 0, err
|
||||||
|
}
|
||||||
|
i += n1
|
||||||
|
if m.Raw != nil {
|
||||||
|
data[i] = 0x12
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(len(m.Raw)))
|
||||||
|
i += copy(data[i:], m.Raw)
|
||||||
|
}
|
||||||
|
data[i] = 0x1a
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(len(m.ContentEncoding)))
|
||||||
|
i += copy(data[i:], m.ContentEncoding)
|
||||||
|
data[i] = 0x22
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(len(m.ContentType)))
|
||||||
|
i += copy(data[i:], m.ContentType)
|
||||||
|
return i, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func encodeFixed64Generated(data []byte, offset int, v uint64) int {
|
||||||
|
data[offset] = uint8(v)
|
||||||
|
data[offset+1] = uint8(v >> 8)
|
||||||
|
data[offset+2] = uint8(v >> 16)
|
||||||
|
data[offset+3] = uint8(v >> 24)
|
||||||
|
data[offset+4] = uint8(v >> 32)
|
||||||
|
data[offset+5] = uint8(v >> 40)
|
||||||
|
data[offset+6] = uint8(v >> 48)
|
||||||
|
data[offset+7] = uint8(v >> 56)
|
||||||
|
return offset + 8
|
||||||
|
}
|
||||||
|
func encodeFixed32Generated(data []byte, offset int, v uint32) int {
|
||||||
|
data[offset] = uint8(v)
|
||||||
|
data[offset+1] = uint8(v >> 8)
|
||||||
|
data[offset+2] = uint8(v >> 16)
|
||||||
|
data[offset+3] = uint8(v >> 24)
|
||||||
|
return offset + 4
|
||||||
|
}
|
||||||
|
func encodeVarintGenerated(data []byte, offset int, v uint64) int {
|
||||||
|
for v >= 1<<7 {
|
||||||
|
data[offset] = uint8(v&0x7f | 0x80)
|
||||||
|
v >>= 7
|
||||||
|
offset++
|
||||||
|
}
|
||||||
|
data[offset] = uint8(v)
|
||||||
|
return offset + 1
|
||||||
|
}
|
||||||
|
func (m *RawExtension) Size() (n int) {
|
||||||
|
var l int
|
||||||
|
_ = l
|
||||||
|
if m.Raw != nil {
|
||||||
|
l = len(m.Raw)
|
||||||
|
n += 1 + l + sovGenerated(uint64(l))
|
||||||
|
}
|
||||||
|
return n
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *TypeMeta) Size() (n int) {
|
||||||
|
var l int
|
||||||
|
_ = l
|
||||||
|
l = len(m.APIVersion)
|
||||||
|
n += 1 + l + sovGenerated(uint64(l))
|
||||||
|
l = len(m.Kind)
|
||||||
|
n += 1 + l + sovGenerated(uint64(l))
|
||||||
|
return n
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *Unknown) Size() (n int) {
|
||||||
|
var l int
|
||||||
|
_ = l
|
||||||
|
l = m.TypeMeta.Size()
|
||||||
|
n += 1 + l + sovGenerated(uint64(l))
|
||||||
|
if m.Raw != nil {
|
||||||
|
l = len(m.Raw)
|
||||||
|
n += 1 + l + sovGenerated(uint64(l))
|
||||||
|
}
|
||||||
|
l = len(m.ContentEncoding)
|
||||||
|
n += 1 + l + sovGenerated(uint64(l))
|
||||||
|
l = len(m.ContentType)
|
||||||
|
n += 1 + l + sovGenerated(uint64(l))
|
||||||
|
return n
|
||||||
|
}
|
||||||
|
|
||||||
|
func sovGenerated(x uint64) (n int) {
|
||||||
|
for {
|
||||||
|
n++
|
||||||
|
x >>= 7
|
||||||
|
if x == 0 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return n
|
||||||
|
}
|
||||||
|
func sozGenerated(x uint64) (n int) {
|
||||||
|
return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63))))
|
||||||
|
}
|
||||||
|
func (m *RawExtension) Unmarshal(data []byte) error {
|
||||||
|
l := len(data)
|
||||||
|
iNdEx := 0
|
||||||
|
for iNdEx < l {
|
||||||
|
preIndex := iNdEx
|
||||||
|
var wire uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
wire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
fieldNum := int32(wire >> 3)
|
||||||
|
wireType := int(wire & 0x7)
|
||||||
|
if wireType == 4 {
|
||||||
|
return fmt.Errorf("proto: RawExtension: wiretype end group for non-group")
|
||||||
|
}
|
||||||
|
if fieldNum <= 0 {
|
||||||
|
return fmt.Errorf("proto: RawExtension: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||||
|
}
|
||||||
|
switch fieldNum {
|
||||||
|
case 1:
|
||||||
|
if wireType != 2 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field Raw", wireType)
|
||||||
|
}
|
||||||
|
var byteLen int
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
byteLen |= (int(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if byteLen < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
postIndex := iNdEx + byteLen
|
||||||
|
if postIndex > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
m.Raw = append(m.Raw[:0], data[iNdEx:postIndex]...)
|
||||||
|
if m.Raw == nil {
|
||||||
|
m.Raw = []byte{}
|
||||||
|
}
|
||||||
|
iNdEx = postIndex
|
||||||
|
default:
|
||||||
|
iNdEx = preIndex
|
||||||
|
skippy, err := skipGenerated(data[iNdEx:])
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
if skippy < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
if (iNdEx + skippy) > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
iNdEx += skippy
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if iNdEx > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
func (m *TypeMeta) Unmarshal(data []byte) error {
|
||||||
|
l := len(data)
|
||||||
|
iNdEx := 0
|
||||||
|
for iNdEx < l {
|
||||||
|
preIndex := iNdEx
|
||||||
|
var wire uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
wire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
fieldNum := int32(wire >> 3)
|
||||||
|
wireType := int(wire & 0x7)
|
||||||
|
if wireType == 4 {
|
||||||
|
return fmt.Errorf("proto: TypeMeta: wiretype end group for non-group")
|
||||||
|
}
|
||||||
|
if fieldNum <= 0 {
|
||||||
|
return fmt.Errorf("proto: TypeMeta: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||||
|
}
|
||||||
|
switch fieldNum {
|
||||||
|
case 1:
|
||||||
|
if wireType != 2 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field APIVersion", wireType)
|
||||||
|
}
|
||||||
|
var stringLen uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
stringLen |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
intStringLen := int(stringLen)
|
||||||
|
if intStringLen < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
postIndex := iNdEx + intStringLen
|
||||||
|
if postIndex > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
m.APIVersion = string(data[iNdEx:postIndex])
|
||||||
|
iNdEx = postIndex
|
||||||
|
case 2:
|
||||||
|
if wireType != 2 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType)
|
||||||
|
}
|
||||||
|
var stringLen uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
stringLen |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
intStringLen := int(stringLen)
|
||||||
|
if intStringLen < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
postIndex := iNdEx + intStringLen
|
||||||
|
if postIndex > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
m.Kind = string(data[iNdEx:postIndex])
|
||||||
|
iNdEx = postIndex
|
||||||
|
default:
|
||||||
|
iNdEx = preIndex
|
||||||
|
skippy, err := skipGenerated(data[iNdEx:])
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
if skippy < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
if (iNdEx + skippy) > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
iNdEx += skippy
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if iNdEx > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
func (m *Unknown) Unmarshal(data []byte) error {
|
||||||
|
l := len(data)
|
||||||
|
iNdEx := 0
|
||||||
|
for iNdEx < l {
|
||||||
|
preIndex := iNdEx
|
||||||
|
var wire uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
wire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
fieldNum := int32(wire >> 3)
|
||||||
|
wireType := int(wire & 0x7)
|
||||||
|
if wireType == 4 {
|
||||||
|
return fmt.Errorf("proto: Unknown: wiretype end group for non-group")
|
||||||
|
}
|
||||||
|
if fieldNum <= 0 {
|
||||||
|
return fmt.Errorf("proto: Unknown: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||||
|
}
|
||||||
|
switch fieldNum {
|
||||||
|
case 1:
|
||||||
|
if wireType != 2 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field TypeMeta", wireType)
|
||||||
|
}
|
||||||
|
var msglen int
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
msglen |= (int(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if msglen < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
postIndex := iNdEx + msglen
|
||||||
|
if postIndex > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
if err := m.TypeMeta.Unmarshal(data[iNdEx:postIndex]); err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
iNdEx = postIndex
|
||||||
|
case 2:
|
||||||
|
if wireType != 2 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field Raw", wireType)
|
||||||
|
}
|
||||||
|
var byteLen int
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
byteLen |= (int(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if byteLen < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
postIndex := iNdEx + byteLen
|
||||||
|
if postIndex > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
m.Raw = append(m.Raw[:0], data[iNdEx:postIndex]...)
|
||||||
|
if m.Raw == nil {
|
||||||
|
m.Raw = []byte{}
|
||||||
|
}
|
||||||
|
iNdEx = postIndex
|
||||||
|
case 3:
|
||||||
|
if wireType != 2 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field ContentEncoding", wireType)
|
||||||
|
}
|
||||||
|
var stringLen uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
stringLen |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
intStringLen := int(stringLen)
|
||||||
|
if intStringLen < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
postIndex := iNdEx + intStringLen
|
||||||
|
if postIndex > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
m.ContentEncoding = string(data[iNdEx:postIndex])
|
||||||
|
iNdEx = postIndex
|
||||||
|
case 4:
|
||||||
|
if wireType != 2 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field ContentType", wireType)
|
||||||
|
}
|
||||||
|
var stringLen uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
stringLen |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
intStringLen := int(stringLen)
|
||||||
|
if intStringLen < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
postIndex := iNdEx + intStringLen
|
||||||
|
if postIndex > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
m.ContentType = string(data[iNdEx:postIndex])
|
||||||
|
iNdEx = postIndex
|
||||||
|
default:
|
||||||
|
iNdEx = preIndex
|
||||||
|
skippy, err := skipGenerated(data[iNdEx:])
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
if skippy < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
if (iNdEx + skippy) > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
iNdEx += skippy
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if iNdEx > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
func skipGenerated(data []byte) (n int, err error) {
|
||||||
|
l := len(data)
|
||||||
|
iNdEx := 0
|
||||||
|
for iNdEx < l {
|
||||||
|
var wire uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
wire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
wireType := int(wire & 0x7)
|
||||||
|
switch wireType {
|
||||||
|
case 0:
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
iNdEx++
|
||||||
|
if data[iNdEx-1] < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return iNdEx, nil
|
||||||
|
case 1:
|
||||||
|
iNdEx += 8
|
||||||
|
return iNdEx, nil
|
||||||
|
case 2:
|
||||||
|
var length int
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
length |= (int(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
iNdEx += length
|
||||||
|
if length < 0 {
|
||||||
|
return 0, ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
return iNdEx, nil
|
||||||
|
case 3:
|
||||||
|
for {
|
||||||
|
var innerWire uint64
|
||||||
|
var start int = iNdEx
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
innerWire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
innerWireType := int(innerWire & 0x7)
|
||||||
|
if innerWireType == 4 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
next, err := skipGenerated(data[start:])
|
||||||
|
if err != nil {
|
||||||
|
return 0, err
|
||||||
|
}
|
||||||
|
iNdEx = start + next
|
||||||
|
}
|
||||||
|
return iNdEx, nil
|
||||||
|
case 4:
|
||||||
|
return iNdEx, nil
|
||||||
|
case 5:
|
||||||
|
iNdEx += 4
|
||||||
|
return iNdEx, nil
|
||||||
|
default:
|
||||||
|
return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
panic("unreachable")
|
||||||
|
}
|
||||||
|
|
||||||
|
var (
|
||||||
|
ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling")
|
||||||
|
ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow")
|
||||||
|
)
|
121
pkg/runtime/generated.proto
Normal file
121
pkg/runtime/generated.proto
Normal file
@@ -0,0 +1,121 @@
|
|||||||
|
/*
|
||||||
|
Copyright 2016 The Kubernetes Authors All rights reserved.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
// This file was autogenerated by go-to-protobuf. Do not edit it manually!
|
||||||
|
|
||||||
|
syntax = 'proto2';
|
||||||
|
|
||||||
|
package k8s.io.kubernetes.pkg.runtime;
|
||||||
|
|
||||||
|
import "k8s.io/kubernetes/pkg/api/resource/generated.proto";
|
||||||
|
import "k8s.io/kubernetes/pkg/util/intstr/generated.proto";
|
||||||
|
|
||||||
|
// Package-wide variables from generator "generated".
|
||||||
|
option go_package = "runtime";
|
||||||
|
|
||||||
|
// RawExtension is used to hold extensions in external versions.
|
||||||
|
//
|
||||||
|
// To use this, make a field which has RawExtension as its type in your external, versioned
|
||||||
|
// struct, and Object in your internal struct. You also need to register your
|
||||||
|
// various plugin types.
|
||||||
|
//
|
||||||
|
// // Internal package:
|
||||||
|
// type MyAPIObject struct {
|
||||||
|
// runtime.TypeMeta `json:",inline"`
|
||||||
|
// MyPlugin runtime.Object `json:"myPlugin"`
|
||||||
|
// }
|
||||||
|
// type PluginA struct {
|
||||||
|
// AOption string `json:"aOption"`
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// // External package:
|
||||||
|
// type MyAPIObject struct {
|
||||||
|
// runtime.TypeMeta `json:",inline"`
|
||||||
|
// MyPlugin runtime.RawExtension `json:"myPlugin"`
|
||||||
|
// }
|
||||||
|
// type PluginA struct {
|
||||||
|
// AOption string `json:"aOption"`
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// // On the wire, the JSON will look something like this:
|
||||||
|
// {
|
||||||
|
// "kind":"MyAPIObject",
|
||||||
|
// "apiVersion":"v1",
|
||||||
|
// "myPlugin": {
|
||||||
|
// "kind":"PluginA",
|
||||||
|
// "aOption":"foo",
|
||||||
|
// },
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// So what happens? Decode first uses json or yaml to unmarshal the serialized data into
|
||||||
|
// your external MyAPIObject. That causes the raw JSON to be stored, but not unpacked.
|
||||||
|
// The next step is to copy (using pkg/conversion) into the internal struct. The runtime
|
||||||
|
// package's DefaultScheme has conversion functions installed which will unpack the
|
||||||
|
// JSON stored in RawExtension, turning it into the correct object type, and storing it
|
||||||
|
// in the Object. (TODO: In the case where the object is of an unknown type, a
|
||||||
|
// runtime.Unknown object will be created and stored.)
|
||||||
|
//
|
||||||
|
// +protobuf=true
|
||||||
|
message RawExtension {
|
||||||
|
// Raw is the underlying serialization of this object.
|
||||||
|
//
|
||||||
|
// TODO: Determine how to detect ContentType and ContentEncoding of 'Raw' data.
|
||||||
|
optional bytes raw = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
// TypeMeta is shared by all top level objects. The proper way to use it is to inline it in your type,
|
||||||
|
// like this:
|
||||||
|
// type MyAwesomeAPIObject struct {
|
||||||
|
// runtime.TypeMeta `json:",inline"`
|
||||||
|
// ... // other fields
|
||||||
|
// }
|
||||||
|
// func (obj *MyAwesomeAPIObject) SetGroupVersionKind(gvk *unversioned.GroupVersionKind) { unversioned.UpdateTypeMeta(obj,gvk) }; GroupVersionKind() *GroupVersionKind
|
||||||
|
//
|
||||||
|
// TypeMeta is provided here for convenience. You may use it directly from this package or define
|
||||||
|
// your own with the same fields.
|
||||||
|
//
|
||||||
|
// +protobuf=true
|
||||||
|
message TypeMeta {
|
||||||
|
optional string apiVersion = 1;
|
||||||
|
|
||||||
|
optional string kind = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Unknown allows api objects with unknown types to be passed-through. This can be used
|
||||||
|
// to deal with the API objects from a plug-in. Unknown objects still have functioning
|
||||||
|
// TypeMeta features-- kind, version, etc.
|
||||||
|
// TODO: Make this object have easy access to field based accessors and settors for
|
||||||
|
// metadata and field mutatation.
|
||||||
|
//
|
||||||
|
// +protobuf=true
|
||||||
|
message Unknown {
|
||||||
|
optional TypeMeta typeMeta = 1;
|
||||||
|
|
||||||
|
// Raw will hold the complete serialized object which couldn't be matched
|
||||||
|
// with a registered type. Most likely, nothing should be done with this
|
||||||
|
// except for passing it through the system.
|
||||||
|
optional bytes raw = 2;
|
||||||
|
|
||||||
|
// ContentEncoding is encoding used to encode 'Raw' data.
|
||||||
|
// Unspecified means no encoding.
|
||||||
|
optional string contentEncoding = 3;
|
||||||
|
|
||||||
|
// ContentType is serialization method used to serialize 'Raw'.
|
||||||
|
// Unspecified means ContentTypeJSON.
|
||||||
|
optional string contentType = 4;
|
||||||
|
}
|
||||||
|
|
@@ -32,8 +32,8 @@ package runtime
|
|||||||
//
|
//
|
||||||
// +protobuf=true
|
// +protobuf=true
|
||||||
type TypeMeta struct {
|
type TypeMeta struct {
|
||||||
APIVersion string `json:"apiVersion,omitempty" yaml:"apiVersion,omitempty"`
|
APIVersion string `json:"apiVersion,omitempty" yaml:"apiVersion,omitempty" protobuf:"bytes,1,opt,name=apiVersion"`
|
||||||
Kind string `json:"kind,omitempty" yaml:"kind,omitempty"`
|
Kind string `json:"kind,omitempty" yaml:"kind,omitempty" protobuf:"bytes,2,opt,name=kind"`
|
||||||
}
|
}
|
||||||
|
|
||||||
const (
|
const (
|
||||||
@@ -87,7 +87,7 @@ type RawExtension struct {
|
|||||||
// Raw is the underlying serialization of this object.
|
// Raw is the underlying serialization of this object.
|
||||||
//
|
//
|
||||||
// TODO: Determine how to detect ContentType and ContentEncoding of 'Raw' data.
|
// TODO: Determine how to detect ContentType and ContentEncoding of 'Raw' data.
|
||||||
Raw []byte
|
Raw []byte `protobuf:"bytes,1,opt,name=raw"`
|
||||||
// Object can hold a representation of this extension - useful for working with versioned
|
// Object can hold a representation of this extension - useful for working with versioned
|
||||||
// structs.
|
// structs.
|
||||||
Object Object `json:"-"`
|
Object Object `json:"-"`
|
||||||
@@ -101,17 +101,17 @@ type RawExtension struct {
|
|||||||
//
|
//
|
||||||
// +protobuf=true
|
// +protobuf=true
|
||||||
type Unknown struct {
|
type Unknown struct {
|
||||||
TypeMeta `json:",inline"`
|
TypeMeta `json:",inline" protobuf:"bytes,1,opt,name=typeMeta"`
|
||||||
// Raw will hold the complete serialized object which couldn't be matched
|
// Raw will hold the complete serialized object which couldn't be matched
|
||||||
// with a registered type. Most likely, nothing should be done with this
|
// with a registered type. Most likely, nothing should be done with this
|
||||||
// except for passing it through the system.
|
// except for passing it through the system.
|
||||||
Raw []byte
|
Raw []byte `protobuf:"bytes,2,opt,name=raw"`
|
||||||
// ContentEncoding is encoding used to encode 'Raw' data.
|
// ContentEncoding is encoding used to encode 'Raw' data.
|
||||||
// Unspecified means no encoding.
|
// Unspecified means no encoding.
|
||||||
ContentEncoding string
|
ContentEncoding string `protobuf:"bytes,3,opt,name=contentEncoding"`
|
||||||
// ContentType is serialization method used to serialize 'Raw'.
|
// ContentType is serialization method used to serialize 'Raw'.
|
||||||
// Unspecified means ContentTypeJSON.
|
// Unspecified means ContentTypeJSON.
|
||||||
ContentType string
|
ContentType string `protobuf:"bytes,4,opt,name=contentType"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Unstructured allows objects that do not have Golang structs registered to be manipulated
|
// Unstructured allows objects that do not have Golang structs registered to be manipulated
|
||||||
|
348
pkg/util/intstr/generated.pb.go
Normal file
348
pkg/util/intstr/generated.pb.go
Normal file
@@ -0,0 +1,348 @@
|
|||||||
|
/*
|
||||||
|
Copyright 2016 The Kubernetes Authors All rights reserved.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by protoc-gen-gogo.
|
||||||
|
// source: k8s.io/kubernetes/pkg/util/intstr/generated.proto
|
||||||
|
// DO NOT EDIT!
|
||||||
|
|
||||||
|
/*
|
||||||
|
Package intstr is a generated protocol buffer package.
|
||||||
|
|
||||||
|
It is generated from these files:
|
||||||
|
k8s.io/kubernetes/pkg/util/intstr/generated.proto
|
||||||
|
|
||||||
|
It has these top-level messages:
|
||||||
|
IntOrString
|
||||||
|
*/
|
||||||
|
package intstr
|
||||||
|
|
||||||
|
import proto "github.com/gogo/protobuf/proto"
|
||||||
|
import fmt "fmt"
|
||||||
|
import math "math"
|
||||||
|
import _ "github.com/gogo/protobuf/gogoproto"
|
||||||
|
|
||||||
|
import io "io"
|
||||||
|
|
||||||
|
// Reference imports to suppress errors if they are not otherwise used.
|
||||||
|
var _ = proto.Marshal
|
||||||
|
var _ = fmt.Errorf
|
||||||
|
var _ = math.Inf
|
||||||
|
|
||||||
|
func (m *IntOrString) Reset() { *m = IntOrString{} }
|
||||||
|
func (*IntOrString) ProtoMessage() {}
|
||||||
|
|
||||||
|
func init() {
|
||||||
|
proto.RegisterType((*IntOrString)(nil), "k8s.io.kubernetes.pkg.util.intstr.IntOrString")
|
||||||
|
}
|
||||||
|
func (m *IntOrString) Marshal() (data []byte, err error) {
|
||||||
|
size := m.Size()
|
||||||
|
data = make([]byte, size)
|
||||||
|
n, err := m.MarshalTo(data)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
return data[:n], nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *IntOrString) MarshalTo(data []byte) (int, error) {
|
||||||
|
var i int
|
||||||
|
_ = i
|
||||||
|
var l int
|
||||||
|
_ = l
|
||||||
|
data[i] = 0x8
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(m.Type))
|
||||||
|
data[i] = 0x10
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(m.IntVal))
|
||||||
|
data[i] = 0x1a
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(len(m.StrVal)))
|
||||||
|
i += copy(data[i:], m.StrVal)
|
||||||
|
return i, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func encodeFixed64Generated(data []byte, offset int, v uint64) int {
|
||||||
|
data[offset] = uint8(v)
|
||||||
|
data[offset+1] = uint8(v >> 8)
|
||||||
|
data[offset+2] = uint8(v >> 16)
|
||||||
|
data[offset+3] = uint8(v >> 24)
|
||||||
|
data[offset+4] = uint8(v >> 32)
|
||||||
|
data[offset+5] = uint8(v >> 40)
|
||||||
|
data[offset+6] = uint8(v >> 48)
|
||||||
|
data[offset+7] = uint8(v >> 56)
|
||||||
|
return offset + 8
|
||||||
|
}
|
||||||
|
func encodeFixed32Generated(data []byte, offset int, v uint32) int {
|
||||||
|
data[offset] = uint8(v)
|
||||||
|
data[offset+1] = uint8(v >> 8)
|
||||||
|
data[offset+2] = uint8(v >> 16)
|
||||||
|
data[offset+3] = uint8(v >> 24)
|
||||||
|
return offset + 4
|
||||||
|
}
|
||||||
|
func encodeVarintGenerated(data []byte, offset int, v uint64) int {
|
||||||
|
for v >= 1<<7 {
|
||||||
|
data[offset] = uint8(v&0x7f | 0x80)
|
||||||
|
v >>= 7
|
||||||
|
offset++
|
||||||
|
}
|
||||||
|
data[offset] = uint8(v)
|
||||||
|
return offset + 1
|
||||||
|
}
|
||||||
|
func (m *IntOrString) Size() (n int) {
|
||||||
|
var l int
|
||||||
|
_ = l
|
||||||
|
n += 1 + sovGenerated(uint64(m.Type))
|
||||||
|
n += 1 + sovGenerated(uint64(m.IntVal))
|
||||||
|
l = len(m.StrVal)
|
||||||
|
n += 1 + l + sovGenerated(uint64(l))
|
||||||
|
return n
|
||||||
|
}
|
||||||
|
|
||||||
|
func sovGenerated(x uint64) (n int) {
|
||||||
|
for {
|
||||||
|
n++
|
||||||
|
x >>= 7
|
||||||
|
if x == 0 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return n
|
||||||
|
}
|
||||||
|
func sozGenerated(x uint64) (n int) {
|
||||||
|
return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63))))
|
||||||
|
}
|
||||||
|
func (m *IntOrString) Unmarshal(data []byte) error {
|
||||||
|
l := len(data)
|
||||||
|
iNdEx := 0
|
||||||
|
for iNdEx < l {
|
||||||
|
preIndex := iNdEx
|
||||||
|
var wire uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
wire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
fieldNum := int32(wire >> 3)
|
||||||
|
wireType := int(wire & 0x7)
|
||||||
|
if wireType == 4 {
|
||||||
|
return fmt.Errorf("proto: IntOrString: wiretype end group for non-group")
|
||||||
|
}
|
||||||
|
if fieldNum <= 0 {
|
||||||
|
return fmt.Errorf("proto: IntOrString: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||||
|
}
|
||||||
|
switch fieldNum {
|
||||||
|
case 1:
|
||||||
|
if wireType != 0 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
|
||||||
|
}
|
||||||
|
m.Type = 0
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
m.Type |= (Type(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
case 2:
|
||||||
|
if wireType != 0 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field IntVal", wireType)
|
||||||
|
}
|
||||||
|
m.IntVal = 0
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
m.IntVal |= (int32(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
case 3:
|
||||||
|
if wireType != 2 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field StrVal", wireType)
|
||||||
|
}
|
||||||
|
var stringLen uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
stringLen |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
intStringLen := int(stringLen)
|
||||||
|
if intStringLen < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
postIndex := iNdEx + intStringLen
|
||||||
|
if postIndex > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
m.StrVal = string(data[iNdEx:postIndex])
|
||||||
|
iNdEx = postIndex
|
||||||
|
default:
|
||||||
|
iNdEx = preIndex
|
||||||
|
skippy, err := skipGenerated(data[iNdEx:])
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
if skippy < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
if (iNdEx + skippy) > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
iNdEx += skippy
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if iNdEx > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
func skipGenerated(data []byte) (n int, err error) {
|
||||||
|
l := len(data)
|
||||||
|
iNdEx := 0
|
||||||
|
for iNdEx < l {
|
||||||
|
var wire uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
wire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
wireType := int(wire & 0x7)
|
||||||
|
switch wireType {
|
||||||
|
case 0:
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
iNdEx++
|
||||||
|
if data[iNdEx-1] < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return iNdEx, nil
|
||||||
|
case 1:
|
||||||
|
iNdEx += 8
|
||||||
|
return iNdEx, nil
|
||||||
|
case 2:
|
||||||
|
var length int
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
length |= (int(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
iNdEx += length
|
||||||
|
if length < 0 {
|
||||||
|
return 0, ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
return iNdEx, nil
|
||||||
|
case 3:
|
||||||
|
for {
|
||||||
|
var innerWire uint64
|
||||||
|
var start int = iNdEx
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
innerWire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
innerWireType := int(innerWire & 0x7)
|
||||||
|
if innerWireType == 4 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
next, err := skipGenerated(data[start:])
|
||||||
|
if err != nil {
|
||||||
|
return 0, err
|
||||||
|
}
|
||||||
|
iNdEx = start + next
|
||||||
|
}
|
||||||
|
return iNdEx, nil
|
||||||
|
case 4:
|
||||||
|
return iNdEx, nil
|
||||||
|
case 5:
|
||||||
|
iNdEx += 4
|
||||||
|
return iNdEx, nil
|
||||||
|
default:
|
||||||
|
return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
panic("unreachable")
|
||||||
|
}
|
||||||
|
|
||||||
|
var (
|
||||||
|
ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling")
|
||||||
|
ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow")
|
||||||
|
)
|
42
pkg/util/intstr/generated.proto
Normal file
42
pkg/util/intstr/generated.proto
Normal file
@@ -0,0 +1,42 @@
|
|||||||
|
/*
|
||||||
|
Copyright 2016 The Kubernetes Authors All rights reserved.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
// This file was autogenerated by go-to-protobuf. Do not edit it manually!
|
||||||
|
|
||||||
|
syntax = 'proto2';
|
||||||
|
|
||||||
|
package k8s.io.kubernetes.pkg.util.intstr;
|
||||||
|
|
||||||
|
// Package-wide variables from generator "generated".
|
||||||
|
option go_package = "intstr";
|
||||||
|
|
||||||
|
// IntOrString is a type that can hold an int32 or a string. When used in
|
||||||
|
// JSON or YAML marshalling and unmarshalling, it produces or consumes the
|
||||||
|
// inner type. This allows you to have, for example, a JSON field that can
|
||||||
|
// accept a name or number.
|
||||||
|
// TODO: Rename to Int32OrString
|
||||||
|
//
|
||||||
|
// +protobuf=true
|
||||||
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
|
message IntOrString {
|
||||||
|
optional int64 type = 1;
|
||||||
|
|
||||||
|
optional int32 intVal = 2;
|
||||||
|
|
||||||
|
optional string strVal = 3;
|
||||||
|
}
|
||||||
|
|
@@ -35,9 +35,9 @@ import (
|
|||||||
// +protobuf=true
|
// +protobuf=true
|
||||||
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
// +protobuf.options.(gogoproto.goproto_stringer)=false
|
||||||
type IntOrString struct {
|
type IntOrString struct {
|
||||||
Type Type
|
Type Type `protobuf:"varint,1,opt,name=type,casttype=Type"`
|
||||||
IntVal int32
|
IntVal int32 `protobuf:"varint,2,opt,name=intVal"`
|
||||||
StrVal string
|
StrVal string `protobuf:"bytes,3,opt,name=strVal"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// Type represents the stored type of IntOrString.
|
// Type represents the stored type of IntOrString.
|
||||||
|
345
pkg/watch/versioned/generated.pb.go
Normal file
345
pkg/watch/versioned/generated.pb.go
Normal file
@@ -0,0 +1,345 @@
|
|||||||
|
/*
|
||||||
|
Copyright 2016 The Kubernetes Authors All rights reserved.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
// Code generated by protoc-gen-gogo.
|
||||||
|
// source: k8s.io/kubernetes/pkg/watch/versioned/generated.proto
|
||||||
|
// DO NOT EDIT!
|
||||||
|
|
||||||
|
/*
|
||||||
|
Package versioned is a generated protocol buffer package.
|
||||||
|
|
||||||
|
It is generated from these files:
|
||||||
|
k8s.io/kubernetes/pkg/watch/versioned/generated.proto
|
||||||
|
|
||||||
|
It has these top-level messages:
|
||||||
|
Event
|
||||||
|
*/
|
||||||
|
package versioned
|
||||||
|
|
||||||
|
import proto "github.com/gogo/protobuf/proto"
|
||||||
|
import fmt "fmt"
|
||||||
|
import math "math"
|
||||||
|
import _ "github.com/gogo/protobuf/gogoproto"
|
||||||
|
|
||||||
|
import _ "k8s.io/kubernetes/pkg/util/intstr"
|
||||||
|
|
||||||
|
import io "io"
|
||||||
|
|
||||||
|
// Reference imports to suppress errors if they are not otherwise used.
|
||||||
|
var _ = proto.Marshal
|
||||||
|
var _ = fmt.Errorf
|
||||||
|
var _ = math.Inf
|
||||||
|
|
||||||
|
func (m *Event) Reset() { *m = Event{} }
|
||||||
|
func (m *Event) String() string { return proto.CompactTextString(m) }
|
||||||
|
func (*Event) ProtoMessage() {}
|
||||||
|
|
||||||
|
func init() {
|
||||||
|
proto.RegisterType((*Event)(nil), "k8s.io.kubernetes.pkg.watch.versioned.Event")
|
||||||
|
}
|
||||||
|
func (m *Event) Marshal() (data []byte, err error) {
|
||||||
|
size := m.Size()
|
||||||
|
data = make([]byte, size)
|
||||||
|
n, err := m.MarshalTo(data)
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
return data[:n], nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func (m *Event) MarshalTo(data []byte) (int, error) {
|
||||||
|
var i int
|
||||||
|
_ = i
|
||||||
|
var l int
|
||||||
|
_ = l
|
||||||
|
data[i] = 0xa
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(len(m.Type)))
|
||||||
|
i += copy(data[i:], m.Type)
|
||||||
|
data[i] = 0x12
|
||||||
|
i++
|
||||||
|
i = encodeVarintGenerated(data, i, uint64(m.Object.Size()))
|
||||||
|
n1, err := m.Object.MarshalTo(data[i:])
|
||||||
|
if err != nil {
|
||||||
|
return 0, err
|
||||||
|
}
|
||||||
|
i += n1
|
||||||
|
return i, nil
|
||||||
|
}
|
||||||
|
|
||||||
|
func encodeFixed64Generated(data []byte, offset int, v uint64) int {
|
||||||
|
data[offset] = uint8(v)
|
||||||
|
data[offset+1] = uint8(v >> 8)
|
||||||
|
data[offset+2] = uint8(v >> 16)
|
||||||
|
data[offset+3] = uint8(v >> 24)
|
||||||
|
data[offset+4] = uint8(v >> 32)
|
||||||
|
data[offset+5] = uint8(v >> 40)
|
||||||
|
data[offset+6] = uint8(v >> 48)
|
||||||
|
data[offset+7] = uint8(v >> 56)
|
||||||
|
return offset + 8
|
||||||
|
}
|
||||||
|
func encodeFixed32Generated(data []byte, offset int, v uint32) int {
|
||||||
|
data[offset] = uint8(v)
|
||||||
|
data[offset+1] = uint8(v >> 8)
|
||||||
|
data[offset+2] = uint8(v >> 16)
|
||||||
|
data[offset+3] = uint8(v >> 24)
|
||||||
|
return offset + 4
|
||||||
|
}
|
||||||
|
func encodeVarintGenerated(data []byte, offset int, v uint64) int {
|
||||||
|
for v >= 1<<7 {
|
||||||
|
data[offset] = uint8(v&0x7f | 0x80)
|
||||||
|
v >>= 7
|
||||||
|
offset++
|
||||||
|
}
|
||||||
|
data[offset] = uint8(v)
|
||||||
|
return offset + 1
|
||||||
|
}
|
||||||
|
func (m *Event) Size() (n int) {
|
||||||
|
var l int
|
||||||
|
_ = l
|
||||||
|
l = len(m.Type)
|
||||||
|
n += 1 + l + sovGenerated(uint64(l))
|
||||||
|
l = m.Object.Size()
|
||||||
|
n += 1 + l + sovGenerated(uint64(l))
|
||||||
|
return n
|
||||||
|
}
|
||||||
|
|
||||||
|
func sovGenerated(x uint64) (n int) {
|
||||||
|
for {
|
||||||
|
n++
|
||||||
|
x >>= 7
|
||||||
|
if x == 0 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return n
|
||||||
|
}
|
||||||
|
func sozGenerated(x uint64) (n int) {
|
||||||
|
return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63))))
|
||||||
|
}
|
||||||
|
func (m *Event) Unmarshal(data []byte) error {
|
||||||
|
l := len(data)
|
||||||
|
iNdEx := 0
|
||||||
|
for iNdEx < l {
|
||||||
|
preIndex := iNdEx
|
||||||
|
var wire uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
wire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
fieldNum := int32(wire >> 3)
|
||||||
|
wireType := int(wire & 0x7)
|
||||||
|
if wireType == 4 {
|
||||||
|
return fmt.Errorf("proto: Event: wiretype end group for non-group")
|
||||||
|
}
|
||||||
|
if fieldNum <= 0 {
|
||||||
|
return fmt.Errorf("proto: Event: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||||
|
}
|
||||||
|
switch fieldNum {
|
||||||
|
case 1:
|
||||||
|
if wireType != 2 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
|
||||||
|
}
|
||||||
|
var stringLen uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
stringLen |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
intStringLen := int(stringLen)
|
||||||
|
if intStringLen < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
postIndex := iNdEx + intStringLen
|
||||||
|
if postIndex > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
m.Type = string(data[iNdEx:postIndex])
|
||||||
|
iNdEx = postIndex
|
||||||
|
case 2:
|
||||||
|
if wireType != 2 {
|
||||||
|
return fmt.Errorf("proto: wrong wireType = %d for field Object", wireType)
|
||||||
|
}
|
||||||
|
var msglen int
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
msglen |= (int(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if msglen < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
postIndex := iNdEx + msglen
|
||||||
|
if postIndex > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
if err := m.Object.Unmarshal(data[iNdEx:postIndex]); err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
iNdEx = postIndex
|
||||||
|
default:
|
||||||
|
iNdEx = preIndex
|
||||||
|
skippy, err := skipGenerated(data[iNdEx:])
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
if skippy < 0 {
|
||||||
|
return ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
if (iNdEx + skippy) > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
iNdEx += skippy
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if iNdEx > l {
|
||||||
|
return io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
func skipGenerated(data []byte) (n int, err error) {
|
||||||
|
l := len(data)
|
||||||
|
iNdEx := 0
|
||||||
|
for iNdEx < l {
|
||||||
|
var wire uint64
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
wire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
wireType := int(wire & 0x7)
|
||||||
|
switch wireType {
|
||||||
|
case 0:
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
iNdEx++
|
||||||
|
if data[iNdEx-1] < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return iNdEx, nil
|
||||||
|
case 1:
|
||||||
|
iNdEx += 8
|
||||||
|
return iNdEx, nil
|
||||||
|
case 2:
|
||||||
|
var length int
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
length |= (int(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
iNdEx += length
|
||||||
|
if length < 0 {
|
||||||
|
return 0, ErrInvalidLengthGenerated
|
||||||
|
}
|
||||||
|
return iNdEx, nil
|
||||||
|
case 3:
|
||||||
|
for {
|
||||||
|
var innerWire uint64
|
||||||
|
var start int = iNdEx
|
||||||
|
for shift := uint(0); ; shift += 7 {
|
||||||
|
if shift >= 64 {
|
||||||
|
return 0, ErrIntOverflowGenerated
|
||||||
|
}
|
||||||
|
if iNdEx >= l {
|
||||||
|
return 0, io.ErrUnexpectedEOF
|
||||||
|
}
|
||||||
|
b := data[iNdEx]
|
||||||
|
iNdEx++
|
||||||
|
innerWire |= (uint64(b) & 0x7F) << shift
|
||||||
|
if b < 0x80 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
innerWireType := int(innerWire & 0x7)
|
||||||
|
if innerWireType == 4 {
|
||||||
|
break
|
||||||
|
}
|
||||||
|
next, err := skipGenerated(data[start:])
|
||||||
|
if err != nil {
|
||||||
|
return 0, err
|
||||||
|
}
|
||||||
|
iNdEx = start + next
|
||||||
|
}
|
||||||
|
return iNdEx, nil
|
||||||
|
case 4:
|
||||||
|
return iNdEx, nil
|
||||||
|
case 5:
|
||||||
|
iNdEx += 4
|
||||||
|
return iNdEx, nil
|
||||||
|
default:
|
||||||
|
return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
panic("unreachable")
|
||||||
|
}
|
||||||
|
|
||||||
|
var (
|
||||||
|
ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling")
|
||||||
|
ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow")
|
||||||
|
)
|
43
pkg/watch/versioned/generated.proto
Normal file
43
pkg/watch/versioned/generated.proto
Normal file
@@ -0,0 +1,43 @@
|
|||||||
|
/*
|
||||||
|
Copyright 2016 The Kubernetes Authors All rights reserved.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
// This file was autogenerated by go-to-protobuf. Do not edit it manually!
|
||||||
|
|
||||||
|
syntax = 'proto2';
|
||||||
|
|
||||||
|
package k8s.io.kubernetes.pkg.watch.versioned;
|
||||||
|
|
||||||
|
import "k8s.io/kubernetes/pkg/runtime/generated.proto";
|
||||||
|
import "k8s.io/kubernetes/pkg/util/intstr/generated.proto";
|
||||||
|
|
||||||
|
// Package-wide variables from generator "generated".
|
||||||
|
option go_package = "versioned";
|
||||||
|
|
||||||
|
// Event represents a single event to a watched resource.
|
||||||
|
//
|
||||||
|
// +protobuf=true
|
||||||
|
message Event {
|
||||||
|
optional string type = 1;
|
||||||
|
|
||||||
|
// Object is:
|
||||||
|
// * If Type is Added or Modified: the new state of the object.
|
||||||
|
// * If Type is Deleted: the state of the object immediately before deletion.
|
||||||
|
// * If Type is Error: *api.Status is recommended; other types may make sense
|
||||||
|
// depending on context.
|
||||||
|
optional k8s.io.kubernetes.pkg.runtime.RawExtension object = 2;
|
||||||
|
}
|
||||||
|
|
Reference in New Issue
Block a user