Address review comments in the APIs.
This commit is contained in:
@@ -81,8 +81,9 @@ type VolumeSnapshotSpec struct {
|
||||
// +optional
|
||||
VolumeSnapshotClassName string `json:"snapshotClassName" protobuf:"bytes,3,opt,name=snapshotClassName"`
|
||||
|
||||
// Size represents the size of the VolumeSnapshot
|
||||
Size core_v1.ResourceList
|
||||
// A description of the volume snapshot's resources and size.
|
||||
// +optional
|
||||
Size core_v1.ResourceList `json:"size,omitempty" protobuf:"bytes,4,rep,name=size,casttype=ResourceList,castkey=ResourceName"`
|
||||
}
|
||||
|
||||
// VolumeSnapshotStatus is the status of the VolumeSnapshot
|
||||
@@ -201,7 +202,7 @@ type VolumeSnapshotContentSpec struct {
|
||||
// Name of the VolumeSnapshotClass used by the VolumeSnapshot. If not specified, a default snapshot class will
|
||||
// be used if it is available.
|
||||
// +optional
|
||||
VolumeSnapshotClassName string `json:"snapshotClassName" protobuf:"bytes,3,opt,name=snapshotClassName"`
|
||||
VolumeSnapshotClassName string `json:"snapshotClassName" protobuf:"bytes,4,opt,name=snapshotClassName"`
|
||||
}
|
||||
|
||||
// VolumeSnapshotSource represents the actual location and type of the snapshot. Only one of its members may be specified.
|
||||
@@ -214,22 +215,26 @@ type VolumeSnapshotSource struct {
|
||||
// Represents the source from CSI volume snapshot
|
||||
type CSIVolumeSnapshotSource struct {
|
||||
// Driver is the name of the driver to use for this snapshot.
|
||||
// This MUST be the same name returned by the CSI GetPluginName() call for
|
||||
// that driver.
|
||||
// Required.
|
||||
Driver string `json:"driver"`
|
||||
Driver string `json:"driver" protobuf:"bytes,1,opt,name=driver"`
|
||||
|
||||
// SnapshotHandle is the unique snapshot id returned by the CSI volume
|
||||
// plugin’s CreateSnapshot to refer to the snapshot on all subsequent calls.
|
||||
// Required.
|
||||
SnapshotHandle string `json:"snapshotHandle"`
|
||||
SnapshotHandle string `json:"snapshotHandle" protobuf:"bytes,2,opt,name=snapshotHandle"`
|
||||
|
||||
// Timestamp when the point-in-time snapshot is taken on the storage
|
||||
// system. This timestamp will be generated by the CSI volume driver after
|
||||
// the snapshot is cut. The format of this field should be a Unix nanoseconds
|
||||
// time encoded as an int64. On Unix, the command `date +%s%N` returns
|
||||
// the current time in nanoseconds since 1970-01-01 00:00:00 UTC.
|
||||
// This field is REQUIRED.
|
||||
// This field is required in the CSI spec but optional here to support static binding.
|
||||
// +optional
|
||||
CreatedAt int64 `json:"createdAt,omitempty" protobuf:"varint,3,opt,name=createdAt"`
|
||||
|
||||
// Size represents the size of the VolumeSnapshot
|
||||
Size core_v1.ResourceList
|
||||
// A description of the volume snapshot's resources and size.
|
||||
// +optional
|
||||
Size core_v1.ResourceList `json:"size,omitempty" protobuf:"bytes,4,rep,name=size,casttype=ResourceList,castkey=ResourceName"`
|
||||
}
|
||||
|
Reference in New Issue
Block a user