Skip to content

Commit

Permalink
Proto updates (#68)
Browse files Browse the repository at this point in the history
* Proto updates for future workflows

Co-authored-by: o.omahony <[email protected]>
  • Loading branch information
2 people authored and m.gougam committed Oct 11, 2022
1 parent caa7a71 commit 24aa7dc
Show file tree
Hide file tree
Showing 15 changed files with 2,325 additions and 345 deletions.
2 changes: 1 addition & 1 deletion sdk/proto/agent.proto
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ message AgentConnectRequest {
reserved 1;
reserved "identity";
AgentMeta meta = 2 [(gogoproto.jsontag) = "meta"];
repeated NginxDetails details = 3 [(gogoproto.jsontag) = "details"];
repeated NginxDetails details = 3 [(gogoproto.jsontag) = "details"]; // moving to dataplane_software_details
HostInfo host = 4 [(gogoproto.jsontag) = "host"];
repeated DataplaneSoftwareDetails dataplane_software_details = 5 [(gogoproto.jsontag) = "dataplane_software_details"];
}
Expand Down
860 changes: 754 additions & 106 deletions sdk/proto/command.pb.go

Large diffs are not rendered by default.

19 changes: 16 additions & 3 deletions sdk/proto/command.proto
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import "nginx.proto";
import "config.proto";
import "events/event.proto";
import "dp_software_details.proto";

import "nap.proto";

// Command is the envelope sent between the management plane and the data plane, requesting some action or reporting a response
message Command {
Expand Down Expand Up @@ -82,10 +82,23 @@ message CommandStatusResponse {
// DataplaneStatus reports Dataplane metrics the Agent is aware of
message DataplaneStatus {
string system_id = 1 [(gogoproto.jsontag) = "system_id" ];
repeated NginxDetails details = 2 [(gogoproto.jsontag) = "details" ];
repeated NginxDetails details = 2 [(gogoproto.jsontag) = "details" ]; // moving to dataplane_software_details
HostInfo host = 3 [(gogoproto.jsontag) = "host" ];
repeated NginxHealth healths = 5 [(gogoproto.jsontag) = "healths" ];
repeated NginxHealth healths = 5 [(gogoproto.jsontag) = "healths" ]; // moving to DataplaneSoftwareHealth
repeated DataplaneSoftwareDetails dataplane_software_details = 6 [(gogoproto.jsontag) = "dataplane_software_details"];
repeated DataplaneSoftwareHealth dataplane_software_healths = 7 [(gogoproto.jsontag) = "dataplane_software_healths"];
}

message DataplaneSoftwareHealth {
oneof health {
NginxHealth nginx_health = 1 [(gogoproto.jsontag) = "nginx_health"];
AppProtectWAFHealth app_protect_waf_health = 2 [(gogoproto.jsontag) = "app_protect_waf_health"];
}
}

message DataplaneUpdate {
HostInfo host = 1 [(gogoproto.jsontag) = "host"];
repeated DataplaneSoftwareDetails dataplane_software_details = 2 [(gogoproto.jsontag) = "dataplane_software_details"];
}

message DownloadRequest {
Expand Down
1 change: 0 additions & 1 deletion sdk/proto/dp_software_details.proto
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,4 @@ message DataplaneSoftwareDetails {
oneof data {
AppProtectWAFDetails app_protect_waf_details = 1 [(gogoproto.jsontag) = "app_protect_waf_details"];
}

}
8 changes: 4 additions & 4 deletions sdk/proto/nap.proto
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import "gogo.proto";
// AppProtectWAFDetails reports the details of Nginx App Protect
message AppProtectWAFDetails {
string waf_version = 1 [(gogoproto.jsontag) = "waf_version"];
string attack_signatures_version = 2 [(gogoproto.jsontag) = "attack_signatures_version"];
string threat_campaigns_version = 3 [(gogoproto.jsontag) = "threat_campaigns_version"];
AppProtectWAFHealth health = 4 [(gogoproto.jsontag) = "health"];
string attack_signatures_version = 2 [(gogoproto.jsontag) = "attack_signatures_version"]; // deprecating
string threat_campaigns_version = 3 [(gogoproto.jsontag) = "threat_campaigns_version"]; // deprecating
AppProtectWAFHealth health = 4 [(gogoproto.jsontag) = "health"]; // deprecating
}

// AppProtectWAFHealth reports the health details of Nginx App Protect
Expand All @@ -22,4 +22,4 @@ message AppProtectWAFHealth {
string system_id = 1 [(gogoproto.jsontag) = "system_id"];
AppProtectWAFStatus app_protect_waf_status = 2 [(gogoproto.jsontag) = "app_protect_waf_status"];
string degraded_reason = 3 [(gogoproto.jsontag) = "degraded_reason"];
}
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Large diffs are not rendered by default.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 24aa7dc

Please sign in to comment.