-
-
Notifications
You must be signed in to change notification settings - Fork 57
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #162 from nitrictech/feature/grpc-errors
feat: add grpc errors
- Loading branch information
Showing
29 changed files
with
485 additions
and
215 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
syntax = "proto3"; | ||
package nitric.error.v1; | ||
|
||
// protoc plugin options for code generation | ||
option go_package = "nitric/v1;v1"; | ||
option java_package = "io.nitric.proto.error.v1"; | ||
option java_multiple_files = true; | ||
option java_outer_classname = "Errors"; | ||
option php_namespace = "Nitric\\Proto\\Error\\V1"; | ||
option csharp_namespace = "Nitric.Proto.Error.v1"; | ||
|
||
message ErrorScope { | ||
// The API service invoked, e.g. 'Service.Method'. | ||
string service = 1; | ||
|
||
// The plugin method invoked, e.g. 'PluginService.Method'. | ||
string plugin = 2; | ||
|
||
// The plugin method arguments, ensure only non-sensitive data is specified. | ||
map<string, string> args = 3; | ||
} | ||
|
||
message ErrorDetails { | ||
// The developer error message, explaining the error and ideally solution. | ||
string message = 1; | ||
|
||
// The error root cause. | ||
string cause = 2; | ||
|
||
// The scope of the error. | ||
ErrorScope scope = 3; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.