All Downloads are FREE. Search and download functionalities are using the official Maven repository.

ddingspudding.taodb.0.2.0.source-code.TaoDB.proto Maven / Gradle / Ivy

The newest version!
syntax = 'proto3';

option java_package = "com.github.puddingspudding.taodb";
option java_multiple_files = true;

import "google/protobuf/wrappers.proto";
import "google/protobuf/timestamp.proto";

message Event {
    EventId id = 1;
    bytes data = 2;
}

message EventId {
    bytes id = 1;
}

service EventStoreService {
    /* Adds new evnts. Returns event with event id */
    rpc add(Event) returns (Event);

    /* Returns all events since given event id */
    rpc getSinceId(EventId) returns (stream Event);

    /* Returns all events since given timestamp */
    rpc getSinceTimestamp(google.protobuf.Timestamp) returns (stream Event);

    /* Returns single event */
    rpc get(EventId) returns (Event);
}

/* The ReplicatedEventStoreService provides the same interface as EventStoreService
 * except for add() to ensure read-only access */
service ReplicatedEventStoreService {
    rpc getById(EventId) returns (stream Event);
    rpc getSinceId(EventId) returns (stream Event);
    rpc getSinceTimestamp(google.protobuf.Timestamp) returns (stream Event);
    rpc get(EventId) returns (Event);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy