summaryrefslogtreecommitdiff
path: root/sources/listing_schema.tex
blob: ef380e8f3838757c6c3cc8e5009c0863f8c1e378 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
\begin{lstlisting}[caption=The Redis and PostgreSQL schema (\texttt{schema.proto} file). All the large volume data packets that travel within the system follow this format (\ie \myCircled{1} through \myCircled{6}). The communication of small datapackets takes place using the HTTP protocol., label={lst:protobuf-schema}]
syntax = "proto3";

package proto;

option java_package = "org.opendc.common";
option java_outer_classname = "ProtobufMetrics";

message ProtoExport {
  string timestamp = 1;
  string host_id = 2;
  int32 tasksactive = 3;
  double cpuutilization = 4;
  double energyusage = 5;
  double uptime = 6;
  double downtime = 7;
}\end{lstlisting}