forked from bentoml/BentoML
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrepository.proto
123 lines (102 loc) · 2.19 KB
/
repository.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
syntax = "proto3";
package bentoml;
import "google/protobuf/timestamp.proto";
import "status.proto";
message BentoUri {
enum StorageType {
UNSET = 0;
LOCAL = 1;
S3 = 2;
GCS = 3;
AZURE_BLOB_STORAGE = 4;
HDFS = 5;
}
StorageType type = 1;
string uri = 2;
string additional_fields = 3;
}
message BentoServiceMetadata {
message BentoServiceEnv {
string setup_sh = 1;
string conda_env = 2;
string pip_dependencies = 3;
string python_version = 4;
}
message BentoArtifact {
string name = 1;
string artifact_type = 2;
}
message BentoServiceApi {
string name = 1;
string handler_type = 2;
string docs = 3;
}
string name = 1;
string version = 2;
google.protobuf.Timestamp created_at = 3;
BentoServiceEnv env = 4;
repeated BentoArtifact artifacts = 5;
repeated BentoServiceApi apis = 6;
}
message Bento {
string name = 1;
string version = 2;
BentoUri uri = 3;
BentoServiceMetadata bento_service_metadata = 4;
UploadStatus status = 5;
}
message AddBentoRequest {
string bento_name = 1;
string bento_version = 2;
}
message AddBentoResponse {
Status status = 1;
BentoUri uri = 2;
}
message UploadStatus {
enum Status {
UNINITIALIZED = 0; // default
UPLOADING = 1;
DONE = 2;
ERROR = 3;
TIMEOUT = 4;
}
Status status = 1;
google.protobuf.Timestamp updated_at = 2;
int32 percentage = 3; // for uploading completion percentage
string error_message = 4; // for error message
}
message UpdateBentoRequest {
string bento_name = 1;
string bento_version = 2;
UploadStatus upload_status = 3;
BentoServiceMetadata service_metadata = 4;
}
message UpdateBentoResponse {
Status status = 1;
}
message DangerouslyDeleteBentoRequest {
string bento_name = 1;
string bento_version = 2;
}
message DangerouslyDeleteBentoResponse {
Status status = 1;
}
message GetBentoRequest {
string bento_name = 1;
string bento_version = 2;
}
message GetBentoResponse {
Status status = 1;
Bento bento = 2;
}
message ListBentoRequest {
string bento_name = 1;
int32 offset = 2;
int32 limit = 3;
string filter = 4;
}
message ListBentoResponse {
Status status = 1;
repeated Bento bentos = 2;
}