syntax = "proto3";

package dunedaq.ersschema;

message Context {
  string cwd = 1;
  string file_name = 2;
  string function_name = 3;
  string host_name = 4;
  uint32 line_number = 5;
  string package_name = 6;

  uint32 process_id = 11;
  uint32 thread_id = 12;
  uint32 user_id = 13;
  string user_name = 14;
  string application_name = 15;
}

message SimpleIssue {
  Context context = 1;

  string name = 2;
  repeated string inheritance = 3;
  string message = 4;
  string severity = 5;
  uint64 time = 6;
  map<string, string> parameters = 7;
}

message IssueChain {
  SimpleIssue final = 1;
  repeated SimpleIssue causes = 2;

  string session = 10;
  string application = 11;
  string module = 12;
}