megacommerce_proto/
uploader.v1.rs

1// This file is @generated by prost-build.
2/// Generated client implementations.
3pub mod uploader_service_client {
4    #![allow(
5        unused_variables,
6        dead_code,
7        missing_docs,
8        clippy::wildcard_imports,
9        clippy::let_unit_value,
10    )]
11    use tonic::codegen::*;
12    use tonic::codegen::http::Uri;
13    #[derive(Debug, Clone)]
14    pub struct UploaderServiceClient<T> {
15        inner: tonic::client::Grpc<T>,
16    }
17    impl UploaderServiceClient<tonic::transport::Channel> {
18        /// Attempt to create a new client by connecting to a given endpoint.
19        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
20        where
21            D: TryInto<tonic::transport::Endpoint>,
22            D::Error: Into<StdError>,
23        {
24            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
25            Ok(Self::new(conn))
26        }
27    }
28    impl<T> UploaderServiceClient<T>
29    where
30        T: tonic::client::GrpcService<tonic::body::Body>,
31        T::Error: Into<StdError>,
32        T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
33        <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
34    {
35        pub fn new(inner: T) -> Self {
36            let inner = tonic::client::Grpc::new(inner);
37            Self { inner }
38        }
39        pub fn with_origin(inner: T, origin: Uri) -> Self {
40            let inner = tonic::client::Grpc::with_origin(inner, origin);
41            Self { inner }
42        }
43        pub fn with_interceptor<F>(
44            inner: T,
45            interceptor: F,
46        ) -> UploaderServiceClient<InterceptedService<T, F>>
47        where
48            F: tonic::service::Interceptor,
49            T::ResponseBody: Default,
50            T: tonic::codegen::Service<
51                http::Request<tonic::body::Body>,
52                Response = http::Response<
53                    <T as tonic::client::GrpcService<tonic::body::Body>>::ResponseBody,
54                >,
55            >,
56            <T as tonic::codegen::Service<
57                http::Request<tonic::body::Body>,
58            >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
59        {
60            UploaderServiceClient::new(InterceptedService::new(inner, interceptor))
61        }
62        /// Compress requests with the given encoding.
63        ///
64        /// This requires the server to support it otherwise it might respond with an
65        /// error.
66        #[must_use]
67        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
68            self.inner = self.inner.send_compressed(encoding);
69            self
70        }
71        /// Enable decompressing responses.
72        #[must_use]
73        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
74            self.inner = self.inner.accept_compressed(encoding);
75            self
76        }
77        /// Limits the maximum size of a decoded message.
78        ///
79        /// Default: `4MB`
80        #[must_use]
81        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
82            self.inner = self.inner.max_decoding_message_size(limit);
83            self
84        }
85        /// Limits the maximum size of an encoded message.
86        ///
87        /// Default: `usize::MAX`
88        #[must_use]
89        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
90            self.inner = self.inner.max_encoding_message_size(limit);
91            self
92        }
93    }
94}
95/// Generated server implementations.
96pub mod uploader_service_server {
97    #![allow(
98        unused_variables,
99        dead_code,
100        missing_docs,
101        clippy::wildcard_imports,
102        clippy::let_unit_value,
103    )]
104    use tonic::codegen::*;
105    /// Generated trait containing gRPC methods that should be implemented for use with UploaderServiceServer.
106    #[async_trait]
107    pub trait UploaderService: std::marker::Send + std::marker::Sync + 'static {}
108    #[derive(Debug)]
109    pub struct UploaderServiceServer<T> {
110        inner: Arc<T>,
111        accept_compression_encodings: EnabledCompressionEncodings,
112        send_compression_encodings: EnabledCompressionEncodings,
113        max_decoding_message_size: Option<usize>,
114        max_encoding_message_size: Option<usize>,
115    }
116    impl<T> UploaderServiceServer<T> {
117        pub fn new(inner: T) -> Self {
118            Self::from_arc(Arc::new(inner))
119        }
120        pub fn from_arc(inner: Arc<T>) -> Self {
121            Self {
122                inner,
123                accept_compression_encodings: Default::default(),
124                send_compression_encodings: Default::default(),
125                max_decoding_message_size: None,
126                max_encoding_message_size: None,
127            }
128        }
129        pub fn with_interceptor<F>(
130            inner: T,
131            interceptor: F,
132        ) -> InterceptedService<Self, F>
133        where
134            F: tonic::service::Interceptor,
135        {
136            InterceptedService::new(Self::new(inner), interceptor)
137        }
138        /// Enable decompressing requests with the given encoding.
139        #[must_use]
140        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
141            self.accept_compression_encodings.enable(encoding);
142            self
143        }
144        /// Compress responses with the given encoding, if the client supports it.
145        #[must_use]
146        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
147            self.send_compression_encodings.enable(encoding);
148            self
149        }
150        /// Limits the maximum size of a decoded message.
151        ///
152        /// Default: `4MB`
153        #[must_use]
154        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
155            self.max_decoding_message_size = Some(limit);
156            self
157        }
158        /// Limits the maximum size of an encoded message.
159        ///
160        /// Default: `usize::MAX`
161        #[must_use]
162        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
163            self.max_encoding_message_size = Some(limit);
164            self
165        }
166    }
167    impl<T, B> tonic::codegen::Service<http::Request<B>> for UploaderServiceServer<T>
168    where
169        T: UploaderService,
170        B: Body + std::marker::Send + 'static,
171        B::Error: Into<StdError> + std::marker::Send + 'static,
172    {
173        type Response = http::Response<tonic::body::Body>;
174        type Error = std::convert::Infallible;
175        type Future = BoxFuture<Self::Response, Self::Error>;
176        fn poll_ready(
177            &mut self,
178            _cx: &mut Context<'_>,
179        ) -> Poll<std::result::Result<(), Self::Error>> {
180            Poll::Ready(Ok(()))
181        }
182        fn call(&mut self, req: http::Request<B>) -> Self::Future {
183            match req.uri().path() {
184                _ => {
185                    Box::pin(async move {
186                        let mut response = http::Response::new(
187                            tonic::body::Body::default(),
188                        );
189                        let headers = response.headers_mut();
190                        headers
191                            .insert(
192                                tonic::Status::GRPC_STATUS,
193                                (tonic::Code::Unimplemented as i32).into(),
194                            );
195                        headers
196                            .insert(
197                                http::header::CONTENT_TYPE,
198                                tonic::metadata::GRPC_CONTENT_TYPE,
199                            );
200                        Ok(response)
201                    })
202                }
203            }
204        }
205    }
206    impl<T> Clone for UploaderServiceServer<T> {
207        fn clone(&self) -> Self {
208            let inner = self.inner.clone();
209            Self {
210                inner,
211                accept_compression_encodings: self.accept_compression_encodings,
212                send_compression_encodings: self.send_compression_encodings,
213                max_decoding_message_size: self.max_decoding_message_size,
214                max_encoding_message_size: self.max_encoding_message_size,
215            }
216        }
217    }
218    /// Generated gRPC service name
219    pub const SERVICE_NAME: &str = "uploader.v1.UploaderService";
220    impl<T> tonic::server::NamedService for UploaderServiceServer<T> {
221        const NAME: &'static str = SERVICE_NAME;
222    }
223}
224#[derive(serde::Serialize, serde::Deserialize)]
225#[derive(Clone, PartialEq, ::prost::Message)]
226pub struct DataStorageOptions {
227    /// Rustus storage type.
228    ///
229    /// Storages are used to store uploads.
230    ///
231    /// NOTE: Rust default is `default_storage()` -> FileStorage. Apply this default if field absent.
232    #[prost(enumeration = "AvailableDataStorages", tag = "1")]
233    pub storage: i32,
234    /// Rustus data directory
235    ///
236    /// This directory is used to store files for all `file_storage` storages.
237    /// PathBuf in Rust -> string path here.
238    ///
239    /// NOTE: Rust default is `./data`.
240    #[prost(string, tag = "2")]
241    pub data_dir: ::prost::alloc::string::String,
242    /// Storage directory structure. This template shows inner directory structure.
243    /// You can use following variables: day, month, year or even environment variables.
244    /// Example: "/year/month/day/env\[HOSTNAME\]/".
245    #[prost(string, tag = "3")]
246    pub dir_structure: ::prost::alloc::string::String,
247    /// Forces fsync call after writing chunk to filesystem. Useful for network filesystems.
248    #[prost(bool, tag = "4")]
249    pub force_fsync: bool,
250    /// S3 bucket to upload files to.
251    ///
252    /// This parameter is required for s3-based storages.
253    #[prost(string, optional, tag = "10")]
254    pub s3_bucket: ::core::option::Option<::prost::alloc::string::String>,
255    /// S3 region.
256    ///
257    /// This parameter is required for s3-based storages.
258    #[prost(string, optional, tag = "11")]
259    pub s3_region: ::core::option::Option<::prost::alloc::string::String>,
260    /// S3 access key.
261    ///
262    /// This parameter is required for s3-based storages.
263    #[prost(string, optional, tag = "12")]
264    pub s3_access_key: ::core::option::Option<::prost::alloc::string::String>,
265    /// S3 access key path.
266    ///
267    /// path to file that has s3-access-key inside.
268    ///
269    /// This parameter is used for s3-based storages.
270    #[prost(string, optional, tag = "13")]
271    pub s3_access_key_path: ::core::option::Option<::prost::alloc::string::String>,
272    /// S3 secret key.
273    ///
274    /// This parameter is required for s3-based storages.
275    #[prost(string, optional, tag = "14")]
276    pub s3_secret_key: ::core::option::Option<::prost::alloc::string::String>,
277    /// S3 secret key path.
278    ///
279    /// path to file that has s3-secret-key inside.
280    ///
281    /// This parameter is required for s3-based storages.
282    #[prost(string, optional, tag = "15")]
283    pub s3_secret_key_path: ::core::option::Option<::prost::alloc::string::String>,
284    /// S3 URL.
285    ///
286    /// This parameter is required for s3-based storages.
287    #[prost(string, optional, tag = "16")]
288    pub s3_url: ::core::option::Option<::prost::alloc::string::String>,
289    /// S3 force path style.
290    ///
291    /// This parameter is required for some s3-based storages (e.g. MinIO).
292    #[prost(bool, tag = "17")]
293    pub s3_force_path_style: bool,
294    /// S3 security token.
295    ///
296    /// This parameter is used for temporary credentials.
297    #[prost(string, optional, tag = "18")]
298    pub s3_security_token: ::core::option::Option<::prost::alloc::string::String>,
299    /// S3 session token.
300    #[prost(string, optional, tag = "19")]
301    pub s3_session_token: ::core::option::Option<::prost::alloc::string::String>,
302    /// S3 profile.
303    #[prost(string, optional, tag = "20")]
304    pub s3_profile: ::core::option::Option<::prost::alloc::string::String>,
305    /// Additional S3 headers. These headers are passed to every request to s3.
306    /// Useful for configuring ACLs.
307    #[prost(string, optional, tag = "21")]
308    pub s3_headers: ::core::option::Option<::prost::alloc::string::String>,
309    /// Number of concurrent downloads of partial files from S3.
310    /// When performing concatenation, Rustus downloads all partial files
311    /// from S3 and concatenates them into a single file.
312    ///
313    /// This parameter controls the number of concurrent downloads.
314    ///
315    /// NOTE: Rust default = 10
316    #[prost(uint32, tag = "22")]
317    pub s3_concat_concurrent_downloads: u32,
318}
319#[derive(serde::Serialize, serde::Deserialize)]
320#[derive(Clone, PartialEq, ::prost::Message)]
321pub struct InfoStoreOptions {
322    /// / Type of info storage.
323    /// /
324    /// / Info storages are used to store information about uploads.
325    /// /
326    /// / This information is used in HEAD requests.
327    ///
328    /// NOTE: Rust default = Files
329    #[prost(enumeration = "AvailableInfoStorages", tag = "1")]
330    pub info_storage: i32,
331    /// / Rustus info directory
332    /// /
333    /// / This directory is used to store .info files for `file_info_storage`.
334    ///
335    /// NOTE: Rust default = "./data"
336    #[prost(string, tag = "2")]
337    pub info_dir: ::prost::alloc::string::String,
338    /// / Connection string for remote info storages.
339    /// /
340    /// / This connection string is used for storages which require connection.
341    /// / Examples of such storages are `Postgres`, `MySQL` or `Redis`.
342    /// /
343    /// / Value must include all connection details.
344    #[prost(string, optional, tag = "3")]
345    pub info_db_dsn: ::core::option::Option<::prost::alloc::string::String>,
346    /// redis_info_expiration: Option<usize> in Rust -> optional uint64 here
347    #[prost(uint64, optional, tag = "4")]
348    pub redis_info_expiration: ::core::option::Option<u64>,
349}
350#[derive(serde::Serialize, serde::Deserialize)]
351#[derive(Clone, PartialEq, ::prost::Message)]
352pub struct AmqpHooksOptions {
353    /// / Url for AMQP server.
354    #[prost(string, optional, tag = "1")]
355    pub url: ::core::option::Option<::prost::alloc::string::String>,
356    /// / Rustus will create exchange if enabled.
357    #[prost(bool, tag = "2")]
358    pub declare_exchange: bool,
359    /// / Rustus will create all queues for communication and bind them
360    /// / to exchange if enabled.
361    #[prost(bool, tag = "3")]
362    pub declare_queues: bool,
363    /// / Durability type of exchange.
364    #[prost(bool, tag = "4")]
365    pub durable_exchange: bool,
366    /// / Durability type of queues.
367    #[prost(bool, tag = "5")]
368    pub durable_queues: bool,
369    /// / Adds celery specific headers.
370    #[prost(bool, tag = "6")]
371    pub celery: bool,
372    /// / Name of amqp exchange.
373    ///
374    /// default "rustus" in Rust
375    #[prost(string, tag = "10")]
376    pub exchange: ::prost::alloc::string::String,
377    /// / Exchange kind.
378    ///
379    /// default "topic" in Rust
380    #[prost(string, tag = "11")]
381    pub exchange_kind: ::prost::alloc::string::String,
382    /// / Routing key to use when sending message to an exchange.
383    #[prost(string, optional, tag = "12")]
384    pub routing_key: ::core::option::Option<::prost::alloc::string::String>,
385    /// / Prefix for all AMQP queues.
386    ///
387    /// default "rustus" in Rust
388    #[prost(string, tag = "13")]
389    pub queues_prefix: ::prost::alloc::string::String,
390    /// / Maximum number of connections for `RabbitMQ`.
391    ///
392    /// default 10
393    #[prost(uint64, tag = "14")]
394    pub connection_pool_size: u64,
395    /// / Maximum number of opened channels for each connection.
396    ///
397    /// default 10
398    #[prost(uint64, tag = "15")]
399    pub channel_pool_size: u64,
400    /// / After this amount of time the connection will be dropped.
401    #[prost(uint64, optional, tag = "16")]
402    pub idle_connection_timeout: ::core::option::Option<u64>,
403    /// / After this amount of time in seconds, the channel will be closed.
404    #[prost(uint64, optional, tag = "17")]
405    pub idle_channels_timeout: ::core::option::Option<u64>,
406    /// / Declares all objects with auto-delete property set.
407    #[prost(bool, tag = "18")]
408    pub auto_delete: bool,
409}
410#[derive(serde::Serialize, serde::Deserialize)]
411#[derive(Clone, PartialEq, ::prost::Message)]
412pub struct KafkaHookOptions {
413    /// / Kafka urls.
414    /// / List of brokers to connect to in the format `host:port`.
415    /// / If you have multiple brokers, separate them with commas.
416    /// / Corresponds to `bootstrap.servers` in Kafka configuration.
417    #[prost(string, optional, tag = "1")]
418    pub urls: ::core::option::Option<::prost::alloc::string::String>,
419    /// / Kafka producer client.id.
420    #[prost(string, optional, tag = "2")]
421    pub client_id: ::core::option::Option<::prost::alloc::string::String>,
422    /// / Kafka required acks.
423    #[prost(string, optional, tag = "5")]
424    pub required_acks: ::core::option::Option<::prost::alloc::string::String>,
425    /// / Compression codec.
426    #[prost(string, optional, tag = "6")]
427    pub compression: ::core::option::Option<::prost::alloc::string::String>,
428    /// / Kafka idle timeout in seconds.
429    #[prost(uint64, optional, tag = "7")]
430    pub idle_timeout: ::core::option::Option<u64>,
431    /// / Kafka send timeout in seconds.
432    #[prost(uint64, optional, tag = "8")]
433    pub send_timeout: ::core::option::Option<u64>,
434    /// / Extra options for Kafka.
435    /// / In Rust this is ExtraKafkaOptions; here it's a map of strings.
436    #[prost(map = "string, string", tag = "20")]
437    pub extra_kafka_opts: ::std::collections::HashMap<
438        ::prost::alloc::string::String,
439        ::prost::alloc::string::String,
440    >,
441    /// Mutual exclusion: topic OR prefix (Rust validate enforces this).
442    #[prost(oneof = "kafka_hook_options::TopicOrPrefix", tags = "3, 4")]
443    pub topic_or_prefix: ::core::option::Option<kafka_hook_options::TopicOrPrefix>,
444}
445/// Nested message and enum types in `KafkaHookOptions`.
446pub mod kafka_hook_options {
447    /// Mutual exclusion: topic OR prefix (Rust validate enforces this).
448    #[derive(serde::Serialize, serde::Deserialize)]
449    #[derive(Clone, PartialEq, ::prost::Oneof)]
450    pub enum TopicOrPrefix {
451        #[prost(string, tag = "3")]
452        Topic(::prost::alloc::string::String),
453        #[prost(string, tag = "4")]
454        Prefix(::prost::alloc::string::String),
455    }
456}
457#[derive(serde::Serialize, serde::Deserialize)]
458#[derive(Clone, PartialEq, ::prost::Message)]
459pub struct NatsHookOptions {
460    /// / List of URLs to connect to NATS. Commas are used as delimiters.
461    #[prost(string, repeated, tag = "1")]
462    pub urls: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
463    /// / Wait for replies from NATS.
464    #[prost(bool, tag = "4")]
465    pub wait_for_replies: bool,
466    /// / NATS user to connect to the server.
467    #[prost(string, optional, tag = "10")]
468    pub username: ::core::option::Option<::prost::alloc::string::String>,
469    /// / NATS password to connect to the server.
470    #[prost(string, optional, tag = "11")]
471    pub password: ::core::option::Option<::prost::alloc::string::String>,
472    /// / NATS token to connect to the server.
473    #[prost(string, optional, tag = "12")]
474    pub token: ::core::option::Option<::prost::alloc::string::String>,
475    /// Mutual exclusion: subject OR prefix (Rust validate enforces this).
476    #[prost(oneof = "nats_hook_options::SubjectOrPrefix", tags = "2, 3")]
477    pub subject_or_prefix: ::core::option::Option<nats_hook_options::SubjectOrPrefix>,
478}
479/// Nested message and enum types in `NatsHookOptions`.
480pub mod nats_hook_options {
481    /// Mutual exclusion: subject OR prefix (Rust validate enforces this).
482    #[derive(serde::Serialize, serde::Deserialize)]
483    #[derive(Clone, PartialEq, ::prost::Oneof)]
484    pub enum SubjectOrPrefix {
485        #[prost(string, tag = "2")]
486        Subject(::prost::alloc::string::String),
487        #[prost(string, tag = "3")]
488        Prefix(::prost::alloc::string::String),
489    }
490}
491#[derive(serde::Serialize, serde::Deserialize)]
492#[derive(Clone, PartialEq, ::prost::Message)]
493pub struct NotificationsOptions {
494    /// / Notifications format.
495    /// /
496    /// / This format will be used in all messages about hooks.
497    ///
498    /// default Format::Default in Rust
499    #[prost(enumeration = "Format", tag = "1")]
500    pub hooks_format: i32,
501    /// / Enabled hooks for notifications.
502    ///
503    /// default set in Rust (pre-create, post-create, ...)
504    #[prost(enumeration = "Hook", repeated, tag = "2")]
505    pub hooks: ::prost::alloc::vec::Vec<i32>,
506    /// / Use this option if you use rustus behind any proxy. Like Nginx or Traefik.
507    #[prost(bool, tag = "3")]
508    pub behind_proxy: bool,
509    /// / List of URLS to send webhooks to.
510    #[prost(string, repeated, tag = "4")]
511    pub hooks_http_urls: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
512    /// / Timeout for all HTTP requests in seconds.
513    #[prost(uint64, optional, tag = "5")]
514    pub http_hook_timeout: ::core::option::Option<u64>,
515    /// List of headers to forward from client.
516    #[prost(string, repeated, tag = "6")]
517    pub hooks_http_proxy_headers: ::prost::alloc::vec::Vec<
518        ::prost::alloc::string::String,
519    >,
520    /// / Directory for executable hook files.
521    #[prost(string, optional, tag = "10")]
522    pub hooks_dir: ::core::option::Option<::prost::alloc::string::String>,
523    /// / Executable file which must be called for notifying about upload status.
524    #[prost(string, optional, tag = "11")]
525    pub hooks_file: ::core::option::Option<::prost::alloc::string::String>,
526    #[prost(message, optional, tag = "20")]
527    pub amqp_hook_opts: ::core::option::Option<AmqpHooksOptions>,
528    #[prost(message, optional, tag = "21")]
529    pub kafka_hook_opts: ::core::option::Option<KafkaHookOptions>,
530    #[prost(message, optional, tag = "22")]
531    pub nats_hook_opts: ::core::option::Option<NatsHookOptions>,
532}
533#[derive(serde::Serialize, serde::Deserialize)]
534#[derive(Clone, PartialEq, ::prost::Message)]
535pub struct SentryOptions {
536    #[prost(string, optional, tag = "1")]
537    pub dsn: ::core::option::Option<::prost::alloc::string::String>,
538    /// sample_rate: f32 in Rust -> float here (no presence tracking for float in proto3
539    /// unless you use wrapper; we keep it as scalar and document default)
540    ///
541    /// Rust default = 1.0; consumers should apply if zero/absent
542    #[prost(float, tag = "2")]
543    pub sample_rate: f32,
544}
545#[derive(serde::Serialize, serde::Deserialize)]
546#[derive(Clone, PartialEq, ::prost::Message)]
547pub struct RustusConf {
548    /// / Rustus server host
549    #[prost(string, tag = "1")]
550    pub host: ::prost::alloc::string::String,
551    /// / Rustus server port
552    #[prost(uint32, tag = "2")]
553    pub port: u32,
554    #[prost(bool, tag = "3")]
555    pub disable_health_access_log: bool,
556    /// / Rustus base API url
557    #[prost(string, tag = "4")]
558    pub url: ::prost::alloc::string::String,
559    /// / Allowed hosts for CORS protocol.
560    #[prost(string, repeated, tag = "10")]
561    pub cors: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
562    /// / Maximum payload size.
563    #[prost(uint64, tag = "11")]
564    pub max_body_size: u64,
565    /// / Rustus maximum log level (string; maps to log::LevelFilter in Rust)
566    #[prost(string, tag = "12")]
567    pub log_level: ::prost::alloc::string::String,
568    /// / Number of actix workers (optional: None -> auto)
569    #[prost(uint64, optional, tag = "13")]
570    pub workers: ::core::option::Option<u64>,
571    /// / Enabled extensions for TUS protocol.
572    #[prost(enumeration = "Extension", repeated, tag = "14")]
573    pub tus_extensions: ::prost::alloc::vec::Vec<i32>,
574    /// / Allow creation of empty files when Upload-Length header equals 0.
575    #[prost(bool, tag = "15")]
576    pub allow_empty: bool,
577    /// / Remove part files after concatenation is done.
578    #[prost(bool, tag = "16")]
579    pub remove_parts: bool,
580    /// / Maximum size of file that can be uploaded. Optional -> presence matters.
581    #[prost(uint64, optional, tag = "17")]
582    pub max_file_size: ::core::option::Option<u64>,
583    /// Nested option messages
584    #[prost(message, optional, tag = "20")]
585    pub storage_opts: ::core::option::Option<DataStorageOptions>,
586    #[prost(message, optional, tag = "21")]
587    pub info_storage_opts: ::core::option::Option<InfoStoreOptions>,
588    #[prost(message, optional, tag = "22")]
589    pub notification_opts: ::core::option::Option<NotificationsOptions>,
590    #[prost(message, optional, tag = "23")]
591    pub sentry_opts: ::core::option::Option<SentryOptions>,
592}
593#[derive(serde::Serialize, serde::Deserialize)]
594#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
595#[repr(i32)]
596pub enum AvailableDataStorages {
597    Unspecified = 0,
598    FileStorage = 1,
599    S3 = 2,
600    HybridS3 = 3,
601}
602impl AvailableDataStorages {
603    /// String value of the enum field names used in the ProtoBuf definition.
604    ///
605    /// The values are not transformed in any way and thus are considered stable
606    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
607    pub fn as_str_name(&self) -> &'static str {
608        match self {
609            Self::Unspecified => "AVAILABLE_DATA_STORAGES_UNSPECIFIED",
610            Self::FileStorage => "FILE_STORAGE",
611            Self::S3 => "S3",
612            Self::HybridS3 => "HYBRID_S3",
613        }
614    }
615    /// Creates an enum from field names used in the ProtoBuf definition.
616    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
617        match value {
618            "AVAILABLE_DATA_STORAGES_UNSPECIFIED" => Some(Self::Unspecified),
619            "FILE_STORAGE" => Some(Self::FileStorage),
620            "S3" => Some(Self::S3),
621            "HYBRID_S3" => Some(Self::HybridS3),
622            _ => None,
623        }
624    }
625}
626#[derive(serde::Serialize, serde::Deserialize)]
627#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
628#[repr(i32)]
629pub enum AvailableInfoStorages {
630    Unspecified = 0,
631    Files = 1,
632    Redis = 2,
633    Postgres = 3,
634}
635impl AvailableInfoStorages {
636    /// String value of the enum field names used in the ProtoBuf definition.
637    ///
638    /// The values are not transformed in any way and thus are considered stable
639    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
640    pub fn as_str_name(&self) -> &'static str {
641        match self {
642            Self::Unspecified => "AVAILABLE_INFO_STORAGES_UNSPECIFIED",
643            Self::Files => "FILES",
644            Self::Redis => "REDIS",
645            Self::Postgres => "POSTGRES",
646        }
647    }
648    /// Creates an enum from field names used in the ProtoBuf definition.
649    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
650        match value {
651            "AVAILABLE_INFO_STORAGES_UNSPECIFIED" => Some(Self::Unspecified),
652            "FILES" => Some(Self::Files),
653            "REDIS" => Some(Self::Redis),
654            "POSTGRES" => Some(Self::Postgres),
655            _ => None,
656        }
657    }
658}
659#[derive(serde::Serialize, serde::Deserialize)]
660#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
661#[repr(i32)]
662pub enum Hook {
663    Unspecified = 0,
664    PreCreate = 1,
665    PostCreate = 2,
666    PostReceive = 3,
667    PreTerminate = 4,
668    PostTerminate = 5,
669    PostFinish = 6,
670}
671impl Hook {
672    /// String value of the enum field names used in the ProtoBuf definition.
673    ///
674    /// The values are not transformed in any way and thus are considered stable
675    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
676    pub fn as_str_name(&self) -> &'static str {
677        match self {
678            Self::Unspecified => "HOOK_UNSPECIFIED",
679            Self::PreCreate => "PRE_CREATE",
680            Self::PostCreate => "POST_CREATE",
681            Self::PostReceive => "POST_RECEIVE",
682            Self::PreTerminate => "PRE_TERMINATE",
683            Self::PostTerminate => "POST_TERMINATE",
684            Self::PostFinish => "POST_FINISH",
685        }
686    }
687    /// Creates an enum from field names used in the ProtoBuf definition.
688    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
689        match value {
690            "HOOK_UNSPECIFIED" => Some(Self::Unspecified),
691            "PRE_CREATE" => Some(Self::PreCreate),
692            "POST_CREATE" => Some(Self::PostCreate),
693            "POST_RECEIVE" => Some(Self::PostReceive),
694            "PRE_TERMINATE" => Some(Self::PreTerminate),
695            "POST_TERMINATE" => Some(Self::PostTerminate),
696            "POST_FINISH" => Some(Self::PostFinish),
697            _ => None,
698        }
699    }
700}
701#[derive(serde::Serialize, serde::Deserialize)]
702#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
703#[repr(i32)]
704pub enum Format {
705    Unspecified = 0,
706    Default = 1,
707    V2 = 2,
708}
709impl Format {
710    /// String value of the enum field names used in the ProtoBuf definition.
711    ///
712    /// The values are not transformed in any way and thus are considered stable
713    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
714    pub fn as_str_name(&self) -> &'static str {
715        match self {
716            Self::Unspecified => "FORMAT_UNSPECIFIED",
717            Self::Default => "DEFAULT",
718            Self::V2 => "V2",
719        }
720    }
721    /// Creates an enum from field names used in the ProtoBuf definition.
722    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
723        match value {
724            "FORMAT_UNSPECIFIED" => Some(Self::Unspecified),
725            "DEFAULT" => Some(Self::Default),
726            "V2" => Some(Self::V2),
727            _ => None,
728        }
729    }
730}
731#[derive(serde::Serialize, serde::Deserialize)]
732#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
733#[repr(i32)]
734pub enum Extension {
735    Unspecified = 0,
736    Getting = 1,
737    Creation = 2,
738    CreationWithUpload = 3,
739    CreationDeferLength = 4,
740    Termination = 5,
741    Concatenation = 6,
742    Checksum = 7,
743}
744impl Extension {
745    /// String value of the enum field names used in the ProtoBuf definition.
746    ///
747    /// The values are not transformed in any way and thus are considered stable
748    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
749    pub fn as_str_name(&self) -> &'static str {
750        match self {
751            Self::Unspecified => "EXTENSION_UNSPECIFIED",
752            Self::Getting => "GETTING",
753            Self::Creation => "CREATION",
754            Self::CreationWithUpload => "CREATION_WITH_UPLOAD",
755            Self::CreationDeferLength => "CREATION_DEFER_LENGTH",
756            Self::Termination => "TERMINATION",
757            Self::Concatenation => "CONCATENATION",
758            Self::Checksum => "CHECKSUM",
759        }
760    }
761    /// Creates an enum from field names used in the ProtoBuf definition.
762    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
763        match value {
764            "EXTENSION_UNSPECIFIED" => Some(Self::Unspecified),
765            "GETTING" => Some(Self::Getting),
766            "CREATION" => Some(Self::Creation),
767            "CREATION_WITH_UPLOAD" => Some(Self::CreationWithUpload),
768            "CREATION_DEFER_LENGTH" => Some(Self::CreationDeferLength),
769            "TERMINATION" => Some(Self::Termination),
770            "CONCATENATION" => Some(Self::Concatenation),
771            "CHECKSUM" => Some(Self::Checksum),
772            _ => None,
773        }
774    }
775}