config_change.proto 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. // Copyright 2023 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.api;
  16. option go_package = "google.golang.org/genproto/googleapis/api/configchange;configchange";
  17. option java_multiple_files = true;
  18. option java_outer_classname = "ConfigChangeProto";
  19. option java_package = "com.google.api";
  20. option objc_class_prefix = "GAPI";
  21. // Output generated from semantically comparing two versions of a service
  22. // configuration.
  23. //
  24. // Includes detailed information about a field that have changed with
  25. // applicable advice about potential consequences for the change, such as
  26. // backwards-incompatibility.
  27. message ConfigChange {
  28. // Object hierarchy path to the change, with levels separated by a '.'
  29. // character. For repeated fields, an applicable unique identifier field is
  30. // used for the index (usually selector, name, or id). For maps, the term
  31. // 'key' is used. If the field has no unique identifier, the numeric index
  32. // is used.
  33. // Examples:
  34. // - visibility.rules[selector=="google.LibraryService.ListBooks"].restriction
  35. // - quota.metric_rules[selector=="google"].metric_costs[key=="reads"].value
  36. // - logging.producer_destinations[0]
  37. string element = 1;
  38. // Value of the changed object in the old Service configuration,
  39. // in JSON format. This field will not be populated if ChangeType == ADDED.
  40. string old_value = 2;
  41. // Value of the changed object in the new Service configuration,
  42. // in JSON format. This field will not be populated if ChangeType == REMOVED.
  43. string new_value = 3;
  44. // The type for this change, either ADDED, REMOVED, or MODIFIED.
  45. ChangeType change_type = 4;
  46. // Collection of advice provided for this change, useful for determining the
  47. // possible impact of this change.
  48. repeated Advice advices = 5;
  49. }
  50. // Generated advice about this change, used for providing more
  51. // information about how a change will affect the existing service.
  52. message Advice {
  53. // Useful description for why this advice was applied and what actions should
  54. // be taken to mitigate any implied risks.
  55. string description = 2;
  56. }
  57. // Classifies set of possible modifications to an object in the service
  58. // configuration.
  59. enum ChangeType {
  60. // No value was provided.
  61. CHANGE_TYPE_UNSPECIFIED = 0;
  62. // The changed object exists in the 'new' service configuration, but not
  63. // in the 'old' service configuration.
  64. ADDED = 1;
  65. // The changed object exists in the 'old' service configuration, but not
  66. // in the 'new' service configuration.
  67. REMOVED = 2;
  68. // The changed object exists in both service configurations, but its value
  69. // is different.
  70. MODIFIED = 3;
  71. }