• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1/* Copyright 2016 The TensorFlow Authors. All Rights Reserved.
2
3Licensed under the Apache License, Version 2.0 (the "License");
4you may not use this file except in compliance with the License.
5You may obtain a copy of the License at
6
7    http://www.apache.org/licenses/LICENSE-2.0
8
9Unless required by applicable law or agreed to in writing, software
10distributed under the License is distributed on an "AS IS" BASIS,
11WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12See the License for the specific language governing permissions and
13limitations under the License.
14==============================================================================*/
15
16syntax = "proto3";
17
18package tensorflow.grpc;
19option java_outer_classname = "WorkerServiceProtos";
20option java_multiple_files = true;
21option java_package = "org.tensorflow.distruntime";
22option go_package = "github.com/tensorflow/tensorflow/tensorflow/go/core/protobuf";
23import "tensorflow/core/protobuf/worker.proto";
24
25////////////////////////////////////////////////////////////////////////////////
26//
27// WorkerService defines a TensorFlow service that executes dataflow
28// graphs on a set of local devices, on behalf of a MasterService.
29//
30// A worker service keeps track of multiple "registered graphs". Each
31// registered graph is a subgraph of a client's graph, corresponding to
32// only the nodes that should execute on this worker (and any
33// additional nodes necessary for inter-process communication using
34// the `RecvTensor` method).
35//
36////////////////////////////////////////////////////////////////////////////////
37
38service WorkerService {
39  // See worker.proto for details.
40  rpc GetStatus(GetStatusRequest) returns (GetStatusResponse);
41
42  // See worker.proto for details.
43  rpc CreateWorkerSession(CreateWorkerSessionRequest)
44      returns (CreateWorkerSessionResponse);
45
46  // See worker.proto for details.
47  rpc DeleteWorkerSession(DeleteWorkerSessionRequest)
48      returns (DeleteWorkerSessionResponse);
49
50  // See worker.proto for details.
51  rpc RegisterGraph(RegisterGraphRequest) returns (RegisterGraphResponse);
52
53  // See worker.proto for details.
54  rpc DeregisterGraph(DeregisterGraphRequest) returns (DeregisterGraphResponse);
55
56  // See worker.proto for details.
57  rpc RunGraph(RunGraphRequest) returns (RunGraphResponse);
58
59  // See worker.proto for details.
60  rpc CleanupGraph(CleanupGraphRequest) returns (CleanupGraphResponse);
61
62  // See worker.proto for details.
63  rpc CleanupAll(CleanupAllRequest) returns (CleanupAllResponse);
64
65  // See worker.proto for details.
66  rpc RecvTensor(RecvTensorRequest) returns (RecvTensorResponse) {
67    // RecvTensor Method
68  }
69
70  // See worker.proto for details.
71  rpc Logging(LoggingRequest) returns (LoggingResponse);
72
73  // See worker.proto for details.
74  rpc Tracing(TracingRequest) returns (TracingResponse);
75
76  // See worker.proto for details.
77  rpc RecvBuf(RecvBufRequest) returns (RecvBufResponse) {
78  }
79
80  // See worker.proto for details.
81  rpc GetStepSequence(GetStepSequenceRequest) returns (GetStepSequenceResponse);
82
83  // See worker.proto for details.
84  rpc CompleteGroup(CompleteGroupRequest) returns (CompleteGroupResponse);
85
86  // See worker.proto for details.
87  rpc CompleteInstance(CompleteInstanceRequest)
88      returns (CompleteInstanceResponse);
89}
90