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}
398impl FileStoreError {
399 pub fn as_str_name(&self) -> &'static str {
404 match self {
405 Self::Unspecified => "FILE_STORE_ERROR_UNSPECIFIED",
406 Self::DriveNotFound => "FILE_STORE_ERROR_DRIVE_NOT_FOUND",
407 Self::FileNotFound => "FILE_STORE_ERROR_FILE_NOT_FOUND",
408 Self::FileRevisionNotFound => "FILE_STORE_ERROR_FILE_REVISION_NOT_FOUND",
409 Self::PathAlreadyExists => "FILE_STORE_ERROR_PATH_ALREADY_EXISTS",
410 Self::InvalidLogicalPath => "FILE_STORE_ERROR_INVALID_LOGICAL_PATH",
411 Self::PermissionDenied => "FILE_STORE_ERROR_PERMISSION_DENIED",
412 Self::RevisionPreconditionFailed => {
413 "FILE_STORE_ERROR_REVISION_PRECONDITION_FAILED"
414 }
415 Self::VirtualDriveNotFound => "FILE_STORE_ERROR_VIRTUAL_DRIVE_NOT_FOUND",
416 Self::InvalidVirtualDriveConfiguration => {
417 "FILE_STORE_ERROR_INVALID_VIRTUAL_DRIVE_CONFIGURATION"
418 }
419 Self::ReadOnlyDrive => "FILE_STORE_ERROR_READ_ONLY_DRIVE",
420 Self::FileHistoryNotAvailable => {
421 "FILE_STORE_ERROR_FILE_HISTORY_NOT_AVAILABLE"
422 }
423 Self::UpstreamUnavailable => "FILE_STORE_ERROR_UPSTREAM_UNAVAILABLE",
424 Self::RevisionBytesReclaimed => "FILE_STORE_ERROR_REVISION_BYTES_RECLAIMED",
425 Self::UpstreamFileNotFound => "FILE_STORE_ERROR_UPSTREAM_FILE_NOT_FOUND",
426 Self::DriveIdAlreadyExists => "FILE_STORE_ERROR_DRIVE_ID_ALREADY_EXISTS",
427 Self::VirtualDriveCredentialsNotFound => {
428 "FILE_STORE_ERROR_VIRTUAL_DRIVE_CREDENTIALS_NOT_FOUND"
429 }
430 Self::VirtualDriveCredentialsInvalid => {
431 "FILE_STORE_ERROR_VIRTUAL_DRIVE_CREDENTIALS_INVALID"
432 }
433 Self::VirtualDriveCredentialsRejected => {
434 "FILE_STORE_ERROR_VIRTUAL_DRIVE_CREDENTIALS_REJECTED"
435 }
436 Self::MaterializationFailed => "FILE_STORE_ERROR_MATERIALIZATION_FAILED",
437 Self::IngestRuleNotFound => "FILE_STORE_ERROR_INGEST_RULE_NOT_FOUND",
438 }
439 }
440 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
442 match value {
443 "FILE_STORE_ERROR_UNSPECIFIED" => Some(Self::Unspecified),
444 "FILE_STORE_ERROR_DRIVE_NOT_FOUND" => Some(Self::DriveNotFound),
445 "FILE_STORE_ERROR_FILE_NOT_FOUND" => Some(Self::FileNotFound),
446 "FILE_STORE_ERROR_FILE_REVISION_NOT_FOUND" => {
447 Some(Self::FileRevisionNotFound)
448 }
449 "FILE_STORE_ERROR_PATH_ALREADY_EXISTS" => Some(Self::PathAlreadyExists),
450 "FILE_STORE_ERROR_INVALID_LOGICAL_PATH" => Some(Self::InvalidLogicalPath),
451 "FILE_STORE_ERROR_PERMISSION_DENIED" => Some(Self::PermissionDenied),
452 "FILE_STORE_ERROR_REVISION_PRECONDITION_FAILED" => {
453 Some(Self::RevisionPreconditionFailed)
454 }
455 "FILE_STORE_ERROR_VIRTUAL_DRIVE_NOT_FOUND" => {
456 Some(Self::VirtualDriveNotFound)
457 }
458 "FILE_STORE_ERROR_INVALID_VIRTUAL_DRIVE_CONFIGURATION" => {
459 Some(Self::InvalidVirtualDriveConfiguration)
460 }
461 "FILE_STORE_ERROR_READ_ONLY_DRIVE" => Some(Self::ReadOnlyDrive),
462 "FILE_STORE_ERROR_FILE_HISTORY_NOT_AVAILABLE" => {
463 Some(Self::FileHistoryNotAvailable)
464 }
465 "FILE_STORE_ERROR_UPSTREAM_UNAVAILABLE" => Some(Self::UpstreamUnavailable),
466 "FILE_STORE_ERROR_REVISION_BYTES_RECLAIMED" => {
467 Some(Self::RevisionBytesReclaimed)
468 }
469 "FILE_STORE_ERROR_UPSTREAM_FILE_NOT_FOUND" => {
470 Some(Self::UpstreamFileNotFound)
471 }
472 "FILE_STORE_ERROR_DRIVE_ID_ALREADY_EXISTS" => {
473 Some(Self::DriveIdAlreadyExists)
474 }
475 "FILE_STORE_ERROR_VIRTUAL_DRIVE_CREDENTIALS_NOT_FOUND" => {
476 Some(Self::VirtualDriveCredentialsNotFound)
477 }
478 "FILE_STORE_ERROR_VIRTUAL_DRIVE_CREDENTIALS_INVALID" => {
479 Some(Self::VirtualDriveCredentialsInvalid)
480 }
481 "FILE_STORE_ERROR_VIRTUAL_DRIVE_CREDENTIALS_REJECTED" => {
482 Some(Self::VirtualDriveCredentialsRejected)
483 }
484 "FILE_STORE_ERROR_MATERIALIZATION_FAILED" => {
485 Some(Self::MaterializationFailed)
486 }
487 "FILE_STORE_ERROR_INGEST_RULE_NOT_FOUND" => Some(Self::IngestRuleNotFound),
488 _ => None,
489 }
490 }
491}
492#[derive(Clone, PartialEq, ::prost::Message)]
493pub struct CreateDriveRequest {
494 #[prost(string, tag = "1")]
495 pub workspace_rid: ::prost::alloc::string::String,
496 #[prost(string, tag = "2")]
497 pub id: ::prost::alloc::string::String,
498}
499#[derive(Clone, PartialEq, ::prost::Message)]
500pub struct CreateDriveResponse {
501 #[prost(message, optional, tag = "1")]
502 pub drive: ::core::option::Option<Drive>,
503}
504#[derive(Clone, PartialEq, ::prost::Message)]
505pub struct CreateVirtualDriveRequest {
506 #[prost(string, tag = "1")]
507 pub workspace_rid: ::prost::alloc::string::String,
508 #[prost(string, tag = "2")]
509 pub id: ::prost::alloc::string::String,
510 #[prost(message, optional, tag = "3")]
511 pub connection_details: ::core::option::Option<VirtualDriveConnectionDetails>,
512}
513#[derive(Clone, PartialEq, ::prost::Message)]
514pub struct CreateVirtualDriveResponse {
515 #[prost(message, optional, tag = "1")]
516 pub drive: ::core::option::Option<Drive>,
517 #[prost(message, optional, tag = "2")]
518 pub virtual_drive: ::core::option::Option<VirtualDrive>,
519}
520#[derive(Clone, PartialEq, ::prost::Message)]
521pub struct GetDriveRequest {
522 #[prost(string, tag = "1")]
523 pub drive_rid: ::prost::alloc::string::String,
524}
525#[derive(Clone, PartialEq, ::prost::Message)]
526pub struct GetDriveResponse {
527 #[prost(message, optional, tag = "1")]
528 pub drive: ::core::option::Option<Drive>,
529}
530#[derive(Clone, PartialEq, ::prost::Message)]
531pub struct GetVirtualDriveRequest {
532 #[prost(string, tag = "1")]
533 pub drive_rid: ::prost::alloc::string::String,
534}
535#[derive(Clone, PartialEq, ::prost::Message)]
536pub struct GetVirtualDriveResponse {
537 #[prost(message, optional, tag = "1")]
538 pub drive: ::core::option::Option<Drive>,
539 #[prost(message, optional, tag = "2")]
540 pub virtual_drive: ::core::option::Option<VirtualDrive>,
541}
542#[derive(Clone, PartialEq, ::prost::Message)]
543pub struct GetDriveByIdRequest {
544 #[prost(string, tag = "1")]
545 pub workspace_rid: ::prost::alloc::string::String,
546 #[prost(string, tag = "2")]
547 pub id: ::prost::alloc::string::String,
548}
549#[derive(Clone, PartialEq, ::prost::Message)]
550pub struct GetDriveByIdResponse {
551 #[prost(message, optional, tag = "1")]
552 pub drive: ::core::option::Option<Drive>,
553}
554#[derive(Clone, PartialEq, ::prost::Message)]
555pub struct GetVirtualDriveByIdRequest {
556 #[prost(string, tag = "1")]
557 pub workspace_rid: ::prost::alloc::string::String,
558 #[prost(string, tag = "2")]
559 pub id: ::prost::alloc::string::String,
560}
561#[derive(Clone, PartialEq, ::prost::Message)]
562pub struct GetVirtualDriveByIdResponse {
563 #[prost(message, optional, tag = "1")]
564 pub drive: ::core::option::Option<Drive>,
565 #[prost(message, optional, tag = "2")]
566 pub virtual_drive: ::core::option::Option<VirtualDrive>,
567}
568#[derive(Clone, PartialEq, ::prost::Message)]
569pub struct ListDrivesRequest {
570 #[prost(string, tag = "1")]
571 pub workspace_rid: ::prost::alloc::string::String,
572 #[prost(bool, tag = "2")]
573 pub include_archived: bool,
574 #[prost(int32, optional, tag = "3")]
575 pub page_size: ::core::option::Option<i32>,
576 #[prost(string, optional, tag = "4")]
577 pub page_token: ::core::option::Option<::prost::alloc::string::String>,
578}
579#[derive(Clone, PartialEq, ::prost::Message)]
580pub struct ListDrivesResponse {
581 #[prost(message, repeated, tag = "1")]
582 pub drives: ::prost::alloc::vec::Vec<Drive>,
583 #[prost(string, optional, tag = "2")]
584 pub next_page_token: ::core::option::Option<::prost::alloc::string::String>,
585}
586#[derive(Clone, PartialEq, ::prost::Message)]
587pub struct UpdateVirtualDriveRequest {
588 #[prost(string, tag = "1")]
589 pub drive_rid: ::prost::alloc::string::String,
590 #[prost(message, optional, tag = "2")]
591 pub connection_details: ::core::option::Option<VirtualDriveConnectionDetails>,
592}
593#[derive(Clone, PartialEq, ::prost::Message)]
594pub struct UpdateVirtualDriveResponse {
595 #[prost(message, optional, tag = "1")]
596 pub drive: ::core::option::Option<Drive>,
597 #[prost(message, optional, tag = "2")]
598 pub virtual_drive: ::core::option::Option<VirtualDrive>,
599}
600#[derive(Clone, PartialEq, ::prost::Message)]
601pub struct UpdateDriveDetailsRequest {
602 #[prost(string, tag = "1")]
603 pub drive_rid: ::prost::alloc::string::String,
604 #[prost(string, optional, tag = "2")]
605 pub id: ::core::option::Option<::prost::alloc::string::String>,
606}
607#[derive(Clone, PartialEq, ::prost::Message)]
608pub struct UpdateDriveDetailsResponse {
609 #[prost(message, optional, tag = "1")]
610 pub drive: ::core::option::Option<Drive>,
611}
612#[derive(Clone, PartialEq, ::prost::Message)]
613pub struct ArchiveDriveRequest {
614 #[prost(string, tag = "1")]
615 pub drive_rid: ::prost::alloc::string::String,
616}
617#[derive(Clone, PartialEq, ::prost::Message)]
618pub struct ArchiveDriveResponse {
619 #[prost(message, optional, tag = "1")]
620 pub drive: ::core::option::Option<Drive>,
621}
622#[derive(Clone, PartialEq, ::prost::Message)]
623pub struct UnarchiveDriveRequest {
624 #[prost(string, tag = "1")]
625 pub drive_rid: ::prost::alloc::string::String,
626}
627#[derive(Clone, PartialEq, ::prost::Message)]
628pub struct UnarchiveDriveResponse {
629 #[prost(message, optional, tag = "1")]
630 pub drive: ::core::option::Option<Drive>,
631}
632pub mod internal_drives_service_client {
634 #![allow(
635 unused_variables,
636 dead_code,
637 missing_docs,
638 clippy::wildcard_imports,
639 clippy::let_unit_value,
640 )]
641 use tonic::codegen::*;
642 use tonic::codegen::http::Uri;
643 #[derive(Debug, Clone)]
644 pub struct InternalDrivesServiceClient<T> {
645 inner: tonic::client::Grpc<T>,
646 }
647 impl InternalDrivesServiceClient<tonic::transport::Channel> {
648 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
650 where
651 D: TryInto<tonic::transport::Endpoint>,
652 D::Error: Into<StdError>,
653 {
654 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
655 Ok(Self::new(conn))
656 }
657 }
658 impl<T> InternalDrivesServiceClient<T>
659 where
660 T: tonic::client::GrpcService<tonic::body::Body>,
661 T::Error: Into<StdError>,
662 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
663 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
664 {
665 pub fn new(inner: T) -> Self {
666 let inner = tonic::client::Grpc::new(inner);
667 Self { inner }
668 }
669 pub fn with_origin(inner: T, origin: Uri) -> Self {
670 let inner = tonic::client::Grpc::with_origin(inner, origin);
671 Self { inner }
672 }
673 pub fn with_interceptor<F>(
674 inner: T,
675 interceptor: F,
676 ) -> InternalDrivesServiceClient<InterceptedService<T, F>>
677 where
678 F: tonic::service::Interceptor,
679 T::ResponseBody: Default,
680 T: tonic::codegen::Service<
681 http::Request<tonic::body::Body>,
682 Response = http::Response<
683 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
684 >,
685 >,
686 <T as tonic::codegen::Service<
687 http::Request<tonic::body::Body>,
688 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
689 {
690 InternalDrivesServiceClient::new(InterceptedService::new(inner, interceptor))
691 }
692 #[must_use]
697 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
698 self.inner = self.inner.send_compressed(encoding);
699 self
700 }
701 #[must_use]
703 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
704 self.inner = self.inner.accept_compressed(encoding);
705 self
706 }
707 #[must_use]
711 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
712 self.inner = self.inner.max_decoding_message_size(limit);
713 self
714 }
715 #[must_use]
719 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
720 self.inner = self.inner.max_encoding_message_size(limit);
721 self
722 }
723 pub async fn create_drive(
724 &mut self,
725 request: impl tonic::IntoRequest<super::CreateDriveRequest>,
726 ) -> std::result::Result<
727 tonic::Response<super::CreateDriveResponse>,
728 tonic::Status,
729 > {
730 self.inner
731 .ready()
732 .await
733 .map_err(|e| {
734 tonic::Status::unknown(
735 format!("Service was not ready: {}", e.into()),
736 )
737 })?;
738 let codec = tonic::codec::ProstCodec::default();
739 let path = http::uri::PathAndQuery::from_static(
740 "/nominal.file_store.v1.InternalDrivesService/CreateDrive",
741 );
742 let mut req = request.into_request();
743 req.extensions_mut()
744 .insert(
745 GrpcMethod::new(
746 "nominal.file_store.v1.InternalDrivesService",
747 "CreateDrive",
748 ),
749 );
750 self.inner.unary(req, path, codec).await
751 }
752 pub async fn create_virtual_drive(
753 &mut self,
754 request: impl tonic::IntoRequest<super::CreateVirtualDriveRequest>,
755 ) -> std::result::Result<
756 tonic::Response<super::CreateVirtualDriveResponse>,
757 tonic::Status,
758 > {
759 self.inner
760 .ready()
761 .await
762 .map_err(|e| {
763 tonic::Status::unknown(
764 format!("Service was not ready: {}", e.into()),
765 )
766 })?;
767 let codec = tonic::codec::ProstCodec::default();
768 let path = http::uri::PathAndQuery::from_static(
769 "/nominal.file_store.v1.InternalDrivesService/CreateVirtualDrive",
770 );
771 let mut req = request.into_request();
772 req.extensions_mut()
773 .insert(
774 GrpcMethod::new(
775 "nominal.file_store.v1.InternalDrivesService",
776 "CreateVirtualDrive",
777 ),
778 );
779 self.inner.unary(req, path, codec).await
780 }
781 pub async fn get_drive(
782 &mut self,
783 request: impl tonic::IntoRequest<super::GetDriveRequest>,
784 ) -> std::result::Result<
785 tonic::Response<super::GetDriveResponse>,
786 tonic::Status,
787 > {
788 self.inner
789 .ready()
790 .await
791 .map_err(|e| {
792 tonic::Status::unknown(
793 format!("Service was not ready: {}", e.into()),
794 )
795 })?;
796 let codec = tonic::codec::ProstCodec::default();
797 let path = http::uri::PathAndQuery::from_static(
798 "/nominal.file_store.v1.InternalDrivesService/GetDrive",
799 );
800 let mut req = request.into_request();
801 req.extensions_mut()
802 .insert(
803 GrpcMethod::new(
804 "nominal.file_store.v1.InternalDrivesService",
805 "GetDrive",
806 ),
807 );
808 self.inner.unary(req, path, codec).await
809 }
810 pub async fn get_virtual_drive(
811 &mut self,
812 request: impl tonic::IntoRequest<super::GetVirtualDriveRequest>,
813 ) -> std::result::Result<
814 tonic::Response<super::GetVirtualDriveResponse>,
815 tonic::Status,
816 > {
817 self.inner
818 .ready()
819 .await
820 .map_err(|e| {
821 tonic::Status::unknown(
822 format!("Service was not ready: {}", e.into()),
823 )
824 })?;
825 let codec = tonic::codec::ProstCodec::default();
826 let path = http::uri::PathAndQuery::from_static(
827 "/nominal.file_store.v1.InternalDrivesService/GetVirtualDrive",
828 );
829 let mut req = request.into_request();
830 req.extensions_mut()
831 .insert(
832 GrpcMethod::new(
833 "nominal.file_store.v1.InternalDrivesService",
834 "GetVirtualDrive",
835 ),
836 );
837 self.inner.unary(req, path, codec).await
838 }
839 pub async fn get_drive_by_id(
840 &mut self,
841 request: impl tonic::IntoRequest<super::GetDriveByIdRequest>,
842 ) -> std::result::Result<
843 tonic::Response<super::GetDriveByIdResponse>,
844 tonic::Status,
845 > {
846 self.inner
847 .ready()
848 .await
849 .map_err(|e| {
850 tonic::Status::unknown(
851 format!("Service was not ready: {}", e.into()),
852 )
853 })?;
854 let codec = tonic::codec::ProstCodec::default();
855 let path = http::uri::PathAndQuery::from_static(
856 "/nominal.file_store.v1.InternalDrivesService/GetDriveById",
857 );
858 let mut req = request.into_request();
859 req.extensions_mut()
860 .insert(
861 GrpcMethod::new(
862 "nominal.file_store.v1.InternalDrivesService",
863 "GetDriveById",
864 ),
865 );
866 self.inner.unary(req, path, codec).await
867 }
868 pub async fn get_virtual_drive_by_id(
869 &mut self,
870 request: impl tonic::IntoRequest<super::GetVirtualDriveByIdRequest>,
871 ) -> std::result::Result<
872 tonic::Response<super::GetVirtualDriveByIdResponse>,
873 tonic::Status,
874 > {
875 self.inner
876 .ready()
877 .await
878 .map_err(|e| {
879 tonic::Status::unknown(
880 format!("Service was not ready: {}", e.into()),
881 )
882 })?;
883 let codec = tonic::codec::ProstCodec::default();
884 let path = http::uri::PathAndQuery::from_static(
885 "/nominal.file_store.v1.InternalDrivesService/GetVirtualDriveById",
886 );
887 let mut req = request.into_request();
888 req.extensions_mut()
889 .insert(
890 GrpcMethod::new(
891 "nominal.file_store.v1.InternalDrivesService",
892 "GetVirtualDriveById",
893 ),
894 );
895 self.inner.unary(req, path, codec).await
896 }
897 pub async fn list_drives(
898 &mut self,
899 request: impl tonic::IntoRequest<super::ListDrivesRequest>,
900 ) -> std::result::Result<
901 tonic::Response<super::ListDrivesResponse>,
902 tonic::Status,
903 > {
904 self.inner
905 .ready()
906 .await
907 .map_err(|e| {
908 tonic::Status::unknown(
909 format!("Service was not ready: {}", e.into()),
910 )
911 })?;
912 let codec = tonic::codec::ProstCodec::default();
913 let path = http::uri::PathAndQuery::from_static(
914 "/nominal.file_store.v1.InternalDrivesService/ListDrives",
915 );
916 let mut req = request.into_request();
917 req.extensions_mut()
918 .insert(
919 GrpcMethod::new(
920 "nominal.file_store.v1.InternalDrivesService",
921 "ListDrives",
922 ),
923 );
924 self.inner.unary(req, path, codec).await
925 }
926 pub async fn update_virtual_drive(
927 &mut self,
928 request: impl tonic::IntoRequest<super::UpdateVirtualDriveRequest>,
929 ) -> std::result::Result<
930 tonic::Response<super::UpdateVirtualDriveResponse>,
931 tonic::Status,
932 > {
933 self.inner
934 .ready()
935 .await
936 .map_err(|e| {
937 tonic::Status::unknown(
938 format!("Service was not ready: {}", e.into()),
939 )
940 })?;
941 let codec = tonic::codec::ProstCodec::default();
942 let path = http::uri::PathAndQuery::from_static(
943 "/nominal.file_store.v1.InternalDrivesService/UpdateVirtualDrive",
944 );
945 let mut req = request.into_request();
946 req.extensions_mut()
947 .insert(
948 GrpcMethod::new(
949 "nominal.file_store.v1.InternalDrivesService",
950 "UpdateVirtualDrive",
951 ),
952 );
953 self.inner.unary(req, path, codec).await
954 }
955 pub async fn update_drive_details(
956 &mut self,
957 request: impl tonic::IntoRequest<super::UpdateDriveDetailsRequest>,
958 ) -> std::result::Result<
959 tonic::Response<super::UpdateDriveDetailsResponse>,
960 tonic::Status,
961 > {
962 self.inner
963 .ready()
964 .await
965 .map_err(|e| {
966 tonic::Status::unknown(
967 format!("Service was not ready: {}", e.into()),
968 )
969 })?;
970 let codec = tonic::codec::ProstCodec::default();
971 let path = http::uri::PathAndQuery::from_static(
972 "/nominal.file_store.v1.InternalDrivesService/UpdateDriveDetails",
973 );
974 let mut req = request.into_request();
975 req.extensions_mut()
976 .insert(
977 GrpcMethod::new(
978 "nominal.file_store.v1.InternalDrivesService",
979 "UpdateDriveDetails",
980 ),
981 );
982 self.inner.unary(req, path, codec).await
983 }
984 pub async fn archive_drive(
985 &mut self,
986 request: impl tonic::IntoRequest<super::ArchiveDriveRequest>,
987 ) -> std::result::Result<
988 tonic::Response<super::ArchiveDriveResponse>,
989 tonic::Status,
990 > {
991 self.inner
992 .ready()
993 .await
994 .map_err(|e| {
995 tonic::Status::unknown(
996 format!("Service was not ready: {}", e.into()),
997 )
998 })?;
999 let codec = tonic::codec::ProstCodec::default();
1000 let path = http::uri::PathAndQuery::from_static(
1001 "/nominal.file_store.v1.InternalDrivesService/ArchiveDrive",
1002 );
1003 let mut req = request.into_request();
1004 req.extensions_mut()
1005 .insert(
1006 GrpcMethod::new(
1007 "nominal.file_store.v1.InternalDrivesService",
1008 "ArchiveDrive",
1009 ),
1010 );
1011 self.inner.unary(req, path, codec).await
1012 }
1013 pub async fn unarchive_drive(
1014 &mut self,
1015 request: impl tonic::IntoRequest<super::UnarchiveDriveRequest>,
1016 ) -> std::result::Result<
1017 tonic::Response<super::UnarchiveDriveResponse>,
1018 tonic::Status,
1019 > {
1020 self.inner
1021 .ready()
1022 .await
1023 .map_err(|e| {
1024 tonic::Status::unknown(
1025 format!("Service was not ready: {}", e.into()),
1026 )
1027 })?;
1028 let codec = tonic::codec::ProstCodec::default();
1029 let path = http::uri::PathAndQuery::from_static(
1030 "/nominal.file_store.v1.InternalDrivesService/UnarchiveDrive",
1031 );
1032 let mut req = request.into_request();
1033 req.extensions_mut()
1034 .insert(
1035 GrpcMethod::new(
1036 "nominal.file_store.v1.InternalDrivesService",
1037 "UnarchiveDrive",
1038 ),
1039 );
1040 self.inner.unary(req, path, codec).await
1041 }
1042 }
1043}
1044#[derive(Clone, PartialEq, ::prost::Message)]
1045pub struct UploadedObjectRef {
1046 #[prost(string, tag = "1")]
1047 pub s3_path: ::prost::alloc::string::String,
1048}
1049#[derive(Clone, PartialEq, ::prost::Message)]
1050pub struct PathTarget {
1051 #[prost(message, optional, tag = "1")]
1052 pub path: ::core::option::Option<LogicalPath>,
1053}
1054#[derive(Clone, PartialEq, ::prost::Message)]
1055pub struct Destination {
1056 #[prost(oneof = "destination::Target", tags = "1, 2")]
1057 pub target: ::core::option::Option<destination::Target>,
1058}
1059pub mod destination {
1061 #[derive(Clone, PartialEq, ::prost::Oneof)]
1062 pub enum Target {
1063 #[prost(message, tag = "1")]
1064 Path(super::PathTarget),
1065 #[prost(string, tag = "2")]
1066 FileRevisionRid(::prost::alloc::string::String),
1067 }
1068}
1069#[derive(Clone, PartialEq, ::prost::Message)]
1070pub struct PutFile {
1071 #[prost(message, optional, tag = "1")]
1072 pub object: ::core::option::Option<UploadedObjectRef>,
1073 #[prost(uint64, tag = "2")]
1074 pub size_bytes: u64,
1075 #[prost(message, optional, tag = "3")]
1076 pub destination: ::core::option::Option<Destination>,
1077}
1078#[derive(Clone, PartialEq, ::prost::Message)]
1079pub struct MoveFile {
1080 #[prost(string, tag = "1")]
1081 pub source_revision_rid: ::prost::alloc::string::String,
1082 #[prost(message, optional, tag = "2")]
1083 pub destination: ::core::option::Option<Destination>,
1084}
1085#[derive(Clone, PartialEq, ::prost::Message)]
1086pub struct RemoveFile {
1087 #[prost(string, tag = "1")]
1088 pub revision_rid: ::prost::alloc::string::String,
1089}
1090#[derive(Clone, PartialEq, ::prost::Message)]
1091pub struct RestoreFile {
1092 #[prost(string, tag = "1")]
1093 pub restore_revision_rid: ::prost::alloc::string::String,
1094 #[prost(message, optional, tag = "2")]
1095 pub destination: ::core::option::Option<Destination>,
1096}
1097#[derive(Clone, PartialEq, ::prost::Message)]
1098pub struct FileChange {
1099 #[prost(oneof = "file_change::Change", tags = "1, 2, 3, 4")]
1100 pub change: ::core::option::Option<file_change::Change>,
1101}
1102pub mod file_change {
1104 #[derive(Clone, PartialEq, ::prost::Oneof)]
1105 pub enum Change {
1106 #[prost(message, tag = "1")]
1107 Put(super::PutFile),
1108 #[prost(message, tag = "2")]
1109 Move(super::MoveFile),
1110 #[prost(message, tag = "3")]
1111 Remove(super::RemoveFile),
1112 #[prost(message, tag = "4")]
1113 Restore(super::RestoreFile),
1114 }
1115}
1116#[derive(Clone, PartialEq, ::prost::Message)]
1117pub struct GetFileRequest {
1118 #[prost(string, tag = "1")]
1119 pub drive_rid: ::prost::alloc::string::String,
1120 #[prost(message, optional, tag = "2")]
1121 pub path: ::core::option::Option<LogicalPath>,
1122 #[prost(bool, tag = "3")]
1123 pub include_removed: bool,
1124}
1125#[derive(Clone, PartialEq, ::prost::Message)]
1126pub struct GetFileResponse {
1127 #[prost(message, optional, tag = "1")]
1128 pub file: ::core::option::Option<LogicalFile>,
1129}
1130#[derive(Clone, PartialEq, ::prost::Message)]
1131pub struct ResolveFileRevisionRequest {
1132 #[prost(message, optional, tag = "2")]
1133 pub source_ref: ::core::option::Option<FileRevisionRef>,
1134}
1135#[derive(Clone, PartialEq, ::prost::Message)]
1136pub struct ResolveFileRevisionResponse {
1137 #[prost(string, tag = "1")]
1138 pub file_revision_rid: ::prost::alloc::string::String,
1139}
1140#[derive(Clone, PartialEq, ::prost::Message)]
1141pub struct ListFilesRequest {
1142 #[prost(string, tag = "1")]
1143 pub drive_rid: ::prost::alloc::string::String,
1144 #[prost(message, optional, tag = "2")]
1145 pub parent_path: ::core::option::Option<LogicalPath>,
1146 #[prost(bool, tag = "3")]
1147 pub include_removed: bool,
1148 #[prost(int32, optional, tag = "4")]
1149 pub page_size: ::core::option::Option<i32>,
1150 #[prost(string, optional, tag = "5")]
1151 pub page_token: ::core::option::Option<::prost::alloc::string::String>,
1152}
1153#[derive(Clone, PartialEq, ::prost::Message)]
1154pub struct ListFilesResponse {
1155 #[prost(message, repeated, tag = "1")]
1156 pub entries: ::prost::alloc::vec::Vec<FileEntry>,
1157 #[prost(string, optional, tag = "2")]
1158 pub next_page_token: ::core::option::Option<::prost::alloc::string::String>,
1159}
1160#[derive(Clone, PartialEq, ::prost::Message)]
1161pub struct ApplyFileChangesRequest {
1162 #[prost(string, tag = "1")]
1163 pub drive_rid: ::prost::alloc::string::String,
1164 #[prost(message, repeated, tag = "2")]
1165 pub changes: ::prost::alloc::vec::Vec<FileChange>,
1166}
1167#[derive(Clone, PartialEq, ::prost::Message)]
1168pub struct ApplyFileChangesResponse {
1169 #[prost(message, repeated, tag = "1")]
1170 pub results: ::prost::alloc::vec::Vec<FileChangeResult>,
1171}
1172#[derive(Clone, PartialEq, ::prost::Message)]
1173pub struct FileChangeSuccess {
1174 #[prost(message, optional, tag = "1")]
1175 pub file: ::core::option::Option<LogicalFile>,
1176 #[prost(message, optional, tag = "2")]
1177 pub file_revision: ::core::option::Option<ManagedFileRevision>,
1178}
1179#[derive(Clone, PartialEq, ::prost::Message)]
1180pub struct FileChangeFailure {
1181 #[prost(enumeration = "FileStoreError", tag = "1")]
1182 pub code: i32,
1183 #[prost(string, tag = "2")]
1184 pub message: ::prost::alloc::string::String,
1185}
1186#[derive(Clone, PartialEq, ::prost::Message)]
1187pub struct FileChangeResult {
1188 #[prost(oneof = "file_change_result::Result", tags = "1, 2")]
1189 pub result: ::core::option::Option<file_change_result::Result>,
1190}
1191pub mod file_change_result {
1193 #[derive(Clone, PartialEq, ::prost::Oneof)]
1194 pub enum Result {
1195 #[prost(message, tag = "1")]
1196 Success(super::FileChangeSuccess),
1197 #[prost(message, tag = "2")]
1198 Failure(super::FileChangeFailure),
1199 }
1200}
1201#[derive(Clone, PartialEq, ::prost::Message)]
1202pub struct ListFileRevisionsRequest {
1203 #[prost(string, tag = "1")]
1204 pub drive_rid: ::prost::alloc::string::String,
1205 #[prost(string, tag = "2")]
1206 pub file_rid: ::prost::alloc::string::String,
1207 #[prost(int32, optional, tag = "3")]
1208 pub page_size: ::core::option::Option<i32>,
1209 #[prost(string, optional, tag = "4")]
1210 pub page_token: ::core::option::Option<::prost::alloc::string::String>,
1211}
1212#[derive(Clone, PartialEq, ::prost::Message)]
1213pub struct ListFileRevisionsResponse {
1214 #[prost(message, repeated, tag = "1")]
1215 pub file_revisions: ::prost::alloc::vec::Vec<ManagedFileRevision>,
1216 #[prost(string, optional, tag = "2")]
1217 pub next_page_token: ::core::option::Option<::prost::alloc::string::String>,
1218}
1219#[derive(Clone, PartialEq, ::prost::Message)]
1220pub struct PurgeFileRequest {
1221 #[prost(string, tag = "1")]
1222 pub file_revision_rid: ::prost::alloc::string::String,
1223}
1224#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1225pub struct PurgeFileResponse {}
1226pub mod internal_files_service_client {
1228 #![allow(
1229 unused_variables,
1230 dead_code,
1231 missing_docs,
1232 clippy::wildcard_imports,
1233 clippy::let_unit_value,
1234 )]
1235 use tonic::codegen::*;
1236 use tonic::codegen::http::Uri;
1237 #[derive(Debug, Clone)]
1238 pub struct InternalFilesServiceClient<T> {
1239 inner: tonic::client::Grpc<T>,
1240 }
1241 impl InternalFilesServiceClient<tonic::transport::Channel> {
1242 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
1244 where
1245 D: TryInto<tonic::transport::Endpoint>,
1246 D::Error: Into<StdError>,
1247 {
1248 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
1249 Ok(Self::new(conn))
1250 }
1251 }
1252 impl<T> InternalFilesServiceClient<T>
1253 where
1254 T: tonic::client::GrpcService<tonic::body::Body>,
1255 T::Error: Into<StdError>,
1256 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
1257 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
1258 {
1259 pub fn new(inner: T) -> Self {
1260 let inner = tonic::client::Grpc::new(inner);
1261 Self { inner }
1262 }
1263 pub fn with_origin(inner: T, origin: Uri) -> Self {
1264 let inner = tonic::client::Grpc::with_origin(inner, origin);
1265 Self { inner }
1266 }
1267 pub fn with_interceptor<F>(
1268 inner: T,
1269 interceptor: F,
1270 ) -> InternalFilesServiceClient<InterceptedService<T, F>>
1271 where
1272 F: tonic::service::Interceptor,
1273 T::ResponseBody: Default,
1274 T: tonic::codegen::Service<
1275 http::Request<tonic::body::Body>,
1276 Response = http::Response<
1277 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
1278 >,
1279 >,
1280 <T as tonic::codegen::Service<
1281 http::Request<tonic::body::Body>,
1282 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
1283 {
1284 InternalFilesServiceClient::new(InterceptedService::new(inner, interceptor))
1285 }
1286 #[must_use]
1291 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
1292 self.inner = self.inner.send_compressed(encoding);
1293 self
1294 }
1295 #[must_use]
1297 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
1298 self.inner = self.inner.accept_compressed(encoding);
1299 self
1300 }
1301 #[must_use]
1305 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
1306 self.inner = self.inner.max_decoding_message_size(limit);
1307 self
1308 }
1309 #[must_use]
1313 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
1314 self.inner = self.inner.max_encoding_message_size(limit);
1315 self
1316 }
1317 pub async fn get_file(
1318 &mut self,
1319 request: impl tonic::IntoRequest<super::GetFileRequest>,
1320 ) -> std::result::Result<
1321 tonic::Response<super::GetFileResponse>,
1322 tonic::Status,
1323 > {
1324 self.inner
1325 .ready()
1326 .await
1327 .map_err(|e| {
1328 tonic::Status::unknown(
1329 format!("Service was not ready: {}", e.into()),
1330 )
1331 })?;
1332 let codec = tonic::codec::ProstCodec::default();
1333 let path = http::uri::PathAndQuery::from_static(
1334 "/nominal.file_store.v1.InternalFilesService/GetFile",
1335 );
1336 let mut req = request.into_request();
1337 req.extensions_mut()
1338 .insert(
1339 GrpcMethod::new(
1340 "nominal.file_store.v1.InternalFilesService",
1341 "GetFile",
1342 ),
1343 );
1344 self.inner.unary(req, path, codec).await
1345 }
1346 pub async fn resolve_file_revision(
1347 &mut self,
1348 request: impl tonic::IntoRequest<super::ResolveFileRevisionRequest>,
1349 ) -> std::result::Result<
1350 tonic::Response<super::ResolveFileRevisionResponse>,
1351 tonic::Status,
1352 > {
1353 self.inner
1354 .ready()
1355 .await
1356 .map_err(|e| {
1357 tonic::Status::unknown(
1358 format!("Service was not ready: {}", e.into()),
1359 )
1360 })?;
1361 let codec = tonic::codec::ProstCodec::default();
1362 let path = http::uri::PathAndQuery::from_static(
1363 "/nominal.file_store.v1.InternalFilesService/ResolveFileRevision",
1364 );
1365 let mut req = request.into_request();
1366 req.extensions_mut()
1367 .insert(
1368 GrpcMethod::new(
1369 "nominal.file_store.v1.InternalFilesService",
1370 "ResolveFileRevision",
1371 ),
1372 );
1373 self.inner.unary(req, path, codec).await
1374 }
1375 pub async fn list_files(
1376 &mut self,
1377 request: impl tonic::IntoRequest<super::ListFilesRequest>,
1378 ) -> std::result::Result<
1379 tonic::Response<super::ListFilesResponse>,
1380 tonic::Status,
1381 > {
1382 self.inner
1383 .ready()
1384 .await
1385 .map_err(|e| {
1386 tonic::Status::unknown(
1387 format!("Service was not ready: {}", e.into()),
1388 )
1389 })?;
1390 let codec = tonic::codec::ProstCodec::default();
1391 let path = http::uri::PathAndQuery::from_static(
1392 "/nominal.file_store.v1.InternalFilesService/ListFiles",
1393 );
1394 let mut req = request.into_request();
1395 req.extensions_mut()
1396 .insert(
1397 GrpcMethod::new(
1398 "nominal.file_store.v1.InternalFilesService",
1399 "ListFiles",
1400 ),
1401 );
1402 self.inner.unary(req, path, codec).await
1403 }
1404 pub async fn apply_file_changes(
1405 &mut self,
1406 request: impl tonic::IntoRequest<super::ApplyFileChangesRequest>,
1407 ) -> std::result::Result<
1408 tonic::Response<super::ApplyFileChangesResponse>,
1409 tonic::Status,
1410 > {
1411 self.inner
1412 .ready()
1413 .await
1414 .map_err(|e| {
1415 tonic::Status::unknown(
1416 format!("Service was not ready: {}", e.into()),
1417 )
1418 })?;
1419 let codec = tonic::codec::ProstCodec::default();
1420 let path = http::uri::PathAndQuery::from_static(
1421 "/nominal.file_store.v1.InternalFilesService/ApplyFileChanges",
1422 );
1423 let mut req = request.into_request();
1424 req.extensions_mut()
1425 .insert(
1426 GrpcMethod::new(
1427 "nominal.file_store.v1.InternalFilesService",
1428 "ApplyFileChanges",
1429 ),
1430 );
1431 self.inner.unary(req, path, codec).await
1432 }
1433 pub async fn list_file_revisions(
1434 &mut self,
1435 request: impl tonic::IntoRequest<super::ListFileRevisionsRequest>,
1436 ) -> std::result::Result<
1437 tonic::Response<super::ListFileRevisionsResponse>,
1438 tonic::Status,
1439 > {
1440 self.inner
1441 .ready()
1442 .await
1443 .map_err(|e| {
1444 tonic::Status::unknown(
1445 format!("Service was not ready: {}", e.into()),
1446 )
1447 })?;
1448 let codec = tonic::codec::ProstCodec::default();
1449 let path = http::uri::PathAndQuery::from_static(
1450 "/nominal.file_store.v1.InternalFilesService/ListFileRevisions",
1451 );
1452 let mut req = request.into_request();
1453 req.extensions_mut()
1454 .insert(
1455 GrpcMethod::new(
1456 "nominal.file_store.v1.InternalFilesService",
1457 "ListFileRevisions",
1458 ),
1459 );
1460 self.inner.unary(req, path, codec).await
1461 }
1462 pub async fn purge_file(
1463 &mut self,
1464 request: impl tonic::IntoRequest<super::PurgeFileRequest>,
1465 ) -> std::result::Result<
1466 tonic::Response<super::PurgeFileResponse>,
1467 tonic::Status,
1468 > {
1469 self.inner
1470 .ready()
1471 .await
1472 .map_err(|e| {
1473 tonic::Status::unknown(
1474 format!("Service was not ready: {}", e.into()),
1475 )
1476 })?;
1477 let codec = tonic::codec::ProstCodec::default();
1478 let path = http::uri::PathAndQuery::from_static(
1479 "/nominal.file_store.v1.InternalFilesService/PurgeFile",
1480 );
1481 let mut req = request.into_request();
1482 req.extensions_mut()
1483 .insert(
1484 GrpcMethod::new(
1485 "nominal.file_store.v1.InternalFilesService",
1486 "PurgeFile",
1487 ),
1488 );
1489 self.inner.unary(req, path, codec).await
1490 }
1491 }
1492}
1493#[derive(Clone, PartialEq, ::prost::Message)]
1494pub struct CreateIngestRuleRequest {
1495 #[prost(string, tag = "1")]
1496 pub drive_rid: ::prost::alloc::string::String,
1497 #[prost(message, optional, tag = "2")]
1498 pub matcher: ::core::option::Option<FileMatcher>,
1499 #[prost(message, optional, tag = "3")]
1500 pub triggers: ::core::option::Option<IngestTriggers>,
1501 #[prost(enumeration = "BackfillMode", tag = "4")]
1502 pub backfill_mode: i32,
1503}
1504#[derive(Clone, PartialEq, ::prost::Message)]
1505pub struct CreateIngestRuleResponse {
1506 #[prost(message, optional, tag = "1")]
1507 pub rule: ::core::option::Option<IngestRule>,
1508}
1509#[derive(Clone, PartialEq, ::prost::Message)]
1510pub struct ListIngestRulesRequest {
1511 #[prost(string, tag = "1")]
1512 pub drive_rid: ::prost::alloc::string::String,
1513 #[prost(bool, tag = "2")]
1514 pub include_archived: bool,
1515 #[prost(int32, optional, tag = "3")]
1516 pub page_size: ::core::option::Option<i32>,
1517 #[prost(string, optional, tag = "4")]
1518 pub page_token: ::core::option::Option<::prost::alloc::string::String>,
1519}
1520#[derive(Clone, PartialEq, ::prost::Message)]
1521pub struct ListIngestRulesResponse {
1522 #[prost(message, repeated, tag = "1")]
1523 pub rules: ::prost::alloc::vec::Vec<IngestRule>,
1524 #[prost(string, optional, tag = "2")]
1525 pub next_page_token: ::core::option::Option<::prost::alloc::string::String>,
1526}
1527#[derive(Clone, PartialEq, ::prost::Message)]
1528pub struct GetIngestRuleRequest {
1529 #[prost(string, tag = "1")]
1530 pub rule_rid: ::prost::alloc::string::String,
1531}
1532#[derive(Clone, PartialEq, ::prost::Message)]
1533pub struct GetIngestRuleResponse {
1534 #[prost(message, optional, tag = "1")]
1535 pub rule: ::core::option::Option<IngestRule>,
1536}
1537#[derive(Clone, PartialEq, ::prost::Message)]
1538pub struct UpdateIngestRuleRequest {
1539 #[prost(string, tag = "1")]
1540 pub rule_rid: ::prost::alloc::string::String,
1541 #[prost(message, optional, tag = "2")]
1542 pub matcher: ::core::option::Option<FileMatcher>,
1543 #[prost(message, optional, tag = "3")]
1544 pub triggers: ::core::option::Option<IngestTriggers>,
1545}
1546#[derive(Clone, PartialEq, ::prost::Message)]
1547pub struct UpdateIngestRuleResponse {
1548 #[prost(message, optional, tag = "1")]
1549 pub rule: ::core::option::Option<IngestRule>,
1550}
1551#[derive(Clone, PartialEq, ::prost::Message)]
1552pub struct ArchiveIngestRuleRequest {
1553 #[prost(string, tag = "1")]
1554 pub rule_rid: ::prost::alloc::string::String,
1555}
1556#[derive(Clone, PartialEq, ::prost::Message)]
1557pub struct ArchiveIngestRuleResponse {
1558 #[prost(message, optional, tag = "1")]
1559 pub rule: ::core::option::Option<IngestRule>,
1560}
1561#[derive(Clone, PartialEq, ::prost::Message)]
1562pub struct UnarchiveIngestRuleRequest {
1563 #[prost(string, tag = "1")]
1564 pub rule_rid: ::prost::alloc::string::String,
1565 #[prost(enumeration = "BackfillMode", tag = "2")]
1566 pub backfill_mode: i32,
1567}
1568#[derive(Clone, PartialEq, ::prost::Message)]
1569pub struct UnarchiveIngestRuleResponse {
1570 #[prost(message, optional, tag = "1")]
1571 pub rule: ::core::option::Option<IngestRule>,
1572}
1573#[derive(Clone, PartialEq, ::prost::Message)]
1574pub struct IngestRule {
1575 #[prost(string, tag = "1")]
1576 pub rule_rid: ::prost::alloc::string::String,
1577 #[prost(string, tag = "2")]
1578 pub drive_rid: ::prost::alloc::string::String,
1579 #[prost(message, optional, tag = "3")]
1580 pub matcher: ::core::option::Option<FileMatcher>,
1581 #[prost(message, optional, tag = "4")]
1582 pub triggers: ::core::option::Option<IngestTriggers>,
1583 #[prost(message, optional, tag = "5")]
1584 pub created: ::core::option::Option<Attribution>,
1585 #[prost(enumeration = "IngestRuleState", tag = "6")]
1586 pub state: i32,
1587 #[prost(message, optional, tag = "7")]
1588 pub archived: ::core::option::Option<Attribution>,
1589}
1590#[derive(Clone, PartialEq, ::prost::Message)]
1591pub struct FileMatcher {
1592 #[prost(oneof = "file_matcher::Matcher", tags = "1")]
1593 pub matcher: ::core::option::Option<file_matcher::Matcher>,
1594}
1595pub mod file_matcher {
1597 #[derive(Clone, PartialEq, ::prost::Oneof)]
1598 pub enum Matcher {
1599 #[prost(message, tag = "1")]
1600 Path(super::PathMatcher),
1601 }
1602}
1603#[derive(Clone, PartialEq, ::prost::Message)]
1604pub struct PathMatcher {
1605 #[prost(message, optional, tag = "1")]
1606 pub glob: ::core::option::Option<GlobPattern>,
1607}
1608#[derive(Clone, PartialEq, ::prost::Message)]
1609pub struct GlobPattern {
1610 #[prost(message, optional, tag = "1")]
1611 pub first: ::core::option::Option<PatternSegment>,
1612 #[prost(message, repeated, tag = "2")]
1613 pub rest: ::prost::alloc::vec::Vec<JoinedSegment>,
1614}
1615#[derive(Clone, PartialEq, ::prost::Message)]
1616pub struct JoinedSegment {
1617 #[prost(enumeration = "SegmentDelimiter", tag = "1")]
1618 pub delimiter: i32,
1619 #[prost(message, optional, tag = "2")]
1620 pub segment: ::core::option::Option<PatternSegment>,
1621}
1622#[derive(Clone, PartialEq, ::prost::Message)]
1623pub struct PatternSegment {
1624 #[prost(oneof = "pattern_segment::Kind", tags = "1, 2, 3")]
1625 pub kind: ::core::option::Option<pattern_segment::Kind>,
1626}
1627pub mod pattern_segment {
1629 #[derive(Clone, PartialEq, ::prost::Oneof)]
1630 pub enum Kind {
1631 #[prost(message, tag = "1")]
1632 Wildcard(super::Wildcard),
1633 #[prost(message, tag = "2")]
1634 Globstar(super::Globstar),
1635 #[prost(string, tag = "3")]
1636 Literal(::prost::alloc::string::String),
1637 }
1638}
1639#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1640pub struct Wildcard {}
1641#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1642pub struct Globstar {}
1643#[derive(Clone, PartialEq, ::prost::Message)]
1644pub struct IngestTriggers {
1645 #[prost(message, optional, tag = "1")]
1646 pub new_match: ::core::option::Option<IngestTarget>,
1647}
1648#[derive(Clone, PartialEq, ::prost::Message)]
1649pub struct IngestTarget {
1650 #[prost(oneof = "ingest_target::Target", tags = "1, 2")]
1651 pub target: ::core::option::Option<ingest_target::Target>,
1652}
1653pub mod ingest_target {
1655 #[derive(Clone, PartialEq, ::prost::Oneof)]
1656 pub enum Target {
1657 #[prost(message, tag = "1")]
1658 NewDataset(super::NewDatasetTarget),
1659 #[prost(message, tag = "2")]
1660 ExistingDataset(super::ExistingDatasetTarget),
1661 }
1662}
1663#[derive(Clone, Copy, PartialEq, ::prost::Message)]
1664pub struct NewDatasetTarget {}
1665#[derive(Clone, PartialEq, ::prost::Message)]
1666pub struct ExistingDatasetTarget {
1667 #[prost(string, tag = "1")]
1668 pub dataset_rid: ::prost::alloc::string::String,
1669}
1670#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1671#[repr(i32)]
1672pub enum BackfillMode {
1673 Unspecified = 0,
1674 NewFilesOnly = 1,
1675 BackfillExisting = 2,
1676}
1677impl BackfillMode {
1678 pub fn as_str_name(&self) -> &'static str {
1683 match self {
1684 Self::Unspecified => "BACKFILL_MODE_UNSPECIFIED",
1685 Self::NewFilesOnly => "BACKFILL_MODE_NEW_FILES_ONLY",
1686 Self::BackfillExisting => "BACKFILL_MODE_BACKFILL_EXISTING",
1687 }
1688 }
1689 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1691 match value {
1692 "BACKFILL_MODE_UNSPECIFIED" => Some(Self::Unspecified),
1693 "BACKFILL_MODE_NEW_FILES_ONLY" => Some(Self::NewFilesOnly),
1694 "BACKFILL_MODE_BACKFILL_EXISTING" => Some(Self::BackfillExisting),
1695 _ => None,
1696 }
1697 }
1698}
1699#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1700#[repr(i32)]
1701pub enum IngestRuleState {
1702 Unspecified = 0,
1703 Active = 1,
1704 Archived = 2,
1705}
1706impl IngestRuleState {
1707 pub fn as_str_name(&self) -> &'static str {
1712 match self {
1713 Self::Unspecified => "INGEST_RULE_STATE_UNSPECIFIED",
1714 Self::Active => "INGEST_RULE_STATE_ACTIVE",
1715 Self::Archived => "INGEST_RULE_STATE_ARCHIVED",
1716 }
1717 }
1718 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1720 match value {
1721 "INGEST_RULE_STATE_UNSPECIFIED" => Some(Self::Unspecified),
1722 "INGEST_RULE_STATE_ACTIVE" => Some(Self::Active),
1723 "INGEST_RULE_STATE_ARCHIVED" => Some(Self::Archived),
1724 _ => None,
1725 }
1726 }
1727}
1728#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1729#[repr(i32)]
1730pub enum SegmentDelimiter {
1731 Unspecified = 0,
1732 PathSeparator = 1,
1733 Concat = 2,
1734}
1735impl SegmentDelimiter {
1736 pub fn as_str_name(&self) -> &'static str {
1741 match self {
1742 Self::Unspecified => "SEGMENT_DELIMITER_UNSPECIFIED",
1743 Self::PathSeparator => "SEGMENT_DELIMITER_PATH_SEPARATOR",
1744 Self::Concat => "SEGMENT_DELIMITER_CONCAT",
1745 }
1746 }
1747 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1749 match value {
1750 "SEGMENT_DELIMITER_UNSPECIFIED" => Some(Self::Unspecified),
1751 "SEGMENT_DELIMITER_PATH_SEPARATOR" => Some(Self::PathSeparator),
1752 "SEGMENT_DELIMITER_CONCAT" => Some(Self::Concat),
1753 _ => None,
1754 }
1755 }
1756}
1757pub mod internal_ingest_rules_service_client {
1759 #![allow(
1760 unused_variables,
1761 dead_code,
1762 missing_docs,
1763 clippy::wildcard_imports,
1764 clippy::let_unit_value,
1765 )]
1766 use tonic::codegen::*;
1767 use tonic::codegen::http::Uri;
1768 #[derive(Debug, Clone)]
1769 pub struct InternalIngestRulesServiceClient<T> {
1770 inner: tonic::client::Grpc<T>,
1771 }
1772 impl InternalIngestRulesServiceClient<tonic::transport::Channel> {
1773 pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
1775 where
1776 D: TryInto<tonic::transport::Endpoint>,
1777 D::Error: Into<StdError>,
1778 {
1779 let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
1780 Ok(Self::new(conn))
1781 }
1782 }
1783 impl<T> InternalIngestRulesServiceClient<T>
1784 where
1785 T: tonic::client::GrpcService<tonic::body::Body>,
1786 T::Error: Into<StdError>,
1787 T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
1788 <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
1789 {
1790 pub fn new(inner: T) -> Self {
1791 let inner = tonic::client::Grpc::new(inner);
1792 Self { inner }
1793 }
1794 pub fn with_origin(inner: T, origin: Uri) -> Self {
1795 let inner = tonic::client::Grpc::with_origin(inner, origin);
1796 Self { inner }
1797 }
1798 pub fn with_interceptor<F>(
1799 inner: T,
1800 interceptor: F,
1801 ) -> InternalIngestRulesServiceClient<InterceptedService<T, F>>
1802 where
1803 F: tonic::service::Interceptor,
1804 T::ResponseBody: Default,
1805 T: tonic::codegen::Service<
1806 http::Request<tonic::body::Body>,
1807 Response = http::Response<
1808 <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
1809 >,
1810 >,
1811 <T as tonic::codegen::Service<
1812 http::Request<tonic::body::Body>,
1813 >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
1814 {
1815 InternalIngestRulesServiceClient::new(
1816 InterceptedService::new(inner, interceptor),
1817 )
1818 }
1819 #[must_use]
1824 pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
1825 self.inner = self.inner.send_compressed(encoding);
1826 self
1827 }
1828 #[must_use]
1830 pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
1831 self.inner = self.inner.accept_compressed(encoding);
1832 self
1833 }
1834 #[must_use]
1838 pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
1839 self.inner = self.inner.max_decoding_message_size(limit);
1840 self
1841 }
1842 #[must_use]
1846 pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
1847 self.inner = self.inner.max_encoding_message_size(limit);
1848 self
1849 }
1850 pub async fn create_ingest_rule(
1851 &mut self,
1852 request: impl tonic::IntoRequest<super::CreateIngestRuleRequest>,
1853 ) -> std::result::Result<
1854 tonic::Response<super::CreateIngestRuleResponse>,
1855 tonic::Status,
1856 > {
1857 self.inner
1858 .ready()
1859 .await
1860 .map_err(|e| {
1861 tonic::Status::unknown(
1862 format!("Service was not ready: {}", e.into()),
1863 )
1864 })?;
1865 let codec = tonic::codec::ProstCodec::default();
1866 let path = http::uri::PathAndQuery::from_static(
1867 "/nominal.file_store.v1.InternalIngestRulesService/CreateIngestRule",
1868 );
1869 let mut req = request.into_request();
1870 req.extensions_mut()
1871 .insert(
1872 GrpcMethod::new(
1873 "nominal.file_store.v1.InternalIngestRulesService",
1874 "CreateIngestRule",
1875 ),
1876 );
1877 self.inner.unary(req, path, codec).await
1878 }
1879 pub async fn list_ingest_rules(
1880 &mut self,
1881 request: impl tonic::IntoRequest<super::ListIngestRulesRequest>,
1882 ) -> std::result::Result<
1883 tonic::Response<super::ListIngestRulesResponse>,
1884 tonic::Status,
1885 > {
1886 self.inner
1887 .ready()
1888 .await
1889 .map_err(|e| {
1890 tonic::Status::unknown(
1891 format!("Service was not ready: {}", e.into()),
1892 )
1893 })?;
1894 let codec = tonic::codec::ProstCodec::default();
1895 let path = http::uri::PathAndQuery::from_static(
1896 "/nominal.file_store.v1.InternalIngestRulesService/ListIngestRules",
1897 );
1898 let mut req = request.into_request();
1899 req.extensions_mut()
1900 .insert(
1901 GrpcMethod::new(
1902 "nominal.file_store.v1.InternalIngestRulesService",
1903 "ListIngestRules",
1904 ),
1905 );
1906 self.inner.unary(req, path, codec).await
1907 }
1908 pub async fn get_ingest_rule(
1909 &mut self,
1910 request: impl tonic::IntoRequest<super::GetIngestRuleRequest>,
1911 ) -> std::result::Result<
1912 tonic::Response<super::GetIngestRuleResponse>,
1913 tonic::Status,
1914 > {
1915 self.inner
1916 .ready()
1917 .await
1918 .map_err(|e| {
1919 tonic::Status::unknown(
1920 format!("Service was not ready: {}", e.into()),
1921 )
1922 })?;
1923 let codec = tonic::codec::ProstCodec::default();
1924 let path = http::uri::PathAndQuery::from_static(
1925 "/nominal.file_store.v1.InternalIngestRulesService/GetIngestRule",
1926 );
1927 let mut req = request.into_request();
1928 req.extensions_mut()
1929 .insert(
1930 GrpcMethod::new(
1931 "nominal.file_store.v1.InternalIngestRulesService",
1932 "GetIngestRule",
1933 ),
1934 );
1935 self.inner.unary(req, path, codec).await
1936 }
1937 pub async fn update_ingest_rule(
1938 &mut self,
1939 request: impl tonic::IntoRequest<super::UpdateIngestRuleRequest>,
1940 ) -> std::result::Result<
1941 tonic::Response<super::UpdateIngestRuleResponse>,
1942 tonic::Status,
1943 > {
1944 self.inner
1945 .ready()
1946 .await
1947 .map_err(|e| {
1948 tonic::Status::unknown(
1949 format!("Service was not ready: {}", e.into()),
1950 )
1951 })?;
1952 let codec = tonic::codec::ProstCodec::default();
1953 let path = http::uri::PathAndQuery::from_static(
1954 "/nominal.file_store.v1.InternalIngestRulesService/UpdateIngestRule",
1955 );
1956 let mut req = request.into_request();
1957 req.extensions_mut()
1958 .insert(
1959 GrpcMethod::new(
1960 "nominal.file_store.v1.InternalIngestRulesService",
1961 "UpdateIngestRule",
1962 ),
1963 );
1964 self.inner.unary(req, path, codec).await
1965 }
1966 pub async fn archive_ingest_rule(
1967 &mut self,
1968 request: impl tonic::IntoRequest<super::ArchiveIngestRuleRequest>,
1969 ) -> std::result::Result<
1970 tonic::Response<super::ArchiveIngestRuleResponse>,
1971 tonic::Status,
1972 > {
1973 self.inner
1974 .ready()
1975 .await
1976 .map_err(|e| {
1977 tonic::Status::unknown(
1978 format!("Service was not ready: {}", e.into()),
1979 )
1980 })?;
1981 let codec = tonic::codec::ProstCodec::default();
1982 let path = http::uri::PathAndQuery::from_static(
1983 "/nominal.file_store.v1.InternalIngestRulesService/ArchiveIngestRule",
1984 );
1985 let mut req = request.into_request();
1986 req.extensions_mut()
1987 .insert(
1988 GrpcMethod::new(
1989 "nominal.file_store.v1.InternalIngestRulesService",
1990 "ArchiveIngestRule",
1991 ),
1992 );
1993 self.inner.unary(req, path, codec).await
1994 }
1995 pub async fn unarchive_ingest_rule(
1996 &mut self,
1997 request: impl tonic::IntoRequest<super::UnarchiveIngestRuleRequest>,
1998 ) -> std::result::Result<
1999 tonic::Response<super::UnarchiveIngestRuleResponse>,
2000 tonic::Status,
2001 > {
2002 self.inner
2003 .ready()
2004 .await
2005 .map_err(|e| {
2006 tonic::Status::unknown(
2007 format!("Service was not ready: {}", e.into()),
2008 )
2009 })?;
2010 let codec = tonic::codec::ProstCodec::default();
2011 let path = http::uri::PathAndQuery::from_static(
2012 "/nominal.file_store.v1.InternalIngestRulesService/UnarchiveIngestRule",
2013 );
2014 let mut req = request.into_request();
2015 req.extensions_mut()
2016 .insert(
2017 GrpcMethod::new(
2018 "nominal.file_store.v1.InternalIngestRulesService",
2019 "UnarchiveIngestRule",
2020 ),
2021 );
2022 self.inner.unary(req, path, codec).await
2023 }
2024 }
2025}