From cf21447164312f4cdc2d451b5c91a79845fed8f7 Mon Sep 17 00:00:00 2001 From: Uwe Krueger Date: Thu, 12 Jan 2023 17:48:43 +0100 Subject: [PATCH 1/2] add creationTime attribute --- .../ocmcmds/common/addhdlrs/comp/elements.go | 1 + .../ocmcmds/componentarchive/create/cmd.go | 1 + pkg/contexts/ocm/compdesc/meta/v1/types.go | 73 +++++++++++++++++++ .../v3alpha1/jsonscheme/bindata.go | 4 +- .../versions/v2/componentdescriptor.go | 3 + .../versions/v2/jsonscheme/bindata.go | 4 +- .../ocm/compdesc/versions/v2/version.go | 16 ++-- .../component-descriptor-ocm-v3-schema.yaml | 3 + resources/component-descriptor-v2-schema.yaml | 3 + 9 files changed, 97 insertions(+), 11 deletions(-) diff --git a/cmds/ocm/commands/ocmcmds/common/addhdlrs/comp/elements.go b/cmds/ocm/commands/ocmcmds/common/addhdlrs/comp/elements.go index 13c2e4c6c..a295efb25 100644 --- a/cmds/ocm/commands/ocmcmds/common/addhdlrs/comp/elements.go +++ b/cmds/ocm/commands/ocmcmds/common/addhdlrs/comp/elements.go @@ -82,6 +82,7 @@ func (*ResourceSpecHandler) Add(ctx clictx.Context, ictx inputs.Context, elem ad cd.Labels = r.Labels cd.Provider = r.Provider + cd.CreationTime = metav1.NewTimestampP() err = handle(ctx, ictx, elem.Source(), cv, r.Sources, srcs.ResourceSpecHandler{}) if err != nil { diff --git a/cmds/ocm/commands/ocmcmds/componentarchive/create/cmd.go b/cmds/ocm/commands/ocmcmds/componentarchive/create/cmd.go index a7dab97f2..da3ce0756 100644 --- a/cmds/ocm/commands/ocmcmds/componentarchive/create/cmd.go +++ b/cmds/ocm/commands/ocmcmds/componentarchive/create/cmd.go @@ -141,6 +141,7 @@ func (o *Command) Run() error { desc.Provider.Name = metav1.ProviderName(o.Provider) desc.Provider.Labels = o.ProviderLabels desc.Labels = o.Labels + desc.CreationTime = metav1.NewTimestampP() err = compdesc.Validate(desc) if err != nil { diff --git a/pkg/contexts/ocm/compdesc/meta/v1/types.go b/pkg/contexts/ocm/compdesc/meta/v1/types.go index 5764f1786..7ef4c3272 100644 --- a/pkg/contexts/ocm/compdesc/meta/v1/types.go +++ b/pkg/contexts/ocm/compdesc/meta/v1/types.go @@ -5,7 +5,11 @@ package v1 import ( + "time" + "k8s.io/apimachinery/pkg/util/validation/field" + + "github.com/open-component-model/ocm/pkg/errors" ) const ( @@ -73,6 +77,9 @@ type ObjectMeta struct { Labels Labels `json:"labels,omitempty"` // Provider described the component provider Provider Provider `json:"provider"` + // CreationTime is the creation time of component version + // +optional + CreationTime *Timestamp `json:"creationTime,omitempty"` } // GetName returns the name of the object. @@ -151,3 +158,69 @@ func (o *Provider) Copy() *Provider { Labels: o.Labels.Copy(), } } + +//////////////////////////////////////////////////////////////////////////////// + +type _time = time.Time + +// Timestamp is time rounded to seconds. +type Timestamp struct { + _time +} + +func NewTimestamp() Timestamp { + return Timestamp{time.Now().Round(time.Second)} +} + +func NewTimestampP() *Timestamp { + return &Timestamp{time.Now().Round(time.Second)} +} + +func NewTimestampFor(t time.Time) Timestamp { + return Timestamp{t.Round(time.Second)} +} + +// MarshalJSON implements the json.Marshaler interface. +// The time is a quoted string in RFC 3339 format, with sub-second precision added if present. +func (t Timestamp) MarshalJSON() ([]byte, error) { + if y := t.Year(); y < 0 || y >= 10000 { + // RFC 3339 is clear that years are 4 digits exactly. + // See golang.org/issue/4556#c15 for more discussion. + return nil, errors.New("Time.MarshalJSON: year outside of range [0,9999]") + } + + b := make([]byte, 0, len(time.RFC3339)+2) + b = append(b, '"') + b = t.AppendFormat(b, time.RFC3339) + b = append(b, '"') + return b, nil +} + +// UnmarshalJSON implements the json.Unmarshaler interface. +// The time is expected to be a quoted string in RFC 3339 format. +func (t *Timestamp) UnmarshalJSON(data []byte) error { + // Ignore null, like in the main JSON package. + if string(data) == "null" { + return nil + } + // Fractional seconds are handled implicitly by Parse. + tt, err := time.Parse(`"`+time.RFC3339+`"`, string(data)) + *t = NewTimestampFor(tt) + return err +} + +func (t *Timestamp) Time() time.Time { + return t._time +} + +func (t *Timestamp) Equal(o Timestamp) bool { + return t._time.Equal(o._time) +} + +func (t *Timestamp) UTC() Timestamp { + return NewTimestampFor(t._time.UTC()) +} + +func (t *Timestamp) Add(d time.Duration) Timestamp { + return NewTimestampFor(t._time.Add(d)) +} diff --git a/pkg/contexts/ocm/compdesc/versions/ocm.software/v3alpha1/jsonscheme/bindata.go b/pkg/contexts/ocm/compdesc/versions/ocm.software/v3alpha1/jsonscheme/bindata.go index ec4279f05..af3a22dcb 100644 --- a/pkg/contexts/ocm/compdesc/versions/ocm.software/v3alpha1/jsonscheme/bindata.go +++ b/pkg/contexts/ocm/compdesc/versions/ocm.software/v3alpha1/jsonscheme/bindata.go @@ -79,7 +79,7 @@ func (fi bindataFileInfo) Sys() interface{} { return nil } -var _ResourcesComponentDescriptorOcmV3SchemaYaml = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x1a\xef\x6f\xdb\xb8\xf5\xbb\xfe\x8a\x87\x4b\x01\x39\x4d\x64\x37\x29\x3a\xe0\xfc\x25\xc8\x7a\x18\x50\x6c\x77\x39\xb4\xb7\x7d\x58\xea\x15\xb4\xf4\x64\xb3\x47\x91\x1e\x49\x39\x71\x7b\xfd\xdf\x07\x92\xa2\x7e\x59\xb2\x65\x3b\xed\x36\xdc\xe5\x4b\x4c\xea\xfd\xe2\xe3\xfb\x2d\x3d\xa3\xc9\x14\xc2\xa5\xd6\x2b\x35\x9d\x4c\x16\x44\x26\xc8\x51\x8e\x63\x26\xf2\x64\xa2\xe2\x25\x66\x44\x4d\x62\x91\xad\x04\x47\xae\xa3\x04\x55\x2c\xe9\x4a\x0b\x19\x89\x38\x8b\xd6\x2f\x09\x5b\x2d\xc9\x55\x18\x3c\x73\xb0\x35\x5a\x1f\x95\xe0\x91\xdb\x1d\x0b\xb9\x98\x24\x92\xa4\x7a\x72\xfd\xe2\xfa\x45\x74\x75\x5d\x90\x0e\x03\x4f\x90\x0a\x3e\x85\xf0\xee\xf5\x8f\xf0\xda\x33\x83\x1f\x4a\x66\xb0\x7e\x09\x15\x46\x4a\x39\x35\x08\x6a\x1a\x00\x64\xa8\x89\xf9\x0f\xa0\x37\x2b\x9c\x42\x28\xe6\x1f\x31\xd6\xa1\xdd\x6a\x52\x2f\x8f\x01\x6b\x94\x8a\x0a\x6e\x91\x13\xa2\x89\x83\x96\xf8\xef\x9c\x4a\x4c\x1c\x39\x80\x08\x42\x4e\x32\x0c\xab\x65\x81\xe7\x76\x48\x92\x58\x31\x08\xfb\x59\x8a\x15\x4a\x4d\x51\x4d\x21\x25\x4c\xa1\x7d\xbe\xaa\x76\x0b\x0a\x86\x9a\xff\x0d\xf0\x4c\x62\x3a\x85\xf0\x6c\x52\x3b\x51\xa5\xea\x9f\x6a\x9c\x0b\xb6\x7b\x50\x25\x32\xf2\x88\xc9\x3b\xcc\xd6\x28\x3d\x2a\x23\x73\x64\x6a\x0f\xa6\x03\xf2\x28\x2b\x29\xd6\x34\x41\xb9\x07\xc9\x83\x85\x41\xd0\x64\x53\xdc\x03\x91\x92\x6c\x1c\x4d\xaa\x31\x2b\x65\xe8\x97\x20\xf4\x84\x7a\xef\x73\xc0\x0d\x11\x96\x17\xeb\x7d\xfa\x77\xf4\x95\x96\x94\x2f\xbc\xa2\x0d\xf6\x14\x3e\x7f\xe9\x53\xfc\x8a\x68\x8d\xd2\x18\xd3\xbf\xd6\xf7\x2f\xa2\xef\x67\x17\xcf\x3c\x73\x45\x17\x9c\xe8\x5c\x6e\x71\x08\xe7\x42\x30\x24\x03\xac\x26\x00\x68\xdc\x7f\x43\x0f\x4e\x50\x47\x24\x23\x8f\x7f\x43\xbe\xd0\xcb\x29\x5c\xbf\x7a\x15\xb4\x24\xbb\x27\xd1\xa7\xd9\x7d\x44\xa2\x4f\x46\xc2\xe7\xa3\xfb\xf1\xac\xb5\x75\xfe\xdc\xef\x7d\xbe\xbe\xfc\x32\x9a\x34\x1e\x7f\xe8\x40\xf9\x60\x70\xce\xcd\x61\x03\x00\x9a\x20\xd7\x54\x6f\x6e\xb5\x96\x74\x9e\x6b\xfc\x2b\x6e\x9c\xa8\x19\xe5\xa5\x5c\x5d\x52\x19\xe6\xa3\xfb\xe8\xc3\x85\x17\xc4\x6f\x9e\xdf\x38\xd2\x0d\x1b\x76\x34\xcf\x40\x93\x5f\x91\x43\x2a\x45\x06\xca\x3e\x30\xf1\x04\x08\x4f\x80\x24\x1f\x73\xa5\x31\x01\x2d\x80\x30\x26\x1e\x80\x70\x10\x2b\xa7\x5f\x60\x48\x12\xca\x17\x10\xae\xc3\x4b\xc8\xc8\x47\x13\xb4\x38\xdb\x5c\x5a\x54\xbb\x1e\x67\x94\x17\xbb\x9e\xd7\x92\x2a\xc8\x90\x70\x05\x7a\x89\x90\x0a\x43\xd5\x10\x71\xea\x57\x40\x24\x1a\x56\xc6\x54\x68\xd2\x94\x57\x79\x81\xaf\xc6\xd7\xe3\x97\xf5\xdf\x51\x2a\xc4\xc5\x9c\xc8\x62\x6f\x5d\x07\x58\x77\x41\x5c\x8d\xaf\xfd\xaf\x12\xac\x06\x5f\xfe\x6c\xa0\xd5\x95\xbd\x9e\xdd\x8c\x5e\xfc\x76\x7f\x15\x7d\x3f\x7b\x9f\x3c\x3f\x1f\xdd\x4c\xdf\x8f\xeb\x1b\xe7\x37\xdd\x5b\xd1\x68\x74\x33\xad\x36\x7f\x7b\x9f\xd8\x3b\xba\x8d\xfe\x19\xcd\x8c\xc1\xfb\xdf\x9e\xe4\x40\xe0\x73\xcf\xf1\x62\x54\x7f\x70\x61\x89\x34\x76\x2c\x64\xe1\x54\x2d\xcb\xef\x32\xbd\xde\x50\x51\x78\xff\xc6\xf8\x91\x9a\xc2\xe7\xee\xb8\xd3\x65\xca\x21\x7c\x71\xa6\xb8\x12\x8a\x6a\x21\x37\xaf\x05\xd7\xf8\xa8\x0f\x89\x4a\x06\xaa\x2f\x0a\x59\x0a\xed\x18\x51\x3b\xa3\x88\xe9\xdb\x6e\xde\x84\xb1\xbb\xb4\xe2\xd2\x93\x05\x5a\xa8\x55\x70\x6c\xcb\x59\xc8\x3a\x27\x0a\xff\x2e\x59\x58\x05\xb9\x2d\x91\xcd\x5f\x01\x56\xdf\xea\x8c\x4d\xee\xaf\x11\xc7\x7e\x24\xab\x15\xe5\x8b\x81\xa8\x00\xc8\xf3\x6c\x0a\xf7\x61\x2e\xd9\xcf\x44\x2f\xc3\x4b\x08\xd5\x92\x5c\xbf\xfa\x53\x94\xd0\x05\x2a\x1d\xce\x82\x16\x9d\x43\x29\x5b\x1d\x2f\xa8\xd2\x72\x63\xa8\xdf\xbd\x7e\x53\x2e\x67\xe6\x0e\x48\x1c\xa3\x52\x03\xeb\x0a\xa3\x19\x0b\x05\xa9\x90\x05\x2a\x2a\x18\x99\x15\x3e\x6a\xe4\x26\x87\xa8\xf3\x3d\xc6\x12\x00\x2c\xa8\x5e\xe6\xf3\xdb\xdd\xbc\x77\x5a\x9b\x5d\x1a\x13\xa8\x5d\xa8\xdd\x49\x8f\xb2\xc6\xb6\xda\x9c\x80\xa5\xfa\x0b\x46\x7b\xd0\x8d\x95\xee\x86\x88\x45\x96\x51\xbd\xcb\x27\xb8\xe0\x78\x8a\x5e\x4e\x3c\xf7\x4f\x82\xa3\x33\x0c\x25\x72\x19\xe3\x0f\xa5\xc3\x1d\x20\x8e\xa9\x3e\xca\x45\x51\x59\x94\x6b\x43\xa1\x5c\x38\x13\x3a\xa0\x88\xd9\x12\x7c\x78\xb0\x2b\x50\xf0\x51\x4b\xf2\xa6\x00\xd8\x53\xf9\x6d\xd1\x79\x82\x3a\x75\xc0\x75\x1c\x51\xca\xd6\xdd\xd8\xae\xf9\xe6\x2e\x6d\x86\xbf\x4e\x2a\x0e\x2f\xdc\x0f\x58\xf7\xd8\x01\xe0\xa6\x37\xf2\xc0\x01\x80\x8b\x66\xef\x56\x18\x1f\x60\x46\x4b\xa2\x96\xb7\x6c\x21\x24\xd5\xcb\xac\x32\x2e\x21\x33\xc2\xa8\x22\x86\xd1\xf6\x63\x5b\xd8\x1e\xd9\xb5\x34\x18\xee\x2c\x9f\xbb\x85\x18\x50\x71\x77\x43\x04\xb5\xa2\xfa\x40\x25\x91\x1d\x1a\x30\xab\x0c\x13\x4a\x7e\xf1\x3e\x77\xb8\x4e\xc8\xc9\x87\x73\x5b\xa5\x1c\x15\x54\x33\xb7\xfc\xb2\x44\x07\xe4\x12\x8c\x48\x6d\x59\x5a\xaa\x05\x6a\xfd\xce\x4e\xfd\x1d\x1b\xa7\x9c\x89\x96\xcb\x92\xde\x91\x7a\xdb\xdb\x81\x39\x7e\x7b\x9c\xbc\xf2\x9b\x1d\xcd\x57\x27\x66\xc3\x9e\xac\x0f\x2a\x19\xbf\xf5\x09\x6a\x6f\xa6\x27\x26\x99\xa1\x44\x1e\xa3\x6d\x39\x60\x54\x8d\x46\x98\x88\x09\x3b\x2f\x12\x44\x5f\xd6\xf1\xa1\xf3\x1d\x32\x8c\xb5\xd8\xd7\x63\xf7\x46\xda\x83\x62\xa1\x2d\x66\x0b\xb1\x8f\x3d\x68\x79\xce\xa1\x8d\x78\xe7\x20\xe3\xf4\x11\x4a\x47\x7f\xdc\x7b\xfe\x4e\x11\x76\xa5\x4f\x38\x03\x12\xeb\x9c\x30\xb6\x99\x56\x9c\x22\xeb\x79\x0f\x13\x50\x2b\x8c\x29\x61\x20\xd1\xc0\xc7\x96\xc9\xff\x6f\xc6\x3d\x22\x9d\xb6\x9d\x53\x70\x6c\xa7\xd3\x42\xa1\x3c\x67\x6c\x40\x3e\xac\x3b\xb2\xb5\x52\xe7\x3d\x55\x40\x3c\xb0\xf6\xf6\x04\xd4\xa1\x03\x3d\x38\xb3\xf8\xd6\x87\x2b\x2a\x97\xc5\x38\x20\x57\x1a\x32\xa2\xe3\x65\xcd\x0d\xd4\x56\x09\xb7\x5d\x86\x33\x9b\x08\x6b\x5b\xf5\xba\xe2\x8f\xca\xae\x3c\x95\x8b\xc1\x6a\x0b\xaa\x36\x42\x84\xf6\x18\xb1\x57\x08\x47\xac\x6a\x3e\xdc\x25\x0c\x2e\xf5\xad\x09\x98\x9e\xd0\x74\x6e\x92\x13\x56\x76\x3b\xff\x8b\xf5\xa7\x88\xe9\x9f\x99\x18\x5e\x80\xda\xd3\xfd\x85\x32\x54\x1b\xa5\x31\x3b\x1c\xf7\xae\x8b\xe1\xd7\x8e\x0b\x22\xa6\x6f\x32\xb2\x38\xa9\x03\xb4\x4b\x6a\xa8\xbc\xf5\x99\xed\x49\x5a\xc3\xfa\x24\xc1\x5b\x4a\x93\xcd\x9e\x59\x4f\xa5\xce\x13\x0e\xc6\xc8\xc6\x7b\xdc\x69\xe7\x81\xb0\x10\x29\x84\xaa\xcb\x4f\xfb\xaa\xd3\x5b\x73\x80\x66\xa9\x60\xca\xd3\x8c\x70\x9a\xa2\xd2\xed\xba\xb4\xc5\xf4\xc8\xe2\xd7\x69\xc6\x85\x66\xe7\x28\x4e\x02\x05\x5a\xec\xe1\xd8\x36\xd4\x6d\x76\x0e\xc2\xb3\xd2\x44\x2e\x50\x63\x02\xb1\xe0\xba\x2c\x7e\x7a\xc9\x2b\xfa\x69\xe7\x59\xcc\x73\xa0\x1c\xe6\x1b\x8d\xca\xf3\x98\x1b\x65\xb7\xe9\xf2\x3c\x9b\xfb\x57\x2b\x7d\x2e\x7b\x82\xb9\xa4\x94\x61\x95\x09\x4f\xb5\x98\x0e\x09\x2b\xeb\xf1\xac\xfa\xf4\xe2\x9f\xd7\xd5\x01\x7a\x49\x34\x50\x65\xcf\x6e\xd4\x4f\xb9\x7d\xf6\x9d\x79\xa8\xbe\x83\x84\x4a\x5b\x3d\x6f\x7a\xef\xc3\xeb\xed\xee\x89\xfc\xeb\x2b\x28\xec\xae\xed\x67\xbb\x8d\xb3\x69\x98\xd6\xdf\xe1\x81\xea\x65\xa1\x9a\x38\x97\x12\xb9\xae\x0a\x14\xa8\x5e\xd5\xee\xd2\x92\x0f\xad\x6f\x8b\x9a\xe7\x94\x57\x6f\xf5\xca\xbe\x4b\x89\x7f\x54\x3f\xfb\x73\x89\xbd\x8c\xa7\x2c\x39\xfa\xca\x86\x5a\x42\xfd\x36\x69\x3c\x00\xa8\xc6\x5f\x27\xb8\x62\xee\x27\xdb\x27\x26\x6e\x23\x4c\xa9\xe8\x7c\xc7\x14\x3b\x00\x58\x20\x47\x49\xe3\xff\xe2\x04\xba\x90\xc0\x0d\xa1\x8b\xc5\xb7\xf6\xd9\xa7\x19\xf7\xfc\xce\x7c\xba\xba\x38\xb7\xff\xb5\x5c\xba\x61\xa2\xdf\xaa\x30\x6f\x7e\x2a\x72\xa8\x05\x7e\x15\x7b\x3a\x74\x32\xa6\x76\x0d\x96\x9b\x29\xd8\xce\x7f\x52\x1a\xdb\x86\xd2\x67\xe2\xa2\x32\x34\xcb\xda\x94\xcc\x9b\x97\x3e\xf6\xa4\xc5\x04\xe2\x89\x5a\xe2\xd6\x4b\xab\xda\x9b\x39\x57\xb8\x3f\x11\x1f\xd9\xec\xac\xaa\x81\xce\xe1\xf4\xb7\x3a\xe5\x1d\x2f\xbc\xab\xa1\x51\x38\x04\xa1\x5d\xf2\x0c\x42\x6a\x85\xdc\x30\x08\x5a\xe6\x52\xb7\x74\x13\x37\x57\xf4\x1f\x55\x6c\x8d\x20\xfc\x95\xf2\xa4\xf8\x59\xff\xea\x2c\x72\x66\x15\x06\x4d\x13\xa8\xd0\x1b\xb6\x59\x37\xf5\x5a\xc3\x96\x8d\x5b\x1f\xee\x95\xdf\xe5\x5d\xba\xc7\x4a\xa4\xfa\x81\x48\xac\x1e\xd8\xaa\xd3\xc8\xd4\x4b\x3f\x16\x5c\xe9\x29\x84\xe5\xf7\x78\xb5\xf3\xf8\x13\x38\xe4\x4e\x85\x19\x90\xb0\xeb\x33\x8a\x61\x5f\x89\xb5\xee\xbf\xff\x2a\xb7\x3e\x95\x08\xe1\xcc\x57\xc3\x6c\x73\x09\x0f\x08\x82\xb3\x4d\xf1\x79\x90\x6d\x1a\x05\xc7\x86\xe3\x77\xfb\x4c\xf1\x76\xa1\x7c\x63\x70\xc2\xd7\x6d\x25\x8d\xf0\x3f\x01\x00\x00\xff\xff\x02\xfb\x97\xa2\x6f\x29\x00\x00") +var _ResourcesComponentDescriptorOcmV3SchemaYaml = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x1a\xef\x6f\xdb\xb8\xf5\xbb\xfe\x8a\x87\x4b\x01\x39\x4d\x64\x37\x29\x3a\xe0\xfc\x25\xc8\x7a\x18\x50\x6c\x77\x39\xb4\xdd\x3e\x2c\xcd\x0a\x5a\x7a\xb6\xd9\xa3\x48\x8f\xa4\x9c\xb8\xbd\xfe\xef\x03\x49\x51\xa2\x64\xc9\x3f\x93\x6e\xc3\x35\x5f\x62\x52\xef\x37\xdf\x2f\x3e\xe9\x19\xcd\xc6\x10\xcf\xb5\x5e\xa8\xf1\x68\x34\x23\x32\x43\x8e\x72\x98\x32\x51\x64\x23\x95\xce\x31\x27\x6a\x94\x8a\x7c\x21\x38\x72\x9d\x64\xa8\x52\x49\x17\x5a\xc8\x44\xa4\x79\xb2\x7c\x49\xd8\x62\x4e\x2e\xe2\xe8\x99\x83\x0d\x68\x7d\x52\x82\x27\x6e\x77\x28\xe4\x6c\x94\x49\x32\xd5\xa3\xcb\x17\x97\x2f\x92\x8b\xcb\x92\x74\x1c\x79\x82\x54\xf0\x31\xc4\x37\xaf\x7f\x86\xd7\x9e\x19\xfc\x54\x31\x83\xe5\x4b\xa8\x31\xa6\x94\x53\x83\xa0\xc6\x11\x40\x8e\x9a\x98\xff\x00\x7a\xb5\xc0\x31\xc4\x62\xf2\x09\x53\x1d\xdb\xad\x26\xf5\x4a\x0d\x58\xa2\x54\x54\x70\x8b\x9c\x11\x4d\x1c\xb4\xc4\x7f\x17\x54\x62\xe6\xc8\x01\x24\x10\x73\x92\x63\x5c\x2f\x4b\x3c\xb7\x43\xb2\xcc\x8a\x41\xd8\xaf\x52\x2c\x50\x6a\x8a\x6a\x0c\x53\xc2\x14\xda\xe7\x8b\x7a\xb7\xa4\x60\xa8\xf9\xdf\x00\xcf\x24\x4e\xc7\x10\x9f\x8c\x02\x8d\x6a\x53\xff\x12\x70\x2e\xd9\x6e\x41\x95\xc8\xc8\x03\x66\xef\x30\x5f\xa2\xf4\xa8\x8c\x4c\x90\xa9\x2d\x98\x0e\xc8\xa3\x2c\xa4\x58\xd2\x0c\xe5\x16\x24\x0f\xe6\xd1\x52\x89\xc4\x3c\x79\x4f\x43\x25\xdd\xa1\x28\x2d\x29\x9f\x55\x9b\x53\x21\x73\xa2\xc7\x90\x11\x8d\x89\xa6\x39\x46\x51\x53\xd2\xf2\x28\x89\x94\x64\xe5\xe8\x53\x8d\x79\xa5\x46\xbf\x12\xb1\x27\xd4\xeb\x12\x3b\x1c\x32\x61\x45\xb9\xde\x76\x84\x1d\xda\x59\xec\x31\x7c\xf9\xda\x77\x76\x0b\xa2\x35\x4a\xe3\x8f\xff\x5a\xde\xbe\x48\x7e\xbc\x3b\x7b\xe6\x99\x2b\x3a\xe3\x44\x17\x72\x8d\x43\x3c\x11\x82\x21\xd9\xc1\xf1\x22\x80\x86\x0b\x35\xec\xe0\x04\x75\x44\x72\xf2\xf0\x37\xe4\x33\x3d\x1f\xc3\xe5\xab\x57\x51\x4b\xb2\x5b\x92\x7c\xbe\xbb\x4d\x48\xf2\xd9\x48\xf8\x7c\x70\x3b\xbc\x6b\x6d\x9d\x3e\xf7\x7b\x5f\x2e\xcf\xbf\x0e\x46\x8d\xc7\x1f\x3b\x50\x3e\x1a\x9c\x53\xa3\x6c\x04\x40\x33\xe4\x9a\xea\xd5\xb5\xd6\x92\x4e\x0a\x8d\x7f\xc5\x95\x13\x35\xa7\xbc\x92\xab\x4b\x2a\xc3\x7c\x70\x9b\x7c\x3c\xf3\x82\xf8\xcd\xd3\x2b\x47\xba\x11\x06\x8e\xe6\x09\x68\xf2\x1b\x72\x98\x4a\x91\x83\xb2\x0f\x4c\x4a\x02\xc2\x33\x20\xd9\xa7\x42\x69\xcc\x40\x0b\x20\x8c\x89\x7b\x20\x1c\xc4\xc2\xd9\x17\x18\x92\x8c\xf2\x19\xc4\xcb\xf8\x1c\x72\xf2\xc9\xe4\x3d\xce\x56\xe7\x16\xd5\xae\x87\x39\xe5\xe5\xae\xe7\x35\xa7\x0a\x72\x24\x5c\x81\x9e\x23\x4c\x85\xa1\x6a\x88\x38\xf3\x2b\x20\x12\x0d\x2b\xe3\x2a\x34\x6b\xca\xab\xbc\xc0\x17\xc3\xcb\xe1\xcb\xf0\x77\x32\x15\xe2\x6c\x42\x64\xb9\xb7\x0c\x01\x96\x5d\x10\x17\xc3\x4b\xff\xab\x02\x0b\xe0\xab\x9f\x0d\xb4\xd0\xd8\xcb\xbb\xab\xc1\x8b\xdf\x6f\x2f\x92\x1f\xef\x3e\x64\xcf\x4f\x07\x57\xe3\x0f\xc3\x70\xe3\xf4\xaa\x7b\x2b\x19\x0c\xae\xc6\xf5\xe6\xef\x1f\x32\x7b\x46\xd7\xc9\x3f\x93\x3b\xe3\xf0\xfe\xb7\x27\xb9\x23\xf0\xa9\xe7\x78\x36\x08\x1f\x9c\x59\x22\x8d\x1d\x0b\x59\x06\x55\xcb\xf3\xbb\x5c\xaf\x37\x55\x94\xd1\xbf\x32\x71\xa4\xc6\xf0\xa5\x3b\xef\x74\xb9\x72\x0c\x5f\x9d\x2b\x2e\x84\xa2\x5a\xc8\xd5\x6b\xc1\x35\x3e\xe8\x7d\xb2\x92\x81\xea\xcb\x42\x96\x42\x3b\x47\x04\x3a\x8a\x94\xbe\xed\xe6\x4d\x18\xbb\x99\xd6\x5c\x7a\x0a\x49\x0b\xb5\x4e\x8e\x6d\x39\x4b\x59\x27\x44\xe1\xdf\x25\x8b\xeb\x24\xb7\x26\xb2\xf9\x2b\xc1\xc2\xad\xce\xdc\x54\x16\x94\x30\x8f\xfd\x4c\x16\x0b\xca\x67\x3b\xa2\x02\x20\x2f\xf2\x31\xdc\xc6\x85\x64\xbf\x12\x3d\x8f\xcf\x21\x56\x73\x72\xf9\xea\x4f\x49\x46\x67\xa8\x74\x7c\x17\xb5\xe8\xec\x4b\xd9\xda\x78\x46\x95\x96\x2b\x43\xfd\xe6\xf5\x9b\x6a\x79\x67\xce\x80\xa4\x29\x2a\xb5\x63\x6b\x62\x2c\x63\xa1\x4c\x6d\x2c\x51\x51\xc1\xc0\xac\xf0\x41\x23\x37\x35\x44\x9d\x6e\x71\x96\x08\x60\x46\xf5\xbc\x98\x5c\x6f\xe6\xbd\xd1\xdb\xec\xd2\xb8\x40\x70\xa0\x76\x67\x7a\x90\x37\xb6\xcd\xe6\x04\xac\xcc\x5f\x32\xda\x82\x6e\xbc\x74\x33\x44\x2a\xf2\x9c\xea\x4d\x31\xc1\x05\xc7\x63\xec\x72\xa4\xde\xbf\x08\x8e\xce\x31\x94\x28\x64\x8a\x3f\x55\x01\xb7\x87\x38\xa6\xfb\xa8\x16\x65\x67\x51\xad\x0d\x85\x6a\xe1\x5c\x68\x8f\x26\x66\x4d\xf0\xdd\x93\x5d\x89\x82\x0f\x5a\x92\x37\x25\xc0\x96\xe6\x71\x8d\xce\x23\xb4\xba\x3b\x1c\xc7\x01\xdd\x70\x18\xc6\x76\xcd\x57\x37\xd3\x66\xfa\xeb\xa4\xe2\xf0\xe2\xed\x80\x61\xc4\xee\x00\x6e\xae\x57\x1e\x38\x02\x70\xd9\xec\xdd\x02\xd3\x3d\xdc\x68\x4e\xd4\xfc\x9a\xcd\x84\xa4\x7a\x9e\xd7\xce\x65\xba\x72\x46\x95\xed\xe2\xd7\x1f\xdb\xc6\xf6\xc0\x8b\x4f\x83\xe1\xc6\xf6\xb9\x5b\x88\x1d\x3a\xee\x6e\x88\x28\x68\xaa\xf7\x34\x12\xd9\x60\x01\xb3\xca\x31\xa3\xe4\xbd\x8f\xb9\xfd\x6d\x42\x8e\x56\xce\x6d\x55\x72\xd4\x50\xcd\xda\xf2\x7e\x8e\x0e\xc8\x15\x18\x31\xb5\x6d\x69\x65\x16\x08\xee\x3b\x1b\xed\x77\x68\x9e\x72\x2e\x5a\x2d\x2b\x7a\x07\xda\x6d\xeb\x0d\xcc\xf1\xdb\x12\xe4\x75\xdc\x6c\xb8\x7c\x75\x62\x36\xfc\xc9\xc6\xa0\x92\xe9\x5b\x5f\xa0\xb6\x56\x7a\x62\x8a\x19\x4a\xe4\x29\xda\x2b\x07\x0c\xea\xe9\x0a\x13\x29\x61\xa7\x65\x81\xe8\xab\x3a\x3e\x75\xbe\x43\x86\xa9\x16\xdb\xae\xe9\xbd\x99\x76\xaf\x5c\x68\x9b\xd9\x52\xec\x43\x15\xad\xf4\xdc\xf5\x22\xde\x39\x0b\x39\x7e\x0a\xd3\x71\x3f\xee\xd5\xbf\x53\x84\x4d\xe5\x13\x4e\x80\xa4\xba\x20\x8c\xad\xc6\x35\xa7\xc4\x46\xde\xfd\x08\xd4\x02\x53\x4a\x18\x48\x34\xf0\xa9\x65\xf2\xff\x5b\x71\x0f\x28\xa7\xed\xe0\x14\x1c\xdb\xe5\xb4\x34\x28\x2f\x18\xdb\xa1\x1e\x86\x81\x6c\xbd\xd4\x45\x4f\x9d\x10\xf7\xec\xbd\x3d\x01\xb5\xef\x4c\x10\x4e\x2c\xbe\x8d\xe1\x9a\xca\x79\x39\x0e\x28\x94\x86\x9c\xe8\x74\x1e\x84\x81\x5a\x6b\xe1\xd6\xdb\x70\x66\x0b\x61\xb0\x15\xf6\x15\xdf\x3b\xbb\x4a\x2b\x97\x83\xd5\x1a\x54\x30\x42\x84\xf6\x18\xb1\x57\x08\x47\xac\xbe\x7c\xb8\x43\xd8\xb9\xd5\xb7\x2e\x60\xee\x84\xe6\xe6\x26\x39\x61\xd5\x6d\xe7\x7f\xb1\xff\x14\x29\xfd\x33\x13\xbb\x37\xa0\x56\xbb\xbf\x50\x86\x6a\xa5\x34\xe6\xfb\xe3\xde\x74\x31\x7c\xea\xbc\x20\x52\xfa\x26\x27\xb3\xa3\x6e\x80\x76\x49\x0d\x95\xb7\xbe\xb2\x3d\xca\xd5\x30\x9c\x24\x78\x4f\x69\xb2\xd9\x32\xeb\xa9\xcd\x79\x84\x62\x8c\xac\x7c\xc4\x1d\xa7\x0f\xc4\xa5\x48\x31\xd4\xb7\xfc\x69\x5f\x77\x7a\x6d\x14\x68\xb6\x0a\xa6\x3d\xcd\x09\xa7\x53\x54\xba\xdd\x97\xb6\x98\x1e\xd8\xfc\x3a\xcb\xb8\xd4\xec\x02\xc5\x49\xa0\x40\x8b\x2d\x1c\xdb\x8e\xba\xce\xce\x41\x78\x56\x9a\xc8\x19\x6a\xcc\x20\x15\x5c\x57\xcd\x4f\x2f\x79\x45\x3f\x6f\xd4\xc5\x3c\x07\xca\x61\xb2\xd2\xa8\x3c\x8f\x89\x31\x76\x9b\x2e\x2f\xf2\x89\x39\xd0\x08\xa0\x37\x64\x8f\x70\x97\x29\x65\x58\x57\xc2\x63\x3d\xa6\x43\xc2\xda\x7b\x3c\xab\x3e\xbb\xf8\xe7\xa1\x39\x40\xcf\x89\x06\xaa\xac\xee\xc6\xfc\x94\xdb\x67\x3f\x98\x87\xea\x07\xc8\xa8\xb4\xdd\xf3\xaa\xf7\x3c\xbc\xdd\x6e\x1e\x29\xbe\x9e\xc0\x60\x37\xed\x38\xdb\xec\x9c\x4d\xc7\xb4\xf1\x0e\xf7\x54\xcf\x4b\xd3\xa4\x85\x94\xc8\x75\xdd\xa0\x40\xfd\xb6\x77\x93\x95\x7c\x6a\x7d\x5b\xf6\x3c\xc7\xbc\x7a\x0b\x3b\xfb\x2e\x23\x7e\xef\x7e\xb6\xd7\x12\x7b\x18\x8f\xd9\x72\xf4\xb5\x0d\x41\x41\xfd\x36\x65\x3c\x02\xa8\xc7\x5f\x47\x84\x62\xe1\x27\xdb\x47\x16\x6e\x23\x4c\x65\xe8\x62\xc3\x14\x3b\x02\x98\x21\x47\x49\xd3\xff\xe2\x04\xba\x94\xc0\x0d\xa1\xcb\xc5\xb7\x8e\xd9\xc7\x19\xf7\xfc\xc1\x62\xba\x3e\x38\xb7\xff\x54\x21\xdd\x70\xd1\x6f\xd5\x98\x37\xbf\x36\xd9\xd7\x03\x9f\xc4\x9f\xf6\x9d\x8c\xa9\x4d\x83\xe5\x66\x09\xb6\xf3\x9f\x29\x4d\xed\x85\xd2\x57\xe2\xb2\x33\x34\xcb\x60\x4a\xe6\xdd\x4b\x1f\xaa\x69\x39\x81\x78\xa4\x2b\x71\xeb\xa5\x55\xf0\x66\xce\x35\xee\x8f\xc4\x47\x36\x6f\x56\xf5\x40\x67\x7f\xfa\x6b\x37\xe5\x0d\x2f\xbc\xeb\xa1\x51\xbc\x0b\x42\xbb\xe5\xd9\x09\xa9\x95\x72\xe3\x28\x6a\xb9\x4b\xe8\xe9\x26\x6f\x2e\xe8\x3f\xea\xdc\x9a\x40\xfc\x1b\xe5\x59\xf9\x33\xfc\x70\x2d\x71\x6e\x15\x47\x4d\x17\xa8\xd1\x1b\xbe\x19\xba\x7a\x70\x61\xcb\x87\xad\x6f\xff\xaa\x4f\xfb\xce\xdd\x63\x25\xa6\xfa\x9e\x48\xac\x1f\xd8\xae\xd3\xc8\xd4\x4b\x3f\x15\x5c\xe9\x31\xc4\xd5\x27\x7d\x81\x3e\x5e\x03\x87\xdc\x69\x30\x03\x12\x77\x7d\x46\xb1\xdb\x57\x62\xad\xf3\xef\x3f\xca\xb5\x4f\x25\x62\x38\xf1\xdd\x30\x5b\x9d\xc3\x3d\x82\xe0\x6c\x55\x7e\x1e\x64\x2f\x8d\x82\x63\x23\xf0\xbb\x63\xa6\x7c\xbb\x50\xbd\x31\x38\xe2\xeb\xb6\x8a\x46\xfc\x9f\x00\x00\x00\xff\xff\xa3\x19\x1f\x72\xb2\x29\x00\x00") func ResourcesComponentDescriptorOcmV3SchemaYamlBytes() ([]byte, error) { return bindataRead( @@ -94,7 +94,7 @@ func ResourcesComponentDescriptorOcmV3SchemaYaml() (*asset, error) { return nil, err } - info := bindataFileInfo{name: "../../../../../../../../resources/component-descriptor-ocm-v3-schema.yaml", size: 10607, mode: os.FileMode(436), modTime: time.Unix(1671551562, 0)} + info := bindataFileInfo{name: "../../../../../../../../resources/component-descriptor-ocm-v3-schema.yaml", size: 10674, mode: os.FileMode(436), modTime: time.Unix(1673540890, 0)} a := &asset{bytes: bytes, info: info} return a, nil } diff --git a/pkg/contexts/ocm/compdesc/versions/v2/componentdescriptor.go b/pkg/contexts/ocm/compdesc/versions/v2/componentdescriptor.go index d70da90b5..320903db9 100644 --- a/pkg/contexts/ocm/compdesc/versions/v2/componentdescriptor.go +++ b/pkg/contexts/ocm/compdesc/versions/v2/componentdescriptor.go @@ -67,6 +67,9 @@ type ObjectMeta struct { // describing the object. // +optional Labels metav1.Labels `json:"labels,omitempty"` + // CreationTime is the creation time of the component version + // +optional + CreationTime *metav1.Timestamp `json:"creationTime,omitempty"` } // GetName returns the name of the object. diff --git a/pkg/contexts/ocm/compdesc/versions/v2/jsonscheme/bindata.go b/pkg/contexts/ocm/compdesc/versions/v2/jsonscheme/bindata.go index cac6ef2dd..c538e36f6 100644 --- a/pkg/contexts/ocm/compdesc/versions/v2/jsonscheme/bindata.go +++ b/pkg/contexts/ocm/compdesc/versions/v2/jsonscheme/bindata.go @@ -79,7 +79,7 @@ func (fi bindataFileInfo) Sys() interface{} { return nil } -var _ResourcesComponentDescriptorV2SchemaYaml = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x1a\x6d\x6f\xdb\xb8\xf9\xbb\x7e\xc5\x83\x4b\x01\x39\x4d\x14\xb7\x1e\x3a\xe0\xfc\x25\xc8\x7a\xd8\x50\x6c\xbb\x0c\xed\x6d\x1f\x96\x7a\x05\x2d\x3d\xb6\xd9\x51\xa4\x47\x52\x6e\xd4\x5e\xff\xfb\x40\x52\xd4\xbb\x64\x3b\x4e\xdb\x3b\xa0\xf9\x12\x91\x7a\xde\xf9\xbc\x52\x7e\x42\x93\x39\x84\x1b\xad\xb7\x6a\x3e\x9d\xae\x89\x4c\x90\xa3\xbc\x8a\x99\xc8\x92\xa9\x8a\x37\x98\x12\x35\x8d\x45\xba\x15\x1c\xb9\x8e\x12\x54\xb1\xa4\x5b\x2d\x64\xb4\x9b\x85\xc1\x13\x07\x51\xa3\xf0\x5e\x09\x1e\xb9\xdd\x2b\x21\xd7\xd3\x44\x92\x95\x9e\xce\x9e\xcd\x9e\x45\xcf\x67\x05\xc1\x30\xf0\x64\xa8\xe0\x73\x08\xff\x52\x70\x85\x97\x9e\x0f\xfc\x54\xf2\x81\xdd\x0c\x2a\xb4\x15\xe5\xd4\x60\xa9\x79\x00\x90\xa2\x26\xe6\x3f\x80\xce\xb7\x38\x87\x50\x2c\xdf\x63\xac\x43\xbb\xd5\x64\x51\x6a\x00\x95\x06\x16\x3f\x21\x9a\x38\x04\x89\xff\xcb\xa8\xc4\xc4\x51\x04\x88\x20\x74\x7c\xff\x85\x52\x51\xc1\x1d\xd4\x56\x8a\x2d\x4a\x4d\x51\x79\xb8\x06\x90\xdf\x2c\x45\x52\x5a\x52\xbe\x0e\x83\x00\x80\x91\x25\xb2\x41\x79\x7b\xd8\x73\x92\x62\x58\x2d\x77\x84\x65\x38\x24\x85\x81\x1d\x64\xee\x36\x2d\xfe\x1c\x3e\x7d\xf6\xeb\xb6\xc8\x5b\xa2\x35\x4a\x63\xae\xff\xec\xee\x9e\x45\x3f\x2e\x2e\x9e\x78\x5c\x45\xd7\x9c\xe8\x4c\x76\x79\x2c\x85\x60\x48\xb8\xd5\xb0\xb4\xf2\xcf\xa5\x34\x3d\x92\xa4\xe4\xfe\x6f\xc8\xd7\x7a\x33\x87\xd9\x8b\x17\x41\x8b\xf3\x1d\x89\x3e\x2e\xee\x22\x12\x7d\x34\x12\x3c\x9d\xdc\x5d\x2d\x5a\x5b\xe7\x4f\xfd\xde\xa7\xd9\xe5\xe7\xc9\xb4\xf1\xfa\x5d\x0f\xca\x3b\x83\x73\x6e\x94\x09\x00\x68\x82\x5c\x53\x9d\xdf\x68\x2d\xe9\x32\xd3\xf8\x57\xcc\x9d\xa8\x29\xe5\xa5\x5c\x7d\x52\x19\xe6\x93\xbb\xe8\xdd\x85\x17\xc4\x6f\x9e\x5f\x3b\xd2\x12\x19\xb9\xc7\xe4\x0d\xa6\x3b\x94\x8e\xe6\x19\x68\xf2\x5f\xe4\xb0\x92\x22\x05\x65\x5f\x98\xb0\x00\xc2\x13\x20\xc9\xfb\x4c\x69\x4c\x40\x0b\x20\x8c\x89\x0f\x40\x38\x08\xeb\xb1\x84\x01\x43\x92\x50\xbe\x86\x70\x17\x5e\x42\x4a\xde\x0b\x19\x09\xce\xf2\x4b\x8b\x6a\xd7\x57\x29\xe5\xc5\xae\xe7\xb5\xa1\x0a\x52\x24\x5c\x81\xde\x20\xac\x84\xa1\x6a\x88\x38\xf3\x2b\x20\x12\x0d\x2b\xe3\x0a\x34\x69\xca\xab\xbc\xc0\xcf\xaf\x66\x57\x7f\xa8\x3f\x47\x2b\x21\x2e\x96\x44\x16\x7b\xbb\x3a\xc0\xae\x0f\xe2\xf9\xd5\xcc\x3f\x95\x60\x35\xf8\xf2\xb1\x81\x56\x37\xf6\x6e\x71\x3d\x79\xf6\xeb\xdd\xf3\xe8\xc7\xc5\xdb\xe4\xe9\xf9\xe4\x7a\xfe\xf6\xaa\xbe\x71\x7e\xdd\xbf\x15\x4d\x26\xd7\xf3\x6a\xf3\xd7\xb7\x89\x3d\xa3\x9b\xe8\xdf\xd1\xc2\x38\xb4\x7f\xf6\x24\x0f\x04\x3e\xf7\x1c\x2f\x26\xf5\x17\x17\x96\x48\x63\xc7\x42\x16\x41\xd3\x4d\x00\x1d\xd7\x1b\x4c\x06\x45\x7c\xe7\x26\x8e\xd4\x1c\x3e\xc1\x13\x89\xab\x39\x84\x67\xd3\x5a\x0a\x9c\xf6\xb9\x72\x08\x9f\x9d\x2b\x6e\x85\xa2\x5a\xc8\xfc\xa5\xe0\x1a\xef\xf5\x31\x79\xc7\x40\x0d\xe5\x19\x4b\x61\x24\xc9\x89\x98\xbe\xee\xe7\x4d\x18\xbb\x5d\x55\x5c\x7a\x35\xea\x88\x5d\xa5\xbf\xb6\x9c\x85\xac\x4b\xa2\xf0\x9f\x92\x85\x55\x12\xeb\x88\x6c\xfe\x0a\xb0\xfa\xd6\x40\x96\x34\x7f\x8d\x3c\xf6\x77\xb2\xdd\x52\xbe\x3e\x10\x15\x00\x79\x96\xce\xe1\x2e\xcc\x24\xfb\x07\xd1\x9b\xf0\x12\x42\xb5\x21\xb3\x17\x7f\x8c\x12\xba\x46\xa5\xc3\x45\xd0\xa2\x73\x2c\x65\x6b\xe3\x35\x55\x5a\xe6\x86\xfa\xed\xcb\x57\xe5\x72\x61\xce\x80\xc4\x31\x2a\x75\x60\x65\x34\x96\xb1\x50\xb0\x12\xb2\x40\x45\x05\x13\xb3\xc2\x7b\x8d\xdc\xd4\x08\x75\xbe\xc7\x59\x02\x80\x35\xd5\x9b\x6c\x79\x33\xce\x7b\xd4\xdb\xec\xd2\xb8\x40\xed\x40\xed\xce\xea\x41\xde\xd8\x36\x9b\x13\xb0\x34\x7f\xc1\x68\x0f\xba\xf1\xd2\x71\x88\x58\xa4\x29\xd5\x63\x31\xc1\x05\xc7\x53\xec\x72\xa2\xde\x3f\x0b\x8e\xce\x31\x94\xc8\x64\x8c\x3f\x95\x01\x77\x84\x38\xa6\xbf\x28\x17\x45\xe7\x50\xae\x0d\x85\x72\xe1\x5c\xe8\xe1\x6d\x0a\x1c\x91\xec\x0a\x14\xbc\xd7\x92\xbc\x2a\x00\xe6\x47\xd2\x09\x87\xda\xa1\x81\x0c\x55\xab\x99\xe1\xe1\xc7\x61\x9b\x3f\xd5\x01\x22\x52\x92\xbc\xd2\x9c\x6a\x4c\x1b\x79\xab\x57\x06\x4b\xcb\x23\xd5\x83\xdd\xae\x79\x7e\xbb\x6a\x26\xc9\x5e\x22\x0e\x2f\xdc\x0f\x58\x8f\xeb\x03\xc0\xcd\x20\xe0\x81\x03\x00\x97\xf3\xde\x6c\x31\x3e\xc2\xd9\x36\x44\x6d\x6e\xd8\x5a\x48\xaa\x37\x69\xe5\x82\x42\xa6\x84\x51\x45\x0c\xa3\xee\x6b\xdb\xde\x0e\xb8\x5d\x83\x60\xfb\x10\xdc\x41\x79\x07\xed\x65\x32\x8a\xe2\xfa\xea\x7e\x88\xa0\xd6\x3a\x1f\x69\x04\x32\xa2\xa1\x59\xa5\x98\x50\xf2\x8b\x8f\xbc\xae\xce\xe4\x64\xe1\xdd\x56\xc9\xa7\x82\x6a\x56\x90\x5f\x36\xe8\x80\x5c\x19\x11\x2b\xdb\x7c\x96\x6a\x43\x6d\x6e\x19\xb5\xcf\x43\xb3\x91\x73\xb1\x72\x59\xd2\x3b\x22\x05\x35\x14\x76\xf4\xf6\xe4\x81\xca\xaf\x47\x46\xa4\x5e\xcc\x86\x3f\xd8\x18\x51\x32\x7e\xed\xcb\xcc\xde\x7a\x4d\x4c\x49\x42\x89\x3c\x46\x3b\x38\xc0\xa4\x9a\xce\x99\x88\x09\x3b\x2f\xd2\xfc\x50\xed\xf0\x09\xf0\x0d\x32\x8c\xb5\x90\x0f\xcd\x97\x5f\x20\xa3\xd5\x47\xc8\xd7\x5e\xcb\x87\xda\xa5\xa4\x74\xe8\x7c\xdd\xe8\xfa\xea\x73\xf7\xf8\xfc\xdf\x33\xf4\x0e\xea\xd9\xcb\x62\xac\x26\xc2\x19\x90\x58\x67\x84\xb1\x7c\x5e\x71\x8a\x6c\xa0\x7d\x98\x82\xda\x62\x4c\x09\x03\x89\x06\x3e\xb6\x4c\x7e\xbf\x65\xf4\x8b\xd5\xc8\x76\x44\x0b\x8e\xed\x1a\x59\xf0\xe2\x19\x63\x07\x14\xb9\x7a\xf4\xdb\x69\xcb\x85\x5c\x95\x25\x8f\x6c\xbb\x3d\x01\x75\xf0\x5d\x50\xe1\x93\x70\x66\xf1\x6d\xe0\x57\x54\x2e\x8b\x9b\x80\x4c\x69\x48\x89\x8e\x37\xb5\x60\x50\x9d\xee\xad\xdb\x81\x33\x5b\xfd\x6a\x5b\xf5\x66\xe1\x7b\x53\x57\x6a\xe5\x12\xf7\x23\x79\xac\x23\x56\xcd\x1d\xee\x10\x0e\xee\xf2\xad\x0b\x98\x71\xd0\x0c\x6d\x92\x13\x56\x0e\x3a\xbf\xdf\xd6\x53\xc4\xf4\x4f\x4c\x1c\xde\x7b\x5a\x1b\xfc\x99\x32\x54\xb9\xd2\x98\x1e\x8f\x7b\xdb\xc7\xf0\x4b\x67\x0f\x11\xd3\x57\x29\x59\x9f\x34\x22\xda\x25\x35\x54\xca\xba\xf9\x28\xb3\x63\xfd\xaa\xc1\xfb\x53\x93\xcd\x9e\xcb\xa0\xca\x9c\x27\x28\xc6\x48\xee\xe3\xf2\x34\x7d\x20\x2c\x44\x0a\xa1\xba\x06\x58\x0d\x35\xb6\x37\x46\x81\x66\x5b\x61\x3a\xdb\x94\x70\xba\x42\xa5\xdb\x2d\x6d\x8b\xe9\x03\xfb\x66\x67\x19\x97\xc0\x5d\xa0\x38\x09\x14\x68\xb1\x87\x63\xdb\x51\xbb\xec\x1c\x84\x67\xa5\x89\x5c\xa3\xc6\x04\x62\xc1\x75\xd9\x28\x0d\x92\x57\xf4\xe3\xa8\x2e\xe6\x3d\x50\x0e\xcb\x5c\xa3\xf2\x3c\x96\xc6\xd8\x6d\xba\x3c\x4b\x97\xe6\x40\x03\x80\xc1\x90\x3d\xc1\x5d\x56\x94\x61\x55\x2f\x4f\xf5\x98\x1e\x09\x2b\xef\xf1\xac\x86\xec\xe2\xdf\xd7\xcd\x01\x7a\x43\x34\x50\x65\x75\x37\xe6\xa7\xdc\xbe\xfb\xc1\xbc\x54\x3f\x40\x42\xa5\x6d\xcc\xf3\xc1\xf3\xf0\x76\xbb\x7d\xa4\xf8\xfa\x02\x06\xbb\x6d\xc7\xd9\xb8\x73\x36\x1d\xd3\xc6\x3b\x7c\xa0\x7a\x53\x98\x26\xce\xa4\x44\xae\xa1\xef\x33\xde\x98\x95\x7c\x6a\x7d\x5d\x74\x46\xa7\x7c\x7d\xab\x4f\x01\x7d\x46\xfc\xde\x23\xed\xaf\x25\xf6\x30\xbe\x7e\x63\x32\xd4\x5c\xd4\xca\xee\xd7\x29\xf6\x01\x40\x75\x3f\x76\x42\xc0\x66\xfe\x82\xfc\xc4\xf2\x6e\x84\x29\x8f\x23\x1b\xb9\x0c\x0f\x00\xd6\xc8\x51\xd2\xf8\x1b\x5e\x64\x17\x12\xb8\xbb\xec\x62\xf1\x3d\xb2\x7f\x03\x91\x5d\x1d\x8c\xdb\xff\xb6\x81\xdd\x70\xd4\xaf\xd5\xc4\x97\x95\xe9\xe0\xeb\xaa\xa3\xef\xa7\xba\x7e\xda\xf9\x5c\xaa\x6a\x2f\xb7\x52\xec\x68\x52\x9d\x68\x04\x61\xe3\x92\xa1\x79\xe7\x55\xf6\xf3\xaa\x41\xbf\x81\xb1\xcf\xf7\x0f\xbf\xf2\x3a\xc1\x31\xbb\x3a\x1f\xed\x67\x9d\x39\x75\x6c\x00\xed\x7c\xcd\x0e\xe1\xcc\xf7\x23\x2c\xbf\x84\x0f\x08\x82\xb3\xbc\xf8\x05\x87\x6d\xdb\x05\xf7\x97\xd3\xfe\x0c\xbe\xd5\xc7\xa1\xe2\xf8\x1e\xe9\x82\xa2\xf5\xf5\xd0\xe3\xf7\xf8\xd0\xe3\x30\xec\x12\xae\x9c\xe0\xa1\x9a\x1d\x7e\xf6\xf5\x4b\xbd\xf0\x40\x67\x69\x34\x9b\x07\x21\xb5\xca\x98\xcd\x25\xfd\x26\x85\x4f\x9f\x83\x20\x68\x25\x96\x7a\xd6\x88\x20\x4c\xd1\xfd\x9a\xad\x1e\xd9\x61\xd0\x8c\xdb\xea\x57\x73\xbd\x02\x79\x12\xad\x84\x36\x7e\x40\x61\xfd\x3b\x4e\xb3\x39\xa8\x1d\x48\xe3\x30\xc6\xbf\x8d\x84\xff\x0f\x00\x00\xff\xff\xe8\xa1\xfb\x44\x98\x28\x00\x00") +var _ResourcesComponentDescriptorV2SchemaYaml = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\x1a\x5d\x6f\xdb\xba\xf5\x5d\xbf\xe2\xe0\xa6\x80\x9c\x26\x8a\x5b\x0f\x1d\x70\xfd\x12\x64\xbd\xd8\x50\x6c\xbb\x19\xda\x6e\x0f\x4b\xb3\x82\x96\x8e\x6d\x76\x14\xe9\x91\x94\x1b\xb5\xb7\xff\x7d\x20\x29\xea\x5b\xb2\x1d\x27\xed\x2d\xd0\xbc\x44\xa4\xce\x17\x0f\xcf\xb7\xfc\x84\x26\x73\x08\xd7\x5a\x6f\xd4\x7c\x3a\x5d\x11\x99\x20\x47\x79\x11\x33\x91\x25\x53\x15\xaf\x31\x25\x6a\x1a\x8b\x74\x23\x38\x72\x1d\x25\xa8\x62\x49\x37\x5a\xc8\x68\x3b\x0b\x83\x27\x0e\xa2\x46\xe1\x83\x12\x3c\x72\xbb\x17\x42\xae\xa6\x89\x24\x4b\x3d\x9d\x3d\x9b\x3d\x8b\x9e\xcf\x0a\x82\x61\xe0\xc9\x50\xc1\xe7\x10\xfe\xa5\xe0\x0a\x2f\x3d\x1f\xf8\xa5\xe4\x03\xdb\x19\x54\x68\x4b\xca\xa9\xc1\x52\xf3\x00\x20\x45\x4d\xcc\x7f\x00\x9d\x6f\x70\x0e\xa1\x58\x7c\xc0\x58\x87\x76\xab\xc9\xa2\x3c\x01\x54\x27\xb0\xf8\x09\xd1\xc4\x21\x48\xfc\x5f\x46\x25\x26\x8e\x22\x40\x04\xa1\xe3\xfb\x2f\x94\x8a\x0a\xee\xa0\x36\x52\x6c\x50\x6a\x8a\xca\xc3\x35\x80\xfc\x66\x29\x92\xd2\x92\xf2\x55\x18\x04\x00\x8c\x2c\x90\x0d\xca\xdb\xc3\x9e\x93\x14\xc3\x6a\xb9\x25\x2c\xc3\x21\x29\x0c\xec\x20\x73\xb7\x69\xf1\xe7\xf0\xf9\x8b\x5f\xb7\x45\xde\x10\xad\x51\x1a\x75\xfd\x67\x7b\xf3\x2c\xfa\xf9\xf6\xec\x89\xc7\x55\x74\xc5\x89\xce\x64\x97\xc7\x42\x08\x86\x84\xdb\x13\x96\x5a\xfe\xb5\x94\xa6\x47\x92\x94\xdc\xfd\x0d\xf9\x4a\xaf\xe7\x30\x7b\xf1\x22\x68\x71\xbe\x21\xd1\xa7\xdb\x9b\x88\x44\x9f\x8c\x04\x4f\x27\x37\x17\xb7\xad\xad\xd3\xa7\x7e\xef\xf3\xec\xfc\xcb\x64\xda\x78\xfd\xbe\x07\xe5\xbd\xc1\x39\x35\x87\x09\x00\x68\x82\x5c\x53\x9d\x5f\x69\x2d\xe9\x22\xd3\xf8\x57\xcc\x9d\xa8\x29\xe5\xa5\x5c\x7d\x52\x19\xe6\x93\x9b\xe8\xfd\x99\x17\xc4\x6f\x9e\x5e\x3a\xd2\x12\x19\xb9\xc3\xe4\x0d\xa6\x5b\x94\x8e\xe6\x09\x68\xf2\x5f\xe4\xb0\x94\x22\x05\x65\x5f\x18\xb7\x00\xc2\x13\x20\xc9\x87\x4c\x69\x4c\x40\x0b\x20\x8c\x89\x8f\x40\x38\x08\x6b\xb1\x84\x01\x43\x92\x50\xbe\x82\x70\x1b\x9e\x43\x4a\x3e\x08\x19\x09\xce\xf2\x73\x8b\x6a\xd7\x17\x29\xe5\xc5\xae\xe7\xb5\xa6\x0a\x52\x24\x5c\x81\x5e\x23\x2c\x85\xa1\x6a\x88\x38\xf5\x2b\x20\x12\x0d\x2b\x63\x0a\x34\x69\xca\xab\xbc\xc0\xcf\x2f\x66\x17\x7f\xa8\x3f\x47\x4b\x21\xce\x16\x44\x16\x7b\xdb\x3a\xc0\xb6\x0f\xe2\xf9\xc5\xcc\x3f\x95\x60\x35\xf8\xf2\xb1\x81\x56\x57\xf6\xf6\xf6\x72\xf2\xec\xb7\x9b\xe7\xd1\xcf\xb7\xef\x92\xa7\xa7\x93\xcb\xf9\xbb\x8b\xfa\xc6\xe9\x65\xff\x56\x34\x99\x5c\xce\xab\xcd\xdf\xde\x25\xf6\x8e\xae\xa2\x7f\x47\xb7\xc6\xa0\xfd\xb3\x27\xb9\x27\xf0\xa9\xe7\x78\x36\xa9\xbf\x38\xb3\x44\x1a\x3b\x16\xb2\x70\x9a\x6e\x00\xe8\x98\xde\x60\x30\x28\xfc\x3b\x37\x7e\xa4\xe6\xf0\x19\x9e\x48\x5c\xce\x21\x3c\x99\xd6\x42\xe0\xb4\xcf\x94\x43\xf8\xe2\x4c\x71\x23\x14\xd5\x42\xe6\x2f\x05\xd7\x78\xa7\x0f\x89\x3b\x06\x6a\x28\xce\x58\x0a\x23\x41\x4e\xc4\xf4\x75\x3f\x6f\xc2\xd8\xf5\xb2\xe2\xd2\x7b\xa2\x8e\xd8\x55\xf8\x6b\xcb\x59\xc8\xba\x20\x0a\xff\x29\x59\x58\x05\xb1\x8e\xc8\xe6\xaf\x00\xab\x6f\x0d\x44\x49\xf3\xd7\x88\x63\x7f\x27\x9b\x0d\xe5\xab\x3d\x51\x01\x90\x67\xe9\x1c\x6e\xc2\x4c\xb2\x7f\x10\xbd\x0e\xcf\x21\x54\x6b\x32\x7b\xf1\xc7\x28\xa1\x2b\x54\x3a\xbc\x0d\x5a\x74\x0e\xa5\x6c\x75\xbc\xa2\x4a\xcb\xdc\x50\xbf\x7e\xf9\xaa\x5c\xde\x9a\x3b\x20\x71\x8c\x4a\xed\x99\x19\x8d\x66\x2c\x14\x2c\x85\x2c\x50\x51\xc1\xc4\xac\xf0\x4e\x23\x37\x39\x42\x9d\xee\x30\x96\x00\x60\x45\xf5\x3a\x5b\x5c\x8d\xf3\x1e\xb5\x36\xbb\x34\x26\x50\xbb\x50\xbb\xb3\xbc\x97\x35\xb6\xd5\xe6\x04\x2c\xd5\x5f\x30\xda\x81\x6e\xac\x74\x1c\x22\x16\x69\x4a\xf5\x98\x4f\x70\xc1\xf1\x18\xbd\x1c\x79\xee\x5f\x05\x47\x67\x18\x4a\x64\x32\xc6\x5f\x4a\x87\x3b\x40\x1c\x53\x5f\x94\x8b\xa2\x72\x28\xd7\x86\x42\xb9\x70\x26\x74\xff\x32\x05\x0e\x08\x76\x05\x0a\xde\x69\x49\x5e\x15\x00\xf3\x03\xe9\x84\x43\xe5\xd0\x40\x84\xaa\xe5\xcc\x70\xff\xeb\xb0\xc5\x9f\xea\x00\x11\x29\x49\x5e\x9d\x9c\x6a\x4c\x1b\x71\xab\x57\x06\x4b\xcb\x23\xd5\x9d\xdd\xae\x79\x7e\xbd\x6c\x06\xc9\x5e\x22\x0e\x2f\xdc\x0d\x58\xf7\xeb\x3d\xc0\x4d\x23\xe0\x81\x03\x00\x17\xf3\xde\x6c\x30\x3e\xc0\xd8\xd6\x44\xad\xaf\xd8\x4a\x48\xaa\xd7\x69\x65\x82\x42\xa6\x84\x51\x45\x0c\xa3\xee\x6b\x5b\xde\x0e\x98\x5d\x83\x60\xfb\x12\xdc\x45\x79\x03\xed\x65\x32\x8a\xe2\xea\xea\x7e\x88\xa0\x56\x3a\x1f\xa8\x04\x32\x72\x42\xb3\x4a\x31\xa1\xe4\xad\xf7\xbc\xee\x99\xc9\xd1\xc2\xbb\xad\x92\x4f\x05\xd5\xcc\x20\x6f\xd7\xe8\x80\x5c\x1a\x11\x4b\x5b\x7c\x96\xc7\x86\x5a\xdf\x32\xaa\x9f\xfb\x46\x23\x67\x62\xe5\xb2\xa4\x77\x40\x08\x6a\x1c\xd8\xd1\xdb\x11\x07\x2a\xbb\x1e\x69\x91\x7a\x31\x1b\xf6\x60\x7d\x44\xc9\xf8\xb5\x4f\x33\x3b\xf3\x35\x31\x29\x09\x25\xf2\x18\x6d\xe3\x00\x93\xaa\x3b\x67\x22\x26\xec\xb4\x08\xf3\x43\xb9\xc3\x07\xc0\x37\xc8\x30\xd6\x42\xde\x37\x5e\x3e\x42\x44\xab\xb7\x90\xaf\xfd\x29\xef\xab\x97\x92\xd2\xbe\xfd\x75\xa3\xea\xab\xf7\xdd\xe3\xfd\x7f\x4f\xd3\x3b\x78\xce\x5e\x16\x63\x39\x11\x4e\x80\xc4\x3a\x23\x8c\xe5\xf3\x8a\x53\x64\x1d\xed\xe3\x14\xd4\x06\x63\x4a\x18\x48\x34\xf0\xb1\x65\xf2\xfd\xa6\xd1\x47\xcb\x91\x6d\x8f\x16\x1c\xdb\x39\xb2\xe0\xc5\x33\xc6\xf6\x48\x72\x75\xef\xb7\xdd\x96\x73\xb9\x2a\x4a\x1e\x58\x76\x7b\x02\x6a\xef\x59\x50\x61\x93\x70\x62\xf1\xad\xe3\x57\x54\xce\x8b\x49\x40\xa6\x34\xa4\x44\xc7\xeb\x9a\x33\xa8\x4e\xf5\xd6\xad\xc0\x99\xcd\x7e\xb5\xad\x7a\xb1\xf0\xa3\xa8\x2b\x4f\xe5\x02\xf7\x03\x59\xac\x23\x56\xf5\x1d\xee\x12\xf6\xae\xf2\xad\x09\x98\x76\xd0\x34\x6d\x92\x13\x56\x36\x3a\xdf\x6f\xe9\x29\x62\xfa\x27\x26\xf6\xaf\x3d\xad\x0e\xfe\x4c\x19\xaa\x5c\x69\x4c\x0f\xc7\xbd\xee\x63\xf8\xd8\xd1\x43\xc4\xf4\x55\x4a\x56\x47\xb5\x88\x76\x49\x0d\x95\x32\x6f\x3e\x48\xef\x58\x1f\x35\x78\x7b\x6a\xb2\xd9\x31\x0c\xaa\xd4\x79\xc4\xc1\x18\xc9\xbd\x5f\x1e\x77\x1e\x08\x0b\x91\x42\xa8\xc6\x00\xcb\xa1\xc2\xf6\xca\x1c\xa0\x59\x56\x98\xca\x36\x25\x9c\x2e\x51\xe9\x76\x49\xdb\x62\x7a\xcf\xba\xd9\x69\xc6\x05\x70\xe7\x28\x4e\x02\x05\x5a\xec\xe0\xd8\x36\xd4\x2e\x3b\x07\xe1\x59\x69\x22\x57\xa8\x31\x81\x58\x70\x5d\x16\x4a\x83\xe4\x15\xfd\x34\x7a\x16\xf3\x1e\x28\x87\x45\xae\x51\x79\x1e\x0b\xa3\xec\x36\x5d\x9e\xa5\x0b\x73\xa1\x01\xc0\xa0\xcb\x1e\x61\x2e\x4b\xca\xb0\xca\x97\xc7\x5a\x4c\x8f\x84\x95\xf5\x78\x56\x43\x7a\xf1\xef\xeb\xea\x00\xbd\x26\x1a\xa8\xb2\x67\x37\xea\xa7\xdc\xbe\xfb\xc9\xbc\x54\x3f\x41\x42\xa5\x2d\xcc\xf3\xc1\xfb\xf0\x7a\xbb\x7e\x20\xff\x7a\x04\x85\x5d\xb7\xfd\x6c\xdc\x38\x9b\x86\x69\xfd\x1d\x3e\x52\xbd\x2e\x54\x13\x67\x52\x22\xd7\xd0\xf7\x19\x6f\x4c\x4b\x3e\xb4\xbe\x2e\x2a\xa3\x63\xbe\xbe\xd5\xbb\x80\x3e\x25\xfe\xa8\x91\x76\xe7\x12\x7b\x19\x5f\xbf\x30\x19\x2a\x2e\x6a\x69\xf7\xeb\x24\xfb\x00\xa0\x9a\x8f\x1d\xe1\xb0\x99\x1f\x90\x1f\x99\xde\x8d\x30\xe5\x75\x64\x23\xc3\xf0\x00\x60\x85\x1c\x25\x8d\xbf\xe1\x20\xbb\x90\xc0\xcd\xb2\x8b\xc5\x0f\xcf\xfe\x1d\x78\x76\x75\x31\x6e\xff\xdb\x3a\x76\xc3\x50\xbf\x56\x11\x5f\x66\xa6\xbd\xc7\x55\x07\xcf\xa7\xba\x76\xda\xf9\x5c\xaa\x6a\x2f\x37\x52\x6c\x69\x52\xdd\x68\x04\x61\x63\xc8\xd0\x9c\x79\x95\xf5\xbc\x6a\xd0\x6f\x60\xec\xb2\xfd\xfd\x47\x5e\x47\x18\x66\x2c\xd1\x36\xc6\x6f\xe9\x8e\x31\x2e\xc0\x52\xc8\x94\xe8\x39\x24\x44\x63\xa4\x69\x39\x32\xee\xaa\xed\x60\x53\xed\xb4\xba\x63\x3d\x6c\xe7\x83\x78\x08\x27\xbe\xa4\x61\xf9\x39\x7c\x44\x10\x9c\xe5\xc5\x8f\x40\x6c\xe5\x2f\xb8\x17\xd6\x5f\xe3\xb7\xfa\xbe\x54\x58\xc0\x03\xcd\x38\x5a\x1f\x20\xcb\x4b\xed\x9a\xe1\xc3\x30\xec\x12\xae\x06\x2c\xf7\x3d\xd9\xfe\x77\x5f\x9f\x0b\x86\x7b\x1a\x4b\xa3\x5e\xdd\x0b\xa9\x95\x09\x6d\x38\xea\x57\x29\x7c\xfe\x12\x04\x41\x2b\x36\xd5\x03\x4f\x04\x61\x8a\xee\x07\x71\xf5\xe0\x10\x06\x4d\xd7\xaf\x7e\x78\xd7\x2b\x90\x27\xd1\x8a\x89\xe3\x17\x14\xd6\x3f\x05\x35\xeb\x8b\xda\x85\x34\x2e\x63\xfc\xf3\x4a\xf8\xff\x00\x00\x00\xff\xff\x19\x32\x06\xe9\xdb\x28\x00\x00") func ResourcesComponentDescriptorV2SchemaYamlBytes() ([]byte, error) { return bindataRead( @@ -94,7 +94,7 @@ func ResourcesComponentDescriptorV2SchemaYaml() (*asset, error) { return nil, err } - info := bindataFileInfo{name: "../../../../../../../resources/component-descriptor-v2-schema.yaml", size: 10392, mode: os.FileMode(436), modTime: time.Unix(1671551562, 0)} + info := bindataFileInfo{name: "../../../../../../../resources/component-descriptor-v2-schema.yaml", size: 10459, mode: os.FileMode(436), modTime: time.Unix(1673541992, 0)} a := &asset{bytes: bytes, info: info} return a, nil } diff --git a/pkg/contexts/ocm/compdesc/versions/v2/version.go b/pkg/contexts/ocm/compdesc/versions/v2/version.go index 77a5b727a..0ab2988dd 100644 --- a/pkg/contexts/ocm/compdesc/versions/v2/version.go +++ b/pkg/contexts/ocm/compdesc/versions/v2/version.go @@ -83,10 +83,11 @@ func (v *DescriptorVersion) ConvertTo(obj compdesc.ComponentDescriptorVersion) ( Metadata: compdesc.Metadata{ConfiguredVersion: in.Metadata.Version}, ComponentSpec: compdesc.ComponentSpec{ ObjectMeta: metav1.ObjectMeta{ - Name: in.Name, - Version: in.Version, - Labels: in.Labels.Copy(), - Provider: provider, + Name: in.Name, + Version: in.Version, + Labels: in.Labels.Copy(), + Provider: provider, + CreationTime: in.CreationTime, }, RepositoryContexts: in.RepositoryContexts.Copy(), Sources: convertSourcesTo(in.Sources), @@ -211,9 +212,10 @@ func (v *DescriptorVersion) ConvertFrom(in *compdesc.ComponentDescriptor) (compd }, ComponentSpec: ComponentSpec{ ObjectMeta: ObjectMeta{ - Name: in.Name, - Version: in.Version, - Labels: in.Labels.Copy(), + Name: in.Name, + Version: in.Version, + Labels: in.Labels.Copy(), + CreationTime: in.CreationTime, }, RepositoryContexts: in.RepositoryContexts.Copy(), Provider: provider, diff --git a/resources/component-descriptor-ocm-v3-schema.yaml b/resources/component-descriptor-ocm-v3-schema.yaml index 80c14caef..ae0fb81af 100644 --- a/resources/component-descriptor-ocm-v3-schema.yaml +++ b/resources/component-descriptor-ocm-v3-schema.yaml @@ -18,6 +18,9 @@ definitions: $ref: '#/definitions/labels' provider: $ref: '#/definitions/provider' + creationTime: + type: string + format: date-time labels: type: 'array' diff --git a/resources/component-descriptor-v2-schema.yaml b/resources/component-descriptor-v2-schema.yaml index de2481b14..b192c8f01 100644 --- a/resources/component-descriptor-v2-schema.yaml +++ b/resources/component-descriptor-v2-schema.yaml @@ -412,6 +412,9 @@ definitions: $ref: '#/definitions/componentName' version: $ref: '#/definitions/relaxedSemver' + creationTime: + type: string + format: date-time repositoryContexts: type: 'array' items: From c7b27a7149c8db4add8b4bee0d2f70c2afe37c34 Mon Sep 17 00:00:00 2001 From: Uwe Krueger Date: Mon, 16 Jan 2023 09:39:04 +0100 Subject: [PATCH 2/2] align json schema with spec --- cmds/ocm/commands/ocmcmds/common/resources.go | 4 ++-- docs/ocm/model.md | 1 + hack/Makefile | 4 ++++ resources/component-descriptor-ocm-v3-schema.yaml | 2 +- resources/component-descriptor-v2-schema.yaml | 4 ++-- 5 files changed, 10 insertions(+), 5 deletions(-) diff --git a/cmds/ocm/commands/ocmcmds/common/resources.go b/cmds/ocm/commands/ocmcmds/common/resources.go index ee84efc14..03bf361d2 100644 --- a/cmds/ocm/commands/ocmcmds/common/resources.go +++ b/cmds/ocm/commands/ocmcmds/common/resources.go @@ -8,13 +8,13 @@ import ( "encoding/json" "fmt" - _ "github.com/open-component-model/ocm/cmds/ocm/commands/ocmcmds/common/inputs/types" - "github.com/mandelsoft/vfs/pkg/vfs" "github.com/spf13/pflag" "golang.org/x/text/cases" "golang.org/x/text/language" + _ "github.com/open-component-model/ocm/cmds/ocm/commands/ocmcmds/common/inputs/types" + "github.com/open-component-model/ocm/cmds/ocm/commands/ocmcmds/common/addhdlrs" "github.com/open-component-model/ocm/cmds/ocm/commands/ocmcmds/common/inputs" "github.com/open-component-model/ocm/cmds/ocm/commands/ocmcmds/common/options/dryrunoption" diff --git a/docs/ocm/model.md b/docs/ocm/model.md index 612be9c47..d123a4df5 100644 --- a/docs/ocm/model.md +++ b/docs/ocm/model.md @@ -119,6 +119,7 @@ A component descriptor describes: - a history of [Repository Contexts](#repository-contexts) describing former repository locations of the component version along a transportation chain +- an optional creation timestamp (RFC3339) rounded to seconds. - a set of [Labels](#labels) to assign arbitrary kinds of information to the component version, which is not formally defined by the Open Component Model - an optional set of [Sources](#sources), that were used to generate the diff --git a/hack/Makefile b/hack/Makefile index a5cfe4ac9..d5c5df1cd 100644 --- a/hack/Makefile +++ b/hack/Makefile @@ -59,6 +59,10 @@ go-bindata: $(GOPATH)/bin/goimports: go install -v golang.org/x/tools/cmd/goimports@latest +Linux_jq: + $(info -> jq is missing) + $(info - sudo apt-get install jq / sudo dnf install jq / sudo zypper install jq / sudo pacman -S jq) + Darwin_sed: Darwin $(info -> GNU sed is missing) $(info - brew install gnu-sed) diff --git a/resources/component-descriptor-ocm-v3-schema.yaml b/resources/component-descriptor-ocm-v3-schema.yaml index ae0fb81af..a7a0f0659 100644 --- a/resources/component-descriptor-ocm-v3-schema.yaml +++ b/resources/component-descriptor-ocm-v3-schema.yaml @@ -37,7 +37,7 @@ definitions: value: {} version: pattern: '^v[0-9]+$' - signature: + signing: type: 'boolean' additionalProperties: false diff --git a/resources/component-descriptor-v2-schema.yaml b/resources/component-descriptor-v2-schema.yaml index b192c8f01..ce41afa14 100644 --- a/resources/component-descriptor-v2-schema.yaml +++ b/resources/component-descriptor-v2-schema.yaml @@ -1,6 +1,6 @@ $id: 'https://gardener.cloud/schemas/component-descriptor-v2' $schema: 'https://json-schema.org/draft/2020-12/schema' -description: 'Gardener Component Descriptor v2 schema' +description: 'Open Component Model v2 schema' definitions: meta: type: 'object' @@ -22,7 +22,7 @@ definitions: value: {} version: pattern: '^v[0-9]+$' - signature: + signing: type: 'boolean' componentName: