1#[derive(Clone, PartialEq, ::prost::Message)]
3pub struct Attribution {
4 #[prost(message, optional, tag = "1")]
5 pub time: ::core::option::Option<super::super::super::google::protobuf::Timestamp>,
6 #[prost(string, tag = "2")]
7 pub user_rid: ::prost::alloc::string::String,
8}
9#[derive(Clone, PartialEq, ::prost::Message)]
10pub struct Drive {
11 #[prost(string, tag = "1")]
12 pub rid: ::prost::alloc::string::String,
13 #[prost(string, tag = "2")]
14 pub workspace_rid: ::prost::alloc::string::String,
15 #[prost(string, tag = "3")]
16 pub id: ::prost::alloc::string::String,
17 #[prost(enumeration = "DriveState", tag = "4")]
18 pub state: i32,
19 #[prost(message, optional, tag = "5")]
20 pub created: ::core::option::Option<Attribution>,
21 #[prost(enumeration = "DriveKind", tag = "6")]
22 pub kind: i32,
23}
24#[derive(Clone, PartialEq, ::prost::Message)]
25pub struct VirtualDrive {
26 #[prost(string, tag = "1")]
27 pub drive_rid: ::prost::alloc::string::String,
28 #[prost(message, optional, tag = "2")]
29 pub connection_details: ::core::option::Option<VirtualDriveConnectionDetails>,
30 #[prost(message, optional, tag = "3")]
31 pub status: ::core::option::Option<VirtualDriveStatus>,
32}
33#[derive(Clone, PartialEq, ::prost::Message)]
34pub struct VirtualDriveStatus {
35 #[prost(enumeration = "VirtualDriveState", tag = "1")]
36 pub state: i32,
37 #[prost(message, optional, tag = "2")]
38 pub last_successful_check_time: ::core::option::Option<
39 super::super::super::google::protobuf::Timestamp,
40 >,
41 #[prost(string, tag = "3")]
42 pub message: ::prost::alloc::string::String,
43}
44#[derive(Clone, PartialEq, ::prost::Message)]
45pub struct VirtualDriveConnectionDetails {
46 #[prost(oneof = "virtual_drive_connection_details::Details", tags = "1, 2")]
47 pub details: ::core::option::Option<virtual_drive_connection_details::Details>,
48}
49pub mod virtual_drive_connection_details {
51 #[derive(Clone, PartialEq, ::prost::Oneof)]
52 pub enum Details {
53 #[prost(message, tag = "1")]
54 S3(super::S3VirtualDriveConnectionDetails),
55 #[prost(message, tag = "2")]
56 GoogleDrive(super::GoogleDriveVirtualDriveConnectionDetails),
57 }
58}
59#[derive(Clone, PartialEq, ::prost::Message)]
60pub struct S3VirtualDriveConnectionDetails {
61 #[prost(string, tag = "1")]
62 pub bucket: ::prost::alloc::string::String,
63 #[prost(string, tag = "2")]
64 pub prefix: ::prost::alloc::string::String,
65 #[prost(string, tag = "3")]
66 pub credentials_secret_rid: ::prost::alloc::string::String,
67 #[prost(string, tag = "4")]
68 pub endpoint: ::prost::alloc::string::String,
69}
70#[derive(Clone, PartialEq, ::prost::Message)]
71pub struct GoogleDriveVirtualDriveConnectionDetails {
72 #[prost(string, tag = "1")]
73 pub folder_id: ::prost::alloc::string::String,
74 #[prost(string, tag = "2")]
75 pub credentials_secret_rid: ::prost::alloc::string::String,
76}
77#[derive(Clone, PartialEq, ::prost::Message)]
78pub struct LogicalPath {
79 #[prost(string, tag = "1")]
80 pub path: ::prost::alloc::string::String,
81}
82#[derive(Clone, PartialEq, ::prost::Message)]
83pub struct LogicalFile {
84 #[prost(message, optional, tag = "1")]
85 pub identity: ::core::option::Option<LogicalFileIdentity>,
86 #[prost(message, optional, tag = "2")]
87 pub path: ::core::option::Option<LogicalPath>,
88 #[prost(enumeration = "FileState", tag = "3")]
89 pub state: i32,
90 #[prost(message, optional, tag = "4")]
91 pub created: ::core::option::Option<Attribution>,
92 #[prost(uint64, tag = "5")]
93 pub size_bytes: u64,
94 #[prost(message, optional, tag = "6")]
95 pub observed: ::core::option::Option<Attribution>,
96 #[prost(message, optional, tag = "7")]
97 pub current_revision: ::core::option::Option<FileRevisionRef>,
98}
99#[derive(Clone, PartialEq, ::prost::Message)]
100pub struct LogicalFileIdentity {
101 #[prost(oneof = "logical_file_identity::Identity", tags = "1, 2")]
102 pub identity: ::core::option::Option<logical_file_identity::Identity>,
103}
104pub mod logical_file_identity {
106 #[derive(Clone, PartialEq, ::prost::Oneof)]
107 pub enum Identity {
108 #[prost(message, tag = "1")]
109 Managed(super::ManagedFileIdentity),
110 #[prost(message, tag = "2")]
111 Virtual(super::VirtualFileIdentity),
112 }
113}
114#[derive(Clone, PartialEq, ::prost::Message)]
115pub struct ManagedFileIdentity {
116 #[prost(string, tag = "1")]
117 pub file_rid: ::prost::alloc::string::String,
118}
119#[derive(Clone, PartialEq, ::prost::Message)]
120pub struct VirtualFileIdentity {
121 #[prost(oneof = "virtual_file_identity::Kind", tags = "1, 2")]
122 pub kind: ::core::option::Option<virtual_file_identity::Kind>,
123}
124pub mod virtual_file_identity {
126 #[derive(Clone, PartialEq, ::prost::Oneof)]
127 pub enum Kind {
128 #[prost(message, tag = "1")]
129 S3(super::S3FileIdentity),
130 #[prost(message, tag = "2")]
131 GoogleDrive(super::GoogleDriveFileIdentity),
132 }
133}
134#[derive(Clone, PartialEq, ::prost::Message)]
135pub struct S3FileIdentity {
136 #[prost(string, tag = "1")]
137 pub drive_rid: ::prost::alloc::string::String,
138 #[prost(string, tag = "2")]
139 pub path: ::prost::alloc::string::String,
140}
141#[derive(Clone, PartialEq, ::prost::Message)]
142pub struct GoogleDriveFileIdentity {
143 #[prost(string, tag = "1")]
144 pub drive_rid: ::prost::alloc::string::String,
145 #[prost(string, tag = "2")]
146 pub file_id: ::prost::alloc::string::String,
147}
148#[derive(Clone, PartialEq, ::prost::Message)]
149pub struct FileRevisionRef {
150 #[prost(oneof = "file_revision_ref::Reference", tags = "1, 2")]
151 pub reference: ::core::option::Option<file_revision_ref::Reference>,
152}
153pub mod file_revision_ref {
155 #[derive(Clone, PartialEq, ::prost::Oneof)]
156 pub enum Reference {
157 #[prost(message, tag = "1")]
158 Managed(super::ManagedFileRevisionRef),
159 #[prost(message, tag = "2")]
160 Virtual(super::VirtualFileRevisionRef),
161 }
162}
163#[derive(Clone, PartialEq, ::prost::Message)]
164pub struct ManagedFileRevisionRef {
165 #[prost(string, tag = "1")]
166 pub file_revision_rid: ::prost::alloc::string::String,
167}
168#[derive(Clone, PartialEq, ::prost::Message)]
169pub struct VirtualFileRevisionRef {
170 #[prost(oneof = "virtual_file_revision_ref::Kind", tags = "1, 2")]
171 pub kind: ::core::option::Option<virtual_file_revision_ref::Kind>,
172}
173pub mod virtual_file_revision_ref {
175 #[derive(Clone, PartialEq, ::prost::Oneof)]
176 pub enum Kind {
177 #[prost(message, tag = "1")]
178 S3(super::S3FileRevisionRef),
179 #[prost(message, tag = "2")]
180 GoogleDrive(super::GoogleDriveFileRevisionRef),
181 }
182}
183#[derive(Clone, PartialEq, ::prost::Message)]
184pub struct S3FileRevisionRef {
185 #[prost(string, tag = "1")]
186 pub drive_rid: ::prost::alloc::string::String,
187 #[prost(string, tag = "2")]
188 pub path: ::prost::alloc::string::String,
189 #[prost(string, tag = "3")]
190 pub etag: ::prost::alloc::string::String,
191}
192#[derive(Clone, PartialEq, ::prost::Message)]
193pub struct GoogleDriveFileRevisionRef {
194 #[prost(string, tag = "1")]
195 pub drive_rid: ::prost::alloc::string::String,
196 #[prost(string, tag = "2")]
197 pub file_id: ::prost::alloc::string::String,
198 #[prost(string, tag = "3")]
199 pub version: ::prost::alloc::string::String,
200}
201#[derive(Clone, PartialEq, ::prost::Message)]
202pub struct ManagedFileRevision {
203 #[prost(string, tag = "1")]
204 pub file_revision_rid: ::prost::alloc::string::String,
205 #[prost(string, tag = "2")]
206 pub file_rid: ::prost::alloc::string::String,
207 #[prost(message, optional, tag = "3")]
208 pub path: ::core::option::Option<LogicalPath>,
209 #[prost(uint64, tag = "4")]
210 pub size_bytes: u64,
211 #[prost(message, optional, tag = "5")]
212 pub created: ::core::option::Option<Attribution>,
213 #[prost(enumeration = "FileState", tag = "6")]
214 pub state: i32,
215}
216#[derive(Clone, PartialEq, ::prost::Message)]
217pub struct VirtualFileRevision {
218 #[prost(string, tag = "1")]
219 pub file_revision_rid: ::prost::alloc::string::String,
220 #[prost(message, optional, tag = "2")]
221 pub file_identity: ::core::option::Option<VirtualFileIdentity>,
222 #[prost(message, optional, tag = "3")]
223 pub path: ::core::option::Option<LogicalPath>,
224 #[prost(uint64, tag = "4")]
225 pub size_bytes: u64,
226 #[prost(message, optional, tag = "5")]
227 pub observed: ::core::option::Option<Attribution>,
228}
229#[derive(Clone, PartialEq, ::prost::Message)]
230pub struct Directory {
231 #[prost(message, optional, tag = "1")]
232 pub path: ::core::option::Option<LogicalPath>,
233}
234#[derive(Clone, PartialEq, ::prost::Message)]
235pub struct FileEntry {
236 #[prost(oneof = "file_entry::Entry", tags = "1, 2")]
237 pub entry: ::core::option::Option<file_entry::Entry>,
238}
239pub mod file_entry {
241 #[derive(Clone, PartialEq, ::prost::Oneof)]
242 pub enum Entry {
243 #[prost(message, tag = "1")]
244 File(super::LogicalFile),
245 #[prost(message, tag = "2")]
246 Directory(super::Directory),
247 }
248}
249#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
250#[repr(i32)]
251pub enum DriveState {
252 Unspecified = 0,
253 Active = 1,
254 Archived = 2,
255}
256impl DriveState {
257 pub fn as_str_name(&self) -> &'static str {
262 match self {
263 Self::Unspecified => "DRIVE_STATE_UNSPECIFIED",
264 Self::Active => "DRIVE_STATE_ACTIVE",
265 Self::Archived => "DRIVE_STATE_ARCHIVED",
266 }
267 }
268 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
270 match value {
271 "DRIVE_STATE_UNSPECIFIED" => Some(Self::Unspecified),
272 "DRIVE_STATE_ACTIVE" => Some(Self::Active),
273 "DRIVE_STATE_ARCHIVED" => Some(Self::Archived),
274 _ => None,
275 }
276 }
277}
278#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
279#[repr(i32)]
280pub enum DriveKind {
281 Unspecified = 0,
282 Managed = 1,
283 Virtual = 2,
284}
285impl DriveKind {
286 pub fn as_str_name(&self) -> &'static str {
291 match self {
292 Self::Unspecified => "DRIVE_KIND_UNSPECIFIED",
293 Self::Managed => "DRIVE_KIND_MANAGED",
294 Self::Virtual => "DRIVE_KIND_VIRTUAL",
295 }
296 }
297 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
299 match value {
300 "DRIVE_KIND_UNSPECIFIED" => Some(Self::Unspecified),
301 "DRIVE_KIND_MANAGED" => Some(Self::Managed),
302 "DRIVE_KIND_VIRTUAL" => Some(Self::Virtual),
303 _ => None,
304 }
305 }
306}
307#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
308#[repr(i32)]
309pub enum VirtualDriveState {
310 Unspecified = 0,
311 Active = 1,
312 AuthError = 2,
313 Unreachable = 3,
314 InvalidConfiguration = 4,
315}
316impl VirtualDriveState {
317 pub fn as_str_name(&self) -> &'static str {
322 match self {
323 Self::Unspecified => "VIRTUAL_DRIVE_STATE_UNSPECIFIED",
324 Self::Active => "VIRTUAL_DRIVE_STATE_ACTIVE",
325 Self::AuthError => "VIRTUAL_DRIVE_STATE_AUTH_ERROR",
326 Self::Unreachable => "VIRTUAL_DRIVE_STATE_UNREACHABLE",
327 Self::InvalidConfiguration => "VIRTUAL_DRIVE_STATE_INVALID_CONFIGURATION",
328 }
329 }
330 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
332 match value {
333 "VIRTUAL_DRIVE_STATE_UNSPECIFIED" => Some(Self::Unspecified),
334 "VIRTUAL_DRIVE_STATE_ACTIVE" => Some(Self::Active),
335 "VIRTUAL_DRIVE_STATE_AUTH_ERROR" => Some(Self::AuthError),
336 "VIRTUAL_DRIVE_STATE_UNREACHABLE" => Some(Self::Unreachable),
337 "VIRTUAL_DRIVE_STATE_INVALID_CONFIGURATION" => {
338 Some(Self::InvalidConfiguration)
339 }
340 _ => None,
341 }
342 }
343}
344#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
345#[repr(i32)]
346pub enum FileState {
347 Unspecified = 0,
348 Active = 1,
349 Removed = 2,
350}
351impl FileState {
352 pub fn as_str_name(&self) -> &'static str {
357 match self {
358 Self::Unspecified => "FILE_STATE_UNSPECIFIED",
359 Self::Active => "FILE_STATE_ACTIVE",
360 Self::Removed => "FILE_STATE_REMOVED",
361 }
362 }
363 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
365 match value {
366 "FILE_STATE_UNSPECIFIED" => Some(Self::Unspecified),
367 "FILE_STATE_ACTIVE" => Some(Self::Active),
368 "FILE_STATE_REMOVED" => Some(Self::Removed),
369 _ => None,
370 }
371 }
372}
373#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
374#[repr(i32)]
375pub enum FileStoreError {
376 Unspecified = 0,
377 DriveNotFound = 1,
378 FileNotFound = 2,
379 FileRevisionNotFound = 3,
380 PathAlreadyExists = 4,
381 InvalidLogicalPath = 5,
382 PermissionDenied = 6,
383 RevisionPreconditionFailed = 7,
384 VirtualDriveNotFound = 8,
385 InvalidVirtualDriveConfiguration = 9,
386 ReadOnlyDrive = 10,
387 FileHistoryNotAvailable = 11,
388 UpstreamUnavailable = 12,
389 RevisionBytesReclaimed = 13,
390 UpstreamFileNotFound = 14,
391 DriveIdAlreadyExists = 15,
392 VirtualDriveCredentialsNotFound = 16,
393 VirtualDriveCredentialsInvalid = 17,
394 VirtualDriveCredentialsRejected = 18,
395 MaterializationFailed = 19,
396 IngestRuleNotFound = 20,
397 UploadedObjectNotFound = 21,
398 InvalidObjectKey = 22,
399 InvalidUpstreamState = 23,
400}
401impl FileStoreError {
402 pub fn as_str_name(&self) -> &'static str {
407 match self {
408 Self::Unspecified => "FILE_STORE_ERROR_UNSPECIFIED",
409 Self::DriveNotFound => "FILE_STORE_ERROR_DRIVE_NOT_FOUND",
410 Self::FileNotFound => "FILE_STORE_ERROR_FILE_NOT_FOUND",
411 Self::FileRevisionNotFound => "FILE_STORE_ERROR_FILE_REVISION_NOT_FOUND",
412 Self::PathAlreadyExists => "FILE_STORE_ERROR_PATH_ALREADY_EXISTS",
413 Self::InvalidLogicalPath => "FILE_STORE_ERROR_INVALID_LOGICAL_PATH",
414 Self::PermissionDenied => "FILE_STORE_ERROR_PERMISSION_DENIED",
415 Self::RevisionPreconditionFailed => {
416 "FILE_STORE_ERROR_REVISION_PRECONDITION_FAILED"
417 }
418 Self::VirtualDriveNotFound => "FILE_STORE_ERROR_VIRTUAL_DRIVE_NOT_FOUND",
419 Self::InvalidVirtualDriveConfiguration => {
420 "FILE_STORE_ERROR_INVALID_VIRTUAL_DRIVE_CONFIGURATION"
421 }
422 Self::ReadOnlyDrive => "FILE_STORE_ERROR_READ_ONLY_DRIVE",
423 Self::FileHistoryNotAvailable => {
424 "FILE_STORE_ERROR_FILE_HISTORY_NOT_AVAILABLE"
425 }
426 Self::UpstreamUnavailable => "FILE_STORE_ERROR_UPSTREAM_UNAVAILABLE",
427 Self::RevisionBytesReclaimed => "FILE_STORE_ERROR_REVISION_BYTES_RECLAIMED",
428 Self::UpstreamFileNotFound => "FILE_STORE_ERROR_UPSTREAM_FILE_NOT_FOUND",
429 Self::DriveIdAlreadyExists => "FILE_STORE_ERROR_DRIVE_ID_ALREADY_EXISTS",
430 Self::VirtualDriveCredentialsNotFound => {
431 "FILE_STORE_ERROR_VIRTUAL_DRIVE_CREDENTIALS_NOT_FOUND"
432 }
433 Self::VirtualDriveCredentialsInvalid => {
434 "FILE_STORE_ERROR_VIRTUAL_DRIVE_CREDENTIALS_INVALID"
435 }
436 Self::VirtualDriveCredentialsRejected => {
437 "FILE_STORE_ERROR_VIRTUAL_DRIVE_CREDENTIALS_REJECTED"
438 }
439 Self::MaterializationFailed => "FILE_STORE_ERROR_MATERIALIZATION_FAILED",
440 Self::IngestRuleNotFound => "FILE_STORE_ERROR_INGEST_RULE_NOT_FOUND",
441 Self::UploadedObjectNotFound => "FILE_STORE_ERROR_UPLOADED_OBJECT_NOT_FOUND",
442 Self::InvalidObjectKey => "FILE_STORE_ERROR_INVALID_OBJECT_KEY",
443 Self::InvalidUpstreamState => "FILE_STORE_ERROR_INVALID_UPSTREAM_STATE",
444 }
445 }
446 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
448 match value {
449 "FILE_STORE_ERROR_UNSPECIFIED" => Some(Self::Unspecified),
450 "FILE_STORE_ERROR_DRIVE_NOT_FOUND" => Some(Self::DriveNotFound),
451 "FILE_STORE_ERROR_FILE_NOT_FOUND" => Some(Self::FileNotFound),
452 "FILE_STORE_ERROR_FILE_REVISION_NOT_FOUND" => {
453 Some(Self::FileRevisionNotFound)
454 }
455 "FILE_STORE_ERROR_PATH_ALREADY_EXISTS" => Some(Self::PathAlreadyExists),
456 "FILE_STORE_ERROR_INVALID_LOGICAL_PATH" => Some(Self::InvalidLogicalPath),
457 "FILE_STORE_ERROR_PERMISSION_DENIED" => Some(Self::PermissionDenied),
458 "FILE_STORE_ERROR_REVISION_PRECONDITION_FAILED" => {
459 Some(Self::RevisionPreconditionFailed)
460 }
461 "FILE_STORE_ERROR_VIRTUAL_DRIVE_NOT_FOUND" => {
462 Some(Self::VirtualDriveNotFound)
463 }
464 "FILE_STORE_ERROR_INVALID_VIRTUAL_DRIVE_CONFIGURATION" => {
465 Some(Self::InvalidVirtualDriveConfiguration)
466 }
467 "FILE_STORE_ERROR_READ_ONLY_DRIVE" => Some(Self::ReadOnlyDrive),
468 "FILE_STORE_ERROR_FILE_HISTORY_NOT_AVAILABLE" => {
469 Some(Self::FileHistoryNotAvailable)
470 }
471 "FILE_STORE_ERROR_UPSTREAM_UNAVAILABLE" => Some(Self::UpstreamUnavailable),
472 "FILE_STORE_ERROR_REVISION_BYTES_RECLAIMED" => {
473 Some(Self::RevisionBytesReclaimed)
474 }
475 "FILE_STORE_ERROR_UPSTREAM_FILE_NOT_FOUND" => {
476 Some(Self::UpstreamFileNotFound)
477 }
478 "FILE_STORE_ERROR_DRIVE_ID_ALREADY_EXISTS" => {
479 Some(Self::DriveIdAlreadyExists)
480 }
481 "FILE_STORE_ERROR_VIRTUAL_DRIVE_CREDENTIALS_NOT_FOUND" => {
482 Some(Self::VirtualDriveCredentialsNotFound)
483 }
484 "FILE_STORE_ERROR_VIRTUAL_DRIVE_CREDENTIALS_INVALID" => {
485 Some(Self::VirtualDriveCredentialsInvalid)
486 }
487 "FILE_STORE_ERROR_VIRTUAL_DRIVE_CREDENTIALS_REJECTED" => {
488 Some(Self::VirtualDriveCredentialsRejected)
489 }
490 "FILE_STORE_ERROR_MATERIALIZATION_FAILED" => {
491 Some(Self::MaterializationFailed)
492 }
493 "FILE_STORE_ERROR_INGEST_RULE_NOT_FOUND" => Some(Self::IngestRuleNotFound),
494 "FILE_STORE_ERROR_UPLOADED_OBJECT_NOT_FOUND" => {
495 Some(Self::UploadedObjectNotFound)
496 }
497 "FILE_STORE_ERROR_INVALID_OBJECT_KEY" => Some(Self::InvalidObjectKey),
498 "FILE_STORE_ERROR_INVALID_UPSTREAM_STATE" => Some(Self::InvalidUpstreamState),
499 _ => None,
500 }
501 }
502}
503#[derive(Clone, PartialEq, ::prost::Message)]
504pub struct CreateDriveRequest {
505 #[prost(string, tag = "1")]
506 pub workspace_rid: ::prost::alloc::string::String,
507 #[prost(string, tag = "2")]
508 pub id: ::prost::alloc::string::String,
509}
510#[derive(Clone, PartialEq, ::prost::Message)]
511pub struct CreateDriveResponse {
512 #[prost(message, optional, tag = "1")]
513 pub drive: ::core::option::Option<Drive>,
514}
515#[derive(Clone, PartialEq, ::prost::Message)]
516pub struct CreateVirtualDriveRequest {
517 #[prost(string, tag = "1")]
518 pub workspace_rid: ::prost::alloc::string::String,
519 #[prost(string, tag = "2")]
520 pub id: ::prost::alloc::string::String,
521 #[prost(message, optional, tag = "3")]
522 pub connection_details: ::core::option::Option<VirtualDriveConnectionDetails>,
523}
524#[derive(Clone, PartialEq, ::prost::Message)]
525pub struct CreateVirtualDriveResponse {
526 #[prost(message, optional, tag = "1")]
527 pub drive: ::core::option::Option<Drive>,
528 #[prost(message, optional, tag = "2")]
529 pub virtual_drive: ::core::option::Option<VirtualDrive>,
530}
531#[derive(Clone, PartialEq, ::prost::Message)]
532pub struct GetDriveRequest {
533 #[prost(string, tag = "1")]
534 pub drive_rid: ::prost::alloc::string::String,
535}
536#[derive(Clone, PartialEq, ::prost::Message)]
537pub struct GetDriveResponse {
538 #[prost(message, optional, tag = "1")]
539 pub drive: ::core::option::Option<Drive>,
540}
541#[derive(Clone, PartialEq, ::prost::Message)]
542pub struct GetVirtualDriveRequest {
543 #[prost(string, tag = "1")]
544 pub drive_rid: ::prost::alloc::string::String,
545}
546#[derive(Clone, PartialEq, ::prost::Message)]
547pub struct GetVirtualDriveResponse {
548 #[prost(message, optional, tag = "1")]
549 pub drive: ::core::option::Option<Drive>,
550 #[prost(message, optional, tag = "2")]
551 pub virtual_drive: ::core::option::Option<VirtualDrive>,
552}
553#[derive(Clone, PartialEq, ::prost::Message)]
554pub struct GetDriveByIdRequest {
555 #[prost(string, tag = "1")]
556 pub workspace_rid: ::prost::alloc::string::String,
557 #[prost(string, tag = "2")]
558 pub id: ::prost::alloc::string::String,
559}
560#[derive(Clone, PartialEq, ::prost::Message)]
561pub struct GetDriveByIdResponse {
562 #[prost(message, optional, tag = "1")]
563 pub drive: ::core::option::Option<Drive>,
564}
565#[derive(Clone, PartialEq, ::prost::Message)]
566pub struct GetVirtualDriveByIdRequest {
567 #[prost(string, tag = "1")]
568 pub workspace_rid: ::prost::alloc::string::String,
569 #[prost(string, tag = "2")]
570 pub id: ::prost::alloc::string::String,
571}
572#[derive(Clone, PartialEq, ::prost::Message)]
573pub struct GetVirtualDriveByIdResponse {
574 #[prost(message, optional, tag = "1")]
575 pub drive: ::core::option::Option<Drive>,
576 #[prost(message, optional, tag = "2")]
577 pub virtual_drive: ::core::option::Option<VirtualDrive>,
578}
579#[derive(Clone, PartialEq, ::prost::Message)]
580pub struct ListDrivesRequest {
581 #[prost(string, tag = "1")]
582 pub workspace_rid: ::prost::alloc::string::String,
583 #[prost(bool, tag = "2")]
584 pub include_archived: bool,
585 #[prost(int32, optional, tag = "3")]
586 pub page_size: ::core::option::Option<i32>,
587 #[prost(string, optional, tag = "4")]
588 pub page_token: ::core::option::Option<::prost::alloc::string::String>,
589}
590#[derive(Clone, PartialEq, ::prost::Message)]
591pub struct ListDrivesResponse {
592 #[prost(message, repeated, tag = "1")]
593 pub drives: ::prost::alloc::vec::Vec<Drive>,
594 #[prost(string, optional, tag = "2")]
595 pub next_page_token: ::core::option::Option<::prost::alloc::string::String>,
596}
597#[derive(Clone, PartialEq, ::prost::Message)]
598pub struct UpdateVirtualDriveRequest {
599 #[prost(string, tag = "1")]
600 pub drive_rid: ::prost::alloc::string::String,
601 #[prost(message, optional, tag = "2")]
602 pub connection_details: ::core::option::Option<VirtualDriveConnectionDetails>,
603}
604#[derive(Clone, PartialEq, ::prost::Message)]
605pub struct UpdateVirtualDriveResponse {
606 #[prost(message, optional, tag = "1")]
607 pub drive: ::core::option::Option<Drive>,
608 #[prost(message, optional, tag = "2")]
609 pub virtual_drive: ::core::option::Option<VirtualDrive>,
610}
611#[derive(Clone, PartialEq, ::prost::Message)]
612pub struct UpdateDriveDetailsRequest {
613 #[prost(string, tag = "1")]
614 pub drive_rid: ::prost::alloc::string::String,
615 #[prost(string, optional, tag = "2")]
616 pub id: ::core::option::Option<::prost::alloc::string::String>,
617}
618#[derive(Clone, PartialEq, ::prost::Message)]
619pub struct UpdateDriveDetailsResponse {
620 #[prost(message, optional, tag = "1")]
621 pub drive: ::core::option::Option<Drive>,
622}
623#[derive(Clone, PartialEq, ::prost::Message)]
624pub struct ArchiveDriveRequest {
625 #[prost(string, tag = "1")]
626 pub drive_rid: ::prost::alloc::string::String,
627}
628#[derive(Clone, PartialEq, ::prost::Message)]
629pub struct ArchiveDriveResponse {
630 #[prost(message, optional, tag = "1")]
631 pub drive: ::core::option::Option<Drive>,
632}
633#[derive(Clone, PartialEq, ::prost::Message)]
634pub struct UnarchiveDriveRequest {
635 #[prost(string, tag = "1")]
636 pub drive_rid: ::prost::alloc::string::String,
637}
638#[derive(Clone, PartialEq, ::prost::Message)]
639pub struct UnarchiveDriveResponse {
640 #[prost(message, optional, tag = "1")]
641 pub drive: ::core::option::Option<Drive>,
642}
643pub mod drives_service_client {
645 #![allow(
646 unused_variables,
647 dead_code,
648 missing_docs,
649 clippy::wildcard_imports,
650 clippy::let_unit_value,
651 )]
652 use tonic::codegen::*;
653 use tonic::codegen::http::Uri;
654 #[derive(Debug, Clone)]
655 pub struct DrivesServiceClient<T> {
656 inner: tonic::client::Grpc<T>,
657 }
658 impl DrivesServiceClient<tonic::transport::Channel> {
659 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
661 where
662 D: TryInto<tonic::transport::Endpoint>,
663 D::Error: Into<StdError>,
664 {
665 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
666 Ok(Self::new(conn))
667 }
668 }
669 impl<T> DrivesServiceClient<T>
670 where
671 T: tonic::client::GrpcService<tonic::body::Body>,
672 T::Error: Into<StdError>,
673 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
674 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
675 {
676 pub fn new(inner: T) -> Self {
677 let inner = tonic::client::Grpc::new(inner);
678 Self { inner }
679 }
680 pub fn with_origin(inner: T, origin: Uri) -> Self {
681 let inner = tonic::client::Grpc::with_origin(inner, origin);
682 Self { inner }
683 }
684 pub fn with_interceptor<F>(
685 inner: T,
686 interceptor: F,
687 ) -> DrivesServiceClient<InterceptedService<T, F>>
688 where
689 F: tonic::service::Interceptor,
690 T::ResponseBody: Default,
691 T: tonic::codegen::Service<
692 http::Request<tonic::body::Body>,
693 Response = http::Response<
694 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
695 >,
696 >,
697 <T as tonic::codegen::Service<
698 http::Request<tonic::body::Body>,
699 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
700 {
701 DrivesServiceClient::new(InterceptedService::new(inner, interceptor))
702 }
703 #[must_use]
708 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
709 self.inner = self.inner.send_compressed(encoding);
710 self
711 }
712 #[must_use]
714 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
715 self.inner = self.inner.accept_compressed(encoding);
716 self
717 }
718 #[must_use]
722 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
723 self.inner = self.inner.max_decoding_message_size(limit);
724 self
725 }
726 #[must_use]
730 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
731 self.inner = self.inner.max_encoding_message_size(limit);
732 self
733 }
734 pub async fn create_drive(
735 &mut self,
736 request: impl tonic::IntoRequest<super::CreateDriveRequest>,
737 ) -> std::result::Result<
738 tonic::Response<super::CreateDriveResponse>,
739 tonic::Status,
740 > {
741 self.inner
742 .ready()
743 .await
744 .map_err(|e| {
745 tonic::Status::unknown(
746 format!("Service was not ready: {}", e.into()),
747 )
748 })?;
749 let codec = tonic::codec::ProstCodec::default();
750 let path = http::uri::PathAndQuery::from_static(
751 "/nominal.file_store.v1.DrivesService/CreateDrive",
752 );
753 let mut req = request.into_request();
754 req.extensions_mut()
755 .insert(
756 GrpcMethod::new("nominal.file_store.v1.DrivesService", "CreateDrive"),
757 );
758 self.inner.unary(req, path, codec).await
759 }
760 pub async fn create_virtual_drive(
761 &mut self,
762 request: impl tonic::IntoRequest<super::CreateVirtualDriveRequest>,
763 ) -> std::result::Result<
764 tonic::Response<super::CreateVirtualDriveResponse>,
765 tonic::Status,
766 > {
767 self.inner
768 .ready()
769 .await
770 .map_err(|e| {
771 tonic::Status::unknown(
772 format!("Service was not ready: {}", e.into()),
773 )
774 })?;
775 let codec = tonic::codec::ProstCodec::default();
776 let path = http::uri::PathAndQuery::from_static(
777 "/nominal.file_store.v1.DrivesService/CreateVirtualDrive",
778 );
779 let mut req = request.into_request();
780 req.extensions_mut()
781 .insert(
782 GrpcMethod::new(
783 "nominal.file_store.v1.DrivesService",
784 "CreateVirtualDrive",
785 ),
786 );
787 self.inner.unary(req, path, codec).await
788 }
789 pub async fn get_drive(
790 &mut self,
791 request: impl tonic::IntoRequest<super::GetDriveRequest>,
792 ) -> std::result::Result<
793 tonic::Response<super::GetDriveResponse>,
794 tonic::Status,
795 > {
796 self.inner
797 .ready()
798 .await
799 .map_err(|e| {
800 tonic::Status::unknown(
801 format!("Service was not ready: {}", e.into()),
802 )
803 })?;
804 let codec = tonic::codec::ProstCodec::default();
805 let path = http::uri::PathAndQuery::from_static(
806 "/nominal.file_store.v1.DrivesService/GetDrive",
807 );
808 let mut req = request.into_request();
809 req.extensions_mut()
810 .insert(
811 GrpcMethod::new("nominal.file_store.v1.DrivesService", "GetDrive"),
812 );
813 self.inner.unary(req, path, codec).await
814 }
815 pub async fn get_virtual_drive(
816 &mut self,
817 request: impl tonic::IntoRequest<super::GetVirtualDriveRequest>,
818 ) -> std::result::Result<
819 tonic::Response<super::GetVirtualDriveResponse>,
820 tonic::Status,
821 > {
822 self.inner
823 .ready()
824 .await
825 .map_err(|e| {
826 tonic::Status::unknown(
827 format!("Service was not ready: {}", e.into()),
828 )
829 })?;
830 let codec = tonic::codec::ProstCodec::default();
831 let path = http::uri::PathAndQuery::from_static(
832 "/nominal.file_store.v1.DrivesService/GetVirtualDrive",
833 );
834 let mut req = request.into_request();
835 req.extensions_mut()
836 .insert(
837 GrpcMethod::new(
838 "nominal.file_store.v1.DrivesService",
839 "GetVirtualDrive",
840 ),
841 );
842 self.inner.unary(req, path, codec).await
843 }
844 pub async fn get_drive_by_id(
845 &mut self,
846 request: impl tonic::IntoRequest<super::GetDriveByIdRequest>,
847 ) -> std::result::Result<
848 tonic::Response<super::GetDriveByIdResponse>,
849 tonic::Status,
850 > {
851 self.inner
852 .ready()
853 .await
854 .map_err(|e| {
855 tonic::Status::unknown(
856 format!("Service was not ready: {}", e.into()),
857 )
858 })?;
859 let codec = tonic::codec::ProstCodec::default();
860 let path = http::uri::PathAndQuery::from_static(
861 "/nominal.file_store.v1.DrivesService/GetDriveById",
862 );
863 let mut req = request.into_request();
864 req.extensions_mut()
865 .insert(
866 GrpcMethod::new(
867 "nominal.file_store.v1.DrivesService",
868 "GetDriveById",
869 ),
870 );
871 self.inner.unary(req, path, codec).await
872 }
873 pub async fn get_virtual_drive_by_id(
874 &mut self,
875 request: impl tonic::IntoRequest<super::GetVirtualDriveByIdRequest>,
876 ) -> std::result::Result<
877 tonic::Response<super::GetVirtualDriveByIdResponse>,
878 tonic::Status,
879 > {
880 self.inner
881 .ready()
882 .await
883 .map_err(|e| {
884 tonic::Status::unknown(
885 format!("Service was not ready: {}", e.into()),
886 )
887 })?;
888 let codec = tonic::codec::ProstCodec::default();
889 let path = http::uri::PathAndQuery::from_static(
890 "/nominal.file_store.v1.DrivesService/GetVirtualDriveById",
891 );
892 let mut req = request.into_request();
893 req.extensions_mut()
894 .insert(
895 GrpcMethod::new(
896 "nominal.file_store.v1.DrivesService",
897 "GetVirtualDriveById",
898 ),
899 );
900 self.inner.unary(req, path, codec).await
901 }
902 pub async fn list_drives(
903 &mut self,
904 request: impl tonic::IntoRequest<super::ListDrivesRequest>,
905 ) -> std::result::Result<
906 tonic::Response<super::ListDrivesResponse>,
907 tonic::Status,
908 > {
909 self.inner
910 .ready()
911 .await
912 .map_err(|e| {
913 tonic::Status::unknown(
914 format!("Service was not ready: {}", e.into()),
915 )
916 })?;
917 let codec = tonic::codec::ProstCodec::default();
918 let path = http::uri::PathAndQuery::from_static(
919 "/nominal.file_store.v1.DrivesService/ListDrives",
920 );
921 let mut req = request.into_request();
922 req.extensions_mut()
923 .insert(
924 GrpcMethod::new("nominal.file_store.v1.DrivesService", "ListDrives"),
925 );
926 self.inner.unary(req, path, codec).await
927 }
928 pub async fn update_virtual_drive(
929 &mut self,
930 request: impl tonic::IntoRequest<super::UpdateVirtualDriveRequest>,
931 ) -> std::result::Result<
932 tonic::Response<super::UpdateVirtualDriveResponse>,
933 tonic::Status,
934 > {
935 self.inner
936 .ready()
937 .await
938 .map_err(|e| {
939 tonic::Status::unknown(
940 format!("Service was not ready: {}", e.into()),
941 )
942 })?;
943 let codec = tonic::codec::ProstCodec::default();
944 let path = http::uri::PathAndQuery::from_static(
945 "/nominal.file_store.v1.DrivesService/UpdateVirtualDrive",
946 );
947 let mut req = request.into_request();
948 req.extensions_mut()
949 .insert(
950 GrpcMethod::new(
951 "nominal.file_store.v1.DrivesService",
952 "UpdateVirtualDrive",
953 ),
954 );
955 self.inner.unary(req, path, codec).await
956 }
957 pub async fn update_drive_details(
958 &mut self,
959 request: impl tonic::IntoRequest<super::UpdateDriveDetailsRequest>,
960 ) -> std::result::Result<
961 tonic::Response<super::UpdateDriveDetailsResponse>,
962 tonic::Status,
963 > {
964 self.inner
965 .ready()
966 .await
967 .map_err(|e| {
968 tonic::Status::unknown(
969 format!("Service was not ready: {}", e.into()),
970 )
971 })?;
972 let codec = tonic::codec::ProstCodec::default();
973 let path = http::uri::PathAndQuery::from_static(
974 "/nominal.file_store.v1.DrivesService/UpdateDriveDetails",
975 );
976 let mut req = request.into_request();
977 req.extensions_mut()
978 .insert(
979 GrpcMethod::new(
980 "nominal.file_store.v1.DrivesService",
981 "UpdateDriveDetails",
982 ),
983 );
984 self.inner.unary(req, path, codec).await
985 }
986 pub async fn archive_drive(
987 &mut self,
988 request: impl tonic::IntoRequest<super::ArchiveDriveRequest>,
989 ) -> std::result::Result<
990 tonic::Response<super::ArchiveDriveResponse>,
991 tonic::Status,
992 > {
993 self.inner
994 .ready()
995 .await
996 .map_err(|e| {
997 tonic::Status::unknown(
998 format!("Service was not ready: {}", e.into()),
999 )
1000 })?;
1001 let codec = tonic::codec::ProstCodec::default();
1002 let path = http::uri::PathAndQuery::from_static(
1003 "/nominal.file_store.v1.DrivesService/ArchiveDrive",
1004 );
1005 let mut req = request.into_request();
1006 req.extensions_mut()
1007 .insert(
1008 GrpcMethod::new(
1009 "nominal.file_store.v1.DrivesService",
1010 "ArchiveDrive",
1011 ),
1012 );
1013 self.inner.unary(req, path, codec).await
1014 }
1015 pub async fn unarchive_drive(
1016 &mut self,
1017 request: impl tonic::IntoRequest<super::UnarchiveDriveRequest>,
1018 ) -> std::result::Result<
1019 tonic::Response<super::UnarchiveDriveResponse>,
1020 tonic::Status,
1021 > {
1022 self.inner
1023 .ready()
1024 .await
1025 .map_err(|e| {
1026 tonic::Status::unknown(
1027 format!("Service was not ready: {}", e.into()),
1028 )
1029 })?;
1030 let codec = tonic::codec::ProstCodec::default();
1031 let path = http::uri::PathAndQuery::from_static(
1032 "/nominal.file_store.v1.DrivesService/UnarchiveDrive",
1033 );
1034 let mut req = request.into_request();
1035 req.extensions_mut()
1036 .insert(
1037 GrpcMethod::new(
1038 "nominal.file_store.v1.DrivesService",
1039 "UnarchiveDrive",
1040 ),
1041 );
1042 self.inner.unary(req, path, codec).await
1043 }
1044 }
1045}
1046#[derive(Clone, PartialEq, ::prost::Message)]
1047pub struct UploadedObjectRef {
1048 #[prost(string, tag = "1")]
1049 pub object_key: ::prost::alloc::string::String,
1050}
1051#[derive(Clone, PartialEq, ::prost::Message)]
1052pub struct PathTarget {
1053 #[prost(message, optional, tag = "1")]
1054 pub path: ::core::option::Option<LogicalPath>,
1055}
1056#[derive(Clone, PartialEq, ::prost::Message)]
1057pub struct Destination {
1058 #[prost(oneof = "destination::Target", tags = "1, 2")]
1059 pub target: ::core::option::Option<destination::Target>,
1060}
1061pub mod destination {
1063 #[derive(Clone, PartialEq, ::prost::Oneof)]
1064 pub enum Target {
1065 #[prost(message, tag = "1")]
1066 Path(super::PathTarget),
1067 #[prost(string, tag = "2")]
1068 FileRevisionRid(::prost::alloc::string::String),
1069 }
1070}
1071#[derive(Clone, PartialEq, ::prost::Message)]
1072pub struct PutFile {
1073 #[prost(message, optional, tag = "1")]
1074 pub object: ::core::option::Option<UploadedObjectRef>,
1075 #[prost(uint64, tag = "2")]
1076 pub size_bytes: u64,
1077 #[prost(message, optional, tag = "3")]
1078 pub destination: ::core::option::Option<Destination>,
1079}
1080#[derive(Clone, PartialEq, ::prost::Message)]
1081pub struct MoveFile {
1082 #[prost(string, tag = "1")]
1083 pub source_revision_rid: ::prost::alloc::string::String,
1084 #[prost(message, optional, tag = "2")]
1085 pub destination: ::core::option::Option<Destination>,
1086}
1087#[derive(Clone, PartialEq, ::prost::Message)]
1088pub struct RemoveFile {
1089 #[prost(string, tag = "1")]
1090 pub revision_rid: ::prost::alloc::string::String,
1091}
1092#[derive(Clone, PartialEq, ::prost::Message)]
1093pub struct RestoreFile {
1094 #[prost(string, tag = "1")]
1095 pub restore_revision_rid: ::prost::alloc::string::String,
1096 #[prost(message, optional, tag = "2")]
1097 pub destination: ::core::option::Option<Destination>,
1098}
1099#[derive(Clone, PartialEq, ::prost::Message)]
1100pub struct FileChange {
1101 #[prost(oneof = "file_change::Change", tags = "1, 2, 3, 4")]
1102 pub change: ::core::option::Option<file_change::Change>,
1103}
1104pub mod file_change {
1106 #[derive(Clone, PartialEq, ::prost::Oneof)]
1107 pub enum Change {
1108 #[prost(message, tag = "1")]
1109 Put(super::PutFile),
1110 #[prost(message, tag = "2")]
1111 Move(super::MoveFile),
1112 #[prost(message, tag = "3")]
1113 Remove(super::RemoveFile),
1114 #[prost(message, tag = "4")]
1115 Restore(super::RestoreFile),
1116 }
1117}
1118#[derive(Clone, PartialEq, ::prost::Message)]
1119pub struct GetFileRequest {
1120 #[prost(string, tag = "1")]
1121 pub drive_rid: ::prost::alloc::string::String,
1122 #[prost(message, optional, tag = "2")]
1123 pub path: ::core::option::Option<LogicalPath>,
1124 #[prost(bool, tag = "3")]
1125 pub include_removed: bool,
1126}
1127#[derive(Clone, PartialEq, ::prost::Message)]
1128pub struct GetFileResponse {
1129 #[prost(message, optional, tag = "1")]
1130 pub file: ::core::option::Option<LogicalFile>,
1131}
1132#[derive(Clone, PartialEq, ::prost::Message)]
1133pub struct ResolveFileRevisionRequest {
1134 #[prost(message, optional, tag = "2")]
1135 pub source_ref: ::core::option::Option<FileRevisionRef>,
1136}
1137#[derive(Clone, PartialEq, ::prost::Message)]
1138pub struct ResolveFileRevisionResponse {
1139 #[prost(string, tag = "1")]
1140 pub file_revision_rid: ::prost::alloc::string::String,
1141}
1142#[derive(Clone, PartialEq, ::prost::Message)]
1143pub struct ListFilesRequest {
1144 #[prost(string, tag = "1")]
1145 pub drive_rid: ::prost::alloc::string::String,
1146 #[prost(message, optional, tag = "2")]
1147 pub parent_path: ::core::option::Option<LogicalPath>,
1148 #[prost(bool, tag = "3")]
1149 pub include_removed: bool,
1150 #[prost(int32, optional, tag = "4")]
1151 pub page_size: ::core::option::Option<i32>,
1152 #[prost(string, optional, tag = "5")]
1153 pub page_token: ::core::option::Option<::prost::alloc::string::String>,
1154}
1155#[derive(Clone, PartialEq, ::prost::Message)]
1156pub struct ListFilesResponse {
1157 #[prost(message, repeated, tag = "1")]
1158 pub entries: ::prost::alloc::vec::Vec<FileEntry>,
1159 #[prost(string, optional, tag = "2")]
1160 pub next_page_token: ::core::option::Option<::prost::alloc::string::String>,
1161}
1162#[derive(Clone, PartialEq, ::prost::Message)]
1163pub struct ApplyFileChangesRequest {
1164 #[prost(string, tag = "1")]
1165 pub drive_rid: ::prost::alloc::string::String,
1166 #[prost(message, repeated, tag = "2")]
1167 pub changes: ::prost::alloc::vec::Vec<FileChange>,
1168}
1169#[derive(Clone, PartialEq, ::prost::Message)]
1170pub struct ApplyFileChangesResponse {
1171 #[prost(message, repeated, tag = "1")]
1172 pub results: ::prost::alloc::vec::Vec<FileChangeResult>,
1173}
1174#[derive(Clone, PartialEq, ::prost::Message)]
1175pub struct FileChangeSuccess {
1176 #[prost(message, optional, tag = "1")]
1177 pub file: ::core::option::Option<LogicalFile>,
1178 #[prost(message, optional, tag = "2")]
1179 pub file_revision: ::core::option::Option<ManagedFileRevision>,
1180}
1181#[derive(Clone, PartialEq, ::prost::Message)]
1182pub struct FileChangeFailure {
1183 #[prost(enumeration = "FileStoreError", tag = "1")]
1184 pub code: i32,
1185 #[prost(string, tag = "2")]
1186 pub message: ::prost::alloc::string::String,
1187}
1188#[derive(Clone, PartialEq, ::prost::Message)]
1189pub struct FileChangeResult {
1190 #[prost(oneof = "file_change_result::Result", tags = "1, 2")]
1191 pub result: ::core::option::Option<file_change_result::Result>,
1192}
1193pub mod file_change_result {
1195 #[derive(Clone, PartialEq, ::prost::Oneof)]
1196 pub enum Result {
1197 #[prost(message, tag = "1")]
1198 Success(super::FileChangeSuccess),
1199 #[prost(message, tag = "2")]
1200 Failure(super::FileChangeFailure),
1201 }
1202}
1203#[derive(Clone, PartialEq, ::prost::Message)]
1204pub struct ListFileRevisionsRequest {
1205 #[prost(string, tag = "1")]
1206 pub drive_rid: ::prost::alloc::string::String,
1207 #[prost(string, tag = "2")]
1208 pub file_rid: ::prost::alloc::string::String,
1209 #[prost(int32, optional, tag = "3")]
1210 pub page_size: ::core::option::Option<i32>,
1211 #[prost(string, optional, tag = "4")]
1212 pub page_token: ::core::option::Option<::prost::alloc::string::String>,
1213}
1214#[derive(Clone, PartialEq, ::prost::Message)]
1215pub struct ListFileRevisionsResponse {
1216 #[prost(message, repeated, tag = "1")]
1217 pub file_revisions: ::prost::alloc::vec::Vec<ManagedFileRevision>,
1218 #[prost(string, optional, tag = "2")]
1219 pub next_page_token: ::core::option::Option<::prost::alloc::string::String>,
1220}
1221#[derive(Clone, PartialEq, ::prost::Message)]
1222pub struct PurgeFileRequest {
1223 #[prost(string, tag = "1")]
1224 pub file_revision_rid: ::prost::alloc::string::String,
1225}
1226#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1227pub struct PurgeFileResponse {}
1228pub mod files_service_client {
1230 #![allow(
1231 unused_variables,
1232 dead_code,
1233 missing_docs,
1234 clippy::wildcard_imports,
1235 clippy::let_unit_value,
1236 )]
1237 use tonic::codegen::*;
1238 use tonic::codegen::http::Uri;
1239 #[derive(Debug, Clone)]
1240 pub struct FilesServiceClient<T> {
1241 inner: tonic::client::Grpc<T>,
1242 }
1243 impl FilesServiceClient<tonic::transport::Channel> {
1244 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
1246 where
1247 D: TryInto<tonic::transport::Endpoint>,
1248 D::Error: Into<StdError>,
1249 {
1250 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
1251 Ok(Self::new(conn))
1252 }
1253 }
1254 impl<T> FilesServiceClient<T>
1255 where
1256 T: tonic::client::GrpcService<tonic::body::Body>,
1257 T::Error: Into<StdError>,
1258 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
1259 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
1260 {
1261 pub fn new(inner: T) -> Self {
1262 let inner = tonic::client::Grpc::new(inner);
1263 Self { inner }
1264 }
1265 pub fn with_origin(inner: T, origin: Uri) -> Self {
1266 let inner = tonic::client::Grpc::with_origin(inner, origin);
1267 Self { inner }
1268 }
1269 pub fn with_interceptor<F>(
1270 inner: T,
1271 interceptor: F,
1272 ) -> FilesServiceClient<InterceptedService<T, F>>
1273 where
1274 F: tonic::service::Interceptor,
1275 T::ResponseBody: Default,
1276 T: tonic::codegen::Service<
1277 http::Request<tonic::body::Body>,
1278 Response = http::Response<
1279 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
1280 >,
1281 >,
1282 <T as tonic::codegen::Service<
1283 http::Request<tonic::body::Body>,
1284 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
1285 {
1286 FilesServiceClient::new(InterceptedService::new(inner, interceptor))
1287 }
1288 #[must_use]
1293 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
1294 self.inner = self.inner.send_compressed(encoding);
1295 self
1296 }
1297 #[must_use]
1299 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
1300 self.inner = self.inner.accept_compressed(encoding);
1301 self
1302 }
1303 #[must_use]
1307 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
1308 self.inner = self.inner.max_decoding_message_size(limit);
1309 self
1310 }
1311 #[must_use]
1315 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
1316 self.inner = self.inner.max_encoding_message_size(limit);
1317 self
1318 }
1319 pub async fn get_file(
1320 &mut self,
1321 request: impl tonic::IntoRequest<super::GetFileRequest>,
1322 ) -> std::result::Result<
1323 tonic::Response<super::GetFileResponse>,
1324 tonic::Status,
1325 > {
1326 self.inner
1327 .ready()
1328 .await
1329 .map_err(|e| {
1330 tonic::Status::unknown(
1331 format!("Service was not ready: {}", e.into()),
1332 )
1333 })?;
1334 let codec = tonic::codec::ProstCodec::default();
1335 let path = http::uri::PathAndQuery::from_static(
1336 "/nominal.file_store.v1.FilesService/GetFile",
1337 );
1338 let mut req = request.into_request();
1339 req.extensions_mut()
1340 .insert(
1341 GrpcMethod::new("nominal.file_store.v1.FilesService", "GetFile"),
1342 );
1343 self.inner.unary(req, path, codec).await
1344 }
1345 pub async fn resolve_file_revision(
1346 &mut self,
1347 request: impl tonic::IntoRequest<super::ResolveFileRevisionRequest>,
1348 ) -> std::result::Result<
1349 tonic::Response<super::ResolveFileRevisionResponse>,
1350 tonic::Status,
1351 > {
1352 self.inner
1353 .ready()
1354 .await
1355 .map_err(|e| {
1356 tonic::Status::unknown(
1357 format!("Service was not ready: {}", e.into()),
1358 )
1359 })?;
1360 let codec = tonic::codec::ProstCodec::default();
1361 let path = http::uri::PathAndQuery::from_static(
1362 "/nominal.file_store.v1.FilesService/ResolveFileRevision",
1363 );
1364 let mut req = request.into_request();
1365 req.extensions_mut()
1366 .insert(
1367 GrpcMethod::new(
1368 "nominal.file_store.v1.FilesService",
1369 "ResolveFileRevision",
1370 ),
1371 );
1372 self.inner.unary(req, path, codec).await
1373 }
1374 pub async fn list_files(
1375 &mut self,
1376 request: impl tonic::IntoRequest<super::ListFilesRequest>,
1377 ) -> std::result::Result<
1378 tonic::Response<super::ListFilesResponse>,
1379 tonic::Status,
1380 > {
1381 self.inner
1382 .ready()
1383 .await
1384 .map_err(|e| {
1385 tonic::Status::unknown(
1386 format!("Service was not ready: {}", e.into()),
1387 )
1388 })?;
1389 let codec = tonic::codec::ProstCodec::default();
1390 let path = http::uri::PathAndQuery::from_static(
1391 "/nominal.file_store.v1.FilesService/ListFiles",
1392 );
1393 let mut req = request.into_request();
1394 req.extensions_mut()
1395 .insert(
1396 GrpcMethod::new("nominal.file_store.v1.FilesService", "ListFiles"),
1397 );
1398 self.inner.unary(req, path, codec).await
1399 }
1400 pub async fn apply_file_changes(
1401 &mut self,
1402 request: impl tonic::IntoRequest<super::ApplyFileChangesRequest>,
1403 ) -> std::result::Result<
1404 tonic::Response<super::ApplyFileChangesResponse>,
1405 tonic::Status,
1406 > {
1407 self.inner
1408 .ready()
1409 .await
1410 .map_err(|e| {
1411 tonic::Status::unknown(
1412 format!("Service was not ready: {}", e.into()),
1413 )
1414 })?;
1415 let codec = tonic::codec::ProstCodec::default();
1416 let path = http::uri::PathAndQuery::from_static(
1417 "/nominal.file_store.v1.FilesService/ApplyFileChanges",
1418 );
1419 let mut req = request.into_request();
1420 req.extensions_mut()
1421 .insert(
1422 GrpcMethod::new(
1423 "nominal.file_store.v1.FilesService",
1424 "ApplyFileChanges",
1425 ),
1426 );
1427 self.inner.unary(req, path, codec).await
1428 }
1429 pub async fn list_file_revisions(
1430 &mut self,
1431 request: impl tonic::IntoRequest<super::ListFileRevisionsRequest>,
1432 ) -> std::result::Result<
1433 tonic::Response<super::ListFileRevisionsResponse>,
1434 tonic::Status,
1435 > {
1436 self.inner
1437 .ready()
1438 .await
1439 .map_err(|e| {
1440 tonic::Status::unknown(
1441 format!("Service was not ready: {}", e.into()),
1442 )
1443 })?;
1444 let codec = tonic::codec::ProstCodec::default();
1445 let path = http::uri::PathAndQuery::from_static(
1446 "/nominal.file_store.v1.FilesService/ListFileRevisions",
1447 );
1448 let mut req = request.into_request();
1449 req.extensions_mut()
1450 .insert(
1451 GrpcMethod::new(
1452 "nominal.file_store.v1.FilesService",
1453 "ListFileRevisions",
1454 ),
1455 );
1456 self.inner.unary(req, path, codec).await
1457 }
1458 pub async fn purge_file(
1459 &mut self,
1460 request: impl tonic::IntoRequest<super::PurgeFileRequest>,
1461 ) -> std::result::Result<
1462 tonic::Response<super::PurgeFileResponse>,
1463 tonic::Status,
1464 > {
1465 self.inner
1466 .ready()
1467 .await
1468 .map_err(|e| {
1469 tonic::Status::unknown(
1470 format!("Service was not ready: {}", e.into()),
1471 )
1472 })?;
1473 let codec = tonic::codec::ProstCodec::default();
1474 let path = http::uri::PathAndQuery::from_static(
1475 "/nominal.file_store.v1.FilesService/PurgeFile",
1476 );
1477 let mut req = request.into_request();
1478 req.extensions_mut()
1479 .insert(
1480 GrpcMethod::new("nominal.file_store.v1.FilesService", "PurgeFile"),
1481 );
1482 self.inner.unary(req, path, codec).await
1483 }
1484 }
1485}
1486#[derive(Clone, PartialEq, ::prost::Message)]
1487pub struct CreateIngestRuleRequest {
1488 #[prost(string, tag = "1")]
1489 pub drive_rid: ::prost::alloc::string::String,
1490 #[prost(message, optional, tag = "2")]
1491 pub matcher: ::core::option::Option<FileMatcher>,
1492 #[prost(message, optional, tag = "3")]
1493 pub triggers: ::core::option::Option<IngestTriggers>,
1494 #[prost(enumeration = "BackfillMode", tag = "4")]
1495 pub backfill_mode: i32,
1496}
1497#[derive(Clone, PartialEq, ::prost::Message)]
1498pub struct CreateIngestRuleResponse {
1499 #[prost(message, optional, tag = "1")]
1500 pub rule: ::core::option::Option<IngestRule>,
1501}
1502#[derive(Clone, PartialEq, ::prost::Message)]
1503pub struct ListIngestRulesRequest {
1504 #[prost(string, tag = "1")]
1505 pub drive_rid: ::prost::alloc::string::String,
1506 #[prost(bool, tag = "2")]
1507 pub include_archived: bool,
1508 #[prost(int32, optional, tag = "3")]
1509 pub page_size: ::core::option::Option<i32>,
1510 #[prost(string, optional, tag = "4")]
1511 pub page_token: ::core::option::Option<::prost::alloc::string::String>,
1512}
1513#[derive(Clone, PartialEq, ::prost::Message)]
1514pub struct ListIngestRulesResponse {
1515 #[prost(message, repeated, tag = "1")]
1516 pub rules: ::prost::alloc::vec::Vec<IngestRule>,
1517 #[prost(string, optional, tag = "2")]
1518 pub next_page_token: ::core::option::Option<::prost::alloc::string::String>,
1519}
1520#[derive(Clone, PartialEq, ::prost::Message)]
1521pub struct GetIngestRuleRequest {
1522 #[prost(string, tag = "1")]
1523 pub rule_rid: ::prost::alloc::string::String,
1524}
1525#[derive(Clone, PartialEq, ::prost::Message)]
1526pub struct GetIngestRuleResponse {
1527 #[prost(message, optional, tag = "1")]
1528 pub rule: ::core::option::Option<IngestRule>,
1529}
1530#[derive(Clone, PartialEq, ::prost::Message)]
1531pub struct UpdateIngestRuleRequest {
1532 #[prost(string, tag = "1")]
1533 pub rule_rid: ::prost::alloc::string::String,
1534 #[prost(message, optional, tag = "2")]
1535 pub matcher: ::core::option::Option<FileMatcher>,
1536 #[prost(message, optional, tag = "3")]
1537 pub triggers: ::core::option::Option<IngestTriggers>,
1538}
1539#[derive(Clone, PartialEq, ::prost::Message)]
1540pub struct UpdateIngestRuleResponse {
1541 #[prost(message, optional, tag = "1")]
1542 pub rule: ::core::option::Option<IngestRule>,
1543}
1544#[derive(Clone, PartialEq, ::prost::Message)]
1545pub struct ArchiveIngestRuleRequest {
1546 #[prost(string, tag = "1")]
1547 pub rule_rid: ::prost::alloc::string::String,
1548}
1549#[derive(Clone, PartialEq, ::prost::Message)]
1550pub struct ArchiveIngestRuleResponse {
1551 #[prost(message, optional, tag = "1")]
1552 pub rule: ::core::option::Option<IngestRule>,
1553}
1554#[derive(Clone, PartialEq, ::prost::Message)]
1555pub struct UnarchiveIngestRuleRequest {
1556 #[prost(string, tag = "1")]
1557 pub rule_rid: ::prost::alloc::string::String,
1558 #[prost(enumeration = "BackfillMode", tag = "2")]
1559 pub backfill_mode: i32,
1560}
1561#[derive(Clone, PartialEq, ::prost::Message)]
1562pub struct UnarchiveIngestRuleResponse {
1563 #[prost(message, optional, tag = "1")]
1564 pub rule: ::core::option::Option<IngestRule>,
1565}
1566#[derive(Clone, PartialEq, ::prost::Message)]
1567pub struct IngestRule {
1568 #[prost(string, tag = "1")]
1569 pub rule_rid: ::prost::alloc::string::String,
1570 #[prost(string, tag = "2")]
1571 pub drive_rid: ::prost::alloc::string::String,
1572 #[prost(message, optional, tag = "3")]
1573 pub matcher: ::core::option::Option<FileMatcher>,
1574 #[prost(message, optional, tag = "4")]
1575 pub triggers: ::core::option::Option<IngestTriggers>,
1576 #[prost(message, optional, tag = "5")]
1577 pub created: ::core::option::Option<Attribution>,
1578 #[prost(enumeration = "IngestRuleState", tag = "6")]
1579 pub state: i32,
1580 #[prost(message, optional, tag = "7")]
1581 pub archived: ::core::option::Option<Attribution>,
1582 #[prost(message, optional, tag = "8")]
1583 pub updated: ::core::option::Option<Attribution>,
1584}
1585#[derive(Clone, PartialEq, ::prost::Message)]
1586pub struct FileMatcher {
1587 #[prost(oneof = "file_matcher::Matcher", tags = "1")]
1588 pub matcher: ::core::option::Option<file_matcher::Matcher>,
1589}
1590pub mod file_matcher {
1592 #[derive(Clone, PartialEq, ::prost::Oneof)]
1593 pub enum Matcher {
1594 #[prost(message, tag = "1")]
1595 Path(super::PathMatcher),
1596 }
1597}
1598#[derive(Clone, PartialEq, ::prost::Message)]
1599pub struct PathMatcher {
1600 #[prost(message, optional, tag = "1")]
1601 pub glob: ::core::option::Option<GlobPattern>,
1602}
1603#[derive(Clone, PartialEq, ::prost::Message)]
1604pub struct GlobPattern {
1605 #[prost(message, optional, tag = "1")]
1606 pub first: ::core::option::Option<PatternSegment>,
1607 #[prost(message, repeated, tag = "2")]
1608 pub rest: ::prost::alloc::vec::Vec<JoinedSegment>,
1609}
1610#[derive(Clone, PartialEq, ::prost::Message)]
1611pub struct JoinedSegment {
1612 #[prost(enumeration = "SegmentDelimiter", tag = "1")]
1613 pub delimiter: i32,
1614 #[prost(message, optional, tag = "2")]
1615 pub segment: ::core::option::Option<PatternSegment>,
1616}
1617#[derive(Clone, PartialEq, ::prost::Message)]
1618pub struct PatternSegment {
1619 #[prost(oneof = "pattern_segment::Kind", tags = "1, 2, 3")]
1620 pub kind: ::core::option::Option<pattern_segment::Kind>,
1621}
1622pub mod pattern_segment {
1624 #[derive(Clone, PartialEq, ::prost::Oneof)]
1625 pub enum Kind {
1626 #[prost(message, tag = "1")]
1627 Wildcard(super::Wildcard),
1628 #[prost(message, tag = "2")]
1629 Globstar(super::Globstar),
1630 #[prost(string, tag = "3")]
1631 Literal(::prost::alloc::string::String),
1632 }
1633}
1634#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1635pub struct Wildcard {}
1636#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1637pub struct Globstar {}
1638#[derive(Clone, PartialEq, ::prost::Message)]
1639pub struct IngestTriggers {
1640 #[prost(message, optional, tag = "1")]
1641 pub new_match: ::core::option::Option<IngestTarget>,
1642}
1643#[derive(Clone, PartialEq, ::prost::Message)]
1644pub struct IngestTarget {
1645 #[prost(oneof = "ingest_target::Target", tags = "1, 2")]
1646 pub target: ::core::option::Option<ingest_target::Target>,
1647}
1648pub mod ingest_target {
1650 #[derive(Clone, PartialEq, ::prost::Oneof)]
1651 pub enum Target {
1652 #[prost(message, tag = "1")]
1653 NewDataset(super::NewDatasetTarget),
1654 #[prost(message, tag = "2")]
1655 ExistingDataset(super::ExistingDatasetTarget),
1656 }
1657}
1658#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1659pub struct NewDatasetTarget {}
1660#[derive(Clone, PartialEq, ::prost::Message)]
1661pub struct ExistingDatasetTarget {
1662 #[prost(string, tag = "1")]
1663 pub dataset_rid: ::prost::alloc::string::String,
1664}
1665#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1666#[repr(i32)]
1667pub enum BackfillMode {
1668 Unspecified = 0,
1669 NewFilesOnly = 1,
1670 BackfillExisting = 2,
1671}
1672impl BackfillMode {
1673 pub fn as_str_name(&self) -> &'static str {
1678 match self {
1679 Self::Unspecified => "BACKFILL_MODE_UNSPECIFIED",
1680 Self::NewFilesOnly => "BACKFILL_MODE_NEW_FILES_ONLY",
1681 Self::BackfillExisting => "BACKFILL_MODE_BACKFILL_EXISTING",
1682 }
1683 }
1684 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1686 match value {
1687 "BACKFILL_MODE_UNSPECIFIED" => Some(Self::Unspecified),
1688 "BACKFILL_MODE_NEW_FILES_ONLY" => Some(Self::NewFilesOnly),
1689 "BACKFILL_MODE_BACKFILL_EXISTING" => Some(Self::BackfillExisting),
1690 _ => None,
1691 }
1692 }
1693}
1694#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1695#[repr(i32)]
1696pub enum IngestRuleState {
1697 Unspecified = 0,
1698 Active = 1,
1699 Archived = 2,
1700}
1701impl IngestRuleState {
1702 pub fn as_str_name(&self) -> &'static str {
1707 match self {
1708 Self::Unspecified => "INGEST_RULE_STATE_UNSPECIFIED",
1709 Self::Active => "INGEST_RULE_STATE_ACTIVE",
1710 Self::Archived => "INGEST_RULE_STATE_ARCHIVED",
1711 }
1712 }
1713 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1715 match value {
1716 "INGEST_RULE_STATE_UNSPECIFIED" => Some(Self::Unspecified),
1717 "INGEST_RULE_STATE_ACTIVE" => Some(Self::Active),
1718 "INGEST_RULE_STATE_ARCHIVED" => Some(Self::Archived),
1719 _ => None,
1720 }
1721 }
1722}
1723#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1724#[repr(i32)]
1725pub enum SegmentDelimiter {
1726 Unspecified = 0,
1727 PathSeparator = 1,
1728 Concat = 2,
1729}
1730impl SegmentDelimiter {
1731 pub fn as_str_name(&self) -> &'static str {
1736 match self {
1737 Self::Unspecified => "SEGMENT_DELIMITER_UNSPECIFIED",
1738 Self::PathSeparator => "SEGMENT_DELIMITER_PATH_SEPARATOR",
1739 Self::Concat => "SEGMENT_DELIMITER_CONCAT",
1740 }
1741 }
1742 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1744 match value {
1745 "SEGMENT_DELIMITER_UNSPECIFIED" => Some(Self::Unspecified),
1746 "SEGMENT_DELIMITER_PATH_SEPARATOR" => Some(Self::PathSeparator),
1747 "SEGMENT_DELIMITER_CONCAT" => Some(Self::Concat),
1748 _ => None,
1749 }
1750 }
1751}
1752pub mod internal_ingest_rules_service_client {
1754 #![allow(
1755 unused_variables,
1756 dead_code,
1757 missing_docs,
1758 clippy::wildcard_imports,
1759 clippy::let_unit_value,
1760 )]
1761 use tonic::codegen::*;
1762 use tonic::codegen::http::Uri;
1763 #[derive(Debug, Clone)]
1764 pub struct InternalIngestRulesServiceClient<T> {
1765 inner: tonic::client::Grpc<T>,
1766 }
1767 impl InternalIngestRulesServiceClient<tonic::transport::Channel> {
1768 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
1770 where
1771 D: TryInto<tonic::transport::Endpoint>,
1772 D::Error: Into<StdError>,
1773 {
1774 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
1775 Ok(Self::new(conn))
1776 }
1777 }
1778 impl<T> InternalIngestRulesServiceClient<T>
1779 where
1780 T: tonic::client::GrpcService<tonic::body::Body>,
1781 T::Error: Into<StdError>,
1782 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
1783 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
1784 {
1785 pub fn new(inner: T) -> Self {
1786 let inner = tonic::client::Grpc::new(inner);
1787 Self { inner }
1788 }
1789 pub fn with_origin(inner: T, origin: Uri) -> Self {
1790 let inner = tonic::client::Grpc::with_origin(inner, origin);
1791 Self { inner }
1792 }
1793 pub fn with_interceptor<F>(
1794 inner: T,
1795 interceptor: F,
1796 ) -> InternalIngestRulesServiceClient<InterceptedService<T, F>>
1797 where
1798 F: tonic::service::Interceptor,
1799 T::ResponseBody: Default,
1800 T: tonic::codegen::Service<
1801 http::Request<tonic::body::Body>,
1802 Response = http::Response<
1803 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
1804 >,
1805 >,
1806 <T as tonic::codegen::Service<
1807 http::Request<tonic::body::Body>,
1808 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
1809 {
1810 InternalIngestRulesServiceClient::new(
1811 InterceptedService::new(inner, interceptor),
1812 )
1813 }
1814 #[must_use]
1819 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
1820 self.inner = self.inner.send_compressed(encoding);
1821 self
1822 }
1823 #[must_use]
1825 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
1826 self.inner = self.inner.accept_compressed(encoding);
1827 self
1828 }
1829 #[must_use]
1833 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
1834 self.inner = self.inner.max_decoding_message_size(limit);
1835 self
1836 }
1837 #[must_use]
1841 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
1842 self.inner = self.inner.max_encoding_message_size(limit);
1843 self
1844 }
1845 pub async fn create_ingest_rule(
1846 &mut self,
1847 request: impl tonic::IntoRequest<super::CreateIngestRuleRequest>,
1848 ) -> std::result::Result<
1849 tonic::Response<super::CreateIngestRuleResponse>,
1850 tonic::Status,
1851 > {
1852 self.inner
1853 .ready()
1854 .await
1855 .map_err(|e| {
1856 tonic::Status::unknown(
1857 format!("Service was not ready: {}", e.into()),
1858 )
1859 })?;
1860 let codec = tonic::codec::ProstCodec::default();
1861 let path = http::uri::PathAndQuery::from_static(
1862 "/nominal.file_store.v1.InternalIngestRulesService/CreateIngestRule",
1863 );
1864 let mut req = request.into_request();
1865 req.extensions_mut()
1866 .insert(
1867 GrpcMethod::new(
1868 "nominal.file_store.v1.InternalIngestRulesService",
1869 "CreateIngestRule",
1870 ),
1871 );
1872 self.inner.unary(req, path, codec).await
1873 }
1874 pub async fn list_ingest_rules(
1875 &mut self,
1876 request: impl tonic::IntoRequest<super::ListIngestRulesRequest>,
1877 ) -> std::result::Result<
1878 tonic::Response<super::ListIngestRulesResponse>,
1879 tonic::Status,
1880 > {
1881 self.inner
1882 .ready()
1883 .await
1884 .map_err(|e| {
1885 tonic::Status::unknown(
1886 format!("Service was not ready: {}", e.into()),
1887 )
1888 })?;
1889 let codec = tonic::codec::ProstCodec::default();
1890 let path = http::uri::PathAndQuery::from_static(
1891 "/nominal.file_store.v1.InternalIngestRulesService/ListIngestRules",
1892 );
1893 let mut req = request.into_request();
1894 req.extensions_mut()
1895 .insert(
1896 GrpcMethod::new(
1897 "nominal.file_store.v1.InternalIngestRulesService",
1898 "ListIngestRules",
1899 ),
1900 );
1901 self.inner.unary(req, path, codec).await
1902 }
1903 pub async fn get_ingest_rule(
1904 &mut self,
1905 request: impl tonic::IntoRequest<super::GetIngestRuleRequest>,
1906 ) -> std::result::Result<
1907 tonic::Response<super::GetIngestRuleResponse>,
1908 tonic::Status,
1909 > {
1910 self.inner
1911 .ready()
1912 .await
1913 .map_err(|e| {
1914 tonic::Status::unknown(
1915 format!("Service was not ready: {}", e.into()),
1916 )
1917 })?;
1918 let codec = tonic::codec::ProstCodec::default();
1919 let path = http::uri::PathAndQuery::from_static(
1920 "/nominal.file_store.v1.InternalIngestRulesService/GetIngestRule",
1921 );
1922 let mut req = request.into_request();
1923 req.extensions_mut()
1924 .insert(
1925 GrpcMethod::new(
1926 "nominal.file_store.v1.InternalIngestRulesService",
1927 "GetIngestRule",
1928 ),
1929 );
1930 self.inner.unary(req, path, codec).await
1931 }
1932 pub async fn update_ingest_rule(
1933 &mut self,
1934 request: impl tonic::IntoRequest<super::UpdateIngestRuleRequest>,
1935 ) -> std::result::Result<
1936 tonic::Response<super::UpdateIngestRuleResponse>,
1937 tonic::Status,
1938 > {
1939 self.inner
1940 .ready()
1941 .await
1942 .map_err(|e| {
1943 tonic::Status::unknown(
1944 format!("Service was not ready: {}", e.into()),
1945 )
1946 })?;
1947 let codec = tonic::codec::ProstCodec::default();
1948 let path = http::uri::PathAndQuery::from_static(
1949 "/nominal.file_store.v1.InternalIngestRulesService/UpdateIngestRule",
1950 );
1951 let mut req = request.into_request();
1952 req.extensions_mut()
1953 .insert(
1954 GrpcMethod::new(
1955 "nominal.file_store.v1.InternalIngestRulesService",
1956 "UpdateIngestRule",
1957 ),
1958 );
1959 self.inner.unary(req, path, codec).await
1960 }
1961 pub async fn archive_ingest_rule(
1962 &mut self,
1963 request: impl tonic::IntoRequest<super::ArchiveIngestRuleRequest>,
1964 ) -> std::result::Result<
1965 tonic::Response<super::ArchiveIngestRuleResponse>,
1966 tonic::Status,
1967 > {
1968 self.inner
1969 .ready()
1970 .await
1971 .map_err(|e| {
1972 tonic::Status::unknown(
1973 format!("Service was not ready: {}", e.into()),
1974 )
1975 })?;
1976 let codec = tonic::codec::ProstCodec::default();
1977 let path = http::uri::PathAndQuery::from_static(
1978 "/nominal.file_store.v1.InternalIngestRulesService/ArchiveIngestRule",
1979 );
1980 let mut req = request.into_request();
1981 req.extensions_mut()
1982 .insert(
1983 GrpcMethod::new(
1984 "nominal.file_store.v1.InternalIngestRulesService",
1985 "ArchiveIngestRule",
1986 ),
1987 );
1988 self.inner.unary(req, path, codec).await
1989 }
1990 pub async fn unarchive_ingest_rule(
1991 &mut self,
1992 request: impl tonic::IntoRequest<super::UnarchiveIngestRuleRequest>,
1993 ) -> std::result::Result<
1994 tonic::Response<super::UnarchiveIngestRuleResponse>,
1995 tonic::Status,
1996 > {
1997 self.inner
1998 .ready()
1999 .await
2000 .map_err(|e| {
2001 tonic::Status::unknown(
2002 format!("Service was not ready: {}", e.into()),
2003 )
2004 })?;
2005 let codec = tonic::codec::ProstCodec::default();
2006 let path = http::uri::PathAndQuery::from_static(
2007 "/nominal.file_store.v1.InternalIngestRulesService/UnarchiveIngestRule",
2008 );
2009 let mut req = request.into_request();
2010 req.extensions_mut()
2011 .insert(
2012 GrpcMethod::new(
2013 "nominal.file_store.v1.InternalIngestRulesService",
2014 "UnarchiveIngestRule",
2015 ),
2016 );
2017 self.inner.unary(req, path, codec).await
2018 }
2019 }
2020}