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

-iot.sdk-algorithm-starter.4.1.17.source-code.algorithm.proto Maven / Gradle / Ivy

There is a newer version: 4.1.19
Show newest version
// Copyright 2015 The gRPC Authors
// protoc -I . --go_out=plugins=grpc:. ./algorithm.proto


// protoc -I ./ --go_out=. ./algorithm/algorithm.proto
// protoc -I ./ --go-grpc_out=. algorithm/algorithm.proto

// kratos proto server ./grpc/algorithm/algorithm.proto -t grpc/algorithm

syntax = "proto3";

package algorithm;

import "api.proto";

option go_package = "./algorithm;algorithm";
option java_package = "io.github.airiot.sdk.algorithm.grpc.algorithm";
option java_multiple_files = true;
option java_generate_equals_and_hash = true;
option java_generic_services = false;

service AlgorithmService {
  rpc HealthCheck (HealthCheckRequest) returns (HealthCheckResponse) {}
  rpc SchemaStream (stream SchemaResult) returns (stream SchemaRequest) {}
  rpc RunStream (stream RunResult) returns (stream RunRequest) {}

  rpc Run (ClientRunByIdRequest) returns (api.Response) {}
}

message HealthCheckRequest {
  string service = 1;
}

message HealthCheckResponse {
  enum ServingStatus {
    UNKNOWN = 0;
    SERVING = 1;
    NOT_SERVING = 2;
    SERVICE_UNKNOWN = 3;  // Used only by the Watch method.
  }
  ServingStatus status = 1;
  repeated Error errors = 2;
}

message Error {
  enum ErrorCode {
    Schema = 0;
    Start = 1;
    Run = 2;
    Write = 3;  // Used only by the Watch method.
    BatchRun = 4;  // Used only by the Watch method.
    Debug = 5;  // Used only by the Watch method.
    Health = 6;
  }
  ErrorCode code = 1;
  string message = 2;
}

message SchemaRequest {
  string request = 1;
}

message SchemaResult {
  string request = 1;
  bytes message = 2;
}

message RunRequest {
  string request = 1;
  bytes data = 2;
}

message RunResult {
  string request = 1;
  bytes message = 2;
}

message ClientRunByIdRequest {
  string id = 1;
  bytes data = 2;
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy