Skip to content

Instantly share code, notes, and snippets.

@ruan65
Last active May 1, 2024 12:49
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save ruan65/f67888eb4c371b9f99b159037345c2ed to your computer and use it in GitHub Desktop.
Save ruan65/f67888eb4c371b9f99b159037345c2ed to your computer and use it in GitHub Desktop.
syntax="proto3";
message Student {
int32 id = 1;
string name = 2;
}
message Question {
int32 id = 1;
string text = 2;
}
message Answer {
int32 id = 1;
Student student = 2;
Question question = 3;
string text = 4;
}
message Evaluation {
int32 id = 1;
int32 answerId = 2;
int32 mark = 3;
}
service Umka {
rpc getQuestion(Student) returns(Question) {}
rpc sendAnswer(Answer) returns(Evaluation) {}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment