lun.proto 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149
  1. // Copyright 2022 Google LLC
  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. syntax = "proto3";
  15. package google.cloud.baremetalsolution.v2;
  16. import "google/api/field_behavior.proto";
  17. import "google/api/resource.proto";
  18. option csharp_namespace = "Google.Cloud.BareMetalSolution.V2";
  19. option go_package = "google.golang.org/genproto/googleapis/cloud/baremetalsolution/v2;baremetalsolution";
  20. option java_multiple_files = true;
  21. option java_outer_classname = "LunProto";
  22. option java_package = "com.google.cloud.baremetalsolution.v2";
  23. option php_namespace = "Google\\Cloud\\BareMetalSolution\\V2";
  24. option ruby_package = "Google::Cloud::BareMetalSolution::V2";
  25. // A storage volume logical unit number (LUN).
  26. message Lun {
  27. option (google.api.resource) = {
  28. type: "baremetalsolution.googleapis.com/Lun"
  29. pattern: "projects/{project}/locations/{location}/volumes/{volume}/luns/{lun}"
  30. };
  31. // The possible states for the LUN.
  32. enum State {
  33. // The LUN is in an unknown state.
  34. STATE_UNSPECIFIED = 0;
  35. // The LUN is being created.
  36. CREATING = 1;
  37. // The LUN is being updated.
  38. UPDATING = 2;
  39. // The LUN is ready for use.
  40. READY = 3;
  41. // The LUN has been requested to be deleted.
  42. DELETING = 4;
  43. }
  44. // Display the operating systems present for the LUN multiprotocol type.
  45. enum MultiprotocolType {
  46. // Server has no OS specified.
  47. MULTIPROTOCOL_TYPE_UNSPECIFIED = 0;
  48. // Server with Linux OS.
  49. LINUX = 1;
  50. }
  51. // The storage types for a LUN.
  52. enum StorageType {
  53. // The storage type for this LUN is unknown.
  54. STORAGE_TYPE_UNSPECIFIED = 0;
  55. // This storage type for this LUN is SSD.
  56. SSD = 1;
  57. // This storage type for this LUN is HDD.
  58. HDD = 2;
  59. }
  60. // Output only. The name of the LUN.
  61. string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
  62. // An identifier for the LUN, generated by the backend.
  63. string id = 10;
  64. // The state of this storage volume.
  65. State state = 2;
  66. // The size of this LUN, in gigabytes.
  67. int64 size_gb = 3;
  68. // The LUN multiprotocol type ensures the characteristics of the LUN are
  69. // optimized for each operating system.
  70. MultiprotocolType multiprotocol_type = 4;
  71. // Display the storage volume for this LUN.
  72. string storage_volume = 5 [(google.api.resource_reference) = {
  73. type: "baremetalsolution.googleapis.com/Volume"
  74. }];
  75. // Display if this LUN can be shared between multiple physical servers.
  76. bool shareable = 6;
  77. // Display if this LUN is a boot LUN.
  78. bool boot_lun = 7;
  79. // The storage type for this LUN.
  80. StorageType storage_type = 8;
  81. // The WWID for this LUN.
  82. string wwid = 9;
  83. }
  84. // Message for requesting storage lun information.
  85. message GetLunRequest {
  86. // Required. Name of the resource.
  87. string name = 1 [
  88. (google.api.field_behavior) = REQUIRED,
  89. (google.api.resource_reference) = {
  90. type: "baremetalsolution.googleapis.com/Lun"
  91. }
  92. ];
  93. }
  94. // Message for requesting a list of storage volume luns.
  95. message ListLunsRequest {
  96. // Required. Parent value for ListLunsRequest.
  97. string parent = 1 [
  98. (google.api.field_behavior) = REQUIRED,
  99. (google.api.resource_reference) = {
  100. type: "baremetalsolution.googleapis.com/Volume"
  101. }
  102. ];
  103. // Requested page size. The server might return fewer items than requested.
  104. // If unspecified, server will pick an appropriate default.
  105. int32 page_size = 2;
  106. // A token identifying a page of results from the server.
  107. string page_token = 3;
  108. }
  109. // Response message containing the list of storage volume luns.
  110. message ListLunsResponse {
  111. // The list of luns.
  112. repeated Lun luns = 1;
  113. // A token identifying a page of results from the server.
  114. string next_page_token = 2;
  115. // Locations that could not be reached.
  116. repeated string unreachable = 3;
  117. }