diff --git a/go.mod b/go.mod index 0b1f58c3d..a0b27f3c0 100644 --- a/go.mod +++ b/go.mod @@ -29,8 +29,8 @@ require ( kmodules.xyz/client-go v0.30.9 kmodules.xyz/custom-resources v0.30.0 kmodules.xyz/monitoring-agent-api v0.29.0 - kubedb.dev/apimachinery v0.47.0-rc.1 - kubedb.dev/db-client-go v0.2.0-rc.1 + kubedb.dev/apimachinery v0.47.0-rc.2 + kubedb.dev/db-client-go v0.2.0-rc.2 sigs.k8s.io/controller-runtime v0.18.4 sigs.k8s.io/yaml v1.4.0 stash.appscode.dev/apimachinery v0.34.0 @@ -115,11 +115,11 @@ require ( github.com/zeebo/xxh3 v1.0.2 // indirect go.starlark.net v0.0.0-20230525235612-a134d8f9ddca // indirect golang.org/x/exp v0.0.0-20240506185415-9bf2ced13842 // indirect - golang.org/x/net v0.26.0 // indirect + golang.org/x/net v0.27.0 // indirect golang.org/x/oauth2 v0.21.0 // indirect golang.org/x/sync v0.7.0 // indirect - golang.org/x/sys v0.21.0 // indirect - golang.org/x/term v0.21.0 // indirect + golang.org/x/sys v0.22.0 // indirect + golang.org/x/term v0.22.0 // indirect golang.org/x/time v0.5.0 // indirect gomodules.xyz/clock v0.0.0-20200817085942-06523dba733f // indirect gomodules.xyz/encoding v0.0.8 // indirect @@ -142,7 +142,7 @@ require ( kmodules.xyz/objectstore-api v0.29.1 // indirect kmodules.xyz/offshoot-api v0.30.0 // indirect kmodules.xyz/prober v0.29.0 // indirect - kmodules.xyz/resource-metadata v0.18.10 // indirect + kmodules.xyz/resource-metadata v0.18.11-0.20240801195527-995886d0c0e5 // indirect kubeops.dev/petset v0.0.6 // indirect kubeops.dev/sidekick v0.0.7 // indirect kubestash.dev/apimachinery v0.10.0 // indirect diff --git a/go.sum b/go.sum index 1dafc0ed7..95506b321 100644 --- a/go.sum +++ b/go.sum @@ -492,8 +492,8 @@ golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= golang.org/x/net v0.7.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg= golang.org/x/net v0.17.0/go.mod h1:NxSsAGuq816PNPmqtQdLE42eU2Fs7NoRIZrHJAlaCOE= -golang.org/x/net v0.26.0 h1:soB7SVo0PWrY4vPW/+ay0jKDNScG2X9wFeYlXIvJsOQ= -golang.org/x/net v0.26.0/go.mod h1:5YKkiSynbBIh3p6iOc/vibscux0x38BZDkn8sCUPxHE= +golang.org/x/net v0.27.0 h1:5K3Njcw06/l2y9vpGCSdcxWOYHOUk3dVNGDXN+FvAys= +golang.org/x/net v0.27.0/go.mod h1:dDi0PyhWNoiUOrAS8uXv/vnScO4wnHQO4mj9fn/RytE= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -535,8 +535,8 @@ golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.13.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.21.0 h1:rF+pYz3DAGSQAxAu1CbC7catZg4ebC4UIeIhKxBZvws= -golang.org/x/sys v0.21.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.22.0 h1:RI27ohtqKCnwULzJLqkv897zojh5/DwS/ENaMzUOaWI= +golang.org/x/sys v0.22.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.0.0-20220526004731-065cf7ba2467/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= @@ -544,8 +544,8 @@ golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= golang.org/x/term v0.8.0/go.mod h1:xPskH00ivmX89bAKVGSKKtLOWNx2+17Eiy94tnKShWo= golang.org/x/term v0.13.0/go.mod h1:LTmsnFJwVN6bCy1rVCoS+qHT1HhALEFxKncY3WNNh4U= -golang.org/x/term v0.21.0 h1:WVXCp+/EBEHOj53Rvu+7KiT/iElMrO8ACK16SMZ3jaA= -golang.org/x/term v0.21.0/go.mod h1:ooXLefLobQVslOqselCNF4SxFAaoS6KujMbsGzSDmX0= +golang.org/x/term v0.22.0 h1:BbsgPEJULsl2fV/AT3v15Mjva5yXKQDyKf+TbDz7QJk= +golang.org/x/term v0.22.0/go.mod h1:F3qCibpT5AMpCRfhfT53vVJwhLtIVHhB9XDjfFvnMI4= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= @@ -723,12 +723,12 @@ kmodules.xyz/offshoot-api v0.30.0 h1:dq9F93pu4Q8rL9oTcCk+vGGy8vpS7RNt0GSwx7Bvhec kmodules.xyz/offshoot-api v0.30.0/go.mod h1:o9VoA3ImZMDBp3lpLb8+kc2d/KBxioRwCpaKDfLIyDw= kmodules.xyz/prober v0.29.0 h1:Ex7m4F9rH7uWNNJlLgP63ROOM+nUATJkC2L5OQ7nwMg= kmodules.xyz/prober v0.29.0/go.mod h1:UtK+HKyI1lFLEKX+HFLyOCVju6TO93zv3kwGpzqmKOo= -kmodules.xyz/resource-metadata v0.18.10 h1:B0DAMsJJBuSOGCKzptZvB8AWcbxzDdUm+3CIE7g9ftE= -kmodules.xyz/resource-metadata v0.18.10/go.mod h1:PXyZXif1b1QRpe0Pwr92OeOveptZricB0jLssCjsYTc= -kubedb.dev/apimachinery v0.47.0-rc.1 h1:5DXoahPbJ1n1Fowa+lv3xobTWRLzDDKGhJaNiWjV/tk= -kubedb.dev/apimachinery v0.47.0-rc.1/go.mod h1:AUV5sXVwo77ctiYyrFWsSrhkuvy5fru5baiX7xF6LBA= -kubedb.dev/db-client-go v0.2.0-rc.1 h1:EonjzXR56vlDQYAYXTiyr1/ntxdOx5ClpCZ7Vs5eUhU= -kubedb.dev/db-client-go v0.2.0-rc.1/go.mod h1:yvkeoYGXCt119xogPO30sj2J3PYLOh/e32NyLv+ZWDc= +kmodules.xyz/resource-metadata v0.18.11-0.20240801195527-995886d0c0e5 h1:9RQEeMpYabFmWTRdeLwHl/ZnlcyR+WKLnIWdg6eiCTA= +kmodules.xyz/resource-metadata v0.18.11-0.20240801195527-995886d0c0e5/go.mod h1:1mOc2/WgOsn+f4tBKbHw8JgjWAEF52I6gOsVpyUE10M= +kubedb.dev/apimachinery v0.47.0-rc.2 h1:pdtbBiLM0VQw8HoJ3Z2tp4PZX5y66CIYBRCIn7inADI= +kubedb.dev/apimachinery v0.47.0-rc.2/go.mod h1:XkzWrijuH4skCU2ru+Ye9O0KSWQ7Nn2mRjP3+F3StLk= +kubedb.dev/db-client-go v0.2.0-rc.2 h1:bXkn4KIfBeiEJbj7HZsXDD/Amf3r7iLMg7RioPi0yVw= +kubedb.dev/db-client-go v0.2.0-rc.2/go.mod h1:6T95WgD1Lz1JEjixdVQ0/Euxd4mq3RhopliaaBer/vc= kubeops.dev/petset v0.0.6 h1:0IbvxD9fadZfH+3iMZWzN6ZHsO0vX458JlioamwyPKQ= kubeops.dev/petset v0.0.6/go.mod h1:A15vh0r979NsvL65DTIZKWsa/NoX9VapHBAEw1ZsdYI= kubeops.dev/sidekick v0.0.7 h1:+rs9AXPsiHjq5pJpzmj+Cen7frPfdi5dK1A57eNh7GM= diff --git a/vendor/golang.org/x/net/http2/transport.go b/vendor/golang.org/x/net/http2/transport.go index 98a49c6b6..61f511f97 100644 --- a/vendor/golang.org/x/net/http2/transport.go +++ b/vendor/golang.org/x/net/http2/transport.go @@ -827,10 +827,6 @@ func (t *Transport) newClientConn(c net.Conn, singleUse bool) (*ClientConn, erro cc.henc.SetMaxDynamicTableSizeLimit(t.maxEncoderHeaderTableSize()) cc.peerMaxHeaderTableSize = initialHeaderTableSize - if t.AllowHTTP { - cc.nextStreamID = 3 - } - if cs, ok := c.(connectionStater); ok { state := cs.ConnectionState() cc.tlsState = &state diff --git a/vendor/golang.org/x/sys/unix/mremap.go b/vendor/golang.org/x/sys/unix/mremap.go index fd45fe529..3a5e776f8 100644 --- a/vendor/golang.org/x/sys/unix/mremap.go +++ b/vendor/golang.org/x/sys/unix/mremap.go @@ -50,3 +50,8 @@ func (m *mremapMmapper) Mremap(oldData []byte, newLength int, flags int) (data [ func Mremap(oldData []byte, newLength int, flags int) (data []byte, err error) { return mapper.Mremap(oldData, newLength, flags) } + +func MremapPtr(oldAddr unsafe.Pointer, oldSize uintptr, newAddr unsafe.Pointer, newSize uintptr, flags int) (ret unsafe.Pointer, err error) { + xaddr, err := mapper.mremap(uintptr(oldAddr), oldSize, newSize, flags, uintptr(newAddr)) + return unsafe.Pointer(xaddr), err +} diff --git a/vendor/golang.org/x/sys/unix/syscall_darwin.go b/vendor/golang.org/x/sys/unix/syscall_darwin.go index 59542a897..4cc7b0059 100644 --- a/vendor/golang.org/x/sys/unix/syscall_darwin.go +++ b/vendor/golang.org/x/sys/unix/syscall_darwin.go @@ -542,6 +542,18 @@ func SysctlKinfoProcSlice(name string, args ...int) ([]KinfoProc, error) { } } +//sys pthread_chdir_np(path string) (err error) + +func PthreadChdir(path string) (err error) { + return pthread_chdir_np(path) +} + +//sys pthread_fchdir_np(fd int) (err error) + +func PthreadFchdir(fd int) (err error) { + return pthread_fchdir_np(fd) +} + //sys sendfile(infd int, outfd int, offset int64, len *int64, hdtr unsafe.Pointer, flags int) (err error) //sys shmat(id int, addr uintptr, flag int) (ret uintptr, err error) diff --git a/vendor/golang.org/x/sys/unix/syscall_unix.go b/vendor/golang.org/x/sys/unix/syscall_unix.go index 77081de8c..4e92e5aa4 100644 --- a/vendor/golang.org/x/sys/unix/syscall_unix.go +++ b/vendor/golang.org/x/sys/unix/syscall_unix.go @@ -154,6 +154,15 @@ func Munmap(b []byte) (err error) { return mapper.Munmap(b) } +func MmapPtr(fd int, offset int64, addr unsafe.Pointer, length uintptr, prot int, flags int) (ret unsafe.Pointer, err error) { + xaddr, err := mapper.mmap(uintptr(addr), length, prot, flags, fd, offset) + return unsafe.Pointer(xaddr), err +} + +func MunmapPtr(addr unsafe.Pointer, length uintptr) (err error) { + return mapper.munmap(uintptr(addr), length) +} + func Read(fd int, p []byte) (n int, err error) { n, err = read(fd, p) if raceenabled { diff --git a/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go b/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go index ccb02f240..07642c308 100644 --- a/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go +++ b/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.go @@ -760,6 +760,39 @@ var libc_sysctl_trampoline_addr uintptr // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func pthread_chdir_np(path string) (err error) { + var _p0 *byte + _p0, err = BytePtrFromString(path) + if err != nil { + return + } + _, _, e1 := syscall_syscall(libc_pthread_chdir_np_trampoline_addr, uintptr(unsafe.Pointer(_p0)), 0, 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_pthread_chdir_np_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_pthread_chdir_np pthread_chdir_np "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + +func pthread_fchdir_np(fd int) (err error) { + _, _, e1 := syscall_syscall(libc_pthread_fchdir_np_trampoline_addr, uintptr(fd), 0, 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_pthread_fchdir_np_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_pthread_fchdir_np pthread_fchdir_np "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func sendfile(infd int, outfd int, offset int64, len *int64, hdtr unsafe.Pointer, flags int) (err error) { _, _, e1 := syscall_syscall6(libc_sendfile_trampoline_addr, uintptr(infd), uintptr(outfd), uintptr(offset), uintptr(unsafe.Pointer(len)), uintptr(hdtr), uintptr(flags)) if e1 != 0 { diff --git a/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.s b/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.s index 8b8bb2840..923e08cb7 100644 --- a/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.s +++ b/vendor/golang.org/x/sys/unix/zsyscall_darwin_amd64.s @@ -228,6 +228,16 @@ TEXT libc_sysctl_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_sysctl_trampoline_addr(SB), RODATA, $8 DATA ·libc_sysctl_trampoline_addr(SB)/8, $libc_sysctl_trampoline<>(SB) +TEXT libc_pthread_chdir_np_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_pthread_chdir_np(SB) +GLOBL ·libc_pthread_chdir_np_trampoline_addr(SB), RODATA, $8 +DATA ·libc_pthread_chdir_np_trampoline_addr(SB)/8, $libc_pthread_chdir_np_trampoline<>(SB) + +TEXT libc_pthread_fchdir_np_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_pthread_fchdir_np(SB) +GLOBL ·libc_pthread_fchdir_np_trampoline_addr(SB), RODATA, $8 +DATA ·libc_pthread_fchdir_np_trampoline_addr(SB)/8, $libc_pthread_fchdir_np_trampoline<>(SB) + TEXT libc_sendfile_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_sendfile(SB) GLOBL ·libc_sendfile_trampoline_addr(SB), RODATA, $8 diff --git a/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go b/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go index 1b40b997b..7d73dda64 100644 --- a/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go +++ b/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.go @@ -760,6 +760,39 @@ var libc_sysctl_trampoline_addr uintptr // THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT +func pthread_chdir_np(path string) (err error) { + var _p0 *byte + _p0, err = BytePtrFromString(path) + if err != nil { + return + } + _, _, e1 := syscall_syscall(libc_pthread_chdir_np_trampoline_addr, uintptr(unsafe.Pointer(_p0)), 0, 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_pthread_chdir_np_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_pthread_chdir_np pthread_chdir_np "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + +func pthread_fchdir_np(fd int) (err error) { + _, _, e1 := syscall_syscall(libc_pthread_fchdir_np_trampoline_addr, uintptr(fd), 0, 0) + if e1 != 0 { + err = errnoErr(e1) + } + return +} + +var libc_pthread_fchdir_np_trampoline_addr uintptr + +//go:cgo_import_dynamic libc_pthread_fchdir_np pthread_fchdir_np "/usr/lib/libSystem.B.dylib" + +// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT + func sendfile(infd int, outfd int, offset int64, len *int64, hdtr unsafe.Pointer, flags int) (err error) { _, _, e1 := syscall_syscall6(libc_sendfile_trampoline_addr, uintptr(infd), uintptr(outfd), uintptr(offset), uintptr(unsafe.Pointer(len)), uintptr(hdtr), uintptr(flags)) if e1 != 0 { diff --git a/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.s b/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.s index 08362c1ab..057700111 100644 --- a/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.s +++ b/vendor/golang.org/x/sys/unix/zsyscall_darwin_arm64.s @@ -228,6 +228,16 @@ TEXT libc_sysctl_trampoline<>(SB),NOSPLIT,$0-0 GLOBL ·libc_sysctl_trampoline_addr(SB), RODATA, $8 DATA ·libc_sysctl_trampoline_addr(SB)/8, $libc_sysctl_trampoline<>(SB) +TEXT libc_pthread_chdir_np_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_pthread_chdir_np(SB) +GLOBL ·libc_pthread_chdir_np_trampoline_addr(SB), RODATA, $8 +DATA ·libc_pthread_chdir_np_trampoline_addr(SB)/8, $libc_pthread_chdir_np_trampoline<>(SB) + +TEXT libc_pthread_fchdir_np_trampoline<>(SB),NOSPLIT,$0-0 + JMP libc_pthread_fchdir_np(SB) +GLOBL ·libc_pthread_fchdir_np_trampoline_addr(SB), RODATA, $8 +DATA ·libc_pthread_fchdir_np_trampoline_addr(SB)/8, $libc_pthread_fchdir_np_trampoline<>(SB) + TEXT libc_sendfile_trampoline<>(SB),NOSPLIT,$0-0 JMP libc_sendfile(SB) GLOBL ·libc_sendfile_trampoline_addr(SB), RODATA, $8 diff --git a/vendor/golang.org/x/sys/windows/security_windows.go b/vendor/golang.org/x/sys/windows/security_windows.go index 6f7d2ac70..97651b5bd 100644 --- a/vendor/golang.org/x/sys/windows/security_windows.go +++ b/vendor/golang.org/x/sys/windows/security_windows.go @@ -894,7 +894,7 @@ type ACL struct { aclRevision byte sbz1 byte aclSize uint16 - aceCount uint16 + AceCount uint16 sbz2 uint16 } @@ -1087,6 +1087,27 @@ type EXPLICIT_ACCESS struct { Trustee TRUSTEE } +// https://learn.microsoft.com/en-us/windows/win32/api/winnt/ns-winnt-ace_header +type ACE_HEADER struct { + AceType uint8 + AceFlags uint8 + AceSize uint16 +} + +// https://learn.microsoft.com/en-us/windows/win32/api/winnt/ns-winnt-access_allowed_ace +type ACCESS_ALLOWED_ACE struct { + Header ACE_HEADER + Mask ACCESS_MASK + SidStart uint32 +} + +const ( + // Constants for AceType + // https://learn.microsoft.com/en-us/windows/win32/api/winnt/ns-winnt-ace_header + ACCESS_ALLOWED_ACE_TYPE = 0 + ACCESS_DENIED_ACE_TYPE = 1 +) + // This type is the union inside of TRUSTEE and must be created using one of the TrusteeValueFrom* functions. type TrusteeValue uintptr @@ -1158,6 +1179,7 @@ type OBJECTS_AND_NAME struct { //sys makeSelfRelativeSD(absoluteSD *SECURITY_DESCRIPTOR, selfRelativeSD *SECURITY_DESCRIPTOR, selfRelativeSDSize *uint32) (err error) = advapi32.MakeSelfRelativeSD //sys setEntriesInAcl(countExplicitEntries uint32, explicitEntries *EXPLICIT_ACCESS, oldACL *ACL, newACL **ACL) (ret error) = advapi32.SetEntriesInAclW +//sys GetAce(acl *ACL, aceIndex uint32, pAce **ACCESS_ALLOWED_ACE) (ret error) = advapi32.GetAce // Control returns the security descriptor control bits. func (sd *SECURITY_DESCRIPTOR) Control() (control SECURITY_DESCRIPTOR_CONTROL, revision uint32, err error) { diff --git a/vendor/golang.org/x/sys/windows/zsyscall_windows.go b/vendor/golang.org/x/sys/windows/zsyscall_windows.go index 9f73df75b..eba761018 100644 --- a/vendor/golang.org/x/sys/windows/zsyscall_windows.go +++ b/vendor/golang.org/x/sys/windows/zsyscall_windows.go @@ -91,6 +91,7 @@ var ( procEnumServicesStatusExW = modadvapi32.NewProc("EnumServicesStatusExW") procEqualSid = modadvapi32.NewProc("EqualSid") procFreeSid = modadvapi32.NewProc("FreeSid") + procGetAce = modadvapi32.NewProc("GetAce") procGetLengthSid = modadvapi32.NewProc("GetLengthSid") procGetNamedSecurityInfoW = modadvapi32.NewProc("GetNamedSecurityInfoW") procGetSecurityDescriptorControl = modadvapi32.NewProc("GetSecurityDescriptorControl") @@ -1224,6 +1225,14 @@ func setEntriesInAcl(countExplicitEntries uint32, explicitEntries *EXPLICIT_ACCE return } +func GetAce(acl *ACL, aceIndex uint32, pAce **ACCESS_ALLOWED_ACE) (ret error) { + r0, _, _ := syscall.Syscall(procGetAce.Addr(), 3, uintptr(unsafe.Pointer(acl)), uintptr(aceIndex), uintptr(unsafe.Pointer(pAce))) + if r0 == 0 { + ret = GetLastError() + } + return +} + func SetKernelObjectSecurity(handle Handle, securityInformation SECURITY_INFORMATION, securityDescriptor *SECURITY_DESCRIPTOR) (err error) { r1, _, e1 := syscall.Syscall(procSetKernelObjectSecurity.Addr(), 3, uintptr(handle), uintptr(securityInformation), uintptr(unsafe.Pointer(securityDescriptor))) if r1 == 0 { diff --git a/vendor/kmodules.xyz/resource-metadata/crds/ui.k8s.appscode.com_features.yaml b/vendor/kmodules.xyz/resource-metadata/crds/ui.k8s.appscode.com_features.yaml index cf8565a1a..9c6491fe0 100644 --- a/vendor/kmodules.xyz/resource-metadata/crds/ui.k8s.appscode.com_features.yaml +++ b/vendor/kmodules.xyz/resource-metadata/crds/ui.k8s.appscode.com_features.yaml @@ -158,6 +158,8 @@ spec: type: string kind: type: string + optional: + type: string selector: additionalProperties: type: string diff --git a/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/helpers.go b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/helpers.go index d39e86ac4..e097263e6 100644 --- a/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/helpers.go +++ b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/helpers.go @@ -41,3 +41,7 @@ func (_ MySQLArchiver) CustomResourceDefinition() *apiextensions.CustomResourceD func (_ MariaDBArchiver) CustomResourceDefinition() *apiextensions.CustomResourceDefinition { return crds.MustCustomResourceDefinition(SchemeGroupVersion.WithResource(ResourcePluralMariaDBArchiver)) } + +func (_ MSSQLServerArchiver) CustomResourceDefinition() *apiextensions.CustomResourceDefinition { + return crds.MustCustomResourceDefinition(SchemeGroupVersion.WithResource(ResourcePluralMSSQLServerArchiver)) +} diff --git a/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/mariadbarchiver_helpers.go b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/mariadbarchiver_helpers.go new file mode 100644 index 000000000..ddb4418ed --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/mariadbarchiver_helpers.go @@ -0,0 +1,43 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + api "kubedb.dev/apimachinery/apis/kubedb/v1" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +var _ Accessor = &MariaDBArchiver{} + +func (m *MariaDBArchiver) GetObjectMeta() metav1.ObjectMeta { + return m.ObjectMeta +} + +func (m *MariaDBArchiver) GetConsumers() *api.AllowedConsumers { + return m.Spec.Databases +} + +var _ ListAccessor = &MariaDBArchiverList{} + +func (l *MariaDBArchiverList) GetItems() []Accessor { + var accessors []Accessor + for _, item := range l.Items { + accessors = append(accessors, &item) + } + return accessors +} diff --git a/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/mongodbarchiver_helpers.go b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/mongodbarchiver_helpers.go new file mode 100644 index 000000000..7b2eeaa51 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/mongodbarchiver_helpers.go @@ -0,0 +1,43 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + api "kubedb.dev/apimachinery/apis/kubedb/v1" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +var _ Accessor = &MongoDBArchiver{} + +func (m *MongoDBArchiver) GetObjectMeta() metav1.ObjectMeta { + return m.ObjectMeta +} + +func (m *MongoDBArchiver) GetConsumers() *api.AllowedConsumers { + return m.Spec.Databases +} + +var _ ListAccessor = MongoDBArchiverList{} + +func (l MongoDBArchiverList) GetItems() []Accessor { + var accessors []Accessor + for _, item := range l.Items { + accessors = append(accessors, &item) + } + return accessors +} diff --git a/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/mssqlserverarchiver_types.go b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/mssqlserverarchiver_types.go new file mode 100644 index 000000000..7e4eb313d --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/mssqlserverarchiver_types.go @@ -0,0 +1,96 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + dbapi "kubedb.dev/apimachinery/apis/kubedb/v1alpha2" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + kmapi "kmodules.xyz/client-go/api/v1" +) + +const ( + ResourceKindMSSQLServerArchiver = "MSSQLServerArchiver" + ResourceSingularMSSQLServerArchiver = "mssqlserverarchiver" + ResourcePluralMSSQLServerArchiver = "mssqlserverarchivers" +) + +// +genclient +// +k8s:openapi-gen=true +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// +kubebuilder:object:root=true +// +kubebuilder:resource:path=mssqlserverarchivers,singular=mssqlserverarchiver,shortName=msarchiver,categories={archiver,kubedb,appscode} +// +kubebuilder:subresource:status +type MSSQLServerArchiver struct { + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty"` + + Spec MSSQLServerArchiverSpec `json:"spec,omitempty"` + Status MSSQLServerArchiverStatus `json:"status,omitempty"` +} + +// MSSQLServerArchiverSpec defines the desired state of MSSQLServerArchiver +type MSSQLServerArchiverSpec struct { + // Databases define which MSSQLServer databases are allowed to consume this archiver + Databases *dbapi.AllowedConsumers `json:"databases"` + // Pause defines if the backup process should be paused or not + // +optional + Pause bool `json:"pause,omitempty"` + // RetentionPolicy field is the RetentionPolicy of the backupConfiguration's backend + // +optional + RetentionPolicy *kmapi.ObjectReference `json:"retentionPolicy"` + // FullBackup defines the sessionConfig of the fullBackup + // This options will eventually go to the full-backup job's yaml + // +optional + FullBackup *FullBackupOptions `json:"fullBackup"` + // WalBackup defines the sessionConfig of the walBackup + // This options will eventually go to the sidekick specification + // +optional + WalBackup *WalBackupOptions `json:"walBackup"` + // ManifestBackup defines the sessionConfig of the manifestBackup + // This options will eventually go to the manifest-backup job's yaml + // +optional + ManifestBackup *ManifestBackupOptions `json:"manifestBackup"` + // +optional + EncryptionSecret *kmapi.ObjectReference `json:"encryptionSecret"` + // BackupStorage is the backend storageRef of the BackupConfiguration + // +optional + BackupStorage *BackupStorage `json:"backupStorage"` + // DeletionPolicy defines the created repository's deletionPolicy + // +optional + DeletionPolicy *DeletionPolicy `json:"deletionPolicy"` +} + +// MSSQLServerArchiverStatus defines the observed state of MSSQLServerArchiver +type MSSQLServerArchiverStatus struct { + // Specifies the information of all the databases managed by this archiver + // +optional + DatabaseRefs []ArchiverDatabaseRef `json:"databaseRefs,omitempty"` +} + +// +kubebuilder:object:root=true +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +type MSSQLServerArchiverList struct { + metav1.TypeMeta `json:",inline"` + metav1.ListMeta `json:"metadata,omitempty"` + Items []MSSQLServerArchiver `json:"items"` +} + +func init() { + SchemeBuilder.Register(&MSSQLServerArchiver{}, &MSSQLServerArchiverList{}) +} diff --git a/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/mysqlarchiver_helpers.go b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/mysqlarchiver_helpers.go new file mode 100644 index 000000000..6e6794b68 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/mysqlarchiver_helpers.go @@ -0,0 +1,43 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + api "kubedb.dev/apimachinery/apis/kubedb/v1" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +var _ Accessor = &MySQLArchiver{} + +func (m *MySQLArchiver) GetObjectMeta() metav1.ObjectMeta { + return m.ObjectMeta +} + +func (m *MySQLArchiver) GetConsumers() *api.AllowedConsumers { + return m.Spec.Databases +} + +var _ ListAccessor = MySQLArchiverList{} + +func (l MySQLArchiverList) GetItems() []Accessor { + var accessors []Accessor + for _, item := range l.Items { + accessors = append(accessors, &item) + } + return accessors +} diff --git a/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/openapi_generated.go b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/openapi_generated.go index 14eb643ef..52c82d1d7 100644 --- a/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/openapi_generated.go +++ b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/openapi_generated.go @@ -491,6 +491,10 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/archiver/v1alpha1.BackupStorage": schema_apimachinery_apis_archiver_v1alpha1_BackupStorage(ref), "kubedb.dev/apimachinery/apis/archiver/v1alpha1.FullBackupOptions": schema_apimachinery_apis_archiver_v1alpha1_FullBackupOptions(ref), "kubedb.dev/apimachinery/apis/archiver/v1alpha1.GenericSecretReference": schema_apimachinery_apis_archiver_v1alpha1_GenericSecretReference(ref), + "kubedb.dev/apimachinery/apis/archiver/v1alpha1.MSSQLServerArchiver": schema_apimachinery_apis_archiver_v1alpha1_MSSQLServerArchiver(ref), + "kubedb.dev/apimachinery/apis/archiver/v1alpha1.MSSQLServerArchiverList": schema_apimachinery_apis_archiver_v1alpha1_MSSQLServerArchiverList(ref), + "kubedb.dev/apimachinery/apis/archiver/v1alpha1.MSSQLServerArchiverSpec": schema_apimachinery_apis_archiver_v1alpha1_MSSQLServerArchiverSpec(ref), + "kubedb.dev/apimachinery/apis/archiver/v1alpha1.MSSQLServerArchiverStatus": schema_apimachinery_apis_archiver_v1alpha1_MSSQLServerArchiverStatus(ref), "kubedb.dev/apimachinery/apis/archiver/v1alpha1.ManifestBackupOptions": schema_apimachinery_apis_archiver_v1alpha1_ManifestBackupOptions(ref), "kubedb.dev/apimachinery/apis/archiver/v1alpha1.MariaDBArchiver": schema_apimachinery_apis_archiver_v1alpha1_MariaDBArchiver(ref), "kubedb.dev/apimachinery/apis/archiver/v1alpha1.MariaDBArchiverList": schema_apimachinery_apis_archiver_v1alpha1_MariaDBArchiverList(ref), @@ -25252,6 +25256,200 @@ func schema_apimachinery_apis_archiver_v1alpha1_GenericSecretReference(ref commo } } +func schema_apimachinery_apis_archiver_v1alpha1_MSSQLServerArchiver(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/archiver/v1alpha1.MSSQLServerArchiverSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/archiver/v1alpha1.MSSQLServerArchiverStatus"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "kubedb.dev/apimachinery/apis/archiver/v1alpha1.MSSQLServerArchiverSpec", "kubedb.dev/apimachinery/apis/archiver/v1alpha1.MSSQLServerArchiverStatus"}, + } +} + +func schema_apimachinery_apis_archiver_v1alpha1_MSSQLServerArchiverList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/archiver/v1alpha1.MSSQLServerArchiver"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "kubedb.dev/apimachinery/apis/archiver/v1alpha1.MSSQLServerArchiver"}, + } +} + +func schema_apimachinery_apis_archiver_v1alpha1_MSSQLServerArchiverSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "MSSQLServerArchiverSpec defines the desired state of MSSQLServerArchiver", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "databases": { + SchemaProps: spec.SchemaProps{ + Description: "Databases define which MSSQLServer databases are allowed to consume this archiver", + Ref: ref("kubedb.dev/apimachinery/apis/kubedb/v1alpha2.AllowedConsumers"), + }, + }, + "pause": { + SchemaProps: spec.SchemaProps{ + Description: "Pause defines if the backup process should be paused or not", + Type: []string{"boolean"}, + Format: "", + }, + }, + "retentionPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "RetentionPolicy field is the RetentionPolicy of the backupConfiguration's backend", + Ref: ref("kmodules.xyz/client-go/api/v1.ObjectReference"), + }, + }, + "fullBackup": { + SchemaProps: spec.SchemaProps{ + Description: "FullBackup defines the sessionConfig of the fullBackup This options will eventually go to the full-backup job's yaml", + Ref: ref("kubedb.dev/apimachinery/apis/archiver/v1alpha1.FullBackupOptions"), + }, + }, + "walBackup": { + SchemaProps: spec.SchemaProps{ + Description: "WalBackup defines the sessionConfig of the walBackup This options will eventually go to the sidekick specification", + Ref: ref("kubedb.dev/apimachinery/apis/archiver/v1alpha1.WalBackupOptions"), + }, + }, + "manifestBackup": { + SchemaProps: spec.SchemaProps{ + Description: "ManifestBackup defines the sessionConfig of the manifestBackup This options will eventually go to the manifest-backup job's yaml", + Ref: ref("kubedb.dev/apimachinery/apis/archiver/v1alpha1.ManifestBackupOptions"), + }, + }, + "encryptionSecret": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kmodules.xyz/client-go/api/v1.ObjectReference"), + }, + }, + "backupStorage": { + SchemaProps: spec.SchemaProps{ + Description: "BackupStorage is the backend storageRef of the BackupConfiguration", + Ref: ref("kubedb.dev/apimachinery/apis/archiver/v1alpha1.BackupStorage"), + }, + }, + "deletionPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "DeletionPolicy defines the created repository's deletionPolicy", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"databases"}, + }, + }, + Dependencies: []string{ + "kmodules.xyz/client-go/api/v1.ObjectReference", "kubedb.dev/apimachinery/apis/archiver/v1alpha1.BackupStorage", "kubedb.dev/apimachinery/apis/archiver/v1alpha1.FullBackupOptions", "kubedb.dev/apimachinery/apis/archiver/v1alpha1.ManifestBackupOptions", "kubedb.dev/apimachinery/apis/archiver/v1alpha1.WalBackupOptions", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.AllowedConsumers"}, + } +} + +func schema_apimachinery_apis_archiver_v1alpha1_MSSQLServerArchiverStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "MSSQLServerArchiverStatus defines the observed state of MSSQLServerArchiver", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "databaseRefs": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the information of all the databases managed by this archiver", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/archiver/v1alpha1.ArchiverDatabaseRef"), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/archiver/v1alpha1.ArchiverDatabaseRef"}, + } +} + func schema_apimachinery_apis_archiver_v1alpha1_ManifestBackupOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ diff --git a/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/postgresarchiver_helpers.go b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/postgresarchiver_helpers.go new file mode 100644 index 000000000..cd22f901e --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/postgresarchiver_helpers.go @@ -0,0 +1,43 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + api "kubedb.dev/apimachinery/apis/kubedb/v1" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +var _ Accessor = &PostgresArchiver{} + +func (m *PostgresArchiver) GetObjectMeta() metav1.ObjectMeta { + return m.ObjectMeta +} + +func (m *PostgresArchiver) GetConsumers() *api.AllowedConsumers { + return m.Spec.Databases +} + +var _ ListAccessor = PostgresArchiverList{} + +func (l PostgresArchiverList) GetItems() []Accessor { + var accessors []Accessor + for _, item := range l.Items { + accessors = append(accessors, &item) + } + return accessors +} diff --git a/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/types.go b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/types.go index 0211e9bc7..e3fc1df90 100644 --- a/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/types.go +++ b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/types.go @@ -17,6 +17,8 @@ limitations under the License. package v1alpha1 import ( + api "kubedb.dev/apimachinery/apis/kubedb/v1" + batch "k8s.io/api/batch/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" @@ -26,6 +28,15 @@ import ( stashcoreapi "kubestash.dev/apimachinery/apis/core/v1alpha1" ) +type Accessor interface { + GetObjectMeta() metav1.ObjectMeta + GetConsumers() *api.AllowedConsumers +} + +type ListAccessor interface { + GetItems() []Accessor +} + type FullBackupOptions struct { // +kubebuilder:default:=VolumeSnapshotter Driver apis.Driver `json:"driver"` diff --git a/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/zz_generated.deepcopy.go b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/zz_generated.deepcopy.go index 460fbde8a..cec94e74d 100644 --- a/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/zz_generated.deepcopy.go +++ b/vendor/kubedb.dev/apimachinery/apis/archiver/v1alpha1/zz_generated.deepcopy.go @@ -23,6 +23,7 @@ package v1alpha1 import ( kubedbv1 "kubedb.dev/apimachinery/apis/kubedb/v1" + v1alpha2 "kubedb.dev/apimachinery/apis/kubedb/v1alpha2" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" runtime "k8s.io/apimachinery/pkg/runtime" @@ -137,6 +138,144 @@ func (in *GenericSecretReference) DeepCopy() *GenericSecretReference { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MSSQLServerArchiver) DeepCopyInto(out *MSSQLServerArchiver) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MSSQLServerArchiver. +func (in *MSSQLServerArchiver) DeepCopy() *MSSQLServerArchiver { + if in == nil { + return nil + } + out := new(MSSQLServerArchiver) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *MSSQLServerArchiver) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MSSQLServerArchiverList) DeepCopyInto(out *MSSQLServerArchiverList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]MSSQLServerArchiver, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MSSQLServerArchiverList. +func (in *MSSQLServerArchiverList) DeepCopy() *MSSQLServerArchiverList { + if in == nil { + return nil + } + out := new(MSSQLServerArchiverList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *MSSQLServerArchiverList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MSSQLServerArchiverSpec) DeepCopyInto(out *MSSQLServerArchiverSpec) { + *out = *in + if in.Databases != nil { + in, out := &in.Databases, &out.Databases + *out = new(v1alpha2.AllowedConsumers) + (*in).DeepCopyInto(*out) + } + if in.RetentionPolicy != nil { + in, out := &in.RetentionPolicy, &out.RetentionPolicy + *out = new(v1.ObjectReference) + **out = **in + } + if in.FullBackup != nil { + in, out := &in.FullBackup, &out.FullBackup + *out = new(FullBackupOptions) + (*in).DeepCopyInto(*out) + } + if in.WalBackup != nil { + in, out := &in.WalBackup, &out.WalBackup + *out = new(WalBackupOptions) + (*in).DeepCopyInto(*out) + } + if in.ManifestBackup != nil { + in, out := &in.ManifestBackup, &out.ManifestBackup + *out = new(ManifestBackupOptions) + (*in).DeepCopyInto(*out) + } + if in.EncryptionSecret != nil { + in, out := &in.EncryptionSecret, &out.EncryptionSecret + *out = new(v1.ObjectReference) + **out = **in + } + if in.BackupStorage != nil { + in, out := &in.BackupStorage, &out.BackupStorage + *out = new(BackupStorage) + (*in).DeepCopyInto(*out) + } + if in.DeletionPolicy != nil { + in, out := &in.DeletionPolicy, &out.DeletionPolicy + *out = new(DeletionPolicy) + **out = **in + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MSSQLServerArchiverSpec. +func (in *MSSQLServerArchiverSpec) DeepCopy() *MSSQLServerArchiverSpec { + if in == nil { + return nil + } + out := new(MSSQLServerArchiverSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MSSQLServerArchiverStatus) DeepCopyInto(out *MSSQLServerArchiverStatus) { + *out = *in + if in.DatabaseRefs != nil { + in, out := &in.DatabaseRefs, &out.DatabaseRefs + *out = make([]ArchiverDatabaseRef, len(*in)) + copy(*out, *in) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MSSQLServerArchiverStatus. +func (in *MSSQLServerArchiverStatus) DeepCopy() *MSSQLServerArchiverStatus { + if in == nil { + return nil + } + out := new(MSSQLServerArchiverStatus) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ManifestBackupOptions) DeepCopyInto(out *ManifestBackupOptions) { *out = *in diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/clickhouse_helpers.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/clickhouse_helpers.go new file mode 100644 index 000000000..1d25768f5 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/clickhouse_helpers.go @@ -0,0 +1,67 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "fmt" + + "kubedb.dev/apimachinery/apis" + "kubedb.dev/apimachinery/apis/autoscaling" + "kubedb.dev/apimachinery/crds" + + "kmodules.xyz/client-go/apiextensions" +) + +func (r ClickHouseAutoscaler) CustomResourceDefinition() *apiextensions.CustomResourceDefinition { + return crds.MustCustomResourceDefinition(SchemeGroupVersion.WithResource(ResourcePluralClickHouseAutoscaler)) +} + +var _ apis.ResourceInfo = &ClickHouseAutoscaler{} + +func (r ClickHouseAutoscaler) ResourceFQN() string { + return fmt.Sprintf("%s.%s", ResourcePluralClickHouseAutoscaler, autoscaling.GroupName) +} + +func (r ClickHouseAutoscaler) ResourceShortCode() string { + return ResourceCodeClickHouseAutoscaler +} + +func (r ClickHouseAutoscaler) ResourceKind() string { + return ResourceKindClickHouseAutoscaler +} + +func (r ClickHouseAutoscaler) ResourceSingular() string { + return ResourceSingularClickHouseAutoscaler +} + +func (r ClickHouseAutoscaler) ResourcePlural() string { + return ResourcePluralClickHouseAutoscaler +} + +func (r ClickHouseAutoscaler) ValidateSpecs() error { + return nil +} + +var _ StatusAccessor = &ClickHouseAutoscaler{} + +func (r *ClickHouseAutoscaler) GetStatus() AutoscalerStatus { + return r.Status +} + +func (r *ClickHouseAutoscaler) SetStatus(s AutoscalerStatus) { + r.Status = s +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/clickhouse_types.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/clickhouse_types.go new file mode 100644 index 000000000..611c2ad14 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/clickhouse_types.go @@ -0,0 +1,100 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + + core "k8s.io/api/core/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +const ( + ResourceCodeClickHouseAutoscaler = "chscaler" + ResourceKindClickHouseAutoscaler = "ClickHouseAutoscaler" + ResourceSingularClickHouseAutoscaler = "clickhouseautoscaler" + ResourcePluralClickHouseAutoscaler = "clickhouseautoscalers" +) + +// ClickHouseAutoscaler is the configuration for a clickhouse database +// autoscaler, which automatically manages pod resources based on historical and +// real time resource utilization. + +// +genclient +// +k8s:openapi-gen=true +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// +kubebuilder:object:root=true +// +kubebuilder:resource:path=clickhouseautoscalers,singular=clickhouseautoscaler,shortName=chscaler,categories={datastore,kubedb,appscode} +// +kubebuilder:subresource:status +type ClickHouseAutoscaler struct { + metav1.TypeMeta `json:",inline"` + // Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta `json:"metadata,omitempty"` + + // Specification of the behavior of the autoscaler. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. + Spec ClickHouseAutoscalerSpec `json:"spec"` + + // Current information about the autoscaler. + // +optional + Status AutoscalerStatus `json:"status,omitempty"` +} + +// ClickHouseAutoscalerSpec is the specification of the behavior of the autoscaler. +type ClickHouseAutoscalerSpec struct { + DatabaseRef *core.LocalObjectReference `json:"databaseRef"` + + // This field will be used to control the behaviour of ops-manager + OpsRequestOptions *ClickHouseOpsRequestOptions `json:"opsRequestOptions,omitempty"` + + Compute *ClickHouseComputeAutoscalerSpec `json:"compute,omitempty"` + Storage *ClickHouseStorageAutoscalerSpec `json:"storage,omitempty"` +} + +type ClickHouseComputeAutoscalerSpec struct { + // +optional + NodeTopology *NodeTopology `json:"nodeTopology,omitempty"` + + ClickHouse *ComputeAutoscalerSpec `json:"clickhouse,omitempty"` +} + +type ClickHouseStorageAutoscalerSpec struct { + ClickHouse *StorageAutoscalerSpec `json:"clickhouse,omitempty"` +} + +type ClickHouseOpsRequestOptions struct { + // Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure. + Timeout *metav1.Duration `json:"timeout,omitempty"` + + // ApplyOption is to control the execution of OpsRequest depending on the database state. + // +kubebuilder:default="IfReady" + Apply opsapi.ApplyOption `json:"apply,omitempty"` +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// ClickHouseAutoscalerList is a list of ClickHouseAutoscaler objects. +type ClickHouseAutoscalerList struct { + metav1.TypeMeta `json:",inline"` + // metadata is the standard list metadata. + // +optional + metav1.ListMeta `json:"metadata"` + + // items is the list of clickhouse database autoscaler objects. + Items []ClickHouseAutoscaler `json:"items"` +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/clickhouse_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/clickhouse_webhook.go new file mode 100644 index 000000000..29473e6d4 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/clickhouse_webhook.go @@ -0,0 +1,111 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "context" + "errors" + "fmt" + + olddbapi "kubedb.dev/apimachinery/apis/kubedb/v1alpha2" + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/types" + logf "sigs.k8s.io/controller-runtime/pkg/log" + "sigs.k8s.io/controller-runtime/pkg/webhook" + "sigs.k8s.io/controller-runtime/pkg/webhook/admission" +) + +// log is for logging in this package. +var chLog = logf.Log.WithName("clickhouse-autoscaler") + +var _ webhook.Defaulter = &ClickHouseAutoscaler{} + +// Default implements webhook.CustomDefaulter so a webhook will be registered for the type +func (r *ClickHouseAutoscaler) Default() { + chLog.Info("defaulting", "name", r.Name) + r.setDefaults() +} + +func (r *ClickHouseAutoscaler) setDefaults() { + var db olddbapi.ClickHouse + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &db) + if err != nil { + _ = fmt.Errorf("can't get ClickHouse %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return + } + + r.setOpsReqOptsDefaults() + + if r.Spec.Storage != nil { + setDefaultStorageValues(r.Spec.Storage.ClickHouse) + } + + if r.Spec.Compute != nil { + setDefaultComputeValues(r.Spec.Compute.ClickHouse) + } +} + +func (r *ClickHouseAutoscaler) setOpsReqOptsDefaults() { + if r.Spec.OpsRequestOptions == nil { + r.Spec.OpsRequestOptions = &ClickHouseOpsRequestOptions{} + } + // Timeout is defaulted to 600s in ops-manager retries.go (to retry 120 times with 5sec pause between each) + // OplogMaxLagSeconds & ObjectsCountDiffPercentage are defaults to 0 + if r.Spec.OpsRequestOptions.Apply == "" { + r.Spec.OpsRequestOptions.Apply = opsapi.ApplyOptionIfReady + } +} + +var _ webhook.Validator = &ClickHouseAutoscaler{} + +// ValidateCreate implements webhook.Validator so a webhook will be registered for the type +func (r *ClickHouseAutoscaler) ValidateCreate() (admission.Warnings, error) { + chLog.Info("validate create", "name", r.Name) + return nil, r.validate() +} + +// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type +func (r *ClickHouseAutoscaler) ValidateUpdate(oldObj runtime.Object) (admission.Warnings, error) { + chLog.Info("validate create", "name", r.Name) + return nil, r.validate() +} + +func (r *ClickHouseAutoscaler) ValidateDelete() (admission.Warnings, error) { + return nil, nil +} + +func (r *ClickHouseAutoscaler) validate() error { + if r.Spec.DatabaseRef == nil { + return errors.New("databaseRef can't be empty") + } + var kf olddbapi.ClickHouse + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &kf) + if err != nil { + _ = fmt.Errorf("can't get ClickHouse %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return err + } + + return nil +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/ferretdb_helpers.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/ferretdb_helpers.go new file mode 100644 index 000000000..0828a28f7 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/ferretdb_helpers.go @@ -0,0 +1,67 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "fmt" + + "kubedb.dev/apimachinery/apis" + "kubedb.dev/apimachinery/apis/autoscaling" + "kubedb.dev/apimachinery/crds" + + "kmodules.xyz/client-go/apiextensions" +) + +func (r FerretDBAutoscaler) CustomResourceDefinition() *apiextensions.CustomResourceDefinition { + return crds.MustCustomResourceDefinition(SchemeGroupVersion.WithResource(ResourcePluralFerretDBAutoscaler)) +} + +var _ apis.ResourceInfo = &FerretDBAutoscaler{} + +func (r FerretDBAutoscaler) ResourceFQN() string { + return fmt.Sprintf("%s.%s", ResourcePluralFerretDBAutoscaler, autoscaling.GroupName) +} + +func (r FerretDBAutoscaler) ResourceShortCode() string { + return ResourceCodeFerretDBAutoscaler +} + +func (r FerretDBAutoscaler) ResourceKind() string { + return ResourceKindFerretDBAutoscaler +} + +func (r FerretDBAutoscaler) ResourceSingular() string { + return ResourceSingularFerretDBAutoscaler +} + +func (r FerretDBAutoscaler) ResourcePlural() string { + return ResourcePluralFerretDBAutoscaler +} + +func (r FerretDBAutoscaler) ValidateSpecs() error { + return nil +} + +var _ StatusAccessor = &FerretDBAutoscaler{} + +func (r *FerretDBAutoscaler) GetStatus() AutoscalerStatus { + return r.Status +} + +func (r *FerretDBAutoscaler) SetStatus(s AutoscalerStatus) { + r.Status = s +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/ferretdb_types.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/ferretdb_types.go new file mode 100644 index 000000000..ac8deb15b --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/ferretdb_types.go @@ -0,0 +1,100 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + + core "k8s.io/api/core/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +const ( + ResourceCodeFerretDBAutoscaler = "frscaler" + ResourceKindFerretDBAutoscaler = "FerretDBAutoscaler" + ResourceSingularFerretDBAutoscaler = "ferretdbautoscaler" + ResourcePluralFerretDBAutoscaler = "ferretdbautoscalers" +) + +// FerretDBAutoscaler is the configuration for a ferretdb database +// autoscaler, which automatically manages pod resources based on historical and +// real time resource utilization. + +// +genclient +// +k8s:openapi-gen=true +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// +kubebuilder:object:root=true +// +kubebuilder:resource:path=ferretdbautoscalers,singular=ferretdbautoscaler,shortName=frscaler,categories={datastore,kubedb,appscode} +// +kubebuilder:subresource:status +type FerretDBAutoscaler struct { + metav1.TypeMeta `json:",inline"` + // Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta `json:"metadata,omitempty"` + + // Specification of the behavior of the autoscaler. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. + Spec FerretDBAutoscalerSpec `json:"spec"` + + // Current information about the autoscaler. + // +optional + Status AutoscalerStatus `json:"status,omitempty"` +} + +// FerretDBAutoscalerSpec is the specification of the behavior of the autoscaler. +type FerretDBAutoscalerSpec struct { + DatabaseRef *core.LocalObjectReference `json:"databaseRef"` + + // This field will be used to control the behaviour of ops-manager + OpsRequestOptions *FerretDBOpsRequestOptions `json:"opsRequestOptions,omitempty"` + + Compute *FerretDBComputeAutoscalerSpec `json:"compute,omitempty"` + Storage *FerretDBStorageAutoscalerSpec `json:"storage,omitempty"` +} + +type FerretDBComputeAutoscalerSpec struct { + // +optional + NodeTopology *NodeTopology `json:"nodeTopology,omitempty"` + + FerretDB *ComputeAutoscalerSpec `json:"ferretdb,omitempty"` +} + +type FerretDBStorageAutoscalerSpec struct { + FerretDB *StorageAutoscalerSpec `json:"ferretdb,omitempty"` +} + +type FerretDBOpsRequestOptions struct { + // Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure. + Timeout *metav1.Duration `json:"timeout,omitempty"` + + // ApplyOption is to control the execution of OpsRequest depending on the database state. + // +kubebuilder:default="IfReady" + Apply opsapi.ApplyOption `json:"apply,omitempty"` +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// FerretDBAutoscalerList is a list of FerretDBAutoscaler objects. +type FerretDBAutoscalerList struct { + metav1.TypeMeta `json:",inline"` + // metadata is the standard list metadata. + // +optional + metav1.ListMeta `json:"metadata"` + + // items is the list of ferretdb database autoscaler objects. + Items []FerretDBAutoscaler `json:"items"` +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/ferretdb_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/ferretdb_webhook.go new file mode 100644 index 000000000..f669e8cdb --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/ferretdb_webhook.go @@ -0,0 +1,111 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "context" + "errors" + "fmt" + + olddbapi "kubedb.dev/apimachinery/apis/kubedb/v1alpha2" + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/types" + logf "sigs.k8s.io/controller-runtime/pkg/log" + "sigs.k8s.io/controller-runtime/pkg/webhook" + "sigs.k8s.io/controller-runtime/pkg/webhook/admission" +) + +// log is for logging in this package. +var frLog = logf.Log.WithName("ferretdb-autoscaler") + +var _ webhook.Defaulter = &FerretDBAutoscaler{} + +// Default implements webhook.CustomDefaulter so a webhook will be registered for the type +func (r *FerretDBAutoscaler) Default() { + frLog.Info("defaulting", "name", r.Name) + r.setDefaults() +} + +func (r *FerretDBAutoscaler) setDefaults() { + var db olddbapi.FerretDB + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &db) + if err != nil { + _ = fmt.Errorf("can't get FerretDB %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return + } + + r.setOpsReqOptsDefaults() + + if r.Spec.Storage != nil { + setDefaultStorageValues(r.Spec.Storage.FerretDB) + } + + if r.Spec.Compute != nil { + setDefaultComputeValues(r.Spec.Compute.FerretDB) + } +} + +func (r *FerretDBAutoscaler) setOpsReqOptsDefaults() { + if r.Spec.OpsRequestOptions == nil { + r.Spec.OpsRequestOptions = &FerretDBOpsRequestOptions{} + } + // Timeout is defaulted to 600s in ops-manager retries.go (to retry 120 times with 5sec pause between each) + // OplogMaxLagSeconds & ObjectsCountDiffPercentage are defaults to 0 + if r.Spec.OpsRequestOptions.Apply == "" { + r.Spec.OpsRequestOptions.Apply = opsapi.ApplyOptionIfReady + } +} + +var _ webhook.Validator = &FerretDBAutoscaler{} + +// ValidateCreate implements webhook.Validator so a webhook will be registered for the type +func (r *FerretDBAutoscaler) ValidateCreate() (admission.Warnings, error) { + frLog.Info("validate create", "name", r.Name) + return nil, r.validate() +} + +// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type +func (r *FerretDBAutoscaler) ValidateUpdate(oldObj runtime.Object) (admission.Warnings, error) { + frLog.Info("validate create", "name", r.Name) + return nil, r.validate() +} + +func (r *FerretDBAutoscaler) ValidateDelete() (admission.Warnings, error) { + return nil, nil +} + +func (r *FerretDBAutoscaler) validate() error { + if r.Spec.DatabaseRef == nil { + return errors.New("databaseRef can't be empty") + } + var kf olddbapi.FerretDB + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &kf) + if err != nil { + _ = fmt.Errorf("can't get FerretDB %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return err + } + + return nil +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/memcached_types.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/memcached_types.go index b72d61a4d..0d6bae527 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/memcached_types.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/memcached_types.go @@ -17,7 +17,8 @@ limitations under the License. package v1alpha1 import ( - "k8s.io/api/autoscaling/v2beta2" + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + core "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) @@ -29,9 +30,9 @@ const ( ResourcePluralMemcachedAutoscaler = "memcachedautoscalers" ) -// MemcachedAutoscaler is the configuration for a horizontal pod -// autoscaler, which automatically manages the replica count of any resource -// implementing the scale subresource based on the metrics specified. +// MemcachedAutoscaler is the configuration for a memcached database +// autoscaler, which automatically manages pod resources based on historical and +// real time resource utilization. // +genclient // +k8s:openapi-gen=true @@ -42,118 +43,61 @@ const ( // +kubebuilder:subresource:status type MemcachedAutoscaler struct { metav1.TypeMeta `json:",inline"` - // metadata is the standard object metadata. - // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + // Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional metav1.ObjectMeta `json:"metadata,omitempty"` - // spec is the specification for the behaviour of the autoscaler. - // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status. - // +optional - Spec MemcachedAutoscalerSpec `json:"spec,omitempty"` + // Specification of the behavior of the autoscaler. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. + Spec MemcachedAutoscalerSpec `json:"spec"` - // status is the current information about the autoscaler. + // Current information about the autoscaler. // +optional Status AutoscalerStatus `json:"status,omitempty"` } -// MemcachedAutoscalerSpec describes the desired functionality of the MemcachedAutoscaler. +// MemcachedAutoscalerSpec is the specification of the behavior of the autoscaler. type MemcachedAutoscalerSpec struct { - // scaleTargetRef points to the target resource to scale, and is used to the pods for which metrics - // should be collected, as well as to actually change the replica count. - ScaleTargetRef core.LocalObjectReference `json:"scaleTargetRef"` - // minReplicas is the lower limit for the number of replicas to which the autoscaler - // can scale down. It defaults to 1 pod. minReplicas is allowed to be 0 if the - // alpha feature gate HPAScaleToZero is enabled and at least one Object or External - // metric is configured. Scaling is active as long as at least one metric value is - // available. - // +optional - MinReplicas *int32 `json:"minReplicas,omitempty"` - // maxReplicas is the upper limit for the number of replicas to which the autoscaler can scale up. - // It cannot be less that minReplicas. - MaxReplicas int32 `json:"maxReplicas"` - // metrics contains the specifications for which to use to calculate the - // desired replica count (the maximum replica count across all metrics will - // be used). The desired replica count is calculated multiplying the - // ratio between the target value and the current value by the current - // number of pods. Ergo, metrics used must decrease as the pod count is - // increased, and vice-versa. See the individual metric source types for - // more information about how each type of metric must respond. - // If not set, the default metric will be set to 80% average CPU utilization. - // +optional - Metrics []v2beta2.MetricSpec `json:"metrics,omitempty"` + DatabaseRef *core.LocalObjectReference `json:"databaseRef"` - // behavior configures the scaling behavior of the target - // in both Up and Down directions (scaleUp and scaleDown fields respectively). - // If not set, the default MemcachedScalingRules for scale up and scale down are used. - // +optional - Behavior *MemcachedAutoscalerBehavior `json:"behavior,omitempty"` + // This field will be used to control the behaviour of ops-manager + OpsRequestOptions *MemcachedOpsRequestOptions `json:"opsRequestOptions,omitempty"` + + Compute *MemcachedComputeAutoscalerSpec `json:"compute,omitempty"` + Storage *MemcachedStorageAutoscalerSpec `json:"storage,omitempty"` } -// MemcachedAutoscalerBehavior configures the scaling behavior of the target -// in both Up and Down directions (scaleUp and scaleDown fields respectively). -type MemcachedAutoscalerBehavior struct { - // scaleUp is scaling policy for scaling Up. - // If not set, the default value is the higher of: - // * increase no more than 4 pods per 60 seconds - // * double the number of pods per 60 seconds - // No stabilization is used. - // +optional - ScaleUp *MemcachedScalingRules `json:"scaleUp,omitempty"` - // scaleDown is scaling policy for scaling Down. - // If not set, the default value is to allow to scale down to minReplicas pods, with a - // 300 second stabilization window (i.e., the highest recommendation for - // the last 300sec is used). +type MemcachedComputeAutoscalerSpec struct { // +optional - ScaleDown *MemcachedScalingRules `json:"scaleDown,omitempty"` + NodeTopology *NodeTopology `json:"nodeTopology,omitempty"` + + Memcached *ComputeAutoscalerSpec `json:"memcached,omitempty"` } -// MemcachedScalingRules configures the scaling behavior for one direction. -// These Rules are applied after calculating DesiredReplicas from metrics for the HPA. -// They can limit the scaling velocity by specifying scaling policies. -// They can prevent flapping by specifying the stabilization window, so that the -// number of replicas is not set instantly, instead, the safest value from the stabilization -// window is chosen. -type MemcachedScalingRules struct { - // StabilizationWindowSeconds is the number of seconds for which past recommendations should be - // considered while scaling up or scaling down. - // StabilizationWindowSeconds must be greater than or equal to zero and less than or equal to 3600 (one hour). - // If not set, use the default values: - // - For scale up: 0 (i.e. no stabilization is done). - // - For scale down: 300 (i.e. the stabilization window is 300 seconds long). - // +optional - StabilizationWindowSeconds *int32 `json:"stabilizationWindowSeconds"` - // selectPolicy is used to specify which policy should be used. - // If not set, the default value MaxPolicySelect is used. - // +optional - SelectPolicy *v2beta2.ScalingPolicySelect `json:"selectPolicy,omitempty"` - // policies is a list of potential scaling polices which can be used during scaling. - // At least one policy must be specified, otherwise the MemcachedScalingRules will be discarded as invalid - // +optional - Policies []MemcachedScalingPolicy `json:"policies,omitempty"` +type MemcachedStorageAutoscalerSpec struct { + Memcached *StorageAutoscalerSpec `json:"memcached,omitempty"` } -// MemcachedScalingPolicy is a single policy which must hold true for a specified past interval. -type MemcachedScalingPolicy struct { - // Type is used to specify the scaling policy. - Type v2beta2.HPAScalingPolicyType `json:"type"` - // Value contains the amount of change which is permitted by the policy. - // It must be greater than zero - Value int32 `json:"value"` - // PeriodSeconds specifies the window of time for which the policy should hold true. - // PeriodSeconds must be greater than zero and less than or equal to 1800 (30 min). - PeriodSeconds int32 `json:"periodSeconds"` +type MemcachedOpsRequestOptions struct { + // Specifies the Readiness Criteria + ReadinessCriteria *opsapi.MemcachedReplicaReadinessCriteria `json:"readinessCriteria,omitempty"` + + // Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure. + Timeout *metav1.Duration `json:"timeout,omitempty"` + + // ApplyOption is to control the execution of OpsRequest depending on the database state. + // +kubebuilder:default="IfReady" + Apply opsapi.ApplyOption `json:"apply,omitempty"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object - -// MemcachedAutoscalerList is a list of horizontal pod autoscaler objects. +// MemcachedAutoscalerList is a list of MemcachedAutoscaler objects. type MemcachedAutoscalerList struct { metav1.TypeMeta `json:",inline"` // metadata is the standard list metadata. // +optional - metav1.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta `json:"metadata"` - // items is the list of horizontal pod autoscaler objects. + // items is the list of memcached database autoscaler objects. Items []MemcachedAutoscaler `json:"items"` } diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/memcached_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/memcached_webhook.go new file mode 100644 index 000000000..27feb65db --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/memcached_webhook.go @@ -0,0 +1,111 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "context" + "errors" + "fmt" + + dbapi "kubedb.dev/apimachinery/apis/kubedb/v1" + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/types" + logf "sigs.k8s.io/controller-runtime/pkg/log" + "sigs.k8s.io/controller-runtime/pkg/webhook" + "sigs.k8s.io/controller-runtime/pkg/webhook/admission" +) + +// log is for logging in this package. +var mcLog = logf.Log.WithName("memcached-autoscaler") + +var _ webhook.Defaulter = &MemcachedAutoscaler{} + +// Default implements webhook.CustomDefaulter so a webhook will be registered for the type +func (r *MemcachedAutoscaler) Default() { + mcLog.Info("defaulting", "name", r.Name) + r.setDefaults() +} + +func (r *MemcachedAutoscaler) setDefaults() { + var db dbapi.Memcached + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &db) + if err != nil { + _ = fmt.Errorf("can't get Memcached %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return + } + + r.setOpsReqOptsDefaults() + + if r.Spec.Storage != nil { + setDefaultStorageValues(r.Spec.Storage.Memcached) + } + + if r.Spec.Compute != nil { + setDefaultComputeValues(r.Spec.Compute.Memcached) + } +} + +func (r *MemcachedAutoscaler) setOpsReqOptsDefaults() { + if r.Spec.OpsRequestOptions == nil { + r.Spec.OpsRequestOptions = &MemcachedOpsRequestOptions{} + } + // Timeout is defaulted to 600s in ops-manager retries.go (to retry 120 times with 5sec pause between each) + // OplogMaxLagSeconds & ObjectsCountDiffPercentage are defaults to 0 + if r.Spec.OpsRequestOptions.Apply == "" { + r.Spec.OpsRequestOptions.Apply = opsapi.ApplyOptionIfReady + } +} + +var _ webhook.Validator = &MemcachedAutoscaler{} + +// ValidateCreate implements webhook.Validator so a webhook will be registered for the type +func (r *MemcachedAutoscaler) ValidateCreate() (admission.Warnings, error) { + mcLog.Info("validate create", "name", r.Name) + return nil, r.validate() +} + +// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type +func (r *MemcachedAutoscaler) ValidateUpdate(oldObj runtime.Object) (admission.Warnings, error) { + mcLog.Info("validate create", "name", r.Name) + return nil, r.validate() +} + +func (r *MemcachedAutoscaler) ValidateDelete() (admission.Warnings, error) { + return nil, nil +} + +func (r *MemcachedAutoscaler) validate() error { + if r.Spec.DatabaseRef == nil { + return errors.New("databaseRef can't be empty") + } + var kf dbapi.Memcached + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &kf) + if err != nil { + _ = fmt.Errorf("can't get Memcached %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return err + } + + return nil +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/mongodb_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/mongodb_webhook.go index 2001e5224..2bf98ec33 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/mongodb_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/mongodb_webhook.go @@ -115,7 +115,7 @@ func (in *MongoDBAutoscaler) ValidateCreate() (admission.Warnings, error) { // ValidateUpdate implements webhook.Validator so a webhook will be registered for the type func (in *MongoDBAutoscaler) ValidateUpdate(old runtime.Object) (admission.Warnings, error) { - mongoLog.Info("validate create", "name", in.Name) + mongoLog.Info("validate update", "name", in.Name) return nil, in.validate() } diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/mssqlserver_helpers.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/mssqlserver_helpers.go new file mode 100644 index 000000000..e1cb2c077 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/mssqlserver_helpers.go @@ -0,0 +1,67 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "fmt" + + "kubedb.dev/apimachinery/apis" + "kubedb.dev/apimachinery/apis/autoscaling" + "kubedb.dev/apimachinery/crds" + + "kmodules.xyz/client-go/apiextensions" +) + +func (r MSSQLServerAutoscaler) CustomResourceDefinition() *apiextensions.CustomResourceDefinition { + return crds.MustCustomResourceDefinition(SchemeGroupVersion.WithResource(ResourcePluralMSSQLServerAutoscaler)) +} + +var _ apis.ResourceInfo = &MSSQLServerAutoscaler{} + +func (r MSSQLServerAutoscaler) ResourceFQN() string { + return fmt.Sprintf("%s.%s", ResourcePluralMSSQLServerAutoscaler, autoscaling.GroupName) +} + +func (r MSSQLServerAutoscaler) ResourceShortCode() string { + return ResourceCodeMSSQLServerAutoscaler +} + +func (r MSSQLServerAutoscaler) ResourceKind() string { + return ResourceKindMSSQLServerAutoscaler +} + +func (r MSSQLServerAutoscaler) ResourceSingular() string { + return ResourceSingularMSSQLServerAutoscaler +} + +func (r MSSQLServerAutoscaler) ResourcePlural() string { + return ResourcePluralMSSQLServerAutoscaler +} + +func (r MSSQLServerAutoscaler) ValidateSpecs() error { + return nil +} + +var _ StatusAccessor = &MSSQLServerAutoscaler{} + +func (r *MSSQLServerAutoscaler) GetStatus() AutoscalerStatus { + return r.Status +} + +func (r *MSSQLServerAutoscaler) SetStatus(s AutoscalerStatus) { + r.Status = s +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/mssqlserver_types.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/mssqlserver_types.go new file mode 100644 index 000000000..19c787647 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/mssqlserver_types.go @@ -0,0 +1,100 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + + core "k8s.io/api/core/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +const ( + ResourceCodeMSSQLServerAutoscaler = "msscaler" + ResourceKindMSSQLServerAutoscaler = "MSSQLServerAutoscaler" + ResourceSingularMSSQLServerAutoscaler = "mssqlserverautoscaler" + ResourcePluralMSSQLServerAutoscaler = "mssqlserverautoscalers" +) + +// MSSQLServerAutoscaler is the configuration for a mssqlserver database +// autoscaler, which automatically manages pod resources based on historical and +// real time resource utilization. + +// +genclient +// +k8s:openapi-gen=true +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// +kubebuilder:object:root=true +// +kubebuilder:resource:path=mssqlserverautoscalers,singular=mssqlserverautoscaler,shortName=msscaler,categories={datastore,kubedb,appscode} +// +kubebuilder:subresource:status +type MSSQLServerAutoscaler struct { + metav1.TypeMeta `json:",inline"` + // Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta `json:"metadata,omitempty"` + + // Specification of the behavior of the autoscaler. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. + Spec MSSQLServerAutoscalerSpec `json:"spec"` + + // Current information about the autoscaler. + // +optional + Status AutoscalerStatus `json:"status,omitempty"` +} + +// MSSQLServerAutoscalerSpec is the specification of the behavior of the autoscaler. +type MSSQLServerAutoscalerSpec struct { + DatabaseRef *core.LocalObjectReference `json:"databaseRef"` + + // This field will be used to control the behaviour of ops-manager + OpsRequestOptions *MSSQLServerOpsRequestOptions `json:"opsRequestOptions,omitempty"` + + Compute *MSSQLServerComputeAutoscalerSpec `json:"compute,omitempty"` + Storage *MSSQLServerStorageAutoscalerSpec `json:"storage,omitempty"` +} + +type MSSQLServerComputeAutoscalerSpec struct { + // +optional + NodeTopology *NodeTopology `json:"nodeTopology,omitempty"` + + MSSQLServer *ComputeAutoscalerSpec `json:"mssqlserver,omitempty"` +} + +type MSSQLServerStorageAutoscalerSpec struct { + MSSQLServer *StorageAutoscalerSpec `json:"mssqlserver,omitempty"` +} + +type MSSQLServerOpsRequestOptions struct { + // Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure. + Timeout *metav1.Duration `json:"timeout,omitempty"` + + // ApplyOption is to control the execution of OpsRequest depending on the database state. + // +kubebuilder:default="IfReady" + Apply opsapi.ApplyOption `json:"apply,omitempty"` +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// MSSQLServerAutoscalerList is a list of MSSQLServerAutoscaler objects. +type MSSQLServerAutoscalerList struct { + metav1.TypeMeta `json:",inline"` + // metadata is the standard list metadata. + // +optional + metav1.ListMeta `json:"metadata"` + + // items is the list of mssqlserver database autoscaler objects. + Items []MSSQLServerAutoscaler `json:"items"` +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/mssqlserver_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/mssqlserver_webhook.go new file mode 100644 index 000000000..1c9942b9f --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/mssqlserver_webhook.go @@ -0,0 +1,111 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "context" + "errors" + "fmt" + + olddbapi "kubedb.dev/apimachinery/apis/kubedb/v1alpha2" + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/types" + logf "sigs.k8s.io/controller-runtime/pkg/log" + "sigs.k8s.io/controller-runtime/pkg/webhook" + "sigs.k8s.io/controller-runtime/pkg/webhook/admission" +) + +// log is for logging in this package. +var msLog = logf.Log.WithName("mssqlserver-autoscaler") + +var _ webhook.Defaulter = &MSSQLServerAutoscaler{} + +// Default implements webhook.CustomDefaulter so a webhook will be registered for the type +func (r *MSSQLServerAutoscaler) Default() { + msLog.Info("defaulting", "name", r.Name) + r.setDefaults() +} + +func (r *MSSQLServerAutoscaler) setDefaults() { + var db olddbapi.MSSQLServer + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &db) + if err != nil { + _ = fmt.Errorf("can't get MSSQLServer %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return + } + + r.setOpsReqOptsDefaults() + + if r.Spec.Storage != nil { + setDefaultStorageValues(r.Spec.Storage.MSSQLServer) + } + + if r.Spec.Compute != nil { + setDefaultComputeValues(r.Spec.Compute.MSSQLServer) + } +} + +func (r *MSSQLServerAutoscaler) setOpsReqOptsDefaults() { + if r.Spec.OpsRequestOptions == nil { + r.Spec.OpsRequestOptions = &MSSQLServerOpsRequestOptions{} + } + // Timeout is defaulted to 600s in ops-manager retries.go (to retry 120 times with 5sec pause between each) + // OplogMaxLagSeconds & ObjectsCountDiffPercentage are defaults to 0 + if r.Spec.OpsRequestOptions.Apply == "" { + r.Spec.OpsRequestOptions.Apply = opsapi.ApplyOptionIfReady + } +} + +var _ webhook.Validator = &MSSQLServerAutoscaler{} + +// ValidateCreate implements webhook.Validator so a webhook will be registered for the type +func (r *MSSQLServerAutoscaler) ValidateCreate() (admission.Warnings, error) { + msLog.Info("validate create", "name", r.Name) + return nil, r.validate() +} + +// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type +func (r *MSSQLServerAutoscaler) ValidateUpdate(oldObj runtime.Object) (admission.Warnings, error) { + msLog.Info("validate create", "name", r.Name) + return nil, r.validate() +} + +func (r *MSSQLServerAutoscaler) ValidateDelete() (admission.Warnings, error) { + return nil, nil +} + +func (r *MSSQLServerAutoscaler) validate() error { + if r.Spec.DatabaseRef == nil { + return errors.New("databaseRef can't be empty") + } + var kf olddbapi.MSSQLServer + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &kf) + if err != nil { + _ = fmt.Errorf("can't get MSSQLServer %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return err + } + + return nil +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/openapi_generated.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/openapi_generated.go index 987647617..8be246bb6 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/openapi_generated.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/openapi_generated.go @@ -491,6 +491,12 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.BucketWeight": schema_apimachinery_apis_autoscaling_v1alpha1_BucketWeight(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.Checkpoint": schema_apimachinery_apis_autoscaling_v1alpha1_Checkpoint(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.CheckpointReference": schema_apimachinery_apis_autoscaling_v1alpha1_CheckpointReference(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseAutoscaler": schema_apimachinery_apis_autoscaling_v1alpha1_ClickHouseAutoscaler(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseAutoscalerList": schema_apimachinery_apis_autoscaling_v1alpha1_ClickHouseAutoscalerList(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_ClickHouseAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseComputeAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_ClickHouseComputeAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseOpsRequestOptions": schema_apimachinery_apis_autoscaling_v1alpha1_ClickHouseOpsRequestOptions(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseStorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_ClickHouseStorageAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_ComputeAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeInMemoryStorageSpec": schema_apimachinery_apis_autoscaling_v1alpha1_ComputeInMemoryStorageSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ContainerResourcePolicy": schema_apimachinery_apis_autoscaling_v1alpha1_ContainerResourcePolicy(ref), @@ -512,6 +518,12 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.EtcdAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_EtcdAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.EtcdScalingPolicy": schema_apimachinery_apis_autoscaling_v1alpha1_EtcdScalingPolicy(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.EtcdScalingRules": schema_apimachinery_apis_autoscaling_v1alpha1_EtcdScalingRules(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBAutoscaler": schema_apimachinery_apis_autoscaling_v1alpha1_FerretDBAutoscaler(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBAutoscalerList": schema_apimachinery_apis_autoscaling_v1alpha1_FerretDBAutoscalerList(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_FerretDBAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBComputeAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_FerretDBComputeAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBOpsRequestOptions": schema_apimachinery_apis_autoscaling_v1alpha1_FerretDBOpsRequestOptions(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBStorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_FerretDBStorageAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.HistogramCheckpoint": schema_apimachinery_apis_autoscaling_v1alpha1_HistogramCheckpoint(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaAutoscaler": schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscaler(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaAutoscalerList": schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscalerList(ref), @@ -519,6 +531,12 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaComputeAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_KafkaComputeAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaOpsRequestOptions": schema_apimachinery_apis_autoscaling_v1alpha1_KafkaOpsRequestOptions(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaStorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_KafkaStorageAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerAutoscaler": schema_apimachinery_apis_autoscaling_v1alpha1_MSSQLServerAutoscaler(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerAutoscalerList": schema_apimachinery_apis_autoscaling_v1alpha1_MSSQLServerAutoscalerList(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_MSSQLServerAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerComputeAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_MSSQLServerComputeAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerOpsRequestOptions": schema_apimachinery_apis_autoscaling_v1alpha1_MSSQLServerOpsRequestOptions(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerStorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_MSSQLServerStorageAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MariaDBAutoscaler": schema_apimachinery_apis_autoscaling_v1alpha1_MariaDBAutoscaler(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MariaDBAutoscalerList": schema_apimachinery_apis_autoscaling_v1alpha1_MariaDBAutoscalerList(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MariaDBAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_MariaDBAutoscalerSpec(ref), @@ -526,11 +544,11 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MariaDBOpsRequestOptions": schema_apimachinery_apis_autoscaling_v1alpha1_MariaDBOpsRequestOptions(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MariaDBStorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_MariaDBStorageAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedAutoscaler": schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedAutoscaler(ref), - "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedAutoscalerBehavior": schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedAutoscalerBehavior(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedAutoscalerList": schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedAutoscalerList(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedAutoscalerSpec(ref), - "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedScalingPolicy": schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedScalingPolicy(ref), - "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedScalingRules": schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedScalingRules(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedComputeAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedComputeAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedOpsRequestOptions": schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedOpsRequestOptions(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedStorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedStorageAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MongoDBAutoscaler": schema_apimachinery_apis_autoscaling_v1alpha1_MongoDBAutoscaler(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MongoDBAutoscalerList": schema_apimachinery_apis_autoscaling_v1alpha1_MongoDBAutoscalerList(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MongoDBAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_MongoDBAutoscalerSpec(ref), @@ -551,11 +569,11 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PerconaXtraDBOpsRequestOptions": schema_apimachinery_apis_autoscaling_v1alpha1_PerconaXtraDBOpsRequestOptions(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PerconaXtraDBStorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_PerconaXtraDBStorageAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerAutoscaler": schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerAutoscaler(ref), - "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerAutoscalerBehavior": schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerAutoscalerBehavior(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerAutoscalerList": schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerAutoscalerList(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerAutoscalerSpec(ref), - "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerScalingPolicy": schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerScalingPolicy(ref), - "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerScalingRules": schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerScalingRules(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerComputeAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerComputeAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerOpsRequestOptions": schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerOpsRequestOptions(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerStorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerStorageAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgpoolAutoscaler": schema_apimachinery_apis_autoscaling_v1alpha1_PgpoolAutoscaler(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgpoolAutoscalerList": schema_apimachinery_apis_autoscaling_v1alpha1_PgpoolAutoscalerList(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgpoolAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_PgpoolAutoscalerSpec(ref), @@ -599,11 +617,23 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreComputeAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreComputeAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreOpsRequestOptions": schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreOpsRequestOptions(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreStorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreStorageAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrAutoscaler": schema_apimachinery_apis_autoscaling_v1alpha1_SolrAutoscaler(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrAutoscalerList": schema_apimachinery_apis_autoscaling_v1alpha1_SolrAutoscalerList(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_SolrAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrComputeAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_SolrComputeAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrOpsRequestOptions": schema_apimachinery_apis_autoscaling_v1alpha1_SolrOpsRequestOptions(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrStorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_SolrStorageAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_StorageAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageScalingRule": schema_apimachinery_apis_autoscaling_v1alpha1_StorageScalingRule(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.VPAStatus": schema_apimachinery_apis_autoscaling_v1alpha1_VPAStatus(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.VerticalPodAutopilotCondition": schema_apimachinery_apis_autoscaling_v1alpha1_VerticalPodAutopilotCondition(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.VerticalPodAutopilotRecommenderSelector": schema_apimachinery_apis_autoscaling_v1alpha1_VerticalPodAutopilotRecommenderSelector(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperAutoscaler": schema_apimachinery_apis_autoscaling_v1alpha1_ZooKeeperAutoscaler(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperAutoscalerList": schema_apimachinery_apis_autoscaling_v1alpha1_ZooKeeperAutoscalerList(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_ZooKeeperAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperComputeAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_ZooKeeperComputeAutoscalerSpec(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperOpsRequestOptions": schema_apimachinery_apis_autoscaling_v1alpha1_ZooKeeperOpsRequestOptions(ref), + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperStorageAutoscalerSpec": schema_apimachinery_apis_autoscaling_v1alpha1_ZooKeeperStorageAutoscalerSpec(ref), "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.quantity": schema_apimachinery_apis_autoscaling_v1alpha1_quantity(ref), } } @@ -25402,6 +25432,214 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_CheckpointReference(ref commo } } +func schema_apimachinery_apis_autoscaling_v1alpha1_ClickHouseAutoscaler(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "Specification of the behavior of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseAutoscalerSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Current information about the autoscaler.", + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus"), + }, + }, + }, + Required: []string{"spec"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseAutoscalerSpec"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_ClickHouseAutoscalerList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ClickHouseAutoscalerList is a list of ClickHouseAutoscaler objects.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "metadata is the standard list metadata.", + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "items is the list of clickhouse database autoscaler objects.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseAutoscaler"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseAutoscaler"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_ClickHouseAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ClickHouseAutoscalerSpec is the specification of the behavior of the autoscaler.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "databaseRef": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + }, + }, + "opsRequestOptions": { + SchemaProps: spec.SchemaProps{ + Description: "This field will be used to control the behaviour of ops-manager", + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseOpsRequestOptions"), + }, + }, + "compute": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseComputeAutoscalerSpec"), + }, + }, + "storage": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseStorageAutoscalerSpec"), + }, + }, + }, + Required: []string{"databaseRef"}, + }, + }, + Dependencies: []string{ + "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseOpsRequestOptions", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ClickHouseStorageAutoscalerSpec"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_ClickHouseComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "nodeTopology": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"), + }, + }, + "clickhouse": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_ClickHouseOpsRequestOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "timeout": { + SchemaProps: spec.SchemaProps{ + Description: "Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "apply": { + SchemaProps: spec.SchemaProps{ + Description: "ApplyOption is to control the execution of OpsRequest depending on the database state.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.Duration"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_ClickHouseStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "clickhouse": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"}, + } +} + func schema_apimachinery_apis_autoscaling_v1alpha1_ComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -26377,49 +26615,7 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_EtcdScalingRules(ref common.R } } -func schema_apimachinery_apis_autoscaling_v1alpha1_HistogramCheckpoint(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "HistogramCheckpoint contains data needed to reconstruct the histogram.", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "referenceTimestamp": { - SchemaProps: spec.SchemaProps{ - Description: "Reference timestamp for samples collected within this histogram.", - Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), - }, - }, - "bucketWeights": { - SchemaProps: spec.SchemaProps{ - Description: "Map from bucket index to bucket weight.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.BucketWeight"), - }, - }, - }, - }, - }, - "totalWeight": { - SchemaProps: spec.SchemaProps{ - Description: "Sum of samples to be used as denominator for weights from BucketWeights.", - Type: []string{"number"}, - Format: "double", - }, - }, - }, - }, - }, - Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.Time", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.BucketWeight"}, - } -} - -func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscaler(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_FerretDBAutoscaler(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ @@ -26450,7 +26646,7 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscaler(ref common.Re SchemaProps: spec.SchemaProps{ Description: "Specification of the behavior of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", Default: map[string]interface{}{}, - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaAutoscalerSpec"), + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBAutoscalerSpec"), }, }, "status": { @@ -26465,15 +26661,15 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscaler(ref common.Re }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaAutoscalerSpec"}, + "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBAutoscalerSpec"}, } } -func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscalerList(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_FerretDBAutoscalerList(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "KafkaAutoscalerList is a list of KafkaAutoscaler objects.", + Description: "FerretDBAutoscalerList is a list of FerretDBAutoscaler objects.", Type: []string{"object"}, Properties: map[string]spec.Schema{ "kind": { @@ -26499,13 +26695,13 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscalerList(ref commo }, "items": { SchemaProps: spec.SchemaProps{ - Description: "items is the list of kafka autoscaler objects.", + Description: "items is the list of ferretdb database autoscaler objects.", Type: []string{"array"}, Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaAutoscaler"), + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBAutoscaler"), }, }, }, @@ -26516,15 +26712,15 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscalerList(ref commo }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaAutoscaler"}, + "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBAutoscaler"}, } } -func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_FerretDBAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "KafkaAutoscalerSpec is the specification of the behavior of the autoscaler.", + Description: "FerretDBAutoscalerSpec is the specification of the behavior of the autoscaler.", Type: []string{"object"}, Properties: map[string]spec.Schema{ "databaseRef": { @@ -26535,17 +26731,17 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscalerSpec(ref commo "opsRequestOptions": { SchemaProps: spec.SchemaProps{ Description: "This field will be used to control the behaviour of ops-manager", - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaOpsRequestOptions"), + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBOpsRequestOptions"), }, }, "compute": { SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaComputeAutoscalerSpec"), + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBComputeAutoscalerSpec"), }, }, "storage": { SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaStorageAutoscalerSpec"), + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBStorageAutoscalerSpec"), }, }, }, @@ -26553,11 +26749,11 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscalerSpec(ref commo }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaOpsRequestOptions", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaStorageAutoscalerSpec"}, + "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBOpsRequestOptions", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.FerretDBStorageAutoscalerSpec"}, } } -func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_FerretDBComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ @@ -26568,20 +26764,488 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaComputeAutoscalerSpec(re Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"), }, }, - "node": { - SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), - }, - }, - "broker": { + "ferretdb": { SchemaProps: spec.SchemaProps{ Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), }, }, - "controller": { - SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), - }, + }, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_FerretDBOpsRequestOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "timeout": { + SchemaProps: spec.SchemaProps{ + Description: "Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "apply": { + SchemaProps: spec.SchemaProps{ + Description: "ApplyOption is to control the execution of OpsRequest depending on the database state.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.Duration"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_FerretDBStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "ferretdb": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_HistogramCheckpoint(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "HistogramCheckpoint contains data needed to reconstruct the histogram.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "referenceTimestamp": { + SchemaProps: spec.SchemaProps{ + Description: "Reference timestamp for samples collected within this histogram.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Time"), + }, + }, + "bucketWeights": { + SchemaProps: spec.SchemaProps{ + Description: "Map from bucket index to bucket weight.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.BucketWeight"), + }, + }, + }, + }, + }, + "totalWeight": { + SchemaProps: spec.SchemaProps{ + Description: "Sum of samples to be used as denominator for weights from BucketWeights.", + Type: []string{"number"}, + Format: "double", + }, + }, + }, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.Time", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.BucketWeight"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscaler(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "Specification of the behavior of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaAutoscalerSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Current information about the autoscaler.", + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus"), + }, + }, + }, + Required: []string{"spec"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaAutoscalerSpec"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscalerList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "KafkaAutoscalerList is a list of KafkaAutoscaler objects.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "metadata is the standard list metadata.", + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "items is the list of kafka autoscaler objects.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaAutoscaler"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaAutoscaler"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "KafkaAutoscalerSpec is the specification of the behavior of the autoscaler.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "databaseRef": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + }, + }, + "opsRequestOptions": { + SchemaProps: spec.SchemaProps{ + Description: "This field will be used to control the behaviour of ops-manager", + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaOpsRequestOptions"), + }, + }, + "compute": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaComputeAutoscalerSpec"), + }, + }, + "storage": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaStorageAutoscalerSpec"), + }, + }, + }, + Required: []string{"databaseRef"}, + }, + }, + Dependencies: []string{ + "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaOpsRequestOptions", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.KafkaStorageAutoscalerSpec"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "nodeTopology": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"), + }, + }, + "node": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), + }, + }, + "broker": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), + }, + }, + "controller": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaOpsRequestOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "timeout": { + SchemaProps: spec.SchemaProps{ + Description: "Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "apply": { + SchemaProps: spec.SchemaProps{ + Description: "ApplyOption is to control the execution of OpsRequest depending on the database state.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.Duration"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "node": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), + }, + }, + "broker": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), + }, + }, + "controller": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_MSSQLServerAutoscaler(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "Specification of the behavior of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerAutoscalerSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Current information about the autoscaler.", + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus"), + }, + }, + }, + Required: []string{"spec"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerAutoscalerSpec"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_MSSQLServerAutoscalerList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "MSSQLServerAutoscalerList is a list of MSSQLServerAutoscaler objects.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "metadata is the standard list metadata.", + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "items is the list of mssqlserver database autoscaler objects.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerAutoscaler"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerAutoscaler"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_MSSQLServerAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "MSSQLServerAutoscalerSpec is the specification of the behavior of the autoscaler.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "databaseRef": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + }, + }, + "opsRequestOptions": { + SchemaProps: spec.SchemaProps{ + Description: "This field will be used to control the behaviour of ops-manager", + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerOpsRequestOptions"), + }, + }, + "compute": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerComputeAutoscalerSpec"), + }, + }, + "storage": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerStorageAutoscalerSpec"), + }, + }, + }, + Required: []string{"databaseRef"}, + }, + }, + Dependencies: []string{ + "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerOpsRequestOptions", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MSSQLServerStorageAutoscalerSpec"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_MSSQLServerComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "nodeTopology": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"), + }, + }, + "mssqlserver": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), + }, }, }, }, @@ -26591,7 +27255,7 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaComputeAutoscalerSpec(re } } -func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaOpsRequestOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_MSSQLServerOpsRequestOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ @@ -26618,23 +27282,13 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaOpsRequestOptions(ref co } } -func schema_apimachinery_apis_autoscaling_v1alpha1_KafkaStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_MSSQLServerStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ Type: []string{"object"}, Properties: map[string]spec.Schema{ - "node": { - SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), - }, - }, - "broker": { - SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), - }, - }, - "controller": { + "mssqlserver": { SchemaProps: spec.SchemaProps{ Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), }, @@ -26883,26 +27537,27 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedAutoscaler(ref commo }, "metadata": { SchemaProps: spec.SchemaProps{ - Description: "metadata is the standard object metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Description: "Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", Default: map[string]interface{}{}, Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "spec": { SchemaProps: spec.SchemaProps{ - Description: "spec is the specification for the behaviour of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status.", + Description: "Specification of the behavior of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", Default: map[string]interface{}{}, Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedAutoscalerSpec"), }, }, "status": { SchemaProps: spec.SchemaProps{ - Description: "status is the current information about the autoscaler.", + Description: "Current information about the autoscaler.", Default: map[string]interface{}{}, Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus"), }, }, }, + Required: []string{"spec"}, }, }, Dependencies: []string{ @@ -26910,38 +27565,11 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedAutoscaler(ref commo } } -func schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedAutoscalerBehavior(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "MemcachedAutoscalerBehavior configures the scaling behavior of the target in both Up and Down directions (scaleUp and scaleDown fields respectively).", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "scaleUp": { - SchemaProps: spec.SchemaProps{ - Description: "scaleUp is scaling policy for scaling Up. If not set, the default value is the higher of:\n * increase no more than 4 pods per 60 seconds\n * double the number of pods per 60 seconds\nNo stabilization is used.", - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedScalingRules"), - }, - }, - "scaleDown": { - SchemaProps: spec.SchemaProps{ - Description: "scaleDown is scaling policy for scaling Down. If not set, the default value is to allow to scale down to minReplicas pods, with a 300 second stabilization window (i.e., the highest recommendation for the last 300sec is used).", - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedScalingRules"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedScalingRules"}, - } -} - func schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedAutoscalerList(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "MemcachedAutoscalerList is a list of horizontal pod autoscaler objects.", + Description: "MemcachedAutoscalerList is a list of MemcachedAutoscaler objects.", Type: []string{"object"}, Properties: map[string]spec.Schema{ "kind": { @@ -26967,7 +27595,7 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedAutoscalerList(ref c }, "items": { SchemaProps: spec.SchemaProps{ - Description: "items is the list of horizontal pod autoscaler objects.", + Description: "items is the list of memcached database autoscaler objects.", Type: []string{"array"}, Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ @@ -26992,138 +27620,112 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedAutoscalerSpec(ref c return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "MemcachedAutoscalerSpec describes the desired functionality of the MemcachedAutoscaler.", + Description: "MemcachedAutoscalerSpec is the specification of the behavior of the autoscaler.", Type: []string{"object"}, Properties: map[string]spec.Schema{ - "scaleTargetRef": { - SchemaProps: spec.SchemaProps{ - Description: "scaleTargetRef points to the target resource to scale, and is used to the pods for which metrics should be collected, as well as to actually change the replica count.", - Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), - }, - }, - "minReplicas": { + "databaseRef": { SchemaProps: spec.SchemaProps{ - Description: "minReplicas is the lower limit for the number of replicas to which the autoscaler can scale down. It defaults to 1 pod. minReplicas is allowed to be 0 if the alpha feature gate HPAScaleToZero is enabled and at least one Object or External metric is configured. Scaling is active as long as at least one metric value is available.", - Type: []string{"integer"}, - Format: "int32", + Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), }, }, - "maxReplicas": { + "opsRequestOptions": { SchemaProps: spec.SchemaProps{ - Description: "maxReplicas is the upper limit for the number of replicas to which the autoscaler can scale up. It cannot be less that minReplicas.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", + Description: "This field will be used to control the behaviour of ops-manager", + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedOpsRequestOptions"), }, }, - "metrics": { + "compute": { SchemaProps: spec.SchemaProps{ - Description: "metrics contains the specifications for which to use to calculate the desired replica count (the maximum replica count across all metrics will be used). The desired replica count is calculated multiplying the ratio between the target value and the current value by the current number of pods. Ergo, metrics used must decrease as the pod count is increased, and vice-versa. See the individual metric source types for more information about how each type of metric must respond. If not set, the default metric will be set to 80% average CPU utilization.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/autoscaling/v2beta2.MetricSpec"), - }, - }, - }, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedComputeAutoscalerSpec"), }, }, - "behavior": { + "storage": { SchemaProps: spec.SchemaProps{ - Description: "behavior configures the scaling behavior of the target in both Up and Down directions (scaleUp and scaleDown fields respectively). If not set, the default MemcachedScalingRules for scale up and scale down are used.", - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedAutoscalerBehavior"), + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedStorageAutoscalerSpec"), }, }, }, - Required: []string{"scaleTargetRef", "maxReplicas"}, + Required: []string{"databaseRef"}, }, }, Dependencies: []string{ - "k8s.io/api/autoscaling/v2beta2.MetricSpec", "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedAutoscalerBehavior"}, + "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedOpsRequestOptions", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedStorageAutoscalerSpec"}, } } -func schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedScalingPolicy(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "MemcachedScalingPolicy is a single policy which must hold true for a specified past interval.", - Type: []string{"object"}, + Type: []string{"object"}, Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Type is used to specify the scaling policy.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "value": { + "nodeTopology": { SchemaProps: spec.SchemaProps{ - Description: "Value contains the amount of change which is permitted by the policy. It must be greater than zero", - Default: 0, - Type: []string{"integer"}, - Format: "int32", + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"), }, }, - "periodSeconds": { + "memcached": { SchemaProps: spec.SchemaProps{ - Description: "PeriodSeconds specifies the window of time for which the policy should hold true. PeriodSeconds must be greater than zero and less than or equal to 1800 (30 min).", - Default: 0, - Type: []string{"integer"}, - Format: "int32", + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), }, }, }, - Required: []string{"type", "value", "periodSeconds"}, }, }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"}, } } -func schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedScalingRules(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedOpsRequestOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "MemcachedScalingRules configures the scaling behavior for one direction. These Rules are applied after calculating DesiredReplicas from metrics for the HPA. They can limit the scaling velocity by specifying scaling policies. They can prevent flapping by specifying the stabilization window, so that the number of replicas is not set instantly, instead, the safest value from the stabilization window is chosen.", - Type: []string{"object"}, + Type: []string{"object"}, Properties: map[string]spec.Schema{ - "stabilizationWindowSeconds": { + "readinessCriteria": { SchemaProps: spec.SchemaProps{ - Description: "StabilizationWindowSeconds is the number of seconds for which past recommendations should be considered while scaling up or scaling down. StabilizationWindowSeconds must be greater than or equal to zero and less than or equal to 3600 (one hour). If not set, use the default values: - For scale up: 0 (i.e. no stabilization is done). - For scale down: 300 (i.e. the stabilization window is 300 seconds long).", - Type: []string{"integer"}, - Format: "int32", + Description: "Specifies the Readiness Criteria", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.MemcachedReplicaReadinessCriteria"), }, }, - "selectPolicy": { + "timeout": { SchemaProps: spec.SchemaProps{ - Description: "selectPolicy is used to specify which policy should be used. If not set, the default value MaxPolicySelect is used.", + Description: "Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "apply": { + SchemaProps: spec.SchemaProps{ + Description: "ApplyOption is to control the execution of OpsRequest depending on the database state.", Type: []string{"string"}, Format: "", }, }, - "policies": { + }, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.Duration", "kubedb.dev/apimachinery/apis/ops/v1alpha1.MemcachedReplicaReadinessCriteria"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_MemcachedStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "memcached": { SchemaProps: spec.SchemaProps{ - Description: "policies is a list of potential scaling polices which can be used during scaling. At least one policy must be specified, otherwise the MemcachedScalingRules will be discarded as invalid", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedScalingPolicy"), - }, - }, - }, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), }, }, }, }, }, Dependencies: []string{ - "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.MemcachedScalingPolicy"}, + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"}, } } @@ -27873,26 +28475,27 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerAutoscaler(ref commo }, "metadata": { SchemaProps: spec.SchemaProps{ - Description: "metadata is the standard object metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata", + Description: "Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", Default: map[string]interface{}{}, Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), }, }, "spec": { SchemaProps: spec.SchemaProps{ - Description: "spec is the specification for the behaviour of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status.", + Description: "Specification of the behavior of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", Default: map[string]interface{}{}, Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerAutoscalerSpec"), }, }, "status": { SchemaProps: spec.SchemaProps{ - Description: "status is the current information about the autoscaler.", + Description: "Current information about the autoscaler.", Default: map[string]interface{}{}, Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus"), }, }, }, + Required: []string{"spec"}, }, }, Dependencies: []string{ @@ -27900,38 +28503,11 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerAutoscaler(ref commo } } -func schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerAutoscalerBehavior(ref common.ReferenceCallback) common.OpenAPIDefinition { - return common.OpenAPIDefinition{ - Schema: spec.Schema{ - SchemaProps: spec.SchemaProps{ - Description: "PgBouncerAutoscalerBehavior configures the scaling behavior of the target in both Up and Down directions (scaleUp and scaleDown fields respectively).", - Type: []string{"object"}, - Properties: map[string]spec.Schema{ - "scaleUp": { - SchemaProps: spec.SchemaProps{ - Description: "scaleUp is scaling policy for scaling Up. If not set, the default value is the higher of:\n * increase no more than 4 pods per 60 seconds\n * double the number of pods per 60 seconds\nNo stabilization is used.", - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerScalingRules"), - }, - }, - "scaleDown": { - SchemaProps: spec.SchemaProps{ - Description: "scaleDown is scaling policy for scaling Down. If not set, the default value is to allow to scale down to minReplicas pods, with a 300 second stabilization window (i.e., the highest recommendation for the last 300sec is used).", - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerScalingRules"), - }, - }, - }, - }, - }, - Dependencies: []string{ - "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerScalingRules"}, - } -} - func schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerAutoscalerList(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "PgBouncerAutoscalerList is a list of horizontal pod autoscaler objects.", + Description: "PgBouncerAutoscalerList is a list of PgBouncerAutoscaler objects.", Type: []string{"object"}, Properties: map[string]spec.Schema{ "kind": { @@ -27957,7 +28533,7 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerAutoscalerList(ref c }, "items": { SchemaProps: spec.SchemaProps{ - Description: "items is the list of horizontal pod autoscaler objects.", + Description: "items is the list of pgbouncer database autoscaler objects.", Type: []string{"array"}, Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ @@ -27982,138 +28558,101 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerAutoscalerSpec(ref c return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "PgBouncerAutoscalerSpec describes the desired functionality of the PgBouncerAutoscaler.", + Description: "PgBouncerAutoscalerSpec is the specification of the behavior of the autoscaler.", Type: []string{"object"}, Properties: map[string]spec.Schema{ - "serverRef": { - SchemaProps: spec.SchemaProps{ - Description: "scaleTargetRef points to the target resource to scale, and is used to the pods for which metrics should be collected, as well as to actually change the replica count.", - Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), - }, - }, - "minReplicas": { - SchemaProps: spec.SchemaProps{ - Description: "minReplicas is the lower limit for the number of replicas to which the autoscaler can scale down. It defaults to 1 pod. minReplicas is allowed to be 0 if the alpha feature gate HPAScaleToZero is enabled and at least one Object or External metric is configured. Scaling is active as long as at least one metric value is available.", - Type: []string{"integer"}, - Format: "int32", - }, - }, - "maxReplicas": { + "databaseRef": { SchemaProps: spec.SchemaProps{ - Description: "maxReplicas is the upper limit for the number of replicas to which the autoscaler can scale up. It cannot be less that minReplicas.", - Default: 0, - Type: []string{"integer"}, - Format: "int32", + Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), }, }, - "metrics": { + "opsRequestOptions": { SchemaProps: spec.SchemaProps{ - Description: "metrics contains the specifications for which to use to calculate the desired replica count (the maximum replica count across all metrics will be used). The desired replica count is calculated multiplying the ratio between the target value and the current value by the current number of pods. Ergo, metrics used must decrease as the pod count is increased, and vice-versa. See the individual metric source types for more information about how each type of metric must respond. If not set, the default metric will be set to 80% average CPU utilization.", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("k8s.io/api/autoscaling/v2beta2.MetricSpec"), - }, - }, - }, + Description: "OpsRequestOptions will be used to control the behaviour of ops-manager", + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerOpsRequestOptions"), }, }, - "behavior": { + "compute": { SchemaProps: spec.SchemaProps{ - Description: "behavior configures the scaling behavior of the target in both Up and Down directions (scaleUp and scaleDown fields respectively). If not set, the default PgBouncerScalingRules for scale up and scale down are used.", - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerAutoscalerBehavior"), + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerComputeAutoscalerSpec"), }, }, }, - Required: []string{"serverRef", "maxReplicas"}, + Required: []string{"databaseRef"}, }, }, Dependencies: []string{ - "k8s.io/api/autoscaling/v2beta2.MetricSpec", "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerAutoscalerBehavior"}, + "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerOpsRequestOptions"}, } } -func schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerScalingPolicy(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "PgBouncerScalingPolicy is a single policy which must hold true for a specified past interval.", - Type: []string{"object"}, + Type: []string{"object"}, Properties: map[string]spec.Schema{ - "type": { - SchemaProps: spec.SchemaProps{ - Description: "Type is used to specify the scaling policy.", - Default: "", - Type: []string{"string"}, - Format: "", - }, - }, - "value": { + "nodeTopology": { SchemaProps: spec.SchemaProps{ - Description: "Value contains the amount of change which is permitted by the policy. It must be greater than zero", - Default: 0, - Type: []string{"integer"}, - Format: "int32", + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"), }, }, - "periodSeconds": { + "pgbouncer": { SchemaProps: spec.SchemaProps{ - Description: "PeriodSeconds specifies the window of time for which the policy should hold true. PeriodSeconds must be greater than zero and less than or equal to 1800 (30 min).", - Default: 0, - Type: []string{"integer"}, - Format: "int32", + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), }, }, }, - Required: []string{"type", "value", "periodSeconds"}, }, }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"}, } } -func schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerScalingRules(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerOpsRequestOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "PgBouncerScalingRules configures the scaling behavior for one direction. These Rules are applied after calculating DesiredReplicas from metrics for the HPA. They can limit the scaling velocity by specifying scaling policies. They can prevent flapping by specifying the stabilization window, so that the number of replicas is not set instantly, instead, the safest value from the stabilization window is chosen.", - Type: []string{"object"}, + Type: []string{"object"}, Properties: map[string]spec.Schema{ - "stabilizationWindowSeconds": { + "timeout": { SchemaProps: spec.SchemaProps{ - Description: "StabilizationWindowSeconds is the number of seconds for which past recommendations should be considered while scaling up or scaling down. StabilizationWindowSeconds must be greater than or equal to zero and less than or equal to 3600 (one hour). If not set, use the default values: - For scale up: 0 (i.e. no stabilization is done). - For scale down: 300 (i.e. the stabilization window is 300 seconds long).", - Type: []string{"integer"}, - Format: "int32", + Description: "Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), }, }, - "selectPolicy": { + "apply": { SchemaProps: spec.SchemaProps{ - Description: "selectPolicy is used to specify which policy should be used. If not set, the default value MaxPolicySelect is used.", + Description: "Apply is to control the execution of OpsRequest depending on the database state.", Type: []string{"string"}, Format: "", }, }, - "policies": { + }, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.Duration"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_PgBouncerStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "pgbouncer": { SchemaProps: spec.SchemaProps{ - Description: "policies is a list of potential scaling polices which can be used during scaling. At least one policy must be specified, otherwise the PgBouncerScalingRules will be discarded as invalid", - Type: []string{"array"}, - Items: &spec.SchemaOrArray{ - Schema: &spec.Schema{ - SchemaProps: spec.SchemaProps{ - Default: map[string]interface{}{}, - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerScalingPolicy"), - }, - }, - }, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), }, }, }, }, }, Dependencies: []string{ - "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgBouncerScalingPolicy"}, + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"}, } } @@ -28232,7 +28771,7 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_PgpoolAutoscalerSpec(ref comm }, "opsRequestOptions": { SchemaProps: spec.SchemaProps{ - Description: "This field will be used to control the behaviour of ops-manager", + Description: "OpsRequestOptions will be used to control the behaviour of ops-manager", Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PgpoolOpsRequestOptions"), }, }, @@ -28477,7 +29016,7 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_PostgresAutoscalerSpec(ref co }, "opsRequestOptions": { SchemaProps: spec.SchemaProps{ - Description: "This field will be used to control the behaviour of ops-manager", + Description: "OpsRequestOptions will be used to control the behaviour of ops-manager", Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.PostgresOpsRequestOptions"), }, }, @@ -29393,7 +29932,225 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelAutoscalerSpec(r }, "compute": { SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelComputeAutoscalerSpec"), + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelComputeAutoscalerSpec"), + }, + }, + }, + Required: []string{"databaseRef"}, + }, + }, + Dependencies: []string{ + "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelOpsRequestOptions"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "nodeTopology": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"), + }, + }, + "sentinel": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelOpsRequestOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "timeout": { + SchemaProps: spec.SchemaProps{ + Description: "Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "apply": { + SchemaProps: spec.SchemaProps{ + Description: "ApplyOption is to control the execution of OpsRequest depending on the database state.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.Duration"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_RedisStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "standalone": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), + }, + }, + "cluster": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), + }, + }, + "sentinel": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreAutoscaler(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "Specification of the behavior of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreAutoscalerSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Current information about the autoscaler.", + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus"), + }, + }, + }, + Required: []string{"spec"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreAutoscalerSpec"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreAutoscalerList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SinglestoreAutoscalerList is a list of SinglestoreAutoscaler objects.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "metadata is the standard list metadata.", + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "items is the list of mongodb database autoscaler objects.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreAutoscaler"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreAutoscaler"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SinglestoreAutoscalerSpec is the specification of the behavior of the autoscaler.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "databaseRef": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + }, + }, + "opsRequestOptions": { + SchemaProps: spec.SchemaProps{ + Description: "This field will be used to control the behaviour of ops-manager", + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreOpsRequestOptions"), + }, + }, + "compute": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreComputeAutoscalerSpec"), + }, + }, + "storage": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreStorageAutoscalerSpec"), }, }, }, @@ -29401,11 +30158,11 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelAutoscalerSpec(r }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.RedisSentinelOpsRequestOptions"}, + "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreOpsRequestOptions", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreStorageAutoscalerSpec"}, } } -func schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ @@ -29416,7 +30173,17 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelComputeAutoscale Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"), }, }, - "sentinel": { + "node": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), + }, + }, + "aggregator": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), + }, + }, + "leaf": { SchemaProps: spec.SchemaProps{ Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), }, @@ -29429,7 +30196,7 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelComputeAutoscale } } -func schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelOpsRequestOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreOpsRequestOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ @@ -29456,23 +30223,23 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_RedisSentinelOpsRequestOption } } -func schema_apimachinery_apis_autoscaling_v1alpha1_RedisStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ Type: []string{"object"}, Properties: map[string]spec.Schema{ - "standalone": { + "node": { SchemaProps: spec.SchemaProps{ Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), }, }, - "cluster": { + "aggregator": { SchemaProps: spec.SchemaProps{ Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), }, }, - "sentinel": { + "leaf": { SchemaProps: spec.SchemaProps{ Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), }, @@ -29485,7 +30252,7 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_RedisStorageAutoscalerSpec(re } } -func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreAutoscaler(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_SolrAutoscaler(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ @@ -29516,7 +30283,7 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreAutoscaler(ref com SchemaProps: spec.SchemaProps{ Description: "Specification of the behavior of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", Default: map[string]interface{}{}, - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreAutoscalerSpec"), + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrAutoscalerSpec"), }, }, "status": { @@ -29531,15 +30298,15 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreAutoscaler(ref com }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreAutoscalerSpec"}, + "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrAutoscalerSpec"}, } } -func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreAutoscalerList(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_SolrAutoscalerList(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "SinglestoreAutoscalerList is a list of SinglestoreAutoscaler objects.", + Description: "SolrAutoscalerList is a list of SolrAutoscaler objects.", Type: []string{"object"}, Properties: map[string]spec.Schema{ "kind": { @@ -29565,13 +30332,13 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreAutoscalerList(ref }, "items": { SchemaProps: spec.SchemaProps{ - Description: "items is the list of mongodb database autoscaler objects.", + Description: "items is the list of solr database autoscaler objects.", Type: []string{"array"}, Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreAutoscaler"), + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrAutoscaler"), }, }, }, @@ -29582,15 +30349,15 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreAutoscalerList(ref }, }, Dependencies: []string{ - "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreAutoscaler"}, + "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrAutoscaler"}, } } -func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_SolrAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ - Description: "SinglestoreAutoscalerSpec is the specification of the behavior of the autoscaler.", + Description: "SolrAutoscalerSpec is the specification of the behavior of the autoscaler.", Type: []string{"object"}, Properties: map[string]spec.Schema{ "databaseRef": { @@ -29601,17 +30368,17 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreAutoscalerSpec(ref "opsRequestOptions": { SchemaProps: spec.SchemaProps{ Description: "This field will be used to control the behaviour of ops-manager", - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreOpsRequestOptions"), + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrOpsRequestOptions"), }, }, "compute": { SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreComputeAutoscalerSpec"), + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrComputeAutoscalerSpec"), }, }, "storage": { SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreStorageAutoscalerSpec"), + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrStorageAutoscalerSpec"), }, }, }, @@ -29619,11 +30386,11 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreAutoscalerSpec(ref }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreOpsRequestOptions", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SinglestoreStorageAutoscalerSpec"}, + "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrOpsRequestOptions", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.SolrStorageAutoscalerSpec"}, } } -func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_SolrComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ @@ -29634,17 +30401,7 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreComputeAutoscalerS Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"), }, }, - "node": { - SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), - }, - }, - "aggregator": { - SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), - }, - }, - "leaf": { + "solr": { SchemaProps: spec.SchemaProps{ Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), }, @@ -29657,7 +30414,7 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreComputeAutoscalerS } } -func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreOpsRequestOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_SolrOpsRequestOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ @@ -29684,23 +30441,13 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreOpsRequestOptions( } } -func schema_apimachinery_apis_autoscaling_v1alpha1_SinglestoreStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { +func schema_apimachinery_apis_autoscaling_v1alpha1_SolrStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ Type: []string{"object"}, Properties: map[string]spec.Schema{ - "node": { - SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), - }, - }, - "aggregator": { - SchemaProps: spec.SchemaProps{ - Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), - }, - }, - "leaf": { + "solr": { SchemaProps: spec.SchemaProps{ Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), }, @@ -29927,6 +30674,214 @@ func schema_apimachinery_apis_autoscaling_v1alpha1_VerticalPodAutopilotRecommend } } +func schema_apimachinery_apis_autoscaling_v1alpha1_ZooKeeperAutoscaler(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Description: "Specification of the behavior of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperAutoscalerSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Description: "Current information about the autoscaler.", + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus"), + }, + }, + }, + Required: []string{"spec"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.AutoscalerStatus", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperAutoscalerSpec"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_ZooKeeperAutoscalerList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ZooKeeperAutoscalerList is a list of ZooKeeperAutoscaler objects.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Description: "metadata is the standard list metadata.", + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "items is the list of zookeeper database autoscaler objects.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperAutoscaler"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperAutoscaler"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_ZooKeeperAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "ZooKeeperAutoscalerSpec is the specification of the behavior of the autoscaler.", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "databaseRef": { + SchemaProps: spec.SchemaProps{ + Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + }, + }, + "opsRequestOptions": { + SchemaProps: spec.SchemaProps{ + Description: "This field will be used to control the behaviour of ops-manager", + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperOpsRequestOptions"), + }, + }, + "compute": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperComputeAutoscalerSpec"), + }, + }, + "storage": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperStorageAutoscalerSpec"), + }, + }, + }, + Required: []string{"databaseRef"}, + }, + }, + Dependencies: []string{ + "k8s.io/api/core/v1.LocalObjectReference", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperOpsRequestOptions", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ZooKeeperStorageAutoscalerSpec"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_ZooKeeperComputeAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "nodeTopology": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"), + }, + }, + "zookeeper": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.ComputeAutoscalerSpec", "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.NodeTopology"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_ZooKeeperOpsRequestOptions(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "timeout": { + SchemaProps: spec.SchemaProps{ + Description: "Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "apply": { + SchemaProps: spec.SchemaProps{ + Description: "ApplyOption is to control the execution of OpsRequest depending on the database state.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.Duration"}, + } +} + +func schema_apimachinery_apis_autoscaling_v1alpha1_ZooKeeperStorageAutoscalerSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "zookeeper": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1.StorageAutoscalerSpec"}, + } +} + func schema_apimachinery_apis_autoscaling_v1alpha1_quantity(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgbouncer_types.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgbouncer_types.go index 2d9ecbe12..e8219c61e 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgbouncer_types.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgbouncer_types.go @@ -17,7 +17,8 @@ limitations under the License. package v1alpha1 import ( - "k8s.io/api/autoscaling/v2beta2" + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + core "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) @@ -29,9 +30,9 @@ const ( ResourcePluralPgBouncerAutoscaler = "pgbouncerautoscalers" ) -// PgBouncerAutoscaler is the configuration for a horizontal pod -// autoscaler, which automatically manages the replica count of any resource -// implementing the scale subresource based on the metrics specified. +// PgBouncerAutoscaler is the configuration for a pgbouncer database +// autoscaler, which automatically manages pod resources based on historical and +// real time resource utilization. // +genclient // +k8s:openapi-gen=true @@ -42,118 +43,57 @@ const ( // +kubebuilder:subresource:status type PgBouncerAutoscaler struct { metav1.TypeMeta `json:",inline"` - // metadata is the standard object metadata. - // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata + // Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional metav1.ObjectMeta `json:"metadata,omitempty"` - // spec is the specification for the behaviour of the autoscaler. - // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status. - // +optional - Spec PgBouncerAutoscalerSpec `json:"spec,omitempty"` + // Specification of the behavior of the autoscaler. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. + Spec PgBouncerAutoscalerSpec `json:"spec"` - // status is the current information about the autoscaler. + // Current information about the autoscaler. // +optional Status AutoscalerStatus `json:"status,omitempty"` } -// PgBouncerAutoscalerSpec describes the desired functionality of the PgBouncerAutoscaler. +// PgBouncerAutoscalerSpec is the specification of the behavior of the autoscaler. type PgBouncerAutoscalerSpec struct { - // scaleTargetRef points to the target resource to scale, and is used to the pods for which metrics - // should be collected, as well as to actually change the replica count. - ServerRef core.LocalObjectReference `json:"serverRef"` - // minReplicas is the lower limit for the number of replicas to which the autoscaler - // can scale down. It defaults to 1 pod. minReplicas is allowed to be 0 if the - // alpha feature gate HPAScaleToZero is enabled and at least one Object or External - // metric is configured. Scaling is active as long as at least one metric value is - // available. - // +optional - MinReplicas *int32 `json:"minReplicas,omitempty"` - // maxReplicas is the upper limit for the number of replicas to which the autoscaler can scale up. - // It cannot be less that minReplicas. - MaxReplicas int32 `json:"maxReplicas"` - // metrics contains the specifications for which to use to calculate the - // desired replica count (the maximum replica count across all metrics will - // be used). The desired replica count is calculated multiplying the - // ratio between the target value and the current value by the current - // number of pods. Ergo, metrics used must decrease as the pod count is - // increased, and vice-versa. See the individual metric source types for - // more information about how each type of metric must respond. - // If not set, the default metric will be set to 80% average CPU utilization. - // +optional - Metrics []v2beta2.MetricSpec `json:"metrics,omitempty"` + DatabaseRef *core.LocalObjectReference `json:"databaseRef"` - // behavior configures the scaling behavior of the target - // in both Up and Down directions (scaleUp and scaleDown fields respectively). - // If not set, the default PgBouncerScalingRules for scale up and scale down are used. - // +optional - Behavior *PgBouncerAutoscalerBehavior `json:"behavior,omitempty"` + // OpsRequestOptions will be used to control the behaviour of ops-manager + OpsRequestOptions *PgBouncerOpsRequestOptions `json:"opsRequestOptions,omitempty"` + + Compute *PgBouncerComputeAutoscalerSpec `json:"compute,omitempty"` } -// PgBouncerAutoscalerBehavior configures the scaling behavior of the target -// in both Up and Down directions (scaleUp and scaleDown fields respectively). -type PgBouncerAutoscalerBehavior struct { - // scaleUp is scaling policy for scaling Up. - // If not set, the default value is the higher of: - // * increase no more than 4 pods per 60 seconds - // * double the number of pods per 60 seconds - // No stabilization is used. - // +optional - ScaleUp *PgBouncerScalingRules `json:"scaleUp,omitempty"` - // scaleDown is scaling policy for scaling Down. - // If not set, the default value is to allow to scale down to minReplicas pods, with a - // 300 second stabilization window (i.e., the highest recommendation for - // the last 300sec is used). +type PgBouncerComputeAutoscalerSpec struct { // +optional - ScaleDown *PgBouncerScalingRules `json:"scaleDown,omitempty"` + NodeTopology *NodeTopology `json:"nodeTopology,omitempty"` + + PgBouncer *ComputeAutoscalerSpec `json:"pgbouncer,omitempty"` } -// PgBouncerScalingRules configures the scaling behavior for one direction. -// These Rules are applied after calculating DesiredReplicas from metrics for the HPA. -// They can limit the scaling velocity by specifying scaling policies. -// They can prevent flapping by specifying the stabilization window, so that the -// number of replicas is not set instantly, instead, the safest value from the stabilization -// window is chosen. -type PgBouncerScalingRules struct { - // StabilizationWindowSeconds is the number of seconds for which past recommendations should be - // considered while scaling up or scaling down. - // StabilizationWindowSeconds must be greater than or equal to zero and less than or equal to 3600 (one hour). - // If not set, use the default values: - // - For scale up: 0 (i.e. no stabilization is done). - // - For scale down: 300 (i.e. the stabilization window is 300 seconds long). - // +optional - StabilizationWindowSeconds *int32 `json:"stabilizationWindowSeconds"` - // selectPolicy is used to specify which policy should be used. - // If not set, the default value MaxPolicySelect is used. - // +optional - SelectPolicy *v2beta2.ScalingPolicySelect `json:"selectPolicy,omitempty"` - // policies is a list of potential scaling polices which can be used during scaling. - // At least one policy must be specified, otherwise the PgBouncerScalingRules will be discarded as invalid - // +optional - Policies []PgBouncerScalingPolicy `json:"policies,omitempty"` +type PgBouncerStorageAutoscalerSpec struct { + PgBouncer *StorageAutoscalerSpec `json:"pgbouncer,omitempty"` } -// PgBouncerScalingPolicy is a single policy which must hold true for a specified past interval. -type PgBouncerScalingPolicy struct { - // Type is used to specify the scaling policy. - Type v2beta2.HPAScalingPolicyType `json:"type"` - // Value contains the amount of change which is permitted by the policy. - // It must be greater than zero - Value int32 `json:"value"` - // PeriodSeconds specifies the window of time for which the policy should hold true. - // PeriodSeconds must be greater than zero and less than or equal to 1800 (30 min). - PeriodSeconds int32 `json:"periodSeconds"` +type PgBouncerOpsRequestOptions struct { + // Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure. + Timeout *metav1.Duration `json:"timeout,omitempty"` + + // Apply is to control the execution of OpsRequest depending on the database state. + // +kubebuilder:default="IfReady" + Apply opsapi.ApplyOption `json:"apply,omitempty"` } // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object - -// PgBouncerAutoscalerList is a list of horizontal pod autoscaler objects. +// PgBouncerAutoscalerList is a list of PgBouncerAutoscaler objects. type PgBouncerAutoscalerList struct { metav1.TypeMeta `json:",inline"` // metadata is the standard list metadata. // +optional - metav1.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta `json:"metadata"` - // items is the list of horizontal pod autoscaler objects. + // items is the list of pgbouncer database autoscaler objects. Items []PgBouncerAutoscaler `json:"items"` } diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgbouncer_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgbouncer_webhook.go new file mode 100644 index 000000000..d7fd405c1 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgbouncer_webhook.go @@ -0,0 +1,119 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "context" + "errors" + "fmt" + + dbapi "kubedb.dev/apimachinery/apis/kubedb/v1" + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/types" + "sigs.k8s.io/controller-runtime/pkg/builder" + logf "sigs.k8s.io/controller-runtime/pkg/log" + "sigs.k8s.io/controller-runtime/pkg/manager" + "sigs.k8s.io/controller-runtime/pkg/webhook" + "sigs.k8s.io/controller-runtime/pkg/webhook/admission" +) + +// log is for logging in this package. +var pbLog = logf.Log.WithName("pgbouncer-autoscaler") + +func (in *PgBouncerAutoscaler) SetupWebhookWithManager(mgr manager.Manager) error { + return builder.WebhookManagedBy(mgr). + For(in). + Complete() +} + +// +kubebuilder:webhook:path=/mutate-autoscaling-kubedb-com-v1alpha1-pgbouncerautoscaler,mutating=true,failurePolicy=fail,sideEffects=None,groups=autoscaling.kubedb.com,resources=pgbouncerautoscaler,verbs=create;update,versions=v1alpha1,name=mpgbouncerautoscaler.kb.io,admissionReviewVersions={v1,v1beta1} + +var _ webhook.Defaulter = &PgBouncerAutoscaler{} + +// Default implements webhook.Defaulter so a webhook will be registered for the type +func (r *PgBouncerAutoscaler) Default() { + pbLog.Info("defaulting", "name", r.Name) + r.setDefaults() +} + +func (r *PgBouncerAutoscaler) setDefaults() { + var db dbapi.PgBouncer + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &db) + if err != nil { + _ = fmt.Errorf("can't get PgBouncer %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return + } + + r.setOpsReqOptsDefaults() + + if r.Spec.Compute != nil { + setDefaultComputeValues(r.Spec.Compute.PgBouncer) + } +} + +func (r *PgBouncerAutoscaler) setOpsReqOptsDefaults() { + if r.Spec.OpsRequestOptions == nil { + r.Spec.OpsRequestOptions = &PgBouncerOpsRequestOptions{} + } + // Timeout is defaulted to 600s in ops-manager retries.go (to retry 120 times with 5sec pause between each) + // OplogMaxLagSeconds & ObjectsCountDiffPercentage are defaults to 0 + if r.Spec.OpsRequestOptions.Apply == "" { + r.Spec.OpsRequestOptions.Apply = opsapi.ApplyOptionIfReady + } +} + +// +kubebuilder:webhook:path=/validate-schema-kubedb-com-v1alpha1-pgbouncerautoscaler,mutating=false,failurePolicy=fail,sideEffects=None,groups=schema.kubedb.com,resources=pgbouncerautoscalers,verbs=create;update;delete,versions=v1alpha1,name=vpgbouncerautoscaler.kb.io,admissionReviewVersions={v1,v1beta1} + +var _ webhook.Validator = &PgBouncerAutoscaler{} + +// ValidateCreate implements webhook.Validator so a webhook will be registered for the type +func (r *PgBouncerAutoscaler) ValidateCreate() (admission.Warnings, error) { + pbLog.Info("validate create", "name", r.Name) + return nil, r.validate() +} + +// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type +func (r *PgBouncerAutoscaler) ValidateUpdate(oldObj runtime.Object) (admission.Warnings, error) { + pbLog.Info("validate update", "name", r.Name) + return nil, r.validate() +} + +func (r *PgBouncerAutoscaler) ValidateDelete() (admission.Warnings, error) { + return nil, nil +} + +func (r *PgBouncerAutoscaler) validate() error { + if r.Spec.DatabaseRef == nil { + return errors.New("databaseRef can't be empty") + } + var bouncer dbapi.PgBouncer + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &bouncer) + if err != nil { + _ = fmt.Errorf("can't get PgBouncer %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return err + } + + return nil +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgpool_types.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgpool_types.go index eebc6670e..32d13a667 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgpool_types.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgpool_types.go @@ -60,7 +60,7 @@ type PgpoolAutoscaler struct { type PgpoolAutoscalerSpec struct { DatabaseRef *core.LocalObjectReference `json:"databaseRef"` - // This field will be used to control the behaviour of ops-manager + // OpsRequestOptions will be used to control the behaviour of ops-manager OpsRequestOptions *PgpoolOpsRequestOptions `json:"opsRequestOptions,omitempty"` Compute *PgpoolComputeAutoscalerSpec `json:"compute,omitempty"` diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgpool_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgpool_webhook.go index 33425ca38..17cadc9f7 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgpool_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/pgpool_webhook.go @@ -81,7 +81,7 @@ func (r *PgpoolAutoscaler) ValidateCreate() (admission.Warnings, error) { // ValidateUpdate implements webhook.Validator so a webhook will be registered for the type func (r *PgpoolAutoscaler) ValidateUpdate(oldObj runtime.Object) (admission.Warnings, error) { - pgpoolLog.Info("validate create", "name", r.Name) + pgpoolLog.Info("validate update", "name", r.Name) return nil, r.validate() } diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/postgres_types.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/postgres_types.go index 6a84fa118..c1dd1bbae 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/postgres_types.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/postgres_types.go @@ -62,7 +62,7 @@ type PostgresAutoscaler struct { type PostgresAutoscalerSpec struct { DatabaseRef *core.LocalObjectReference `json:"databaseRef"` - // This field will be used to control the behaviour of ops-manager + // OpsRequestOptions will be used to control the behaviour of ops-manager OpsRequestOptions *PostgresOpsRequestOptions `json:"opsRequestOptions,omitempty"` Compute *PostgresComputeAutoscalerSpec `json:"compute,omitempty"` diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/postgres_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/postgres_webhook.go index a608b462b..efda7e516 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/postgres_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/postgres_webhook.go @@ -83,7 +83,7 @@ func (in *PostgresAutoscaler) ValidateCreate() (admission.Warnings, error) { // ValidateUpdate implements webhook.Validator so a webhook will be registered for the type func (in *PostgresAutoscaler) ValidateUpdate(old runtime.Object) (admission.Warnings, error) { - pgLog.Info("validate create", "name", in.Name) + pgLog.Info("validate update", "name", in.Name) return nil, in.validate() } diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/proxysql_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/proxysql_webhook.go index cf3d10793..24e8b297e 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/proxysql_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/proxysql_webhook.go @@ -79,7 +79,7 @@ func (in *ProxySQLAutoscaler) ValidateCreate() (admission.Warnings, error) { // ValidateUpdate implements webhook.Validator so a webhook will be registered for the type func (in *ProxySQLAutoscaler) ValidateUpdate(old runtime.Object) (admission.Warnings, error) { - proxyLog.Info("validate create", "name", in.Name) + proxyLog.Info("validate update", "name", in.Name) return nil, in.validate() } diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/rabbitmq_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/rabbitmq_webhook.go index b352ce75d..9f1a41cfa 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/rabbitmq_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/rabbitmq_webhook.go @@ -85,7 +85,7 @@ func (r *RabbitMQAutoscaler) ValidateCreate() (admission.Warnings, error) { // ValidateUpdate implements webhook.Validator so a webhook will be registered for the type func (r *RabbitMQAutoscaler) ValidateUpdate(oldObj runtime.Object) (admission.Warnings, error) { - rabbitLog.Info("validate create", "name", r.Name) + rabbitLog.Info("validate update", "name", r.Name) return nil, r.validate() } diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_sentinel_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_sentinel_webhook.go index c44df8986..90d89d4e4 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_sentinel_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_sentinel_webhook.go @@ -79,7 +79,7 @@ func (in *RedisSentinelAutoscaler) ValidateCreate() (admission.Warnings, error) // ValidateUpdate implements webhook.Validator so a webhook will be registered for the type func (in *RedisSentinelAutoscaler) ValidateUpdate(old runtime.Object) (admission.Warnings, error) { - rsLog.Info("validate create", "name", in.Name) + rsLog.Info("validate update", "name", in.Name) return nil, in.validate() } diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_webhook.go index 4f4315194..e43fbf6b6 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/redis_webhook.go @@ -91,7 +91,7 @@ func (in *RedisAutoscaler) ValidateCreate() (admission.Warnings, error) { // ValidateUpdate implements webhook.Validator so a webhook will be registered for the type func (in *RedisAutoscaler) ValidateUpdate(old runtime.Object) (admission.Warnings, error) { - redisLog.Info("validate create", "name", in.Name) + redisLog.Info("validate update", "name", in.Name) return nil, in.validate() } diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/register.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/register.go index 599546a12..bd4816f6b 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/register.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/register.go @@ -54,12 +54,16 @@ func Resource(resource string) schema.GroupResource { // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, + &ClickHouseAutoscaler{}, + &ClickHouseAutoscalerList{}, &DruidAutoscaler{}, &DruidAutoscalerList{}, &ElasticsearchAutoscaler{}, &ElasticsearchAutoscalerList{}, &EtcdAutoscaler{}, &EtcdAutoscalerList{}, + &FerretDBAutoscaler{}, + &FerretDBAutoscalerList{}, &KafkaAutoscaler{}, &KafkaAutoscalerList{}, &MariaDBAutoscaler{}, @@ -68,10 +72,14 @@ func addKnownTypes(scheme *runtime.Scheme) error { &MemcachedAutoscalerList{}, &MongoDBAutoscaler{}, &MongoDBAutoscalerList{}, + &MSSQLServerAutoscaler{}, + &MSSQLServerAutoscalerList{}, &MySQLAutoscaler{}, &MySQLAutoscalerList{}, &PerconaXtraDBAutoscaler{}, &PerconaXtraDBAutoscalerList{}, + &PgBouncerAutoscaler{}, + &PgBouncerAutoscalerList{}, &PgpoolAutoscaler{}, &PgpoolAutoscalerList{}, &PostgresAutoscaler{}, @@ -86,6 +94,10 @@ func addKnownTypes(scheme *runtime.Scheme) error { &RedisSentinelAutoscalerList{}, &SinglestoreAutoscaler{}, &SinglestoreAutoscalerList{}, + &SolrAutoscaler{}, + &SolrAutoscalerList{}, + &ZooKeeperAutoscaler{}, + &ZooKeeperAutoscalerList{}, ) scheme.AddKnownTypes(SchemeGroupVersion, diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/singlestore_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/singlestore_webhook.go index c8c4c3f48..00e22b87f 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/singlestore_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/singlestore_webhook.go @@ -95,7 +95,7 @@ func (s *SinglestoreAutoscaler) ValidateCreate() (admission.Warnings, error) { // ValidateUpdate implements webhook.Validator so a webhook will be registered for the type func (s *SinglestoreAutoscaler) ValidateUpdate(oldObj runtime.Object) (admission.Warnings, error) { - kafkaLog.Info("validate create", "name", s.Name) + kafkaLog.Info("validate update", "name", s.Name) return nil, s.validate() } diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/solr_helpers.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/solr_helpers.go new file mode 100644 index 000000000..8e396490b --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/solr_helpers.go @@ -0,0 +1,67 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "fmt" + + "kubedb.dev/apimachinery/apis" + "kubedb.dev/apimachinery/apis/autoscaling" + "kubedb.dev/apimachinery/crds" + + "kmodules.xyz/client-go/apiextensions" +) + +func (r SolrAutoscaler) CustomResourceDefinition() *apiextensions.CustomResourceDefinition { + return crds.MustCustomResourceDefinition(SchemeGroupVersion.WithResource(ResourcePluralSolrAutoscaler)) +} + +var _ apis.ResourceInfo = &SolrAutoscaler{} + +func (r SolrAutoscaler) ResourceFQN() string { + return fmt.Sprintf("%s.%s", ResourcePluralSolrAutoscaler, autoscaling.GroupName) +} + +func (r SolrAutoscaler) ResourceShortCode() string { + return ResourceCodeSolrAutoscaler +} + +func (r SolrAutoscaler) ResourceKind() string { + return ResourceKindSolrAutoscaler +} + +func (r SolrAutoscaler) ResourceSingular() string { + return ResourceSingularSolrAutoscaler +} + +func (r SolrAutoscaler) ResourcePlural() string { + return ResourcePluralSolrAutoscaler +} + +func (r SolrAutoscaler) ValidateSpecs() error { + return nil +} + +var _ StatusAccessor = &SolrAutoscaler{} + +func (r *SolrAutoscaler) GetStatus() AutoscalerStatus { + return r.Status +} + +func (r *SolrAutoscaler) SetStatus(s AutoscalerStatus) { + r.Status = s +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/solr_types.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/solr_types.go new file mode 100644 index 000000000..e3f09b2c1 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/solr_types.go @@ -0,0 +1,100 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + + core "k8s.io/api/core/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +const ( + ResourceCodeSolrAutoscaler = "slscaler" + ResourceKindSolrAutoscaler = "SolrAutoscaler" + ResourceSingularSolrAutoscaler = "solrautoscaler" + ResourcePluralSolrAutoscaler = "solrautoscalers" +) + +// SolrAutoscaler is the configuration for a solr database +// autoscaler, which automatically manages pod resources based on historical and +// real time resource utilization. + +// +genclient +// +k8s:openapi-gen=true +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// +kubebuilder:object:root=true +// +kubebuilder:resource:path=solrautoscalers,singular=solrautoscaler,shortName=slscaler,categories={datastore,kubedb,appscode} +// +kubebuilder:subresource:status +type SolrAutoscaler struct { + metav1.TypeMeta `json:",inline"` + // Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta `json:"metadata,omitempty"` + + // Specification of the behavior of the autoscaler. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. + Spec SolrAutoscalerSpec `json:"spec"` + + // Current information about the autoscaler. + // +optional + Status AutoscalerStatus `json:"status,omitempty"` +} + +// SolrAutoscalerSpec is the specification of the behavior of the autoscaler. +type SolrAutoscalerSpec struct { + DatabaseRef *core.LocalObjectReference `json:"databaseRef"` + + // This field will be used to control the behaviour of ops-manager + OpsRequestOptions *SolrOpsRequestOptions `json:"opsRequestOptions,omitempty"` + + Compute *SolrComputeAutoscalerSpec `json:"compute,omitempty"` + Storage *SolrStorageAutoscalerSpec `json:"storage,omitempty"` +} + +type SolrComputeAutoscalerSpec struct { + // +optional + NodeTopology *NodeTopology `json:"nodeTopology,omitempty"` + + Solr *ComputeAutoscalerSpec `json:"solr,omitempty"` +} + +type SolrStorageAutoscalerSpec struct { + Solr *StorageAutoscalerSpec `json:"solr,omitempty"` +} + +type SolrOpsRequestOptions struct { + // Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure. + Timeout *metav1.Duration `json:"timeout,omitempty"` + + // ApplyOption is to control the execution of OpsRequest depending on the database state. + // +kubebuilder:default="IfReady" + Apply opsapi.ApplyOption `json:"apply,omitempty"` +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// SolrAutoscalerList is a list of SolrAutoscaler objects. +type SolrAutoscalerList struct { + metav1.TypeMeta `json:",inline"` + // metadata is the standard list metadata. + // +optional + metav1.ListMeta `json:"metadata"` + + // items is the list of solr database autoscaler objects. + Items []SolrAutoscaler `json:"items"` +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/solr_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/solr_webhook.go new file mode 100644 index 000000000..5a7b46ddb --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/solr_webhook.go @@ -0,0 +1,111 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "context" + "errors" + "fmt" + + olddbapi "kubedb.dev/apimachinery/apis/kubedb/v1alpha2" + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/types" + logf "sigs.k8s.io/controller-runtime/pkg/log" + "sigs.k8s.io/controller-runtime/pkg/webhook" + "sigs.k8s.io/controller-runtime/pkg/webhook/admission" +) + +// log is for logging in this package. +var sllog = logf.Log.WithName("solr-autoscaler") + +var _ webhook.Defaulter = &SolrAutoscaler{} + +// Default implements webhook.CustomDefaulter so a webhook will be registered for the type +func (r *SolrAutoscaler) Default() { + sllog.Info("defaulting", "name", r.Name) + r.setDefaults() +} + +func (r *SolrAutoscaler) setDefaults() { + var db olddbapi.Solr + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &db) + if err != nil { + _ = fmt.Errorf("can't get Solr %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return + } + + r.setOpsReqOptsDefaults() + + if r.Spec.Storage != nil { + setDefaultStorageValues(r.Spec.Storage.Solr) + } + + if r.Spec.Compute != nil { + setDefaultComputeValues(r.Spec.Compute.Solr) + } +} + +func (r *SolrAutoscaler) setOpsReqOptsDefaults() { + if r.Spec.OpsRequestOptions == nil { + r.Spec.OpsRequestOptions = &SolrOpsRequestOptions{} + } + // Timeout is defaulted to 600s in ops-manager retries.go (to retry 120 times with 5sec pause between each) + // OplogMaxLagSeconds & ObjectsCountDiffPercentage are defaults to 0 + if r.Spec.OpsRequestOptions.Apply == "" { + r.Spec.OpsRequestOptions.Apply = opsapi.ApplyOptionIfReady + } +} + +var _ webhook.Validator = &SolrAutoscaler{} + +// ValidateCreate implements webhook.Validator so a webhook will be registered for the type +func (r *SolrAutoscaler) ValidateCreate() (admission.Warnings, error) { + sllog.Info("validate create", "name", r.Name) + return nil, r.validate() +} + +// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type +func (r *SolrAutoscaler) ValidateUpdate(oldObj runtime.Object) (admission.Warnings, error) { + sllog.Info("validate update", "name", r.Name) + return nil, r.validate() +} + +func (r *SolrAutoscaler) ValidateDelete() (admission.Warnings, error) { + return nil, nil +} + +func (r *SolrAutoscaler) validate() error { + if r.Spec.DatabaseRef == nil { + return errors.New("databaseRef can't be empty") + } + var kf olddbapi.Solr + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &kf) + if err != nil { + _ = fmt.Errorf("can't get Solr %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return err + } + + return nil +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zookeeper_helpers.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zookeeper_helpers.go new file mode 100644 index 000000000..a4c574500 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zookeeper_helpers.go @@ -0,0 +1,67 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "fmt" + + "kubedb.dev/apimachinery/apis" + "kubedb.dev/apimachinery/apis/autoscaling" + "kubedb.dev/apimachinery/crds" + + "kmodules.xyz/client-go/apiextensions" +) + +func (r ZooKeeperAutoscaler) CustomResourceDefinition() *apiextensions.CustomResourceDefinition { + return crds.MustCustomResourceDefinition(SchemeGroupVersion.WithResource(ResourcePluralZooKeeperAutoscaler)) +} + +var _ apis.ResourceInfo = &ZooKeeperAutoscaler{} + +func (r ZooKeeperAutoscaler) ResourceFQN() string { + return fmt.Sprintf("%s.%s", ResourcePluralZooKeeperAutoscaler, autoscaling.GroupName) +} + +func (r ZooKeeperAutoscaler) ResourceShortCode() string { + return ResourceCodeZooKeeperAutoscaler +} + +func (r ZooKeeperAutoscaler) ResourceKind() string { + return ResourceKindZooKeeperAutoscaler +} + +func (r ZooKeeperAutoscaler) ResourceSingular() string { + return ResourceSingularZooKeeperAutoscaler +} + +func (r ZooKeeperAutoscaler) ResourcePlural() string { + return ResourcePluralZooKeeperAutoscaler +} + +func (r ZooKeeperAutoscaler) ValidateSpecs() error { + return nil +} + +var _ StatusAccessor = &ZooKeeperAutoscaler{} + +func (r *ZooKeeperAutoscaler) GetStatus() AutoscalerStatus { + return r.Status +} + +func (r *ZooKeeperAutoscaler) SetStatus(s AutoscalerStatus) { + r.Status = s +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zookeeper_types.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zookeeper_types.go new file mode 100644 index 000000000..4c9aa5e72 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zookeeper_types.go @@ -0,0 +1,100 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + + core "k8s.io/api/core/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +const ( + ResourceCodeZooKeeperAutoscaler = "zkscaler" + ResourceKindZooKeeperAutoscaler = "ZooKeeperAutoscaler" + ResourceSingularZooKeeperAutoscaler = "zookeeperautoscaler" + ResourcePluralZooKeeperAutoscaler = "zookeeperautoscalers" +) + +// ZooKeeperAutoscaler is the configuration for a zookeeper database +// autoscaler, which automatically manages pod resources based on historical and +// real time resource utilization. + +// +genclient +// +k8s:openapi-gen=true +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// +kubebuilder:object:root=true +// +kubebuilder:resource:path=zookeeperautoscalers,singular=zookeeperautoscaler,shortName=zkscaler,categories={datastore,kubedb,appscode} +// +kubebuilder:subresource:status +type ZooKeeperAutoscaler struct { + metav1.TypeMeta `json:",inline"` + // Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta `json:"metadata,omitempty"` + + // Specification of the behavior of the autoscaler. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. + Spec ZooKeeperAutoscalerSpec `json:"spec"` + + // Current information about the autoscaler. + // +optional + Status AutoscalerStatus `json:"status,omitempty"` +} + +// ZooKeeperAutoscalerSpec is the specification of the behavior of the autoscaler. +type ZooKeeperAutoscalerSpec struct { + DatabaseRef *core.LocalObjectReference `json:"databaseRef"` + + // This field will be used to control the behaviour of ops-manager + OpsRequestOptions *ZooKeeperOpsRequestOptions `json:"opsRequestOptions,omitempty"` + + Compute *ZooKeeperComputeAutoscalerSpec `json:"compute,omitempty"` + Storage *ZooKeeperStorageAutoscalerSpec `json:"storage,omitempty"` +} + +type ZooKeeperComputeAutoscalerSpec struct { + // +optional + NodeTopology *NodeTopology `json:"nodeTopology,omitempty"` + + ZooKeeper *ComputeAutoscalerSpec `json:"zookeeper,omitempty"` +} + +type ZooKeeperStorageAutoscalerSpec struct { + ZooKeeper *StorageAutoscalerSpec `json:"zookeeper,omitempty"` +} + +type ZooKeeperOpsRequestOptions struct { + // Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure. + Timeout *metav1.Duration `json:"timeout,omitempty"` + + // ApplyOption is to control the execution of OpsRequest depending on the database state. + // +kubebuilder:default="IfReady" + Apply opsapi.ApplyOption `json:"apply,omitempty"` +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +// ZooKeeperAutoscalerList is a list of ZooKeeperAutoscaler objects. +type ZooKeeperAutoscalerList struct { + metav1.TypeMeta `json:",inline"` + // metadata is the standard list metadata. + // +optional + metav1.ListMeta `json:"metadata"` + + // items is the list of zookeeper database autoscaler objects. + Items []ZooKeeperAutoscaler `json:"items"` +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zookeeper_webhook.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zookeeper_webhook.go new file mode 100644 index 000000000..e94734834 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zookeeper_webhook.go @@ -0,0 +1,111 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "context" + "errors" + "fmt" + + olddbapi "kubedb.dev/apimachinery/apis/kubedb/v1alpha2" + opsapi "kubedb.dev/apimachinery/apis/ops/v1alpha1" + + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/types" + logf "sigs.k8s.io/controller-runtime/pkg/log" + "sigs.k8s.io/controller-runtime/pkg/webhook" + "sigs.k8s.io/controller-runtime/pkg/webhook/admission" +) + +// log is for logging in this package. +var zkLog = logf.Log.WithName("zookeeper-autoscaler") + +var _ webhook.Defaulter = &ZooKeeperAutoscaler{} + +// Default implements webhook.CustomDefaulter so a webhook will be registered for the type +func (r *ZooKeeperAutoscaler) Default() { + zkLog.Info("defaulting", "name", r.Name) + r.setDefaults() +} + +func (r *ZooKeeperAutoscaler) setDefaults() { + var db olddbapi.ZooKeeper + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &db) + if err != nil { + _ = fmt.Errorf("can't get ZooKeeper %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return + } + + r.setOpsReqOptsDefaults() + + if r.Spec.Storage != nil { + setDefaultStorageValues(r.Spec.Storage.ZooKeeper) + } + + if r.Spec.Compute != nil { + setDefaultComputeValues(r.Spec.Compute.ZooKeeper) + } +} + +func (r *ZooKeeperAutoscaler) setOpsReqOptsDefaults() { + if r.Spec.OpsRequestOptions == nil { + r.Spec.OpsRequestOptions = &ZooKeeperOpsRequestOptions{} + } + // Timeout is defaulted to 600s in ops-manager retries.go (to retry 120 times with 5sec pause between each) + // OplogMaxLagSeconds & ObjectsCountDiffPercentage are defaults to 0 + if r.Spec.OpsRequestOptions.Apply == "" { + r.Spec.OpsRequestOptions.Apply = opsapi.ApplyOptionIfReady + } +} + +var _ webhook.Validator = &ZooKeeperAutoscaler{} + +// ValidateCreate implements webhook.Validator so a webhook will be registered for the type +func (r *ZooKeeperAutoscaler) ValidateCreate() (admission.Warnings, error) { + zkLog.Info("validate create", "name", r.Name) + return nil, r.validate() +} + +// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type +func (r *ZooKeeperAutoscaler) ValidateUpdate(oldObj runtime.Object) (admission.Warnings, error) { + zkLog.Info("validate update", "name", r.Name) + return nil, r.validate() +} + +func (r *ZooKeeperAutoscaler) ValidateDelete() (admission.Warnings, error) { + return nil, nil +} + +func (r *ZooKeeperAutoscaler) validate() error { + if r.Spec.DatabaseRef == nil { + return errors.New("databaseRef can't be empty") + } + var kf olddbapi.ZooKeeper + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: r.Spec.DatabaseRef.Name, + Namespace: r.Namespace, + }, &kf) + if err != nil { + _ = fmt.Errorf("can't get ZooKeeper %s/%s \n", r.Namespace, r.Spec.DatabaseRef.Name) + return err + } + + return nil +} diff --git a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zz_generated.deepcopy.go b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zz_generated.deepcopy.go index 7b82e0df5..8748406c4 100644 --- a/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zz_generated.deepcopy.go +++ b/vendor/kubedb.dev/apimachinery/apis/autoscaling/v1alpha1/zz_generated.deepcopy.go @@ -122,6 +122,171 @@ func (in *CheckpointReference) DeepCopy() *CheckpointReference { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClickHouseAutoscaler) DeepCopyInto(out *ClickHouseAutoscaler) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClickHouseAutoscaler. +func (in *ClickHouseAutoscaler) DeepCopy() *ClickHouseAutoscaler { + if in == nil { + return nil + } + out := new(ClickHouseAutoscaler) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *ClickHouseAutoscaler) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClickHouseAutoscalerList) DeepCopyInto(out *ClickHouseAutoscalerList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ClickHouseAutoscaler, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClickHouseAutoscalerList. +func (in *ClickHouseAutoscalerList) DeepCopy() *ClickHouseAutoscalerList { + if in == nil { + return nil + } + out := new(ClickHouseAutoscalerList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *ClickHouseAutoscalerList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClickHouseAutoscalerSpec) DeepCopyInto(out *ClickHouseAutoscalerSpec) { + *out = *in + if in.DatabaseRef != nil { + in, out := &in.DatabaseRef, &out.DatabaseRef + *out = new(corev1.LocalObjectReference) + **out = **in + } + if in.OpsRequestOptions != nil { + in, out := &in.OpsRequestOptions, &out.OpsRequestOptions + *out = new(ClickHouseOpsRequestOptions) + (*in).DeepCopyInto(*out) + } + if in.Compute != nil { + in, out := &in.Compute, &out.Compute + *out = new(ClickHouseComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Storage != nil { + in, out := &in.Storage, &out.Storage + *out = new(ClickHouseStorageAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClickHouseAutoscalerSpec. +func (in *ClickHouseAutoscalerSpec) DeepCopy() *ClickHouseAutoscalerSpec { + if in == nil { + return nil + } + out := new(ClickHouseAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClickHouseComputeAutoscalerSpec) DeepCopyInto(out *ClickHouseComputeAutoscalerSpec) { + *out = *in + if in.NodeTopology != nil { + in, out := &in.NodeTopology, &out.NodeTopology + *out = new(NodeTopology) + (*in).DeepCopyInto(*out) + } + if in.ClickHouse != nil { + in, out := &in.ClickHouse, &out.ClickHouse + *out = new(ComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClickHouseComputeAutoscalerSpec. +func (in *ClickHouseComputeAutoscalerSpec) DeepCopy() *ClickHouseComputeAutoscalerSpec { + if in == nil { + return nil + } + out := new(ClickHouseComputeAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClickHouseOpsRequestOptions) DeepCopyInto(out *ClickHouseOpsRequestOptions) { + *out = *in + if in.Timeout != nil { + in, out := &in.Timeout, &out.Timeout + *out = new(metav1.Duration) + **out = **in + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClickHouseOpsRequestOptions. +func (in *ClickHouseOpsRequestOptions) DeepCopy() *ClickHouseOpsRequestOptions { + if in == nil { + return nil + } + out := new(ClickHouseOpsRequestOptions) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ClickHouseStorageAutoscalerSpec) DeepCopyInto(out *ClickHouseStorageAutoscalerSpec) { + *out = *in + if in.ClickHouse != nil { + in, out := &in.ClickHouse, &out.ClickHouse + *out = new(StorageAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ClickHouseStorageAutoscalerSpec. +func (in *ClickHouseStorageAutoscalerSpec) DeepCopy() *ClickHouseStorageAutoscalerSpec { + if in == nil { + return nil + } + out := new(ClickHouseStorageAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ComputeAutoscalerSpec) DeepCopyInto(out *ComputeAutoscalerSpec) { *out = *in @@ -849,29 +1014,7 @@ func (in *EtcdScalingRules) DeepCopy() *EtcdScalingRules { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *HistogramCheckpoint) DeepCopyInto(out *HistogramCheckpoint) { - *out = *in - in.ReferenceTimestamp.DeepCopyInto(&out.ReferenceTimestamp) - if in.BucketWeights != nil { - in, out := &in.BucketWeights, &out.BucketWeights - *out = make([]BucketWeight, len(*in)) - copy(*out, *in) - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HistogramCheckpoint. -func (in *HistogramCheckpoint) DeepCopy() *HistogramCheckpoint { - if in == nil { - return nil - } - out := new(HistogramCheckpoint) - in.DeepCopyInto(out) - return out -} - -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *KafkaAutoscaler) DeepCopyInto(out *KafkaAutoscaler) { +func (in *FerretDBAutoscaler) DeepCopyInto(out *FerretDBAutoscaler) { *out = *in out.TypeMeta = in.TypeMeta in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) @@ -880,18 +1023,18 @@ func (in *KafkaAutoscaler) DeepCopyInto(out *KafkaAutoscaler) { return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KafkaAutoscaler. -func (in *KafkaAutoscaler) DeepCopy() *KafkaAutoscaler { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FerretDBAutoscaler. +func (in *FerretDBAutoscaler) DeepCopy() *FerretDBAutoscaler { if in == nil { return nil } - out := new(KafkaAutoscaler) + out := new(FerretDBAutoscaler) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *KafkaAutoscaler) DeepCopyObject() runtime.Object { +func (in *FerretDBAutoscaler) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } @@ -899,13 +1042,13 @@ func (in *KafkaAutoscaler) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *KafkaAutoscalerList) DeepCopyInto(out *KafkaAutoscalerList) { +func (in *FerretDBAutoscalerList) DeepCopyInto(out *FerretDBAutoscalerList) { *out = *in out.TypeMeta = in.TypeMeta in.ListMeta.DeepCopyInto(&out.ListMeta) if in.Items != nil { in, out := &in.Items, &out.Items - *out = make([]KafkaAutoscaler, len(*in)) + *out = make([]FerretDBAutoscaler, len(*in)) for i := range *in { (*in)[i].DeepCopyInto(&(*out)[i]) } @@ -913,18 +1056,18 @@ func (in *KafkaAutoscalerList) DeepCopyInto(out *KafkaAutoscalerList) { return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KafkaAutoscalerList. -func (in *KafkaAutoscalerList) DeepCopy() *KafkaAutoscalerList { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FerretDBAutoscalerList. +func (in *FerretDBAutoscalerList) DeepCopy() *FerretDBAutoscalerList { if in == nil { return nil } - out := new(KafkaAutoscalerList) + out := new(FerretDBAutoscalerList) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *KafkaAutoscalerList) DeepCopyObject() runtime.Object { +func (in *FerretDBAutoscalerList) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } @@ -932,7 +1075,7 @@ func (in *KafkaAutoscalerList) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *KafkaAutoscalerSpec) DeepCopyInto(out *KafkaAutoscalerSpec) { +func (in *FerretDBAutoscalerSpec) DeepCopyInto(out *FerretDBAutoscalerSpec) { *out = *in if in.DatabaseRef != nil { in, out := &in.DatabaseRef, &out.DatabaseRef @@ -941,70 +1084,60 @@ func (in *KafkaAutoscalerSpec) DeepCopyInto(out *KafkaAutoscalerSpec) { } if in.OpsRequestOptions != nil { in, out := &in.OpsRequestOptions, &out.OpsRequestOptions - *out = new(KafkaOpsRequestOptions) + *out = new(FerretDBOpsRequestOptions) (*in).DeepCopyInto(*out) } if in.Compute != nil { in, out := &in.Compute, &out.Compute - *out = new(KafkaComputeAutoscalerSpec) + *out = new(FerretDBComputeAutoscalerSpec) (*in).DeepCopyInto(*out) } if in.Storage != nil { in, out := &in.Storage, &out.Storage - *out = new(KafkaStorageAutoscalerSpec) + *out = new(FerretDBStorageAutoscalerSpec) (*in).DeepCopyInto(*out) } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KafkaAutoscalerSpec. -func (in *KafkaAutoscalerSpec) DeepCopy() *KafkaAutoscalerSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FerretDBAutoscalerSpec. +func (in *FerretDBAutoscalerSpec) DeepCopy() *FerretDBAutoscalerSpec { if in == nil { return nil } - out := new(KafkaAutoscalerSpec) + out := new(FerretDBAutoscalerSpec) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *KafkaComputeAutoscalerSpec) DeepCopyInto(out *KafkaComputeAutoscalerSpec) { +func (in *FerretDBComputeAutoscalerSpec) DeepCopyInto(out *FerretDBComputeAutoscalerSpec) { *out = *in if in.NodeTopology != nil { in, out := &in.NodeTopology, &out.NodeTopology *out = new(NodeTopology) (*in).DeepCopyInto(*out) } - if in.Node != nil { - in, out := &in.Node, &out.Node - *out = new(ComputeAutoscalerSpec) - (*in).DeepCopyInto(*out) - } - if in.Broker != nil { - in, out := &in.Broker, &out.Broker - *out = new(ComputeAutoscalerSpec) - (*in).DeepCopyInto(*out) - } - if in.Controller != nil { - in, out := &in.Controller, &out.Controller + if in.FerretDB != nil { + in, out := &in.FerretDB, &out.FerretDB *out = new(ComputeAutoscalerSpec) (*in).DeepCopyInto(*out) } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KafkaComputeAutoscalerSpec. -func (in *KafkaComputeAutoscalerSpec) DeepCopy() *KafkaComputeAutoscalerSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FerretDBComputeAutoscalerSpec. +func (in *FerretDBComputeAutoscalerSpec) DeepCopy() *FerretDBComputeAutoscalerSpec { if in == nil { return nil } - out := new(KafkaComputeAutoscalerSpec) + out := new(FerretDBComputeAutoscalerSpec) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *KafkaOpsRequestOptions) DeepCopyInto(out *KafkaOpsRequestOptions) { +func (in *FerretDBOpsRequestOptions) DeepCopyInto(out *FerretDBOpsRequestOptions) { *out = *in if in.Timeout != nil { in, out := &in.Timeout, &out.Timeout @@ -1014,49 +1147,61 @@ func (in *KafkaOpsRequestOptions) DeepCopyInto(out *KafkaOpsRequestOptions) { return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KafkaOpsRequestOptions. -func (in *KafkaOpsRequestOptions) DeepCopy() *KafkaOpsRequestOptions { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FerretDBOpsRequestOptions. +func (in *FerretDBOpsRequestOptions) DeepCopy() *FerretDBOpsRequestOptions { if in == nil { return nil } - out := new(KafkaOpsRequestOptions) + out := new(FerretDBOpsRequestOptions) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *KafkaStorageAutoscalerSpec) DeepCopyInto(out *KafkaStorageAutoscalerSpec) { +func (in *FerretDBStorageAutoscalerSpec) DeepCopyInto(out *FerretDBStorageAutoscalerSpec) { *out = *in - if in.Node != nil { - in, out := &in.Node, &out.Node + if in.FerretDB != nil { + in, out := &in.FerretDB, &out.FerretDB *out = new(StorageAutoscalerSpec) (*in).DeepCopyInto(*out) } - if in.Broker != nil { - in, out := &in.Broker, &out.Broker - *out = new(StorageAutoscalerSpec) - (*in).DeepCopyInto(*out) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FerretDBStorageAutoscalerSpec. +func (in *FerretDBStorageAutoscalerSpec) DeepCopy() *FerretDBStorageAutoscalerSpec { + if in == nil { + return nil } - if in.Controller != nil { - in, out := &in.Controller, &out.Controller - *out = new(StorageAutoscalerSpec) - (*in).DeepCopyInto(*out) + out := new(FerretDBStorageAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *HistogramCheckpoint) DeepCopyInto(out *HistogramCheckpoint) { + *out = *in + in.ReferenceTimestamp.DeepCopyInto(&out.ReferenceTimestamp) + if in.BucketWeights != nil { + in, out := &in.BucketWeights, &out.BucketWeights + *out = make([]BucketWeight, len(*in)) + copy(*out, *in) } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KafkaStorageAutoscalerSpec. -func (in *KafkaStorageAutoscalerSpec) DeepCopy() *KafkaStorageAutoscalerSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HistogramCheckpoint. +func (in *HistogramCheckpoint) DeepCopy() *HistogramCheckpoint { if in == nil { return nil } - out := new(KafkaStorageAutoscalerSpec) + out := new(HistogramCheckpoint) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *MariaDBAutoscaler) DeepCopyInto(out *MariaDBAutoscaler) { +func (in *KafkaAutoscaler) DeepCopyInto(out *KafkaAutoscaler) { *out = *in out.TypeMeta = in.TypeMeta in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) @@ -1065,18 +1210,18 @@ func (in *MariaDBAutoscaler) DeepCopyInto(out *MariaDBAutoscaler) { return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MariaDBAutoscaler. -func (in *MariaDBAutoscaler) DeepCopy() *MariaDBAutoscaler { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KafkaAutoscaler. +func (in *KafkaAutoscaler) DeepCopy() *KafkaAutoscaler { if in == nil { return nil } - out := new(MariaDBAutoscaler) + out := new(KafkaAutoscaler) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *MariaDBAutoscaler) DeepCopyObject() runtime.Object { +func (in *KafkaAutoscaler) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } @@ -1084,13 +1229,13 @@ func (in *MariaDBAutoscaler) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *MariaDBAutoscalerList) DeepCopyInto(out *MariaDBAutoscalerList) { +func (in *KafkaAutoscalerList) DeepCopyInto(out *KafkaAutoscalerList) { *out = *in out.TypeMeta = in.TypeMeta in.ListMeta.DeepCopyInto(&out.ListMeta) if in.Items != nil { in, out := &in.Items, &out.Items - *out = make([]MariaDBAutoscaler, len(*in)) + *out = make([]KafkaAutoscaler, len(*in)) for i := range *in { (*in)[i].DeepCopyInto(&(*out)[i]) } @@ -1098,18 +1243,18 @@ func (in *MariaDBAutoscalerList) DeepCopyInto(out *MariaDBAutoscalerList) { return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MariaDBAutoscalerList. -func (in *MariaDBAutoscalerList) DeepCopy() *MariaDBAutoscalerList { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KafkaAutoscalerList. +func (in *KafkaAutoscalerList) DeepCopy() *KafkaAutoscalerList { if in == nil { return nil } - out := new(MariaDBAutoscalerList) + out := new(KafkaAutoscalerList) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *MariaDBAutoscalerList) DeepCopyObject() runtime.Object { +func (in *KafkaAutoscalerList) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } @@ -1117,7 +1262,7 @@ func (in *MariaDBAutoscalerList) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *MariaDBAutoscalerSpec) DeepCopyInto(out *MariaDBAutoscalerSpec) { +func (in *KafkaAutoscalerSpec) DeepCopyInto(out *KafkaAutoscalerSpec) { *out = *in if in.DatabaseRef != nil { in, out := &in.DatabaseRef, &out.DatabaseRef @@ -1126,23 +1271,373 @@ func (in *MariaDBAutoscalerSpec) DeepCopyInto(out *MariaDBAutoscalerSpec) { } if in.OpsRequestOptions != nil { in, out := &in.OpsRequestOptions, &out.OpsRequestOptions - *out = new(MariaDBOpsRequestOptions) + *out = new(KafkaOpsRequestOptions) (*in).DeepCopyInto(*out) } if in.Compute != nil { in, out := &in.Compute, &out.Compute - *out = new(MariaDBComputeAutoscalerSpec) + *out = new(KafkaComputeAutoscalerSpec) (*in).DeepCopyInto(*out) } if in.Storage != nil { in, out := &in.Storage, &out.Storage - *out = new(MariaDBStorageAutoscalerSpec) + *out = new(KafkaStorageAutoscalerSpec) (*in).DeepCopyInto(*out) } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MariaDBAutoscalerSpec. +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KafkaAutoscalerSpec. +func (in *KafkaAutoscalerSpec) DeepCopy() *KafkaAutoscalerSpec { + if in == nil { + return nil + } + out := new(KafkaAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *KafkaComputeAutoscalerSpec) DeepCopyInto(out *KafkaComputeAutoscalerSpec) { + *out = *in + if in.NodeTopology != nil { + in, out := &in.NodeTopology, &out.NodeTopology + *out = new(NodeTopology) + (*in).DeepCopyInto(*out) + } + if in.Node != nil { + in, out := &in.Node, &out.Node + *out = new(ComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Broker != nil { + in, out := &in.Broker, &out.Broker + *out = new(ComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Controller != nil { + in, out := &in.Controller, &out.Controller + *out = new(ComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KafkaComputeAutoscalerSpec. +func (in *KafkaComputeAutoscalerSpec) DeepCopy() *KafkaComputeAutoscalerSpec { + if in == nil { + return nil + } + out := new(KafkaComputeAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *KafkaOpsRequestOptions) DeepCopyInto(out *KafkaOpsRequestOptions) { + *out = *in + if in.Timeout != nil { + in, out := &in.Timeout, &out.Timeout + *out = new(metav1.Duration) + **out = **in + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KafkaOpsRequestOptions. +func (in *KafkaOpsRequestOptions) DeepCopy() *KafkaOpsRequestOptions { + if in == nil { + return nil + } + out := new(KafkaOpsRequestOptions) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *KafkaStorageAutoscalerSpec) DeepCopyInto(out *KafkaStorageAutoscalerSpec) { + *out = *in + if in.Node != nil { + in, out := &in.Node, &out.Node + *out = new(StorageAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Broker != nil { + in, out := &in.Broker, &out.Broker + *out = new(StorageAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Controller != nil { + in, out := &in.Controller, &out.Controller + *out = new(StorageAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KafkaStorageAutoscalerSpec. +func (in *KafkaStorageAutoscalerSpec) DeepCopy() *KafkaStorageAutoscalerSpec { + if in == nil { + return nil + } + out := new(KafkaStorageAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MSSQLServerAutoscaler) DeepCopyInto(out *MSSQLServerAutoscaler) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MSSQLServerAutoscaler. +func (in *MSSQLServerAutoscaler) DeepCopy() *MSSQLServerAutoscaler { + if in == nil { + return nil + } + out := new(MSSQLServerAutoscaler) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *MSSQLServerAutoscaler) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MSSQLServerAutoscalerList) DeepCopyInto(out *MSSQLServerAutoscalerList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]MSSQLServerAutoscaler, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MSSQLServerAutoscalerList. +func (in *MSSQLServerAutoscalerList) DeepCopy() *MSSQLServerAutoscalerList { + if in == nil { + return nil + } + out := new(MSSQLServerAutoscalerList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *MSSQLServerAutoscalerList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MSSQLServerAutoscalerSpec) DeepCopyInto(out *MSSQLServerAutoscalerSpec) { + *out = *in + if in.DatabaseRef != nil { + in, out := &in.DatabaseRef, &out.DatabaseRef + *out = new(corev1.LocalObjectReference) + **out = **in + } + if in.OpsRequestOptions != nil { + in, out := &in.OpsRequestOptions, &out.OpsRequestOptions + *out = new(MSSQLServerOpsRequestOptions) + (*in).DeepCopyInto(*out) + } + if in.Compute != nil { + in, out := &in.Compute, &out.Compute + *out = new(MSSQLServerComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Storage != nil { + in, out := &in.Storage, &out.Storage + *out = new(MSSQLServerStorageAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MSSQLServerAutoscalerSpec. +func (in *MSSQLServerAutoscalerSpec) DeepCopy() *MSSQLServerAutoscalerSpec { + if in == nil { + return nil + } + out := new(MSSQLServerAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MSSQLServerComputeAutoscalerSpec) DeepCopyInto(out *MSSQLServerComputeAutoscalerSpec) { + *out = *in + if in.NodeTopology != nil { + in, out := &in.NodeTopology, &out.NodeTopology + *out = new(NodeTopology) + (*in).DeepCopyInto(*out) + } + if in.MSSQLServer != nil { + in, out := &in.MSSQLServer, &out.MSSQLServer + *out = new(ComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MSSQLServerComputeAutoscalerSpec. +func (in *MSSQLServerComputeAutoscalerSpec) DeepCopy() *MSSQLServerComputeAutoscalerSpec { + if in == nil { + return nil + } + out := new(MSSQLServerComputeAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MSSQLServerOpsRequestOptions) DeepCopyInto(out *MSSQLServerOpsRequestOptions) { + *out = *in + if in.Timeout != nil { + in, out := &in.Timeout, &out.Timeout + *out = new(metav1.Duration) + **out = **in + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MSSQLServerOpsRequestOptions. +func (in *MSSQLServerOpsRequestOptions) DeepCopy() *MSSQLServerOpsRequestOptions { + if in == nil { + return nil + } + out := new(MSSQLServerOpsRequestOptions) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MSSQLServerStorageAutoscalerSpec) DeepCopyInto(out *MSSQLServerStorageAutoscalerSpec) { + *out = *in + if in.MSSQLServer != nil { + in, out := &in.MSSQLServer, &out.MSSQLServer + *out = new(StorageAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MSSQLServerStorageAutoscalerSpec. +func (in *MSSQLServerStorageAutoscalerSpec) DeepCopy() *MSSQLServerStorageAutoscalerSpec { + if in == nil { + return nil + } + out := new(MSSQLServerStorageAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MariaDBAutoscaler) DeepCopyInto(out *MariaDBAutoscaler) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MariaDBAutoscaler. +func (in *MariaDBAutoscaler) DeepCopy() *MariaDBAutoscaler { + if in == nil { + return nil + } + out := new(MariaDBAutoscaler) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *MariaDBAutoscaler) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MariaDBAutoscalerList) DeepCopyInto(out *MariaDBAutoscalerList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]MariaDBAutoscaler, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MariaDBAutoscalerList. +func (in *MariaDBAutoscalerList) DeepCopy() *MariaDBAutoscalerList { + if in == nil { + return nil + } + out := new(MariaDBAutoscalerList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *MariaDBAutoscalerList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MariaDBAutoscalerSpec) DeepCopyInto(out *MariaDBAutoscalerSpec) { + *out = *in + if in.DatabaseRef != nil { + in, out := &in.DatabaseRef, &out.DatabaseRef + *out = new(corev1.LocalObjectReference) + **out = **in + } + if in.OpsRequestOptions != nil { + in, out := &in.OpsRequestOptions, &out.OpsRequestOptions + *out = new(MariaDBOpsRequestOptions) + (*in).DeepCopyInto(*out) + } + if in.Compute != nil { + in, out := &in.Compute, &out.Compute + *out = new(MariaDBComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Storage != nil { + in, out := &in.Storage, &out.Storage + *out = new(MariaDBStorageAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MariaDBAutoscalerSpec. func (in *MariaDBAutoscalerSpec) DeepCopy() *MariaDBAutoscalerSpec { if in == nil { return nil @@ -1253,32 +1748,6 @@ func (in *MemcachedAutoscaler) DeepCopyObject() runtime.Object { return nil } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *MemcachedAutoscalerBehavior) DeepCopyInto(out *MemcachedAutoscalerBehavior) { - *out = *in - if in.ScaleUp != nil { - in, out := &in.ScaleUp, &out.ScaleUp - *out = new(MemcachedScalingRules) - (*in).DeepCopyInto(*out) - } - if in.ScaleDown != nil { - in, out := &in.ScaleDown, &out.ScaleDown - *out = new(MemcachedScalingRules) - (*in).DeepCopyInto(*out) - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MemcachedAutoscalerBehavior. -func (in *MemcachedAutoscalerBehavior) DeepCopy() *MemcachedAutoscalerBehavior { - if in == nil { - return nil - } - out := new(MemcachedAutoscalerBehavior) - in.DeepCopyInto(out) - return out -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *MemcachedAutoscalerList) DeepCopyInto(out *MemcachedAutoscalerList) { *out = *in @@ -1315,22 +1784,24 @@ func (in *MemcachedAutoscalerList) DeepCopyObject() runtime.Object { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *MemcachedAutoscalerSpec) DeepCopyInto(out *MemcachedAutoscalerSpec) { *out = *in - out.ScaleTargetRef = in.ScaleTargetRef - if in.MinReplicas != nil { - in, out := &in.MinReplicas, &out.MinReplicas - *out = new(int32) + if in.DatabaseRef != nil { + in, out := &in.DatabaseRef, &out.DatabaseRef + *out = new(corev1.LocalObjectReference) **out = **in } - if in.Metrics != nil { - in, out := &in.Metrics, &out.Metrics - *out = make([]v2beta2.MetricSpec, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } + if in.OpsRequestOptions != nil { + in, out := &in.OpsRequestOptions, &out.OpsRequestOptions + *out = new(MemcachedOpsRequestOptions) + (*in).DeepCopyInto(*out) } - if in.Behavior != nil { - in, out := &in.Behavior, &out.Behavior - *out = new(MemcachedAutoscalerBehavior) + if in.Compute != nil { + in, out := &in.Compute, &out.Compute + *out = new(MemcachedComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Storage != nil { + in, out := &in.Storage, &out.Storage + *out = new(MemcachedStorageAutoscalerSpec) (*in).DeepCopyInto(*out) } return @@ -1347,48 +1818,74 @@ func (in *MemcachedAutoscalerSpec) DeepCopy() *MemcachedAutoscalerSpec { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *MemcachedScalingPolicy) DeepCopyInto(out *MemcachedScalingPolicy) { +func (in *MemcachedComputeAutoscalerSpec) DeepCopyInto(out *MemcachedComputeAutoscalerSpec) { *out = *in + if in.NodeTopology != nil { + in, out := &in.NodeTopology, &out.NodeTopology + *out = new(NodeTopology) + (*in).DeepCopyInto(*out) + } + if in.Memcached != nil { + in, out := &in.Memcached, &out.Memcached + *out = new(ComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MemcachedScalingPolicy. -func (in *MemcachedScalingPolicy) DeepCopy() *MemcachedScalingPolicy { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MemcachedComputeAutoscalerSpec. +func (in *MemcachedComputeAutoscalerSpec) DeepCopy() *MemcachedComputeAutoscalerSpec { if in == nil { return nil } - out := new(MemcachedScalingPolicy) + out := new(MemcachedComputeAutoscalerSpec) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *MemcachedScalingRules) DeepCopyInto(out *MemcachedScalingRules) { +func (in *MemcachedOpsRequestOptions) DeepCopyInto(out *MemcachedOpsRequestOptions) { *out = *in - if in.StabilizationWindowSeconds != nil { - in, out := &in.StabilizationWindowSeconds, &out.StabilizationWindowSeconds - *out = new(int32) + if in.ReadinessCriteria != nil { + in, out := &in.ReadinessCriteria, &out.ReadinessCriteria + *out = new(opsv1alpha1.MemcachedReplicaReadinessCriteria) **out = **in } - if in.SelectPolicy != nil { - in, out := &in.SelectPolicy, &out.SelectPolicy - *out = new(v2beta2.ScalingPolicySelect) + if in.Timeout != nil { + in, out := &in.Timeout, &out.Timeout + *out = new(metav1.Duration) **out = **in } - if in.Policies != nil { - in, out := &in.Policies, &out.Policies - *out = make([]MemcachedScalingPolicy, len(*in)) - copy(*out, *in) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MemcachedOpsRequestOptions. +func (in *MemcachedOpsRequestOptions) DeepCopy() *MemcachedOpsRequestOptions { + if in == nil { + return nil + } + out := new(MemcachedOpsRequestOptions) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MemcachedStorageAutoscalerSpec) DeepCopyInto(out *MemcachedStorageAutoscalerSpec) { + *out = *in + if in.Memcached != nil { + in, out := &in.Memcached, &out.Memcached + *out = new(StorageAutoscalerSpec) + (*in).DeepCopyInto(*out) } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MemcachedScalingRules. -func (in *MemcachedScalingRules) DeepCopy() *MemcachedScalingRules { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MemcachedStorageAutoscalerSpec. +func (in *MemcachedStorageAutoscalerSpec) DeepCopy() *MemcachedStorageAutoscalerSpec { if in == nil { return nil } - out := new(MemcachedScalingRules) + out := new(MemcachedStorageAutoscalerSpec) in.DeepCopyInto(out) return out } @@ -2007,32 +2504,6 @@ func (in *PgBouncerAutoscaler) DeepCopyObject() runtime.Object { return nil } -// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *PgBouncerAutoscalerBehavior) DeepCopyInto(out *PgBouncerAutoscalerBehavior) { - *out = *in - if in.ScaleUp != nil { - in, out := &in.ScaleUp, &out.ScaleUp - *out = new(PgBouncerScalingRules) - (*in).DeepCopyInto(*out) - } - if in.ScaleDown != nil { - in, out := &in.ScaleDown, &out.ScaleDown - *out = new(PgBouncerScalingRules) - (*in).DeepCopyInto(*out) - } - return -} - -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PgBouncerAutoscalerBehavior. -func (in *PgBouncerAutoscalerBehavior) DeepCopy() *PgBouncerAutoscalerBehavior { - if in == nil { - return nil - } - out := new(PgBouncerAutoscalerBehavior) - in.DeepCopyInto(out) - return out -} - // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *PgBouncerAutoscalerList) DeepCopyInto(out *PgBouncerAutoscalerList) { *out = *in @@ -2069,22 +2540,19 @@ func (in *PgBouncerAutoscalerList) DeepCopyObject() runtime.Object { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *PgBouncerAutoscalerSpec) DeepCopyInto(out *PgBouncerAutoscalerSpec) { *out = *in - out.ServerRef = in.ServerRef - if in.MinReplicas != nil { - in, out := &in.MinReplicas, &out.MinReplicas - *out = new(int32) + if in.DatabaseRef != nil { + in, out := &in.DatabaseRef, &out.DatabaseRef + *out = new(corev1.LocalObjectReference) **out = **in } - if in.Metrics != nil { - in, out := &in.Metrics, &out.Metrics - *out = make([]v2beta2.MetricSpec, len(*in)) - for i := range *in { - (*in)[i].DeepCopyInto(&(*out)[i]) - } + if in.OpsRequestOptions != nil { + in, out := &in.OpsRequestOptions, &out.OpsRequestOptions + *out = new(PgBouncerOpsRequestOptions) + (*in).DeepCopyInto(*out) } - if in.Behavior != nil { - in, out := &in.Behavior, &out.Behavior - *out = new(PgBouncerAutoscalerBehavior) + if in.Compute != nil { + in, out := &in.Compute, &out.Compute + *out = new(PgBouncerComputeAutoscalerSpec) (*in).DeepCopyInto(*out) } return @@ -2101,48 +2569,69 @@ func (in *PgBouncerAutoscalerSpec) DeepCopy() *PgBouncerAutoscalerSpec { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *PgBouncerScalingPolicy) DeepCopyInto(out *PgBouncerScalingPolicy) { +func (in *PgBouncerComputeAutoscalerSpec) DeepCopyInto(out *PgBouncerComputeAutoscalerSpec) { *out = *in + if in.NodeTopology != nil { + in, out := &in.NodeTopology, &out.NodeTopology + *out = new(NodeTopology) + (*in).DeepCopyInto(*out) + } + if in.PgBouncer != nil { + in, out := &in.PgBouncer, &out.PgBouncer + *out = new(ComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PgBouncerScalingPolicy. -func (in *PgBouncerScalingPolicy) DeepCopy() *PgBouncerScalingPolicy { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PgBouncerComputeAutoscalerSpec. +func (in *PgBouncerComputeAutoscalerSpec) DeepCopy() *PgBouncerComputeAutoscalerSpec { if in == nil { return nil } - out := new(PgBouncerScalingPolicy) + out := new(PgBouncerComputeAutoscalerSpec) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *PgBouncerScalingRules) DeepCopyInto(out *PgBouncerScalingRules) { +func (in *PgBouncerOpsRequestOptions) DeepCopyInto(out *PgBouncerOpsRequestOptions) { *out = *in - if in.StabilizationWindowSeconds != nil { - in, out := &in.StabilizationWindowSeconds, &out.StabilizationWindowSeconds - *out = new(int32) + if in.Timeout != nil { + in, out := &in.Timeout, &out.Timeout + *out = new(metav1.Duration) **out = **in } - if in.SelectPolicy != nil { - in, out := &in.SelectPolicy, &out.SelectPolicy - *out = new(v2beta2.ScalingPolicySelect) - **out = **in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PgBouncerOpsRequestOptions. +func (in *PgBouncerOpsRequestOptions) DeepCopy() *PgBouncerOpsRequestOptions { + if in == nil { + return nil } - if in.Policies != nil { - in, out := &in.Policies, &out.Policies - *out = make([]PgBouncerScalingPolicy, len(*in)) - copy(*out, *in) + out := new(PgBouncerOpsRequestOptions) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *PgBouncerStorageAutoscalerSpec) DeepCopyInto(out *PgBouncerStorageAutoscalerSpec) { + *out = *in + if in.PgBouncer != nil { + in, out := &in.PgBouncer, &out.PgBouncer + *out = new(StorageAutoscalerSpec) + (*in).DeepCopyInto(*out) } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PgBouncerScalingRules. -func (in *PgBouncerScalingRules) DeepCopy() *PgBouncerScalingRules { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PgBouncerStorageAutoscalerSpec. +func (in *PgBouncerStorageAutoscalerSpec) DeepCopy() *PgBouncerStorageAutoscalerSpec { if in == nil { return nil } - out := new(PgBouncerScalingRules) + out := new(PgBouncerStorageAutoscalerSpec) in.DeepCopyInto(out) return out } @@ -3078,13 +3567,183 @@ func (in *RedisSentinelAutoscalerList) DeepCopy() *RedisSentinelAutoscalerList { if in == nil { return nil } - out := new(RedisSentinelAutoscalerList) + out := new(RedisSentinelAutoscalerList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *RedisSentinelAutoscalerList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RedisSentinelAutoscalerSpec) DeepCopyInto(out *RedisSentinelAutoscalerSpec) { + *out = *in + if in.DatabaseRef != nil { + in, out := &in.DatabaseRef, &out.DatabaseRef + *out = new(corev1.LocalObjectReference) + **out = **in + } + if in.OpsRequestOptions != nil { + in, out := &in.OpsRequestOptions, &out.OpsRequestOptions + *out = new(RedisSentinelOpsRequestOptions) + (*in).DeepCopyInto(*out) + } + if in.Compute != nil { + in, out := &in.Compute, &out.Compute + *out = new(RedisSentinelComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RedisSentinelAutoscalerSpec. +func (in *RedisSentinelAutoscalerSpec) DeepCopy() *RedisSentinelAutoscalerSpec { + if in == nil { + return nil + } + out := new(RedisSentinelAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RedisSentinelComputeAutoscalerSpec) DeepCopyInto(out *RedisSentinelComputeAutoscalerSpec) { + *out = *in + if in.NodeTopology != nil { + in, out := &in.NodeTopology, &out.NodeTopology + *out = new(NodeTopology) + (*in).DeepCopyInto(*out) + } + if in.Sentinel != nil { + in, out := &in.Sentinel, &out.Sentinel + *out = new(ComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RedisSentinelComputeAutoscalerSpec. +func (in *RedisSentinelComputeAutoscalerSpec) DeepCopy() *RedisSentinelComputeAutoscalerSpec { + if in == nil { + return nil + } + out := new(RedisSentinelComputeAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RedisSentinelOpsRequestOptions) DeepCopyInto(out *RedisSentinelOpsRequestOptions) { + *out = *in + if in.Timeout != nil { + in, out := &in.Timeout, &out.Timeout + *out = new(metav1.Duration) + **out = **in + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RedisSentinelOpsRequestOptions. +func (in *RedisSentinelOpsRequestOptions) DeepCopy() *RedisSentinelOpsRequestOptions { + if in == nil { + return nil + } + out := new(RedisSentinelOpsRequestOptions) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RedisStorageAutoscalerSpec) DeepCopyInto(out *RedisStorageAutoscalerSpec) { + *out = *in + if in.Standalone != nil { + in, out := &in.Standalone, &out.Standalone + *out = new(StorageAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Cluster != nil { + in, out := &in.Cluster, &out.Cluster + *out = new(StorageAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Sentinel != nil { + in, out := &in.Sentinel, &out.Sentinel + *out = new(StorageAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RedisStorageAutoscalerSpec. +func (in *RedisStorageAutoscalerSpec) DeepCopy() *RedisStorageAutoscalerSpec { + if in == nil { + return nil + } + out := new(RedisStorageAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SinglestoreAutoscaler) DeepCopyInto(out *SinglestoreAutoscaler) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SinglestoreAutoscaler. +func (in *SinglestoreAutoscaler) DeepCopy() *SinglestoreAutoscaler { + if in == nil { + return nil + } + out := new(SinglestoreAutoscaler) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *SinglestoreAutoscaler) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SinglestoreAutoscalerList) DeepCopyInto(out *SinglestoreAutoscalerList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]SinglestoreAutoscaler, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SinglestoreAutoscalerList. +func (in *SinglestoreAutoscalerList) DeepCopy() *SinglestoreAutoscalerList { + if in == nil { + return nil + } + out := new(SinglestoreAutoscalerList) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *RedisSentinelAutoscalerList) DeepCopyObject() runtime.Object { +func (in *SinglestoreAutoscalerList) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } @@ -3092,7 +3751,7 @@ func (in *RedisSentinelAutoscalerList) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *RedisSentinelAutoscalerSpec) DeepCopyInto(out *RedisSentinelAutoscalerSpec) { +func (in *SinglestoreAutoscalerSpec) DeepCopyInto(out *SinglestoreAutoscalerSpec) { *out = *in if in.DatabaseRef != nil { in, out := &in.DatabaseRef, &out.DatabaseRef @@ -3101,55 +3760,70 @@ func (in *RedisSentinelAutoscalerSpec) DeepCopyInto(out *RedisSentinelAutoscaler } if in.OpsRequestOptions != nil { in, out := &in.OpsRequestOptions, &out.OpsRequestOptions - *out = new(RedisSentinelOpsRequestOptions) + *out = new(SinglestoreOpsRequestOptions) (*in).DeepCopyInto(*out) } if in.Compute != nil { in, out := &in.Compute, &out.Compute - *out = new(RedisSentinelComputeAutoscalerSpec) + *out = new(SinglestoreComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Storage != nil { + in, out := &in.Storage, &out.Storage + *out = new(SinglestoreStorageAutoscalerSpec) (*in).DeepCopyInto(*out) } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RedisSentinelAutoscalerSpec. -func (in *RedisSentinelAutoscalerSpec) DeepCopy() *RedisSentinelAutoscalerSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SinglestoreAutoscalerSpec. +func (in *SinglestoreAutoscalerSpec) DeepCopy() *SinglestoreAutoscalerSpec { if in == nil { return nil } - out := new(RedisSentinelAutoscalerSpec) + out := new(SinglestoreAutoscalerSpec) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *RedisSentinelComputeAutoscalerSpec) DeepCopyInto(out *RedisSentinelComputeAutoscalerSpec) { +func (in *SinglestoreComputeAutoscalerSpec) DeepCopyInto(out *SinglestoreComputeAutoscalerSpec) { *out = *in if in.NodeTopology != nil { in, out := &in.NodeTopology, &out.NodeTopology *out = new(NodeTopology) (*in).DeepCopyInto(*out) } - if in.Sentinel != nil { - in, out := &in.Sentinel, &out.Sentinel + if in.Node != nil { + in, out := &in.Node, &out.Node + *out = new(ComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Aggregator != nil { + in, out := &in.Aggregator, &out.Aggregator + *out = new(ComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Leaf != nil { + in, out := &in.Leaf, &out.Leaf *out = new(ComputeAutoscalerSpec) (*in).DeepCopyInto(*out) } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RedisSentinelComputeAutoscalerSpec. -func (in *RedisSentinelComputeAutoscalerSpec) DeepCopy() *RedisSentinelComputeAutoscalerSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SinglestoreComputeAutoscalerSpec. +func (in *SinglestoreComputeAutoscalerSpec) DeepCopy() *SinglestoreComputeAutoscalerSpec { if in == nil { return nil } - out := new(RedisSentinelComputeAutoscalerSpec) + out := new(SinglestoreComputeAutoscalerSpec) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *RedisSentinelOpsRequestOptions) DeepCopyInto(out *RedisSentinelOpsRequestOptions) { +func (in *SinglestoreOpsRequestOptions) DeepCopyInto(out *SinglestoreOpsRequestOptions) { *out = *in if in.Timeout != nil { in, out := &in.Timeout, &out.Timeout @@ -3159,49 +3833,49 @@ func (in *RedisSentinelOpsRequestOptions) DeepCopyInto(out *RedisSentinelOpsRequ return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RedisSentinelOpsRequestOptions. -func (in *RedisSentinelOpsRequestOptions) DeepCopy() *RedisSentinelOpsRequestOptions { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SinglestoreOpsRequestOptions. +func (in *SinglestoreOpsRequestOptions) DeepCopy() *SinglestoreOpsRequestOptions { if in == nil { return nil } - out := new(RedisSentinelOpsRequestOptions) + out := new(SinglestoreOpsRequestOptions) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *RedisStorageAutoscalerSpec) DeepCopyInto(out *RedisStorageAutoscalerSpec) { +func (in *SinglestoreStorageAutoscalerSpec) DeepCopyInto(out *SinglestoreStorageAutoscalerSpec) { *out = *in - if in.Standalone != nil { - in, out := &in.Standalone, &out.Standalone + if in.Node != nil { + in, out := &in.Node, &out.Node *out = new(StorageAutoscalerSpec) (*in).DeepCopyInto(*out) } - if in.Cluster != nil { - in, out := &in.Cluster, &out.Cluster + if in.Aggregator != nil { + in, out := &in.Aggregator, &out.Aggregator *out = new(StorageAutoscalerSpec) (*in).DeepCopyInto(*out) } - if in.Sentinel != nil { - in, out := &in.Sentinel, &out.Sentinel + if in.Leaf != nil { + in, out := &in.Leaf, &out.Leaf *out = new(StorageAutoscalerSpec) (*in).DeepCopyInto(*out) } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RedisStorageAutoscalerSpec. -func (in *RedisStorageAutoscalerSpec) DeepCopy() *RedisStorageAutoscalerSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SinglestoreStorageAutoscalerSpec. +func (in *SinglestoreStorageAutoscalerSpec) DeepCopy() *SinglestoreStorageAutoscalerSpec { if in == nil { return nil } - out := new(RedisStorageAutoscalerSpec) + out := new(SinglestoreStorageAutoscalerSpec) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *SinglestoreAutoscaler) DeepCopyInto(out *SinglestoreAutoscaler) { +func (in *SolrAutoscaler) DeepCopyInto(out *SolrAutoscaler) { *out = *in out.TypeMeta = in.TypeMeta in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) @@ -3210,18 +3884,18 @@ func (in *SinglestoreAutoscaler) DeepCopyInto(out *SinglestoreAutoscaler) { return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SinglestoreAutoscaler. -func (in *SinglestoreAutoscaler) DeepCopy() *SinglestoreAutoscaler { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SolrAutoscaler. +func (in *SolrAutoscaler) DeepCopy() *SolrAutoscaler { if in == nil { return nil } - out := new(SinglestoreAutoscaler) + out := new(SolrAutoscaler) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *SinglestoreAutoscaler) DeepCopyObject() runtime.Object { +func (in *SolrAutoscaler) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } @@ -3229,13 +3903,13 @@ func (in *SinglestoreAutoscaler) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *SinglestoreAutoscalerList) DeepCopyInto(out *SinglestoreAutoscalerList) { +func (in *SolrAutoscalerList) DeepCopyInto(out *SolrAutoscalerList) { *out = *in out.TypeMeta = in.TypeMeta in.ListMeta.DeepCopyInto(&out.ListMeta) if in.Items != nil { in, out := &in.Items, &out.Items - *out = make([]SinglestoreAutoscaler, len(*in)) + *out = make([]SolrAutoscaler, len(*in)) for i := range *in { (*in)[i].DeepCopyInto(&(*out)[i]) } @@ -3243,18 +3917,18 @@ func (in *SinglestoreAutoscalerList) DeepCopyInto(out *SinglestoreAutoscalerList return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SinglestoreAutoscalerList. -func (in *SinglestoreAutoscalerList) DeepCopy() *SinglestoreAutoscalerList { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SolrAutoscalerList. +func (in *SolrAutoscalerList) DeepCopy() *SolrAutoscalerList { if in == nil { return nil } - out := new(SinglestoreAutoscalerList) + out := new(SolrAutoscalerList) in.DeepCopyInto(out) return out } // DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. -func (in *SinglestoreAutoscalerList) DeepCopyObject() runtime.Object { +func (in *SolrAutoscalerList) DeepCopyObject() runtime.Object { if c := in.DeepCopy(); c != nil { return c } @@ -3262,7 +3936,7 @@ func (in *SinglestoreAutoscalerList) DeepCopyObject() runtime.Object { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *SinglestoreAutoscalerSpec) DeepCopyInto(out *SinglestoreAutoscalerSpec) { +func (in *SolrAutoscalerSpec) DeepCopyInto(out *SolrAutoscalerSpec) { *out = *in if in.DatabaseRef != nil { in, out := &in.DatabaseRef, &out.DatabaseRef @@ -3271,70 +3945,60 @@ func (in *SinglestoreAutoscalerSpec) DeepCopyInto(out *SinglestoreAutoscalerSpec } if in.OpsRequestOptions != nil { in, out := &in.OpsRequestOptions, &out.OpsRequestOptions - *out = new(SinglestoreOpsRequestOptions) + *out = new(SolrOpsRequestOptions) (*in).DeepCopyInto(*out) } if in.Compute != nil { in, out := &in.Compute, &out.Compute - *out = new(SinglestoreComputeAutoscalerSpec) + *out = new(SolrComputeAutoscalerSpec) (*in).DeepCopyInto(*out) } if in.Storage != nil { in, out := &in.Storage, &out.Storage - *out = new(SinglestoreStorageAutoscalerSpec) + *out = new(SolrStorageAutoscalerSpec) (*in).DeepCopyInto(*out) } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SinglestoreAutoscalerSpec. -func (in *SinglestoreAutoscalerSpec) DeepCopy() *SinglestoreAutoscalerSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SolrAutoscalerSpec. +func (in *SolrAutoscalerSpec) DeepCopy() *SolrAutoscalerSpec { if in == nil { return nil } - out := new(SinglestoreAutoscalerSpec) + out := new(SolrAutoscalerSpec) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *SinglestoreComputeAutoscalerSpec) DeepCopyInto(out *SinglestoreComputeAutoscalerSpec) { +func (in *SolrComputeAutoscalerSpec) DeepCopyInto(out *SolrComputeAutoscalerSpec) { *out = *in if in.NodeTopology != nil { in, out := &in.NodeTopology, &out.NodeTopology *out = new(NodeTopology) (*in).DeepCopyInto(*out) } - if in.Node != nil { - in, out := &in.Node, &out.Node - *out = new(ComputeAutoscalerSpec) - (*in).DeepCopyInto(*out) - } - if in.Aggregator != nil { - in, out := &in.Aggregator, &out.Aggregator - *out = new(ComputeAutoscalerSpec) - (*in).DeepCopyInto(*out) - } - if in.Leaf != nil { - in, out := &in.Leaf, &out.Leaf + if in.Solr != nil { + in, out := &in.Solr, &out.Solr *out = new(ComputeAutoscalerSpec) (*in).DeepCopyInto(*out) } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SinglestoreComputeAutoscalerSpec. -func (in *SinglestoreComputeAutoscalerSpec) DeepCopy() *SinglestoreComputeAutoscalerSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SolrComputeAutoscalerSpec. +func (in *SolrComputeAutoscalerSpec) DeepCopy() *SolrComputeAutoscalerSpec { if in == nil { return nil } - out := new(SinglestoreComputeAutoscalerSpec) + out := new(SolrComputeAutoscalerSpec) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *SinglestoreOpsRequestOptions) DeepCopyInto(out *SinglestoreOpsRequestOptions) { +func (in *SolrOpsRequestOptions) DeepCopyInto(out *SolrOpsRequestOptions) { *out = *in if in.Timeout != nil { in, out := &in.Timeout, &out.Timeout @@ -3344,43 +4008,33 @@ func (in *SinglestoreOpsRequestOptions) DeepCopyInto(out *SinglestoreOpsRequestO return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SinglestoreOpsRequestOptions. -func (in *SinglestoreOpsRequestOptions) DeepCopy() *SinglestoreOpsRequestOptions { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SolrOpsRequestOptions. +func (in *SolrOpsRequestOptions) DeepCopy() *SolrOpsRequestOptions { if in == nil { return nil } - out := new(SinglestoreOpsRequestOptions) + out := new(SolrOpsRequestOptions) in.DeepCopyInto(out) return out } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. -func (in *SinglestoreStorageAutoscalerSpec) DeepCopyInto(out *SinglestoreStorageAutoscalerSpec) { +func (in *SolrStorageAutoscalerSpec) DeepCopyInto(out *SolrStorageAutoscalerSpec) { *out = *in - if in.Node != nil { - in, out := &in.Node, &out.Node - *out = new(StorageAutoscalerSpec) - (*in).DeepCopyInto(*out) - } - if in.Aggregator != nil { - in, out := &in.Aggregator, &out.Aggregator - *out = new(StorageAutoscalerSpec) - (*in).DeepCopyInto(*out) - } - if in.Leaf != nil { - in, out := &in.Leaf, &out.Leaf + if in.Solr != nil { + in, out := &in.Solr, &out.Solr *out = new(StorageAutoscalerSpec) (*in).DeepCopyInto(*out) } return } -// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SinglestoreStorageAutoscalerSpec. -func (in *SinglestoreStorageAutoscalerSpec) DeepCopy() *SinglestoreStorageAutoscalerSpec { +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SolrStorageAutoscalerSpec. +func (in *SolrStorageAutoscalerSpec) DeepCopy() *SolrStorageAutoscalerSpec { if in == nil { return nil } - out := new(SinglestoreStorageAutoscalerSpec) + out := new(SolrStorageAutoscalerSpec) in.DeepCopyInto(out) return out } @@ -3497,3 +4151,168 @@ func (in *VerticalPodAutopilotRecommenderSelector) DeepCopy() *VerticalPodAutopi in.DeepCopyInto(out) return out } + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ZooKeeperAutoscaler) DeepCopyInto(out *ZooKeeperAutoscaler) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ZooKeeperAutoscaler. +func (in *ZooKeeperAutoscaler) DeepCopy() *ZooKeeperAutoscaler { + if in == nil { + return nil + } + out := new(ZooKeeperAutoscaler) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *ZooKeeperAutoscaler) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ZooKeeperAutoscalerList) DeepCopyInto(out *ZooKeeperAutoscalerList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ZooKeeperAutoscaler, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ZooKeeperAutoscalerList. +func (in *ZooKeeperAutoscalerList) DeepCopy() *ZooKeeperAutoscalerList { + if in == nil { + return nil + } + out := new(ZooKeeperAutoscalerList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *ZooKeeperAutoscalerList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ZooKeeperAutoscalerSpec) DeepCopyInto(out *ZooKeeperAutoscalerSpec) { + *out = *in + if in.DatabaseRef != nil { + in, out := &in.DatabaseRef, &out.DatabaseRef + *out = new(corev1.LocalObjectReference) + **out = **in + } + if in.OpsRequestOptions != nil { + in, out := &in.OpsRequestOptions, &out.OpsRequestOptions + *out = new(ZooKeeperOpsRequestOptions) + (*in).DeepCopyInto(*out) + } + if in.Compute != nil { + in, out := &in.Compute, &out.Compute + *out = new(ZooKeeperComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + if in.Storage != nil { + in, out := &in.Storage, &out.Storage + *out = new(ZooKeeperStorageAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ZooKeeperAutoscalerSpec. +func (in *ZooKeeperAutoscalerSpec) DeepCopy() *ZooKeeperAutoscalerSpec { + if in == nil { + return nil + } + out := new(ZooKeeperAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ZooKeeperComputeAutoscalerSpec) DeepCopyInto(out *ZooKeeperComputeAutoscalerSpec) { + *out = *in + if in.NodeTopology != nil { + in, out := &in.NodeTopology, &out.NodeTopology + *out = new(NodeTopology) + (*in).DeepCopyInto(*out) + } + if in.ZooKeeper != nil { + in, out := &in.ZooKeeper, &out.ZooKeeper + *out = new(ComputeAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ZooKeeperComputeAutoscalerSpec. +func (in *ZooKeeperComputeAutoscalerSpec) DeepCopy() *ZooKeeperComputeAutoscalerSpec { + if in == nil { + return nil + } + out := new(ZooKeeperComputeAutoscalerSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ZooKeeperOpsRequestOptions) DeepCopyInto(out *ZooKeeperOpsRequestOptions) { + *out = *in + if in.Timeout != nil { + in, out := &in.Timeout, &out.Timeout + *out = new(metav1.Duration) + **out = **in + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ZooKeeperOpsRequestOptions. +func (in *ZooKeeperOpsRequestOptions) DeepCopy() *ZooKeeperOpsRequestOptions { + if in == nil { + return nil + } + out := new(ZooKeeperOpsRequestOptions) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ZooKeeperStorageAutoscalerSpec) DeepCopyInto(out *ZooKeeperStorageAutoscalerSpec) { + *out = *in + if in.ZooKeeper != nil { + in, out := &in.ZooKeeper, &out.ZooKeeper + *out = new(StorageAutoscalerSpec) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ZooKeeperStorageAutoscalerSpec. +func (in *ZooKeeperStorageAutoscalerSpec) DeepCopy() *ZooKeeperStorageAutoscalerSpec { + if in == nil { + return nil + } + out := new(ZooKeeperStorageAutoscalerSpec) + in.DeepCopyInto(out) + return out +} diff --git a/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/mssql_version_types.go b/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/mssql_version_types.go index 9ba860097..47498d66a 100644 --- a/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/mssql_version_types.go +++ b/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/mssql_version_types.go @@ -55,6 +55,8 @@ type MSSQLServerVersionSpec struct { // Coordinator Image // +optional Coordinator MSSQLServerCoordinator `json:"coordinator,omitempty"` + // Exporter Image + Exporter MSSQLServerVersionExporter `json:"exporter"` // Init container Image InitContainer MSSQLServerInitContainer `json:"initContainer"` // Deprecated versions usable but regarded as obsolete and best avoided, typically due to having been superseded. @@ -68,6 +70,8 @@ type MSSQLServerVersionSpec struct { SecurityContext SecurityContext `json:"securityContext"` // update constraints UpdateConstraints UpdateConstraints `json:"updateConstraints,omitempty"` + // Archiver defines the walg & kube-stash-addon related specifications + Archiver ArchiverSpec `json:"archiver,omitempty"` // +optional UI []ChartInfo `json:"ui,omitempty"` } @@ -82,6 +86,11 @@ type MSSQLServerCoordinator struct { Image string `json:"image"` } +// MSSQLServerVersionExporter is the image for the MSSQL Server exporter +type MSSQLServerVersionExporter struct { + Image string `json:"image"` +} + // MSSQLServerInitContainer is the MSSQLServer Container initializer type MSSQLServerInitContainer struct { Image string `json:"image"` diff --git a/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/openapi_generated.go b/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/openapi_generated.go index e874ce392..32f78c10b 100644 --- a/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/openapi_generated.go +++ b/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/openapi_generated.go @@ -525,6 +525,8 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/catalog/v1alpha1.FerretDBVersionDatabase": schema_apimachinery_apis_catalog_v1alpha1_FerretDBVersionDatabase(ref), "kubedb.dev/apimachinery/apis/catalog/v1alpha1.FerretDBVersionList": schema_apimachinery_apis_catalog_v1alpha1_FerretDBVersionList(ref), "kubedb.dev/apimachinery/apis/catalog/v1alpha1.FerretDBVersionSpec": schema_apimachinery_apis_catalog_v1alpha1_FerretDBVersionSpec(ref), + "kubedb.dev/apimachinery/apis/catalog/v1alpha1.FullBackup": schema_apimachinery_apis_catalog_v1alpha1_FullBackup(ref), + "kubedb.dev/apimachinery/apis/catalog/v1alpha1.FullBackupRestore": schema_apimachinery_apis_catalog_v1alpha1_FullBackupRestore(ref), "kubedb.dev/apimachinery/apis/catalog/v1alpha1.GitSyncer": schema_apimachinery_apis_catalog_v1alpha1_GitSyncer(ref), "kubedb.dev/apimachinery/apis/catalog/v1alpha1.KafkaConnectorVersion": schema_apimachinery_apis_catalog_v1alpha1_KafkaConnectorVersion(ref), "kubedb.dev/apimachinery/apis/catalog/v1alpha1.KafkaConnectorVersionList": schema_apimachinery_apis_catalog_v1alpha1_KafkaConnectorVersionList(ref), @@ -538,6 +540,7 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerDatabase": schema_apimachinery_apis_catalog_v1alpha1_MSSQLServerDatabase(ref), "kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerInitContainer": schema_apimachinery_apis_catalog_v1alpha1_MSSQLServerInitContainer(ref), "kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerVersion": schema_apimachinery_apis_catalog_v1alpha1_MSSQLServerVersion(ref), + "kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerVersionExporter": schema_apimachinery_apis_catalog_v1alpha1_MSSQLServerVersionExporter(ref), "kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerVersionList": schema_apimachinery_apis_catalog_v1alpha1_MSSQLServerVersionList(ref), "kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerVersionSpec": schema_apimachinery_apis_catalog_v1alpha1_MSSQLServerVersionSpec(ref), "kubedb.dev/apimachinery/apis/catalog/v1alpha1.ManifestBackup": schema_apimachinery_apis_catalog_v1alpha1_ManifestBackup(ref), @@ -25305,11 +25308,23 @@ func schema_apimachinery_apis_catalog_v1alpha1_AddonTasks(ref common.ReferenceCa Ref: ref("kubedb.dev/apimachinery/apis/catalog/v1alpha1.ManifestRestore"), }, }, + "fullBackup": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/catalog/v1alpha1.FullBackup"), + }, + }, + "fullBackupRestore": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/catalog/v1alpha1.FullBackupRestore"), + }, + }, }, }, }, Dependencies: []string{ - "kubedb.dev/apimachinery/apis/catalog/v1alpha1.ManifestBackup", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.ManifestRestore", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.VolumeSnapshot"}, + "kubedb.dev/apimachinery/apis/catalog/v1alpha1.FullBackup", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.FullBackupRestore", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.ManifestBackup", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.ManifestRestore", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.VolumeSnapshot"}, } } @@ -26614,6 +26629,46 @@ func schema_apimachinery_apis_catalog_v1alpha1_FerretDBVersionSpec(ref common.Re } } +func schema_apimachinery_apis_catalog_v1alpha1_FullBackup(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name"}, + }, + }, + } +} + +func schema_apimachinery_apis_catalog_v1alpha1_FullBackupRestore(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "name": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"name"}, + }, + }, + } +} + func schema_apimachinery_apis_catalog_v1alpha1_GitSyncer(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -27104,6 +27159,27 @@ func schema_apimachinery_apis_catalog_v1alpha1_MSSQLServerVersion(ref common.Ref } } +func schema_apimachinery_apis_catalog_v1alpha1_MSSQLServerVersionExporter(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "MSSQLServerVersionExporter is the image for the MSSQL Server exporter", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "image": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"image"}, + }, + }, + } +} + func schema_apimachinery_apis_catalog_v1alpha1_MSSQLServerVersionList(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -27182,6 +27258,13 @@ func schema_apimachinery_apis_catalog_v1alpha1_MSSQLServerVersionSpec(ref common Ref: ref("kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerCoordinator"), }, }, + "exporter": { + SchemaProps: spec.SchemaProps{ + Description: "Exporter Image", + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerVersionExporter"), + }, + }, "initContainer": { SchemaProps: spec.SchemaProps{ Description: "Init container Image", @@ -27217,6 +27300,13 @@ func schema_apimachinery_apis_catalog_v1alpha1_MSSQLServerVersionSpec(ref common Ref: ref("kubedb.dev/apimachinery/apis/catalog/v1alpha1.UpdateConstraints"), }, }, + "archiver": { + SchemaProps: spec.SchemaProps{ + Description: "Archiver defines the walg & kube-stash-addon related specifications", + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/catalog/v1alpha1.ArchiverSpec"), + }, + }, "ui": { SchemaProps: spec.SchemaProps{ Type: []string{"array"}, @@ -27231,11 +27321,11 @@ func schema_apimachinery_apis_catalog_v1alpha1_MSSQLServerVersionSpec(ref common }, }, }, - Required: []string{"version", "db", "initContainer"}, + Required: []string{"version", "db", "exporter", "initContainer"}, }, }, Dependencies: []string{ - "kmodules.xyz/custom-resources/apis/appcatalog/v1alpha1.StashAddonSpec", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.ChartInfo", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerCoordinator", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerDatabase", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerInitContainer", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.SecurityContext", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.UpdateConstraints"}, + "kmodules.xyz/custom-resources/apis/appcatalog/v1alpha1.StashAddonSpec", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.ArchiverSpec", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.ChartInfo", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerCoordinator", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerDatabase", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerInitContainer", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.MSSQLServerVersionExporter", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.SecurityContext", "kubedb.dev/apimachinery/apis/catalog/v1alpha1.UpdateConstraints"}, } } diff --git a/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/types.go b/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/types.go index 9bef0f283..224a6cc7f 100644 --- a/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/types.go +++ b/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/types.go @@ -49,13 +49,19 @@ type AddonSpec struct { Tasks AddonTasks `json:"tasks,omitempty"` } -// +kubebuilder:validation:Enum=mongodb-addon;postgres-addon;mysql-addon;mariadb-addon +// +kubebuilder:validation:Enum=mongodb-addon;postgres-addon;mysql-addon;mariadb-addon;mssqlserver-addon type AddonType string type AddonTasks struct { - VolumeSnapshot VolumeSnapshot `json:"volumeSnapshot,omitempty"` - ManifestBackup ManifestBackup `json:"manifestBackup,omitempty"` - ManifestRestore ManifestRestore `json:"manifestRestore,omitempty"` + VolumeSnapshot VolumeSnapshot `json:"volumeSnapshot,omitempty"` + ManifestBackup ManifestBackup `json:"manifestBackup,omitempty"` + ManifestRestore ManifestRestore `json:"manifestRestore,omitempty"` + FullBackup FullBackup `json:"fullBackup,omitempty"` + FullBackupRestore FullBackupRestore `json:"fullBackupRestore,omitempty"` +} + +type FullBackup struct { + Name string `json:"name"` } type VolumeSnapshot struct { @@ -70,6 +76,10 @@ type ManifestRestore struct { Name string `json:"name"` } +type FullBackupRestore struct { + Name string `json:"name"` +} + // GitSyncer is the image for the kubernetes/git-sync // https://github.com/kubernetes/git-sync type GitSyncer struct { diff --git a/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/zz_generated.deepcopy.go b/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/zz_generated.deepcopy.go index 1fb4f4477..292382643 100644 --- a/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/zz_generated.deepcopy.go +++ b/vendor/kubedb.dev/apimachinery/apis/catalog/v1alpha1/zz_generated.deepcopy.go @@ -49,6 +49,8 @@ func (in *AddonTasks) DeepCopyInto(out *AddonTasks) { out.VolumeSnapshot = in.VolumeSnapshot out.ManifestBackup = in.ManifestBackup out.ManifestRestore = in.ManifestRestore + out.FullBackup = in.FullBackup + out.FullBackupRestore = in.FullBackupRestore return } @@ -843,6 +845,38 @@ func (in *FerretDBVersionSpec) DeepCopy() *FerretDBVersionSpec { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *FullBackup) DeepCopyInto(out *FullBackup) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FullBackup. +func (in *FullBackup) DeepCopy() *FullBackup { + if in == nil { + return nil + } + out := new(FullBackup) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *FullBackupRestore) DeepCopyInto(out *FullBackupRestore) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FullBackupRestore. +func (in *FullBackupRestore) DeepCopy() *FullBackupRestore { + if in == nil { + return nil + } + out := new(FullBackupRestore) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *GitSyncer) DeepCopyInto(out *GitSyncer) { *out = *in @@ -1134,6 +1168,22 @@ func (in *MSSQLServerVersion) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *MSSQLServerVersionExporter) DeepCopyInto(out *MSSQLServerVersionExporter) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MSSQLServerVersionExporter. +func (in *MSSQLServerVersionExporter) DeepCopy() *MSSQLServerVersionExporter { + if in == nil { + return nil + } + out := new(MSSQLServerVersionExporter) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *MSSQLServerVersionList) DeepCopyInto(out *MSSQLServerVersionList) { *out = *in @@ -1172,10 +1222,12 @@ func (in *MSSQLServerVersionSpec) DeepCopyInto(out *MSSQLServerVersionSpec) { *out = *in out.DB = in.DB out.Coordinator = in.Coordinator + out.Exporter = in.Exporter out.InitContainer = in.InitContainer in.Stash.DeepCopyInto(&out.Stash) in.SecurityContext.DeepCopyInto(&out.SecurityContext) in.UpdateConstraints.DeepCopyInto(&out.UpdateConstraints) + out.Archiver = in.Archiver if in.UI != nil { in, out := &in.UI, &out.UI *out = make([]ChartInfo, len(*in)) diff --git a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/connect_cluster_webhook.go b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/connect_cluster_webhook.go index 9cb1bc8fa..6070f1718 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/connect_cluster_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/connect_cluster_webhook.go @@ -59,7 +59,7 @@ func (k *ConnectCluster) ValidateCreate() (admission.Warnings, error) { if len(allErr) == 0 { return nil, nil } - return nil, apierrors.NewInvalid(schema.GroupKind{Group: "kafka.kubedb.com", Kind: "Kafka"}, k.Name, allErr) + return nil, apierrors.NewInvalid(schema.GroupKind{Group: "kafka.kubedb.com", Kind: "ConnectCluster"}, k.Name, allErr) } // ValidateUpdate implements webhook.Validator so a webhook will be registered for the type @@ -87,9 +87,9 @@ func (k *ConnectCluster) ValidateDelete() (admission.Warnings, error) { var allErr field.ErrorList if k.Spec.DeletionPolicy == dbapi.DeletionPolicyDoNotTerminate { - allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("terminationPolicy"), + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("deletionPolicy"), k.Name, - "Can not delete as terminationPolicy is set to \"DoNotTerminate\"")) + "Can not delete as deletionPolicy is set to \"DoNotTerminate\"")) return nil, apierrors.NewInvalid(schema.GroupKind{Group: "kafka.kubedb.com", Kind: "ConnectCluster"}, k.Name, allErr) } return nil, nil @@ -112,7 +112,7 @@ func (k *ConnectCluster) ValidateCreateOrUpdate() field.ErrorList { } if k.Spec.DeletionPolicy == dbapi.DeletionPolicyHalt { - allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("terminationPolicy"), + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("deletionPolicy"), k.Name, "DeletionPolicyHalt is not supported for ConnectCluster")) } diff --git a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/connector_webhook.go b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/connector_webhook.go index 802b3cb3d..7e38d4431 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/connector_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/connector_webhook.go @@ -64,9 +64,9 @@ func (k *Connector) ValidateDelete() (admission.Warnings, error) { var allErr field.ErrorList if k.Spec.DeletionPolicy == dbapi.DeletionPolicyDoNotTerminate { - allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("terminationPolicy"), + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("deletionPolicy"), k.Name, - "Can not delete as terminationPolicy is set to \"DoNotTerminate\"")) + "Can not delete as deletionPolicy is set to \"DoNotTerminate\"")) return nil, apierrors.NewInvalid(schema.GroupKind{Group: "kafka.kubedb.com", Kind: "Connector"}, k.Name, allErr) } return nil, nil @@ -75,7 +75,7 @@ func (k *Connector) ValidateDelete() (admission.Warnings, error) { func (k *Connector) ValidateCreateOrUpdate() error { var allErr field.ErrorList if k.Spec.DeletionPolicy == dbapi.DeletionPolicyHalt { - allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("terminationPolicy"), + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("deletionPolicy"), k.Name, "DeletionPolicyHalt isn't supported for Connector")) } diff --git a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/constants.go b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/constants.go index 24b212763..11930bfaa 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/constants.go +++ b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/constants.go @@ -111,3 +111,33 @@ const ( SchemaRegistryOperatorVolumeConfig = "registry-operator-config" SchemaRegistryOperatorConfigPath = "/deployments/config" ) + +// RestProxy constants + +const ( + RestProxyPrimaryPortName = "primary" + RestProxyPortName = "restproxy" + RestProxyRESTPort = 8082 + RestProxyContainerName = "rest-proxy" + RestProxyOperatorVolumeConfig = "rest-proxy-operator-config" + RestProxyOperatorConfigPath = "/opt/karapace/config" + + RestProxyKarapaceLogLevel = "log_level" + RestProxyKarapaceLogLevelWarning = "WARNING" + RestProxyKarapaceLogLevelInfo = "INFO" + RestProxyKarapaceLogLevelDebug = "DEBUG" + RestProxyKarapaceHostName = "host" + RestProxyKarapacePortName = "port" + RestProxyKafkaBootstrapURI = "bootstrap_uri" + RestProxyKafkaSecurityProtocolName = "security_protocol" + RestProxyKafkaSASLMechanismName = "sasl_mechanism" + RestProxyKafkaSASLUsername = "sasl_plain_username" + RestProxyKafkaSASLPassword = "sasl_plain_password" + RestProxyKafkaSSLCAFile = "ssl_cafile" + RestProxyKafkaSSLCertFile = "ssl_certfile" + RestProxyKafkaSSLKeyFile = "ssl_keyfile" + RestProxyKafkaSSLCAFilePath = "/var/private/kafka-client-ssl/ca.crt" + RestProxyKafkaSSLCertFilePath = "/var/private/kafka-client-ssl/tls.crt" + RestProxyKafkaSSLKeyFilePath = "/var/private/kafka-client-ssl/tls.key" + RestProxyConfigFileName = "rest.config.json" +) diff --git a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/openapi_generated.go b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/openapi_generated.go index 228565b07..2ca7f6880 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/openapi_generated.go +++ b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/openapi_generated.go @@ -496,6 +496,11 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/kafka/v1alpha1.ConnectorList": schema_apimachinery_apis_kafka_v1alpha1_ConnectorList(ref), "kubedb.dev/apimachinery/apis/kafka/v1alpha1.ConnectorSpec": schema_apimachinery_apis_kafka_v1alpha1_ConnectorSpec(ref), "kubedb.dev/apimachinery/apis/kafka/v1alpha1.ConnectorStatus": schema_apimachinery_apis_kafka_v1alpha1_ConnectorStatus(ref), + "kubedb.dev/apimachinery/apis/kafka/v1alpha1.RestProxy": schema_apimachinery_apis_kafka_v1alpha1_RestProxy(ref), + "kubedb.dev/apimachinery/apis/kafka/v1alpha1.RestProxyApp": schema_apimachinery_apis_kafka_v1alpha1_RestProxyApp(ref), + "kubedb.dev/apimachinery/apis/kafka/v1alpha1.RestProxyList": schema_apimachinery_apis_kafka_v1alpha1_RestProxyList(ref), + "kubedb.dev/apimachinery/apis/kafka/v1alpha1.RestProxySpec": schema_apimachinery_apis_kafka_v1alpha1_RestProxySpec(ref), + "kubedb.dev/apimachinery/apis/kafka/v1alpha1.RestProxyStatus": schema_apimachinery_apis_kafka_v1alpha1_RestProxyStatus(ref), "kubedb.dev/apimachinery/apis/kafka/v1alpha1.SchemaRegistry": schema_apimachinery_apis_kafka_v1alpha1_SchemaRegistry(ref), "kubedb.dev/apimachinery/apis/kafka/v1alpha1.SchemaRegistryApp": schema_apimachinery_apis_kafka_v1alpha1_SchemaRegistryApp(ref), "kubedb.dev/apimachinery/apis/kafka/v1alpha1.SchemaRegistryList": schema_apimachinery_apis_kafka_v1alpha1_SchemaRegistryList(ref), @@ -25562,6 +25567,236 @@ func schema_apimachinery_apis_kafka_v1alpha1_ConnectorStatus(ref common.Referenc } } +func schema_apimachinery_apis_kafka_v1alpha1_RestProxy(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/kafka/v1alpha1.RestProxySpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/kafka/v1alpha1.RestProxyStatus"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "kubedb.dev/apimachinery/apis/kafka/v1alpha1.RestProxySpec", "kubedb.dev/apimachinery/apis/kafka/v1alpha1.RestProxyStatus"}, + } +} + +func schema_apimachinery_apis_kafka_v1alpha1_RestProxyApp(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "RestProxy": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/kafka/v1alpha1.RestProxy"), + }, + }, + }, + Required: []string{"RestProxy"}, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/kafka/v1alpha1.RestProxy"}, + } +} + +func schema_apimachinery_apis_kafka_v1alpha1_RestProxyList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "RestProxyList contains a list of RestProxy", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/kafka/v1alpha1.RestProxy"), + }, + }, + }, + }, + }, + }, + Required: []string{"items"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "kubedb.dev/apimachinery/apis/kafka/v1alpha1.RestProxy"}, + } +} + +func schema_apimachinery_apis_kafka_v1alpha1_RestProxySpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "RestProxySpec defines the desired state of RestProxy", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "version": { + SchemaProps: spec.SchemaProps{ + Description: "Version of RestProxy to be deployed.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "replicas": { + SchemaProps: spec.SchemaProps{ + Description: "Number of instances to deploy for a rest proxy.", + Type: []string{"integer"}, + Format: "int32", + }, + }, + "kafkaRef": { + SchemaProps: spec.SchemaProps{ + Description: "Kafka app-binding reference KafkaRef is a required field, where RestProxy will connect to Kafka", + Ref: ref("kmodules.xyz/client-go/api/v1.ObjectReference"), + }, + }, + "podTemplate": { + SchemaProps: spec.SchemaProps{ + Description: "PodTemplate is an optional configuration for pods used to expose database", + Default: map[string]interface{}{}, + Ref: ref("kmodules.xyz/offshoot-api/api/v2.PodTemplateSpec"), + }, + }, + "serviceTemplates": { + SchemaProps: spec.SchemaProps{ + Description: "ServiceTemplates is an optional configuration for services used to expose database", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/kubedb/v1.NamedServiceTemplateSpec"), + }, + }, + }, + }, + }, + "deletionPolicy": { + SchemaProps: spec.SchemaProps{ + Description: "DeletionPolicy controls the delete operation for database", + Type: []string{"string"}, + Format: "", + }, + }, + "healthChecker": { + SchemaProps: spec.SchemaProps{ + Description: "HealthChecker defines attributes of the health checker", + Default: map[string]interface{}{}, + Ref: ref("kmodules.xyz/client-go/api/v1.HealthCheckSpec"), + }, + }, + }, + Required: []string{"version", "kafkaRef"}, + }, + }, + Dependencies: []string{ + "kmodules.xyz/client-go/api/v1.HealthCheckSpec", "kmodules.xyz/client-go/api/v1.ObjectReference", "kmodules.xyz/offshoot-api/api/v2.PodTemplateSpec", "kubedb.dev/apimachinery/apis/kubedb/v1.NamedServiceTemplateSpec"}, + } +} + +func schema_apimachinery_apis_kafka_v1alpha1_RestProxyStatus(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "RestProxyStatus defines the observed state of RestProxy", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "phase": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the current phase of the database", + Type: []string{"string"}, + Format: "", + }, + }, + "observedGeneration": { + SchemaProps: spec.SchemaProps{ + Description: "observedGeneration is the most recent generation observed for this resource. It corresponds to the resource's generation, which is updated on mutation by the API Server.", + Type: []string{"integer"}, + Format: "int64", + }, + }, + "conditions": { + SchemaProps: spec.SchemaProps{ + Description: "Conditions applied to the database, such as approval or denial.", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kmodules.xyz/client-go/api/v1.Condition"), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + "kmodules.xyz/client-go/api/v1.Condition"}, + } +} + func schema_apimachinery_apis_kafka_v1alpha1_SchemaRegistry(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ diff --git a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/register.go b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/register.go index ab368fa10..8a98a57d8 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/register.go +++ b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/register.go @@ -58,6 +58,8 @@ func addKnownTypes(scheme *runtime.Scheme) error { &ConnectClusterList{}, &Connector{}, &ConnectorList{}, + &RestProxy{}, + &RestProxyList{}, &SchemaRegistry{}, &SchemaRegistryList{}, ) diff --git a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/restproxy_helpers.go b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/restproxy_helpers.go new file mode 100644 index 000000000..5d50e1e85 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/restproxy_helpers.go @@ -0,0 +1,249 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "context" + "fmt" + + "kubedb.dev/apimachinery/apis" + catalog "kubedb.dev/apimachinery/apis/catalog/v1alpha1" + "kubedb.dev/apimachinery/apis/kafka" + "kubedb.dev/apimachinery/apis/kubedb" + dbapi "kubedb.dev/apimachinery/apis/kubedb/v1" + "kubedb.dev/apimachinery/crds" + + "gomodules.xyz/pointer" + core "k8s.io/api/core/v1" + meta "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/types" + "k8s.io/klog/v2" + "kmodules.xyz/client-go/apiextensions" + coreutil "kmodules.xyz/client-go/core/v1" + meta_util "kmodules.xyz/client-go/meta" + "kmodules.xyz/client-go/policy/secomp" + appcat "kmodules.xyz/custom-resources/apis/appcatalog/v1alpha1" + ofst "kmodules.xyz/offshoot-api/api/v1" + ofstv2 "kmodules.xyz/offshoot-api/api/v2" +) + +func (k *RestProxy) CustomResourceDefinition() *apiextensions.CustomResourceDefinition { + return crds.MustCustomResourceDefinition(SchemeGroupVersion.WithResource(ResourcePluralRestProxy)) +} + +func (k *RestProxy) AsOwner() *meta.OwnerReference { + return meta.NewControllerRef(k, SchemeGroupVersion.WithKind(ResourceKindRestProxy)) +} + +func (k *RestProxy) ResourceShortCode() string { + return ResourceCodeRestProxy +} + +func (k *RestProxy) ResourceKind() string { + return ResourceKindRestProxy +} + +func (k *RestProxy) ResourceSingular() string { + return ResourceSingularRestProxy +} + +func (k *RestProxy) ResourcePlural() string { + return ResourcePluralRestProxy +} + +func (k *RestProxy) ResourceFQN() string { + return fmt.Sprintf("%s.%s", k.ResourcePlural(), kafka.GroupName) +} + +// Owner returns owner reference to resources +func (k *RestProxy) Owner() *meta.OwnerReference { + return meta.NewControllerRef(k, SchemeGroupVersion.WithKind(k.ResourceKind())) +} + +func (k *RestProxy) OffshootName() string { + return k.Name +} + +func (k *RestProxy) GoverningServiceName() string { + return meta_util.NameWithSuffix(k.ServiceName(), "pods") +} + +func (k *RestProxy) ServiceName() string { + return k.OffshootName() +} + +func (k *RestProxy) offshootLabels(selector, override map[string]string) map[string]string { + selector[meta_util.ComponentLabelKey] = ComponentKafka + return meta_util.FilterKeys(kafka.GroupName, selector, meta_util.OverwriteKeys(nil, k.Labels, override)) +} + +func (k *RestProxy) OffshootSelectors(extraSelectors ...map[string]string) map[string]string { + selector := map[string]string{ + meta_util.NameLabelKey: k.ResourceFQN(), + meta_util.InstanceLabelKey: k.Name, + meta_util.ManagedByLabelKey: kafka.GroupName, + } + return meta_util.OverwriteKeys(selector, extraSelectors...) +} + +func (k *RestProxy) OffshootLabels() map[string]string { + return k.offshootLabels(k.OffshootSelectors(), nil) +} + +// GetServiceTemplate returns a pointer to the desired serviceTemplate referred by "aliaS". Otherwise, it returns nil. +func (k *RestProxy) GetServiceTemplate(templates []dbapi.NamedServiceTemplateSpec, alias dbapi.ServiceAlias) ofst.ServiceTemplateSpec { + for i := range templates { + c := templates[i] + if c.Alias == alias { + return c.ServiceTemplateSpec + } + } + return ofst.ServiceTemplateSpec{} +} + +func (k *RestProxy) ServiceLabels(alias dbapi.ServiceAlias, extraLabels ...map[string]string) map[string]string { + svcTemplate := k.GetServiceTemplate(k.Spec.ServiceTemplates, alias) + return k.offshootLabels(meta_util.OverwriteKeys(k.OffshootSelectors(), extraLabels...), svcTemplate.Labels) +} + +func (k *RestProxy) PodControllerLabels(extraLabels ...map[string]string) map[string]string { + return k.offshootLabels(meta_util.OverwriteKeys(k.OffshootSelectors(), extraLabels...), k.Spec.PodTemplate.Controller.Labels) +} + +func (k *RestProxy) PodLabels(extraLabels ...map[string]string) map[string]string { + return k.offshootLabels(meta_util.OverwriteKeys(k.OffshootSelectors(), extraLabels...), k.Spec.PodTemplate.Labels) +} + +func (k *RestProxy) PetSetName() string { + return k.OffshootName() +} + +func (k *RestProxy) ConfigSecretName() string { + return meta_util.NameWithSuffix(k.OffshootName(), "config") +} + +func (k *RestProxy) GetPersistentSecrets() []string { + var secrets []string + return secrets +} + +func (k *RestProxy) KafkaClientCredentialsSecretName() string { + return meta_util.NameWithSuffix(k.Name, "kafka-client-cred") +} + +func (k *RestProxy) SetHealthCheckerDefaults() { + if k.Spec.HealthChecker.PeriodSeconds == nil { + k.Spec.HealthChecker.PeriodSeconds = pointer.Int32P(10) + } + if k.Spec.HealthChecker.TimeoutSeconds == nil { + k.Spec.HealthChecker.TimeoutSeconds = pointer.Int32P(10) + } + if k.Spec.HealthChecker.FailureThreshold == nil { + k.Spec.HealthChecker.FailureThreshold = pointer.Int32P(3) + } +} + +func (k *RestProxy) SetDefaults() { + if k.Spec.DeletionPolicy == "" { + k.Spec.DeletionPolicy = dbapi.DeletionPolicyDelete + } + + if k.Spec.Replicas == nil { + k.Spec.Replicas = pointer.Int32P(1) + } + + var ksrVersion catalog.SchemaRegistryVersion + err := DefaultClient.Get(context.TODO(), types.NamespacedName{Name: k.Spec.Version}, &ksrVersion) + if err != nil { + klog.Errorf("can't get the version object %s for %s \n", err.Error(), k.Spec.Version) + return + } + + k.setDefaultContainerSecurityContext(&ksrVersion, &k.Spec.PodTemplate) + + dbContainer := coreutil.GetContainerByName(k.Spec.PodTemplate.Spec.Containers, RestProxyContainerName) + if dbContainer != nil && (dbContainer.Resources.Requests == nil && dbContainer.Resources.Limits == nil) { + apis.SetDefaultResourceLimits(&dbContainer.Resources, kubedb.DefaultResources) + } + + k.SetHealthCheckerDefaults() +} + +func (k *RestProxy) setDefaultContainerSecurityContext(ksrVersion *catalog.SchemaRegistryVersion, podTemplate *ofstv2.PodTemplateSpec) { + if podTemplate == nil { + return + } + if podTemplate.Spec.SecurityContext == nil { + podTemplate.Spec.SecurityContext = &core.PodSecurityContext{} + } + if podTemplate.Spec.SecurityContext.FSGroup == nil { + podTemplate.Spec.SecurityContext.FSGroup = ksrVersion.Spec.SecurityContext.RunAsUser + } + + container := coreutil.GetContainerByName(podTemplate.Spec.Containers, RestProxyContainerName) + if container == nil { + container = &core.Container{ + Name: RestProxyContainerName, + } + } + if container.SecurityContext == nil { + container.SecurityContext = &core.SecurityContext{} + } + k.assignDefaultContainerSecurityContext(ksrVersion, container.SecurityContext) + podTemplate.Spec.Containers = coreutil.UpsertContainer(podTemplate.Spec.Containers, *container) +} + +func (k *RestProxy) assignDefaultContainerSecurityContext(ksrVersion *catalog.SchemaRegistryVersion, sc *core.SecurityContext) { + if sc.AllowPrivilegeEscalation == nil { + sc.AllowPrivilegeEscalation = pointer.BoolP(false) + } + if sc.Capabilities == nil { + sc.Capabilities = &core.Capabilities{ + Drop: []core.Capability{"ALL"}, + } + } + if sc.RunAsNonRoot == nil { + sc.RunAsNonRoot = pointer.BoolP(true) + } + if sc.RunAsUser == nil { + sc.RunAsUser = ksrVersion.Spec.SecurityContext.RunAsUser + } + if sc.SeccompProfile == nil { + sc.SeccompProfile = secomp.DefaultSeccompProfile() + } +} + +type RestProxyApp struct { + *RestProxy +} + +func (r RestProxyApp) Name() string { + return r.RestProxy.Name +} + +func (r RestProxyApp) Type() appcat.AppType { + return appcat.AppType(fmt.Sprintf("%s/%s", kafka.GroupName, ResourceSingularRestProxy)) +} + +func (k *RestProxy) AppBindingMeta() appcat.AppBindingMeta { + return &RestProxyApp{k} +} + +func (k *RestProxy) GetConnectionScheme() string { + scheme := "http" + return scheme +} diff --git a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/restproxy_types.go b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/restproxy_types.go new file mode 100644 index 000000000..15a6d55c0 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/restproxy_types.go @@ -0,0 +1,119 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + dbapi "kubedb.dev/apimachinery/apis/kubedb/v1" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + kmapi "kmodules.xyz/client-go/api/v1" + ofst "kmodules.xyz/offshoot-api/api/v2" +) + +const ( + ResourceCodeRestProxy = "krp" + ResourceKindRestProxy = "RestProxy" + ResourceSingularRestProxy = "restproxy" + ResourcePluralRestProxy = "restproxies" +) + +// RestProxy defines a runtime server system that stores a specific set of artifacts as files. + +// +genclient +// +k8s:openapi-gen=true +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// +kubebuilder:object:root=true +// +kubebuilder:subresource:status +// +kubebuilder:resource:shortName=krp,scope=Namespaced +// +kubebuilder:printcolumn:name="Type",type="string",JSONPath=".apiVersion" +// +kubebuilder:printcolumn:name="Version",type="string",JSONPath=".spec.version" +// +kubebuilder:printcolumn:name="Kafka",type="string",JSONPath=".spec.kafkaRef.name" +// +kubebuilder:printcolumn:name="Status",type="string",JSONPath=".status.phase" +// +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp" +type RestProxy struct { + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty"` + + Spec RestProxySpec `json:"spec,omitempty"` + Status RestProxyStatus `json:"status,omitempty"` +} + +// RestProxySpec defines the desired state of RestProxy +type RestProxySpec struct { + // Version of RestProxy to be deployed. + Version string `json:"version"` + + // Number of instances to deploy for a rest proxy. + // +optional + Replicas *int32 `json:"replicas,omitempty"` + + // Kafka app-binding reference + // KafkaRef is a required field, where RestProxy will connect to Kafka + KafkaRef *kmapi.ObjectReference `json:"kafkaRef"` + + // PodTemplate is an optional configuration for pods used to expose database + // +optional + PodTemplate ofst.PodTemplateSpec `json:"podTemplate,omitempty"` + + // ServiceTemplates is an optional configuration for services used to expose database + // +optional + ServiceTemplates []dbapi.NamedServiceTemplateSpec `json:"serviceTemplates,omitempty"` + + // DeletionPolicy controls the delete operation for database + // +optional + DeletionPolicy dbapi.DeletionPolicy `json:"deletionPolicy,omitempty"` + + // HealthChecker defines attributes of the health checker + // +optional + // +kubebuilder:default={periodSeconds: 10, timeoutSeconds: 10, failureThreshold: 3} + HealthChecker kmapi.HealthCheckSpec `json:"healthChecker"` +} + +// RestProxyStatus defines the observed state of RestProxy +type RestProxyStatus struct { + // Specifies the current phase of the database + // +optional + Phase RestProxyPhase `json:"phase,omitempty"` + // observedGeneration is the most recent generation observed for this resource. It corresponds to the + // resource's generation, which is updated on mutation by the API Server. + // +optional + ObservedGeneration int64 `json:"observedGeneration,omitempty"` + // Conditions applied to the database, such as approval or denial. + // +optional + Conditions []kmapi.Condition `json:"conditions,omitempty"` +} + +// +kubebuilder:validation:Enum=Provisioning;Ready;NotReady;Critical;Unknown +type RestProxyPhase string + +const ( + RestProxyPhaseProvisioning RestProxyPhase = "Provisioning" + RestProxyPhaseReady RestProxyPhase = "Ready" + RestProxyPhaseNotReady RestProxyPhase = "NotReady" + RestProxyPhaseCritical RestProxyPhase = "Critical" + RestProxyPhaseUnknown RestProxyPhase = "Unknown" +) + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// RestProxyList contains a list of RestProxy +type RestProxyList struct { + metav1.TypeMeta `json:",inline"` + metav1.ListMeta `json:"metadata,omitempty"` + Items []RestProxy `json:"items"` +} diff --git a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/restproxy_webhook.go b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/restproxy_webhook.go new file mode 100644 index 000000000..7568eb19b --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/restproxy_webhook.go @@ -0,0 +1,186 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "context" + "fmt" + + catalog "kubedb.dev/apimachinery/apis/catalog/v1alpha1" + dbapi "kubedb.dev/apimachinery/apis/kubedb/v1" + + "github.com/pkg/errors" + apierrors "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/types" + "k8s.io/apimachinery/pkg/util/validation/field" + coreutil "kmodules.xyz/client-go/core/v1" + logf "sigs.k8s.io/controller-runtime/pkg/log" + "sigs.k8s.io/controller-runtime/pkg/webhook" + "sigs.k8s.io/controller-runtime/pkg/webhook/admission" +) + +// log is for logging in this package. +var restproxylog = logf.Log.WithName("restproxy-resource") + +var _ webhook.Defaulter = &RestProxy{} + +// Default implements webhook.Defaulter so a webhook will be registered for the type +func (k *RestProxy) Default() { + if k == nil { + return + } + restproxylog.Info("default", "name", k.Name) + k.SetDefaults() +} + +var _ webhook.Validator = &RestProxy{} + +// ValidateCreate implements webhook.Validator so a webhook will be registered for the type +func (k *RestProxy) ValidateCreate() (admission.Warnings, error) { + restproxylog.Info("validate create", "name", k.Name) + allErr := k.ValidateCreateOrUpdate() + if len(allErr) == 0 { + return nil, nil + } + return nil, apierrors.NewInvalid(schema.GroupKind{Group: "kafka.kubedb.com", Kind: "RestProxy"}, k.Name, allErr) +} + +// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type +func (k *RestProxy) ValidateUpdate(old runtime.Object) (admission.Warnings, error) { + restproxylog.Info("validate update", "name", k.Name) + allErr := k.ValidateCreateOrUpdate() + if len(allErr) == 0 { + return nil, nil + } + return nil, apierrors.NewInvalid(schema.GroupKind{Group: "kafka.kubedb.com", Kind: "RestProxy"}, k.Name, allErr) +} + +// ValidateDelete implements webhook.Validator so a webhook will be registered for the type +func (k *RestProxy) ValidateDelete() (admission.Warnings, error) { + restproxylog.Info("validate delete", "name", k.Name) + + var allErr field.ErrorList + if k.Spec.DeletionPolicy == dbapi.DeletionPolicyDoNotTerminate { + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("deletionPolicy"), + k.Name, + "Can not delete as deletionPolicy is set to \"DoNotTerminate\"")) + return nil, apierrors.NewInvalid(schema.GroupKind{Group: "kafka.kubedb.com", Kind: "RestProxy"}, k.Name, allErr) + } + return nil, nil +} + +func (k *RestProxy) ValidateCreateOrUpdate() field.ErrorList { + var allErr field.ErrorList + + err := k.validateVersion() + if err != nil { + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("version"), + k.Name, + err.Error())) + return allErr + } + + if k.Spec.DeletionPolicy == dbapi.DeletionPolicyHalt { + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("deletionPolicy"), + k.Name, + "DeletionPolicyHalt is not supported for RestProxy")) + } + + // number of replicas can not be 0 or less + if k.Spec.Replicas != nil && *k.Spec.Replicas <= 0 { + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("replicas"), + k.Name, + "number of replicas can not be 0 or less")) + } + + err = k.validateVolumes() + if err != nil { + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("podTemplate").Child("spec").Child("volumes"), + k.Name, + err.Error())) + } + + err = k.validateContainerVolumeMountPaths() + if err != nil { + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("podTemplate").Child("spec").Child("containers").Child("volumeMounts"), + k.Name, + err.Error())) + } + + if len(allErr) == 0 { + return nil + } + return allErr +} + +func (k *RestProxy) validateVersion() error { + ksrVersion := &catalog.SchemaRegistryVersion{} + err := DefaultClient.Get(context.TODO(), types.NamespacedName{Name: k.Spec.Version}, ksrVersion) + if err != nil { + return errors.New("version not supported") + } + if ksrVersion.Spec.Distribution != catalog.SchemaRegistryDistroAiven { + return errors.New(fmt.Sprintf("Distribution %s is not supported, only supported distribution is Aiven", ksrVersion.Spec.Distribution)) + } + return nil +} + +var restProxyReservedVolumes = []string{ + KafkaClientCertVolumeName, + RestProxyOperatorVolumeConfig, +} + +func (k *RestProxy) validateVolumes() error { + if k.Spec.PodTemplate.Spec.Volumes == nil { + return nil + } + rsv := make([]string, len(restProxyReservedVolumes)) + copy(rsv, restProxyReservedVolumes) + volumes := k.Spec.PodTemplate.Spec.Volumes + for _, rv := range rsv { + for _, ugv := range volumes { + if ugv.Name == rv { + return errors.New("Cannot use a reserve volume name: " + rv) + } + } + } + return nil +} + +var restProxyReservedVolumeMountPaths = []string{ + KafkaClientCertDir, + RestProxyOperatorVolumeConfig, +} + +func (k *RestProxy) validateContainerVolumeMountPaths() error { + container := coreutil.GetContainerByName(k.Spec.PodTemplate.Spec.Containers, RestProxyContainerName) + if container == nil { + return errors.New("container not found") + } + rPaths := restProxyReservedVolumeMountPaths + volumeMountPaths := container.VolumeMounts + for _, rvm := range rPaths { + for _, ugv := range volumeMountPaths { + if ugv.MountPath == rvm { + return errors.New("Cannot use a reserve volume mount path: " + rvm) + } + } + } + return nil +} diff --git a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/schemaregistry_webhook.go b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/schemaregistry_webhook.go index fca54d3e1..e3d76578c 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/schemaregistry_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/schemaregistry_webhook.go @@ -85,9 +85,9 @@ func (k *SchemaRegistry) ValidateDelete() (admission.Warnings, error) { var allErr field.ErrorList if k.Spec.DeletionPolicy == dbapi.DeletionPolicyDoNotTerminate { - allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("terminationPolicy"), + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("deletionPolicy"), k.Name, - "Can not delete as terminationPolicy is set to \"DoNotTerminate\"")) + "Can not delete as deletionPolicy is set to \"DoNotTerminate\"")) return nil, apierrors.NewInvalid(schema.GroupKind{Group: "kafka.kubedb.com", Kind: "SchemaRegistry"}, k.Name, allErr) } return nil, nil @@ -97,7 +97,7 @@ func (k *SchemaRegistry) ValidateCreateOrUpdate() field.ErrorList { var allErr field.ErrorList if k.Spec.DeletionPolicy == dbapi.DeletionPolicyHalt { - allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("terminationPolicy"), + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("deletionPolicy"), k.Name, "DeletionPolicyHalt is not supported for SchemaRegistry")) } diff --git a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/zz_generated.deepcopy.go b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/zz_generated.deepcopy.go index 245e96b0b..b333a0f4b 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/zz_generated.deepcopy.go +++ b/vendor/kubedb.dev/apimachinery/apis/kafka/v1alpha1/zz_generated.deepcopy.go @@ -310,6 +310,146 @@ func (in *ConnectorStatus) DeepCopy() *ConnectorStatus { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RestProxy) DeepCopyInto(out *RestProxy) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RestProxy. +func (in *RestProxy) DeepCopy() *RestProxy { + if in == nil { + return nil + } + out := new(RestProxy) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *RestProxy) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RestProxyApp) DeepCopyInto(out *RestProxyApp) { + *out = *in + if in.RestProxy != nil { + in, out := &in.RestProxy, &out.RestProxy + *out = new(RestProxy) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RestProxyApp. +func (in *RestProxyApp) DeepCopy() *RestProxyApp { + if in == nil { + return nil + } + out := new(RestProxyApp) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RestProxyList) DeepCopyInto(out *RestProxyList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]RestProxy, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RestProxyList. +func (in *RestProxyList) DeepCopy() *RestProxyList { + if in == nil { + return nil + } + out := new(RestProxyList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *RestProxyList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RestProxySpec) DeepCopyInto(out *RestProxySpec) { + *out = *in + if in.Replicas != nil { + in, out := &in.Replicas, &out.Replicas + *out = new(int32) + **out = **in + } + if in.KafkaRef != nil { + in, out := &in.KafkaRef, &out.KafkaRef + *out = new(v1.ObjectReference) + **out = **in + } + in.PodTemplate.DeepCopyInto(&out.PodTemplate) + if in.ServiceTemplates != nil { + in, out := &in.ServiceTemplates, &out.ServiceTemplates + *out = make([]kubedbv1.NamedServiceTemplateSpec, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + in.HealthChecker.DeepCopyInto(&out.HealthChecker) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RestProxySpec. +func (in *RestProxySpec) DeepCopy() *RestProxySpec { + if in == nil { + return nil + } + out := new(RestProxySpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *RestProxyStatus) DeepCopyInto(out *RestProxyStatus) { + *out = *in + if in.Conditions != nil { + in, out := &in.Conditions, &out.Conditions + *out = make([]v1.Condition, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RestProxyStatus. +func (in *RestProxyStatus) DeepCopy() *RestProxyStatus { + if in == nil { + return nil + } + out := new(RestProxyStatus) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SchemaRegistry) DeepCopyInto(out *SchemaRegistry) { *out = *in diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/constants.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/constants.go index 78a28e577..d732cfd24 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/constants.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/constants.go @@ -689,6 +689,10 @@ const ( DatabaseWriteAccess = "DatabaseWriteAccess" // check dependencies are ready DatabaseDependencyReady = "DatabaseDependencyReady" + // update config secret for backup in solr + PatchConfigSecretUpdateForBackup = "PatchConfigSecretUpdatesForBackup" + // sync db to update configuration + SyncDatabaseForConfigurationUpdate = "SyncDatabaseForConfigurationUpdate" // Condition reasons DataRestoreStartedByExternalInitializer = "DataRestoreStartedByExternalInitializer" @@ -923,6 +927,15 @@ const ( SolrConfAllowPathsValue = "" SolrConfSolrCloudKey = "solrcloud" SolrConfShardHandlerFactoryKey = "shardHandlerFactory" + + ProxyDeploymentName = "s3proxy" + ProxyServiceName = "proxy-svc" + ProxySecretName = "proxy-env" + ProxyImage = "andrewgaul/s3proxy" + ProxyPortName = "http" + ProxyPortNumber = 80 + ProxyContainerName = "proxy" + ProxyLabelsApp = "app" ) // =========================== Druid Constants ============================ diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1/elasticsearch_helpers.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1/elasticsearch_helpers.go index ab4993326..a8a4ac291 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1/elasticsearch_helpers.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1/elasticsearch_helpers.go @@ -389,7 +389,7 @@ func (e Elasticsearch) StatsServiceLabels() map[string]string { return e.ServiceLabels(StatsServiceAlias, map[string]string{kubedb.LabelRole: kubedb.RoleStats}) } -func (e Elasticsearch) setContainerSecurityContextDefaults(esVersion *catalog.ElasticsearchVersion, podTemplate *ofstv2.PodTemplateSpec) { +func (e Elasticsearch) setContainerSecurityContextDefaults(esVersion *catalog.ElasticsearchVersion, podTemplate *ofstv2.PodTemplateSpec, containerName string) { if podTemplate == nil { return } @@ -400,17 +400,27 @@ func (e Elasticsearch) setContainerSecurityContextDefaults(esVersion *catalog.El if podTemplate.Spec.SecurityContext.FSGroup == nil { podTemplate.Spec.SecurityContext.FSGroup = esVersion.Spec.SecurityContext.RunAsUser } - dbContainer := core_util.GetContainerByName(podTemplate.Spec.Containers, kubedb.ElasticsearchContainerName) - if dbContainer == nil { - dbContainer = &core.Container{ - Name: kubedb.ElasticsearchContainerName, + getContainers := func() []core.Container { + if containerName == kubedb.ElasticsearchInitConfigMergerContainerName { + return podTemplate.Spec.InitContainers } + return podTemplate.Spec.Containers } - if dbContainer.SecurityContext == nil { - dbContainer.SecurityContext = &core.SecurityContext{} + container := core_util.GetContainerByName(getContainers(), containerName) + if container == nil { + container = &core.Container{ + Name: containerName, + } + } + if container.SecurityContext == nil { + container.SecurityContext = &core.SecurityContext{} + } + e.assignDefaultContainerSecurityContext(esVersion, container.SecurityContext) + if containerName == kubedb.ElasticsearchInitConfigMergerContainerName { + podTemplate.Spec.InitContainers = core_util.UpsertContainer(podTemplate.Spec.InitContainers, *container) + return } - e.assignDefaultContainerSecurityContext(esVersion, dbContainer.SecurityContext) - podTemplate.Spec.Containers = core_util.UpsertContainer(podTemplate.Spec.Containers, *dbContainer) + podTemplate.Spec.Containers = core_util.UpsertContainer(podTemplate.Spec.Containers, *container) } func (e Elasticsearch) assignDefaultContainerSecurityContext(esVersion *catalog.ElasticsearchVersion, sc *core.SecurityContext) { @@ -460,7 +470,8 @@ func (e *Elasticsearch) SetDefaults(esVersion *catalog.ElasticsearchVersion) { if e.Spec.Topology.Ingest.Suffix == "" { e.Spec.Topology.Ingest.Suffix = string(ElasticsearchNodeRoleTypeIngest) } - e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.Ingest.PodTemplate) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.Ingest.PodTemplate, kubedb.ElasticsearchContainerName) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.Ingest.PodTemplate, kubedb.ElasticsearchInitConfigMergerContainerName) dbContainer := core_util.GetContainerByName(e.Spec.Topology.Ingest.PodTemplate.Spec.Containers, kubedb.ElasticsearchContainerName) if dbContainer != nil && (dbContainer.Resources.Requests == nil && dbContainer.Resources.Limits == nil) { apis.SetDefaultResourceLimits(&dbContainer.Resources, kubedb.DefaultResourcesMemoryIntensive) @@ -477,7 +488,8 @@ func (e *Elasticsearch) SetDefaults(esVersion *catalog.ElasticsearchVersion) { if e.Spec.Topology.Master.Suffix == "" { e.Spec.Topology.Master.Suffix = string(ElasticsearchNodeRoleTypeMaster) } - e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.Master.PodTemplate) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.Master.PodTemplate, kubedb.ElasticsearchContainerName) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.Master.PodTemplate, kubedb.ElasticsearchInitConfigMergerContainerName) dbContainer = core_util.GetContainerByName(e.Spec.Topology.Master.PodTemplate.Spec.Containers, kubedb.ElasticsearchContainerName) if dbContainer != nil && (dbContainer.Resources.Requests == nil && dbContainer.Resources.Limits == nil) { apis.SetDefaultResourceLimits(&dbContainer.Resources, kubedb.DefaultResourcesMemoryIntensive) @@ -496,7 +508,8 @@ func (e *Elasticsearch) SetDefaults(esVersion *catalog.ElasticsearchVersion) { if e.Spec.Topology.Data.Suffix == "" { e.Spec.Topology.Data.Suffix = string(ElasticsearchNodeRoleTypeData) } - e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.Data.PodTemplate) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.Data.PodTemplate, kubedb.ElasticsearchContainerName) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.Data.PodTemplate, kubedb.ElasticsearchInitConfigMergerContainerName) dbContainer = core_util.GetContainerByName(e.Spec.Topology.Data.PodTemplate.Spec.Containers, kubedb.ElasticsearchContainerName) if dbContainer != nil && (dbContainer.Resources.Requests == nil && dbContainer.Resources.Limits == nil) { apis.SetDefaultResourceLimits(&dbContainer.Resources, kubedb.DefaultResourcesMemoryIntensive) @@ -515,7 +528,8 @@ func (e *Elasticsearch) SetDefaults(esVersion *catalog.ElasticsearchVersion) { if e.Spec.Topology.DataHot.Suffix == "" { e.Spec.Topology.DataHot.Suffix = string(ElasticsearchNodeRoleTypeDataHot) } - e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataHot.PodTemplate) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataHot.PodTemplate, kubedb.ElasticsearchContainerName) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataHot.PodTemplate, kubedb.ElasticsearchInitConfigMergerContainerName) dbContainer = core_util.GetContainerByName(e.Spec.Topology.DataHot.PodTemplate.Spec.Containers, kubedb.ElasticsearchContainerName) if dbContainer != nil && (dbContainer.Resources.Requests == nil && dbContainer.Resources.Limits == nil) { apis.SetDefaultResourceLimits(&dbContainer.Resources, kubedb.DefaultResourcesMemoryIntensive) @@ -534,7 +548,8 @@ func (e *Elasticsearch) SetDefaults(esVersion *catalog.ElasticsearchVersion) { if e.Spec.Topology.DataWarm.Suffix == "" { e.Spec.Topology.DataWarm.Suffix = string(ElasticsearchNodeRoleTypeDataWarm) } - e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataWarm.PodTemplate) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataWarm.PodTemplate, kubedb.ElasticsearchContainerName) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataWarm.PodTemplate, kubedb.ElasticsearchInitConfigMergerContainerName) dbContainer = core_util.GetContainerByName(e.Spec.Topology.DataWarm.PodTemplate.Spec.Containers, kubedb.ElasticsearchContainerName) if dbContainer != nil && (dbContainer.Resources.Requests == nil && dbContainer.Resources.Limits == nil) { apis.SetDefaultResourceLimits(&dbContainer.Resources, kubedb.DefaultResourcesMemoryIntensive) @@ -553,7 +568,8 @@ func (e *Elasticsearch) SetDefaults(esVersion *catalog.ElasticsearchVersion) { if e.Spec.Topology.DataCold.Suffix == "" { e.Spec.Topology.DataCold.Suffix = string(ElasticsearchNodeRoleTypeDataCold) } - e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataCold.PodTemplate) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataCold.PodTemplate, kubedb.ElasticsearchContainerName) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataCold.PodTemplate, kubedb.ElasticsearchInitConfigMergerContainerName) dbContainer = core_util.GetContainerByName(e.Spec.Topology.DataCold.PodTemplate.Spec.Containers, kubedb.ElasticsearchContainerName) if dbContainer != nil && (dbContainer.Resources.Requests == nil && dbContainer.Resources.Limits == nil) { apis.SetDefaultResourceLimits(&dbContainer.Resources, kubedb.DefaultResourcesMemoryIntensive) @@ -572,7 +588,8 @@ func (e *Elasticsearch) SetDefaults(esVersion *catalog.ElasticsearchVersion) { if e.Spec.Topology.DataFrozen.Suffix == "" { e.Spec.Topology.DataFrozen.Suffix = string(ElasticsearchNodeRoleTypeDataFrozen) } - e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataFrozen.PodTemplate) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataFrozen.PodTemplate, kubedb.ElasticsearchContainerName) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataFrozen.PodTemplate, kubedb.ElasticsearchInitConfigMergerContainerName) dbContainer = core_util.GetContainerByName(e.Spec.Topology.DataFrozen.PodTemplate.Spec.Containers, kubedb.ElasticsearchContainerName) if dbContainer != nil && (dbContainer.Resources.Requests == nil && dbContainer.Resources.Limits == nil) { apis.SetDefaultResourceLimits(&dbContainer.Resources, kubedb.DefaultResourcesMemoryIntensive) @@ -591,7 +608,8 @@ func (e *Elasticsearch) SetDefaults(esVersion *catalog.ElasticsearchVersion) { if e.Spec.Topology.DataContent.Suffix == "" { e.Spec.Topology.DataContent.Suffix = string(ElasticsearchNodeRoleTypeDataContent) } - e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataContent.PodTemplate) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataContent.PodTemplate, kubedb.ElasticsearchContainerName) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.DataContent.PodTemplate, kubedb.ElasticsearchInitConfigMergerContainerName) dbContainer = core_util.GetContainerByName(e.Spec.Topology.DataContent.PodTemplate.Spec.Containers, kubedb.ElasticsearchContainerName) if dbContainer != nil && (dbContainer.Resources.Requests == nil && dbContainer.Resources.Limits == nil) { apis.SetDefaultResourceLimits(&dbContainer.Resources, kubedb.DefaultResourcesMemoryIntensive) @@ -610,7 +628,8 @@ func (e *Elasticsearch) SetDefaults(esVersion *catalog.ElasticsearchVersion) { if e.Spec.Topology.ML.Suffix == "" { e.Spec.Topology.ML.Suffix = string(ElasticsearchNodeRoleTypeML) } - e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.ML.PodTemplate) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.ML.PodTemplate, kubedb.ElasticsearchContainerName) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.ML.PodTemplate, kubedb.ElasticsearchInitConfigMergerContainerName) dbContainer = core_util.GetContainerByName(e.Spec.Topology.ML.PodTemplate.Spec.Containers, kubedb.ElasticsearchContainerName) if dbContainer != nil && (dbContainer.Resources.Requests == nil && dbContainer.Resources.Limits == nil) { apis.SetDefaultResourceLimits(&dbContainer.Resources, kubedb.DefaultResourcesMemoryIntensive) @@ -629,7 +648,8 @@ func (e *Elasticsearch) SetDefaults(esVersion *catalog.ElasticsearchVersion) { if e.Spec.Topology.Transform.Suffix == "" { e.Spec.Topology.Transform.Suffix = string(ElasticsearchNodeRoleTypeTransform) } - e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.Transform.PodTemplate) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.Transform.PodTemplate, kubedb.ElasticsearchContainerName) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.Topology.Transform.PodTemplate, kubedb.ElasticsearchInitConfigMergerContainerName) dbContainer = core_util.GetContainerByName(e.Spec.Topology.Transform.PodTemplate.Spec.Containers, kubedb.ElasticsearchContainerName) if dbContainer != nil && (dbContainer.Resources.Requests == nil && dbContainer.Resources.Limits == nil) { apis.SetDefaultResourceLimits(&dbContainer.Resources, kubedb.DefaultResourcesMemoryIntensive) @@ -643,7 +663,8 @@ func (e *Elasticsearch) SetDefaults(esVersion *catalog.ElasticsearchVersion) { } } else { - e.setContainerSecurityContextDefaults(esVersion, &e.Spec.PodTemplate) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.PodTemplate, kubedb.ElasticsearchContainerName) + e.setContainerSecurityContextDefaults(esVersion, &e.Spec.PodTemplate, kubedb.ElasticsearchInitConfigMergerContainerName) dbContainer := core_util.GetContainerByName(e.Spec.PodTemplate.Spec.Containers, kubedb.ElasticsearchContainerName) if dbContainer != nil && (dbContainer.Resources.Requests == nil && dbContainer.Resources.Limits == nil) { apis.SetDefaultResourceLimits(&dbContainer.Resources, kubedb.DefaultResourcesMemoryIntensive) diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha1/conversion.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha1/conversion.go index d308d6ecc..b5a0a2b13 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha1/conversion.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha1/conversion.go @@ -280,7 +280,7 @@ func Convert_v1alpha1_EtcdSpec_To_v1alpha2_EtcdSpec(in *EtcdSpec, out *v1alpha2. }) } // WARNING: in.UpdateStrategy requires manual conversion: does not exist in peer-type - out.TerminationPolicy = v1alpha2.TerminationPolicy(in.TerminationPolicy) + out.DeletionPolicy = v1alpha2.TerminationPolicy(in.TerminationPolicy) return nil } @@ -304,7 +304,7 @@ func Convert_v1alpha2_EtcdSpec_To_v1alpha1_EtcdSpec(in *v1alpha2.EtcdSpec, out * out.PodTemplate = in.PodTemplate // WARNING: in.ServiceTemplates requires manual conversion: does not exist in peer-type // WARNING: in.Halted requires manual conversion: does not exist in peer-type - out.TerminationPolicy = TerminationPolicy(in.TerminationPolicy) + out.TerminationPolicy = TerminationPolicy(in.DeletionPolicy) return nil } diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha1/zz_generated.conversion.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha1/zz_generated.conversion.go index 7aa2f92c7..5202c5cc8 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha1/zz_generated.conversion.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha1/zz_generated.conversion.go @@ -896,7 +896,7 @@ func autoConvert_v1alpha1_EtcdSpec_To_v1alpha2_EtcdSpec(in *EtcdSpec, out *v1alp out.PodTemplate = in.PodTemplate // WARNING: in.ServiceTemplate requires manual conversion: does not exist in peer-type // WARNING: in.UpdateStrategy requires manual conversion: does not exist in peer-type - out.TerminationPolicy = v1alpha2.TerminationPolicy(in.TerminationPolicy) + out.DeletionPolicy = v1alpha2.TerminationPolicy(in.TerminationPolicy) return nil } @@ -920,7 +920,7 @@ func autoConvert_v1alpha2_EtcdSpec_To_v1alpha1_EtcdSpec(in *v1alpha2.EtcdSpec, o out.PodTemplate = in.PodTemplate // WARNING: in.ServiceTemplates requires manual conversion: does not exist in peer-type // WARNING: in.Halted requires manual conversion: does not exist in peer-type - out.TerminationPolicy = TerminationPolicy(in.TerminationPolicy) + out.TerminationPolicy = TerminationPolicy(in.DeletionPolicy) return nil } diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/clickhouse_helpers.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/clickhouse_helpers.go index b7627aa52..e82cf96fa 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/clickhouse_helpers.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/clickhouse_helpers.go @@ -30,6 +30,7 @@ import ( "gomodules.xyz/pointer" core "k8s.io/api/core/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/labels" "k8s.io/apimachinery/pkg/types" "k8s.io/klog/v2" "kmodules.xyz/client-go/apiextensions" @@ -38,6 +39,7 @@ import ( "kmodules.xyz/client-go/policy/secomp" appcat "kmodules.xyz/custom-resources/apis/appcatalog/v1alpha1" ofst "kmodules.xyz/offshoot-api/api/v2" + pslister "kubeops.dev/petset/client/listers/apps/v1" ) type ClickhouseApp struct { @@ -269,7 +271,7 @@ func (c *ClickHouse) SetDefaults() { } } -func (r *ClickHouse) setDefaultContainerSecurityContext(chVersion *catalog.ClickHouseVersion, podTemplate *ofst.PodTemplateSpec) { +func (c *ClickHouse) setDefaultContainerSecurityContext(chVersion *catalog.ClickHouseVersion, podTemplate *ofst.PodTemplateSpec) { if podTemplate == nil { return } @@ -290,7 +292,7 @@ func (r *ClickHouse) setDefaultContainerSecurityContext(chVersion *catalog.Click if container.SecurityContext == nil { container.SecurityContext = &core.SecurityContext{} } - r.assignDefaultContainerSecurityContext(chVersion, container.SecurityContext) + c.assignDefaultContainerSecurityContext(chVersion, container.SecurityContext) initContainer := coreutil.GetContainerByName(podTemplate.Spec.InitContainers, kubedb.ClickHouseInitContainerName) if initContainer == nil { @@ -302,10 +304,10 @@ func (r *ClickHouse) setDefaultContainerSecurityContext(chVersion *catalog.Click if initContainer.SecurityContext == nil { initContainer.SecurityContext = &core.SecurityContext{} } - r.assignDefaultContainerSecurityContext(chVersion, initContainer.SecurityContext) + c.assignDefaultContainerSecurityContext(chVersion, initContainer.SecurityContext) } -func (r *ClickHouse) assignDefaultContainerSecurityContext(chVersion *catalog.ClickHouseVersion, rc *core.SecurityContext) { +func (c *ClickHouse) assignDefaultContainerSecurityContext(chVersion *catalog.ClickHouseVersion, rc *core.SecurityContext) { if rc.AllowPrivilegeEscalation == nil { rc.AllowPrivilegeEscalation = pointer.BoolP(false) } @@ -324,3 +326,16 @@ func (r *ClickHouse) assignDefaultContainerSecurityContext(chVersion *catalog.Cl rc.SeccompProfile = secomp.DefaultSeccompProfile() } } + +func (c *ClickHouse) ReplicasAreReady(lister pslister.PetSetLister) (bool, string, error) { + // Desire number of petSets + expectedItems := 0 + if c.Spec.ClusterTopology != nil { + for _, cluster := range c.Spec.ClusterTopology.Cluster { + expectedItems += int(*cluster.Shards) + } + } else { + expectedItems += 1 + } + return checkReplicasOfPetSet(lister.PetSets(c.Namespace), labels.SelectorFromSet(c.OffshootLabels()), expectedItems) +} diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/conversion.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/conversion.go index cbe892276..fd347d990 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/conversion.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/conversion.go @@ -662,11 +662,13 @@ func Convert_v1alpha2_RedisSpec_To_v1_RedisSpec(in *RedisSpec, out *v1.RedisSpec return err } - if out.Cluster == nil { - out.Cluster = &v1.RedisClusterSpec{} - } - if err := Convert_v1alpha2_RedisClusterSpec_To_v1_RedisClusterSpec(in.Cluster, out.Cluster, s); err != nil { - return err + if in.Mode == RedisModeCluster { + if out.Cluster == nil { + out.Cluster = &v1.RedisClusterSpec{} + } + if err := Convert_v1alpha2_RedisClusterSpec_To_v1_RedisClusterSpec(in.Cluster, out.Cluster, s); err != nil { + return err + } } out.Version = in.Version @@ -730,11 +732,13 @@ func Convert_v1_RedisSpec_To_v1alpha2_RedisSpec(in *v1.RedisSpec, out *RedisSpec return err } - if out.Cluster == nil { - out.Cluster = &RedisClusterSpec{} - } - if err := Convert_v1_RedisClusterSpec_To_v1alpha2_RedisClusterSpec(in.Cluster, out.Cluster, s); err != nil { - return err + if in.Mode == v1.RedisModeCluster { + if out.Cluster == nil { + out.Cluster = &RedisClusterSpec{} + } + if err := Convert_v1_RedisClusterSpec_To_v1alpha2_RedisClusterSpec(in.Cluster, out.Cluster, s); err != nil { + return err + } } out.Version = in.Version diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/druid_helpers.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/druid_helpers.go index 46eae241d..45fd8c665 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/druid_helpers.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/druid_helpers.go @@ -511,18 +511,25 @@ func (d *Druid) SetDefaults() { } } - if d.Spec.MetadataStorage == nil { - d.Spec.MetadataStorage = &MetadataStorage{} - } - if !d.Spec.MetadataStorage.ExternallyManaged { - if d.Spec.MetadataStorage.ObjectReference == nil { - d.Spec.MetadataStorage.ObjectReference = &kmapi.ObjectReference{} + d.SetDefaultsToMetadataStorage() + d.SetDefaultsToZooKeeperRef() + + if d.Spec.Monitor != nil { + if d.Spec.Monitor.Prometheus == nil { + d.Spec.Monitor.Prometheus = &mona.PrometheusSpec{} } - d.Spec.MetadataStorage.Name = d.GetMetadataStorageName() + if d.Spec.Monitor.Prometheus != nil && d.Spec.Monitor.Prometheus.Exporter.Port == 0 { + d.Spec.Monitor.Prometheus.Exporter.Port = kubedb.DruidExporterPort + } + d.Spec.Monitor.SetDefaults() } - if d.Spec.MetadataStorage.Namespace == "" { - d.Spec.MetadataStorage.Namespace = d.Namespace +} + +func (d *Druid) SetDefaultsToMetadataStorage() { + if d.Spec.MetadataStorage == nil { + d.Spec.MetadataStorage = &MetadataStorage{} } + d.SetMetadataStorageObjectRef() if d.Spec.MetadataStorage.LinkedDB == "" { d.Spec.MetadataStorage.LinkedDB = "druid" } @@ -541,12 +548,6 @@ func (d *Druid) SetDefaults() { d.Spec.MetadataStorage.Type = DruidMetadataStorageMySQL } } - if !d.Spec.MetadataStorage.ExternallyManaged { - if d.Spec.MetadataStorage.ObjectReference == nil { - d.Spec.MetadataStorage.ObjectReference = &kmapi.ObjectReference{} - } - d.Spec.MetadataStorage.Name = d.GetMetadataStorageName() - } if d.Spec.MetadataStorage.Version == nil { var defaultVersion string @@ -557,33 +558,17 @@ func (d *Druid) SetDefaults() { } d.Spec.MetadataStorage.Version = &defaultVersion } +} +func (d *Druid) SetDefaultsToZooKeeperRef() { if d.Spec.ZookeeperRef == nil { d.Spec.ZookeeperRef = &ZookeeperRef{} } - if !d.Spec.ZookeeperRef.ExternallyManaged { - if d.Spec.ZookeeperRef.ObjectReference == nil { - d.Spec.ZookeeperRef.ObjectReference = &kmapi.ObjectReference{} - } - if d.Spec.ZookeeperRef.Name == "" { - d.Spec.ZookeeperRef.Name = d.GetZooKeeperName() - } - if d.Spec.ZookeeperRef.Namespace == "" { - d.Spec.ZookeeperRef.Namespace = d.Namespace - } + d.SetZooKeeperObjectRef() + if d.Spec.ZookeeperRef.Version == nil { defaultVersion := "3.7.2" d.Spec.ZookeeperRef.Version = &defaultVersion } - - if d.Spec.Monitor != nil { - if d.Spec.Monitor.Prometheus == nil { - d.Spec.Monitor.Prometheus = &mona.PrometheusSpec{} - } - if d.Spec.Monitor.Prometheus != nil && d.Spec.Monitor.Prometheus.Exporter.Port == 0 { - d.Spec.Monitor.Prometheus.Exporter.Port = kubedb.DruidExporterPort - } - d.Spec.Monitor.SetDefaults() - } } func (d *Druid) GetDefaultPVC() *core.PersistentVolumeClaimSpec { @@ -700,6 +685,19 @@ func (d *Druid) GetAppBinding(name string, namespace string) (*appcat.AppBinding return appbinding, nil } +func (d *Druid) SetMetadataStorageObjectRef() { + if d.Spec.MetadataStorage.ObjectReference == nil { + d.Spec.MetadataStorage.ObjectReference = &kmapi.ObjectReference{} + } + if d.Spec.MetadataStorage.Name == "" { + d.Spec.MetadataStorage.ExternallyManaged = false + d.Spec.MetadataStorage.Name = d.GetMetadataStorageName() + } + if d.Spec.MetadataStorage.Namespace == "" { + d.Spec.MetadataStorage.Namespace = d.Namespace + } +} + func (d *Druid) GetMetadataStorageName() string { if d.Spec.MetadataStorage.Type == DruidMetadataStoragePostgreSQL { return d.OffShootName() + "-pg-metadata" @@ -707,6 +705,19 @@ func (d *Druid) GetMetadataStorageName() string { return d.OffShootName() + "-mysql-metadata" } +func (d *Druid) SetZooKeeperObjectRef() { + if d.Spec.ZookeeperRef.ObjectReference == nil { + d.Spec.ZookeeperRef.ObjectReference = &kmapi.ObjectReference{} + } + if d.Spec.ZookeeperRef.Name == "" { + d.Spec.ZookeeperRef.ExternallyManaged = false + d.Spec.ZookeeperRef.Name = d.GetZooKeeperName() + } + if d.Spec.ZookeeperRef.Namespace == "" { + d.Spec.ZookeeperRef.Namespace = d.Namespace + } +} + func (d *Druid) GetZooKeeperName() string { return d.OffShootName() + "-zk" } diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/druid_webhook.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/druid_webhook.go index cf62fbf71..dfc662898 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/druid_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/druid_webhook.go @@ -126,16 +126,26 @@ func (d *Druid) validateCreateOrUpdate() field.ErrorList { } } - if d.Spec.MetadataStorage == nil { - allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("metadataStorage"), + if d.Spec.MetadataStorage.Name == "" { + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("metadataStorage").Child("name"), d.Name, - "spec.metadataStorage is missing")) - } else { - if d.Spec.MetadataStorage.ExternallyManaged && d.Spec.MetadataStorage.Name == "" { - allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("metadataStorage").Child("name"), - d.Name, - "spec.metadataStorage.name can not be empty when d.Spec.MetadataStorage.ExternallyManaged is true")) - } + "spec.metadataStorage.name can not be empty")) + } + if d.Spec.MetadataStorage.Namespace == "" { + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("metadataStorage").Child("namespace"), + d.Name, + "spec.metadataStorage.namespace can not be empty")) + } + + if d.Spec.ZookeeperRef.Name == "" { + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("zookeeperRef").Child("name"), + d.Name, + "spec.zookeeperRef.name can not be empty")) + } + if d.Spec.ZookeeperRef.Namespace == "" { + allErr = append(allErr, field.Invalid(field.NewPath("spec").Child("zookeeperRef").Child("namespace"), + d.Name, + "spec.zookeeperRef.namespace can not be empty")) } if d.Spec.Topology == nil { diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/etcd_helpers.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/etcd_helpers.go index 60f3bb472..d0708704c 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/etcd_helpers.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/etcd_helpers.go @@ -181,8 +181,8 @@ func (e *Etcd) SetDefaults() { if e.Spec.StorageType == "" { e.Spec.StorageType = StorageTypeDurable } - if e.Spec.TerminationPolicy == "" { - e.Spec.TerminationPolicy = TerminationPolicyDelete + if e.Spec.DeletionPolicy == "" { + e.Spec.DeletionPolicy = TerminationPolicyDelete } e.Spec.Monitor.SetDefaults() diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/etcd_types.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/etcd_types.go index caa57e978..cbf151b15 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/etcd_types.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/etcd_types.go @@ -90,9 +90,9 @@ type EtcdSpec struct { // +optional Halted bool `json:"halted,omitempty"` - // TerminationPolicy controls the delete operation for database + // DeletionPolicy controls the delete operation for database // +optional - TerminationPolicy TerminationPolicy `json:"terminationPolicy,omitempty"` + DeletionPolicy TerminationPolicy `json:"deletionPolicy,omitempty"` } type TLSPolicy struct { diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/mssqlserver_helpers.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/mssqlserver_helpers.go index bdbe5e3c9..6f0a31d49 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/mssqlserver_helpers.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/mssqlserver_helpers.go @@ -28,6 +28,7 @@ import ( "kubedb.dev/apimachinery/apis/kubedb" "kubedb.dev/apimachinery/crds" + promapi "github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring/v1" "gomodules.xyz/pointer" core "k8s.io/api/core/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1" @@ -40,6 +41,7 @@ import ( metautil "kmodules.xyz/client-go/meta" "kmodules.xyz/client-go/policy/secomp" appcat "kmodules.xyz/custom-resources/apis/appcatalog/v1alpha1" + mona "kmodules.xyz/monitoring-agent-api/api/v1" ofst "kmodules.xyz/offshoot-api/api/v2" pslister "kubeops.dev/petset/client/listers/apps/v1" ) @@ -120,6 +122,46 @@ func (m *MSSQLServer) OffshootSelectors(extraSelectors ...map[string]string) map return metautil.OverwriteKeys(selector, extraSelectors...) } +type mssqlserverStatsService struct { + *MSSQLServer +} + +func (m mssqlserverStatsService) GetNamespace() string { + return m.MSSQLServer.GetNamespace() +} + +func (m mssqlserverStatsService) ServiceName() string { + return m.OffshootName() + "-stats" +} + +func (m mssqlserverStatsService) ServiceMonitorName() string { + return m.ServiceName() +} + +func (m mssqlserverStatsService) ServiceMonitorAdditionalLabels() map[string]string { + return m.OffshootLabels() +} + +func (m mssqlserverStatsService) Path() string { + return kubedb.DefaultStatsPath +} + +func (m mssqlserverStatsService) Scheme() string { + return "" +} + +func (m mssqlserverStatsService) TLSConfig() *promapi.TLSConfig { + return nil +} + +func (m MSSQLServer) StatsService() mona.StatsAccessor { + return &mssqlserverStatsService{&m} +} + +func (m MSSQLServer) StatsServiceLabels() map[string]string { + return m.ServiceLabels(StatsServiceAlias, map[string]string{kubedb.LabelRole: kubedb.RoleStats}) +} + func (m *MSSQLServer) IsAvailabilityGroup() bool { return m.Spec.Topology != nil && m.Spec.Topology.Mode != nil && diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/mssqlserver_types.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/mssqlserver_types.go index 1a08746ec..afa369e30 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/mssqlserver_types.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/mssqlserver_types.go @@ -20,6 +20,7 @@ import ( core "k8s.io/api/core/v1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" kmapi "kmodules.xyz/client-go/api/v1" + mona "kmodules.xyz/monitoring-agent-api/api/v1" ofst "kmodules.xyz/offshoot-api/api/v2" ) @@ -129,6 +130,14 @@ type MSSQLServerSpec struct { // +optional // +kubebuilder:default={periodSeconds: 10, timeoutSeconds: 10, failureThreshold: 1} HealthChecker kmapi.HealthCheckSpec `json:"healthChecker"` + + // Monitor is used monitor database instance + // +optional + Monitor *mona.AgentSpec `json:"monitor,omitempty"` + + // Archiver controls database backup using Archiver CR + // +optional + Archiver *Archiver `json:"archiver,omitempty"` } // InternalAuthentication provides different way of endpoint authentication diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/openapi_generated.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/openapi_generated.go index f0cb1d2f0..6dc46a631 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/openapi_generated.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/openapi_generated.go @@ -667,6 +667,7 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.memcachedStatsService": schema_apimachinery_apis_kubedb_v1alpha2_memcachedStatsService(ref), "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.mongoDBApp": schema_apimachinery_apis_kubedb_v1alpha2_mongoDBApp(ref), "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.mongoDBStatsService": schema_apimachinery_apis_kubedb_v1alpha2_mongoDBStatsService(ref), + "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.mssqlserverStatsService": schema_apimachinery_apis_kubedb_v1alpha2_mssqlserverStatsService(ref), "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.mysqlApp": schema_apimachinery_apis_kubedb_v1alpha2_mysqlApp(ref), "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.mysqlStatsService": schema_apimachinery_apis_kubedb_v1alpha2_mysqlStatsService(ref), "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.perconaXtraDBApp": schema_apimachinery_apis_kubedb_v1alpha2_perconaXtraDBApp(ref), @@ -27409,9 +27410,9 @@ func schema_apimachinery_apis_kubedb_v1alpha2_EtcdSpec(ref common.ReferenceCallb Format: "", }, }, - "terminationPolicy": { + "deletionPolicy": { SchemaProps: spec.SchemaProps{ - Description: "TerminationPolicy controls the delete operation for database", + Description: "DeletionPolicy controls the delete operation for database", Type: []string{"string"}, Format: "", }, @@ -28752,12 +28753,24 @@ func schema_apimachinery_apis_kubedb_v1alpha2_MSSQLServerSpec(ref common.Referen Ref: ref("kmodules.xyz/client-go/api/v1.HealthCheckSpec"), }, }, + "monitor": { + SchemaProps: spec.SchemaProps{ + Description: "Monitor is used monitor database instance", + Ref: ref("kmodules.xyz/monitoring-agent-api/api/v1.AgentSpec"), + }, + }, + "archiver": { + SchemaProps: spec.SchemaProps{ + Description: "Archiver controls database backup using Archiver CR", + Ref: ref("kubedb.dev/apimachinery/apis/kubedb/v1alpha2.Archiver"), + }, + }, }, Required: []string{"version"}, }, }, Dependencies: []string{ - "k8s.io/api/core/v1.PersistentVolumeClaimSpec", "kmodules.xyz/client-go/api/v1.HealthCheckSpec", "kmodules.xyz/offshoot-api/api/v2.PodTemplateSpec", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.CoordinatorSpec", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.InitSpec", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.InternalAuthentication", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.MSSQLServerLeaderElectionConfig", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.MSSQLServerTopology", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.NamedServiceTemplateSpec", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.SQLServerTLSConfig", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.SecretReference"}, + "k8s.io/api/core/v1.PersistentVolumeClaimSpec", "kmodules.xyz/client-go/api/v1.HealthCheckSpec", "kmodules.xyz/monitoring-agent-api/api/v1.AgentSpec", "kmodules.xyz/offshoot-api/api/v2.PodTemplateSpec", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.Archiver", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.CoordinatorSpec", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.InitSpec", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.InternalAuthentication", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.MSSQLServerLeaderElectionConfig", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.MSSQLServerTopology", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.NamedServiceTemplateSpec", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.SQLServerTLSConfig", "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.SecretReference"}, } } @@ -34838,6 +34851,26 @@ func schema_apimachinery_apis_kubedb_v1alpha2_mongoDBStatsService(ref common.Ref } } +func schema_apimachinery_apis_kubedb_v1alpha2_mssqlserverStatsService(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "MSSQLServer": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/kubedb/v1alpha2.MSSQLServer"), + }, + }, + }, + Required: []string{"MSSQLServer"}, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/kubedb/v1alpha2.MSSQLServer"}, + } +} + func schema_apimachinery_apis_kubedb_v1alpha2_mysqlApp(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/solr_helpers.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/solr_helpers.go index 96fc283f9..0cccf01a2 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/solr_helpers.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/solr_helpers.go @@ -17,6 +17,7 @@ limitations under the License. package v1alpha2 import ( + "context" "fmt" "strings" @@ -30,6 +31,8 @@ import ( v1 "k8s.io/api/core/v1" meta "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/labels" + "k8s.io/apimachinery/pkg/types" + "k8s.io/klog/v2" "kmodules.xyz/client-go/apiextensions" coreutil "kmodules.xyz/client-go/core/v1" meta_util "kmodules.xyz/client-go/meta" @@ -230,7 +233,7 @@ func (s *Solr) PVCName(alias string) string { return meta_util.NameWithSuffix(s.Name, alias) } -func (s *Solr) SetDefaults(slVersion *catalog.SolrVersion) { +func (s *Solr) SetDefaults() { if s.Spec.DeletionPolicy == "" { s.Spec.DeletionPolicy = TerminationPolicyDelete } @@ -263,6 +266,15 @@ func (s *Solr) SetDefaults(slVersion *catalog.SolrVersion) { } } + var slVersion catalog.SolrVersion + err := DefaultClient.Get(context.TODO(), types.NamespacedName{ + Name: s.Spec.Version, + }, &slVersion) + if err != nil { + klog.Errorf("can't get the solr version object %s for %s \n", err.Error(), s.Spec.Version) + return + } + if s.Spec.Topology != nil { if s.Spec.Topology.Data != nil { if s.Spec.Topology.Data.Suffix == "" { @@ -275,7 +287,7 @@ func (s *Solr) SetDefaults(slVersion *catalog.SolrVersion) { s.Spec.Topology.Data.PodTemplate.Spec.SecurityContext = &v1.PodSecurityContext{} } s.Spec.Topology.Data.PodTemplate.Spec.SecurityContext.FSGroup = slVersion.Spec.SecurityContext.RunAsUser - s.setDefaultContainerSecurityContext(slVersion, &s.Spec.Topology.Data.PodTemplate) + s.setDefaultContainerSecurityContext(&slVersion, &s.Spec.Topology.Data.PodTemplate) s.setDefaultContainerResourceLimits(&s.Spec.Topology.Data.PodTemplate) } @@ -291,7 +303,7 @@ func (s *Solr) SetDefaults(slVersion *catalog.SolrVersion) { s.Spec.Topology.Overseer.PodTemplate.Spec.SecurityContext = &v1.PodSecurityContext{} } s.Spec.Topology.Overseer.PodTemplate.Spec.SecurityContext.FSGroup = slVersion.Spec.SecurityContext.RunAsUser - s.setDefaultContainerSecurityContext(slVersion, &s.Spec.Topology.Overseer.PodTemplate) + s.setDefaultContainerSecurityContext(&slVersion, &s.Spec.Topology.Overseer.PodTemplate) s.setDefaultContainerResourceLimits(&s.Spec.Topology.Overseer.PodTemplate) } @@ -306,7 +318,7 @@ func (s *Solr) SetDefaults(slVersion *catalog.SolrVersion) { s.Spec.Topology.Coordinator.PodTemplate.Spec.SecurityContext = &v1.PodSecurityContext{} } s.Spec.Topology.Coordinator.PodTemplate.Spec.SecurityContext.FSGroup = slVersion.Spec.SecurityContext.RunAsUser - s.setDefaultContainerSecurityContext(slVersion, &s.Spec.Topology.Coordinator.PodTemplate) + s.setDefaultContainerSecurityContext(&slVersion, &s.Spec.Topology.Coordinator.PodTemplate) s.setDefaultContainerResourceLimits(&s.Spec.Topology.Coordinator.PodTemplate) } } else { @@ -317,7 +329,7 @@ func (s *Solr) SetDefaults(slVersion *catalog.SolrVersion) { s.Spec.PodTemplate.Spec.SecurityContext = &v1.PodSecurityContext{} } s.Spec.PodTemplate.Spec.SecurityContext.FSGroup = slVersion.Spec.SecurityContext.RunAsUser - s.setDefaultContainerSecurityContext(slVersion, &s.Spec.PodTemplate) + s.setDefaultContainerSecurityContext(&slVersion, &s.Spec.PodTemplate) s.setDefaultContainerResourceLimits(&s.Spec.PodTemplate) } diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/solr_webhook.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/solr_webhook.go index e57ae3fa1..69c3d4ae7 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/solr_webhook.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/solr_webhook.go @@ -30,7 +30,6 @@ import ( "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/types" "k8s.io/apimachinery/pkg/util/validation/field" - "k8s.io/klog/v2" ofst "kmodules.xyz/offshoot-api/api/v2" logf "sigs.k8s.io/controller-runtime/pkg/log" "sigs.k8s.io/controller-runtime/pkg/webhook" @@ -49,14 +48,7 @@ func (s *Solr) Default() { } solrlog.Info("default", "name", s.Name) - slVersion := catalog.SolrVersion{} - err := DefaultClient.Get(context.TODO(), types.NamespacedName{Name: s.Spec.Version}, &slVersion) - if err != nil { - klog.Errorf("Version does not exist.") - return - } - - s.SetDefaults(&slVersion) + s.SetDefaults() } var _ webhook.Validator = &Solr{} diff --git a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/zz_generated.deepcopy.go b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/zz_generated.deepcopy.go index 115171a02..5fb64b38d 100644 --- a/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/zz_generated.deepcopy.go +++ b/vendor/kubedb.dev/apimachinery/apis/kubedb/v1alpha2/zz_generated.deepcopy.go @@ -2182,6 +2182,16 @@ func (in *MSSQLServerSpec) DeepCopyInto(out *MSSQLServerSpec) { (*in).DeepCopyInto(*out) } in.HealthChecker.DeepCopyInto(&out.HealthChecker) + if in.Monitor != nil { + in, out := &in.Monitor, &out.Monitor + *out = new(monitoringagentapiapiv1.AgentSpec) + (*in).DeepCopyInto(*out) + } + if in.Archiver != nil { + in, out := &in.Archiver, &out.Archiver + *out = new(Archiver) + **out = **in + } return } diff --git a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/constant.go b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/constant.go index 119145c20..2637f4690 100644 --- a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/constant.go +++ b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/constant.go @@ -169,6 +169,8 @@ const ( VolumeExpansionMLNode = "VolumeExpansionMLNode" VolumeExpansionTransformNode = "VolumeExpansionTransformNode" VolumeExpansionCoordinatingNode = "VolumeExpansionCoordinatingNode" + VolumeExpansionOverseerNode = "VolumeExpansionOverseerNode" + VolumeExpansionCoordinatorNode = "VolumeExpansionCoordinatorNode" ) // Kafka Constants diff --git a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/ferretdb_ops.types.go b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/ferretdb_ops.types.go new file mode 100644 index 000000000..d08c40270 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/ferretdb_ops.types.go @@ -0,0 +1,118 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +//go:generate go-enum --mustparse --names --values +package v1alpha1 + +import ( + "kubedb.dev/apimachinery/apis/kubedb/v1alpha2" + + core "k8s.io/api/core/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +const ( + ResourceCodeFerretDBOpsRequest = "frops" + ResourceKindFerretDBOpsRequest = "FerretDBOpsRequest" + ResourceSingularFerretDBOpsRequest = "ferretdbopsrequest" + ResourcePluralFerretDBOpsRequest = "ferretdbopsrequests" +) + +// FerretDBDBOpsRequest defines a FerretDB DBA operation. + +// +genclient +// +k8s:openapi-gen=true +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// +kubebuilder:object:root=true +// +kubebuilder:resource:path=ferretdbopsrequests,singular=ferretdbopsrequest,shortName=frops,categories={datastore,kubedb,appscode} +// +kubebuilder:subresource:status +// +kubebuilder:printcolumn:name="Type",type="string",JSONPath=".spec.type" +// +kubebuilder:printcolumn:name="Status",type="string",JSONPath=".status.phase" +// +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp" +type FerretDBOpsRequest struct { + metav1.TypeMeta `json:",inline,omitempty"` + metav1.ObjectMeta `json:"metadata,omitempty"` + Spec FerretDBOpsRequestSpec `json:"spec,omitempty"` + Status OpsRequestStatus `json:"status,omitempty"` +} + +// FerretDBOpsRequestSpec is the spec for FerretDBOpsRequest +type FerretDBOpsRequestSpec struct { + // Specifies the FerretDB reference + DatabaseRef core.LocalObjectReference `json:"databaseRef"` + // Specifies the ops request type: UpdateVersion, HorizontalScaling, VerticalScaling etc. + Type FerretDBOpsRequestType `json:"type"` + // Specifies information necessary for upgrading ferretdb + UpdateVersion *FerretDBUpdateVersionSpec `json:"updateVersion,omitempty"` + // Specifies information necessary for horizontal scaling + HorizontalScaling *FerretDBHorizontalScalingSpec `json:"horizontalScaling,omitempty"` + // Specifies information necessary for vertical scaling + VerticalScaling *FerretDBVerticalScalingSpec `json:"verticalScaling,omitempty"` + // Specifies information necessary for configuring TLS + TLS *FerretDBTLSSpec `json:"tls,omitempty"` + // Specifies information necessary for restarting database + Restart *RestartSpec `json:"restart,omitempty"` + // Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure. + Timeout *metav1.Duration `json:"timeout,omitempty"` + // ApplyOption is to control the execution of OpsRequest depending on the database state. + // +kubebuilder:default="IfReady" + Apply ApplyOption `json:"apply,omitempty"` +} + +type FerretDBTLSSpec struct { + TLSSpec `json:",inline,omitempty"` + + // SSLMode for both standalone and clusters. [disable;allow;prefer;require;verify-ca;verify-full] + // +optional + SSLMode v1alpha2.SSLMode `json:"sslMode,omitempty"` + + // ClientAuthMode for both standalone and clusters. (default will be md5. [md5;scram;cert]) + // +optional + ClientAuthMode v1alpha2.ClusterAuthMode `json:"clientAuthMode,omitempty"` +} + +// +kubebuilder:validation:Enum=UpdateVersion;VerticalScaling;Restart;HorizontalScaling;ReconfigureTLS +// ENUM(UpdateVersion, Restart, VerticalScaling, HorizontalScaling, ReconfigureTLS) +type FerretDBOpsRequestType string + +// FerretDBUpdateVersionSpec contains the update version information of a ferretdb cluster +type FerretDBUpdateVersionSpec struct { + // Specifies the target version name from catalog + TargetVersion string `json:"targetVersion,omitempty"` +} + +// FerretDBHorizontalScalingSpec contains the horizontal scaling information of a FerretDB cluster +type FerretDBHorizontalScalingSpec struct { + // Number of node + Node *int32 `json:"node,omitempty"` +} + +// FerretDBVerticalScalingSpec contains the vertical scaling information of a FerretDB cluster +type FerretDBVerticalScalingSpec struct { + // Resource spec for nodes + Node *PodResources `json:"node,omitempty"` +} + +// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object + +// FerretDBOpsRequestList is a list of FerretDBOpsRequests +type FerretDBOpsRequestList struct { + metav1.TypeMeta `json:",inline"` + metav1.ListMeta `json:"metadata,omitempty"` + // Items is a list of FerretDBOpsRequest CRD objects + Items []FerretDBOpsRequest `json:"items,omitempty"` +} diff --git a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/ferretdb_ops.types_enum.go b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/ferretdb_ops.types_enum.go new file mode 100644 index 000000000..284db35ac --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/ferretdb_ops.types_enum.go @@ -0,0 +1,90 @@ +// Code generated by go-enum DO NOT EDIT. +// Version: +// Revision: +// Build Date: +// Built By: + +package v1alpha1 + +import ( + "fmt" + "strings" +) + +const ( + // FerretDBOpsRequestTypeUpdateVersion is a FerretDBOpsRequestType of type UpdateVersion. + FerretDBOpsRequestTypeUpdateVersion FerretDBOpsRequestType = "UpdateVersion" + // FerretDBOpsRequestTypeRestart is a FerretDBOpsRequestType of type Restart. + FerretDBOpsRequestTypeRestart FerretDBOpsRequestType = "Restart" + // FerretDBOpsRequestTypeVerticalScaling is a FerretDBOpsRequestType of type VerticalScaling. + FerretDBOpsRequestTypeVerticalScaling FerretDBOpsRequestType = "VerticalScaling" + // FerretDBOpsRequestTypeHorizontalScaling is a FerretDBOpsRequestType of type HorizontalScaling. + FerretDBOpsRequestTypeHorizontalScaling FerretDBOpsRequestType = "HorizontalScaling" + // FerretDBOpsRequestTypeReconfigureTLS is a FerretDBOpsRequestType of type ReconfigureTLS. + FerretDBOpsRequestTypeReconfigureTLS FerretDBOpsRequestType = "ReconfigureTLS" +) + +var ErrInvalidFerretDBOpsRequestType = fmt.Errorf("not a valid FerretDBOpsRequestType, try [%s]", strings.Join(_FerretDBOpsRequestTypeNames, ", ")) + +var _FerretDBOpsRequestTypeNames = []string{ + string(FerretDBOpsRequestTypeUpdateVersion), + string(FerretDBOpsRequestTypeRestart), + string(FerretDBOpsRequestTypeVerticalScaling), + string(FerretDBOpsRequestTypeHorizontalScaling), + string(FerretDBOpsRequestTypeReconfigureTLS), +} + +// FerretDBOpsRequestTypeNames returns a list of possible string values of FerretDBOpsRequestType. +func FerretDBOpsRequestTypeNames() []string { + tmp := make([]string, len(_FerretDBOpsRequestTypeNames)) + copy(tmp, _FerretDBOpsRequestTypeNames) + return tmp +} + +// FerretDBOpsRequestTypeValues returns a list of the values for FerretDBOpsRequestType +func FerretDBOpsRequestTypeValues() []FerretDBOpsRequestType { + return []FerretDBOpsRequestType{ + FerretDBOpsRequestTypeUpdateVersion, + FerretDBOpsRequestTypeRestart, + FerretDBOpsRequestTypeVerticalScaling, + FerretDBOpsRequestTypeHorizontalScaling, + FerretDBOpsRequestTypeReconfigureTLS, + } +} + +// String implements the Stringer interface. +func (x FerretDBOpsRequestType) String() string { + return string(x) +} + +// IsValid provides a quick way to determine if the typed value is +// part of the allowed enumerated values +func (x FerretDBOpsRequestType) IsValid() bool { + _, err := ParseFerretDBOpsRequestType(string(x)) + return err == nil +} + +var _FerretDBOpsRequestTypeValue = map[string]FerretDBOpsRequestType{ + "UpdateVersion": FerretDBOpsRequestTypeUpdateVersion, + "Restart": FerretDBOpsRequestTypeRestart, + "VerticalScaling": FerretDBOpsRequestTypeVerticalScaling, + "HorizontalScaling": FerretDBOpsRequestTypeHorizontalScaling, + "ReconfigureTLS": FerretDBOpsRequestTypeReconfigureTLS, +} + +// ParseFerretDBOpsRequestType attempts to convert a string to a FerretDBOpsRequestType. +func ParseFerretDBOpsRequestType(name string) (FerretDBOpsRequestType, error) { + if x, ok := _FerretDBOpsRequestTypeValue[name]; ok { + return x, nil + } + return FerretDBOpsRequestType(""), fmt.Errorf("%s is %w", name, ErrInvalidFerretDBOpsRequestType) +} + +// MustParseFerretDBOpsRequestType converts a string to a FerretDBOpsRequestType, and panics if is not valid. +func MustParseFerretDBOpsRequestType(name string) FerretDBOpsRequestType { + val, err := ParseFerretDBOpsRequestType(name) + if err != nil { + panic(err) + } + return val +} diff --git a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/ferretdb_ops_helpers.go b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/ferretdb_ops_helpers.go new file mode 100644 index 000000000..abdc3c76f --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/ferretdb_ops_helpers.go @@ -0,0 +1,76 @@ +/* +Copyright AppsCode Inc. and Contributors + +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. +*/ + +package v1alpha1 + +import ( + "fmt" + + "kubedb.dev/apimachinery/apis" + "kubedb.dev/apimachinery/apis/ops" + "kubedb.dev/apimachinery/crds" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "kmodules.xyz/client-go/apiextensions" +) + +func (r *FerretDBOpsRequest) CustomResourceDefinition() *apiextensions.CustomResourceDefinition { + return crds.MustCustomResourceDefinition(SchemeGroupVersion.WithResource(ResourcePluralFerretDBOpsRequest)) +} + +var _ apis.ResourceInfo = &FerretDBOpsRequest{} + +func (r *FerretDBOpsRequest) ResourceFQN() string { + return fmt.Sprintf("%s.%s", ResourcePluralFerretDBOpsRequest, ops.GroupName) +} + +func (r *FerretDBOpsRequest) ResourceShortCode() string { + return ResourceCodeFerretDBOpsRequest +} + +func (r *FerretDBOpsRequest) ResourceKind() string { + return ResourceKindFerretDBOpsRequest +} + +func (r *FerretDBOpsRequest) ResourceSingular() string { + return ResourceSingularFerretDBOpsRequest +} + +func (r *FerretDBOpsRequest) ResourcePlural() string { + return ResourcePluralFerretDBOpsRequest +} + +var _ Accessor = &FerretDBOpsRequest{} + +func (r *FerretDBOpsRequest) GetObjectMeta() metav1.ObjectMeta { + return r.ObjectMeta +} + +func (r *FerretDBOpsRequest) GetDBRefName() string { + return r.Spec.DatabaseRef.Name +} + +func (r *FerretDBOpsRequest) GetRequestType() any { + return r.Spec.Type +} + +func (r *FerretDBOpsRequest) GetStatus() OpsRequestStatus { + return r.Status +} + +func (r *FerretDBOpsRequest) SetStatus(s OpsRequestStatus) { + r.Status = s +} diff --git a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/memcached_ops_types.go b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/memcached_ops_types.go index 4654fb502..e6ea1c276 100644 --- a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/memcached_ops_types.go +++ b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/memcached_ops_types.go @@ -90,11 +90,15 @@ type MemcachedUpdateVersionSpec struct { } // HorizontalScaling is the spec for Memcached horizontal scaling -type MemcachedHorizontalScalingSpec struct{} +type MemcachedHorizontalScalingSpec struct { + // specifies the number of replica + Replicas *int32 `json:"replicas,omitempty"` +} // MemcachedVerticalScalingSpec is the spec for Memcached vertical scaling type MemcachedVerticalScalingSpec struct { Memcached *PodResources `json:"memcached,omitempty"` + Exporter *ContainerResources `json:"exporter,omitempty"` ReadinessCriteria *MemcachedReplicaReadinessCriteria `json:"readinessCriteria,omitempty"` } diff --git a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/openapi_generated.go b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/openapi_generated.go index e55977115..6f00e7941 100644 --- a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/openapi_generated.go +++ b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/openapi_generated.go @@ -516,6 +516,13 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/ops/v1alpha1.EtcdUpdateVersionSpec": schema_apimachinery_apis_ops_v1alpha1_EtcdUpdateVersionSpec(ref), "kubedb.dev/apimachinery/apis/ops/v1alpha1.EtcdVerticalScalingSpec": schema_apimachinery_apis_ops_v1alpha1_EtcdVerticalScalingSpec(ref), "kubedb.dev/apimachinery/apis/ops/v1alpha1.EtcdVolumeExpansionSpec": schema_apimachinery_apis_ops_v1alpha1_EtcdVolumeExpansionSpec(ref), + "kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBHorizontalScalingSpec": schema_apimachinery_apis_ops_v1alpha1_FerretDBHorizontalScalingSpec(ref), + "kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBOpsRequest": schema_apimachinery_apis_ops_v1alpha1_FerretDBOpsRequest(ref), + "kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBOpsRequestList": schema_apimachinery_apis_ops_v1alpha1_FerretDBOpsRequestList(ref), + "kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBOpsRequestSpec": schema_apimachinery_apis_ops_v1alpha1_FerretDBOpsRequestSpec(ref), + "kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBTLSSpec": schema_apimachinery_apis_ops_v1alpha1_FerretDBTLSSpec(ref), + "kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBUpdateVersionSpec": schema_apimachinery_apis_ops_v1alpha1_FerretDBUpdateVersionSpec(ref), + "kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBVerticalScalingSpec": schema_apimachinery_apis_ops_v1alpha1_FerretDBVerticalScalingSpec(ref), "kubedb.dev/apimachinery/apis/ops/v1alpha1.HiddenNode": schema_apimachinery_apis_ops_v1alpha1_HiddenNode(ref), "kubedb.dev/apimachinery/apis/ops/v1alpha1.KafkaCustomConfigurationSpec": schema_apimachinery_apis_ops_v1alpha1_KafkaCustomConfigurationSpec(ref), "kubedb.dev/apimachinery/apis/ops/v1alpha1.KafkaHorizontalScalingSpec": schema_apimachinery_apis_ops_v1alpha1_KafkaHorizontalScalingSpec(ref), @@ -659,9 +666,13 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA "kubedb.dev/apimachinery/apis/ops/v1alpha1.SinglestoreOpsRequestSpec": schema_apimachinery_apis_ops_v1alpha1_SinglestoreOpsRequestSpec(ref), "kubedb.dev/apimachinery/apis/ops/v1alpha1.SinglestoreVerticalScalingSpec": schema_apimachinery_apis_ops_v1alpha1_SinglestoreVerticalScalingSpec(ref), "kubedb.dev/apimachinery/apis/ops/v1alpha1.SinglestoreVolumeExpansionSpec": schema_apimachinery_apis_ops_v1alpha1_SinglestoreVolumeExpansionSpec(ref), + "kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrCustomConfigurationSpec": schema_apimachinery_apis_ops_v1alpha1_SolrCustomConfigurationSpec(ref), "kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrOpsRequest": schema_apimachinery_apis_ops_v1alpha1_SolrOpsRequest(ref), "kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrOpsRequestList": schema_apimachinery_apis_ops_v1alpha1_SolrOpsRequestList(ref), "kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrOpsRequestSpec": schema_apimachinery_apis_ops_v1alpha1_SolrOpsRequestSpec(ref), + "kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrUpdateVersionSpec": schema_apimachinery_apis_ops_v1alpha1_SolrUpdateVersionSpec(ref), + "kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrVerticalScalingSpec": schema_apimachinery_apis_ops_v1alpha1_SolrVerticalScalingSpec(ref), + "kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrVolumeExpansionSpec": schema_apimachinery_apis_ops_v1alpha1_SolrVolumeExpansionSpec(ref), "kubedb.dev/apimachinery/apis/ops/v1alpha1.TLSSpec": schema_apimachinery_apis_ops_v1alpha1_TLSSpec(ref), "kubedb.dev/apimachinery/apis/ops/v1alpha1.Topology": schema_apimachinery_apis_ops_v1alpha1_Topology(ref), } @@ -26459,6 +26470,298 @@ func schema_apimachinery_apis_ops_v1alpha1_EtcdVolumeExpansionSpec(ref common.Re } } +func schema_apimachinery_apis_ops_v1alpha1_FerretDBHorizontalScalingSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "FerretDBHorizontalScalingSpec contains the horizontal scaling information of a FerretDB cluster", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "node": { + SchemaProps: spec.SchemaProps{ + Description: "Number of node", + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, + }, + }, + } +} + +func schema_apimachinery_apis_ops_v1alpha1_FerretDBOpsRequest(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"), + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBOpsRequestSpec"), + }, + }, + "status": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.OpsRequestStatus"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta", "kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBOpsRequestSpec", "kubedb.dev/apimachinery/apis/ops/v1alpha1.OpsRequestStatus"}, + } +} + +func schema_apimachinery_apis_ops_v1alpha1_FerretDBOpsRequestList(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "FerretDBOpsRequestList is a list of FerretDBOpsRequests", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds", + Type: []string{"string"}, + Format: "", + }, + }, + "apiVersion": { + SchemaProps: spec.SchemaProps{ + Description: "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: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources", + Type: []string{"string"}, + Format: "", + }, + }, + "metadata": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"), + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Description: "Items is a list of FerretDBOpsRequest CRD objects", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBOpsRequest"), + }, + }, + }, + }, + }, + }, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta", "kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBOpsRequest"}, + } +} + +func schema_apimachinery_apis_ops_v1alpha1_FerretDBOpsRequestSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "FerretDBOpsRequestSpec is the spec for FerretDBOpsRequest", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "databaseRef": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the FerretDB reference", + Default: map[string]interface{}{}, + Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + }, + }, + "type": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the ops request type: UpdateVersion, HorizontalScaling, VerticalScaling etc.", + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "updateVersion": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies information necessary for upgrading ferretdb", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBUpdateVersionSpec"), + }, + }, + "horizontalScaling": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies information necessary for horizontal scaling", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBHorizontalScalingSpec"), + }, + }, + "verticalScaling": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies information necessary for vertical scaling", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBVerticalScalingSpec"), + }, + }, + "tls": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies information necessary for configuring TLS", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBTLSSpec"), + }, + }, + "restart": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies information necessary for restarting database", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.RestartSpec"), + }, + }, + "timeout": { + SchemaProps: spec.SchemaProps{ + Description: "Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure.", + Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.Duration"), + }, + }, + "apply": { + SchemaProps: spec.SchemaProps{ + Description: "ApplyOption is to control the execution of OpsRequest depending on the database state.", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"databaseRef", "type"}, + }, + }, + Dependencies: []string{ + "k8s.io/api/core/v1.LocalObjectReference", "k8s.io/apimachinery/pkg/apis/meta/v1.Duration", "kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBHorizontalScalingSpec", "kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBTLSSpec", "kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBUpdateVersionSpec", "kubedb.dev/apimachinery/apis/ops/v1alpha1.FerretDBVerticalScalingSpec", "kubedb.dev/apimachinery/apis/ops/v1alpha1.RestartSpec"}, + } +} + +func schema_apimachinery_apis_ops_v1alpha1_FerretDBTLSSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "issuerRef": { + SchemaProps: spec.SchemaProps{ + Description: "IssuerRef is a reference to a Certificate Issuer.", + Ref: ref("k8s.io/api/core/v1.TypedLocalObjectReference"), + }, + }, + "certificates": { + SchemaProps: spec.SchemaProps{ + Description: "Certificate provides server and/or client certificate options used by application pods. These options are passed to a cert-manager Certificate object. xref: https://github.com/jetstack/cert-manager/blob/v0.16.0/pkg/apis/certmanager/v1beta1/types_certificate.go#L82-L162", + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("kmodules.xyz/client-go/api/v1.CertificateSpec"), + }, + }, + }, + }, + }, + "rotateCertificates": { + SchemaProps: spec.SchemaProps{ + Description: "RotateCertificates tells operator to initiate certificate rotation", + Type: []string{"boolean"}, + Format: "", + }, + }, + "remove": { + SchemaProps: spec.SchemaProps{ + Description: "Remove tells operator to remove TLS configuration", + Type: []string{"boolean"}, + Format: "", + }, + }, + "sslMode": { + SchemaProps: spec.SchemaProps{ + Description: "SSLMode for both standalone and clusters. [disable;allow;prefer;require;verify-ca;verify-full]", + Type: []string{"string"}, + Format: "", + }, + }, + "clientAuthMode": { + SchemaProps: spec.SchemaProps{ + Description: "ClientAuthMode for both standalone and clusters. (default will be md5. [md5;scram;cert])", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + "k8s.io/api/core/v1.TypedLocalObjectReference", "kmodules.xyz/client-go/api/v1.CertificateSpec"}, + } +} + +func schema_apimachinery_apis_ops_v1alpha1_FerretDBUpdateVersionSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "FerretDBUpdateVersionSpec contains the update version information of a ferretdb cluster", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "targetVersion": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the target version name from catalog", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_apimachinery_apis_ops_v1alpha1_FerretDBVerticalScalingSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "FerretDBVerticalScalingSpec contains the vertical scaling information of a FerretDB cluster", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "node": { + SchemaProps: spec.SchemaProps{ + Description: "Resource spec for nodes", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.PodResources"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/ops/v1alpha1.PodResources"}, + } +} + func schema_apimachinery_apis_ops_v1alpha1_HiddenNode(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -27380,6 +27683,15 @@ func schema_apimachinery_apis_ops_v1alpha1_MemcachedHorizontalScalingSpec(ref co SchemaProps: spec.SchemaProps{ Description: "HorizontalScaling is the spec for Memcached horizontal scaling", Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "replicas": { + SchemaProps: spec.SchemaProps{ + Description: "specifies the number of replica", + Type: []string{"integer"}, + Format: "int32", + }, + }, + }, }, }, } @@ -27615,6 +27927,11 @@ func schema_apimachinery_apis_ops_v1alpha1_MemcachedVerticalScalingSpec(ref comm Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.PodResources"), }, }, + "exporter": { + SchemaProps: spec.SchemaProps{ + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.ContainerResources"), + }, + }, "readinessCriteria": { SchemaProps: spec.SchemaProps{ Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.MemcachedReplicaReadinessCriteria"), @@ -27624,7 +27941,7 @@ func schema_apimachinery_apis_ops_v1alpha1_MemcachedVerticalScalingSpec(ref comm }, }, Dependencies: []string{ - "kubedb.dev/apimachinery/apis/ops/v1alpha1.MemcachedReplicaReadinessCriteria", "kubedb.dev/apimachinery/apis/ops/v1alpha1.PodResources"}, + "kubedb.dev/apimachinery/apis/ops/v1alpha1.ContainerResources", "kubedb.dev/apimachinery/apis/ops/v1alpha1.MemcachedReplicaReadinessCriteria", "kubedb.dev/apimachinery/apis/ops/v1alpha1.PodResources"}, } } @@ -31968,6 +32285,50 @@ func schema_apimachinery_apis_ops_v1alpha1_SinglestoreVolumeExpansionSpec(ref co } } +func schema_apimachinery_apis_ops_v1alpha1_SolrCustomConfigurationSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Description: "SolrCustomConfigurationSpec is the spec for Reconfiguring the solr Settings", + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "configSecret": { + SchemaProps: spec.SchemaProps{ + Description: "ConfigSecret is an optional field to provide custom configuration file for database.", + Ref: ref("k8s.io/api/core/v1.LocalObjectReference"), + }, + }, + "applyConfig": { + SchemaProps: spec.SchemaProps{ + Description: "ApplyConfig is an optional field to provide solr configuration. Provided configuration will be applied to config files stored in ConfigSecret. If the ConfigSecret is missing, the operator will create a new k8s secret by the following naming convention: {db-name}-user-config . Expected input format:\n\tapplyConfig:\n\t\tsolr.xml: |\n\t\t\tkey=value", + Type: []string{"object"}, + AdditionalProperties: &spec.SchemaOrBool{ + Allows: true, + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + "removeCustomConfig": { + SchemaProps: spec.SchemaProps{ + Description: "If set to \"true\", the user provided configuration will be removed. The solr cluster will start will default configuration that is generated by the operator.", + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + }, + }, + Dependencies: []string{ + "k8s.io/api/core/v1.LocalObjectReference"}, + } +} + func schema_apimachinery_apis_ops_v1alpha1_SolrOpsRequest(ref common.ReferenceCallback) common.OpenAPIDefinition { return common.OpenAPIDefinition{ Schema: spec.Schema{ @@ -32085,12 +32446,36 @@ func schema_apimachinery_apis_ops_v1alpha1_SolrOpsRequestSpec(ref common.Referen Format: "", }, }, + "updateVersion": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies information necessary for upgrading Solr", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrUpdateVersionSpec"), + }, + }, + "verticalScaling": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies information necessary for vertical scaling", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrVerticalScalingSpec"), + }, + }, + "volumeExpansion": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies information necessary for volume expansion", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrVolumeExpansionSpec"), + }, + }, "restart": { SchemaProps: spec.SchemaProps{ Description: "Specifies information necessary for restarting database", Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.RestartSpec"), }, }, + "configuration": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies information necessary for custom configuration of solr", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrCustomConfigurationSpec"), + }, + }, "timeout": { SchemaProps: spec.SchemaProps{ Description: "Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure.", @@ -32109,7 +32494,110 @@ func schema_apimachinery_apis_ops_v1alpha1_SolrOpsRequestSpec(ref common.Referen }, }, Dependencies: []string{ - "k8s.io/api/core/v1.LocalObjectReference", "k8s.io/apimachinery/pkg/apis/meta/v1.Duration", "kubedb.dev/apimachinery/apis/ops/v1alpha1.RestartSpec"}, + "k8s.io/api/core/v1.LocalObjectReference", "k8s.io/apimachinery/pkg/apis/meta/v1.Duration", "kubedb.dev/apimachinery/apis/ops/v1alpha1.RestartSpec", "kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrCustomConfigurationSpec", "kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrUpdateVersionSpec", "kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrVerticalScalingSpec", "kubedb.dev/apimachinery/apis/ops/v1alpha1.SolrVolumeExpansionSpec"}, + } +} + +func schema_apimachinery_apis_ops_v1alpha1_SolrUpdateVersionSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "targetVersion": { + SchemaProps: spec.SchemaProps{ + Description: "Specifies the target version name from catalog", + Type: []string{"string"}, + Format: "", + }, + }, + }, + }, + }, + } +} + +func schema_apimachinery_apis_ops_v1alpha1_SolrVerticalScalingSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "node": { + SchemaProps: spec.SchemaProps{ + Description: "Resource spec for combined nodes", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.PodResources"), + }, + }, + "data": { + SchemaProps: spec.SchemaProps{ + Description: "Resource spec for data nodes", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.PodResources"), + }, + }, + "overseer": { + SchemaProps: spec.SchemaProps{ + Description: "Resource spec for overseer nodes", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.PodResources"), + }, + }, + "coordinator": { + SchemaProps: spec.SchemaProps{ + Description: "Resource spec for overseer nodes", + Ref: ref("kubedb.dev/apimachinery/apis/ops/v1alpha1.PodResources"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "kubedb.dev/apimachinery/apis/ops/v1alpha1.PodResources"}, + } +} + +func schema_apimachinery_apis_ops_v1alpha1_SolrVolumeExpansionSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "mode": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "node": { + SchemaProps: spec.SchemaProps{ + Description: "volume specification for combined nodes", + Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + }, + }, + "data": { + SchemaProps: spec.SchemaProps{ + Description: "volume specification for data nodes", + Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + }, + }, + "overseer": { + SchemaProps: spec.SchemaProps{ + Description: "volume specification for overseer nodes", + Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + }, + }, + "coordinator": { + SchemaProps: spec.SchemaProps{ + Description: "volume specification for overseer nodes", + Ref: ref("k8s.io/apimachinery/pkg/api/resource.Quantity"), + }, + }, + }, + Required: []string{"mode"}, + }, + }, + Dependencies: []string{ + "k8s.io/apimachinery/pkg/api/resource.Quantity"}, } } diff --git a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/register.go b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/register.go index 2d3d703d5..a9820f1ef 100644 --- a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/register.go +++ b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/register.go @@ -58,6 +58,8 @@ func addKnownTypes(scheme *runtime.Scheme) error { &DruidOpsRequestList{}, &ElasticsearchOpsRequest{}, &ElasticsearchOpsRequestList{}, + &FerretDBOpsRequest{}, + &FerretDBOpsRequestList{}, &EtcdOpsRequest{}, &EtcdOpsRequestList{}, &KafkaOpsRequest{}, diff --git a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/solr_ops_types.go b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/solr_ops_types.go index 6fa282211..9a9439849 100644 --- a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/solr_ops_types.go +++ b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/solr_ops_types.go @@ -19,6 +19,7 @@ package v1alpha1 import ( core "k8s.io/api/core/v1" + "k8s.io/apimachinery/pkg/api/resource" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) @@ -48,8 +49,8 @@ type SolrOpsRequest struct { Status OpsRequestStatus `json:"status,omitempty"` } -// +kubebuilder:validation:Enum=Restart -// ENUM(Restart) +// +kubebuilder:validation:Enum=UpdateVersion;VerticalScaling;VolumeExpansion;Reconfigure;Restart +// ENUM(UpdateVersion, VerticalScaling, VolumeExpansion, Reconfigure, Restart) type SolrOpsRequestType string // DruidOpsRequestSpec is the spec for DruidOpsRequest @@ -58,8 +59,16 @@ type SolrOpsRequestSpec struct { DatabaseRef core.LocalObjectReference `json:"databaseRef"` // Specifies the ops request type: UpdateVersion, HorizontalScaling, VerticalScaling etc. Type SolrOpsRequestType `json:"type"` + // Specifies information necessary for upgrading Solr + UpdateVersion *SolrUpdateVersionSpec `json:"updateVersion,omitempty"` + // Specifies information necessary for vertical scaling + VerticalScaling *SolrVerticalScalingSpec `json:"verticalScaling,omitempty"` + // Specifies information necessary for volume expansion + VolumeExpansion *SolrVolumeExpansionSpec `json:"volumeExpansion,omitempty"` // Specifies information necessary for restarting database Restart *RestartSpec `json:"restart,omitempty"` + // Specifies information necessary for custom configuration of solr + Configuration *SolrCustomConfigurationSpec `json:"configuration,omitempty"` // Timeout for each step of the ops request in second. If a step doesn't finish within the specified timeout, the ops request will result in failure. Timeout *metav1.Duration `json:"timeout,omitempty"` // ApplyOption is to control the execution of OpsRequest depending on the database state. @@ -67,6 +76,55 @@ type SolrOpsRequestSpec struct { Apply ApplyOption `json:"apply,omitempty"` } +type SolrVerticalScalingSpec struct { + // Resource spec for combined nodes + Node *PodResources `json:"node,omitempty"` + // Resource spec for data nodes + Data *PodResources `json:"data,omitempty"` + // Resource spec for overseer nodes + Overseer *PodResources `json:"overseer,omitempty"` + // Resource spec for overseer nodes + Coordinator *PodResources `json:"coordinator,omitempty"` +} + +type SolrVolumeExpansionSpec struct { + Mode VolumeExpansionMode `json:"mode"` + // volume specification for combined nodes + Node *resource.Quantity `json:"node,omitempty"` + // volume specification for data nodes + Data *resource.Quantity `json:"data,omitempty"` + // volume specification for overseer nodes + Overseer *resource.Quantity `json:"overseer,omitempty"` + // volume specification for overseer nodes + Coordinator *resource.Quantity `json:"coordinator,omitempty"` +} + +type SolrUpdateVersionSpec struct { + // Specifies the target version name from catalog + TargetVersion string `json:"targetVersion,omitempty"` +} + +// SolrCustomConfigurationSpec is the spec for Reconfiguring the solr Settings +type SolrCustomConfigurationSpec struct { + // ConfigSecret is an optional field to provide custom configuration file for database. + // +optional + ConfigSecret *core.LocalObjectReference `json:"configSecret,omitempty"` + // ApplyConfig is an optional field to provide solr configuration. + // Provided configuration will be applied to config files stored in ConfigSecret. + // If the ConfigSecret is missing, the operator will create a new k8s secret by the + // following naming convention: {db-name}-user-config . + // Expected input format: + // applyConfig: + // solr.xml: | + // key=value + // +optional + ApplyConfig map[string]string `json:"applyConfig,omitempty"` + // If set to "true", the user provided configuration will be removed. + // The solr cluster will start will default configuration that is generated by the operator. + // +optional + RemoveCustomConfig bool `json:"removeCustomConfig,omitempty"` +} + // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object // SolrOpsRequestList is a list of DruidOpsRequests diff --git a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/solr_ops_types_enum.go b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/solr_ops_types_enum.go index fc067b514..194c348cc 100644 --- a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/solr_ops_types_enum.go +++ b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/solr_ops_types_enum.go @@ -12,6 +12,14 @@ import ( ) const ( + // SolrOpsRequestTypeUpdateVersion is a SolrOpsRequestType of type UpdateVersion. + SolrOpsRequestTypeUpdateVersion SolrOpsRequestType = "UpdateVersion" + // SolrOpsRequestTypeVerticalScaling is a SolrOpsRequestType of type VerticalScaling. + SolrOpsRequestTypeVerticalScaling SolrOpsRequestType = "VerticalScaling" + // SolrOpsRequestTypeVolumeExpansion is a SolrOpsRequestType of type VolumeExpansion. + SolrOpsRequestTypeVolumeExpansion SolrOpsRequestType = "VolumeExpansion" + // SolrOpsRequestTypeReconfigure is a SolrOpsRequestType of type Reconfigure. + SolrOpsRequestTypeReconfigure SolrOpsRequestType = "Reconfigure" // SolrOpsRequestTypeRestart is a SolrOpsRequestType of type Restart. SolrOpsRequestTypeRestart SolrOpsRequestType = "Restart" ) @@ -19,6 +27,10 @@ const ( var ErrInvalidSolrOpsRequestType = fmt.Errorf("not a valid SolrOpsRequestType, try [%s]", strings.Join(_SolrOpsRequestTypeNames, ", ")) var _SolrOpsRequestTypeNames = []string{ + string(SolrOpsRequestTypeUpdateVersion), + string(SolrOpsRequestTypeVerticalScaling), + string(SolrOpsRequestTypeVolumeExpansion), + string(SolrOpsRequestTypeReconfigure), string(SolrOpsRequestTypeRestart), } @@ -32,6 +44,10 @@ func SolrOpsRequestTypeNames() []string { // SolrOpsRequestTypeValues returns a list of the values for SolrOpsRequestType func SolrOpsRequestTypeValues() []SolrOpsRequestType { return []SolrOpsRequestType{ + SolrOpsRequestTypeUpdateVersion, + SolrOpsRequestTypeVerticalScaling, + SolrOpsRequestTypeVolumeExpansion, + SolrOpsRequestTypeReconfigure, SolrOpsRequestTypeRestart, } } @@ -49,7 +65,11 @@ func (x SolrOpsRequestType) IsValid() bool { } var _SolrOpsRequestTypeValue = map[string]SolrOpsRequestType{ - "Restart": SolrOpsRequestTypeRestart, + "UpdateVersion": SolrOpsRequestTypeUpdateVersion, + "VerticalScaling": SolrOpsRequestTypeVerticalScaling, + "VolumeExpansion": SolrOpsRequestTypeVolumeExpansion, + "Reconfigure": SolrOpsRequestTypeReconfigure, + "Restart": SolrOpsRequestTypeRestart, } // ParseSolrOpsRequestType attempts to convert a string to a SolrOpsRequestType. diff --git a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/zz_generated.deepcopy.go b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/zz_generated.deepcopy.go index 68a003551..572bf734d 100644 --- a/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/zz_generated.deepcopy.go +++ b/vendor/kubedb.dev/apimachinery/apis/ops/v1alpha1/zz_generated.deepcopy.go @@ -962,6 +962,189 @@ func (in *EtcdVolumeExpansionSpec) DeepCopy() *EtcdVolumeExpansionSpec { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *FerretDBHorizontalScalingSpec) DeepCopyInto(out *FerretDBHorizontalScalingSpec) { + *out = *in + if in.Node != nil { + in, out := &in.Node, &out.Node + *out = new(int32) + **out = **in + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FerretDBHorizontalScalingSpec. +func (in *FerretDBHorizontalScalingSpec) DeepCopy() *FerretDBHorizontalScalingSpec { + if in == nil { + return nil + } + out := new(FerretDBHorizontalScalingSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *FerretDBOpsRequest) DeepCopyInto(out *FerretDBOpsRequest) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) + in.Spec.DeepCopyInto(&out.Spec) + in.Status.DeepCopyInto(&out.Status) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FerretDBOpsRequest. +func (in *FerretDBOpsRequest) DeepCopy() *FerretDBOpsRequest { + if in == nil { + return nil + } + out := new(FerretDBOpsRequest) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *FerretDBOpsRequest) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *FerretDBOpsRequestList) DeepCopyInto(out *FerretDBOpsRequestList) { + *out = *in + out.TypeMeta = in.TypeMeta + in.ListMeta.DeepCopyInto(&out.ListMeta) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]FerretDBOpsRequest, len(*in)) + for i := range *in { + (*in)[i].DeepCopyInto(&(*out)[i]) + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FerretDBOpsRequestList. +func (in *FerretDBOpsRequestList) DeepCopy() *FerretDBOpsRequestList { + if in == nil { + return nil + } + out := new(FerretDBOpsRequestList) + in.DeepCopyInto(out) + return out +} + +// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object. +func (in *FerretDBOpsRequestList) DeepCopyObject() runtime.Object { + if c := in.DeepCopy(); c != nil { + return c + } + return nil +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *FerretDBOpsRequestSpec) DeepCopyInto(out *FerretDBOpsRequestSpec) { + *out = *in + out.DatabaseRef = in.DatabaseRef + if in.UpdateVersion != nil { + in, out := &in.UpdateVersion, &out.UpdateVersion + *out = new(FerretDBUpdateVersionSpec) + **out = **in + } + if in.HorizontalScaling != nil { + in, out := &in.HorizontalScaling, &out.HorizontalScaling + *out = new(FerretDBHorizontalScalingSpec) + (*in).DeepCopyInto(*out) + } + if in.VerticalScaling != nil { + in, out := &in.VerticalScaling, &out.VerticalScaling + *out = new(FerretDBVerticalScalingSpec) + (*in).DeepCopyInto(*out) + } + if in.TLS != nil { + in, out := &in.TLS, &out.TLS + *out = new(FerretDBTLSSpec) + (*in).DeepCopyInto(*out) + } + if in.Restart != nil { + in, out := &in.Restart, &out.Restart + *out = new(RestartSpec) + **out = **in + } + if in.Timeout != nil { + in, out := &in.Timeout, &out.Timeout + *out = new(v1.Duration) + **out = **in + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FerretDBOpsRequestSpec. +func (in *FerretDBOpsRequestSpec) DeepCopy() *FerretDBOpsRequestSpec { + if in == nil { + return nil + } + out := new(FerretDBOpsRequestSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *FerretDBTLSSpec) DeepCopyInto(out *FerretDBTLSSpec) { + *out = *in + in.TLSSpec.DeepCopyInto(&out.TLSSpec) + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FerretDBTLSSpec. +func (in *FerretDBTLSSpec) DeepCopy() *FerretDBTLSSpec { + if in == nil { + return nil + } + out := new(FerretDBTLSSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *FerretDBUpdateVersionSpec) DeepCopyInto(out *FerretDBUpdateVersionSpec) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FerretDBUpdateVersionSpec. +func (in *FerretDBUpdateVersionSpec) DeepCopy() *FerretDBUpdateVersionSpec { + if in == nil { + return nil + } + out := new(FerretDBUpdateVersionSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *FerretDBVerticalScalingSpec) DeepCopyInto(out *FerretDBVerticalScalingSpec) { + *out = *in + if in.Node != nil { + in, out := &in.Node, &out.Node + *out = new(PodResources) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FerretDBVerticalScalingSpec. +func (in *FerretDBVerticalScalingSpec) DeepCopy() *FerretDBVerticalScalingSpec { + if in == nil { + return nil + } + out := new(FerretDBVerticalScalingSpec) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *HiddenNode) DeepCopyInto(out *HiddenNode) { *out = *in @@ -1630,6 +1813,11 @@ func (in *MemcachedCustomConfigurationSpec) DeepCopy() *MemcachedCustomConfigura // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *MemcachedHorizontalScalingSpec) DeepCopyInto(out *MemcachedHorizontalScalingSpec) { *out = *in + if in.Replicas != nil { + in, out := &in.Replicas, &out.Replicas + *out = new(int32) + **out = **in + } return } @@ -1716,7 +1904,7 @@ func (in *MemcachedOpsRequestSpec) DeepCopyInto(out *MemcachedOpsRequestSpec) { if in.HorizontalScaling != nil { in, out := &in.HorizontalScaling, &out.HorizontalScaling *out = new(MemcachedHorizontalScalingSpec) - **out = **in + (*in).DeepCopyInto(*out) } if in.VerticalScaling != nil { in, out := &in.VerticalScaling, &out.VerticalScaling @@ -1806,6 +1994,11 @@ func (in *MemcachedVerticalScalingSpec) DeepCopyInto(out *MemcachedVerticalScali *out = new(PodResources) (*in).DeepCopyInto(*out) } + if in.Exporter != nil { + in, out := &in.Exporter, &out.Exporter + *out = new(ContainerResources) + (*in).DeepCopyInto(*out) + } if in.ReadinessCriteria != nil { in, out := &in.ReadinessCriteria, &out.ReadinessCriteria *out = new(MemcachedReplicaReadinessCriteria) @@ -5005,6 +5198,34 @@ func (in *SinglestoreVolumeExpansionSpec) DeepCopy() *SinglestoreVolumeExpansion return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SolrCustomConfigurationSpec) DeepCopyInto(out *SolrCustomConfigurationSpec) { + *out = *in + if in.ConfigSecret != nil { + in, out := &in.ConfigSecret, &out.ConfigSecret + *out = new(corev1.LocalObjectReference) + **out = **in + } + if in.ApplyConfig != nil { + in, out := &in.ApplyConfig, &out.ApplyConfig + *out = make(map[string]string, len(*in)) + for key, val := range *in { + (*out)[key] = val + } + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SolrCustomConfigurationSpec. +func (in *SolrCustomConfigurationSpec) DeepCopy() *SolrCustomConfigurationSpec { + if in == nil { + return nil + } + out := new(SolrCustomConfigurationSpec) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SolrOpsRequest) DeepCopyInto(out *SolrOpsRequest) { *out = *in @@ -5070,11 +5291,31 @@ func (in *SolrOpsRequestList) DeepCopyObject() runtime.Object { func (in *SolrOpsRequestSpec) DeepCopyInto(out *SolrOpsRequestSpec) { *out = *in out.DatabaseRef = in.DatabaseRef + if in.UpdateVersion != nil { + in, out := &in.UpdateVersion, &out.UpdateVersion + *out = new(SolrUpdateVersionSpec) + **out = **in + } + if in.VerticalScaling != nil { + in, out := &in.VerticalScaling, &out.VerticalScaling + *out = new(SolrVerticalScalingSpec) + (*in).DeepCopyInto(*out) + } + if in.VolumeExpansion != nil { + in, out := &in.VolumeExpansion, &out.VolumeExpansion + *out = new(SolrVolumeExpansionSpec) + (*in).DeepCopyInto(*out) + } if in.Restart != nil { in, out := &in.Restart, &out.Restart *out = new(RestartSpec) **out = **in } + if in.Configuration != nil { + in, out := &in.Configuration, &out.Configuration + *out = new(SolrCustomConfigurationSpec) + (*in).DeepCopyInto(*out) + } if in.Timeout != nil { in, out := &in.Timeout, &out.Timeout *out = new(v1.Duration) @@ -5093,6 +5334,94 @@ func (in *SolrOpsRequestSpec) DeepCopy() *SolrOpsRequestSpec { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SolrUpdateVersionSpec) DeepCopyInto(out *SolrUpdateVersionSpec) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SolrUpdateVersionSpec. +func (in *SolrUpdateVersionSpec) DeepCopy() *SolrUpdateVersionSpec { + if in == nil { + return nil + } + out := new(SolrUpdateVersionSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SolrVerticalScalingSpec) DeepCopyInto(out *SolrVerticalScalingSpec) { + *out = *in + if in.Node != nil { + in, out := &in.Node, &out.Node + *out = new(PodResources) + (*in).DeepCopyInto(*out) + } + if in.Data != nil { + in, out := &in.Data, &out.Data + *out = new(PodResources) + (*in).DeepCopyInto(*out) + } + if in.Overseer != nil { + in, out := &in.Overseer, &out.Overseer + *out = new(PodResources) + (*in).DeepCopyInto(*out) + } + if in.Coordinator != nil { + in, out := &in.Coordinator, &out.Coordinator + *out = new(PodResources) + (*in).DeepCopyInto(*out) + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SolrVerticalScalingSpec. +func (in *SolrVerticalScalingSpec) DeepCopy() *SolrVerticalScalingSpec { + if in == nil { + return nil + } + out := new(SolrVerticalScalingSpec) + in.DeepCopyInto(out) + return out +} + +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SolrVolumeExpansionSpec) DeepCopyInto(out *SolrVolumeExpansionSpec) { + *out = *in + if in.Node != nil { + in, out := &in.Node, &out.Node + x := (*in).DeepCopy() + *out = &x + } + if in.Data != nil { + in, out := &in.Data, &out.Data + x := (*in).DeepCopy() + *out = &x + } + if in.Overseer != nil { + in, out := &in.Overseer, &out.Overseer + x := (*in).DeepCopy() + *out = &x + } + if in.Coordinator != nil { + in, out := &in.Coordinator, &out.Coordinator + x := (*in).DeepCopy() + *out = &x + } + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SolrVolumeExpansionSpec. +func (in *SolrVolumeExpansionSpec) DeepCopy() *SolrVolumeExpansionSpec { + if in == nil { + return nil + } + out := new(SolrVolumeExpansionSpec) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TLSSpec) DeepCopyInto(out *TLSSpec) { *out = *in diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/archiver/v1alpha1/archiver_client.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/archiver/v1alpha1/archiver_client.go index b9b4486ff..902f22979 100644 --- a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/archiver/v1alpha1/archiver_client.go +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/archiver/v1alpha1/archiver_client.go @@ -29,6 +29,7 @@ import ( type ArchiverV1alpha1Interface interface { RESTClient() rest.Interface + MSSQLServerArchiversGetter MariaDBArchiversGetter MongoDBArchiversGetter MySQLArchiversGetter @@ -40,6 +41,10 @@ type ArchiverV1alpha1Client struct { restClient rest.Interface } +func (c *ArchiverV1alpha1Client) MSSQLServerArchivers(namespace string) MSSQLServerArchiverInterface { + return newMSSQLServerArchivers(c, namespace) +} + func (c *ArchiverV1alpha1Client) MariaDBArchivers(namespace string) MariaDBArchiverInterface { return newMariaDBArchivers(c, namespace) } diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/archiver/v1alpha1/generated_expansion.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/archiver/v1alpha1/generated_expansion.go index 1ab3cc4e4..fd00a485f 100644 --- a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/archiver/v1alpha1/generated_expansion.go +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/archiver/v1alpha1/generated_expansion.go @@ -18,6 +18,8 @@ limitations under the License. package v1alpha1 +type MSSQLServerArchiverExpansion interface{} + type MariaDBArchiverExpansion interface{} type MongoDBArchiverExpansion interface{} diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/archiver/v1alpha1/mssqlserverarchiver.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/archiver/v1alpha1/mssqlserverarchiver.go new file mode 100644 index 000000000..67fa91493 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/archiver/v1alpha1/mssqlserverarchiver.go @@ -0,0 +1,196 @@ +/* +Copyright AppsCode Inc. and Contributors + +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 client-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + "context" + "time" + + v1alpha1 "kubedb.dev/apimachinery/apis/archiver/v1alpha1" + scheme "kubedb.dev/apimachinery/client/clientset/versioned/scheme" + + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" +) + +// MSSQLServerArchiversGetter has a method to return a MSSQLServerArchiverInterface. +// A group's client should implement this interface. +type MSSQLServerArchiversGetter interface { + MSSQLServerArchivers(namespace string) MSSQLServerArchiverInterface +} + +// MSSQLServerArchiverInterface has methods to work with MSSQLServerArchiver resources. +type MSSQLServerArchiverInterface interface { + Create(ctx context.Context, mSSQLServerArchiver *v1alpha1.MSSQLServerArchiver, opts v1.CreateOptions) (*v1alpha1.MSSQLServerArchiver, error) + Update(ctx context.Context, mSSQLServerArchiver *v1alpha1.MSSQLServerArchiver, opts v1.UpdateOptions) (*v1alpha1.MSSQLServerArchiver, error) + UpdateStatus(ctx context.Context, mSSQLServerArchiver *v1alpha1.MSSQLServerArchiver, opts v1.UpdateOptions) (*v1alpha1.MSSQLServerArchiver, error) + Delete(ctx context.Context, name string, opts v1.DeleteOptions) error + DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error + Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.MSSQLServerArchiver, error) + List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.MSSQLServerArchiverList, error) + Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) + Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.MSSQLServerArchiver, err error) + MSSQLServerArchiverExpansion +} + +// mSSQLServerArchivers implements MSSQLServerArchiverInterface +type mSSQLServerArchivers struct { + client rest.Interface + ns string +} + +// newMSSQLServerArchivers returns a MSSQLServerArchivers +func newMSSQLServerArchivers(c *ArchiverV1alpha1Client, namespace string) *mSSQLServerArchivers { + return &mSSQLServerArchivers{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Get takes name of the mSSQLServerArchiver, and returns the corresponding mSSQLServerArchiver object, and an error if there is any. +func (c *mSSQLServerArchivers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.MSSQLServerArchiver, err error) { + result = &v1alpha1.MSSQLServerArchiver{} + err = c.client.Get(). + Namespace(c.ns). + Resource("mssqlserverarchivers"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(ctx). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of MSSQLServerArchivers that match those selectors. +func (c *mSSQLServerArchivers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.MSSQLServerArchiverList, err error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + result = &v1alpha1.MSSQLServerArchiverList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("mssqlserverarchivers"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Do(ctx). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested mSSQLServerArchivers. +func (c *mSSQLServerArchivers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("mssqlserverarchivers"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Watch(ctx) +} + +// Create takes the representation of a mSSQLServerArchiver and creates it. Returns the server's representation of the mSSQLServerArchiver, and an error, if there is any. +func (c *mSSQLServerArchivers) Create(ctx context.Context, mSSQLServerArchiver *v1alpha1.MSSQLServerArchiver, opts v1.CreateOptions) (result *v1alpha1.MSSQLServerArchiver, err error) { + result = &v1alpha1.MSSQLServerArchiver{} + err = c.client.Post(). + Namespace(c.ns). + Resource("mssqlserverarchivers"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(mSSQLServerArchiver). + Do(ctx). + Into(result) + return +} + +// Update takes the representation of a mSSQLServerArchiver and updates it. Returns the server's representation of the mSSQLServerArchiver, and an error, if there is any. +func (c *mSSQLServerArchivers) Update(ctx context.Context, mSSQLServerArchiver *v1alpha1.MSSQLServerArchiver, opts v1.UpdateOptions) (result *v1alpha1.MSSQLServerArchiver, err error) { + result = &v1alpha1.MSSQLServerArchiver{} + err = c.client.Put(). + Namespace(c.ns). + Resource("mssqlserverarchivers"). + Name(mSSQLServerArchiver.Name). + VersionedParams(&opts, scheme.ParameterCodec). + Body(mSSQLServerArchiver). + Do(ctx). + Into(result) + return +} + +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). +func (c *mSSQLServerArchivers) UpdateStatus(ctx context.Context, mSSQLServerArchiver *v1alpha1.MSSQLServerArchiver, opts v1.UpdateOptions) (result *v1alpha1.MSSQLServerArchiver, err error) { + result = &v1alpha1.MSSQLServerArchiver{} + err = c.client.Put(). + Namespace(c.ns). + Resource("mssqlserverarchivers"). + Name(mSSQLServerArchiver.Name). + SubResource("status"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(mSSQLServerArchiver). + Do(ctx). + Into(result) + return +} + +// Delete takes name of the mSSQLServerArchiver and deletes it. Returns an error if one occurs. +func (c *mSSQLServerArchivers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("mssqlserverarchivers"). + Name(name). + Body(&opts). + Do(ctx). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *mSSQLServerArchivers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error { + var timeout time.Duration + if listOpts.TimeoutSeconds != nil { + timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second + } + return c.client.Delete(). + Namespace(c.ns). + Resource("mssqlserverarchivers"). + VersionedParams(&listOpts, scheme.ParameterCodec). + Timeout(timeout). + Body(&opts). + Do(ctx). + Error() +} + +// Patch applies the patch and returns the patched mSSQLServerArchiver. +func (c *mSSQLServerArchivers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.MSSQLServerArchiver, err error) { + result = &v1alpha1.MSSQLServerArchiver{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("mssqlserverarchivers"). + Name(name). + SubResource(subresources...). + VersionedParams(&opts, scheme.ParameterCodec). + Body(data). + Do(ctx). + Into(result) + return +} diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/autoscaling_client.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/autoscaling_client.go index 04bf9d4ee..f0b8c9250 100644 --- a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/autoscaling_client.go +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/autoscaling_client.go @@ -29,10 +29,13 @@ import ( type AutoscalingV1alpha1Interface interface { RESTClient() rest.Interface + ClickHouseAutoscalersGetter DruidAutoscalersGetter ElasticsearchAutoscalersGetter EtcdAutoscalersGetter + FerretDBAutoscalersGetter KafkaAutoscalersGetter + MSSQLServerAutoscalersGetter MariaDBAutoscalersGetter MemcachedAutoscalersGetter MongoDBAutoscalersGetter @@ -46,6 +49,8 @@ type AutoscalingV1alpha1Interface interface { RedisAutoscalersGetter RedisSentinelAutoscalersGetter SinglestoreAutoscalersGetter + SolrAutoscalersGetter + ZooKeeperAutoscalersGetter } // AutoscalingV1alpha1Client is used to interact with features provided by the autoscaling.kubedb.com group. @@ -53,6 +58,10 @@ type AutoscalingV1alpha1Client struct { restClient rest.Interface } +func (c *AutoscalingV1alpha1Client) ClickHouseAutoscalers(namespace string) ClickHouseAutoscalerInterface { + return newClickHouseAutoscalers(c, namespace) +} + func (c *AutoscalingV1alpha1Client) DruidAutoscalers(namespace string) DruidAutoscalerInterface { return newDruidAutoscalers(c, namespace) } @@ -65,10 +74,18 @@ func (c *AutoscalingV1alpha1Client) EtcdAutoscalers(namespace string) EtcdAutosc return newEtcdAutoscalers(c, namespace) } +func (c *AutoscalingV1alpha1Client) FerretDBAutoscalers(namespace string) FerretDBAutoscalerInterface { + return newFerretDBAutoscalers(c, namespace) +} + func (c *AutoscalingV1alpha1Client) KafkaAutoscalers(namespace string) KafkaAutoscalerInterface { return newKafkaAutoscalers(c, namespace) } +func (c *AutoscalingV1alpha1Client) MSSQLServerAutoscalers(namespace string) MSSQLServerAutoscalerInterface { + return newMSSQLServerAutoscalers(c, namespace) +} + func (c *AutoscalingV1alpha1Client) MariaDBAutoscalers(namespace string) MariaDBAutoscalerInterface { return newMariaDBAutoscalers(c, namespace) } @@ -121,6 +138,14 @@ func (c *AutoscalingV1alpha1Client) SinglestoreAutoscalers(namespace string) Sin return newSinglestoreAutoscalers(c, namespace) } +func (c *AutoscalingV1alpha1Client) SolrAutoscalers(namespace string) SolrAutoscalerInterface { + return newSolrAutoscalers(c, namespace) +} + +func (c *AutoscalingV1alpha1Client) ZooKeeperAutoscalers(namespace string) ZooKeeperAutoscalerInterface { + return newZooKeeperAutoscalers(c, namespace) +} + // NewForConfig creates a new AutoscalingV1alpha1Client for the given config. // NewForConfig is equivalent to NewForConfigAndClient(c, httpClient), // where httpClient was generated with rest.HTTPClientFor(c). diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/clickhouseautoscaler.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/clickhouseautoscaler.go new file mode 100644 index 000000000..872ea36ad --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/clickhouseautoscaler.go @@ -0,0 +1,196 @@ +/* +Copyright AppsCode Inc. and Contributors + +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 client-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + "context" + "time" + + v1alpha1 "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1" + scheme "kubedb.dev/apimachinery/client/clientset/versioned/scheme" + + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" +) + +// ClickHouseAutoscalersGetter has a method to return a ClickHouseAutoscalerInterface. +// A group's client should implement this interface. +type ClickHouseAutoscalersGetter interface { + ClickHouseAutoscalers(namespace string) ClickHouseAutoscalerInterface +} + +// ClickHouseAutoscalerInterface has methods to work with ClickHouseAutoscaler resources. +type ClickHouseAutoscalerInterface interface { + Create(ctx context.Context, clickHouseAutoscaler *v1alpha1.ClickHouseAutoscaler, opts v1.CreateOptions) (*v1alpha1.ClickHouseAutoscaler, error) + Update(ctx context.Context, clickHouseAutoscaler *v1alpha1.ClickHouseAutoscaler, opts v1.UpdateOptions) (*v1alpha1.ClickHouseAutoscaler, error) + UpdateStatus(ctx context.Context, clickHouseAutoscaler *v1alpha1.ClickHouseAutoscaler, opts v1.UpdateOptions) (*v1alpha1.ClickHouseAutoscaler, error) + Delete(ctx context.Context, name string, opts v1.DeleteOptions) error + DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error + Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.ClickHouseAutoscaler, error) + List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.ClickHouseAutoscalerList, error) + Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) + Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.ClickHouseAutoscaler, err error) + ClickHouseAutoscalerExpansion +} + +// clickHouseAutoscalers implements ClickHouseAutoscalerInterface +type clickHouseAutoscalers struct { + client rest.Interface + ns string +} + +// newClickHouseAutoscalers returns a ClickHouseAutoscalers +func newClickHouseAutoscalers(c *AutoscalingV1alpha1Client, namespace string) *clickHouseAutoscalers { + return &clickHouseAutoscalers{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Get takes name of the clickHouseAutoscaler, and returns the corresponding clickHouseAutoscaler object, and an error if there is any. +func (c *clickHouseAutoscalers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.ClickHouseAutoscaler, err error) { + result = &v1alpha1.ClickHouseAutoscaler{} + err = c.client.Get(). + Namespace(c.ns). + Resource("clickhouseautoscalers"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(ctx). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of ClickHouseAutoscalers that match those selectors. +func (c *clickHouseAutoscalers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.ClickHouseAutoscalerList, err error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + result = &v1alpha1.ClickHouseAutoscalerList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("clickhouseautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Do(ctx). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested clickHouseAutoscalers. +func (c *clickHouseAutoscalers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("clickhouseautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Watch(ctx) +} + +// Create takes the representation of a clickHouseAutoscaler and creates it. Returns the server's representation of the clickHouseAutoscaler, and an error, if there is any. +func (c *clickHouseAutoscalers) Create(ctx context.Context, clickHouseAutoscaler *v1alpha1.ClickHouseAutoscaler, opts v1.CreateOptions) (result *v1alpha1.ClickHouseAutoscaler, err error) { + result = &v1alpha1.ClickHouseAutoscaler{} + err = c.client.Post(). + Namespace(c.ns). + Resource("clickhouseautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(clickHouseAutoscaler). + Do(ctx). + Into(result) + return +} + +// Update takes the representation of a clickHouseAutoscaler and updates it. Returns the server's representation of the clickHouseAutoscaler, and an error, if there is any. +func (c *clickHouseAutoscalers) Update(ctx context.Context, clickHouseAutoscaler *v1alpha1.ClickHouseAutoscaler, opts v1.UpdateOptions) (result *v1alpha1.ClickHouseAutoscaler, err error) { + result = &v1alpha1.ClickHouseAutoscaler{} + err = c.client.Put(). + Namespace(c.ns). + Resource("clickhouseautoscalers"). + Name(clickHouseAutoscaler.Name). + VersionedParams(&opts, scheme.ParameterCodec). + Body(clickHouseAutoscaler). + Do(ctx). + Into(result) + return +} + +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). +func (c *clickHouseAutoscalers) UpdateStatus(ctx context.Context, clickHouseAutoscaler *v1alpha1.ClickHouseAutoscaler, opts v1.UpdateOptions) (result *v1alpha1.ClickHouseAutoscaler, err error) { + result = &v1alpha1.ClickHouseAutoscaler{} + err = c.client.Put(). + Namespace(c.ns). + Resource("clickhouseautoscalers"). + Name(clickHouseAutoscaler.Name). + SubResource("status"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(clickHouseAutoscaler). + Do(ctx). + Into(result) + return +} + +// Delete takes name of the clickHouseAutoscaler and deletes it. Returns an error if one occurs. +func (c *clickHouseAutoscalers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("clickhouseautoscalers"). + Name(name). + Body(&opts). + Do(ctx). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *clickHouseAutoscalers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error { + var timeout time.Duration + if listOpts.TimeoutSeconds != nil { + timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second + } + return c.client.Delete(). + Namespace(c.ns). + Resource("clickhouseautoscalers"). + VersionedParams(&listOpts, scheme.ParameterCodec). + Timeout(timeout). + Body(&opts). + Do(ctx). + Error() +} + +// Patch applies the patch and returns the patched clickHouseAutoscaler. +func (c *clickHouseAutoscalers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.ClickHouseAutoscaler, err error) { + result = &v1alpha1.ClickHouseAutoscaler{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("clickhouseautoscalers"). + Name(name). + SubResource(subresources...). + VersionedParams(&opts, scheme.ParameterCodec). + Body(data). + Do(ctx). + Into(result) + return +} diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/ferretdbautoscaler.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/ferretdbautoscaler.go new file mode 100644 index 000000000..f861388eb --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/ferretdbautoscaler.go @@ -0,0 +1,196 @@ +/* +Copyright AppsCode Inc. and Contributors + +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 client-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + "context" + "time" + + v1alpha1 "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1" + scheme "kubedb.dev/apimachinery/client/clientset/versioned/scheme" + + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" +) + +// FerretDBAutoscalersGetter has a method to return a FerretDBAutoscalerInterface. +// A group's client should implement this interface. +type FerretDBAutoscalersGetter interface { + FerretDBAutoscalers(namespace string) FerretDBAutoscalerInterface +} + +// FerretDBAutoscalerInterface has methods to work with FerretDBAutoscaler resources. +type FerretDBAutoscalerInterface interface { + Create(ctx context.Context, ferretDBAutoscaler *v1alpha1.FerretDBAutoscaler, opts v1.CreateOptions) (*v1alpha1.FerretDBAutoscaler, error) + Update(ctx context.Context, ferretDBAutoscaler *v1alpha1.FerretDBAutoscaler, opts v1.UpdateOptions) (*v1alpha1.FerretDBAutoscaler, error) + UpdateStatus(ctx context.Context, ferretDBAutoscaler *v1alpha1.FerretDBAutoscaler, opts v1.UpdateOptions) (*v1alpha1.FerretDBAutoscaler, error) + Delete(ctx context.Context, name string, opts v1.DeleteOptions) error + DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error + Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.FerretDBAutoscaler, error) + List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.FerretDBAutoscalerList, error) + Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) + Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.FerretDBAutoscaler, err error) + FerretDBAutoscalerExpansion +} + +// ferretDBAutoscalers implements FerretDBAutoscalerInterface +type ferretDBAutoscalers struct { + client rest.Interface + ns string +} + +// newFerretDBAutoscalers returns a FerretDBAutoscalers +func newFerretDBAutoscalers(c *AutoscalingV1alpha1Client, namespace string) *ferretDBAutoscalers { + return &ferretDBAutoscalers{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Get takes name of the ferretDBAutoscaler, and returns the corresponding ferretDBAutoscaler object, and an error if there is any. +func (c *ferretDBAutoscalers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.FerretDBAutoscaler, err error) { + result = &v1alpha1.FerretDBAutoscaler{} + err = c.client.Get(). + Namespace(c.ns). + Resource("ferretdbautoscalers"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(ctx). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of FerretDBAutoscalers that match those selectors. +func (c *ferretDBAutoscalers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.FerretDBAutoscalerList, err error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + result = &v1alpha1.FerretDBAutoscalerList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("ferretdbautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Do(ctx). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested ferretDBAutoscalers. +func (c *ferretDBAutoscalers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("ferretdbautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Watch(ctx) +} + +// Create takes the representation of a ferretDBAutoscaler and creates it. Returns the server's representation of the ferretDBAutoscaler, and an error, if there is any. +func (c *ferretDBAutoscalers) Create(ctx context.Context, ferretDBAutoscaler *v1alpha1.FerretDBAutoscaler, opts v1.CreateOptions) (result *v1alpha1.FerretDBAutoscaler, err error) { + result = &v1alpha1.FerretDBAutoscaler{} + err = c.client.Post(). + Namespace(c.ns). + Resource("ferretdbautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(ferretDBAutoscaler). + Do(ctx). + Into(result) + return +} + +// Update takes the representation of a ferretDBAutoscaler and updates it. Returns the server's representation of the ferretDBAutoscaler, and an error, if there is any. +func (c *ferretDBAutoscalers) Update(ctx context.Context, ferretDBAutoscaler *v1alpha1.FerretDBAutoscaler, opts v1.UpdateOptions) (result *v1alpha1.FerretDBAutoscaler, err error) { + result = &v1alpha1.FerretDBAutoscaler{} + err = c.client.Put(). + Namespace(c.ns). + Resource("ferretdbautoscalers"). + Name(ferretDBAutoscaler.Name). + VersionedParams(&opts, scheme.ParameterCodec). + Body(ferretDBAutoscaler). + Do(ctx). + Into(result) + return +} + +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). +func (c *ferretDBAutoscalers) UpdateStatus(ctx context.Context, ferretDBAutoscaler *v1alpha1.FerretDBAutoscaler, opts v1.UpdateOptions) (result *v1alpha1.FerretDBAutoscaler, err error) { + result = &v1alpha1.FerretDBAutoscaler{} + err = c.client.Put(). + Namespace(c.ns). + Resource("ferretdbautoscalers"). + Name(ferretDBAutoscaler.Name). + SubResource("status"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(ferretDBAutoscaler). + Do(ctx). + Into(result) + return +} + +// Delete takes name of the ferretDBAutoscaler and deletes it. Returns an error if one occurs. +func (c *ferretDBAutoscalers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("ferretdbautoscalers"). + Name(name). + Body(&opts). + Do(ctx). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *ferretDBAutoscalers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error { + var timeout time.Duration + if listOpts.TimeoutSeconds != nil { + timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second + } + return c.client.Delete(). + Namespace(c.ns). + Resource("ferretdbautoscalers"). + VersionedParams(&listOpts, scheme.ParameterCodec). + Timeout(timeout). + Body(&opts). + Do(ctx). + Error() +} + +// Patch applies the patch and returns the patched ferretDBAutoscaler. +func (c *ferretDBAutoscalers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.FerretDBAutoscaler, err error) { + result = &v1alpha1.FerretDBAutoscaler{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("ferretdbautoscalers"). + Name(name). + SubResource(subresources...). + VersionedParams(&opts, scheme.ParameterCodec). + Body(data). + Do(ctx). + Into(result) + return +} diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/generated_expansion.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/generated_expansion.go index ea5cb5228..e3467456f 100644 --- a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/generated_expansion.go +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/generated_expansion.go @@ -18,14 +18,20 @@ limitations under the License. package v1alpha1 +type ClickHouseAutoscalerExpansion interface{} + type DruidAutoscalerExpansion interface{} type ElasticsearchAutoscalerExpansion interface{} type EtcdAutoscalerExpansion interface{} +type FerretDBAutoscalerExpansion interface{} + type KafkaAutoscalerExpansion interface{} +type MSSQLServerAutoscalerExpansion interface{} + type MariaDBAutoscalerExpansion interface{} type MemcachedAutoscalerExpansion interface{} @@ -51,3 +57,7 @@ type RedisAutoscalerExpansion interface{} type RedisSentinelAutoscalerExpansion interface{} type SinglestoreAutoscalerExpansion interface{} + +type SolrAutoscalerExpansion interface{} + +type ZooKeeperAutoscalerExpansion interface{} diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/mssqlserverautoscaler.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/mssqlserverautoscaler.go new file mode 100644 index 000000000..d217c126f --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/mssqlserverautoscaler.go @@ -0,0 +1,196 @@ +/* +Copyright AppsCode Inc. and Contributors + +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 client-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + "context" + "time" + + v1alpha1 "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1" + scheme "kubedb.dev/apimachinery/client/clientset/versioned/scheme" + + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" +) + +// MSSQLServerAutoscalersGetter has a method to return a MSSQLServerAutoscalerInterface. +// A group's client should implement this interface. +type MSSQLServerAutoscalersGetter interface { + MSSQLServerAutoscalers(namespace string) MSSQLServerAutoscalerInterface +} + +// MSSQLServerAutoscalerInterface has methods to work with MSSQLServerAutoscaler resources. +type MSSQLServerAutoscalerInterface interface { + Create(ctx context.Context, mSSQLServerAutoscaler *v1alpha1.MSSQLServerAutoscaler, opts v1.CreateOptions) (*v1alpha1.MSSQLServerAutoscaler, error) + Update(ctx context.Context, mSSQLServerAutoscaler *v1alpha1.MSSQLServerAutoscaler, opts v1.UpdateOptions) (*v1alpha1.MSSQLServerAutoscaler, error) + UpdateStatus(ctx context.Context, mSSQLServerAutoscaler *v1alpha1.MSSQLServerAutoscaler, opts v1.UpdateOptions) (*v1alpha1.MSSQLServerAutoscaler, error) + Delete(ctx context.Context, name string, opts v1.DeleteOptions) error + DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error + Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.MSSQLServerAutoscaler, error) + List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.MSSQLServerAutoscalerList, error) + Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) + Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.MSSQLServerAutoscaler, err error) + MSSQLServerAutoscalerExpansion +} + +// mSSQLServerAutoscalers implements MSSQLServerAutoscalerInterface +type mSSQLServerAutoscalers struct { + client rest.Interface + ns string +} + +// newMSSQLServerAutoscalers returns a MSSQLServerAutoscalers +func newMSSQLServerAutoscalers(c *AutoscalingV1alpha1Client, namespace string) *mSSQLServerAutoscalers { + return &mSSQLServerAutoscalers{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Get takes name of the mSSQLServerAutoscaler, and returns the corresponding mSSQLServerAutoscaler object, and an error if there is any. +func (c *mSSQLServerAutoscalers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.MSSQLServerAutoscaler, err error) { + result = &v1alpha1.MSSQLServerAutoscaler{} + err = c.client.Get(). + Namespace(c.ns). + Resource("mssqlserverautoscalers"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(ctx). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of MSSQLServerAutoscalers that match those selectors. +func (c *mSSQLServerAutoscalers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.MSSQLServerAutoscalerList, err error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + result = &v1alpha1.MSSQLServerAutoscalerList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("mssqlserverautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Do(ctx). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested mSSQLServerAutoscalers. +func (c *mSSQLServerAutoscalers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("mssqlserverautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Watch(ctx) +} + +// Create takes the representation of a mSSQLServerAutoscaler and creates it. Returns the server's representation of the mSSQLServerAutoscaler, and an error, if there is any. +func (c *mSSQLServerAutoscalers) Create(ctx context.Context, mSSQLServerAutoscaler *v1alpha1.MSSQLServerAutoscaler, opts v1.CreateOptions) (result *v1alpha1.MSSQLServerAutoscaler, err error) { + result = &v1alpha1.MSSQLServerAutoscaler{} + err = c.client.Post(). + Namespace(c.ns). + Resource("mssqlserverautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(mSSQLServerAutoscaler). + Do(ctx). + Into(result) + return +} + +// Update takes the representation of a mSSQLServerAutoscaler and updates it. Returns the server's representation of the mSSQLServerAutoscaler, and an error, if there is any. +func (c *mSSQLServerAutoscalers) Update(ctx context.Context, mSSQLServerAutoscaler *v1alpha1.MSSQLServerAutoscaler, opts v1.UpdateOptions) (result *v1alpha1.MSSQLServerAutoscaler, err error) { + result = &v1alpha1.MSSQLServerAutoscaler{} + err = c.client.Put(). + Namespace(c.ns). + Resource("mssqlserverautoscalers"). + Name(mSSQLServerAutoscaler.Name). + VersionedParams(&opts, scheme.ParameterCodec). + Body(mSSQLServerAutoscaler). + Do(ctx). + Into(result) + return +} + +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). +func (c *mSSQLServerAutoscalers) UpdateStatus(ctx context.Context, mSSQLServerAutoscaler *v1alpha1.MSSQLServerAutoscaler, opts v1.UpdateOptions) (result *v1alpha1.MSSQLServerAutoscaler, err error) { + result = &v1alpha1.MSSQLServerAutoscaler{} + err = c.client.Put(). + Namespace(c.ns). + Resource("mssqlserverautoscalers"). + Name(mSSQLServerAutoscaler.Name). + SubResource("status"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(mSSQLServerAutoscaler). + Do(ctx). + Into(result) + return +} + +// Delete takes name of the mSSQLServerAutoscaler and deletes it. Returns an error if one occurs. +func (c *mSSQLServerAutoscalers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("mssqlserverautoscalers"). + Name(name). + Body(&opts). + Do(ctx). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *mSSQLServerAutoscalers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error { + var timeout time.Duration + if listOpts.TimeoutSeconds != nil { + timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second + } + return c.client.Delete(). + Namespace(c.ns). + Resource("mssqlserverautoscalers"). + VersionedParams(&listOpts, scheme.ParameterCodec). + Timeout(timeout). + Body(&opts). + Do(ctx). + Error() +} + +// Patch applies the patch and returns the patched mSSQLServerAutoscaler. +func (c *mSSQLServerAutoscalers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.MSSQLServerAutoscaler, err error) { + result = &v1alpha1.MSSQLServerAutoscaler{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("mssqlserverautoscalers"). + Name(name). + SubResource(subresources...). + VersionedParams(&opts, scheme.ParameterCodec). + Body(data). + Do(ctx). + Into(result) + return +} diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/solrautoscaler.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/solrautoscaler.go new file mode 100644 index 000000000..fa9e5dc8b --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/solrautoscaler.go @@ -0,0 +1,196 @@ +/* +Copyright AppsCode Inc. and Contributors + +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 client-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + "context" + "time" + + v1alpha1 "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1" + scheme "kubedb.dev/apimachinery/client/clientset/versioned/scheme" + + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" +) + +// SolrAutoscalersGetter has a method to return a SolrAutoscalerInterface. +// A group's client should implement this interface. +type SolrAutoscalersGetter interface { + SolrAutoscalers(namespace string) SolrAutoscalerInterface +} + +// SolrAutoscalerInterface has methods to work with SolrAutoscaler resources. +type SolrAutoscalerInterface interface { + Create(ctx context.Context, solrAutoscaler *v1alpha1.SolrAutoscaler, opts v1.CreateOptions) (*v1alpha1.SolrAutoscaler, error) + Update(ctx context.Context, solrAutoscaler *v1alpha1.SolrAutoscaler, opts v1.UpdateOptions) (*v1alpha1.SolrAutoscaler, error) + UpdateStatus(ctx context.Context, solrAutoscaler *v1alpha1.SolrAutoscaler, opts v1.UpdateOptions) (*v1alpha1.SolrAutoscaler, error) + Delete(ctx context.Context, name string, opts v1.DeleteOptions) error + DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error + Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.SolrAutoscaler, error) + List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.SolrAutoscalerList, error) + Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) + Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.SolrAutoscaler, err error) + SolrAutoscalerExpansion +} + +// solrAutoscalers implements SolrAutoscalerInterface +type solrAutoscalers struct { + client rest.Interface + ns string +} + +// newSolrAutoscalers returns a SolrAutoscalers +func newSolrAutoscalers(c *AutoscalingV1alpha1Client, namespace string) *solrAutoscalers { + return &solrAutoscalers{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Get takes name of the solrAutoscaler, and returns the corresponding solrAutoscaler object, and an error if there is any. +func (c *solrAutoscalers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.SolrAutoscaler, err error) { + result = &v1alpha1.SolrAutoscaler{} + err = c.client.Get(). + Namespace(c.ns). + Resource("solrautoscalers"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(ctx). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of SolrAutoscalers that match those selectors. +func (c *solrAutoscalers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.SolrAutoscalerList, err error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + result = &v1alpha1.SolrAutoscalerList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("solrautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Do(ctx). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested solrAutoscalers. +func (c *solrAutoscalers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("solrautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Watch(ctx) +} + +// Create takes the representation of a solrAutoscaler and creates it. Returns the server's representation of the solrAutoscaler, and an error, if there is any. +func (c *solrAutoscalers) Create(ctx context.Context, solrAutoscaler *v1alpha1.SolrAutoscaler, opts v1.CreateOptions) (result *v1alpha1.SolrAutoscaler, err error) { + result = &v1alpha1.SolrAutoscaler{} + err = c.client.Post(). + Namespace(c.ns). + Resource("solrautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(solrAutoscaler). + Do(ctx). + Into(result) + return +} + +// Update takes the representation of a solrAutoscaler and updates it. Returns the server's representation of the solrAutoscaler, and an error, if there is any. +func (c *solrAutoscalers) Update(ctx context.Context, solrAutoscaler *v1alpha1.SolrAutoscaler, opts v1.UpdateOptions) (result *v1alpha1.SolrAutoscaler, err error) { + result = &v1alpha1.SolrAutoscaler{} + err = c.client.Put(). + Namespace(c.ns). + Resource("solrautoscalers"). + Name(solrAutoscaler.Name). + VersionedParams(&opts, scheme.ParameterCodec). + Body(solrAutoscaler). + Do(ctx). + Into(result) + return +} + +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). +func (c *solrAutoscalers) UpdateStatus(ctx context.Context, solrAutoscaler *v1alpha1.SolrAutoscaler, opts v1.UpdateOptions) (result *v1alpha1.SolrAutoscaler, err error) { + result = &v1alpha1.SolrAutoscaler{} + err = c.client.Put(). + Namespace(c.ns). + Resource("solrautoscalers"). + Name(solrAutoscaler.Name). + SubResource("status"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(solrAutoscaler). + Do(ctx). + Into(result) + return +} + +// Delete takes name of the solrAutoscaler and deletes it. Returns an error if one occurs. +func (c *solrAutoscalers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("solrautoscalers"). + Name(name). + Body(&opts). + Do(ctx). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *solrAutoscalers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error { + var timeout time.Duration + if listOpts.TimeoutSeconds != nil { + timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second + } + return c.client.Delete(). + Namespace(c.ns). + Resource("solrautoscalers"). + VersionedParams(&listOpts, scheme.ParameterCodec). + Timeout(timeout). + Body(&opts). + Do(ctx). + Error() +} + +// Patch applies the patch and returns the patched solrAutoscaler. +func (c *solrAutoscalers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.SolrAutoscaler, err error) { + result = &v1alpha1.SolrAutoscaler{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("solrautoscalers"). + Name(name). + SubResource(subresources...). + VersionedParams(&opts, scheme.ParameterCodec). + Body(data). + Do(ctx). + Into(result) + return +} diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/zookeeperautoscaler.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/zookeeperautoscaler.go new file mode 100644 index 000000000..857f47747 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/autoscaling/v1alpha1/zookeeperautoscaler.go @@ -0,0 +1,196 @@ +/* +Copyright AppsCode Inc. and Contributors + +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 client-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + "context" + "time" + + v1alpha1 "kubedb.dev/apimachinery/apis/autoscaling/v1alpha1" + scheme "kubedb.dev/apimachinery/client/clientset/versioned/scheme" + + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" +) + +// ZooKeeperAutoscalersGetter has a method to return a ZooKeeperAutoscalerInterface. +// A group's client should implement this interface. +type ZooKeeperAutoscalersGetter interface { + ZooKeeperAutoscalers(namespace string) ZooKeeperAutoscalerInterface +} + +// ZooKeeperAutoscalerInterface has methods to work with ZooKeeperAutoscaler resources. +type ZooKeeperAutoscalerInterface interface { + Create(ctx context.Context, zooKeeperAutoscaler *v1alpha1.ZooKeeperAutoscaler, opts v1.CreateOptions) (*v1alpha1.ZooKeeperAutoscaler, error) + Update(ctx context.Context, zooKeeperAutoscaler *v1alpha1.ZooKeeperAutoscaler, opts v1.UpdateOptions) (*v1alpha1.ZooKeeperAutoscaler, error) + UpdateStatus(ctx context.Context, zooKeeperAutoscaler *v1alpha1.ZooKeeperAutoscaler, opts v1.UpdateOptions) (*v1alpha1.ZooKeeperAutoscaler, error) + Delete(ctx context.Context, name string, opts v1.DeleteOptions) error + DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error + Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.ZooKeeperAutoscaler, error) + List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.ZooKeeperAutoscalerList, error) + Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) + Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.ZooKeeperAutoscaler, err error) + ZooKeeperAutoscalerExpansion +} + +// zooKeeperAutoscalers implements ZooKeeperAutoscalerInterface +type zooKeeperAutoscalers struct { + client rest.Interface + ns string +} + +// newZooKeeperAutoscalers returns a ZooKeeperAutoscalers +func newZooKeeperAutoscalers(c *AutoscalingV1alpha1Client, namespace string) *zooKeeperAutoscalers { + return &zooKeeperAutoscalers{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Get takes name of the zooKeeperAutoscaler, and returns the corresponding zooKeeperAutoscaler object, and an error if there is any. +func (c *zooKeeperAutoscalers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.ZooKeeperAutoscaler, err error) { + result = &v1alpha1.ZooKeeperAutoscaler{} + err = c.client.Get(). + Namespace(c.ns). + Resource("zookeeperautoscalers"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(ctx). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of ZooKeeperAutoscalers that match those selectors. +func (c *zooKeeperAutoscalers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.ZooKeeperAutoscalerList, err error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + result = &v1alpha1.ZooKeeperAutoscalerList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("zookeeperautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Do(ctx). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested zooKeeperAutoscalers. +func (c *zooKeeperAutoscalers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("zookeeperautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Watch(ctx) +} + +// Create takes the representation of a zooKeeperAutoscaler and creates it. Returns the server's representation of the zooKeeperAutoscaler, and an error, if there is any. +func (c *zooKeeperAutoscalers) Create(ctx context.Context, zooKeeperAutoscaler *v1alpha1.ZooKeeperAutoscaler, opts v1.CreateOptions) (result *v1alpha1.ZooKeeperAutoscaler, err error) { + result = &v1alpha1.ZooKeeperAutoscaler{} + err = c.client.Post(). + Namespace(c.ns). + Resource("zookeeperautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(zooKeeperAutoscaler). + Do(ctx). + Into(result) + return +} + +// Update takes the representation of a zooKeeperAutoscaler and updates it. Returns the server's representation of the zooKeeperAutoscaler, and an error, if there is any. +func (c *zooKeeperAutoscalers) Update(ctx context.Context, zooKeeperAutoscaler *v1alpha1.ZooKeeperAutoscaler, opts v1.UpdateOptions) (result *v1alpha1.ZooKeeperAutoscaler, err error) { + result = &v1alpha1.ZooKeeperAutoscaler{} + err = c.client.Put(). + Namespace(c.ns). + Resource("zookeeperautoscalers"). + Name(zooKeeperAutoscaler.Name). + VersionedParams(&opts, scheme.ParameterCodec). + Body(zooKeeperAutoscaler). + Do(ctx). + Into(result) + return +} + +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). +func (c *zooKeeperAutoscalers) UpdateStatus(ctx context.Context, zooKeeperAutoscaler *v1alpha1.ZooKeeperAutoscaler, opts v1.UpdateOptions) (result *v1alpha1.ZooKeeperAutoscaler, err error) { + result = &v1alpha1.ZooKeeperAutoscaler{} + err = c.client.Put(). + Namespace(c.ns). + Resource("zookeeperautoscalers"). + Name(zooKeeperAutoscaler.Name). + SubResource("status"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(zooKeeperAutoscaler). + Do(ctx). + Into(result) + return +} + +// Delete takes name of the zooKeeperAutoscaler and deletes it. Returns an error if one occurs. +func (c *zooKeeperAutoscalers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("zookeeperautoscalers"). + Name(name). + Body(&opts). + Do(ctx). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *zooKeeperAutoscalers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error { + var timeout time.Duration + if listOpts.TimeoutSeconds != nil { + timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second + } + return c.client.Delete(). + Namespace(c.ns). + Resource("zookeeperautoscalers"). + VersionedParams(&listOpts, scheme.ParameterCodec). + Timeout(timeout). + Body(&opts). + Do(ctx). + Error() +} + +// Patch applies the patch and returns the patched zooKeeperAutoscaler. +func (c *zooKeeperAutoscalers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.ZooKeeperAutoscaler, err error) { + result = &v1alpha1.ZooKeeperAutoscaler{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("zookeeperautoscalers"). + Name(name). + SubResource(subresources...). + VersionedParams(&opts, scheme.ParameterCodec). + Body(data). + Do(ctx). + Into(result) + return +} diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/kafka/v1alpha1/generated_expansion.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/kafka/v1alpha1/generated_expansion.go index b8df56845..2113df9d8 100644 --- a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/kafka/v1alpha1/generated_expansion.go +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/kafka/v1alpha1/generated_expansion.go @@ -22,4 +22,6 @@ type ConnectClusterExpansion interface{} type ConnectorExpansion interface{} +type RestProxyExpansion interface{} + type SchemaRegistryExpansion interface{} diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/kafka/v1alpha1/kafka_client.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/kafka/v1alpha1/kafka_client.go index d547431fa..0cfeb9726 100644 --- a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/kafka/v1alpha1/kafka_client.go +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/kafka/v1alpha1/kafka_client.go @@ -31,6 +31,7 @@ type KafkaV1alpha1Interface interface { RESTClient() rest.Interface ConnectClustersGetter ConnectorsGetter + RestProxiesGetter SchemaRegistriesGetter } @@ -47,6 +48,10 @@ func (c *KafkaV1alpha1Client) Connectors(namespace string) ConnectorInterface { return newConnectors(c, namespace) } +func (c *KafkaV1alpha1Client) RestProxies(namespace string) RestProxyInterface { + return newRestProxies(c, namespace) +} + func (c *KafkaV1alpha1Client) SchemaRegistries(namespace string) SchemaRegistryInterface { return newSchemaRegistries(c, namespace) } diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/kafka/v1alpha1/restproxy.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/kafka/v1alpha1/restproxy.go new file mode 100644 index 000000000..acd0474b4 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/kafka/v1alpha1/restproxy.go @@ -0,0 +1,196 @@ +/* +Copyright AppsCode Inc. and Contributors + +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 client-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + "context" + "time" + + v1alpha1 "kubedb.dev/apimachinery/apis/kafka/v1alpha1" + scheme "kubedb.dev/apimachinery/client/clientset/versioned/scheme" + + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" +) + +// RestProxiesGetter has a method to return a RestProxyInterface. +// A group's client should implement this interface. +type RestProxiesGetter interface { + RestProxies(namespace string) RestProxyInterface +} + +// RestProxyInterface has methods to work with RestProxy resources. +type RestProxyInterface interface { + Create(ctx context.Context, restProxy *v1alpha1.RestProxy, opts v1.CreateOptions) (*v1alpha1.RestProxy, error) + Update(ctx context.Context, restProxy *v1alpha1.RestProxy, opts v1.UpdateOptions) (*v1alpha1.RestProxy, error) + UpdateStatus(ctx context.Context, restProxy *v1alpha1.RestProxy, opts v1.UpdateOptions) (*v1alpha1.RestProxy, error) + Delete(ctx context.Context, name string, opts v1.DeleteOptions) error + DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error + Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.RestProxy, error) + List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.RestProxyList, error) + Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) + Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.RestProxy, err error) + RestProxyExpansion +} + +// restProxies implements RestProxyInterface +type restProxies struct { + client rest.Interface + ns string +} + +// newRestProxies returns a RestProxies +func newRestProxies(c *KafkaV1alpha1Client, namespace string) *restProxies { + return &restProxies{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Get takes name of the restProxy, and returns the corresponding restProxy object, and an error if there is any. +func (c *restProxies) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.RestProxy, err error) { + result = &v1alpha1.RestProxy{} + err = c.client.Get(). + Namespace(c.ns). + Resource("restproxies"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(ctx). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of RestProxies that match those selectors. +func (c *restProxies) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.RestProxyList, err error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + result = &v1alpha1.RestProxyList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("restproxies"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Do(ctx). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested restProxies. +func (c *restProxies) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("restproxies"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Watch(ctx) +} + +// Create takes the representation of a restProxy and creates it. Returns the server's representation of the restProxy, and an error, if there is any. +func (c *restProxies) Create(ctx context.Context, restProxy *v1alpha1.RestProxy, opts v1.CreateOptions) (result *v1alpha1.RestProxy, err error) { + result = &v1alpha1.RestProxy{} + err = c.client.Post(). + Namespace(c.ns). + Resource("restproxies"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(restProxy). + Do(ctx). + Into(result) + return +} + +// Update takes the representation of a restProxy and updates it. Returns the server's representation of the restProxy, and an error, if there is any. +func (c *restProxies) Update(ctx context.Context, restProxy *v1alpha1.RestProxy, opts v1.UpdateOptions) (result *v1alpha1.RestProxy, err error) { + result = &v1alpha1.RestProxy{} + err = c.client.Put(). + Namespace(c.ns). + Resource("restproxies"). + Name(restProxy.Name). + VersionedParams(&opts, scheme.ParameterCodec). + Body(restProxy). + Do(ctx). + Into(result) + return +} + +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). +func (c *restProxies) UpdateStatus(ctx context.Context, restProxy *v1alpha1.RestProxy, opts v1.UpdateOptions) (result *v1alpha1.RestProxy, err error) { + result = &v1alpha1.RestProxy{} + err = c.client.Put(). + Namespace(c.ns). + Resource("restproxies"). + Name(restProxy.Name). + SubResource("status"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(restProxy). + Do(ctx). + Into(result) + return +} + +// Delete takes name of the restProxy and deletes it. Returns an error if one occurs. +func (c *restProxies) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("restproxies"). + Name(name). + Body(&opts). + Do(ctx). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *restProxies) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error { + var timeout time.Duration + if listOpts.TimeoutSeconds != nil { + timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second + } + return c.client.Delete(). + Namespace(c.ns). + Resource("restproxies"). + VersionedParams(&listOpts, scheme.ParameterCodec). + Timeout(timeout). + Body(&opts). + Do(ctx). + Error() +} + +// Patch applies the patch and returns the patched restProxy. +func (c *restProxies) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.RestProxy, err error) { + result = &v1alpha1.RestProxy{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("restproxies"). + Name(name). + SubResource(subresources...). + VersionedParams(&opts, scheme.ParameterCodec). + Body(data). + Do(ctx). + Into(result) + return +} diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/ops/v1alpha1/ferretdbopsrequest.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/ops/v1alpha1/ferretdbopsrequest.go new file mode 100644 index 000000000..b986c5ead --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/ops/v1alpha1/ferretdbopsrequest.go @@ -0,0 +1,196 @@ +/* +Copyright AppsCode Inc. and Contributors + +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 client-gen. DO NOT EDIT. + +package v1alpha1 + +import ( + "context" + "time" + + v1alpha1 "kubedb.dev/apimachinery/apis/ops/v1alpha1" + scheme "kubedb.dev/apimachinery/client/clientset/versioned/scheme" + + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + rest "k8s.io/client-go/rest" +) + +// FerretDBOpsRequestsGetter has a method to return a FerretDBOpsRequestInterface. +// A group's client should implement this interface. +type FerretDBOpsRequestsGetter interface { + FerretDBOpsRequests(namespace string) FerretDBOpsRequestInterface +} + +// FerretDBOpsRequestInterface has methods to work with FerretDBOpsRequest resources. +type FerretDBOpsRequestInterface interface { + Create(ctx context.Context, ferretDBOpsRequest *v1alpha1.FerretDBOpsRequest, opts v1.CreateOptions) (*v1alpha1.FerretDBOpsRequest, error) + Update(ctx context.Context, ferretDBOpsRequest *v1alpha1.FerretDBOpsRequest, opts v1.UpdateOptions) (*v1alpha1.FerretDBOpsRequest, error) + UpdateStatus(ctx context.Context, ferretDBOpsRequest *v1alpha1.FerretDBOpsRequest, opts v1.UpdateOptions) (*v1alpha1.FerretDBOpsRequest, error) + Delete(ctx context.Context, name string, opts v1.DeleteOptions) error + DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error + Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.FerretDBOpsRequest, error) + List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.FerretDBOpsRequestList, error) + Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) + Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.FerretDBOpsRequest, err error) + FerretDBOpsRequestExpansion +} + +// ferretDBOpsRequests implements FerretDBOpsRequestInterface +type ferretDBOpsRequests struct { + client rest.Interface + ns string +} + +// newFerretDBOpsRequests returns a FerretDBOpsRequests +func newFerretDBOpsRequests(c *OpsV1alpha1Client, namespace string) *ferretDBOpsRequests { + return &ferretDBOpsRequests{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Get takes name of the ferretDBOpsRequest, and returns the corresponding ferretDBOpsRequest object, and an error if there is any. +func (c *ferretDBOpsRequests) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.FerretDBOpsRequest, err error) { + result = &v1alpha1.FerretDBOpsRequest{} + err = c.client.Get(). + Namespace(c.ns). + Resource("ferretdbopsrequests"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(ctx). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of FerretDBOpsRequests that match those selectors. +func (c *ferretDBOpsRequests) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.FerretDBOpsRequestList, err error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + result = &v1alpha1.FerretDBOpsRequestList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("ferretdbopsrequests"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Do(ctx). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested ferretDBOpsRequests. +func (c *ferretDBOpsRequests) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) { + var timeout time.Duration + if opts.TimeoutSeconds != nil { + timeout = time.Duration(*opts.TimeoutSeconds) * time.Second + } + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("ferretdbopsrequests"). + VersionedParams(&opts, scheme.ParameterCodec). + Timeout(timeout). + Watch(ctx) +} + +// Create takes the representation of a ferretDBOpsRequest and creates it. Returns the server's representation of the ferretDBOpsRequest, and an error, if there is any. +func (c *ferretDBOpsRequests) Create(ctx context.Context, ferretDBOpsRequest *v1alpha1.FerretDBOpsRequest, opts v1.CreateOptions) (result *v1alpha1.FerretDBOpsRequest, err error) { + result = &v1alpha1.FerretDBOpsRequest{} + err = c.client.Post(). + Namespace(c.ns). + Resource("ferretdbopsrequests"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(ferretDBOpsRequest). + Do(ctx). + Into(result) + return +} + +// Update takes the representation of a ferretDBOpsRequest and updates it. Returns the server's representation of the ferretDBOpsRequest, and an error, if there is any. +func (c *ferretDBOpsRequests) Update(ctx context.Context, ferretDBOpsRequest *v1alpha1.FerretDBOpsRequest, opts v1.UpdateOptions) (result *v1alpha1.FerretDBOpsRequest, err error) { + result = &v1alpha1.FerretDBOpsRequest{} + err = c.client.Put(). + Namespace(c.ns). + Resource("ferretdbopsrequests"). + Name(ferretDBOpsRequest.Name). + VersionedParams(&opts, scheme.ParameterCodec). + Body(ferretDBOpsRequest). + Do(ctx). + Into(result) + return +} + +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). +func (c *ferretDBOpsRequests) UpdateStatus(ctx context.Context, ferretDBOpsRequest *v1alpha1.FerretDBOpsRequest, opts v1.UpdateOptions) (result *v1alpha1.FerretDBOpsRequest, err error) { + result = &v1alpha1.FerretDBOpsRequest{} + err = c.client.Put(). + Namespace(c.ns). + Resource("ferretdbopsrequests"). + Name(ferretDBOpsRequest.Name). + SubResource("status"). + VersionedParams(&opts, scheme.ParameterCodec). + Body(ferretDBOpsRequest). + Do(ctx). + Into(result) + return +} + +// Delete takes name of the ferretDBOpsRequest and deletes it. Returns an error if one occurs. +func (c *ferretDBOpsRequests) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("ferretdbopsrequests"). + Name(name). + Body(&opts). + Do(ctx). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *ferretDBOpsRequests) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error { + var timeout time.Duration + if listOpts.TimeoutSeconds != nil { + timeout = time.Duration(*listOpts.TimeoutSeconds) * time.Second + } + return c.client.Delete(). + Namespace(c.ns). + Resource("ferretdbopsrequests"). + VersionedParams(&listOpts, scheme.ParameterCodec). + Timeout(timeout). + Body(&opts). + Do(ctx). + Error() +} + +// Patch applies the patch and returns the patched ferretDBOpsRequest. +func (c *ferretDBOpsRequests) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.FerretDBOpsRequest, err error) { + result = &v1alpha1.FerretDBOpsRequest{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("ferretdbopsrequests"). + Name(name). + SubResource(subresources...). + VersionedParams(&opts, scheme.ParameterCodec). + Body(data). + Do(ctx). + Into(result) + return +} diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/ops/v1alpha1/generated_expansion.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/ops/v1alpha1/generated_expansion.go index e47b8248f..65ed3e73d 100644 --- a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/ops/v1alpha1/generated_expansion.go +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/ops/v1alpha1/generated_expansion.go @@ -24,6 +24,8 @@ type ElasticsearchOpsRequestExpansion interface{} type EtcdOpsRequestExpansion interface{} +type FerretDBOpsRequestExpansion interface{} + type KafkaOpsRequestExpansion interface{} type MariaDBOpsRequestExpansion interface{} diff --git a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/ops/v1alpha1/ops_client.go b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/ops/v1alpha1/ops_client.go index 74cd3315f..e58eb6f70 100644 --- a/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/ops/v1alpha1/ops_client.go +++ b/vendor/kubedb.dev/apimachinery/client/clientset/versioned/typed/ops/v1alpha1/ops_client.go @@ -32,6 +32,7 @@ type OpsV1alpha1Interface interface { DruidOpsRequestsGetter ElasticsearchOpsRequestsGetter EtcdOpsRequestsGetter + FerretDBOpsRequestsGetter KafkaOpsRequestsGetter MariaDBOpsRequestsGetter MemcachedOpsRequestsGetter @@ -66,6 +67,10 @@ func (c *OpsV1alpha1Client) EtcdOpsRequests(namespace string) EtcdOpsRequestInte return newEtcdOpsRequests(c, namespace) } +func (c *OpsV1alpha1Client) FerretDBOpsRequests(namespace string) FerretDBOpsRequestInterface { + return newFerretDBOpsRequests(c, namespace) +} + func (c *OpsV1alpha1Client) KafkaOpsRequests(namespace string) KafkaOpsRequestInterface { return newKafkaOpsRequests(c, namespace) } diff --git a/vendor/kubedb.dev/apimachinery/crds/archiver.kubedb.com_mssqlserverarchivers.yaml b/vendor/kubedb.dev/apimachinery/crds/archiver.kubedb.com_mssqlserverarchivers.yaml new file mode 100644 index 000000000..c13cdee89 --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/crds/archiver.kubedb.com_mssqlserverarchivers.yaml @@ -0,0 +1,12961 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + creationTimestamp: null + labels: + app.kubernetes.io/name: kubedb + name: mssqlserverarchivers.archiver.kubedb.com +spec: + group: archiver.kubedb.com + names: + categories: + - archiver + - kubedb + - appscode + kind: MSSQLServerArchiver + listKind: MSSQLServerArchiverList + plural: mssqlserverarchivers + shortNames: + - msarchiver + singular: mssqlserverarchiver + scope: Namespaced + versions: + - name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + properties: + backupStorage: + properties: + ref: + properties: + name: + type: string + namespace: + type: string + required: + - name + type: object + subDir: + type: string + type: object + databases: + properties: + namespaces: + default: + from: Same + properties: + from: + default: Same + enum: + - All + - Selector + - Same + type: string + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + type: object + deletionPolicy: + enum: + - Delete + - WipeOut + - DoNotDelete + type: string + encryptionSecret: + properties: + name: + type: string + namespace: + type: string + required: + - name + type: object + fullBackup: + properties: + containerRuntimeSettings: + properties: + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + ionice: + properties: + class: + format: int32 + type: integer + classData: + format: int32 + type: integer + type: object + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + nice: + properties: + adjustment: + format: int32 + type: integer + type: object + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + type: object + driver: + default: VolumeSnapshotter + enum: + - Restic + - WalG + - VolumeSnapshotter + type: string + jobTemplate: + properties: + controller: + properties: + annotations: + additionalProperties: + type: string + type: object + labels: + additionalProperties: + type: string + type: object + type: object + metadata: + properties: + annotations: + additionalProperties: + type: string + type: object + labels: + additionalProperties: + type: string + type: object + type: object + spec: + properties: + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + args: + items: + type: string + type: array + containerSecurityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + podPlacementPolicy: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + runtimeClassName: + type: string + schedulerName: + type: string + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccountName: + type: string + shareProcessNamespace: + type: boolean + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + type: string + kind: + type: string + readOnly: + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + properties: + annotations: + additionalProperties: + type: string + type: object + generateName: + type: string + labels: + additionalProperties: + type: string + type: object + name: + type: string + namespace: + type: string + ownerReferences: + items: + properties: + apiVersion: + type: string + blockOwnerDeletion: + type: boolean + controller: + type: boolean + kind: + type: string + name: + type: string + uid: + type: string + required: + - apiVersion + - kind + - name + - uid + type: object + x-kubernetes-map-type: atomic + type: array + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + type: object + type: object + retryConfig: + properties: + delay: + type: string + maxRetry: + default: 1 + format: int32 + minimum: 1 + type: integer + type: object + scheduler: + properties: + concurrencyPolicy: + type: string + failedJobsHistoryLimit: + format: int32 + type: integer + jobTemplate: + properties: + activeDeadlineSeconds: + format: int64 + type: integer + backoffLimit: + format: int32 + type: integer + completionMode: + type: string + completions: + format: int32 + type: integer + parallelism: + format: int32 + type: integer + suspend: + type: boolean + template: + properties: + controller: + properties: + annotations: + additionalProperties: + type: string + type: object + labels: + additionalProperties: + type: string + type: object + type: object + metadata: + properties: + annotations: + additionalProperties: + type: string + type: object + labels: + additionalProperties: + type: string + type: object + type: object + spec: + properties: + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + args: + items: + type: string + type: array + containerSecurityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + podPlacementPolicy: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + runtimeClassName: + type: string + schedulerName: + type: string + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccountName: + type: string + shareProcessNamespace: + type: boolean + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + type: string + kind: + type: string + readOnly: + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + properties: + annotations: + additionalProperties: + type: string + type: object + generateName: + type: string + labels: + additionalProperties: + type: string + type: object + name: + type: string + namespace: + type: string + ownerReferences: + items: + properties: + apiVersion: + type: string + blockOwnerDeletion: + type: boolean + controller: + type: boolean + kind: + type: string + name: + type: string + uid: + type: string + required: + - apiVersion + - kind + - name + - uid + type: object + x-kubernetes-map-type: atomic + type: array + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + type: object + type: object + ttlSecondsAfterFinished: + format: int32 + type: integer + type: object + schedule: + type: string + successfulJobsHistoryLimit: + format: int32 + type: integer + required: + - schedule + type: object + sessionHistoryLimit: + format: int32 + type: integer + task: + properties: + params: + type: object + x-kubernetes-preserve-unknown-fields: true + required: + - params + type: object + timeout: + type: string + required: + - driver + type: object + manifestBackup: + properties: + containerRuntimeSettings: + properties: + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + ionice: + properties: + class: + format: int32 + type: integer + classData: + format: int32 + type: integer + type: object + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + nice: + properties: + adjustment: + format: int32 + type: integer + type: object + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + type: object + jobTemplate: + properties: + controller: + properties: + annotations: + additionalProperties: + type: string + type: object + labels: + additionalProperties: + type: string + type: object + type: object + metadata: + properties: + annotations: + additionalProperties: + type: string + type: object + labels: + additionalProperties: + type: string + type: object + type: object + spec: + properties: + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + args: + items: + type: string + type: array + containerSecurityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + podPlacementPolicy: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + runtimeClassName: + type: string + schedulerName: + type: string + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccountName: + type: string + shareProcessNamespace: + type: boolean + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + type: string + kind: + type: string + readOnly: + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + properties: + annotations: + additionalProperties: + type: string + type: object + generateName: + type: string + labels: + additionalProperties: + type: string + type: object + name: + type: string + namespace: + type: string + ownerReferences: + items: + properties: + apiVersion: + type: string + blockOwnerDeletion: + type: boolean + controller: + type: boolean + kind: + type: string + name: + type: string + uid: + type: string + required: + - apiVersion + - kind + - name + - uid + type: object + x-kubernetes-map-type: atomic + type: array + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + type: object + type: object + retryConfig: + properties: + delay: + type: string + maxRetry: + default: 1 + format: int32 + minimum: 1 + type: integer + type: object + scheduler: + properties: + concurrencyPolicy: + type: string + failedJobsHistoryLimit: + format: int32 + type: integer + jobTemplate: + properties: + activeDeadlineSeconds: + format: int64 + type: integer + backoffLimit: + format: int32 + type: integer + completionMode: + type: string + completions: + format: int32 + type: integer + parallelism: + format: int32 + type: integer + suspend: + type: boolean + template: + properties: + controller: + properties: + annotations: + additionalProperties: + type: string + type: object + labels: + additionalProperties: + type: string + type: object + type: object + metadata: + properties: + annotations: + additionalProperties: + type: string + type: object + labels: + additionalProperties: + type: string + type: object + type: object + spec: + properties: + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + args: + items: + type: string + type: array + containerSecurityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + podPlacementPolicy: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + runtimeClassName: + type: string + schedulerName: + type: string + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccountName: + type: string + shareProcessNamespace: + type: boolean + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + type: string + kind: + type: string + readOnly: + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + properties: + annotations: + additionalProperties: + type: string + type: object + generateName: + type: string + labels: + additionalProperties: + type: string + type: object + name: + type: string + namespace: + type: string + ownerReferences: + items: + properties: + apiVersion: + type: string + blockOwnerDeletion: + type: boolean + controller: + type: boolean + kind: + type: string + name: + type: string + uid: + type: string + required: + - apiVersion + - kind + - name + - uid + type: object + x-kubernetes-map-type: atomic + type: array + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + type: object + type: object + ttlSecondsAfterFinished: + format: int32 + type: integer + type: object + schedule: + type: string + successfulJobsHistoryLimit: + format: int32 + type: integer + required: + - schedule + type: object + sessionHistoryLimit: + format: int32 + type: integer + timeout: + type: string + type: object + pause: + type: boolean + retentionPolicy: + properties: + name: + type: string + namespace: + type: string + required: + - name + type: object + walBackup: + properties: + configSecret: + properties: + envToSecretKey: + additionalProperties: + type: string + type: object + name: + type: string + required: + - envToSecretKey + - name + type: object + runtimeSettings: + properties: + container: + properties: + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + ionice: + properties: + class: + format: int32 + type: integer + classData: + format: int32 + type: integer + type: object + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + nice: + properties: + adjustment: + format: int32 + type: integer + type: object + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + type: object + pod: + properties: + affinity: + properties: + nodeAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + preference: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + weight: + format: int32 + type: integer + required: + - preference + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + properties: + nodeSelectorTerms: + items: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchFields: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + type: object + x-kubernetes-map-type: atomic + type: array + x-kubernetes-list-type: atomic + required: + - nodeSelectorTerms + type: object + x-kubernetes-map-type: atomic + type: object + podAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + podAntiAffinity: + properties: + preferredDuringSchedulingIgnoredDuringExecution: + items: + properties: + podAffinityTerm: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + weight: + format: int32 + type: integer + required: + - podAffinityTerm + - weight + type: object + type: array + x-kubernetes-list-type: atomic + requiredDuringSchedulingIgnoredDuringExecution: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + mismatchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaceSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + namespaces: + items: + type: string + type: array + x-kubernetes-list-type: atomic + topologyKey: + type: string + required: + - topologyKey + type: object + type: array + x-kubernetes-list-type: atomic + type: object + type: object + automountServiceAccountToken: + type: boolean + enableServiceLinks: + type: boolean + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + nodeName: + type: string + nodeSelector: + additionalProperties: + type: string + type: object + podAnnotations: + additionalProperties: + type: string + type: object + podLabels: + additionalProperties: + type: string + type: object + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessGates: + items: + properties: + conditionType: + type: string + required: + - conditionType + type: object + type: array + runtimeClassName: + type: string + schedulerName: + type: string + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccountAnnotations: + additionalProperties: + type: string + type: object + serviceAccountName: + type: string + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + topologySpreadConstraints: + items: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + matchLabelKeys: + items: + type: string + type: array + x-kubernetes-list-type: atomic + maxSkew: + format: int32 + type: integer + minDomains: + format: int32 + type: integer + nodeAffinityPolicy: + type: string + nodeTaintsPolicy: + type: string + topologyKey: + type: string + whenUnsatisfiable: + type: string + required: + - maxSkew + - topologyKey + - whenUnsatisfiable + type: object + type: array + x-kubernetes-list-map-keys: + - topologyKey + - whenUnsatisfiable + x-kubernetes-list-type: map + type: object + type: object + type: object + required: + - databases + type: object + status: + properties: + databaseRefs: + items: + properties: + name: + type: string + namespace: + type: string + type: object + type: array + type: object + type: object + served: true + storage: true + subresources: + status: {} diff --git a/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_clickhouseautoscalers.yaml b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_clickhouseautoscalers.yaml new file mode 100644 index 000000000..194c5665c --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_clickhouseautoscalers.yaml @@ -0,0 +1,345 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + creationTimestamp: null + labels: + app.kubernetes.io/name: kubedb + name: clickhouseautoscalers.autoscaling.kubedb.com +spec: + group: autoscaling.kubedb.com + names: + categories: + - datastore + - kubedb + - appscode + kind: ClickHouseAutoscaler + listKind: ClickHouseAutoscalerList + plural: clickhouseautoscalers + shortNames: + - chscaler + singular: clickhouseautoscaler + scope: Namespaced + versions: + - name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + properties: + compute: + properties: + clickhouse: + properties: + containerControlledValues: + enum: + - RequestsAndLimits + - RequestsOnly + type: string + controlledResources: + items: + type: string + type: array + inMemoryStorage: + properties: + scalingFactorPercentage: + format: int32 + type: integer + usageThresholdPercentage: + format: int32 + type: integer + type: object + maxAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + minAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + podLifeTimeThreshold: + type: string + resourceDiffPercentage: + format: int32 + type: integer + trigger: + type: string + type: object + nodeTopology: + properties: + name: + type: string + scaleDownDiffPercentage: + default: 25 + format: int32 + type: integer + scaleUpDiffPercentage: + default: 15 + format: int32 + type: integer + type: object + type: object + databaseRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + opsRequestOptions: + properties: + apply: + default: IfReady + enum: + - IfReady + - Always + type: string + timeout: + type: string + type: object + storage: + properties: + clickhouse: + properties: + expansionMode: + enum: + - Offline + - Online + type: string + scalingRules: + items: + properties: + appliesUpto: + type: string + threshold: + type: string + required: + - appliesUpto + - threshold + type: object + type: array + scalingThreshold: + format: int32 + type: integer + trigger: + type: string + upperBound: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + usageThreshold: + format: int32 + type: integer + required: + - expansionMode + type: object + type: object + required: + - databaseRef + type: object + status: + properties: + checkpoints: + items: + properties: + cpuHistogram: + properties: + bucketWeights: + items: + properties: + index: + type: integer + weight: + format: int32 + type: integer + required: + - index + - weight + type: object + type: array + x-kubernetes-preserve-unknown-fields: true + referenceTimestamp: + format: date-time + nullable: true + type: string + totalWeight: + format: double + type: number + type: object + firstSampleStart: + format: date-time + nullable: true + type: string + lastSampleStart: + format: date-time + nullable: true + type: string + lastUpdateTime: + format: date-time + nullable: true + type: string + memoryHistogram: + properties: + bucketWeights: + items: + properties: + index: + type: integer + weight: + format: int32 + type: integer + required: + - index + - weight + type: object + type: array + x-kubernetes-preserve-unknown-fields: true + referenceTimestamp: + format: date-time + nullable: true + type: string + totalWeight: + format: double + type: number + type: object + ref: + properties: + containerName: + type: string + vpaObjectName: + type: string + type: object + totalSamplesCount: + type: integer + version: + type: string + type: object + type: array + conditions: + items: + properties: + lastTransitionTime: + format: date-time + type: string + message: + type: string + observedGeneration: + format: int64 + type: integer + reason: + type: string + severity: + type: string + status: + type: string + type: + type: string + required: + - lastTransitionTime + - status + - type + type: object + type: array + observedGeneration: + format: int64 + type: integer + phase: + enum: + - InProgress + - Current + - Terminating + - Failed + type: string + vpas: + items: + properties: + conditions: + items: + properties: + lastTransitionTime: + format: date-time + type: string + message: + type: string + reason: + type: string + status: + type: string + type: + type: string + required: + - status + - type + type: object + type: array + recommendation: + properties: + containerRecommendations: + items: + properties: + containerName: + type: string + lowerBound: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + target: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + uncappedTarget: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + upperBound: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + required: + - target + type: object + type: array + type: object + vpaName: + type: string + type: object + type: array + type: object + required: + - spec + type: object + served: true + storage: true + subresources: + status: {} diff --git a/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_ferretdbautoscalers.yaml b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_ferretdbautoscalers.yaml new file mode 100644 index 000000000..2a56973ba --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_ferretdbautoscalers.yaml @@ -0,0 +1,345 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + creationTimestamp: null + labels: + app.kubernetes.io/name: kubedb + name: ferretdbautoscalers.autoscaling.kubedb.com +spec: + group: autoscaling.kubedb.com + names: + categories: + - datastore + - kubedb + - appscode + kind: FerretDBAutoscaler + listKind: FerretDBAutoscalerList + plural: ferretdbautoscalers + shortNames: + - frscaler + singular: ferretdbautoscaler + scope: Namespaced + versions: + - name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + properties: + compute: + properties: + ferretdb: + properties: + containerControlledValues: + enum: + - RequestsAndLimits + - RequestsOnly + type: string + controlledResources: + items: + type: string + type: array + inMemoryStorage: + properties: + scalingFactorPercentage: + format: int32 + type: integer + usageThresholdPercentage: + format: int32 + type: integer + type: object + maxAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + minAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + podLifeTimeThreshold: + type: string + resourceDiffPercentage: + format: int32 + type: integer + trigger: + type: string + type: object + nodeTopology: + properties: + name: + type: string + scaleDownDiffPercentage: + default: 25 + format: int32 + type: integer + scaleUpDiffPercentage: + default: 15 + format: int32 + type: integer + type: object + type: object + databaseRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + opsRequestOptions: + properties: + apply: + default: IfReady + enum: + - IfReady + - Always + type: string + timeout: + type: string + type: object + storage: + properties: + ferretdb: + properties: + expansionMode: + enum: + - Offline + - Online + type: string + scalingRules: + items: + properties: + appliesUpto: + type: string + threshold: + type: string + required: + - appliesUpto + - threshold + type: object + type: array + scalingThreshold: + format: int32 + type: integer + trigger: + type: string + upperBound: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + usageThreshold: + format: int32 + type: integer + required: + - expansionMode + type: object + type: object + required: + - databaseRef + type: object + status: + properties: + checkpoints: + items: + properties: + cpuHistogram: + properties: + bucketWeights: + items: + properties: + index: + type: integer + weight: + format: int32 + type: integer + required: + - index + - weight + type: object + type: array + x-kubernetes-preserve-unknown-fields: true + referenceTimestamp: + format: date-time + nullable: true + type: string + totalWeight: + format: double + type: number + type: object + firstSampleStart: + format: date-time + nullable: true + type: string + lastSampleStart: + format: date-time + nullable: true + type: string + lastUpdateTime: + format: date-time + nullable: true + type: string + memoryHistogram: + properties: + bucketWeights: + items: + properties: + index: + type: integer + weight: + format: int32 + type: integer + required: + - index + - weight + type: object + type: array + x-kubernetes-preserve-unknown-fields: true + referenceTimestamp: + format: date-time + nullable: true + type: string + totalWeight: + format: double + type: number + type: object + ref: + properties: + containerName: + type: string + vpaObjectName: + type: string + type: object + totalSamplesCount: + type: integer + version: + type: string + type: object + type: array + conditions: + items: + properties: + lastTransitionTime: + format: date-time + type: string + message: + type: string + observedGeneration: + format: int64 + type: integer + reason: + type: string + severity: + type: string + status: + type: string + type: + type: string + required: + - lastTransitionTime + - status + - type + type: object + type: array + observedGeneration: + format: int64 + type: integer + phase: + enum: + - InProgress + - Current + - Terminating + - Failed + type: string + vpas: + items: + properties: + conditions: + items: + properties: + lastTransitionTime: + format: date-time + type: string + message: + type: string + reason: + type: string + status: + type: string + type: + type: string + required: + - status + - type + type: object + type: array + recommendation: + properties: + containerRecommendations: + items: + properties: + containerName: + type: string + lowerBound: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + target: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + uncappedTarget: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + upperBound: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + required: + - target + type: object + type: array + type: object + vpaName: + type: string + type: object + type: array + type: object + required: + - spec + type: object + served: true + storage: true + subresources: + status: {} diff --git a/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_memcachedautoscalers.yaml b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_memcachedautoscalers.yaml index 3023b18d3..4d8ffedd1 100644 --- a/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_memcachedautoscalers.yaml +++ b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_memcachedautoscalers.yaml @@ -32,343 +32,127 @@ spec: type: object spec: properties: - behavior: + compute: properties: - scaleDown: + memcached: properties: - policies: + containerControlledValues: + enum: + - RequestsAndLimits + - RequestsOnly + type: string + controlledResources: items: - properties: - periodSeconds: - format: int32 - type: integer - type: - type: string - value: - format: int32 - type: integer - required: - - periodSeconds - - type - - value - type: object + type: string type: array - selectPolicy: + inMemoryStorage: + properties: + scalingFactorPercentage: + format: int32 + type: integer + usageThresholdPercentage: + format: int32 + type: integer + type: object + maxAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + minAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + podLifeTimeThreshold: type: string - stabilizationWindowSeconds: + resourceDiffPercentage: format: int32 type: integer + trigger: + type: string type: object - scaleUp: + nodeTopology: properties: - policies: - items: - properties: - periodSeconds: - format: int32 - type: integer - type: - type: string - value: - format: int32 - type: integer - required: - - periodSeconds - - type - - value - type: object - type: array - selectPolicy: + name: type: string - stabilizationWindowSeconds: + scaleDownDiffPercentage: + default: 25 + format: int32 + type: integer + scaleUpDiffPercentage: + default: 15 format: int32 type: integer type: object type: object - maxReplicas: - format: int32 - type: integer - metrics: - items: - properties: - containerResource: - properties: - container: - type: string - name: - type: string - target: - properties: - averageUtilization: - format: int32 - type: integer - averageValue: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - type: - type: string - value: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - required: - - type - type: object - required: - - container - - name - - target - type: object - external: - properties: - metric: - properties: - name: - type: string - selector: - properties: - matchExpressions: - items: - properties: - key: - type: string - operator: - type: string - values: - items: - type: string - type: array - x-kubernetes-list-type: atomic - required: - - key - - operator - type: object - type: array - x-kubernetes-list-type: atomic - matchLabels: - additionalProperties: - type: string - type: object - type: object - x-kubernetes-map-type: atomic - required: - - name - type: object - target: - properties: - averageUtilization: - format: int32 - type: integer - averageValue: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - type: - type: string - value: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - required: - - type - type: object - required: - - metric - - target - type: object - object: - properties: - describedObject: - properties: - apiVersion: - type: string - kind: - type: string - name: - type: string - required: - - kind - - name - type: object - metric: - properties: - name: - type: string - selector: - properties: - matchExpressions: - items: - properties: - key: - type: string - operator: - type: string - values: - items: - type: string - type: array - x-kubernetes-list-type: atomic - required: - - key - - operator - type: object - type: array - x-kubernetes-list-type: atomic - matchLabels: - additionalProperties: - type: string - type: object - type: object - x-kubernetes-map-type: atomic - required: - - name - type: object - target: - properties: - averageUtilization: - format: int32 - type: integer - averageValue: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - type: - type: string - value: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - required: - - type - type: object - required: - - describedObject - - metric - - target - type: object - pods: - properties: - metric: - properties: - name: - type: string - selector: - properties: - matchExpressions: - items: - properties: - key: - type: string - operator: - type: string - values: - items: - type: string - type: array - x-kubernetes-list-type: atomic - required: - - key - - operator - type: object - type: array - x-kubernetes-list-type: atomic - matchLabels: - additionalProperties: - type: string - type: object - type: object - x-kubernetes-map-type: atomic - required: - - name - type: object - target: - properties: - averageUtilization: - format: int32 - type: integer - averageValue: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - type: - type: string - value: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - required: - - type - type: object - required: - - metric - - target - type: object - resource: - properties: - name: - type: string - target: - properties: - averageUtilization: - format: int32 - type: integer - averageValue: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - type: - type: string - value: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - required: - - type - type: object - required: - - name - - target - type: object - type: - type: string - required: - - type - type: object - type: array - minReplicas: - format: int32 - type: integer - scaleTargetRef: + databaseRef: properties: name: default: "" type: string type: object x-kubernetes-map-type: atomic + opsRequestOptions: + properties: + apply: + default: IfReady + enum: + - IfReady + - Always + type: string + readinessCriteria: + type: object + timeout: + type: string + type: object + storage: + properties: + memcached: + properties: + expansionMode: + enum: + - Offline + - Online + type: string + scalingRules: + items: + properties: + appliesUpto: + type: string + threshold: + type: string + required: + - appliesUpto + - threshold + type: object + type: array + scalingThreshold: + format: int32 + type: integer + trigger: + type: string + upperBound: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + usageThreshold: + format: int32 + type: integer + required: + - expansionMode + type: object + type: object required: - - maxReplicas - - scaleTargetRef + - databaseRef type: object status: properties: @@ -554,6 +338,8 @@ spec: type: object type: array type: object + required: + - spec type: object served: true storage: true diff --git a/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_mssqlserverautoscalers.yaml b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_mssqlserverautoscalers.yaml new file mode 100644 index 000000000..32dbce09a --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_mssqlserverautoscalers.yaml @@ -0,0 +1,345 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + creationTimestamp: null + labels: + app.kubernetes.io/name: kubedb + name: mssqlserverautoscalers.autoscaling.kubedb.com +spec: + group: autoscaling.kubedb.com + names: + categories: + - datastore + - kubedb + - appscode + kind: MSSQLServerAutoscaler + listKind: MSSQLServerAutoscalerList + plural: mssqlserverautoscalers + shortNames: + - msscaler + singular: mssqlserverautoscaler + scope: Namespaced + versions: + - name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + properties: + compute: + properties: + mssqlserver: + properties: + containerControlledValues: + enum: + - RequestsAndLimits + - RequestsOnly + type: string + controlledResources: + items: + type: string + type: array + inMemoryStorage: + properties: + scalingFactorPercentage: + format: int32 + type: integer + usageThresholdPercentage: + format: int32 + type: integer + type: object + maxAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + minAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + podLifeTimeThreshold: + type: string + resourceDiffPercentage: + format: int32 + type: integer + trigger: + type: string + type: object + nodeTopology: + properties: + name: + type: string + scaleDownDiffPercentage: + default: 25 + format: int32 + type: integer + scaleUpDiffPercentage: + default: 15 + format: int32 + type: integer + type: object + type: object + databaseRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + opsRequestOptions: + properties: + apply: + default: IfReady + enum: + - IfReady + - Always + type: string + timeout: + type: string + type: object + storage: + properties: + mssqlserver: + properties: + expansionMode: + enum: + - Offline + - Online + type: string + scalingRules: + items: + properties: + appliesUpto: + type: string + threshold: + type: string + required: + - appliesUpto + - threshold + type: object + type: array + scalingThreshold: + format: int32 + type: integer + trigger: + type: string + upperBound: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + usageThreshold: + format: int32 + type: integer + required: + - expansionMode + type: object + type: object + required: + - databaseRef + type: object + status: + properties: + checkpoints: + items: + properties: + cpuHistogram: + properties: + bucketWeights: + items: + properties: + index: + type: integer + weight: + format: int32 + type: integer + required: + - index + - weight + type: object + type: array + x-kubernetes-preserve-unknown-fields: true + referenceTimestamp: + format: date-time + nullable: true + type: string + totalWeight: + format: double + type: number + type: object + firstSampleStart: + format: date-time + nullable: true + type: string + lastSampleStart: + format: date-time + nullable: true + type: string + lastUpdateTime: + format: date-time + nullable: true + type: string + memoryHistogram: + properties: + bucketWeights: + items: + properties: + index: + type: integer + weight: + format: int32 + type: integer + required: + - index + - weight + type: object + type: array + x-kubernetes-preserve-unknown-fields: true + referenceTimestamp: + format: date-time + nullable: true + type: string + totalWeight: + format: double + type: number + type: object + ref: + properties: + containerName: + type: string + vpaObjectName: + type: string + type: object + totalSamplesCount: + type: integer + version: + type: string + type: object + type: array + conditions: + items: + properties: + lastTransitionTime: + format: date-time + type: string + message: + type: string + observedGeneration: + format: int64 + type: integer + reason: + type: string + severity: + type: string + status: + type: string + type: + type: string + required: + - lastTransitionTime + - status + - type + type: object + type: array + observedGeneration: + format: int64 + type: integer + phase: + enum: + - InProgress + - Current + - Terminating + - Failed + type: string + vpas: + items: + properties: + conditions: + items: + properties: + lastTransitionTime: + format: date-time + type: string + message: + type: string + reason: + type: string + status: + type: string + type: + type: string + required: + - status + - type + type: object + type: array + recommendation: + properties: + containerRecommendations: + items: + properties: + containerName: + type: string + lowerBound: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + target: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + uncappedTarget: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + upperBound: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + required: + - target + type: object + type: array + type: object + vpaName: + type: string + type: object + type: array + type: object + required: + - spec + type: object + served: true + storage: true + subresources: + status: {} diff --git a/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_pgbouncerautoscalers.yaml b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_pgbouncerautoscalers.yaml index 70b1487c8..b717ba8d5 100644 --- a/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_pgbouncerautoscalers.yaml +++ b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_pgbouncerautoscalers.yaml @@ -32,343 +32,86 @@ spec: type: object spec: properties: - behavior: + compute: properties: - scaleDown: + nodeTopology: properties: - policies: - items: - properties: - periodSeconds: - format: int32 - type: integer - type: - type: string - value: - format: int32 - type: integer - required: - - periodSeconds - - type - - value - type: object - type: array - selectPolicy: + name: type: string - stabilizationWindowSeconds: + scaleDownDiffPercentage: + default: 25 + format: int32 + type: integer + scaleUpDiffPercentage: + default: 15 format: int32 type: integer type: object - scaleUp: + pgbouncer: properties: - policies: + containerControlledValues: + enum: + - RequestsAndLimits + - RequestsOnly + type: string + controlledResources: items: - properties: - periodSeconds: - format: int32 - type: integer - type: - type: string - value: - format: int32 - type: integer - required: - - periodSeconds - - type - - value - type: object + type: string type: array - selectPolicy: + inMemoryStorage: + properties: + scalingFactorPercentage: + format: int32 + type: integer + usageThresholdPercentage: + format: int32 + type: integer + type: object + maxAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + minAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + podLifeTimeThreshold: type: string - stabilizationWindowSeconds: + resourceDiffPercentage: format: int32 type: integer + trigger: + type: string type: object type: object - maxReplicas: - format: int32 - type: integer - metrics: - items: - properties: - containerResource: - properties: - container: - type: string - name: - type: string - target: - properties: - averageUtilization: - format: int32 - type: integer - averageValue: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - type: - type: string - value: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - required: - - type - type: object - required: - - container - - name - - target - type: object - external: - properties: - metric: - properties: - name: - type: string - selector: - properties: - matchExpressions: - items: - properties: - key: - type: string - operator: - type: string - values: - items: - type: string - type: array - x-kubernetes-list-type: atomic - required: - - key - - operator - type: object - type: array - x-kubernetes-list-type: atomic - matchLabels: - additionalProperties: - type: string - type: object - type: object - x-kubernetes-map-type: atomic - required: - - name - type: object - target: - properties: - averageUtilization: - format: int32 - type: integer - averageValue: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - type: - type: string - value: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - required: - - type - type: object - required: - - metric - - target - type: object - object: - properties: - describedObject: - properties: - apiVersion: - type: string - kind: - type: string - name: - type: string - required: - - kind - - name - type: object - metric: - properties: - name: - type: string - selector: - properties: - matchExpressions: - items: - properties: - key: - type: string - operator: - type: string - values: - items: - type: string - type: array - x-kubernetes-list-type: atomic - required: - - key - - operator - type: object - type: array - x-kubernetes-list-type: atomic - matchLabels: - additionalProperties: - type: string - type: object - type: object - x-kubernetes-map-type: atomic - required: - - name - type: object - target: - properties: - averageUtilization: - format: int32 - type: integer - averageValue: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - type: - type: string - value: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - required: - - type - type: object - required: - - describedObject - - metric - - target - type: object - pods: - properties: - metric: - properties: - name: - type: string - selector: - properties: - matchExpressions: - items: - properties: - key: - type: string - operator: - type: string - values: - items: - type: string - type: array - x-kubernetes-list-type: atomic - required: - - key - - operator - type: object - type: array - x-kubernetes-list-type: atomic - matchLabels: - additionalProperties: - type: string - type: object - type: object - x-kubernetes-map-type: atomic - required: - - name - type: object - target: - properties: - averageUtilization: - format: int32 - type: integer - averageValue: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - type: - type: string - value: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - required: - - type - type: object - required: - - metric - - target - type: object - resource: - properties: - name: - type: string - target: - properties: - averageUtilization: - format: int32 - type: integer - averageValue: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - type: - type: string - value: - anyOf: - - type: integer - - type: string - pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ - x-kubernetes-int-or-string: true - required: - - type - type: object - required: - - name - - target - type: object - type: - type: string - required: - - type - type: object - type: array - minReplicas: - format: int32 - type: integer - serverRef: + databaseRef: properties: name: default: "" type: string type: object x-kubernetes-map-type: atomic + opsRequestOptions: + properties: + apply: + default: IfReady + enum: + - IfReady + - Always + type: string + timeout: + type: string + type: object required: - - maxReplicas - - serverRef + - databaseRef type: object status: properties: @@ -554,6 +297,8 @@ spec: type: object type: array type: object + required: + - spec type: object served: true storage: true diff --git a/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_solrautoscalers.yaml b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_solrautoscalers.yaml new file mode 100644 index 000000000..e23f3c80c --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_solrautoscalers.yaml @@ -0,0 +1,345 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + creationTimestamp: null + labels: + app.kubernetes.io/name: kubedb + name: solrautoscalers.autoscaling.kubedb.com +spec: + group: autoscaling.kubedb.com + names: + categories: + - datastore + - kubedb + - appscode + kind: SolrAutoscaler + listKind: SolrAutoscalerList + plural: solrautoscalers + shortNames: + - slscaler + singular: solrautoscaler + scope: Namespaced + versions: + - name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + properties: + compute: + properties: + nodeTopology: + properties: + name: + type: string + scaleDownDiffPercentage: + default: 25 + format: int32 + type: integer + scaleUpDiffPercentage: + default: 15 + format: int32 + type: integer + type: object + solr: + properties: + containerControlledValues: + enum: + - RequestsAndLimits + - RequestsOnly + type: string + controlledResources: + items: + type: string + type: array + inMemoryStorage: + properties: + scalingFactorPercentage: + format: int32 + type: integer + usageThresholdPercentage: + format: int32 + type: integer + type: object + maxAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + minAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + podLifeTimeThreshold: + type: string + resourceDiffPercentage: + format: int32 + type: integer + trigger: + type: string + type: object + type: object + databaseRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + opsRequestOptions: + properties: + apply: + default: IfReady + enum: + - IfReady + - Always + type: string + timeout: + type: string + type: object + storage: + properties: + solr: + properties: + expansionMode: + enum: + - Offline + - Online + type: string + scalingRules: + items: + properties: + appliesUpto: + type: string + threshold: + type: string + required: + - appliesUpto + - threshold + type: object + type: array + scalingThreshold: + format: int32 + type: integer + trigger: + type: string + upperBound: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + usageThreshold: + format: int32 + type: integer + required: + - expansionMode + type: object + type: object + required: + - databaseRef + type: object + status: + properties: + checkpoints: + items: + properties: + cpuHistogram: + properties: + bucketWeights: + items: + properties: + index: + type: integer + weight: + format: int32 + type: integer + required: + - index + - weight + type: object + type: array + x-kubernetes-preserve-unknown-fields: true + referenceTimestamp: + format: date-time + nullable: true + type: string + totalWeight: + format: double + type: number + type: object + firstSampleStart: + format: date-time + nullable: true + type: string + lastSampleStart: + format: date-time + nullable: true + type: string + lastUpdateTime: + format: date-time + nullable: true + type: string + memoryHistogram: + properties: + bucketWeights: + items: + properties: + index: + type: integer + weight: + format: int32 + type: integer + required: + - index + - weight + type: object + type: array + x-kubernetes-preserve-unknown-fields: true + referenceTimestamp: + format: date-time + nullable: true + type: string + totalWeight: + format: double + type: number + type: object + ref: + properties: + containerName: + type: string + vpaObjectName: + type: string + type: object + totalSamplesCount: + type: integer + version: + type: string + type: object + type: array + conditions: + items: + properties: + lastTransitionTime: + format: date-time + type: string + message: + type: string + observedGeneration: + format: int64 + type: integer + reason: + type: string + severity: + type: string + status: + type: string + type: + type: string + required: + - lastTransitionTime + - status + - type + type: object + type: array + observedGeneration: + format: int64 + type: integer + phase: + enum: + - InProgress + - Current + - Terminating + - Failed + type: string + vpas: + items: + properties: + conditions: + items: + properties: + lastTransitionTime: + format: date-time + type: string + message: + type: string + reason: + type: string + status: + type: string + type: + type: string + required: + - status + - type + type: object + type: array + recommendation: + properties: + containerRecommendations: + items: + properties: + containerName: + type: string + lowerBound: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + target: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + uncappedTarget: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + upperBound: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + required: + - target + type: object + type: array + type: object + vpaName: + type: string + type: object + type: array + type: object + required: + - spec + type: object + served: true + storage: true + subresources: + status: {} diff --git a/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_zookeeperautoscalers.yaml b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_zookeeperautoscalers.yaml new file mode 100644 index 000000000..278334b4b --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/crds/autoscaling.kubedb.com_zookeeperautoscalers.yaml @@ -0,0 +1,345 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + creationTimestamp: null + labels: + app.kubernetes.io/name: kubedb + name: zookeeperautoscalers.autoscaling.kubedb.com +spec: + group: autoscaling.kubedb.com + names: + categories: + - datastore + - kubedb + - appscode + kind: ZooKeeperAutoscaler + listKind: ZooKeeperAutoscalerList + plural: zookeeperautoscalers + shortNames: + - zkscaler + singular: zookeeperautoscaler + scope: Namespaced + versions: + - name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + properties: + compute: + properties: + nodeTopology: + properties: + name: + type: string + scaleDownDiffPercentage: + default: 25 + format: int32 + type: integer + scaleUpDiffPercentage: + default: 15 + format: int32 + type: integer + type: object + zookeeper: + properties: + containerControlledValues: + enum: + - RequestsAndLimits + - RequestsOnly + type: string + controlledResources: + items: + type: string + type: array + inMemoryStorage: + properties: + scalingFactorPercentage: + format: int32 + type: integer + usageThresholdPercentage: + format: int32 + type: integer + type: object + maxAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + minAllowed: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + podLifeTimeThreshold: + type: string + resourceDiffPercentage: + format: int32 + type: integer + trigger: + type: string + type: object + type: object + databaseRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + opsRequestOptions: + properties: + apply: + default: IfReady + enum: + - IfReady + - Always + type: string + timeout: + type: string + type: object + storage: + properties: + zookeeper: + properties: + expansionMode: + enum: + - Offline + - Online + type: string + scalingRules: + items: + properties: + appliesUpto: + type: string + threshold: + type: string + required: + - appliesUpto + - threshold + type: object + type: array + scalingThreshold: + format: int32 + type: integer + trigger: + type: string + upperBound: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + usageThreshold: + format: int32 + type: integer + required: + - expansionMode + type: object + type: object + required: + - databaseRef + type: object + status: + properties: + checkpoints: + items: + properties: + cpuHistogram: + properties: + bucketWeights: + items: + properties: + index: + type: integer + weight: + format: int32 + type: integer + required: + - index + - weight + type: object + type: array + x-kubernetes-preserve-unknown-fields: true + referenceTimestamp: + format: date-time + nullable: true + type: string + totalWeight: + format: double + type: number + type: object + firstSampleStart: + format: date-time + nullable: true + type: string + lastSampleStart: + format: date-time + nullable: true + type: string + lastUpdateTime: + format: date-time + nullable: true + type: string + memoryHistogram: + properties: + bucketWeights: + items: + properties: + index: + type: integer + weight: + format: int32 + type: integer + required: + - index + - weight + type: object + type: array + x-kubernetes-preserve-unknown-fields: true + referenceTimestamp: + format: date-time + nullable: true + type: string + totalWeight: + format: double + type: number + type: object + ref: + properties: + containerName: + type: string + vpaObjectName: + type: string + type: object + totalSamplesCount: + type: integer + version: + type: string + type: object + type: array + conditions: + items: + properties: + lastTransitionTime: + format: date-time + type: string + message: + type: string + observedGeneration: + format: int64 + type: integer + reason: + type: string + severity: + type: string + status: + type: string + type: + type: string + required: + - lastTransitionTime + - status + - type + type: object + type: array + observedGeneration: + format: int64 + type: integer + phase: + enum: + - InProgress + - Current + - Terminating + - Failed + type: string + vpas: + items: + properties: + conditions: + items: + properties: + lastTransitionTime: + format: date-time + type: string + message: + type: string + reason: + type: string + status: + type: string + type: + type: string + required: + - status + - type + type: object + type: array + recommendation: + properties: + containerRecommendations: + items: + properties: + containerName: + type: string + lowerBound: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + target: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + uncappedTarget: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + upperBound: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + required: + - target + type: object + type: array + type: object + vpaName: + type: string + type: object + type: array + type: object + required: + - spec + type: object + served: true + storage: true + subresources: + status: {} diff --git a/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mariadbversions.yaml b/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mariadbversions.yaml index 31d11b731..61d21dc5b 100644 --- a/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mariadbversions.yaml +++ b/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mariadbversions.yaml @@ -55,9 +55,24 @@ spec: - postgres-addon - mysql-addon - mariadb-addon + - mssqlserver-addon type: string tasks: properties: + fullBackup: + properties: + name: + type: string + required: + - name + type: object + fullBackupRestore: + properties: + name: + type: string + required: + - name + type: object manifestBackup: properties: name: diff --git a/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mongodbversions.yaml b/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mongodbversions.yaml index 5c3678575..b36a2bb80 100644 --- a/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mongodbversions.yaml +++ b/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mongodbversions.yaml @@ -58,9 +58,24 @@ spec: - postgres-addon - mysql-addon - mariadb-addon + - mssqlserver-addon type: string tasks: properties: + fullBackup: + properties: + name: + type: string + required: + - name + type: object + fullBackupRestore: + properties: + name: + type: string + required: + - name + type: object manifestBackup: properties: name: diff --git a/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mssqlserverversions.yaml b/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mssqlserverversions.yaml index af8a50990..2bd7ea243 100644 --- a/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mssqlserverversions.yaml +++ b/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mssqlserverversions.yaml @@ -45,6 +45,65 @@ spec: type: object spec: properties: + archiver: + properties: + addon: + properties: + name: + enum: + - mongodb-addon + - postgres-addon + - mysql-addon + - mariadb-addon + - mssqlserver-addon + type: string + tasks: + properties: + fullBackup: + properties: + name: + type: string + required: + - name + type: object + fullBackupRestore: + properties: + name: + type: string + required: + - name + type: object + manifestBackup: + properties: + name: + type: string + required: + - name + type: object + manifestRestore: + properties: + name: + type: string + required: + - name + type: object + volumeSnapshot: + properties: + name: + type: string + required: + - name + type: object + type: object + type: object + walg: + properties: + image: + type: string + required: + - image + type: object + type: object coordinator: properties: image: @@ -61,6 +120,13 @@ spec: type: object deprecated: type: boolean + exporter: + properties: + image: + type: string + required: + - image + type: object initContainer: properties: image: @@ -151,6 +217,7 @@ spec: type: string required: - db + - exporter - initContainer - version type: object diff --git a/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mysqlversions.yaml b/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mysqlversions.yaml index 0cb454bb3..281bff963 100644 --- a/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mysqlversions.yaml +++ b/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_mysqlversions.yaml @@ -58,9 +58,24 @@ spec: - postgres-addon - mysql-addon - mariadb-addon + - mssqlserver-addon type: string tasks: properties: + fullBackup: + properties: + name: + type: string + required: + - name + type: object + fullBackupRestore: + properties: + name: + type: string + required: + - name + type: object manifestBackup: properties: name: diff --git a/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_postgresversions.yaml b/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_postgresversions.yaml index 13e7cc44d..e391a69e7 100644 --- a/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_postgresversions.yaml +++ b/vendor/kubedb.dev/apimachinery/crds/catalog.kubedb.com_postgresversions.yaml @@ -58,9 +58,24 @@ spec: - postgres-addon - mysql-addon - mariadb-addon + - mssqlserver-addon type: string tasks: properties: + fullBackup: + properties: + name: + type: string + required: + - name + type: object + fullBackupRestore: + properties: + name: + type: string + required: + - name + type: object manifestBackup: properties: name: diff --git a/vendor/kubedb.dev/apimachinery/crds/kafka.kubedb.com_restproxies.yaml b/vendor/kubedb.dev/apimachinery/crds/kafka.kubedb.com_restproxies.yaml new file mode 100644 index 000000000..957e1274c --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/crds/kafka.kubedb.com_restproxies.yaml @@ -0,0 +1,3270 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + creationTimestamp: null + labels: + app.kubernetes.io/name: kubedb + name: restproxies.kafka.kubedb.com +spec: + group: kafka.kubedb.com + names: + kind: RestProxy + listKind: RestProxyList + plural: restproxies + shortNames: + - krp + singular: restproxy + scope: Namespaced + versions: + - additionalPrinterColumns: + - jsonPath: .apiVersion + name: Type + type: string + - jsonPath: .spec.version + name: Version + type: string + - jsonPath: .spec.kafkaRef.name + name: Kafka + type: string + - jsonPath: .status.phase + name: Status + type: string + - jsonPath: .metadata.creationTimestamp + name: Age + type: date + name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + properties: + deletionPolicy: + enum: + - Halt + - Delete + - WipeOut + - DoNotTerminate + type: string + healthChecker: + default: + failureThreshold: 3 + periodSeconds: 10 + timeoutSeconds: 10 + properties: + disableWriteCheck: + type: boolean + failureThreshold: + default: 1 + format: int32 + type: integer + periodSeconds: + default: 10 + format: int32 + type: integer + timeoutSeconds: + default: 10 + format: int32 + type: integer + type: object + kafkaRef: + properties: + name: + type: string + namespace: + type: string + required: + - name + type: object + podTemplate: + properties: + controller: + properties: + annotations: + additionalProperties: + type: string + type: object + labels: + additionalProperties: + type: string + type: object + type: object + metadata: + properties: + annotations: + additionalProperties: + type: string + type: object + labels: + additionalProperties: + type: string + type: object + type: object + spec: + properties: + activeDeadlineSeconds: + format: int64 + type: integer + automountServiceAccountToken: + type: boolean + containers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + dnsConfig: + properties: + nameservers: + items: + type: string + type: array + x-kubernetes-list-type: atomic + options: + items: + properties: + name: + type: string + value: + type: string + type: object + type: array + x-kubernetes-list-type: atomic + searches: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + dnsPolicy: + type: string + enableServiceLinks: + type: boolean + ephemeralContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + targetContainerName: + type: string + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + hostAliases: + items: + properties: + hostnames: + items: + type: string + type: array + x-kubernetes-list-type: atomic + ip: + type: string + required: + - ip + type: object + type: array + hostIPC: + type: boolean + hostNetwork: + type: boolean + hostPID: + type: boolean + hostUsers: + type: boolean + imagePullSecrets: + items: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + type: array + initContainers: + items: + properties: + args: + items: + type: string + type: array + x-kubernetes-list-type: atomic + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + envFrom: + items: + properties: + configMapRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + prefix: + type: string + secretRef: + properties: + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + type: object + type: array + x-kubernetes-list-type: atomic + image: + type: string + imagePullPolicy: + type: string + lifecycle: + properties: + postStart: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + preStop: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + sleep: + properties: + seconds: + format: int64 + type: integer + required: + - seconds + type: object + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + type: object + type: object + livenessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + name: + type: string + ports: + items: + properties: + containerPort: + format: int32 + type: integer + hostIP: + type: string + hostPort: + format: int32 + type: integer + name: + type: string + protocol: + default: TCP + type: string + required: + - containerPort + type: object + type: array + x-kubernetes-list-map-keys: + - containerPort + - protocol + x-kubernetes-list-type: map + readinessProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + resizePolicy: + items: + properties: + resourceName: + type: string + restartPolicy: + type: string + required: + - resourceName + - restartPolicy + type: object + type: array + x-kubernetes-list-type: atomic + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + restartPolicy: + type: string + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + startupProbe: + properties: + exec: + properties: + command: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + failureThreshold: + format: int32 + type: integer + grpc: + properties: + port: + format: int32 + type: integer + service: + type: string + required: + - port + type: object + httpGet: + properties: + host: + type: string + httpHeaders: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + path: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + scheme: + type: string + required: + - port + type: object + initialDelaySeconds: + format: int32 + type: integer + periodSeconds: + format: int32 + type: integer + successThreshold: + format: int32 + type: integer + tcpSocket: + properties: + host: + type: string + port: + anyOf: + - type: integer + - type: string + x-kubernetes-int-or-string: true + required: + - port + type: object + terminationGracePeriodSeconds: + format: int64 + type: integer + timeoutSeconds: + format: int32 + type: integer + type: object + stdin: + type: boolean + stdinOnce: + type: boolean + terminationMessagePath: + type: string + terminationMessagePolicy: + type: string + tty: + type: boolean + volumeDevices: + items: + properties: + devicePath: + type: string + name: + type: string + required: + - devicePath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - devicePath + x-kubernetes-list-type: map + volumeMounts: + items: + properties: + mountPath: + type: string + mountPropagation: + type: string + name: + type: string + readOnly: + type: boolean + recursiveReadOnly: + type: string + subPath: + type: string + subPathExpr: + type: string + required: + - mountPath + - name + type: object + type: array + x-kubernetes-list-map-keys: + - mountPath + x-kubernetes-list-type: map + workingDir: + type: string + required: + - name + type: object + type: array + nodeName: + type: string + nodeSelector: + additionalProperties: + type: string + type: object + x-kubernetes-map-type: atomic + os: + properties: + name: + type: string + required: + - name + type: object + overhead: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + podPlacementPolicy: + default: + name: default + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + preemptionPolicy: + type: string + priority: + format: int32 + type: integer + priorityClassName: + type: string + readinessGates: + items: + properties: + conditionType: + type: string + required: + - conditionType + type: object + type: array + restartPolicy: + type: string + runtimeClassName: + type: string + schedulerName: + type: string + securityContext: + properties: + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + fsGroup: + format: int64 + type: integer + fsGroupChangePolicy: + type: string + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + supplementalGroups: + items: + format: int64 + type: integer + type: array + x-kubernetes-list-type: atomic + sysctls: + items: + properties: + name: + type: string + value: + type: string + required: + - name + - value + type: object + type: array + x-kubernetes-list-type: atomic + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + serviceAccountName: + type: string + setHostnameAsFQDN: + type: boolean + shareProcessNamespace: + type: boolean + terminationGracePeriodSeconds: + format: int64 + type: integer + tolerations: + items: + properties: + effect: + type: string + key: + type: string + operator: + type: string + tolerationSeconds: + format: int64 + type: integer + value: + type: string + type: object + type: array + volumes: + items: + properties: + awsElasticBlockStore: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + azureDisk: + properties: + cachingMode: + type: string + diskName: + type: string + diskURI: + type: string + fsType: + type: string + kind: + type: string + readOnly: + type: boolean + required: + - diskName + - diskURI + type: object + azureFile: + properties: + readOnly: + type: boolean + secretName: + type: string + shareName: + type: string + required: + - secretName + - shareName + type: object + cephfs: + properties: + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + path: + type: string + readOnly: + type: boolean + secretFile: + type: string + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - monitors + type: object + cinder: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeID: + type: string + required: + - volumeID + type: object + configMap: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + csi: + properties: + driver: + type: string + fsType: + type: string + nodePublishSecretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + readOnly: + type: boolean + volumeAttributes: + additionalProperties: + type: string + type: object + required: + - driver + type: object + downwardAPI: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + emptyDir: + properties: + medium: + type: string + sizeLimit: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + ephemeral: + properties: + volumeClaimTemplate: + properties: + metadata: + properties: + annotations: + additionalProperties: + type: string + type: object + generateName: + type: string + labels: + additionalProperties: + type: string + type: object + name: + type: string + namespace: + type: string + ownerReferences: + items: + properties: + apiVersion: + type: string + blockOwnerDeletion: + type: boolean + controller: + type: boolean + kind: + type: string + name: + type: string + uid: + type: string + required: + - apiVersion + - kind + - name + - uid + type: object + x-kubernetes-map-type: atomic + type: array + type: object + spec: + properties: + accessModes: + items: + type: string + type: array + x-kubernetes-list-type: atomic + dataSource: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + dataSourceRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - kind + - name + type: object + resources: + properties: + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + selector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + storageClassName: + type: string + volumeAttributesClassName: + type: string + volumeMode: + type: string + volumeName: + type: string + type: object + required: + - spec + type: object + type: object + fc: + properties: + fsType: + type: string + lun: + format: int32 + type: integer + readOnly: + type: boolean + targetWWNs: + items: + type: string + type: array + x-kubernetes-list-type: atomic + wwids: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + flexVolume: + properties: + driver: + type: string + fsType: + type: string + options: + additionalProperties: + type: string + type: object + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + required: + - driver + type: object + flocker: + properties: + datasetName: + type: string + datasetUUID: + type: string + type: object + gcePersistentDisk: + properties: + fsType: + type: string + partition: + format: int32 + type: integer + pdName: + type: string + readOnly: + type: boolean + required: + - pdName + type: object + glusterfs: + properties: + endpoints: + type: string + path: + type: string + readOnly: + type: boolean + required: + - endpoints + - path + type: object + hostPath: + properties: + path: + type: string + type: + type: string + required: + - path + type: object + iscsi: + properties: + chapAuthDiscovery: + type: boolean + chapAuthSession: + type: boolean + fsType: + type: string + initiatorName: + type: string + iqn: + type: string + iscsiInterface: + type: string + lun: + format: int32 + type: integer + portals: + items: + type: string + type: array + x-kubernetes-list-type: atomic + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + targetPortal: + type: string + required: + - iqn + - lun + - targetPortal + type: object + name: + type: string + nfs: + properties: + path: + type: string + readOnly: + type: boolean + server: + type: string + required: + - path + - server + type: object + persistentVolumeClaim: + properties: + claimName: + type: string + readOnly: + type: boolean + required: + - claimName + type: object + photonPersistentDisk: + properties: + fsType: + type: string + pdID: + type: string + required: + - pdID + type: object + portworxVolume: + properties: + fsType: + type: string + readOnly: + type: boolean + volumeID: + type: string + required: + - volumeID + type: object + projected: + properties: + defaultMode: + format: int32 + type: integer + sources: + items: + properties: + clusterTrustBundle: + properties: + labelSelector: + properties: + matchExpressions: + items: + properties: + key: + type: string + operator: + type: string + values: + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - key + - operator + type: object + type: array + x-kubernetes-list-type: atomic + matchLabels: + additionalProperties: + type: string + type: object + type: object + x-kubernetes-map-type: atomic + name: + type: string + optional: + type: boolean + path: + type: string + signerName: + type: string + required: + - path + type: object + configMap: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + downwardAPI: + properties: + items: + items: + properties: + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + mode: + format: int32 + type: integer + path: + type: string + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + required: + - path + type: object + type: array + x-kubernetes-list-type: atomic + type: object + secret: + properties: + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + name: + default: "" + type: string + optional: + type: boolean + type: object + x-kubernetes-map-type: atomic + serviceAccountToken: + properties: + audience: + type: string + expirationSeconds: + format: int64 + type: integer + path: + type: string + required: + - path + type: object + type: object + type: array + x-kubernetes-list-type: atomic + type: object + quobyte: + properties: + group: + type: string + readOnly: + type: boolean + registry: + type: string + tenant: + type: string + user: + type: string + volume: + type: string + required: + - registry + - volume + type: object + rbd: + properties: + fsType: + type: string + image: + type: string + keyring: + type: string + monitors: + items: + type: string + type: array + x-kubernetes-list-type: atomic + pool: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + user: + type: string + required: + - image + - monitors + type: object + scaleIO: + properties: + fsType: + type: string + gateway: + type: string + protectionDomain: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + sslEnabled: + type: boolean + storageMode: + type: string + storagePool: + type: string + system: + type: string + volumeName: + type: string + required: + - gateway + - secretRef + - system + type: object + secret: + properties: + defaultMode: + format: int32 + type: integer + items: + items: + properties: + key: + type: string + mode: + format: int32 + type: integer + path: + type: string + required: + - key + - path + type: object + type: array + x-kubernetes-list-type: atomic + optional: + type: boolean + secretName: + type: string + type: object + storageos: + properties: + fsType: + type: string + readOnly: + type: boolean + secretRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + volumeName: + type: string + volumeNamespace: + type: string + type: object + vsphereVolume: + properties: + fsType: + type: string + storagePolicyID: + type: string + storagePolicyName: + type: string + volumePath: + type: string + required: + - volumePath + type: object + required: + - name + type: object + type: array + type: object + type: object + replicas: + format: int32 + type: integer + serviceTemplates: + items: + properties: + alias: + enum: + - primary + - standby + - stats + type: string + metadata: + properties: + annotations: + additionalProperties: + type: string + type: object + labels: + additionalProperties: + type: string + type: object + type: object + spec: + properties: + clusterIP: + type: string + externalIPs: + items: + type: string + type: array + externalTrafficPolicy: + type: string + healthCheckNodePort: + format: int32 + type: integer + loadBalancerIP: + type: string + loadBalancerSourceRanges: + items: + type: string + type: array + ports: + items: + properties: + name: + type: string + nodePort: + format: int32 + type: integer + port: + format: int32 + type: integer + required: + - port + type: object + type: array + sessionAffinityConfig: + properties: + clientIP: + properties: + timeoutSeconds: + format: int32 + type: integer + type: object + type: object + type: + type: string + type: object + required: + - alias + type: object + type: array + version: + type: string + required: + - kafkaRef + - version + type: object + status: + properties: + conditions: + items: + properties: + lastTransitionTime: + format: date-time + type: string + message: + type: string + observedGeneration: + format: int64 + type: integer + reason: + type: string + severity: + type: string + status: + type: string + type: + type: string + required: + - lastTransitionTime + - status + - type + type: object + type: array + observedGeneration: + format: int64 + type: integer + phase: + enum: + - Provisioning + - Ready + - NotReady + - Critical + - Unknown + type: string + type: object + type: object + served: true + storage: true + subresources: + status: {} diff --git a/vendor/kubedb.dev/apimachinery/crds/kubedb.com_etcds.yaml b/vendor/kubedb.dev/apimachinery/crds/kubedb.com_etcds.yaml index 2f93dee89..55f5741d0 100644 --- a/vendor/kubedb.dev/apimachinery/crds/kubedb.com_etcds.yaml +++ b/vendor/kubedb.dev/apimachinery/crds/kubedb.com_etcds.yaml @@ -57,6 +57,13 @@ spec: type: string type: object x-kubernetes-map-type: atomic + deletionPolicy: + enum: + - Halt + - Delete + - WipeOut + - DoNotTerminate + type: string halted: type: boolean init: @@ -4064,13 +4071,6 @@ spec: - Durable - Ephemeral type: string - terminationPolicy: - enum: - - Halt - - Delete - - WipeOut - - DoNotTerminate - type: string tls: properties: member: diff --git a/vendor/kubedb.dev/apimachinery/crds/kubedb.com_mssqlservers.yaml b/vendor/kubedb.dev/apimachinery/crds/kubedb.com_mssqlservers.yaml index 2d5bb0fa6..50123b441 100644 --- a/vendor/kubedb.dev/apimachinery/crds/kubedb.com_mssqlservers.yaml +++ b/vendor/kubedb.dev/apimachinery/crds/kubedb.com_mssqlservers.yaml @@ -43,6 +43,22 @@ spec: type: object spec: properties: + archiver: + properties: + pause: + type: boolean + ref: + properties: + name: + type: string + namespace: + type: string + required: + - name + type: object + required: + - ref + type: object authSecret: properties: externallyManaged: @@ -1321,6 +1337,207 @@ spec: default: 60s type: string type: object + monitor: + properties: + agent: + enum: + - prometheus.io/operator + - prometheus.io + - prometheus.io/builtin + type: string + prometheus: + properties: + exporter: + properties: + args: + items: + type: string + type: array + env: + items: + properties: + name: + type: string + value: + type: string + valueFrom: + properties: + configMapKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + fieldRef: + properties: + apiVersion: + type: string + fieldPath: + type: string + required: + - fieldPath + type: object + x-kubernetes-map-type: atomic + resourceFieldRef: + properties: + containerName: + type: string + divisor: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + resource: + type: string + required: + - resource + type: object + x-kubernetes-map-type: atomic + secretKeyRef: + properties: + key: + type: string + name: + default: "" + type: string + optional: + type: boolean + required: + - key + type: object + x-kubernetes-map-type: atomic + type: object + required: + - name + type: object + type: array + port: + default: 56790 + format: int32 + type: integer + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + securityContext: + properties: + allowPrivilegeEscalation: + type: boolean + appArmorProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + capabilities: + properties: + add: + items: + type: string + type: array + x-kubernetes-list-type: atomic + drop: + items: + type: string + type: array + x-kubernetes-list-type: atomic + type: object + privileged: + type: boolean + procMount: + type: string + readOnlyRootFilesystem: + type: boolean + runAsGroup: + format: int64 + type: integer + runAsNonRoot: + type: boolean + runAsUser: + format: int64 + type: integer + seLinuxOptions: + properties: + level: + type: string + role: + type: string + type: + type: string + user: + type: string + type: object + seccompProfile: + properties: + localhostProfile: + type: string + type: + type: string + required: + - type + type: object + windowsOptions: + properties: + gmsaCredentialSpec: + type: string + gmsaCredentialSpecName: + type: string + hostProcess: + type: boolean + runAsUserName: + type: string + type: object + type: object + type: object + serviceMonitor: + properties: + interval: + type: string + labels: + additionalProperties: + type: string + type: object + type: object + type: object + type: object podTemplate: properties: controller: diff --git a/vendor/kubedb.dev/apimachinery/crds/ops.kubedb.com_ferretdbopsrequests.yaml b/vendor/kubedb.dev/apimachinery/crds/ops.kubedb.com_ferretdbopsrequests.yaml new file mode 100644 index 000000000..9da67451d --- /dev/null +++ b/vendor/kubedb.dev/apimachinery/crds/ops.kubedb.com_ferretdbopsrequests.yaml @@ -0,0 +1,314 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + creationTimestamp: null + labels: + app.kubernetes.io/name: kubedb + name: ferretdbopsrequests.ops.kubedb.com +spec: + group: ops.kubedb.com + names: + categories: + - datastore + - kubedb + - appscode + kind: FerretDBOpsRequest + listKind: FerretDBOpsRequestList + plural: ferretdbopsrequests + shortNames: + - frops + singular: ferretdbopsrequest + scope: Namespaced + versions: + - additionalPrinterColumns: + - jsonPath: .spec.type + name: Type + type: string + - jsonPath: .status.phase + name: Status + type: string + - jsonPath: .metadata.creationTimestamp + name: Age + type: date + name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + properties: + apply: + default: IfReady + enum: + - IfReady + - Always + type: string + databaseRef: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + horizontalScaling: + properties: + node: + format: int32 + type: integer + type: object + restart: + type: object + timeout: + type: string + tls: + properties: + certificates: + items: + properties: + alias: + type: string + dnsNames: + items: + type: string + type: array + duration: + type: string + emailAddresses: + items: + type: string + type: array + ipAddresses: + items: + type: string + type: array + issuerRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + privateKey: + properties: + encoding: + enum: + - PKCS1 + - PKCS8 + type: string + type: object + renewBefore: + type: string + secretName: + type: string + subject: + properties: + countries: + items: + type: string + type: array + localities: + items: + type: string + type: array + organizationalUnits: + items: + type: string + type: array + organizations: + items: + type: string + type: array + postalCodes: + items: + type: string + type: array + provinces: + items: + type: string + type: array + serialNumber: + type: string + streetAddresses: + items: + type: string + type: array + type: object + uris: + items: + type: string + type: array + required: + - alias + type: object + type: array + clientAuthMode: + enum: + - keyFile + - sendKeyFile + - sendX509 + - x509 + type: string + issuerRef: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + required: + - kind + - name + type: object + x-kubernetes-map-type: atomic + remove: + type: boolean + rotateCertificates: + type: boolean + sslMode: + enum: + - disabled + - allowSSL + - preferSSL + - requireSSL + type: string + type: object + type: + enum: + - UpdateVersion + - VerticalScaling + - Restart + - HorizontalScaling + - ReconfigureTLS + type: string + updateVersion: + properties: + targetVersion: + type: string + type: object + verticalScaling: + properties: + node: + properties: + nodeSelectionPolicy: + type: string + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + topology: + properties: + key: + type: string + value: + type: string + required: + - key + - value + type: object + type: object + type: object + required: + - databaseRef + - type + type: object + status: + properties: + conditions: + items: + properties: + lastTransitionTime: + format: date-time + type: string + message: + type: string + observedGeneration: + format: int64 + type: integer + reason: + type: string + severity: + type: string + status: + type: string + type: + type: string + required: + - lastTransitionTime + - status + - type + type: object + type: array + observedGeneration: + format: int64 + type: integer + pausedBackups: + items: + properties: + apiGroup: + type: string + kind: + type: string + name: + type: string + namespace: + type: string + required: + - name + type: object + type: array + phase: + enum: + - Pending + - Progressing + - Successful + - WaitingForApproval + - Failed + - Approved + - Denied + - Skipped + type: string + type: object + type: object + served: true + storage: true + subresources: + status: {} diff --git a/vendor/kubedb.dev/apimachinery/crds/ops.kubedb.com_memcachedopsrequests.yaml b/vendor/kubedb.dev/apimachinery/crds/ops.kubedb.com_memcachedopsrequests.yaml index f1e51641c..6464037d7 100644 --- a/vendor/kubedb.dev/apimachinery/crds/ops.kubedb.com_memcachedopsrequests.yaml +++ b/vendor/kubedb.dev/apimachinery/crds/ops.kubedb.com_memcachedopsrequests.yaml @@ -72,6 +72,10 @@ spec: type: object x-kubernetes-map-type: atomic horizontalScaling: + properties: + replicas: + format: int32 + type: integer type: object restart: type: object @@ -202,6 +206,40 @@ spec: type: object verticalScaling: properties: + exporter: + properties: + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + type: object memcached: properties: nodeSelectionPolicy: diff --git a/vendor/kubedb.dev/apimachinery/crds/ops.kubedb.com_solropsrequests.yaml b/vendor/kubedb.dev/apimachinery/crds/ops.kubedb.com_solropsrequests.yaml index 0a67ea29d..daa371cc5 100644 --- a/vendor/kubedb.dev/apimachinery/crds/ops.kubedb.com_solropsrequests.yaml +++ b/vendor/kubedb.dev/apimachinery/crds/ops.kubedb.com_solropsrequests.yaml @@ -48,6 +48,22 @@ spec: - IfReady - Always type: string + configuration: + properties: + applyConfig: + additionalProperties: + type: string + type: object + configSecret: + properties: + name: + default: "" + type: string + type: object + x-kubernetes-map-type: atomic + removeCustomConfig: + type: boolean + type: object databaseRef: properties: name: @@ -61,8 +77,238 @@ spec: type: string type: enum: + - UpdateVersion + - VerticalScaling + - VolumeExpansion + - Reconfigure - Restart type: string + updateVersion: + properties: + targetVersion: + type: string + type: object + verticalScaling: + properties: + coordinator: + properties: + nodeSelectionPolicy: + type: string + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + topology: + properties: + key: + type: string + value: + type: string + required: + - key + - value + type: object + type: object + data: + properties: + nodeSelectionPolicy: + type: string + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + topology: + properties: + key: + type: string + value: + type: string + required: + - key + - value + type: object + type: object + node: + properties: + nodeSelectionPolicy: + type: string + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + topology: + properties: + key: + type: string + value: + type: string + required: + - key + - value + type: object + type: object + overseer: + properties: + nodeSelectionPolicy: + type: string + resources: + properties: + claims: + items: + properties: + name: + type: string + required: + - name + type: object + type: array + x-kubernetes-list-map-keys: + - name + x-kubernetes-list-type: map + limits: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + requests: + additionalProperties: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + type: object + type: object + topology: + properties: + key: + type: string + value: + type: string + required: + - key + - value + type: object + type: object + type: object + volumeExpansion: + properties: + coordinator: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + data: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + mode: + enum: + - Offline + - Online + type: string + node: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + overseer: + anyOf: + - type: integer + - type: string + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true + required: + - mode + type: object required: - databaseRef - type diff --git a/vendor/kubedb.dev/apimachinery/pkg/double_optin/double_optin.go b/vendor/kubedb.dev/apimachinery/pkg/double_optin/double_optin.go index c1f1901d0..2dcc94def 100644 --- a/vendor/kubedb.dev/apimachinery/pkg/double_optin/double_optin.go +++ b/vendor/kubedb.dev/apimachinery/pkg/double_optin/double_optin.go @@ -24,28 +24,25 @@ import ( "k8s.io/klog/v2" ) -// CheckIfDoubleOptInPossible is the intended function to be called from operator -// It checks if the namespace, where SchemaDatabase or Archiver is applied, is allowed. -// It also checks the labels of schemaDatabase OR archiver, to decide if that is allowed or not. -// -// Here, clientMeta is the ObjectMeta of SchemaDatabase or Archiver -// & clientNSMeta is the ObjectMeta of the namespace where they belong. -func CheckIfDoubleOptInPossible(clientMeta metav1.ObjectMeta, clientNSMeta metav1.ObjectMeta, dbNSMeta metav1.ObjectMeta, consumers *dbapi.AllowedConsumers) (bool, error) { +// CheckIfDoubleOptInPossible is the intended function to be called from operators. +// In Archiver - DB connection, DB is the requester, Archiver is the allower +// In Schema - DB connection, Schema is the requester, DB is the allower +func CheckIfDoubleOptInPossible(requesterMeta, requesterNSMeta, allowerNSMeta metav1.ObjectMeta, consumers *dbapi.AllowedConsumers) (bool, error) { if consumers == nil { return false, nil } - matchNamespace, err := IsInAllowedNamespaces(clientNSMeta, dbNSMeta, consumers) + matchNamespace, err := IsInAllowedNamespaces(requesterNSMeta, allowerNSMeta, consumers) if err != nil { return false, err } - matchLabels, err := IsMatchByLabels(clientMeta, consumers) + matchLabels, err := IsMatchByLabels(requesterMeta, consumers) if err != nil { return false, err } return matchNamespace && matchLabels, nil } -func IsInAllowedNamespaces(clientNSMeta metav1.ObjectMeta, dbNSMeta metav1.ObjectMeta, consumers *dbapi.AllowedConsumers) (bool, error) { +func IsInAllowedNamespaces(requesterNSMeta, allowerNSMeta metav1.ObjectMeta, consumers *dbapi.AllowedConsumers) (bool, error) { if consumers.Namespaces == nil || consumers.Namespaces.From == nil { return false, nil } @@ -54,14 +51,14 @@ func IsInAllowedNamespaces(clientNSMeta metav1.ObjectMeta, dbNSMeta metav1.Objec return true, nil } if *consumers.Namespaces.From == dbapi.NamespacesFromSame { - return clientNSMeta.GetName() == dbNSMeta.GetName(), nil + return requesterNSMeta.GetName() == allowerNSMeta.GetName(), nil } if *consumers.Namespaces.From == dbapi.NamespacesFromSelector { if consumers.Namespaces.Selector == nil { // this says, Select namespace from the Selector, but the Namespace.Selector field is nil. So, no way to select namespace here. return false, nil } - ret, err := selectorMatches(consumers.Namespaces.Selector, clientNSMeta.GetLabels()) + ret, err := selectorMatches(consumers.Namespaces.Selector, requesterNSMeta.GetLabels()) if err != nil { return false, err } @@ -70,9 +67,9 @@ func IsInAllowedNamespaces(clientNSMeta metav1.ObjectMeta, dbNSMeta metav1.Objec return false, nil } -func IsMatchByLabels(clientMeta metav1.ObjectMeta, consumers *dbapi.AllowedConsumers) (bool, error) { +func IsMatchByLabels(requesterMeta metav1.ObjectMeta, consumers *dbapi.AllowedConsumers) (bool, error) { if consumers.Selector != nil { - ret, err := selectorMatches(consumers.Selector, clientMeta.Labels) + ret, err := selectorMatches(consumers.Selector, requesterMeta.Labels) if err != nil { return false, err } diff --git a/vendor/kubedb.dev/db-client-go/redis/kubedb_client_builder.go b/vendor/kubedb.dev/db-client-go/redis/kubedb_client_builder.go index 00d74d4d0..f94dbeb43 100644 --- a/vendor/kubedb.dev/db-client-go/redis/kubedb_client_builder.go +++ b/vendor/kubedb.dev/db-client-go/redis/kubedb_client_builder.go @@ -40,10 +40,11 @@ const ( ) type KubeDBClientBuilder struct { - kc client.Client - db *dbapi.Redis - podName string - url string + kc client.Client + db *dbapi.Redis + podName string + url string + database int } func NewKubeDBClientBuilder(kc client.Client, db *dbapi.Redis) *KubeDBClientBuilder { @@ -63,6 +64,11 @@ func (o *KubeDBClientBuilder) WithURL(url string) *KubeDBClientBuilder { return o } +func (o *KubeDBClientBuilder) WithDatabase(database int) *KubeDBClientBuilder { + o.database = database + return o +} + func (o *KubeDBClientBuilder) GetRedisClient(ctx context.Context) (*Client, error) { var err error if o.podName != "" { @@ -76,6 +82,7 @@ func (o *KubeDBClientBuilder) GetRedisClient(ctx context.Context) (*Client, erro ConnMaxIdleTime: DefaultConnMaxIdleTime, PoolSize: DefaultPoolSize, Addr: o.url, + DB: o.database, } if !o.db.Spec.DisableAuth { rdOpts.Password, err = o.getClientPassword(ctx) diff --git a/vendor/modules.txt b/vendor/modules.txt index 96550ad57..2e078b065 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -930,7 +930,7 @@ go.starlark.net/syntax # golang.org/x/exp v0.0.0-20240506185415-9bf2ced13842 ## explicit; go 1.20 golang.org/x/exp/maps -# golang.org/x/net v0.26.0 +# golang.org/x/net v0.27.0 ## explicit; go 1.18 golang.org/x/net/html golang.org/x/net/html/atom @@ -950,12 +950,12 @@ golang.org/x/oauth2/internal # golang.org/x/sync v0.7.0 ## explicit; go 1.18 golang.org/x/sync/errgroup -# golang.org/x/sys v0.21.0 +# golang.org/x/sys v0.22.0 ## explicit; go 1.18 golang.org/x/sys/plan9 golang.org/x/sys/unix golang.org/x/sys/windows -# golang.org/x/term v0.21.0 +# golang.org/x/term v0.22.0 ## explicit; go 1.18 golang.org/x/term # golang.org/x/text v0.16.0 @@ -1500,12 +1500,12 @@ kmodules.xyz/offshoot-api/util # kmodules.xyz/prober v0.29.0 ## explicit; go 1.21.5 kmodules.xyz/prober/api/v1 -# kmodules.xyz/resource-metadata v0.18.10 +# kmodules.xyz/resource-metadata v0.18.11-0.20240801195527-995886d0c0e5 ## explicit; go 1.22.1 kmodules.xyz/resource-metadata/apis/node kmodules.xyz/resource-metadata/apis/node/v1alpha1 kmodules.xyz/resource-metadata/crds -# kubedb.dev/apimachinery v0.47.0-rc.1 +# kubedb.dev/apimachinery v0.47.0-rc.2 ## explicit; go 1.22.1 kubedb.dev/apimachinery/apis kubedb.dev/apimachinery/apis/archiver/v1alpha1 @@ -1549,7 +1549,7 @@ kubedb.dev/apimachinery/crds kubedb.dev/apimachinery/pkg/double_optin kubedb.dev/apimachinery/pkg/factory kubedb.dev/apimachinery/pkg/validator -# kubedb.dev/db-client-go v0.2.0-rc.1 +# kubedb.dev/db-client-go v0.2.0-rc.2 ## explicit; go 1.22.1 kubedb.dev/db-client-go/elasticsearch kubedb.dev/db-client-go/redis