storagecachedimage.go 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. // Copyright 2019 Yunion
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. package compute
  15. import (
  16. "yunion.io/x/onecloud/pkg/apis"
  17. )
  18. type StoragecachedimageDetails struct {
  19. SStoragecachedimage
  20. apis.JointResourceBaseDetails
  21. StoragecacheResourceInfo
  22. // 缓存镜像名称
  23. Cachedimage string `json:"cachedimage"`
  24. // 存储列表
  25. // Storages []string `json:"storages"`
  26. // 通过一致性哈希获取的一个宿主机详情
  27. // Host *jsonutils.JSONDict `json:"host"`
  28. // 镜像名称
  29. Image string `json:"image"`
  30. // 镜像大小
  31. Size int64 `json:"size"`
  32. // 引用次数
  33. Reference int `json:"reference"`
  34. // Disk引用次数
  35. DiskReference int `json:"disk_reference"`
  36. // Cdrom引用次数
  37. CdromReference int `json:"cdrom_reference"`
  38. }
  39. type StoragecachedimageListInput struct {
  40. apis.JointResourceBaseListInput
  41. apis.ExternalizedResourceBaseListInput
  42. StoragecacheFilterListInput
  43. // 以镜像缓存过滤
  44. CachedimageId string `json:"cachedimage_id"`
  45. // Deprecated
  46. // swagger:ignore
  47. Cachedimage string `json:"cachedimage" yunion-deprecated-by:"cachedimage_id"`
  48. // 镜像状态
  49. Status []string `json:"status"`
  50. }