action_log.proto 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. // Copyright 2020 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.recommender.logging.v1beta1;
  16. import "google/api/field_behavior.proto";
  17. import "google/cloud/recommender/v1beta1/insight.proto";
  18. import "google/cloud/recommender/v1beta1/recommendation.proto";
  19. option go_package = "google.golang.org/genproto/googleapis/cloud/recommender/logging/v1beta1;logging";
  20. option java_multiple_files = true;
  21. option java_outer_classname = "ActionLogProto";
  22. option java_package = "com.google.cloud.recommender.logging.v1beta1";
  23. // Log content of an action on a recommendation. This includes Mark* actions.
  24. message ActionLog {
  25. // Required. User that executed this action. Eg, foo@gmail.com
  26. string actor = 1;
  27. // Required. State change that was made by the actor. Eg, SUCCEEDED.
  28. google.cloud.recommender.v1beta1.RecommendationStateInfo.State state = 2;
  29. // Optional. Metadata that was included with the action that was taken.
  30. map<string, string> state_metadata = 3;
  31. // Required. Name of the recommendation which was acted on. Eg, :
  32. // 'projects/foo/locations/global/recommenders/roleReco/recommendations/r1'
  33. string recommendation_name = 4;
  34. }
  35. // Log content of an action on an insight. This includes Mark* actions.
  36. message InsightActionLog {
  37. // Required. User that executed this action. Eg, foo@gmail.com
  38. string actor = 1 [(google.api.field_behavior) = REQUIRED];
  39. // Required. State change that was made by the actor. Eg, ACCEPTED.
  40. google.cloud.recommender.v1beta1.InsightStateInfo.State state = 2 [(google.api.field_behavior) = REQUIRED];
  41. // Optional. Metadata that was included with the action that was taken.
  42. map<string, string> state_metadata = 3 [(google.api.field_behavior) = OPTIONAL];
  43. // Required. Name of the insight which was acted on. Eg, :
  44. // 'projects/foo/locations/global/insightTypes/roleInsight/insights/i1'
  45. string insight = 4 [(google.api.field_behavior) = REQUIRED];
  46. }