Commit 5b733d5c authored by Daniel Eggert's avatar Daniel Eggert
Browse files

added grpc/protobuf description of indexmediator

parent 4ff087c2
......@@ -10,6 +10,9 @@
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<protobuf.version>3.4.0</protobuf.version>
<grpc.version>1.6.1</grpc.version>
</properties>
<build>
......@@ -22,6 +25,60 @@
</includes>
</resource>
</resources>
<plugins>
<plugin>
<groupId>com.github.os72</groupId>
<artifactId>protoc-jar-maven-plugin</artifactId>
<version>3.4.0</version>
<executions>
<execution>
<phase>generate-sources</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<protocVersion>${protobuf.version}</protocVersion>
<includeStdTypes>true</includeStdTypes>
<outputTargets>
<outputTarget>
<type>java</type>
</outputTarget>
<outputTarget>
<type>grpc-java</type>
<pluginArtifact>io.grpc:protoc-gen-grpc-java:${grpc.version}</pluginArtifact>
</outputTarget>
</outputTargets>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
<version>3.4.0</version>
</dependency>
<!-- grpc dependencies -->
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-netty</artifactId>
<version>${grpc.version}</version>
</dependency>
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-protobuf</artifactId>
<version>${grpc.version}</version>
</dependency>
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-stub</artifactId>
<version>${grpc.version}</version>
</dependency>
</dependencies>
</project>
\ No newline at end of file
syntax="proto3";
package de.potsdam.gfz.gms.shared.indexmediator;
import "google/protobuf/timestamp.proto";
import "google/protobuf/empty.proto";
// gms controller service definition
service GmsIndexMediatorServer {
// Executes the remote call in order to check whether the connection is still alive. In case the connection is broken an exception is thrown.
rpc CheckConnection (google.protobuf.Empty) returns (google.protobuf.Empty);
// Returns the version string of the running module
rpc GetVersion(google.protobuf.Empty) returns (Text);
// Returns a combined version and build-timestamp string of the runningn module
rpc GetVersionInfo(google.protobuf.Empty) returns (Text);
// e, start, end, seasoncode, minCloudcover, maxCloudcover, datasetid, minProclevel, maxProclevel
rpc GetScenesForDataset(SceneSearchRequest) returns (SceneSearchResponse);
}
message Envelope {
Coordinate min = 1;
Coordinate max = 2;
}
message SceneSearchRequest {
Envelope envelope = 1;
google.protobuf.Timestamp start = 2;
google.protobuf.Timestamp end = 3;
int32 seasonCode = 4;
int32 minCloudcover = 5;
int32 maxCloudcover = 6;
int32 datasetid = 7;
int32 minProclevel = 8;
int32 maxProclevel = 9;
}
message SceneSearchResponse {
SceneSearchRequest request = 1;
repeated SceneMetaData result = 2;
}
message Coordinate {
double x = 1;
double y = 2;
}
message SceneMetaData {
int64 id = 1;
google.protobuf.Timestamp acquisitionDate = 2;
int32 cloudcover = 3;
int32 proclevel = 4;
repeated Coordinate bounds = 5;
}
message Text {
string text = 1;
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment