diff --git a/Cargo.toml b/Cargo.toml index 6dac0e66..b364e529 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -13,5 +13,6 @@ members = [ "bigquery", "spanner-derive", "artifact-registry", - "kms" + "kms", + "monitoring" ] diff --git a/googleapis/Cargo.toml b/googleapis/Cargo.toml index 5bee19fc..55edf212 100644 --- a/googleapis/Cargo.toml +++ b/googleapis/Cargo.toml @@ -27,5 +27,6 @@ storage = [] artifact-registry = [] kms = [] bigquery = [] +monitoring = [] generate = ["dep:tonic-build", "dep:prost-build"] bytes = [] diff --git a/googleapis/build.rs b/googleapis/build.rs index d816d716..685e5248 100644 --- a/googleapis/build.rs +++ b/googleapis/build.rs @@ -41,6 +41,9 @@ fn generate(config: prost_build::Config, out_dir: impl AsRef) { "googleapis/google/cloud/kms/v1/service.proto", "googleapis/google/cloud/kms/v1/resources.proto", "googleapis/google/cloud/kms/v1/ekm_service.proto", + "googleapis/google/monitoring/v3/metric_service.proto", + "googleapis/google/monitoring/v3/metric.proto", + "googleapis/google/monitoring/v3/common.proto", ], &["googleapis"], // specify the root location to search proto dependencies ) diff --git a/googleapis/src/bytes/google.api.rs b/googleapis/src/bytes/google.api.rs index cd38789a..e3926d9d 100644 --- a/googleapis/src/bytes/google.api.rs +++ b/googleapis/src/bytes/google.api.rs @@ -2,7 +2,6 @@ /// Defines the HTTP configuration for an API service. It contains a list of /// [HttpRule][google.api.HttpRule], each specifying the mapping of an RPC method /// to one or more HTTP REST API methods. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Http { /// A list of HTTP configuration rules that apply to individual API methods. @@ -283,7 +282,6 @@ pub struct Http { /// If an API needs to use a JSON array for request or response body, it can map /// the request or response body to a repeated field. However, some gRPC /// Transcoding implementations may not support this feature. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct HttpRule { /// Selects a method to which this rule applies. @@ -324,7 +322,6 @@ pub mod http_rule { /// Determines the URL pattern is matched by this rules. This pattern can be /// used with any of the {get|put|post|delete|patch} methods. A custom method /// can be defined using the 'custom' field. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Pattern { /// Maps to HTTP GET. Used for listing and getting information about @@ -352,7 +349,6 @@ pub mod http_rule { } } /// A custom pattern is used for defining custom HTTP verb. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CustomHttpPattern { /// The name of this custom HTTP verb. @@ -412,14 +408,14 @@ impl LaunchStage { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - LaunchStage::Unspecified => "LAUNCH_STAGE_UNSPECIFIED", - LaunchStage::Unimplemented => "UNIMPLEMENTED", - LaunchStage::Prelaunch => "PRELAUNCH", - LaunchStage::EarlyAccess => "EARLY_ACCESS", - LaunchStage::Alpha => "ALPHA", - LaunchStage::Beta => "BETA", - LaunchStage::Ga => "GA", - LaunchStage::Deprecated => "DEPRECATED", + Self::Unspecified => "LAUNCH_STAGE_UNSPECIFIED", + Self::Unimplemented => "UNIMPLEMENTED", + Self::Prelaunch => "PRELAUNCH", + Self::EarlyAccess => "EARLY_ACCESS", + Self::Alpha => "ALPHA", + Self::Beta => "BETA", + Self::Ga => "GA", + Self::Deprecated => "DEPRECATED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -438,7 +434,6 @@ impl LaunchStage { } } /// Required information for every language. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CommonLanguageSettings { /// Link to automatically generated reference documentation. Example: @@ -451,7 +446,6 @@ pub struct CommonLanguageSettings { pub destinations: ::prost::alloc::vec::Vec, } /// Details about how and where to publish client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ClientLibrarySettings { /// Version of the API to apply these settings to. This is the full protobuf @@ -494,7 +488,6 @@ pub struct ClientLibrarySettings { /// This message configures the settings for publishing [Google Cloud Client /// libraries]() /// generated from the service config. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Publishing { /// A list of API method settings, e.g. the behavior for methods that use the @@ -543,7 +536,6 @@ pub struct Publishing { pub rest_reference_documentation_uri: ::prost::alloc::string::String, } /// Settings for Java client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct JavaSettings { /// The package name to use in Java. Clobbers the java_package option @@ -583,7 +575,6 @@ pub struct JavaSettings { pub common: ::core::option::Option, } /// Settings for C++ client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CppSettings { /// Some settings. @@ -591,7 +582,6 @@ pub struct CppSettings { pub common: ::core::option::Option, } /// Settings for Php client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PhpSettings { /// Some settings. @@ -599,7 +589,6 @@ pub struct PhpSettings { pub common: ::core::option::Option, } /// Settings for Python client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PythonSettings { /// Some settings. @@ -616,7 +605,6 @@ pub mod python_settings { /// Experimental features to be included during client library generation. /// These fields will be deprecated once the feature graduates and is enabled /// by default. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ExperimentalFeatures { /// Enables generation of asynchronous REST clients if `rest` transport is @@ -628,7 +616,6 @@ pub mod python_settings { } } /// Settings for Node client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct NodeSettings { /// Some settings. @@ -636,7 +623,6 @@ pub struct NodeSettings { pub common: ::core::option::Option, } /// Settings for Dotnet client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DotnetSettings { /// Some settings. @@ -682,7 +668,6 @@ pub struct DotnetSettings { pub handwritten_signatures: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Settings for Ruby client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RubySettings { /// Some settings. @@ -690,7 +675,6 @@ pub struct RubySettings { pub common: ::core::option::Option, } /// Settings for Go client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GoSettings { /// Some settings. @@ -698,7 +682,6 @@ pub struct GoSettings { pub common: ::core::option::Option, } /// Describes the generator configuration for a method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MethodSettings { /// The fully qualified name of the method, for which the options below apply. @@ -749,7 +732,6 @@ pub mod method_settings { /// All default values below are from those used in the client library /// generators (e.g. /// [Java]()). - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct LongRunning { /// Initial delay after which the first poll request will be made. @@ -800,16 +782,14 @@ impl ClientLibraryOrganization { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ClientLibraryOrganization::Unspecified => { - "CLIENT_LIBRARY_ORGANIZATION_UNSPECIFIED" - } - ClientLibraryOrganization::Cloud => "CLOUD", - ClientLibraryOrganization::Ads => "ADS", - ClientLibraryOrganization::Photos => "PHOTOS", - ClientLibraryOrganization::StreetView => "STREET_VIEW", - ClientLibraryOrganization::Shopping => "SHOPPING", - ClientLibraryOrganization::Geo => "GEO", - ClientLibraryOrganization::GenerativeAi => "GENERATIVE_AI", + Self::Unspecified => "CLIENT_LIBRARY_ORGANIZATION_UNSPECIFIED", + Self::Cloud => "CLOUD", + Self::Ads => "ADS", + Self::Photos => "PHOTOS", + Self::StreetView => "STREET_VIEW", + Self::Shopping => "SHOPPING", + Self::Geo => "GEO", + Self::GenerativeAi => "GENERATIVE_AI", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -847,11 +827,9 @@ impl ClientLibraryDestination { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ClientLibraryDestination::Unspecified => { - "CLIENT_LIBRARY_DESTINATION_UNSPECIFIED" - } - ClientLibraryDestination::Github => "GITHUB", - ClientLibraryDestination::PackageManager => "PACKAGE_MANAGER", + Self::Unspecified => "CLIENT_LIBRARY_DESTINATION_UNSPECIFIED", + Self::Github => "GITHUB", + Self::PackageManager => "PACKAGE_MANAGER", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -927,15 +905,15 @@ impl FieldBehavior { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - FieldBehavior::Unspecified => "FIELD_BEHAVIOR_UNSPECIFIED", - FieldBehavior::Optional => "OPTIONAL", - FieldBehavior::Required => "REQUIRED", - FieldBehavior::OutputOnly => "OUTPUT_ONLY", - FieldBehavior::InputOnly => "INPUT_ONLY", - FieldBehavior::Immutable => "IMMUTABLE", - FieldBehavior::UnorderedList => "UNORDERED_LIST", - FieldBehavior::NonEmptyDefault => "NON_EMPTY_DEFAULT", - FieldBehavior::Identifier => "IDENTIFIER", + Self::Unspecified => "FIELD_BEHAVIOR_UNSPECIFIED", + Self::Optional => "OPTIONAL", + Self::Required => "REQUIRED", + Self::OutputOnly => "OUTPUT_ONLY", + Self::InputOnly => "INPUT_ONLY", + Self::Immutable => "IMMUTABLE", + Self::UnorderedList => "UNORDERED_LIST", + Self::NonEmptyDefault => "NON_EMPTY_DEFAULT", + Self::Identifier => "IDENTIFIER", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1001,7 +979,6 @@ impl FieldBehavior { /// pattern: "folders/{folder}/logs/{log}" /// pattern: "organizations/{organization}/logs/{log}" /// pattern: "billingAccounts/{billing_account}/logs/{log}" -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ResourceDescriptor { /// The resource type. It must be in the format of @@ -1118,9 +1095,9 @@ pub mod resource_descriptor { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - History::Unspecified => "HISTORY_UNSPECIFIED", - History::OriginallySinglePattern => "ORIGINALLY_SINGLE_PATTERN", - History::FutureMultiPattern => "FUTURE_MULTI_PATTERN", + Self::Unspecified => "HISTORY_UNSPECIFIED", + Self::OriginallySinglePattern => "ORIGINALLY_SINGLE_PATTERN", + Self::FutureMultiPattern => "FUTURE_MULTI_PATTERN", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1166,8 +1143,8 @@ pub mod resource_descriptor { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Style::Unspecified => "STYLE_UNSPECIFIED", - Style::DeclarativeFriendly => "DECLARATIVE_FRIENDLY", + Self::Unspecified => "STYLE_UNSPECIFIED", + Self::DeclarativeFriendly => "DECLARATIVE_FRIENDLY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1182,7 +1159,6 @@ pub mod resource_descriptor { } /// Defines a proto annotation that describes a string field that refers to /// an API resource. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ResourceReference { /// The resource type that the annotated field references. @@ -1580,7 +1556,6 @@ pub struct ResourceReference { /// /// x-goog-request-params: /// table_location=instances/instance_bar&routing_id=prof_qux -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RoutingRule { /// A collection of Routing Parameter specifications. @@ -1593,7 +1568,6 @@ pub struct RoutingRule { pub routing_parameters: ::prost::alloc::vec::Vec, } /// A projection from an input message to the GRPC or REST header. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RoutingParameter { /// A request field to extract the header key-value pair from. @@ -1656,3 +1630,697 @@ pub struct RoutingParameter { #[prost(string, tag = "2")] pub path_template: ::prost::alloc::string::String, } +/// A description of a label. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct LabelDescriptor { + /// The label key. + #[prost(string, tag = "1")] + pub key: ::prost::alloc::string::String, + /// The type of data that can be assigned to the label. + #[prost(enumeration = "label_descriptor::ValueType", tag = "2")] + pub value_type: i32, + /// A human-readable description for the label. + #[prost(string, tag = "3")] + pub description: ::prost::alloc::string::String, +} +/// Nested message and enum types in `LabelDescriptor`. +pub mod label_descriptor { + /// Value types that can be used as label values. + #[derive( + Clone, + Copy, + Debug, + PartialEq, + Eq, + Hash, + PartialOrd, + Ord, + ::prost::Enumeration + )] + #[repr(i32)] + pub enum ValueType { + /// A variable-length string. This is the default. + String = 0, + /// Boolean; true or false. + Bool = 1, + /// A 64-bit signed integer. + Int64 = 2, + } + impl ValueType { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::String => "STRING", + Self::Bool => "BOOL", + Self::Int64 => "INT64", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "STRING" => Some(Self::String), + "BOOL" => Some(Self::Bool), + "INT64" => Some(Self::Int64), + _ => None, + } + } + } +} +/// Defines a metric type and its schema. Once a metric descriptor is created, +/// deleting or altering it stops data collection and makes the metric type's +/// existing data unusable. +/// +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct MetricDescriptor { + /// The resource name of the metric descriptor. + #[prost(string, tag = "1")] + pub name: ::prost::alloc::string::String, + /// The metric type, including its DNS name prefix. The type is not + /// URL-encoded. All user-defined metric types have the DNS name + /// `custom.googleapis.com` or `external.googleapis.com`. Metric types should + /// use a natural hierarchical grouping. For example: + /// + /// "custom.googleapis.com/invoice/paid/amount" + /// "external.googleapis.com/prometheus/up" + /// "appengine.googleapis.com/http/server/response_latencies" + #[prost(string, tag = "8")] + pub r#type: ::prost::alloc::string::String, + /// The set of labels that can be used to describe a specific + /// instance of this metric type. For example, the + /// `appengine.googleapis.com/http/server/response_latencies` metric + /// type has a label for the HTTP response code, `response_code`, so + /// you can look at latencies for successful responses or just + /// for responses that failed. + #[prost(message, repeated, tag = "2")] + pub labels: ::prost::alloc::vec::Vec, + /// Whether the metric records instantaneous values, changes to a value, etc. + /// Some combinations of `metric_kind` and `value_type` might not be supported. + #[prost(enumeration = "metric_descriptor::MetricKind", tag = "3")] + pub metric_kind: i32, + /// Whether the measurement is an integer, a floating-point number, etc. + /// Some combinations of `metric_kind` and `value_type` might not be supported. + #[prost(enumeration = "metric_descriptor::ValueType", tag = "4")] + pub value_type: i32, + /// The units in which the metric value is reported. It is only applicable + /// if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The `unit` + /// defines the representation of the stored metric values. + /// + /// Different systems might scale the values to be more easily displayed (so a + /// value of `0.02kBy` _might_ be displayed as `20By`, and a value of + /// `3523kBy` _might_ be displayed as `3.5MBy`). However, if the `unit` is + /// `kBy`, then the value of the metric is always in thousands of bytes, no + /// matter how it might be displayed. + /// + /// If you want a custom metric to record the exact number of CPU-seconds used + /// by a job, you can create an `INT64 CUMULATIVE` metric whose `unit` is + /// `s{CPU}` (or equivalently `1s{CPU}` or just `s`). If the job uses 12,005 + /// CPU-seconds, then the value is written as `12005`. + /// + /// Alternatively, if you want a custom metric to record data in a more + /// granular way, you can create a `DOUBLE CUMULATIVE` metric whose `unit` is + /// `ks{CPU}`, and then write the value `12.005` (which is `12005/1000`), + /// or use `Kis{CPU}` and write `11.723` (which is `12005/1024`). + /// + /// The supported units are a subset of [The Unified Code for Units of + /// Measure]() standard: + /// + /// **Basic units (UNIT)** + /// + /// * `bit` bit + /// * `By` byte + /// * `s` second + /// * `min` minute + /// * `h` hour + /// * `d` day + /// * `1` dimensionless + /// + /// **Prefixes (PREFIX)** + /// + /// * `k` kilo (10^3) + /// * `M` mega (10^6) + /// * `G` giga (10^9) + /// * `T` tera (10^12) + /// * `P` peta (10^15) + /// * `E` exa (10^18) + /// * `Z` zetta (10^21) + /// * `Y` yotta (10^24) + /// + /// * `m` milli (10^-3) + /// * `u` micro (10^-6) + /// * `n` nano (10^-9) + /// * `p` pico (10^-12) + /// * `f` femto (10^-15) + /// * `a` atto (10^-18) + /// * `z` zepto (10^-21) + /// * `y` yocto (10^-24) + /// + /// * `Ki` kibi (2^10) + /// * `Mi` mebi (2^20) + /// * `Gi` gibi (2^30) + /// * `Ti` tebi (2^40) + /// * `Pi` pebi (2^50) + /// + /// **Grammar** + /// + /// The grammar also includes these connectors: + /// + /// * `/` division or ratio (as an infix operator). For examples, + /// `kBy/{email}` or `MiBy/10ms` (although you should almost never + /// have `/s` in a metric `unit`; rates should always be computed at + /// query time from the underlying cumulative or delta value). + /// * `.` multiplication or composition (as an infix operator). For + /// examples, `GBy.d` or `k{watt}.h`. + /// + /// The grammar for a unit is as follows: + /// + /// Expression = Component { "." Component } { "/" Component } ; + /// + /// Component = ( \[ PREFIX \] UNIT | "%" ) \[ Annotation \] + /// | Annotation + /// | "1" + /// ; + /// + /// Annotation = "{" NAME "}" ; + /// + /// Notes: + /// + /// * `Annotation` is just a comment if it follows a `UNIT`. If the annotation + /// is used alone, then the unit is equivalent to `1`. For examples, + /// `{request}/s == 1/s`, `By{transmitted}/s == By/s`. + /// * `NAME` is a sequence of non-blank printable ASCII characters not + /// containing `{` or `}`. + /// * `1` represents a unitary [dimensionless + /// unit]() of 1, such + /// as in `1/s`. It is typically used when none of the basic units are + /// appropriate. For example, "new users per day" can be represented as + /// `1/d` or `{new-users}/d` (and a metric value `5` would mean "5 new + /// users). Alternatively, "thousands of page views per day" would be + /// represented as `1000/d` or `k1/d` or `k{page_views}/d` (and a metric + /// value of `5.3` would mean "5300 page views per day"). + /// * `%` represents dimensionless value of 1/100, and annotates values giving + /// a percentage (so the metric values are typically in the range of 0..100, + /// and a metric value `3` means "3 percent"). + /// * `10^2.%` indicates a metric contains a ratio, typically in the range + /// 0..1, that will be multiplied by 100 and displayed as a percentage + /// (so a metric value `0.03` means "3 percent"). + #[prost(string, tag = "5")] + pub unit: ::prost::alloc::string::String, + /// A detailed description of the metric, which can be used in documentation. + #[prost(string, tag = "6")] + pub description: ::prost::alloc::string::String, + /// A concise name for the metric, which can be displayed in user interfaces. + /// Use sentence case without an ending period, for example "Request count". + /// This field is optional but it is recommended to be set for any metrics + /// associated with user-visible concepts, such as Quota. + #[prost(string, tag = "7")] + pub display_name: ::prost::alloc::string::String, + /// Optional. Metadata which can be used to guide usage of the metric. + #[prost(message, optional, tag = "10")] + pub metadata: ::core::option::Option, + /// Optional. The launch stage of the metric definition. + #[prost(enumeration = "LaunchStage", tag = "12")] + pub launch_stage: i32, + /// Read-only. If present, then a [time + /// series][google.monitoring.v3.TimeSeries], which is identified partially by + /// a metric type and a + /// [MonitoredResourceDescriptor][google.api.MonitoredResourceDescriptor], that + /// is associated with this metric type can only be associated with one of the + /// monitored resource types listed here. + #[prost(string, repeated, tag = "13")] + pub monitored_resource_types: ::prost::alloc::vec::Vec< + ::prost::alloc::string::String, + >, +} +/// Nested message and enum types in `MetricDescriptor`. +pub mod metric_descriptor { + /// Additional annotations that can be used to guide the usage of a metric. + #[derive(Clone, Copy, PartialEq, ::prost::Message)] + pub struct MetricDescriptorMetadata { + /// Deprecated. Must use the + /// [MetricDescriptor.launch_stage][google.api.MetricDescriptor.launch_stage] + /// instead. + #[deprecated] + #[prost(enumeration = "super::LaunchStage", tag = "1")] + pub launch_stage: i32, + /// The sampling period of metric data points. For metrics which are written + /// periodically, consecutive data points are stored at this time interval, + /// excluding data loss due to errors. Metrics with a higher granularity have + /// a smaller sampling period. + #[prost(message, optional, tag = "2")] + pub sample_period: ::core::option::Option<::prost_types::Duration>, + /// The delay of data points caused by ingestion. Data points older than this + /// age are guaranteed to be ingested and available to be read, excluding + /// data loss due to errors. + #[prost(message, optional, tag = "3")] + pub ingest_delay: ::core::option::Option<::prost_types::Duration>, + } + /// The kind of measurement. It describes how the data is reported. + /// For information on setting the start time and end time based on + /// the MetricKind, see [TimeInterval][google.monitoring.v3.TimeInterval]. + #[derive( + Clone, + Copy, + Debug, + PartialEq, + Eq, + Hash, + PartialOrd, + Ord, + ::prost::Enumeration + )] + #[repr(i32)] + pub enum MetricKind { + /// Do not use this default value. + Unspecified = 0, + /// An instantaneous measurement of a value. + Gauge = 1, + /// The change in a value during a time interval. + Delta = 2, + /// A value accumulated over a time interval. Cumulative + /// measurements in a time series should have the same start time + /// and increasing end times, until an event resets the cumulative + /// value to zero and sets a new start time for the following + /// points. + Cumulative = 3, + } + impl MetricKind { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::Unspecified => "METRIC_KIND_UNSPECIFIED", + Self::Gauge => "GAUGE", + Self::Delta => "DELTA", + Self::Cumulative => "CUMULATIVE", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "METRIC_KIND_UNSPECIFIED" => Some(Self::Unspecified), + "GAUGE" => Some(Self::Gauge), + "DELTA" => Some(Self::Delta), + "CUMULATIVE" => Some(Self::Cumulative), + _ => None, + } + } + } + /// The value type of a metric. + #[derive( + Clone, + Copy, + Debug, + PartialEq, + Eq, + Hash, + PartialOrd, + Ord, + ::prost::Enumeration + )] + #[repr(i32)] + pub enum ValueType { + /// Do not use this default value. + Unspecified = 0, + /// The value is a boolean. + /// This value type can be used only if the metric kind is `GAUGE`. + Bool = 1, + /// The value is a signed 64-bit integer. + Int64 = 2, + /// The value is a double precision floating point number. + Double = 3, + /// The value is a text string. + /// This value type can be used only if the metric kind is `GAUGE`. + String = 4, + /// The value is a [`Distribution`][google.api.Distribution]. + Distribution = 5, + /// The value is money. + Money = 6, + } + impl ValueType { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::Unspecified => "VALUE_TYPE_UNSPECIFIED", + Self::Bool => "BOOL", + Self::Int64 => "INT64", + Self::Double => "DOUBLE", + Self::String => "STRING", + Self::Distribution => "DISTRIBUTION", + Self::Money => "MONEY", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "VALUE_TYPE_UNSPECIFIED" => Some(Self::Unspecified), + "BOOL" => Some(Self::Bool), + "INT64" => Some(Self::Int64), + "DOUBLE" => Some(Self::Double), + "STRING" => Some(Self::String), + "DISTRIBUTION" => Some(Self::Distribution), + "MONEY" => Some(Self::Money), + _ => None, + } + } + } +} +/// A specific metric, identified by specifying values for all of the +/// labels of a [`MetricDescriptor`][google.api.MetricDescriptor]. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct Metric { + /// An existing metric type, see + /// [google.api.MetricDescriptor][google.api.MetricDescriptor]. For example, + /// `custom.googleapis.com/invoice/paid/amount`. + #[prost(string, tag = "3")] + pub r#type: ::prost::alloc::string::String, + /// The set of label values that uniquely identify this metric. All + /// labels listed in the `MetricDescriptor` must be assigned values. + #[prost(map = "string, string", tag = "2")] + pub labels: ::std::collections::HashMap< + ::prost::alloc::string::String, + ::prost::alloc::string::String, + >, +} +/// An object that describes the schema of a +/// [MonitoredResource][google.api.MonitoredResource] object using a type name +/// and a set of labels. For example, the monitored resource descriptor for +/// Google Compute Engine VM instances has a type of +/// `"gce_instance"` and specifies the use of the labels `"instance_id"` and +/// `"zone"` to identify particular VM instances. +/// +/// Different APIs can support different monitored resource types. APIs generally +/// provide a `list` method that returns the monitored resource descriptors used +/// by the API. +/// +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct MonitoredResourceDescriptor { + /// Optional. The resource name of the monitored resource descriptor: + /// `"projects/{project_id}/monitoredResourceDescriptors/{type}"` where + /// {type} is the value of the `type` field in this object and + /// {project_id} is a project ID that provides API-specific context for + /// accessing the type. APIs that do not use project information can use the + /// resource name format `"monitoredResourceDescriptors/{type}"`. + #[prost(string, tag = "5")] + pub name: ::prost::alloc::string::String, + /// Required. The monitored resource type. For example, the type + /// `"cloudsql_database"` represents databases in Google Cloud SQL. + /// For a list of types, see [Monitored resource + /// types]() + /// and [Logging resource + /// types](). + #[prost(string, tag = "1")] + pub r#type: ::prost::alloc::string::String, + /// Optional. A concise name for the monitored resource type that might be + /// displayed in user interfaces. It should be a Title Cased Noun Phrase, + /// without any article or other determiners. For example, + /// `"Google Cloud SQL Database"`. + #[prost(string, tag = "2")] + pub display_name: ::prost::alloc::string::String, + /// Optional. A detailed description of the monitored resource type that might + /// be used in documentation. + #[prost(string, tag = "3")] + pub description: ::prost::alloc::string::String, + /// Required. A set of labels used to describe instances of this monitored + /// resource type. For example, an individual Google Cloud SQL database is + /// identified by values for the labels `"database_id"` and `"zone"`. + #[prost(message, repeated, tag = "4")] + pub labels: ::prost::alloc::vec::Vec, + /// Optional. The launch stage of the monitored resource definition. + #[prost(enumeration = "LaunchStage", tag = "7")] + pub launch_stage: i32, +} +/// An object representing a resource that can be used for monitoring, logging, +/// billing, or other purposes. Examples include virtual machine instances, +/// databases, and storage devices such as disks. The `type` field identifies a +/// [MonitoredResourceDescriptor][google.api.MonitoredResourceDescriptor] object +/// that describes the resource's schema. Information in the `labels` field +/// identifies the actual resource and its attributes according to the schema. +/// For example, a particular Compute Engine VM instance could be represented by +/// the following object, because the +/// [MonitoredResourceDescriptor][google.api.MonitoredResourceDescriptor] for +/// `"gce_instance"` has labels +/// `"project_id"`, `"instance_id"` and `"zone"`: +/// +/// { "type": "gce_instance", +/// "labels": { "project_id": "my-project", +/// "instance_id": "12345678901234", +/// "zone": "us-central1-a" }} +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct MonitoredResource { + /// Required. The monitored resource type. This field must match + /// the `type` field of a + /// [MonitoredResourceDescriptor][google.api.MonitoredResourceDescriptor] + /// object. For example, the type of a Compute Engine VM instance is + /// `gce_instance`. Some descriptors include the service name in the type; for + /// example, the type of a Datastream stream is + /// `datastream.googleapis.com/Stream`. + #[prost(string, tag = "1")] + pub r#type: ::prost::alloc::string::String, + /// Required. Values for all of the labels listed in the associated monitored + /// resource descriptor. For example, Compute Engine VM instances use the + /// labels `"project_id"`, `"instance_id"`, and `"zone"`. + #[prost(map = "string, string", tag = "2")] + pub labels: ::std::collections::HashMap< + ::prost::alloc::string::String, + ::prost::alloc::string::String, + >, +} +/// Auxiliary metadata for a [MonitoredResource][google.api.MonitoredResource] +/// object. [MonitoredResource][google.api.MonitoredResource] objects contain the +/// minimum set of information to uniquely identify a monitored resource +/// instance. There is some other useful auxiliary metadata. Monitoring and +/// Logging use an ingestion pipeline to extract metadata for cloud resources of +/// all types, and store the metadata in this message. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct MonitoredResourceMetadata { + /// Output only. Values for predefined system metadata labels. + /// System labels are a kind of metadata extracted by Google, including + /// "machine_image", "vpc", "subnet_id", + /// "security_group", "name", etc. + /// System label values can be only strings, Boolean values, or a list of + /// strings. For example: + /// + /// { "name": "my-test-instance", + /// "security_group": \["a", "b", "c"\], + /// "spot_instance": false } + #[prost(message, optional, tag = "1")] + pub system_labels: ::core::option::Option<::prost_types::Struct>, + /// Output only. A map of user-defined metadata labels. + #[prost(map = "string, string", tag = "2")] + pub user_labels: ::std::collections::HashMap< + ::prost::alloc::string::String, + ::prost::alloc::string::String, + >, +} +/// `Distribution` contains summary statistics for a population of values. It +/// optionally contains a histogram representing the distribution of those values +/// across a set of buckets. +/// +/// The summary statistics are the count, mean, sum of the squared deviation from +/// the mean, the minimum, and the maximum of the set of population of values. +/// The histogram is based on a sequence of buckets and gives a count of values +/// that fall into each bucket. The boundaries of the buckets are given either +/// explicitly or by formulas for buckets of fixed or exponentially increasing +/// widths. +/// +/// Although it is not forbidden, it is generally a bad idea to include +/// non-finite values (infinities or NaNs) in the population of values, as this +/// will render the `mean` and `sum_of_squared_deviation` fields meaningless. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct Distribution { + /// The number of values in the population. Must be non-negative. This value + /// must equal the sum of the values in `bucket_counts` if a histogram is + /// provided. + #[prost(int64, tag = "1")] + pub count: i64, + /// The arithmetic mean of the values in the population. If `count` is zero + /// then this field must be zero. + #[prost(double, tag = "2")] + pub mean: f64, + /// The sum of squared deviations from the mean of the values in the + /// population. For values x_i this is: + /// + /// Sum[i=1..n]((x_i - mean)^2) + /// + /// Knuth, "The Art of Computer Programming", Vol. 2, page 232, 3rd edition + /// describes Welford's method for accumulating this sum in one pass. + /// + /// If `count` is zero then this field must be zero. + #[prost(double, tag = "3")] + pub sum_of_squared_deviation: f64, + /// If specified, contains the range of the population values. The field + /// must not be present if the `count` is zero. + #[prost(message, optional, tag = "4")] + pub range: ::core::option::Option, + /// Defines the histogram bucket boundaries. If the distribution does not + /// contain a histogram, then omit this field. + #[prost(message, optional, tag = "6")] + pub bucket_options: ::core::option::Option, + /// The number of values in each bucket of the histogram, as described in + /// `bucket_options`. If the distribution does not have a histogram, then omit + /// this field. If there is a histogram, then the sum of the values in + /// `bucket_counts` must equal the value in the `count` field of the + /// distribution. + /// + /// If present, `bucket_counts` should contain N values, where N is the number + /// of buckets specified in `bucket_options`. If you supply fewer than N + /// values, the remaining values are assumed to be 0. + /// + /// The order of the values in `bucket_counts` follows the bucket numbering + /// schemes described for the three bucket types. The first value must be the + /// count for the underflow bucket (number 0). The next N-2 values are the + /// counts for the finite buckets (number 1 through N-2). The N'th value in + /// `bucket_counts` is the count for the overflow bucket (number N-1). + #[prost(int64, repeated, tag = "7")] + pub bucket_counts: ::prost::alloc::vec::Vec, + /// Must be in increasing order of `value` field. + #[prost(message, repeated, tag = "10")] + pub exemplars: ::prost::alloc::vec::Vec, +} +/// Nested message and enum types in `Distribution`. +pub mod distribution { + /// The range of the population values. + #[derive(Clone, Copy, PartialEq, ::prost::Message)] + pub struct Range { + /// The minimum of the population values. + #[prost(double, tag = "1")] + pub min: f64, + /// The maximum of the population values. + #[prost(double, tag = "2")] + pub max: f64, + } + /// `BucketOptions` describes the bucket boundaries used to create a histogram + /// for the distribution. The buckets can be in a linear sequence, an + /// exponential sequence, or each bucket can be specified explicitly. + /// `BucketOptions` does not include the number of values in each bucket. + /// + /// A bucket has an inclusive lower bound and exclusive upper bound for the + /// values that are counted for that bucket. The upper bound of a bucket must + /// be strictly greater than the lower bound. The sequence of N buckets for a + /// distribution consists of an underflow bucket (number 0), zero or more + /// finite buckets (number 1 through N - 2) and an overflow bucket (number N - + /// 1). The buckets are contiguous: the lower bound of bucket i (i > 0) is the + /// same as the upper bound of bucket i - 1. The buckets span the whole range + /// of finite values: lower bound of the underflow bucket is -infinity and the + /// upper bound of the overflow bucket is +infinity. The finite buckets are + /// so-called because both bounds are finite. + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct BucketOptions { + /// Exactly one of these three fields must be set. + #[prost(oneof = "bucket_options::Options", tags = "1, 2, 3")] + pub options: ::core::option::Option, + } + /// Nested message and enum types in `BucketOptions`. + pub mod bucket_options { + /// Specifies a linear sequence of buckets that all have the same width + /// (except overflow and underflow). Each bucket represents a constant + /// absolute uncertainty on the specific value in the bucket. + /// + /// There are `num_finite_buckets + 2` (= N) buckets. Bucket `i` has the + /// following boundaries: + /// + /// Upper bound (0 <= i < N-1): offset + (width * i). + /// + /// Lower bound (1 <= i < N): offset + (width * (i - 1)). + #[derive(Clone, Copy, PartialEq, ::prost::Message)] + pub struct Linear { + /// Must be greater than 0. + #[prost(int32, tag = "1")] + pub num_finite_buckets: i32, + /// Must be greater than 0. + #[prost(double, tag = "2")] + pub width: f64, + /// Lower bound of the first bucket. + #[prost(double, tag = "3")] + pub offset: f64, + } + /// Specifies an exponential sequence of buckets that have a width that is + /// proportional to the value of the lower bound. Each bucket represents a + /// constant relative uncertainty on a specific value in the bucket. + /// + /// There are `num_finite_buckets + 2` (= N) buckets. Bucket `i` has the + /// following boundaries: + /// + /// Upper bound (0 <= i < N-1): scale * (growth_factor ^ i). + /// + /// Lower bound (1 <= i < N): scale * (growth_factor ^ (i - 1)). + #[derive(Clone, Copy, PartialEq, ::prost::Message)] + pub struct Exponential { + /// Must be greater than 0. + #[prost(int32, tag = "1")] + pub num_finite_buckets: i32, + /// Must be greater than 1. + #[prost(double, tag = "2")] + pub growth_factor: f64, + /// Must be greater than 0. + #[prost(double, tag = "3")] + pub scale: f64, + } + /// Specifies a set of buckets with arbitrary widths. + /// + /// There are `size(bounds) + 1` (= N) buckets. Bucket `i` has the following + /// boundaries: + /// + /// Upper bound (0 <= i < N-1): bounds\[i\] + /// Lower bound (1 <= i < N); bounds\[i - 1\] + /// + /// The `bounds` field must contain at least one element. If `bounds` has + /// only one element, then there are no finite buckets, and that single + /// element is the common boundary of the overflow and underflow buckets. + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct Explicit { + /// The values must be monotonically increasing. + #[prost(double, repeated, tag = "1")] + pub bounds: ::prost::alloc::vec::Vec, + } + /// Exactly one of these three fields must be set. + #[derive(Clone, PartialEq, ::prost::Oneof)] + pub enum Options { + /// The linear bucket. + #[prost(message, tag = "1")] + LinearBuckets(Linear), + /// The exponential buckets. + #[prost(message, tag = "2")] + ExponentialBuckets(Exponential), + /// The explicit buckets. + #[prost(message, tag = "3")] + ExplicitBuckets(Explicit), + } + } + /// Exemplars are example points that may be used to annotate aggregated + /// distribution values. They are metadata that gives information about a + /// particular value added to a Distribution bucket, such as a trace ID that + /// was active when a value was added. They may contain further information, + /// such as a example values and timestamps, origin, etc. + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct Exemplar { + /// Value of the exemplar point. This value determines to which bucket the + /// exemplar belongs. + #[prost(double, tag = "1")] + pub value: f64, + /// The observation (sampling) time of the above value. + #[prost(message, optional, tag = "2")] + pub timestamp: ::core::option::Option<::prost_types::Timestamp>, + /// Contextual information about the example value. Examples are: + /// + /// Trace: type.googleapis.com/google.monitoring.v3.SpanContext + /// + /// Literal string: type.googleapis.com/google.protobuf.StringValue + /// + /// Labels dropped during aggregation: + /// type.googleapis.com/google.monitoring.v3.DroppedLabels + /// + /// There may be only a single attachment of any given message type in a + /// single exemplar, and this is enforced by the system. + #[prost(message, repeated, tag = "3")] + pub attachments: ::prost::alloc::vec::Vec<::prost_types::Any>, + } +} diff --git a/googleapis/src/bytes/google.cloud.bigquery.storage.v1.rs b/googleapis/src/bytes/google.cloud.bigquery.storage.v1.rs index 6c7ff71c..1d897b6b 100644 --- a/googleapis/src/bytes/google.cloud.bigquery.storage.v1.rs +++ b/googleapis/src/bytes/google.cloud.bigquery.storage.v1.rs @@ -5,7 +5,6 @@ /// /// /// See code samples on how this message can be deserialized. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ArrowSchema { /// IPC serialized Arrow schema. @@ -13,7 +12,6 @@ pub struct ArrowSchema { pub serialized_schema: ::prost::bytes::Bytes, } /// Arrow RecordBatch. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ArrowRecordBatch { /// IPC-serialized Arrow RecordBatch. @@ -26,7 +24,6 @@ pub struct ArrowRecordBatch { pub row_count: i64, } /// Contains options specific to Arrow Serialization. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ArrowSerializationOptions { /// The compression codec to use for Arrow buffers in serialized record @@ -64,9 +61,9 @@ pub mod arrow_serialization_options { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - CompressionCodec::CompressionUnspecified => "COMPRESSION_UNSPECIFIED", - CompressionCodec::Lz4Frame => "LZ4_FRAME", - CompressionCodec::Zstd => "ZSTD", + Self::CompressionUnspecified => "COMPRESSION_UNSPECIFIED", + Self::Lz4Frame => "LZ4_FRAME", + Self::Zstd => "ZSTD", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -81,7 +78,6 @@ pub mod arrow_serialization_options { } } /// Avro schema. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AvroSchema { /// Json serialized schema, as described at @@ -90,7 +86,6 @@ pub struct AvroSchema { pub schema: ::prost::alloc::string::String, } /// Avro rows. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AvroRows { /// Binary serialized rows in a block. @@ -103,7 +98,6 @@ pub struct AvroRows { pub row_count: i64, } /// Contains options specific to Avro Serialization. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AvroSerializationOptions { /// Enable displayName attribute in Avro schema. @@ -120,7 +114,6 @@ pub struct AvroSerializationOptions { pub enable_display_name_attribute: bool, } /// ProtoSchema describes the schema of the serialized protocol buffer data rows. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ProtoSchema { /// Descriptor for input message. The provided descriptor must be self @@ -135,7 +128,6 @@ pub struct ProtoSchema { #[prost(message, optional, tag = "1")] pub proto_descriptor: ::core::option::Option<::prost_types::DescriptorProto>, } -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ProtoRows { /// A sequence of rows serialized as a Protocol Buffer. @@ -148,7 +140,6 @@ pub struct ProtoRows { /// Schema of a table. This schema is a subset of /// google.cloud.bigquery.v2.TableSchema containing information necessary to /// generate valid message to write to BigQuery. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TableSchema { /// Describes the fields in a table. @@ -156,7 +147,6 @@ pub struct TableSchema { pub fields: ::prost::alloc::vec::Vec, } /// TableFieldSchema defines a single field/column within a table schema. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TableFieldSchema { /// Required. The field name. The name must contain only letters (a-z, A-Z), @@ -244,7 +234,6 @@ pub struct TableFieldSchema { /// Nested message and enum types in `TableFieldSchema`. pub mod table_field_schema { /// Represents the type of a field element. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct FieldElementType { /// Required. The type of a field element. @@ -306,23 +295,23 @@ pub mod table_field_schema { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Type::Unspecified => "TYPE_UNSPECIFIED", - Type::String => "STRING", - Type::Int64 => "INT64", - Type::Double => "DOUBLE", - Type::Struct => "STRUCT", - Type::Bytes => "BYTES", - Type::Bool => "BOOL", - Type::Timestamp => "TIMESTAMP", - Type::Date => "DATE", - Type::Time => "TIME", - Type::Datetime => "DATETIME", - Type::Geography => "GEOGRAPHY", - Type::Numeric => "NUMERIC", - Type::Bignumeric => "BIGNUMERIC", - Type::Interval => "INTERVAL", - Type::Json => "JSON", - Type::Range => "RANGE", + Self::Unspecified => "TYPE_UNSPECIFIED", + Self::String => "STRING", + Self::Int64 => "INT64", + Self::Double => "DOUBLE", + Self::Struct => "STRUCT", + Self::Bytes => "BYTES", + Self::Bool => "BOOL", + Self::Timestamp => "TIMESTAMP", + Self::Date => "DATE", + Self::Time => "TIME", + Self::Datetime => "DATETIME", + Self::Geography => "GEOGRAPHY", + Self::Numeric => "NUMERIC", + Self::Bignumeric => "BIGNUMERIC", + Self::Interval => "INTERVAL", + Self::Json => "JSON", + Self::Range => "RANGE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -375,10 +364,10 @@ pub mod table_field_schema { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Mode::Unspecified => "MODE_UNSPECIFIED", - Mode::Nullable => "NULLABLE", - Mode::Required => "REQUIRED", - Mode::Repeated => "REPEATED", + Self::Unspecified => "MODE_UNSPECIFIED", + Self::Nullable => "NULLABLE", + Self::Required => "REQUIRED", + Self::Repeated => "REPEATED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -394,7 +383,6 @@ pub mod table_field_schema { } } /// Information about the ReadSession. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadSession { /// Output only. Unique identifier for the session, in the form @@ -464,7 +452,6 @@ pub struct ReadSession { /// Nested message and enum types in `ReadSession`. pub mod read_session { /// Additional attributes when reading a table. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct TableModifiers { /// The snapshot time of the table. If not set, interpreted as now. @@ -472,7 +459,6 @@ pub mod read_session { pub snapshot_time: ::core::option::Option<::prost_types::Timestamp>, } /// Options dictating how we read a table. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TableReadOptions { /// Optional. The names of the fields in the table to be returned. If no @@ -594,10 +580,8 @@ pub mod read_session { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ResponseCompressionCodec::Unspecified => { - "RESPONSE_COMPRESSION_CODEC_UNSPECIFIED" - } - ResponseCompressionCodec::Lz4 => "RESPONSE_COMPRESSION_CODEC_LZ4", + Self::Unspecified => "RESPONSE_COMPRESSION_CODEC_UNSPECIFIED", + Self::Lz4 => "RESPONSE_COMPRESSION_CODEC_LZ4", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -609,7 +593,6 @@ pub mod read_session { } } } - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum OutputFormatSerializationOptions { /// Optional. Options specific to the Apache Arrow output format. @@ -623,7 +606,6 @@ pub mod read_session { /// The schema for the read. If read_options.selected_fields is set, the /// schema may be different from the table schema as it will only contain /// the selected fields. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Schema { /// Output only. Avro schema. @@ -637,7 +619,6 @@ pub mod read_session { /// Information about a single stream that gets data out of the storage system. /// Most of the information about `ReadStream` instances is aggregated, making /// `ReadStream` lightweight. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadStream { /// Output only. Name of the stream, in the form @@ -646,7 +627,6 @@ pub struct ReadStream { pub name: ::prost::alloc::string::String, } /// Information about a single stream that gets data inside the storage system. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct WriteStream { /// Output only. Name of the stream, in the form @@ -714,10 +694,10 @@ pub mod write_stream { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Type::Unspecified => "TYPE_UNSPECIFIED", - Type::Committed => "COMMITTED", - Type::Pending => "PENDING", - Type::Buffered => "BUFFERED", + Self::Unspecified => "TYPE_UNSPECIFIED", + Self::Committed => "COMMITTED", + Self::Pending => "PENDING", + Self::Buffered => "BUFFERED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -758,8 +738,8 @@ pub mod write_stream { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - WriteMode::Unspecified => "WRITE_MODE_UNSPECIFIED", - WriteMode::Insert => "INSERT", + Self::Unspecified => "WRITE_MODE_UNSPECIFIED", + Self::Insert => "INSERT", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -792,9 +772,9 @@ impl DataFormat { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - DataFormat::Unspecified => "DATA_FORMAT_UNSPECIFIED", - DataFormat::Avro => "AVRO", - DataFormat::Arrow => "ARROW", + Self::Unspecified => "DATA_FORMAT_UNSPECIFIED", + Self::Avro => "AVRO", + Self::Arrow => "ARROW", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -830,9 +810,9 @@ impl WriteStreamView { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - WriteStreamView::Unspecified => "WRITE_STREAM_VIEW_UNSPECIFIED", - WriteStreamView::Basic => "BASIC", - WriteStreamView::Full => "FULL", + Self::Unspecified => "WRITE_STREAM_VIEW_UNSPECIFIED", + Self::Basic => "BASIC", + Self::Full => "FULL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -846,7 +826,6 @@ impl WriteStreamView { } } /// Request message for `CreateReadSession`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateReadSessionRequest { /// Required. The request project that owns the session, in the form of @@ -880,7 +859,6 @@ pub struct CreateReadSessionRequest { pub preferred_min_stream_count: i32, } /// Request message for `ReadRows`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadRowsRequest { /// Required. Stream to read rows from. @@ -893,7 +871,6 @@ pub struct ReadRowsRequest { pub offset: i64, } /// Information on if the current connection is being throttled. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ThrottleState { /// How much this connection is being throttled. Zero means no throttling, @@ -902,7 +879,6 @@ pub struct ThrottleState { pub throttle_percent: i32, } /// Estimated stream statistics for a given read Stream. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct StreamStats { /// Represents the progress of the current stream. @@ -911,7 +887,6 @@ pub struct StreamStats { } /// Nested message and enum types in `StreamStats`. pub mod stream_stats { - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct Progress { /// The fraction of rows assigned to the stream that have been processed by @@ -936,7 +911,6 @@ pub mod stream_stats { } /// Response from calling `ReadRows` may include row data, progress and /// throttling information. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadRowsResponse { /// Number of serialized rows in the rows block. @@ -979,7 +953,6 @@ pub struct ReadRowsResponse { /// Nested message and enum types in `ReadRowsResponse`. pub mod read_rows_response { /// Row data is returned in format specified during session creation. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Rows { /// Serialized row data in AVRO format. @@ -994,7 +967,6 @@ pub mod read_rows_response { /// the selected fields. This schema is equivalent to the one returned by /// CreateSession. This field is only populated in the first ReadRowsResponse /// RPC. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Schema { /// Output only. Avro schema. @@ -1006,7 +978,6 @@ pub mod read_rows_response { } } /// Request message for `SplitReadStream`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct SplitReadStreamRequest { /// Required. Name of the stream to split. @@ -1023,7 +994,6 @@ pub struct SplitReadStreamRequest { pub fraction: f64, } /// Response message for `SplitReadStream`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct SplitReadStreamResponse { /// Primary stream, which contains the beginning portion of @@ -1037,7 +1007,6 @@ pub struct SplitReadStreamResponse { pub remainder_stream: ::core::option::Option, } /// Request message for `CreateWriteStream`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateWriteStreamRequest { /// Required. Reference to the table to which the stream belongs, in the format @@ -1057,7 +1026,6 @@ pub struct CreateWriteStreamRequest { /// /// The size of a single AppendRowsRequest must be less than 10 MB in size. /// Requests larger than this return an error, typically `INVALID_ARGUMENT`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AppendRowsRequest { /// Required. The write_stream identifies the append operation. It must be @@ -1152,7 +1120,6 @@ pub struct AppendRowsRequest { pub mod append_rows_request { /// ProtoData contains the data rows and schema when constructing append /// requests. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ProtoData { /// The protocol buffer schema used to serialize the data. Provide this value @@ -1204,11 +1171,9 @@ pub mod append_rows_request { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - MissingValueInterpretation::Unspecified => { - "MISSING_VALUE_INTERPRETATION_UNSPECIFIED" - } - MissingValueInterpretation::NullValue => "NULL_VALUE", - MissingValueInterpretation::DefaultValue => "DEFAULT_VALUE", + Self::Unspecified => "MISSING_VALUE_INTERPRETATION_UNSPECIFIED", + Self::NullValue => "NULL_VALUE", + Self::DefaultValue => "DEFAULT_VALUE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1225,7 +1190,6 @@ pub mod append_rows_request { /// request and currently, it will be ignored if specified in following /// requests. Following requests must have data in the same format as the /// initial request. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Rows { /// Rows in proto format. @@ -1234,7 +1198,6 @@ pub mod append_rows_request { } } /// Response message for `AppendRows`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AppendRowsResponse { /// If backend detects a schema update, pass it to user so that user can @@ -1257,7 +1220,6 @@ pub struct AppendRowsResponse { /// Nested message and enum types in `AppendRowsResponse`. pub mod append_rows_response { /// AppendResult is returned for successful append requests. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AppendResult { /// The row offset at which the last append occurred. The offset will not be @@ -1265,7 +1227,6 @@ pub mod append_rows_response { #[prost(message, optional, tag = "1")] pub offset: ::core::option::Option, } - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Response { /// Result if the append is successful. @@ -1296,7 +1257,6 @@ pub mod append_rows_response { } } /// Request message for `GetWriteStreamRequest`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetWriteStreamRequest { /// Required. Name of the stream to get, in the form of @@ -1309,7 +1269,6 @@ pub struct GetWriteStreamRequest { pub view: i32, } /// Request message for `BatchCommitWriteStreams`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchCommitWriteStreamsRequest { /// Required. Parent table that all the streams should belong to, in the form @@ -1321,7 +1280,6 @@ pub struct BatchCommitWriteStreamsRequest { pub write_streams: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Response message for `BatchCommitWriteStreams`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchCommitWriteStreamsResponse { /// The time at which streams were committed in microseconds granularity. @@ -1338,7 +1296,6 @@ pub struct BatchCommitWriteStreamsResponse { pub stream_errors: ::prost::alloc::vec::Vec, } /// Request message for invoking `FinalizeWriteStream`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct FinalizeWriteStreamRequest { /// Required. Name of the stream to finalize, in the form of @@ -1347,7 +1304,6 @@ pub struct FinalizeWriteStreamRequest { pub name: ::prost::alloc::string::String, } /// Response message for `FinalizeWriteStream`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct FinalizeWriteStreamResponse { /// Number of rows in the finalized stream. @@ -1355,7 +1311,6 @@ pub struct FinalizeWriteStreamResponse { pub row_count: i64, } /// Request message for `FlushRows`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct FlushRowsRequest { /// Required. The stream that is the target of the flush operation. @@ -1367,7 +1322,6 @@ pub struct FlushRowsRequest { pub offset: ::core::option::Option, } /// Respond message for `FlushRows`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct FlushRowsResponse { /// The rows before this offset (including this offset) are flushed. @@ -1378,7 +1332,6 @@ pub struct FlushRowsResponse { /// as error details in the returned rpc Status. In particular, the use of error /// codes allows more structured error handling, and reduces the need to evaluate /// unstructured error text strings. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct StorageError { /// BigQuery Storage specific error code. @@ -1451,23 +1404,21 @@ pub mod storage_error { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - StorageErrorCode::Unspecified => "STORAGE_ERROR_CODE_UNSPECIFIED", - StorageErrorCode::TableNotFound => "TABLE_NOT_FOUND", - StorageErrorCode::StreamAlreadyCommitted => "STREAM_ALREADY_COMMITTED", - StorageErrorCode::StreamNotFound => "STREAM_NOT_FOUND", - StorageErrorCode::InvalidStreamType => "INVALID_STREAM_TYPE", - StorageErrorCode::InvalidStreamState => "INVALID_STREAM_STATE", - StorageErrorCode::StreamFinalized => "STREAM_FINALIZED", - StorageErrorCode::SchemaMismatchExtraFields => { - "SCHEMA_MISMATCH_EXTRA_FIELDS" - } - StorageErrorCode::OffsetAlreadyExists => "OFFSET_ALREADY_EXISTS", - StorageErrorCode::OffsetOutOfRange => "OFFSET_OUT_OF_RANGE", - StorageErrorCode::CmekNotProvided => "CMEK_NOT_PROVIDED", - StorageErrorCode::InvalidCmekProvided => "INVALID_CMEK_PROVIDED", - StorageErrorCode::CmekEncryptionError => "CMEK_ENCRYPTION_ERROR", - StorageErrorCode::KmsServiceError => "KMS_SERVICE_ERROR", - StorageErrorCode::KmsPermissionDenied => "KMS_PERMISSION_DENIED", + Self::Unspecified => "STORAGE_ERROR_CODE_UNSPECIFIED", + Self::TableNotFound => "TABLE_NOT_FOUND", + Self::StreamAlreadyCommitted => "STREAM_ALREADY_COMMITTED", + Self::StreamNotFound => "STREAM_NOT_FOUND", + Self::InvalidStreamType => "INVALID_STREAM_TYPE", + Self::InvalidStreamState => "INVALID_STREAM_STATE", + Self::StreamFinalized => "STREAM_FINALIZED", + Self::SchemaMismatchExtraFields => "SCHEMA_MISMATCH_EXTRA_FIELDS", + Self::OffsetAlreadyExists => "OFFSET_ALREADY_EXISTS", + Self::OffsetOutOfRange => "OFFSET_OUT_OF_RANGE", + Self::CmekNotProvided => "CMEK_NOT_PROVIDED", + Self::InvalidCmekProvided => "INVALID_CMEK_PROVIDED", + Self::CmekEncryptionError => "CMEK_ENCRYPTION_ERROR", + Self::KmsServiceError => "KMS_SERVICE_ERROR", + Self::KmsPermissionDenied => "KMS_PERMISSION_DENIED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1494,7 +1445,6 @@ pub mod storage_error { } } /// The message that presents row level error info in a request. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RowError { /// Index of the malformed row in the request. @@ -1535,8 +1485,8 @@ pub mod row_error { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - RowErrorCode::Unspecified => "ROW_ERROR_CODE_UNSPECIFIED", - RowErrorCode::FieldsError => "FIELDS_ERROR", + Self::Unspecified => "ROW_ERROR_CODE_UNSPECIFIED", + Self::FieldsError => "FIELDS_ERROR", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1551,7 +1501,13 @@ pub mod row_error { } /// Generated client implementations. pub mod big_query_read_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value, + )] use tonic::codegen::*; use tonic::codegen::http::Uri; /// BigQuery Read API. @@ -1576,8 +1532,8 @@ pub mod big_query_read_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -1602,7 +1558,7 @@ pub mod big_query_read_client { >, , - >>::Error: Into + Send + Sync, + >>::Error: Into + std::marker::Send + std::marker::Sync, { BigQueryReadClient::new(InterceptedService::new(inner, interceptor)) } @@ -1664,8 +1620,7 @@ pub mod big_query_read_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1701,8 +1656,7 @@ pub mod big_query_read_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1743,8 +1697,7 @@ pub mod big_query_read_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1766,7 +1719,13 @@ pub mod big_query_read_client { } /// Generated client implementations. pub mod big_query_write_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value, + )] use tonic::codegen::*; use tonic::codegen::http::Uri; /// BigQuery Write API. @@ -1794,8 +1753,8 @@ pub mod big_query_write_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -1820,7 +1779,7 @@ pub mod big_query_write_client { >, , - >>::Error: Into + Send + Sync, + >>::Error: Into + std::marker::Send + std::marker::Sync, { BigQueryWriteClient::new(InterceptedService::new(inner, interceptor)) } @@ -1869,8 +1828,7 @@ pub mod big_query_write_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1930,8 +1888,7 @@ pub mod big_query_write_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1958,8 +1915,7 @@ pub mod big_query_write_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1990,8 +1946,7 @@ pub mod big_query_write_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2026,8 +1981,7 @@ pub mod big_query_write_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2064,8 +2018,7 @@ pub mod big_query_write_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; diff --git a/googleapis/src/bytes/google.cloud.kms.v1.rs b/googleapis/src/bytes/google.cloud.kms.v1.rs index fa63efd9..f1b88ac4 100644 --- a/googleapis/src/bytes/google.cloud.kms.v1.rs +++ b/googleapis/src/bytes/google.cloud.kms.v1.rs @@ -1,7 +1,6 @@ // This file is @generated by prost-build. /// A [KeyRing][google.cloud.kms.v1.KeyRing] is a toplevel logical grouping of /// [CryptoKeys][google.cloud.kms.v1.CryptoKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct KeyRing { /// Output only. The resource name for the @@ -20,7 +19,6 @@ pub struct KeyRing { /// A [CryptoKey][google.cloud.kms.v1.CryptoKey] is made up of zero or more /// [versions][google.cloud.kms.v1.CryptoKeyVersion], which represent the actual /// key material used in cryptographic operations. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CryptoKey { /// Output only. The resource name for this @@ -177,12 +175,12 @@ pub mod crypto_key { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - CryptoKeyPurpose::Unspecified => "CRYPTO_KEY_PURPOSE_UNSPECIFIED", - CryptoKeyPurpose::EncryptDecrypt => "ENCRYPT_DECRYPT", - CryptoKeyPurpose::AsymmetricSign => "ASYMMETRIC_SIGN", - CryptoKeyPurpose::AsymmetricDecrypt => "ASYMMETRIC_DECRYPT", - CryptoKeyPurpose::RawEncryptDecrypt => "RAW_ENCRYPT_DECRYPT", - CryptoKeyPurpose::Mac => "MAC", + Self::Unspecified => "CRYPTO_KEY_PURPOSE_UNSPECIFIED", + Self::EncryptDecrypt => "ENCRYPT_DECRYPT", + Self::AsymmetricSign => "ASYMMETRIC_SIGN", + Self::AsymmetricDecrypt => "ASYMMETRIC_DECRYPT", + Self::RawEncryptDecrypt => "RAW_ENCRYPT_DECRYPT", + Self::Mac => "MAC", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -199,7 +197,6 @@ pub mod crypto_key { } } /// Controls the rate of automatic rotation. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum RotationSchedule { /// [next_rotation_time][google.cloud.kms.v1.CryptoKey.next_rotation_time] @@ -224,7 +221,6 @@ pub mod crypto_key { /// with /// [CreateCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.CreateCryptoKeyVersion] /// or automatically as a result of auto-rotation. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct CryptoKeyVersionTemplate { /// [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] to use when creating @@ -249,7 +245,6 @@ pub struct CryptoKeyVersionTemplate { /// Contains an HSM-generated attestation about a key operation. For more /// information, see \[Verifying attestations\] /// (). -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct KeyOperationAttestation { /// Output only. The format of the attestation data. @@ -270,7 +265,6 @@ pub mod key_operation_attestation { /// Certificate chains needed to verify the attestation. /// Certificates in chains are PEM-encoded and are ordered based on /// - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CertificateChains { /// Cavium certificate chain corresponding to the attestation. @@ -318,9 +312,9 @@ pub mod key_operation_attestation { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - AttestationFormat::Unspecified => "ATTESTATION_FORMAT_UNSPECIFIED", - AttestationFormat::CaviumV1Compressed => "CAVIUM_V1_COMPRESSED", - AttestationFormat::CaviumV2Compressed => "CAVIUM_V2_COMPRESSED", + Self::Unspecified => "ATTESTATION_FORMAT_UNSPECIFIED", + Self::CaviumV1Compressed => "CAVIUM_V1_COMPRESSED", + Self::CaviumV2Compressed => "CAVIUM_V2_COMPRESSED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -345,7 +339,6 @@ pub mod key_operation_attestation { /// [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] can never be viewed /// or exported. It can only be used to encrypt, decrypt, or sign data when an /// authorized user or application invokes Cloud KMS. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CryptoKeyVersion { /// Output only. The resource name for this @@ -587,86 +580,42 @@ pub mod crypto_key_version { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - CryptoKeyVersionAlgorithm::Unspecified => { - "CRYPTO_KEY_VERSION_ALGORITHM_UNSPECIFIED" - } - CryptoKeyVersionAlgorithm::GoogleSymmetricEncryption => { - "GOOGLE_SYMMETRIC_ENCRYPTION" - } - CryptoKeyVersionAlgorithm::Aes128Gcm => "AES_128_GCM", - CryptoKeyVersionAlgorithm::Aes256Gcm => "AES_256_GCM", - CryptoKeyVersionAlgorithm::Aes128Cbc => "AES_128_CBC", - CryptoKeyVersionAlgorithm::Aes256Cbc => "AES_256_CBC", - CryptoKeyVersionAlgorithm::Aes128Ctr => "AES_128_CTR", - CryptoKeyVersionAlgorithm::Aes256Ctr => "AES_256_CTR", - CryptoKeyVersionAlgorithm::RsaSignPss2048Sha256 => { - "RSA_SIGN_PSS_2048_SHA256" - } - CryptoKeyVersionAlgorithm::RsaSignPss3072Sha256 => { - "RSA_SIGN_PSS_3072_SHA256" - } - CryptoKeyVersionAlgorithm::RsaSignPss4096Sha256 => { - "RSA_SIGN_PSS_4096_SHA256" - } - CryptoKeyVersionAlgorithm::RsaSignPss4096Sha512 => { - "RSA_SIGN_PSS_4096_SHA512" - } - CryptoKeyVersionAlgorithm::RsaSignPkcs12048Sha256 => { - "RSA_SIGN_PKCS1_2048_SHA256" - } - CryptoKeyVersionAlgorithm::RsaSignPkcs13072Sha256 => { - "RSA_SIGN_PKCS1_3072_SHA256" - } - CryptoKeyVersionAlgorithm::RsaSignPkcs14096Sha256 => { - "RSA_SIGN_PKCS1_4096_SHA256" - } - CryptoKeyVersionAlgorithm::RsaSignPkcs14096Sha512 => { - "RSA_SIGN_PKCS1_4096_SHA512" - } - CryptoKeyVersionAlgorithm::RsaSignRawPkcs12048 => { - "RSA_SIGN_RAW_PKCS1_2048" - } - CryptoKeyVersionAlgorithm::RsaSignRawPkcs13072 => { - "RSA_SIGN_RAW_PKCS1_3072" - } - CryptoKeyVersionAlgorithm::RsaSignRawPkcs14096 => { - "RSA_SIGN_RAW_PKCS1_4096" - } - CryptoKeyVersionAlgorithm::RsaDecryptOaep2048Sha256 => { - "RSA_DECRYPT_OAEP_2048_SHA256" - } - CryptoKeyVersionAlgorithm::RsaDecryptOaep3072Sha256 => { - "RSA_DECRYPT_OAEP_3072_SHA256" - } - CryptoKeyVersionAlgorithm::RsaDecryptOaep4096Sha256 => { - "RSA_DECRYPT_OAEP_4096_SHA256" - } - CryptoKeyVersionAlgorithm::RsaDecryptOaep4096Sha512 => { - "RSA_DECRYPT_OAEP_4096_SHA512" - } - CryptoKeyVersionAlgorithm::RsaDecryptOaep2048Sha1 => { - "RSA_DECRYPT_OAEP_2048_SHA1" - } - CryptoKeyVersionAlgorithm::RsaDecryptOaep3072Sha1 => { - "RSA_DECRYPT_OAEP_3072_SHA1" - } - CryptoKeyVersionAlgorithm::RsaDecryptOaep4096Sha1 => { - "RSA_DECRYPT_OAEP_4096_SHA1" - } - CryptoKeyVersionAlgorithm::EcSignP256Sha256 => "EC_SIGN_P256_SHA256", - CryptoKeyVersionAlgorithm::EcSignP384Sha384 => "EC_SIGN_P384_SHA384", - CryptoKeyVersionAlgorithm::EcSignSecp256k1Sha256 => { - "EC_SIGN_SECP256K1_SHA256" - } - CryptoKeyVersionAlgorithm::EcSignEd25519 => "EC_SIGN_ED25519", - CryptoKeyVersionAlgorithm::HmacSha256 => "HMAC_SHA256", - CryptoKeyVersionAlgorithm::HmacSha1 => "HMAC_SHA1", - CryptoKeyVersionAlgorithm::HmacSha384 => "HMAC_SHA384", - CryptoKeyVersionAlgorithm::HmacSha512 => "HMAC_SHA512", - CryptoKeyVersionAlgorithm::HmacSha224 => "HMAC_SHA224", - CryptoKeyVersionAlgorithm::ExternalSymmetricEncryption => { - "EXTERNAL_SYMMETRIC_ENCRYPTION" - } + Self::Unspecified => "CRYPTO_KEY_VERSION_ALGORITHM_UNSPECIFIED", + Self::GoogleSymmetricEncryption => "GOOGLE_SYMMETRIC_ENCRYPTION", + Self::Aes128Gcm => "AES_128_GCM", + Self::Aes256Gcm => "AES_256_GCM", + Self::Aes128Cbc => "AES_128_CBC", + Self::Aes256Cbc => "AES_256_CBC", + Self::Aes128Ctr => "AES_128_CTR", + Self::Aes256Ctr => "AES_256_CTR", + Self::RsaSignPss2048Sha256 => "RSA_SIGN_PSS_2048_SHA256", + Self::RsaSignPss3072Sha256 => "RSA_SIGN_PSS_3072_SHA256", + Self::RsaSignPss4096Sha256 => "RSA_SIGN_PSS_4096_SHA256", + Self::RsaSignPss4096Sha512 => "RSA_SIGN_PSS_4096_SHA512", + Self::RsaSignPkcs12048Sha256 => "RSA_SIGN_PKCS1_2048_SHA256", + Self::RsaSignPkcs13072Sha256 => "RSA_SIGN_PKCS1_3072_SHA256", + Self::RsaSignPkcs14096Sha256 => "RSA_SIGN_PKCS1_4096_SHA256", + Self::RsaSignPkcs14096Sha512 => "RSA_SIGN_PKCS1_4096_SHA512", + Self::RsaSignRawPkcs12048 => "RSA_SIGN_RAW_PKCS1_2048", + Self::RsaSignRawPkcs13072 => "RSA_SIGN_RAW_PKCS1_3072", + Self::RsaSignRawPkcs14096 => "RSA_SIGN_RAW_PKCS1_4096", + Self::RsaDecryptOaep2048Sha256 => "RSA_DECRYPT_OAEP_2048_SHA256", + Self::RsaDecryptOaep3072Sha256 => "RSA_DECRYPT_OAEP_3072_SHA256", + Self::RsaDecryptOaep4096Sha256 => "RSA_DECRYPT_OAEP_4096_SHA256", + Self::RsaDecryptOaep4096Sha512 => "RSA_DECRYPT_OAEP_4096_SHA512", + Self::RsaDecryptOaep2048Sha1 => "RSA_DECRYPT_OAEP_2048_SHA1", + Self::RsaDecryptOaep3072Sha1 => "RSA_DECRYPT_OAEP_3072_SHA1", + Self::RsaDecryptOaep4096Sha1 => "RSA_DECRYPT_OAEP_4096_SHA1", + Self::EcSignP256Sha256 => "EC_SIGN_P256_SHA256", + Self::EcSignP384Sha384 => "EC_SIGN_P384_SHA384", + Self::EcSignSecp256k1Sha256 => "EC_SIGN_SECP256K1_SHA256", + Self::EcSignEd25519 => "EC_SIGN_ED25519", + Self::HmacSha256 => "HMAC_SHA256", + Self::HmacSha1 => "HMAC_SHA1", + Self::HmacSha384 => "HMAC_SHA384", + Self::HmacSha512 => "HMAC_SHA512", + Self::HmacSha224 => "HMAC_SHA224", + Self::ExternalSymmetricEncryption => "EXTERNAL_SYMMETRIC_ENCRYPTION", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -792,23 +741,17 @@ pub mod crypto_key_version { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - CryptoKeyVersionState::Unspecified => { - "CRYPTO_KEY_VERSION_STATE_UNSPECIFIED" - } - CryptoKeyVersionState::PendingGeneration => "PENDING_GENERATION", - CryptoKeyVersionState::Enabled => "ENABLED", - CryptoKeyVersionState::Disabled => "DISABLED", - CryptoKeyVersionState::Destroyed => "DESTROYED", - CryptoKeyVersionState::DestroyScheduled => "DESTROY_SCHEDULED", - CryptoKeyVersionState::PendingImport => "PENDING_IMPORT", - CryptoKeyVersionState::ImportFailed => "IMPORT_FAILED", - CryptoKeyVersionState::GenerationFailed => "GENERATION_FAILED", - CryptoKeyVersionState::PendingExternalDestruction => { - "PENDING_EXTERNAL_DESTRUCTION" - } - CryptoKeyVersionState::ExternalDestructionFailed => { - "EXTERNAL_DESTRUCTION_FAILED" - } + Self::Unspecified => "CRYPTO_KEY_VERSION_STATE_UNSPECIFIED", + Self::PendingGeneration => "PENDING_GENERATION", + Self::Enabled => "ENABLED", + Self::Disabled => "DISABLED", + Self::Destroyed => "DESTROYED", + Self::DestroyScheduled => "DESTROY_SCHEDULED", + Self::PendingImport => "PENDING_IMPORT", + Self::ImportFailed => "IMPORT_FAILED", + Self::GenerationFailed => "GENERATION_FAILED", + Self::PendingExternalDestruction => "PENDING_EXTERNAL_DESTRUCTION", + Self::ExternalDestructionFailed => "EXTERNAL_DESTRUCTION_FAILED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -865,10 +808,8 @@ pub mod crypto_key_version { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - CryptoKeyVersionView::Unspecified => { - "CRYPTO_KEY_VERSION_VIEW_UNSPECIFIED" - } - CryptoKeyVersionView::Full => "FULL", + Self::Unspecified => "CRYPTO_KEY_VERSION_VIEW_UNSPECIFIED", + Self::Full => "FULL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -884,7 +825,6 @@ pub mod crypto_key_version { /// The public keys for a given /// [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion]. Obtained via /// [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PublicKey { /// The public key, encoded in PEM format. For more information, see the @@ -960,7 +900,6 @@ pub struct PublicKey { /// /// For more information, see /// [Importing a key](). -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportJob { /// Output only. The resource name for this @@ -1021,7 +960,6 @@ pub mod import_job { /// The public key component of the wrapping key. For details of the type of /// key this public key corresponds to, see the /// [ImportMethod][google.cloud.kms.v1.ImportJob.ImportMethod]. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct WrappingPublicKey { /// The public key, encoded in PEM format. For more information, see the [RFC @@ -1096,13 +1034,13 @@ pub mod import_job { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ImportMethod::Unspecified => "IMPORT_METHOD_UNSPECIFIED", - ImportMethod::RsaOaep3072Sha1Aes256 => "RSA_OAEP_3072_SHA1_AES_256", - ImportMethod::RsaOaep4096Sha1Aes256 => "RSA_OAEP_4096_SHA1_AES_256", - ImportMethod::RsaOaep3072Sha256Aes256 => "RSA_OAEP_3072_SHA256_AES_256", - ImportMethod::RsaOaep4096Sha256Aes256 => "RSA_OAEP_4096_SHA256_AES_256", - ImportMethod::RsaOaep3072Sha256 => "RSA_OAEP_3072_SHA256", - ImportMethod::RsaOaep4096Sha256 => "RSA_OAEP_4096_SHA256", + Self::Unspecified => "IMPORT_METHOD_UNSPECIFIED", + Self::RsaOaep3072Sha1Aes256 => "RSA_OAEP_3072_SHA1_AES_256", + Self::RsaOaep4096Sha1Aes256 => "RSA_OAEP_4096_SHA1_AES_256", + Self::RsaOaep3072Sha256Aes256 => "RSA_OAEP_3072_SHA256_AES_256", + Self::RsaOaep4096Sha256Aes256 => "RSA_OAEP_4096_SHA256_AES_256", + Self::RsaOaep3072Sha256 => "RSA_OAEP_3072_SHA256", + Self::RsaOaep4096Sha256 => "RSA_OAEP_4096_SHA256", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1157,10 +1095,10 @@ pub mod import_job { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ImportJobState::Unspecified => "IMPORT_JOB_STATE_UNSPECIFIED", - ImportJobState::PendingGeneration => "PENDING_GENERATION", - ImportJobState::Active => "ACTIVE", - ImportJobState::Expired => "EXPIRED", + Self::Unspecified => "IMPORT_JOB_STATE_UNSPECIFIED", + Self::PendingGeneration => "PENDING_GENERATION", + Self::Active => "ACTIVE", + Self::Expired => "EXPIRED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1181,7 +1119,6 @@ pub mod import_job { /// protection level and /// [EXTERNAL_VPC][google.cloud.kms.v1.ProtectionLevel.EXTERNAL_VPC] protection /// levels. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ExternalProtectionLevelOptions { /// The URI for an external resource that this @@ -1200,7 +1137,6 @@ pub struct ExternalProtectionLevelOptions { /// specifies zero or more allowed /// [AccessReason][google.cloud.kms.v1.AccessReason] values for encrypt, decrypt, /// and sign operations on a [CryptoKey][google.cloud.kms.v1.CryptoKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct KeyAccessJustificationsPolicy { /// The list of allowed reasons for access to a @@ -1235,11 +1171,11 @@ impl ProtectionLevel { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ProtectionLevel::Unspecified => "PROTECTION_LEVEL_UNSPECIFIED", - ProtectionLevel::Software => "SOFTWARE", - ProtectionLevel::Hsm => "HSM", - ProtectionLevel::External => "EXTERNAL", - ProtectionLevel::ExternalVpc => "EXTERNAL_VPC", + Self::Unspecified => "PROTECTION_LEVEL_UNSPECIFIED", + Self::Software => "SOFTWARE", + Self::Hsm => "HSM", + Self::External => "EXTERNAL", + Self::ExternalVpc => "EXTERNAL_VPC", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1318,26 +1254,22 @@ impl AccessReason { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - AccessReason::ReasonUnspecified => "REASON_UNSPECIFIED", - AccessReason::CustomerInitiatedSupport => "CUSTOMER_INITIATED_SUPPORT", - AccessReason::GoogleInitiatedService => "GOOGLE_INITIATED_SERVICE", - AccessReason::ThirdPartyDataRequest => "THIRD_PARTY_DATA_REQUEST", - AccessReason::GoogleInitiatedReview => "GOOGLE_INITIATED_REVIEW", - AccessReason::CustomerInitiatedAccess => "CUSTOMER_INITIATED_ACCESS", - AccessReason::GoogleInitiatedSystemOperation => { - "GOOGLE_INITIATED_SYSTEM_OPERATION" - } - AccessReason::ReasonNotExpected => "REASON_NOT_EXPECTED", - AccessReason::ModifiedCustomerInitiatedAccess => { - "MODIFIED_CUSTOMER_INITIATED_ACCESS" - } - AccessReason::ModifiedGoogleInitiatedSystemOperation => { + Self::ReasonUnspecified => "REASON_UNSPECIFIED", + Self::CustomerInitiatedSupport => "CUSTOMER_INITIATED_SUPPORT", + Self::GoogleInitiatedService => "GOOGLE_INITIATED_SERVICE", + Self::ThirdPartyDataRequest => "THIRD_PARTY_DATA_REQUEST", + Self::GoogleInitiatedReview => "GOOGLE_INITIATED_REVIEW", + Self::CustomerInitiatedAccess => "CUSTOMER_INITIATED_ACCESS", + Self::GoogleInitiatedSystemOperation => "GOOGLE_INITIATED_SYSTEM_OPERATION", + Self::ReasonNotExpected => "REASON_NOT_EXPECTED", + Self::ModifiedCustomerInitiatedAccess => "MODIFIED_CUSTOMER_INITIATED_ACCESS", + Self::ModifiedGoogleInitiatedSystemOperation => { "MODIFIED_GOOGLE_INITIATED_SYSTEM_OPERATION" } - AccessReason::GoogleResponseToProductionAlert => { + Self::GoogleResponseToProductionAlert => { "GOOGLE_RESPONSE_TO_PRODUCTION_ALERT" } - AccessReason::CustomerAuthorizedWorkflowServicing => { + Self::CustomerAuthorizedWorkflowServicing => { "CUSTOMER_AUTHORIZED_WORKFLOW_SERVICING" } } @@ -1373,7 +1305,6 @@ impl AccessReason { } /// Request message for /// [KeyManagementService.ListKeyRings][google.cloud.kms.v1.KeyManagementService.ListKeyRings]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListKeyRingsRequest { /// Required. The resource name of the location associated with the @@ -1409,7 +1340,6 @@ pub struct ListKeyRingsRequest { } /// Request message for /// [KeyManagementService.ListCryptoKeys][google.cloud.kms.v1.KeyManagementService.ListCryptoKeys]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListCryptoKeysRequest { /// Required. The resource name of the [KeyRing][google.cloud.kms.v1.KeyRing] @@ -1447,7 +1377,6 @@ pub struct ListCryptoKeysRequest { } /// Request message for /// [KeyManagementService.ListCryptoKeyVersions][google.cloud.kms.v1.KeyManagementService.ListCryptoKeyVersions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListCryptoKeyVersionsRequest { /// Required. The resource name of the @@ -1486,7 +1415,6 @@ pub struct ListCryptoKeyVersionsRequest { } /// Request message for /// [KeyManagementService.ListImportJobs][google.cloud.kms.v1.KeyManagementService.ListImportJobs]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListImportJobsRequest { /// Required. The resource name of the [KeyRing][google.cloud.kms.v1.KeyRing] @@ -1521,7 +1449,6 @@ pub struct ListImportJobsRequest { } /// Response message for /// [KeyManagementService.ListKeyRings][google.cloud.kms.v1.KeyManagementService.ListKeyRings]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListKeyRingsResponse { /// The list of [KeyRings][google.cloud.kms.v1.KeyRing]. @@ -1539,7 +1466,6 @@ pub struct ListKeyRingsResponse { } /// Response message for /// [KeyManagementService.ListCryptoKeys][google.cloud.kms.v1.KeyManagementService.ListCryptoKeys]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListCryptoKeysResponse { /// The list of [CryptoKeys][google.cloud.kms.v1.CryptoKey]. @@ -1557,7 +1483,6 @@ pub struct ListCryptoKeysResponse { } /// Response message for /// [KeyManagementService.ListCryptoKeyVersions][google.cloud.kms.v1.KeyManagementService.ListCryptoKeyVersions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListCryptoKeyVersionsResponse { /// The list of [CryptoKeyVersions][google.cloud.kms.v1.CryptoKeyVersion]. @@ -1576,7 +1501,6 @@ pub struct ListCryptoKeyVersionsResponse { } /// Response message for /// [KeyManagementService.ListImportJobs][google.cloud.kms.v1.KeyManagementService.ListImportJobs]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListImportJobsResponse { /// The list of [ImportJobs][google.cloud.kms.v1.ImportJob]. @@ -1594,7 +1518,6 @@ pub struct ListImportJobsResponse { } /// Request message for /// [KeyManagementService.GetKeyRing][google.cloud.kms.v1.KeyManagementService.GetKeyRing]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetKeyRingRequest { /// Required. The [name][google.cloud.kms.v1.KeyRing.name] of the @@ -1604,7 +1527,6 @@ pub struct GetKeyRingRequest { } /// Request message for /// [KeyManagementService.GetCryptoKey][google.cloud.kms.v1.KeyManagementService.GetCryptoKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetCryptoKeyRequest { /// Required. The [name][google.cloud.kms.v1.CryptoKey.name] of the @@ -1614,7 +1536,6 @@ pub struct GetCryptoKeyRequest { } /// Request message for /// [KeyManagementService.GetCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.GetCryptoKeyVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetCryptoKeyVersionRequest { /// Required. The [name][google.cloud.kms.v1.CryptoKeyVersion.name] of the @@ -1624,7 +1545,6 @@ pub struct GetCryptoKeyVersionRequest { } /// Request message for /// [KeyManagementService.GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetPublicKeyRequest { /// Required. The [name][google.cloud.kms.v1.CryptoKeyVersion.name] of the @@ -1634,7 +1554,6 @@ pub struct GetPublicKeyRequest { } /// Request message for /// [KeyManagementService.GetImportJob][google.cloud.kms.v1.KeyManagementService.GetImportJob]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetImportJobRequest { /// Required. The [name][google.cloud.kms.v1.ImportJob.name] of the @@ -1644,7 +1563,6 @@ pub struct GetImportJobRequest { } /// Request message for /// [KeyManagementService.CreateKeyRing][google.cloud.kms.v1.KeyManagementService.CreateKeyRing]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateKeyRingRequest { /// Required. The resource name of the location associated with the @@ -1663,7 +1581,6 @@ pub struct CreateKeyRingRequest { } /// Request message for /// [KeyManagementService.CreateCryptoKey][google.cloud.kms.v1.KeyManagementService.CreateCryptoKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateCryptoKeyRequest { /// Required. The [name][google.cloud.kms.v1.KeyRing.name] of the KeyRing @@ -1691,7 +1608,6 @@ pub struct CreateCryptoKeyRequest { } /// Request message for /// [KeyManagementService.CreateCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.CreateCryptoKeyVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateCryptoKeyVersionRequest { /// Required. The [name][google.cloud.kms.v1.CryptoKey.name] of the @@ -1706,7 +1622,6 @@ pub struct CreateCryptoKeyVersionRequest { } /// Request message for /// [KeyManagementService.ImportCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.ImportCryptoKeyVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportCryptoKeyVersionRequest { /// Required. The [name][google.cloud.kms.v1.CryptoKey.name] of the @@ -1804,7 +1719,6 @@ pub mod import_crypto_key_version_request { /// This field is legacy. Use the field /// [wrapped_key][google.cloud.kms.v1.ImportCryptoKeyVersionRequest.wrapped_key] /// instead. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum WrappedKeyMaterial { /// Optional. This field has the same meaning as @@ -1817,7 +1731,6 @@ pub mod import_crypto_key_version_request { } /// Request message for /// [KeyManagementService.CreateImportJob][google.cloud.kms.v1.KeyManagementService.CreateImportJob]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateImportJobRequest { /// Required. The [name][google.cloud.kms.v1.KeyRing.name] of the @@ -1836,7 +1749,6 @@ pub struct CreateImportJobRequest { } /// Request message for /// [KeyManagementService.UpdateCryptoKey][google.cloud.kms.v1.KeyManagementService.UpdateCryptoKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateCryptoKeyRequest { /// Required. [CryptoKey][google.cloud.kms.v1.CryptoKey] with updated values. @@ -1848,7 +1760,6 @@ pub struct UpdateCryptoKeyRequest { } /// Request message for /// [KeyManagementService.UpdateCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.UpdateCryptoKeyVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateCryptoKeyVersionRequest { /// Required. [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] with @@ -1861,7 +1772,6 @@ pub struct UpdateCryptoKeyVersionRequest { } /// Request message for /// [KeyManagementService.UpdateCryptoKeyPrimaryVersion][google.cloud.kms.v1.KeyManagementService.UpdateCryptoKeyPrimaryVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateCryptoKeyPrimaryVersionRequest { /// Required. The resource name of the @@ -1875,7 +1785,6 @@ pub struct UpdateCryptoKeyPrimaryVersionRequest { } /// Request message for /// [KeyManagementService.DestroyCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.DestroyCryptoKeyVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DestroyCryptoKeyVersionRequest { /// Required. The resource name of the @@ -1885,7 +1794,6 @@ pub struct DestroyCryptoKeyVersionRequest { } /// Request message for /// [KeyManagementService.RestoreCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.RestoreCryptoKeyVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RestoreCryptoKeyVersionRequest { /// Required. The resource name of the @@ -1895,7 +1803,6 @@ pub struct RestoreCryptoKeyVersionRequest { } /// Request message for /// [KeyManagementService.Encrypt][google.cloud.kms.v1.KeyManagementService.Encrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct EncryptRequest { /// Required. The resource name of the @@ -1980,7 +1887,6 @@ pub struct EncryptRequest { } /// Request message for /// [KeyManagementService.Decrypt][google.cloud.kms.v1.KeyManagementService.Decrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DecryptRequest { /// Required. The resource name of the @@ -2041,7 +1947,6 @@ pub struct DecryptRequest { } /// Request message for /// [KeyManagementService.RawEncrypt][google.cloud.kms.v1.KeyManagementService.RawEncrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RawEncryptRequest { /// Required. The resource name of the @@ -2139,7 +2044,6 @@ pub struct RawEncryptRequest { } /// Request message for /// [KeyManagementService.RawDecrypt][google.cloud.kms.v1.KeyManagementService.RawDecrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RawDecryptRequest { /// Required. The resource name of the @@ -2220,7 +2124,6 @@ pub struct RawDecryptRequest { } /// Request message for /// [KeyManagementService.AsymmetricSign][google.cloud.kms.v1.KeyManagementService.AsymmetricSign]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AsymmetricSignRequest { /// Required. The resource name of the @@ -2288,7 +2191,6 @@ pub struct AsymmetricSignRequest { } /// Request message for /// [KeyManagementService.AsymmetricDecrypt][google.cloud.kms.v1.KeyManagementService.AsymmetricDecrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AsymmetricDecryptRequest { /// Required. The resource name of the @@ -2325,7 +2227,6 @@ pub struct AsymmetricDecryptRequest { } /// Request message for /// [KeyManagementService.MacSign][google.cloud.kms.v1.KeyManagementService.MacSign]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MacSignRequest { /// Required. The resource name of the @@ -2359,7 +2260,6 @@ pub struct MacSignRequest { } /// Request message for /// [KeyManagementService.MacVerify][google.cloud.kms.v1.KeyManagementService.MacVerify]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MacVerifyRequest { /// Required. The resource name of the @@ -2416,7 +2316,6 @@ pub struct MacVerifyRequest { } /// Request message for /// [KeyManagementService.GenerateRandomBytes][google.cloud.kms.v1.KeyManagementService.GenerateRandomBytes]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GenerateRandomBytesRequest { /// The project-specific location in which to generate random bytes. @@ -2436,7 +2335,6 @@ pub struct GenerateRandomBytesRequest { } /// Response message for /// [KeyManagementService.Encrypt][google.cloud.kms.v1.KeyManagementService.Encrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct EncryptResponse { /// The resource name of the @@ -2503,7 +2401,6 @@ pub struct EncryptResponse { } /// Response message for /// [KeyManagementService.Decrypt][google.cloud.kms.v1.KeyManagementService.Decrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DecryptResponse { /// The decrypted data originally supplied in @@ -2540,7 +2437,6 @@ pub struct DecryptResponse { } /// Response message for /// [KeyManagementService.RawEncrypt][google.cloud.kms.v1.KeyManagementService.RawEncrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RawEncryptResponse { /// The encrypted data. In the case of AES-GCM, the authentication tag @@ -2641,7 +2537,6 @@ pub struct RawEncryptResponse { } /// Response message for /// [KeyManagementService.RawDecrypt][google.cloud.kms.v1.KeyManagementService.RawDecrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RawDecryptResponse { /// The decrypted data. @@ -2717,7 +2612,6 @@ pub struct RawDecryptResponse { } /// Response message for /// [KeyManagementService.AsymmetricSign][google.cloud.kms.v1.KeyManagementService.AsymmetricSign]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AsymmetricSignResponse { /// The created signature. @@ -2782,7 +2676,6 @@ pub struct AsymmetricSignResponse { } /// Response message for /// [KeyManagementService.AsymmetricDecrypt][google.cloud.kms.v1.KeyManagementService.AsymmetricDecrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AsymmetricDecryptResponse { /// The decrypted data originally encrypted with the matching public key. @@ -2827,7 +2720,6 @@ pub struct AsymmetricDecryptResponse { } /// Response message for /// [KeyManagementService.MacSign][google.cloud.kms.v1.KeyManagementService.MacSign]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MacSignResponse { /// The resource name of the @@ -2876,7 +2768,6 @@ pub struct MacSignResponse { } /// Response message for /// [KeyManagementService.MacVerify][google.cloud.kms.v1.KeyManagementService.MacVerify]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MacVerifyResponse { /// The resource name of the @@ -2937,7 +2828,6 @@ pub struct MacVerifyResponse { } /// Response message for /// [KeyManagementService.GenerateRandomBytes][google.cloud.kms.v1.KeyManagementService.GenerateRandomBytes]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GenerateRandomBytesResponse { /// The generated data. @@ -2960,7 +2850,6 @@ pub struct GenerateRandomBytesResponse { pub data_crc32c: ::core::option::Option, } /// A [Digest][google.cloud.kms.v1.Digest] holds a cryptographic message digest. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Digest { /// Required. The message digest. @@ -2970,7 +2859,6 @@ pub struct Digest { /// Nested message and enum types in `Digest`. pub mod digest { /// Required. The message digest. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Digest { /// A message digest produced with the SHA-256 algorithm. @@ -2986,7 +2874,6 @@ pub mod digest { } /// Cloud KMS metadata for the given /// [google.cloud.location.Location][google.cloud.location.Location]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct LocationMetadata { /// Indicates whether [CryptoKeys][google.cloud.kms.v1.CryptoKey] with @@ -3004,7 +2891,13 @@ pub struct LocationMetadata { } /// Generated client implementations. pub mod key_management_service_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value, + )] use tonic::codegen::*; use tonic::codegen::http::Uri; /// Google Cloud Key Management Service @@ -3038,8 +2931,8 @@ pub mod key_management_service_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -3064,7 +2957,7 @@ pub mod key_management_service_client { >, , - >>::Error: Into + Send + Sync, + >>::Error: Into + std::marker::Send + std::marker::Sync, { KeyManagementServiceClient::new(InterceptedService::new(inner, interceptor)) } @@ -3111,8 +3004,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3142,8 +3034,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3173,8 +3064,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3204,8 +3094,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3232,8 +3121,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3262,8 +3150,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3294,8 +3181,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3327,8 +3213,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3355,8 +3240,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3384,8 +3268,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3417,8 +3300,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3453,8 +3335,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3491,8 +3372,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3523,8 +3403,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3551,8 +3430,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3593,8 +3471,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3626,8 +3503,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3677,8 +3553,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3716,8 +3591,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3750,8 +3624,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3784,8 +3657,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3820,8 +3692,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3854,8 +3725,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3889,8 +3759,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3924,8 +3793,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3957,8 +3825,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3991,8 +3858,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -4023,8 +3889,7 @@ pub mod key_management_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -4046,7 +3911,6 @@ pub mod key_management_service_client { } /// Request message for /// [EkmService.ListEkmConnections][google.cloud.kms.v1.EkmService.ListEkmConnections]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListEkmConnectionsRequest { /// Required. The resource name of the location associated with the @@ -4082,7 +3946,6 @@ pub struct ListEkmConnectionsRequest { } /// Response message for /// [EkmService.ListEkmConnections][google.cloud.kms.v1.EkmService.ListEkmConnections]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListEkmConnectionsResponse { /// The list of [EkmConnections][google.cloud.kms.v1.EkmConnection]. @@ -4100,7 +3963,6 @@ pub struct ListEkmConnectionsResponse { } /// Request message for /// [EkmService.GetEkmConnection][google.cloud.kms.v1.EkmService.GetEkmConnection]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetEkmConnectionRequest { /// Required. The [name][google.cloud.kms.v1.EkmConnection.name] of the @@ -4110,7 +3972,6 @@ pub struct GetEkmConnectionRequest { } /// Request message for /// [EkmService.CreateEkmConnection][google.cloud.kms.v1.EkmService.CreateEkmConnection]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateEkmConnectionRequest { /// Required. The resource name of the location associated with the @@ -4129,7 +3990,6 @@ pub struct CreateEkmConnectionRequest { } /// Request message for /// [EkmService.UpdateEkmConnection][google.cloud.kms.v1.EkmService.UpdateEkmConnection]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateEkmConnectionRequest { /// Required. [EkmConnection][google.cloud.kms.v1.EkmConnection] with updated @@ -4142,7 +4002,6 @@ pub struct UpdateEkmConnectionRequest { } /// Request message for /// [EkmService.GetEkmConfig][google.cloud.kms.v1.EkmService.GetEkmConfig]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetEkmConfigRequest { /// Required. The [name][google.cloud.kms.v1.EkmConfig.name] of the @@ -4152,7 +4011,6 @@ pub struct GetEkmConfigRequest { } /// Request message for /// [EkmService.UpdateEkmConfig][google.cloud.kms.v1.EkmService.UpdateEkmConfig]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateEkmConfigRequest { /// Required. [EkmConfig][google.cloud.kms.v1.EkmConfig] with updated values. @@ -4164,7 +4022,6 @@ pub struct UpdateEkmConfigRequest { } /// A [Certificate][google.cloud.kms.v1.Certificate] represents an X.509 /// certificate used to authenticate HTTPS connections to EKM replicas. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Certificate { /// Required. The raw certificate bytes in DER format. @@ -4212,7 +4069,6 @@ pub struct Certificate { /// [EXTERNAL_VPC][CryptoKeyVersion.ProtectionLevel.EXTERNAL_VPC], as well as /// performing cryptographic operations using keys created within the /// [EkmConnection][google.cloud.kms.v1.EkmConnection]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct EkmConnection { /// Output only. The resource name for the @@ -4254,7 +4110,6 @@ pub mod ekm_connection { /// A [ServiceResolver][google.cloud.kms.v1.EkmConnection.ServiceResolver] /// represents an EKM replica that can be reached within an /// [EkmConnection][google.cloud.kms.v1.EkmConnection]. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ServiceResolver { /// Required. The resource name of the Service Directory service pointing to @@ -4333,9 +4188,9 @@ pub mod ekm_connection { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - KeyManagementMode::Unspecified => "KEY_MANAGEMENT_MODE_UNSPECIFIED", - KeyManagementMode::Manual => "MANUAL", - KeyManagementMode::CloudKms => "CLOUD_KMS", + Self::Unspecified => "KEY_MANAGEMENT_MODE_UNSPECIFIED", + Self::Manual => "MANUAL", + Self::CloudKms => "CLOUD_KMS", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -4356,7 +4211,6 @@ pub mod ekm_connection { /// [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] of /// [EXTERNAL_VPC][CryptoKeyVersion.ProtectionLevel.EXTERNAL_VPC] in a given /// project and location. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct EkmConfig { /// Output only. The resource name for the @@ -4372,7 +4226,6 @@ pub struct EkmConfig { } /// Request message for /// [EkmService.VerifyConnectivity][google.cloud.kms.v1.EkmService.VerifyConnectivity]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct VerifyConnectivityRequest { /// Required. The [name][google.cloud.kms.v1.EkmConnection.name] of the @@ -4382,12 +4235,17 @@ pub struct VerifyConnectivityRequest { } /// Response message for /// [EkmService.VerifyConnectivity][google.cloud.kms.v1.EkmService.VerifyConnectivity]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct VerifyConnectivityResponse {} /// Generated client implementations. pub mod ekm_service_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value, + )] use tonic::codegen::*; use tonic::codegen::http::Uri; /// Google Cloud Key Management EKM Service @@ -4414,8 +4272,8 @@ pub mod ekm_service_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -4440,7 +4298,7 @@ pub mod ekm_service_client { >, , - >>::Error: Into + Send + Sync, + >>::Error: Into + std::marker::Send + std::marker::Sync, { EkmServiceClient::new(InterceptedService::new(inner, interceptor)) } @@ -4487,8 +4345,7 @@ pub mod ekm_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -4516,8 +4373,7 @@ pub mod ekm_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -4542,8 +4398,7 @@ pub mod ekm_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -4570,8 +4425,7 @@ pub mod ekm_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -4599,8 +4453,7 @@ pub mod ekm_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -4625,8 +4478,7 @@ pub mod ekm_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -4657,8 +4509,7 @@ pub mod ekm_service_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; diff --git a/googleapis/src/bytes/google.devtools.artifactregistry.v1.rs b/googleapis/src/bytes/google.devtools.artifactregistry.v1.rs index 0d61a82c..cf29a51f 100644 --- a/googleapis/src/bytes/google.devtools.artifactregistry.v1.rs +++ b/googleapis/src/bytes/google.devtools.artifactregistry.v1.rs @@ -5,7 +5,6 @@ /// * imageSizeBytes /// * mediaType /// * buildTime -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DockerImage { /// Required. registry_location, project_id, repository_name and image id forms @@ -54,7 +53,6 @@ pub struct DockerImage { pub update_time: ::core::option::Option<::prost_types::Timestamp>, } /// The request to list docker images. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDockerImagesRequest { /// Required. The name of the parent resource whose docker images will be @@ -72,7 +70,6 @@ pub struct ListDockerImagesRequest { pub order_by: ::prost::alloc::string::String, } /// The response from listing docker images. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDockerImagesResponse { /// The docker images returned. @@ -84,7 +81,6 @@ pub struct ListDockerImagesResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to get docker images. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetDockerImageRequest { /// Required. The name of the docker images. @@ -92,7 +88,6 @@ pub struct GetDockerImageRequest { pub name: ::prost::alloc::string::String, } /// MavenArtifact represents a maven artifact. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MavenArtifact { /// Required. registry_location, project_id, repository_name and maven_artifact @@ -129,7 +124,6 @@ pub struct MavenArtifact { pub update_time: ::core::option::Option<::prost_types::Timestamp>, } /// The request to list maven artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListMavenArtifactsRequest { /// Required. The name of the parent resource whose maven artifacts will be @@ -144,7 +138,6 @@ pub struct ListMavenArtifactsRequest { pub page_token: ::prost::alloc::string::String, } /// The response from listing maven artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListMavenArtifactsResponse { /// The maven artifacts returned. @@ -156,7 +149,6 @@ pub struct ListMavenArtifactsResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to get maven artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetMavenArtifactRequest { /// Required. The name of the maven artifact. @@ -164,7 +156,6 @@ pub struct GetMavenArtifactRequest { pub name: ::prost::alloc::string::String, } /// NpmPackage represents an npm artifact. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct NpmPackage { /// Required. registry_location, project_id, repository_name and npm_package @@ -193,7 +184,6 @@ pub struct NpmPackage { pub update_time: ::core::option::Option<::prost_types::Timestamp>, } /// The request to list npm packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListNpmPackagesRequest { /// Required. The name of the parent resource whose npm packages will be @@ -208,7 +198,6 @@ pub struct ListNpmPackagesRequest { pub page_token: ::prost::alloc::string::String, } /// The response from listing npm packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListNpmPackagesResponse { /// The npm packages returned. @@ -220,7 +209,6 @@ pub struct ListNpmPackagesResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to get npm packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetNpmPackageRequest { /// Required. The name of the npm package. @@ -228,7 +216,6 @@ pub struct GetNpmPackageRequest { pub name: ::prost::alloc::string::String, } /// PythonPackage represents a python artifact. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PythonPackage { /// Required. registry_location, project_id, repository_name and python_package @@ -261,7 +248,6 @@ pub struct PythonPackage { pub update_time: ::core::option::Option<::prost_types::Timestamp>, } /// The request to list python packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListPythonPackagesRequest { /// Required. The name of the parent resource whose python packages will be @@ -276,7 +262,6 @@ pub struct ListPythonPackagesRequest { pub page_token: ::prost::alloc::string::String, } /// The response from listing python packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListPythonPackagesResponse { /// The python packages returned. @@ -288,7 +273,6 @@ pub struct ListPythonPackagesResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to get python packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetPythonPackageRequest { /// Required. The name of the python package. @@ -296,7 +280,6 @@ pub struct GetPythonPackageRequest { pub name: ::prost::alloc::string::String, } /// A detailed representation of a Yum artifact. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct YumArtifact { /// Output only. The Artifact Registry resource name of the artifact. @@ -342,9 +325,9 @@ pub mod yum_artifact { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - PackageType::Unspecified => "PACKAGE_TYPE_UNSPECIFIED", - PackageType::Binary => "BINARY", - PackageType::Source => "SOURCE", + Self::Unspecified => "PACKAGE_TYPE_UNSPECIFIED", + Self::Binary => "BINARY", + Self::Source => "SOURCE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -359,7 +342,6 @@ pub mod yum_artifact { } } /// Google Cloud Storage location where the artifacts currently reside. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportYumArtifactsGcsSource { /// Cloud Storage paths URI (e.g., gs://my_bucket//my_object). @@ -370,7 +352,6 @@ pub struct ImportYumArtifactsGcsSource { pub use_wildcards: bool, } /// The request to import new yum artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportYumArtifactsRequest { /// The name of the parent resource where the artifacts will be imported. @@ -383,7 +364,6 @@ pub struct ImportYumArtifactsRequest { /// Nested message and enum types in `ImportYumArtifactsRequest`. pub mod import_yum_artifacts_request { /// The source location of the package binaries. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Source { /// Google Cloud Storage location where input content is located. @@ -392,7 +372,6 @@ pub mod import_yum_artifacts_request { } } /// Error information explaining why a package was not imported. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportYumArtifactsErrorInfo { /// The detailed error status. @@ -405,7 +384,6 @@ pub struct ImportYumArtifactsErrorInfo { /// Nested message and enum types in `ImportYumArtifactsErrorInfo`. pub mod import_yum_artifacts_error_info { /// The source that was not imported. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Source { /// Google Cloud Storage location requested. @@ -414,7 +392,6 @@ pub mod import_yum_artifacts_error_info { } } /// The response message from importing YUM artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportYumArtifactsResponse { /// The yum artifacts imported. @@ -425,11 +402,9 @@ pub struct ImportYumArtifactsResponse { pub errors: ::prost::alloc::vec::Vec, } /// The operation metadata for importing artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ImportYumArtifactsMetadata {} /// The Artifact Registry VPC SC config that apply to a Project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct VpcscConfig { /// The name of the project's VPC SC Config. @@ -480,9 +455,9 @@ pub mod vpcsc_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - VpcscPolicy::Unspecified => "VPCSC_POLICY_UNSPECIFIED", - VpcscPolicy::Deny => "DENY", - VpcscPolicy::Allow => "ALLOW", + Self::Unspecified => "VPCSC_POLICY_UNSPECIFIED", + Self::Deny => "DENY", + Self::Allow => "ALLOW", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -497,7 +472,6 @@ pub mod vpcsc_config { } } /// Gets the VPC SC config for a project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetVpcscConfigRequest { /// Required. The name of the VPCSCConfig resource. @@ -505,7 +479,6 @@ pub struct GetVpcscConfigRequest { pub name: ::prost::alloc::string::String, } /// Sets the VPCSC config of the project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateVpcscConfigRequest { /// The project config. @@ -518,7 +491,6 @@ pub struct UpdateVpcscConfigRequest { /// A detailed representation of an Apt artifact. Information in the record /// is derived from the archive's control file. /// See -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AptArtifact { /// Output only. The Artifact Registry resource name of the artifact. @@ -570,9 +542,9 @@ pub mod apt_artifact { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - PackageType::Unspecified => "PACKAGE_TYPE_UNSPECIFIED", - PackageType::Binary => "BINARY", - PackageType::Source => "SOURCE", + Self::Unspecified => "PACKAGE_TYPE_UNSPECIFIED", + Self::Binary => "BINARY", + Self::Source => "SOURCE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -587,7 +559,6 @@ pub mod apt_artifact { } } /// Google Cloud Storage location where the artifacts currently reside. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportAptArtifactsGcsSource { /// Cloud Storage paths URI (e.g., gs://my_bucket//my_object). @@ -598,7 +569,6 @@ pub struct ImportAptArtifactsGcsSource { pub use_wildcards: bool, } /// The request to import new apt artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportAptArtifactsRequest { /// The name of the parent resource where the artifacts will be imported. @@ -611,7 +581,6 @@ pub struct ImportAptArtifactsRequest { /// Nested message and enum types in `ImportAptArtifactsRequest`. pub mod import_apt_artifacts_request { /// The source location of the package binaries. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Source { /// Google Cloud Storage location where input content is located. @@ -620,7 +589,6 @@ pub mod import_apt_artifacts_request { } } /// Error information explaining why a package was not imported. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportAptArtifactsErrorInfo { /// The detailed error status. @@ -633,7 +601,6 @@ pub struct ImportAptArtifactsErrorInfo { /// Nested message and enum types in `ImportAptArtifactsErrorInfo`. pub mod import_apt_artifacts_error_info { /// The source that was not imported. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Source { /// Google Cloud Storage location requested. @@ -642,7 +609,6 @@ pub mod import_apt_artifacts_error_info { } } /// The response message from importing APT artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportAptArtifactsResponse { /// The Apt artifacts imported. @@ -653,11 +619,9 @@ pub struct ImportAptArtifactsResponse { pub errors: ::prost::alloc::vec::Vec, } /// The operation metadata for importing artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ImportAptArtifactsMetadata {} /// A hash of file content. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Hash { /// The algorithm used to compute the hash value. @@ -697,9 +661,9 @@ pub mod hash { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - HashType::Unspecified => "HASH_TYPE_UNSPECIFIED", - HashType::Sha256 => "SHA256", - HashType::Md5 => "MD5", + Self::Unspecified => "HASH_TYPE_UNSPECIFIED", + Self::Sha256 => "SHA256", + Self::Md5 => "MD5", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -714,7 +678,6 @@ pub mod hash { } } /// Files store content that is potentially associated with Packages or Versions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct File { /// The name of the file, for example: @@ -743,7 +706,6 @@ pub struct File { pub fetch_time: ::core::option::Option<::prost_types::Timestamp>, } /// The request to list files. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListFilesRequest { /// Required. The name of the repository whose files will be listed. For @@ -775,7 +737,6 @@ pub struct ListFilesRequest { pub order_by: ::prost::alloc::string::String, } /// The response from listing files. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListFilesResponse { /// The files returned. @@ -787,7 +748,6 @@ pub struct ListFilesResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to retrieve a file. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetFileRequest { /// Required. The name of the file to retrieve. @@ -795,7 +755,6 @@ pub struct GetFileRequest { pub name: ::prost::alloc::string::String, } /// Packages are named collections of versions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Package { /// The name of the package, for example: @@ -815,7 +774,6 @@ pub struct Package { pub update_time: ::core::option::Option<::prost_types::Timestamp>, } /// The request to list packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListPackagesRequest { /// Required. The name of the parent resource whose packages will be listed. @@ -829,7 +787,6 @@ pub struct ListPackagesRequest { pub page_token: ::prost::alloc::string::String, } /// The response from listing packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListPackagesResponse { /// The packages returned. @@ -841,7 +798,6 @@ pub struct ListPackagesResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to retrieve a package. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetPackageRequest { /// Required. The name of the package to retrieve. @@ -849,7 +805,6 @@ pub struct GetPackageRequest { pub name: ::prost::alloc::string::String, } /// The request to delete a package. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeletePackageRequest { /// Required. The name of the package to delete. @@ -857,7 +812,6 @@ pub struct DeletePackageRequest { pub name: ::prost::alloc::string::String, } /// Artifact policy configuration for the repository contents. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpstreamPolicy { /// The user-provided ID of the upstream policy. @@ -874,7 +828,6 @@ pub struct UpstreamPolicy { /// CleanupPolicyCondition is a set of conditions attached to a CleanupPolicy. /// If multiple entries are set, all must be satisfied for the condition to be /// satisfied. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CleanupPolicyCondition { /// Match versions by tag status. @@ -928,10 +881,10 @@ pub mod cleanup_policy_condition { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - TagState::Unspecified => "TAG_STATE_UNSPECIFIED", - TagState::Tagged => "TAGGED", - TagState::Untagged => "UNTAGGED", - TagState::Any => "ANY", + Self::Unspecified => "TAG_STATE_UNSPECIFIED", + Self::Tagged => "TAGGED", + Self::Untagged => "UNTAGGED", + Self::Any => "ANY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -948,7 +901,6 @@ pub mod cleanup_policy_condition { } /// CleanupPolicyMostRecentVersions is an alternate condition of a CleanupPolicy /// for retaining a minimum number of versions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CleanupPolicyMostRecentVersions { /// List of package name prefixes that will apply this rule. @@ -959,7 +911,6 @@ pub struct CleanupPolicyMostRecentVersions { pub keep_count: ::core::option::Option, } /// Artifact policy configuration for repository cleanup policies. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CleanupPolicy { /// The user-provided ID of the cleanup policy. @@ -1001,9 +952,9 @@ pub mod cleanup_policy { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Action::Unspecified => "ACTION_UNSPECIFIED", - Action::Delete => "DELETE", - Action::Keep => "KEEP", + Self::Unspecified => "ACTION_UNSPECIFIED", + Self::Delete => "DELETE", + Self::Keep => "KEEP", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1016,7 +967,6 @@ pub mod cleanup_policy { } } } - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum ConditionType { /// Policy condition for matching versions. @@ -1029,7 +979,6 @@ pub mod cleanup_policy { } } /// Virtual repository configuration. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct VirtualRepositoryConfig { /// Policies that configure the upstream artifacts distributed by the Virtual @@ -1038,7 +987,6 @@ pub struct VirtualRepositoryConfig { pub upstream_policies: ::prost::alloc::vec::Vec, } /// Remote repository configuration. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RemoteRepositoryConfig { /// The description of the remote source. @@ -1056,7 +1004,6 @@ pub struct RemoteRepositoryConfig { /// Nested message and enum types in `RemoteRepositoryConfig`. pub mod remote_repository_config { /// The credentials to access the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpstreamCredentials { #[prost(oneof = "upstream_credentials::Credentials", tags = "1")] @@ -1065,7 +1012,6 @@ pub mod remote_repository_config { /// Nested message and enum types in `UpstreamCredentials`. pub mod upstream_credentials { /// Username and password credentials. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UsernamePasswordCredentials { /// The username to access the remote repository. @@ -1077,7 +1023,6 @@ pub mod remote_repository_config { #[prost(string, tag = "2")] pub password_secret_version: ::prost::alloc::string::String, } - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Credentials { /// Use username and password to access the remote repository. @@ -1086,7 +1031,6 @@ pub mod remote_repository_config { } } /// Configuration for a Docker remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct DockerRepository { /// Address of the remote repository. @@ -1122,8 +1066,8 @@ pub mod remote_repository_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - PublicRepository::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", - PublicRepository::DockerHub => "DOCKER_HUB", + Self::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", + Self::DockerHub => "DOCKER_HUB", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1136,7 +1080,6 @@ pub mod remote_repository_config { } } /// Address of the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum Upstream { /// One of the publicly available Docker repositories supported by Artifact @@ -1146,7 +1089,6 @@ pub mod remote_repository_config { } } /// Configuration for a Maven remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct MavenRepository { /// Address of the remote repository. @@ -1182,8 +1124,8 @@ pub mod remote_repository_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - PublicRepository::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", - PublicRepository::MavenCentral => "MAVEN_CENTRAL", + Self::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", + Self::MavenCentral => "MAVEN_CENTRAL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1196,7 +1138,6 @@ pub mod remote_repository_config { } } /// Address of the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum Upstream { /// One of the publicly available Maven repositories supported by Artifact @@ -1206,7 +1147,6 @@ pub mod remote_repository_config { } } /// Configuration for a Npm remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct NpmRepository { /// Address of the remote repository @@ -1241,8 +1181,8 @@ pub mod remote_repository_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - PublicRepository::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", - PublicRepository::Npmjs => "NPMJS", + Self::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", + Self::Npmjs => "NPMJS", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1255,7 +1195,6 @@ pub mod remote_repository_config { } } /// Address of the remote repository - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum Upstream { /// One of the publicly available Npm repositories supported by Artifact @@ -1265,7 +1204,6 @@ pub mod remote_repository_config { } } /// Configuration for a Python remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct PythonRepository { /// Address of the remote repository. @@ -1300,8 +1238,8 @@ pub mod remote_repository_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - PublicRepository::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", - PublicRepository::Pypi => "PYPI", + Self::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", + Self::Pypi => "PYPI", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1314,7 +1252,6 @@ pub mod remote_repository_config { } } /// Address of the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum Upstream { /// One of the publicly available Python repositories supported by Artifact @@ -1324,7 +1261,6 @@ pub mod remote_repository_config { } } /// Configuration for an Apt remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AptRepository { /// Address of the remote repository. @@ -1335,7 +1271,6 @@ pub mod remote_repository_config { pub mod apt_repository { /// Publicly available Apt repositories constructed from a common repository /// base and a custom repository path. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PublicRepository { /// A common public repository base for Apt. @@ -1375,9 +1310,9 @@ pub mod remote_repository_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - RepositoryBase::Unspecified => "REPOSITORY_BASE_UNSPECIFIED", - RepositoryBase::Debian => "DEBIAN", - RepositoryBase::Ubuntu => "UBUNTU", + Self::Unspecified => "REPOSITORY_BASE_UNSPECIFIED", + Self::Debian => "DEBIAN", + Self::Ubuntu => "UBUNTU", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1392,7 +1327,6 @@ pub mod remote_repository_config { } } /// Address of the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Upstream { /// One of the publicly available Apt repositories supported by Artifact @@ -1402,7 +1336,6 @@ pub mod remote_repository_config { } } /// Configuration for a Yum remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct YumRepository { /// Address of the remote repository. @@ -1413,7 +1346,6 @@ pub mod remote_repository_config { pub mod yum_repository { /// Publicly available Yum repositories constructed from a common repository /// base and a custom repository path. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PublicRepository { /// A common public repository base for Yum. @@ -1461,13 +1393,13 @@ pub mod remote_repository_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - RepositoryBase::Unspecified => "REPOSITORY_BASE_UNSPECIFIED", - RepositoryBase::Centos => "CENTOS", - RepositoryBase::CentosDebug => "CENTOS_DEBUG", - RepositoryBase::CentosVault => "CENTOS_VAULT", - RepositoryBase::CentosStream => "CENTOS_STREAM", - RepositoryBase::Rocky => "ROCKY", - RepositoryBase::Epel => "EPEL", + Self::Unspecified => "REPOSITORY_BASE_UNSPECIFIED", + Self::Centos => "CENTOS", + Self::CentosDebug => "CENTOS_DEBUG", + Self::CentosVault => "CENTOS_VAULT", + Self::CentosStream => "CENTOS_STREAM", + Self::Rocky => "ROCKY", + Self::Epel => "EPEL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1486,7 +1418,6 @@ pub mod remote_repository_config { } } /// Address of the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Upstream { /// One of the publicly available Yum repositories supported by Artifact @@ -1496,7 +1427,6 @@ pub mod remote_repository_config { } } /// Settings specific to the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum RemoteSource { /// Specific settings for a Docker remote repository. @@ -1520,7 +1450,6 @@ pub mod remote_repository_config { } } /// A Repository for storing artifacts with a specific format. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Repository { /// The name of the repository, for example: @@ -1592,7 +1521,6 @@ pub mod repository { /// MavenRepositoryConfig is maven related repository details. /// Provides additional configuration details for repositories of the maven /// format type. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct MavenRepositoryConfig { /// The repository with this flag will allow publishing @@ -1635,9 +1563,9 @@ pub mod repository { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - VersionPolicy::Unspecified => "VERSION_POLICY_UNSPECIFIED", - VersionPolicy::Release => "RELEASE", - VersionPolicy::Snapshot => "SNAPSHOT", + Self::Unspecified => "VERSION_POLICY_UNSPECIFIED", + Self::Release => "RELEASE", + Self::Snapshot => "SNAPSHOT", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1654,7 +1582,6 @@ pub mod repository { /// DockerRepositoryConfig is docker related repository details. /// Provides additional configuration details for repositories of the docker /// format type. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct DockerRepositoryConfig { /// The repository which enabled this flag prevents all tags from being @@ -1703,15 +1630,15 @@ pub mod repository { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Format::Unspecified => "FORMAT_UNSPECIFIED", - Format::Docker => "DOCKER", - Format::Maven => "MAVEN", - Format::Npm => "NPM", - Format::Apt => "APT", - Format::Yum => "YUM", - Format::Python => "PYTHON", - Format::Kfp => "KFP", - Format::Go => "GO", + Self::Unspecified => "FORMAT_UNSPECIFIED", + Self::Docker => "DOCKER", + Self::Maven => "MAVEN", + Self::Npm => "NPM", + Self::Apt => "APT", + Self::Yum => "YUM", + Self::Python => "PYTHON", + Self::Kfp => "KFP", + Self::Go => "GO", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1761,10 +1688,10 @@ pub mod repository { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Mode::Unspecified => "MODE_UNSPECIFIED", - Mode::StandardRepository => "STANDARD_REPOSITORY", - Mode::VirtualRepository => "VIRTUAL_REPOSITORY", - Mode::RemoteRepository => "REMOTE_REPOSITORY", + Self::Unspecified => "MODE_UNSPECIFIED", + Self::StandardRepository => "STANDARD_REPOSITORY", + Self::VirtualRepository => "VIRTUAL_REPOSITORY", + Self::RemoteRepository => "REMOTE_REPOSITORY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1779,7 +1706,6 @@ pub mod repository { } } /// Repository-specific configurations. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum FormatConfig { /// Maven repository config contains repository level configuration @@ -1793,7 +1719,6 @@ pub mod repository { } /// Repository configuration specific to the Mode value being selected (Remote /// or Virtual) - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum ModeConfig { /// Configuration specific for a Virtual Repository. @@ -1805,7 +1730,6 @@ pub mod repository { } } /// The request to list repositories. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListRepositoriesRequest { /// Required. The name of the parent resource whose repositories will be @@ -1820,7 +1744,6 @@ pub struct ListRepositoriesRequest { pub page_token: ::prost::alloc::string::String, } /// The response from listing repositories. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListRepositoriesResponse { /// The repositories returned. @@ -1832,7 +1755,6 @@ pub struct ListRepositoriesResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to retrieve a repository. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetRepositoryRequest { /// Required. The name of the repository to retrieve. @@ -1840,7 +1762,6 @@ pub struct GetRepositoryRequest { pub name: ::prost::alloc::string::String, } /// The request to create a new repository. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateRepositoryRequest { /// Required. The name of the parent resource where the repository will be @@ -1855,7 +1776,6 @@ pub struct CreateRepositoryRequest { pub repository: ::core::option::Option, } /// The request to update a repository. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateRepositoryRequest { /// The repository that replaces the resource on the server. @@ -1868,7 +1788,6 @@ pub struct UpdateRepositoryRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// The request to delete a repository. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteRepositoryRequest { /// Required. The name of the repository to delete. @@ -1876,7 +1795,6 @@ pub struct DeleteRepositoryRequest { pub name: ::prost::alloc::string::String, } /// The Artifact Registry settings that apply to a Project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ProjectSettings { /// The name of the project's settings. @@ -1924,14 +1842,10 @@ pub mod project_settings { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - RedirectionState::Unspecified => "REDIRECTION_STATE_UNSPECIFIED", - RedirectionState::RedirectionFromGcrIoDisabled => { - "REDIRECTION_FROM_GCR_IO_DISABLED" - } - RedirectionState::RedirectionFromGcrIoEnabled => { - "REDIRECTION_FROM_GCR_IO_ENABLED" - } - RedirectionState::RedirectionFromGcrIoFinalized => { + Self::Unspecified => "REDIRECTION_STATE_UNSPECIFIED", + Self::RedirectionFromGcrIoDisabled => "REDIRECTION_FROM_GCR_IO_DISABLED", + Self::RedirectionFromGcrIoEnabled => "REDIRECTION_FROM_GCR_IO_ENABLED", + Self::RedirectionFromGcrIoFinalized => { "REDIRECTION_FROM_GCR_IO_FINALIZED" } } @@ -1955,7 +1869,6 @@ pub mod project_settings { } } /// Gets the redirection status for a project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetProjectSettingsRequest { /// Required. The name of the projectSettings resource. @@ -1963,7 +1876,6 @@ pub struct GetProjectSettingsRequest { pub name: ::prost::alloc::string::String, } /// Sets the settings of the project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateProjectSettingsRequest { /// The project settings. @@ -1975,7 +1887,6 @@ pub struct UpdateProjectSettingsRequest { } /// Tags point to a version and represent an alternative name that can be used /// to access the version. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Tag { /// The name of the tag, for example: @@ -1993,7 +1904,6 @@ pub struct Tag { pub version: ::prost::alloc::string::String, } /// The request to list tags. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTagsRequest { /// The name of the parent package whose tags will be listed. @@ -2020,7 +1930,6 @@ pub struct ListTagsRequest { pub page_token: ::prost::alloc::string::String, } /// The response from listing tags. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTagsResponse { /// The tags returned. @@ -2032,7 +1941,6 @@ pub struct ListTagsResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to retrieve a tag. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetTagRequest { /// The name of the tag to retrieve. @@ -2040,7 +1948,6 @@ pub struct GetTagRequest { pub name: ::prost::alloc::string::String, } /// The request to create a new tag. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateTagRequest { /// The name of the parent resource where the tag will be created. @@ -2054,7 +1961,6 @@ pub struct CreateTagRequest { pub tag: ::core::option::Option, } /// The request to create or update a tag. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateTagRequest { /// The tag that replaces the resource on the server. @@ -2067,7 +1973,6 @@ pub struct UpdateTagRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// The request to delete a tag. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteTagRequest { /// The name of the tag to delete. @@ -2077,7 +1982,6 @@ pub struct DeleteTagRequest { /// The body of a version resource. A version resource represents a /// collection of components, such as files and other data. This may correspond /// to a version in many package management schemes. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Version { /// The name of the version, for example: @@ -2108,7 +2012,6 @@ pub struct Version { pub metadata: ::core::option::Option<::prost_types::Struct>, } /// The request to list versions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListVersionsRequest { /// The name of the parent resource whose versions will be listed. @@ -2128,7 +2031,6 @@ pub struct ListVersionsRequest { pub order_by: ::prost::alloc::string::String, } /// The response from listing versions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListVersionsResponse { /// The versions returned. @@ -2140,7 +2042,6 @@ pub struct ListVersionsResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to retrieve a version. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetVersionRequest { /// The name of the version to retrieve. @@ -2151,7 +2052,6 @@ pub struct GetVersionRequest { pub view: i32, } /// The request to delete a version. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteVersionRequest { /// The name of the version to delete. @@ -2163,7 +2063,6 @@ pub struct DeleteVersionRequest { pub force: bool, } /// The request to delete multiple versions across a repository. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchDeleteVersionsRequest { /// The name of the repository holding all requested versions. @@ -2178,7 +2077,6 @@ pub struct BatchDeleteVersionsRequest { pub validate_only: bool, } /// The metadata of an LRO from deleting multiple versions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchDeleteVersionsMetadata { /// The versions the operation failed to delete. @@ -2205,9 +2103,9 @@ impl VersionView { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - VersionView::Unspecified => "VERSION_VIEW_UNSPECIFIED", - VersionView::Basic => "BASIC", - VersionView::Full => "FULL", + Self::Unspecified => "VERSION_VIEW_UNSPECIFIED", + Self::Basic => "BASIC", + Self::Full => "FULL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -2221,12 +2119,17 @@ impl VersionView { } } /// Metadata type for longrunning-operations, currently empty. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct OperationMetadata {} /// Generated client implementations. pub mod artifact_registry_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value, + )] use tonic::codegen::*; use tonic::codegen::http::Uri; /// The Artifact Registry API service. @@ -2261,8 +2164,8 @@ pub mod artifact_registry_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -2287,7 +2190,7 @@ pub mod artifact_registry_client { >, , - >>::Error: Into + Send + Sync, + >>::Error: Into + std::marker::Send + std::marker::Sync, { ArtifactRegistryClient::new(InterceptedService::new(inner, interceptor)) } @@ -2334,8 +2237,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2362,8 +2264,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2393,8 +2294,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2421,8 +2321,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2452,8 +2351,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2480,8 +2378,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2511,8 +2408,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2539,8 +2435,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2573,8 +2468,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2607,8 +2501,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2638,8 +2531,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2666,8 +2558,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2698,8 +2589,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2726,8 +2616,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2759,8 +2648,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2790,8 +2678,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2818,8 +2705,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2850,8 +2736,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2881,8 +2766,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2909,8 +2793,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2941,8 +2824,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2973,8 +2855,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3004,8 +2885,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3032,8 +2912,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3063,8 +2942,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3091,8 +2969,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3119,8 +2996,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3147,8 +3023,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3175,8 +3050,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3208,8 +3082,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3241,8 +3114,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3276,8 +3148,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3307,8 +3178,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3338,8 +3208,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3366,8 +3235,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3394,8 +3262,7 @@ pub mod artifact_registry_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; diff --git a/googleapis/src/bytes/google.iam.v1.rs b/googleapis/src/bytes/google.iam.v1.rs index 9ac9638e..0bbcbb7e 100644 --- a/googleapis/src/bytes/google.iam.v1.rs +++ b/googleapis/src/bytes/google.iam.v1.rs @@ -1,6 +1,5 @@ // This file is @generated by prost-build. /// Encapsulates settings provided to GetIamPolicy. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct GetPolicyOptions { /// Optional. The maximum policy version that will be used to format the @@ -97,7 +96,6 @@ pub struct GetPolicyOptions { /// /// For a description of IAM and its features, see the /// [IAM documentation](). -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Policy { /// Specifies the format of the policy. @@ -158,7 +156,6 @@ pub struct Policy { pub etag: ::prost::bytes::Bytes, } /// Associates `members`, or principals, with a `role`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Binding { /// Role that is assigned to the list of `members`, or principals. @@ -277,7 +274,6 @@ pub struct Binding { /// For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ /// logging. It also exempts `jose@example.com` from DATA_READ logging, and /// `aliya@example.com` from DATA_WRITE logging. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AuditConfig { /// Specifies a service that will be enabled for audit logging. @@ -308,7 +304,6 @@ pub struct AuditConfig { /// /// This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting /// jose@example.com from DATA_READ logging. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AuditLogConfig { /// The log type that this config enables. @@ -354,10 +349,10 @@ pub mod audit_log_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - LogType::Unspecified => "LOG_TYPE_UNSPECIFIED", - LogType::AdminRead => "ADMIN_READ", - LogType::DataWrite => "DATA_WRITE", - LogType::DataRead => "DATA_READ", + Self::Unspecified => "LOG_TYPE_UNSPECIFIED", + Self::AdminRead => "ADMIN_READ", + Self::DataWrite => "DATA_WRITE", + Self::DataRead => "DATA_READ", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -373,7 +368,6 @@ pub mod audit_log_config { } } /// The difference delta between two policies. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PolicyDelta { /// The delta for Bindings between two policies. @@ -385,7 +379,6 @@ pub struct PolicyDelta { } /// One delta entry for Binding. Each individual change (only one member in each /// entry) to a binding will be a separate entry. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BindingDelta { /// The action that was performed on a Binding. @@ -436,9 +429,9 @@ pub mod binding_delta { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Action::Unspecified => "ACTION_UNSPECIFIED", - Action::Add => "ADD", - Action::Remove => "REMOVE", + Self::Unspecified => "ACTION_UNSPECIFIED", + Self::Add => "ADD", + Self::Remove => "REMOVE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -454,7 +447,6 @@ pub mod binding_delta { } /// One delta entry for AuditConfig. Each individual change (only one /// exempted_member in each entry) to a AuditConfig will be a separate entry. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AuditConfigDelta { /// The action that was performed on an audit configuration in a policy. @@ -508,9 +500,9 @@ pub mod audit_config_delta { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Action::Unspecified => "ACTION_UNSPECIFIED", - Action::Add => "ADD", - Action::Remove => "REMOVE", + Self::Unspecified => "ACTION_UNSPECIFIED", + Self::Add => "ADD", + Self::Remove => "REMOVE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -525,7 +517,6 @@ pub mod audit_config_delta { } } /// Request message for `SetIamPolicy` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct SetIamPolicyRequest { /// REQUIRED: The resource for which the policy is being specified. @@ -547,7 +538,6 @@ pub struct SetIamPolicyRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Request message for `GetIamPolicy` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetIamPolicyRequest { /// REQUIRED: The resource for which the policy is being requested. @@ -560,7 +550,6 @@ pub struct GetIamPolicyRequest { pub options: ::core::option::Option, } /// Request message for `TestIamPermissions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TestIamPermissionsRequest { /// REQUIRED: The resource for which the policy detail is being requested. @@ -575,7 +564,6 @@ pub struct TestIamPermissionsRequest { pub permissions: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Response message for `TestIamPermissions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TestIamPermissionsResponse { /// A subset of `TestPermissionsRequest.permissions` that the caller is @@ -585,7 +573,13 @@ pub struct TestIamPermissionsResponse { } /// Generated client implementations. pub mod iam_policy_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value, + )] use tonic::codegen::*; use tonic::codegen::http::Uri; /// API Overview @@ -633,8 +627,8 @@ pub mod iam_policy_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -659,7 +653,7 @@ pub mod iam_policy_client { >, , - >>::Error: Into + Send + Sync, + >>::Error: Into + std::marker::Send + std::marker::Sync, { IamPolicyClient::new(InterceptedService::new(inner, interceptor)) } @@ -706,8 +700,7 @@ pub mod iam_policy_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -731,8 +724,7 @@ pub mod iam_policy_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -763,8 +755,7 @@ pub mod iam_policy_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; diff --git a/googleapis/src/bytes/google.longrunning.rs b/googleapis/src/bytes/google.longrunning.rs index 4ede41fe..612502d6 100644 --- a/googleapis/src/bytes/google.longrunning.rs +++ b/googleapis/src/bytes/google.longrunning.rs @@ -1,7 +1,6 @@ // This file is @generated by prost-build. /// This resource represents a long-running operation that is the result of a /// network API call. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Operation { /// The server-assigned name, which is only unique within the same service that @@ -31,7 +30,6 @@ pub mod operation { /// The operation result, which can be either an `error` or a valid `response`. /// If `done` == `false`, neither `error` nor `response` is set. /// If `done` == `true`, exactly one of `error` or `response` is set. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Result { /// The error result of the operation in case of failure or cancellation. @@ -50,7 +48,6 @@ pub mod operation { } } /// The request message for [Operations.GetOperation][google.longrunning.Operations.GetOperation]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetOperationRequest { /// The name of the operation resource. @@ -58,7 +55,6 @@ pub struct GetOperationRequest { pub name: ::prost::alloc::string::String, } /// The request message for [Operations.ListOperations][google.longrunning.Operations.ListOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListOperationsRequest { /// The name of the operation's parent resource. @@ -75,7 +71,6 @@ pub struct ListOperationsRequest { pub page_token: ::prost::alloc::string::String, } /// The response message for [Operations.ListOperations][google.longrunning.Operations.ListOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListOperationsResponse { /// A list of operations that matches the specified filter in the request. @@ -86,7 +81,6 @@ pub struct ListOperationsResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request message for [Operations.CancelOperation][google.longrunning.Operations.CancelOperation]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CancelOperationRequest { /// The name of the operation resource to be cancelled. @@ -94,7 +88,6 @@ pub struct CancelOperationRequest { pub name: ::prost::alloc::string::String, } /// The request message for [Operations.DeleteOperation][google.longrunning.Operations.DeleteOperation]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteOperationRequest { /// The name of the operation resource to be deleted. @@ -102,7 +95,6 @@ pub struct DeleteOperationRequest { pub name: ::prost::alloc::string::String, } /// The request message for [Operations.WaitOperation][google.longrunning.Operations.WaitOperation]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct WaitOperationRequest { /// The name of the operation resource to wait on. @@ -125,7 +117,6 @@ pub struct WaitOperationRequest { /// metadata_type: "LongRunningRecognizeMetadata" /// }; /// } -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct OperationInfo { /// Required. The message name of the primary return type for this @@ -150,7 +141,13 @@ pub struct OperationInfo { } /// Generated client implementations. pub mod operations_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value, + )] use tonic::codegen::*; use tonic::codegen::http::Uri; /// Manages long-running operations with an API service. @@ -181,8 +178,8 @@ pub mod operations_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -207,7 +204,7 @@ pub mod operations_client { >, , - >>::Error: Into + Send + Sync, + >>::Error: Into + std::marker::Send + std::marker::Sync, { OperationsClient::new(InterceptedService::new(inner, interceptor)) } @@ -263,8 +260,7 @@ pub mod operations_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -290,8 +286,7 @@ pub mod operations_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -318,8 +313,7 @@ pub mod operations_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -352,8 +346,7 @@ pub mod operations_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -385,8 +378,7 @@ pub mod operations_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; diff --git a/googleapis/src/bytes/google.monitoring.v3.rs b/googleapis/src/bytes/google.monitoring.v3.rs new file mode 100644 index 00000000..f7da40a9 --- /dev/null +++ b/googleapis/src/bytes/google.monitoring.v3.rs @@ -0,0 +1,1620 @@ +// This file is @generated by prost-build. +/// A single strongly-typed value. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct TypedValue { + /// The typed value field. + #[prost(oneof = "typed_value::Value", tags = "1, 2, 3, 4, 5")] + pub value: ::core::option::Option, +} +/// Nested message and enum types in `TypedValue`. +pub mod typed_value { + /// The typed value field. + #[derive(Clone, PartialEq, ::prost::Oneof)] + pub enum Value { + /// A Boolean value: `true` or `false`. + #[prost(bool, tag = "1")] + BoolValue(bool), + /// A 64-bit integer. Its range is approximately ±9.2x1018. + #[prost(int64, tag = "2")] + Int64Value(i64), + /// A 64-bit double-precision floating-point number. Its magnitude + /// is approximately ±10±300 and it has 16 + /// significant digits of precision. + #[prost(double, tag = "3")] + DoubleValue(f64), + /// A variable-length string value. + #[prost(string, tag = "4")] + StringValue(::prost::alloc::string::String), + /// A distribution value. + #[prost(message, tag = "5")] + DistributionValue(super::super::super::api::Distribution), + } +} +/// Describes a time interval: +/// +/// * Reads: A half-open time interval. It includes the end time but +/// excludes the start time: `(startTime, endTime]`. The start time +/// must be specified, must be earlier than the end time, and should be +/// no older than the data retention period for the metric. +/// * Writes: A closed time interval. It extends from the start time to the end +/// time, +/// and includes both: `\[startTime, endTime\]`. Valid time intervals +/// depend on the +/// [`MetricKind`]() +/// of the metric value. The end time must not be earlier than the start +/// time, and the end time must not be more than 25 hours in the past or more +/// than five minutes in the future. +/// * For `GAUGE` metrics, the `startTime` value is technically optional; if +/// no value is specified, the start time defaults to the value of the +/// end time, and the interval represents a single point in time. If both +/// start and end times are specified, they must be identical. Such an +/// interval is valid only for `GAUGE` metrics, which are point-in-time +/// measurements. The end time of a new interval must be at least a +/// millisecond after the end time of the previous interval. +/// * For `DELTA` metrics, the start time and end time must specify a +/// non-zero interval, with subsequent points specifying contiguous and +/// non-overlapping intervals. For `DELTA` metrics, the start time of +/// the next interval must be at least a millisecond after the end time +/// of the previous interval. +/// * For `CUMULATIVE` metrics, the start time and end time must specify a +/// non-zero interval, with subsequent points specifying the same +/// start time and increasing end times, until an event resets the +/// cumulative value to zero and sets a new start time for the following +/// points. The new start time must be at least a millisecond after the +/// end time of the previous interval. +/// * The start time of a new interval must be at least a millisecond after +/// the +/// end time of the previous interval because intervals are closed. If the +/// start time of a new interval is the same as the end time of the +/// previous interval, then data written at the new start time could +/// overwrite data written at the previous end time. +#[derive(Clone, Copy, PartialEq, ::prost::Message)] +pub struct TimeInterval { + /// Required. The end of the time interval. + #[prost(message, optional, tag = "2")] + pub end_time: ::core::option::Option<::prost_types::Timestamp>, + /// Optional. The beginning of the time interval. The default value + /// for the start time is the end time. The start time must not be + /// later than the end time. + #[prost(message, optional, tag = "1")] + pub start_time: ::core::option::Option<::prost_types::Timestamp>, +} +/// Describes how to combine multiple time series to provide a different view of +/// the data. Aggregation of time series is done in two steps. First, each time +/// series in the set is _aligned_ to the same time interval boundaries, then the +/// set of time series is optionally _reduced_ in number. +/// +/// Alignment consists of applying the `per_series_aligner` operation +/// to each time series after its data has been divided into regular +/// `alignment_period` time intervals. This process takes _all_ of the data +/// points in an alignment period, applies a mathematical transformation such as +/// averaging, minimum, maximum, delta, etc., and converts them into a single +/// data point per period. +/// +/// Reduction is when the aligned and transformed time series can optionally be +/// combined, reducing the number of time series through similar mathematical +/// transformations. Reduction involves applying a `cross_series_reducer` to +/// all the time series, optionally sorting the time series into subsets with +/// `group_by_fields`, and applying the reducer to each subset. +/// +/// The raw time series data can contain a huge amount of information from +/// multiple sources. Alignment and reduction transforms this mass of data into +/// a more manageable and representative collection of data, for example "the +/// 95% latency across the average of all tasks in a cluster". This +/// representative data can be more easily graphed and comprehended, and the +/// individual time series data is still available for later drilldown. For more +/// details, see [Filtering and +/// aggregation](). +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct Aggregation { + /// The `alignment_period` specifies a time interval, in seconds, that is used + /// to divide the data in all the + /// [time series][google.monitoring.v3.TimeSeries] into consistent blocks of + /// time. This will be done before the per-series aligner can be applied to + /// the data. + /// + /// The value must be at least 60 seconds. If a per-series + /// aligner other than `ALIGN_NONE` is specified, this field is required or an + /// error is returned. If no per-series aligner is specified, or the aligner + /// `ALIGN_NONE` is specified, then this field is ignored. + /// + /// The maximum value of the `alignment_period` is 104 weeks (2 years) for + /// charts, and 90,000 seconds (25 hours) for alerting policies. + #[prost(message, optional, tag = "1")] + pub alignment_period: ::core::option::Option<::prost_types::Duration>, + /// An `Aligner` describes how to bring the data points in a single + /// time series into temporal alignment. Except for `ALIGN_NONE`, all + /// alignments cause all the data points in an `alignment_period` to be + /// mathematically grouped together, resulting in a single data point for + /// each `alignment_period` with end timestamp at the end of the period. + /// + /// Not all alignment operations may be applied to all time series. The valid + /// choices depend on the `metric_kind` and `value_type` of the original time + /// series. Alignment can change the `metric_kind` or the `value_type` of + /// the time series. + /// + /// Time series data must be aligned in order to perform cross-time + /// series reduction. If `cross_series_reducer` is specified, then + /// `per_series_aligner` must be specified and not equal to `ALIGN_NONE` + /// and `alignment_period` must be specified; otherwise, an error is + /// returned. + #[prost(enumeration = "aggregation::Aligner", tag = "2")] + pub per_series_aligner: i32, + /// The reduction operation to be used to combine time series into a single + /// time series, where the value of each data point in the resulting series is + /// a function of all the already aligned values in the input time series. + /// + /// Not all reducer operations can be applied to all time series. The valid + /// choices depend on the `metric_kind` and the `value_type` of the original + /// time series. Reduction can yield a time series with a different + /// `metric_kind` or `value_type` than the input time series. + /// + /// Time series data must first be aligned (see `per_series_aligner`) in order + /// to perform cross-time series reduction. If `cross_series_reducer` is + /// specified, then `per_series_aligner` must be specified, and must not be + /// `ALIGN_NONE`. An `alignment_period` must also be specified; otherwise, an + /// error is returned. + #[prost(enumeration = "aggregation::Reducer", tag = "4")] + pub cross_series_reducer: i32, + /// The set of fields to preserve when `cross_series_reducer` is + /// specified. The `group_by_fields` determine how the time series are + /// partitioned into subsets prior to applying the aggregation + /// operation. Each subset contains time series that have the same + /// value for each of the grouping fields. Each individual time + /// series is a member of exactly one subset. The + /// `cross_series_reducer` is applied to each subset of time series. + /// It is not possible to reduce across different resource types, so + /// this field implicitly contains `resource.type`. Fields not + /// specified in `group_by_fields` are aggregated away. If + /// `group_by_fields` is not specified and all the time series have + /// the same resource type, then the time series are aggregated into + /// a single output time series. If `cross_series_reducer` is not + /// defined, this field is ignored. + #[prost(string, repeated, tag = "5")] + pub group_by_fields: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, +} +/// Nested message and enum types in `Aggregation`. +pub mod aggregation { + /// The `Aligner` specifies the operation that will be applied to the data + /// points in each alignment period in a time series. Except for + /// `ALIGN_NONE`, which specifies that no operation be applied, each alignment + /// operation replaces the set of data values in each alignment period with + /// a single value: the result of applying the operation to the data values. + /// An aligned time series has a single data value at the end of each + /// `alignment_period`. + /// + /// An alignment operation can change the data type of the values, too. For + /// example, if you apply a counting operation to boolean values, the data + /// `value_type` in the original time series is `BOOLEAN`, but the `value_type` + /// in the aligned result is `INT64`. + #[derive( + Clone, + Copy, + Debug, + PartialEq, + Eq, + Hash, + PartialOrd, + Ord, + ::prost::Enumeration + )] + #[repr(i32)] + pub enum Aligner { + /// No alignment. Raw data is returned. Not valid if cross-series reduction + /// is requested. The `value_type` of the result is the same as the + /// `value_type` of the input. + AlignNone = 0, + /// Align and convert to + /// [DELTA][google.api.MetricDescriptor.MetricKind.DELTA]. + /// The output is `delta = y1 - y0`. + /// + /// This alignment is valid for + /// [CUMULATIVE][google.api.MetricDescriptor.MetricKind.CUMULATIVE] and + /// `DELTA` metrics. If the selected alignment period results in periods + /// with no data, then the aligned value for such a period is created by + /// interpolation. The `value_type` of the aligned result is the same as + /// the `value_type` of the input. + AlignDelta = 1, + /// Align and convert to a rate. The result is computed as + /// `rate = (y1 - y0)/(t1 - t0)`, or "delta over time". + /// Think of this aligner as providing the slope of the line that passes + /// through the value at the start and at the end of the `alignment_period`. + /// + /// This aligner is valid for `CUMULATIVE` + /// and `DELTA` metrics with numeric values. If the selected alignment + /// period results in periods with no data, then the aligned value for + /// such a period is created by interpolation. The output is a `GAUGE` + /// metric with `value_type` `DOUBLE`. + /// + /// If, by "rate", you mean "percentage change", see the + /// `ALIGN_PERCENT_CHANGE` aligner instead. + AlignRate = 2, + /// Align by interpolating between adjacent points around the alignment + /// period boundary. This aligner is valid for `GAUGE` metrics with + /// numeric values. The `value_type` of the aligned result is the same as the + /// `value_type` of the input. + AlignInterpolate = 3, + /// Align by moving the most recent data point before the end of the + /// alignment period to the boundary at the end of the alignment + /// period. This aligner is valid for `GAUGE` metrics. The `value_type` of + /// the aligned result is the same as the `value_type` of the input. + AlignNextOlder = 4, + /// Align the time series by returning the minimum value in each alignment + /// period. This aligner is valid for `GAUGE` and `DELTA` metrics with + /// numeric values. The `value_type` of the aligned result is the same as + /// the `value_type` of the input. + AlignMin = 10, + /// Align the time series by returning the maximum value in each alignment + /// period. This aligner is valid for `GAUGE` and `DELTA` metrics with + /// numeric values. The `value_type` of the aligned result is the same as + /// the `value_type` of the input. + AlignMax = 11, + /// Align the time series by returning the mean value in each alignment + /// period. This aligner is valid for `GAUGE` and `DELTA` metrics with + /// numeric values. The `value_type` of the aligned result is `DOUBLE`. + AlignMean = 12, + /// Align the time series by returning the number of values in each alignment + /// period. This aligner is valid for `GAUGE` and `DELTA` metrics with + /// numeric or Boolean values. The `value_type` of the aligned result is + /// `INT64`. + AlignCount = 13, + /// Align the time series by returning the sum of the values in each + /// alignment period. This aligner is valid for `GAUGE` and `DELTA` + /// metrics with numeric and distribution values. The `value_type` of the + /// aligned result is the same as the `value_type` of the input. + AlignSum = 14, + /// Align the time series by returning the standard deviation of the values + /// in each alignment period. This aligner is valid for `GAUGE` and + /// `DELTA` metrics with numeric values. The `value_type` of the output is + /// `DOUBLE`. + AlignStddev = 15, + /// Align the time series by returning the number of `True` values in + /// each alignment period. This aligner is valid for `GAUGE` metrics with + /// Boolean values. The `value_type` of the output is `INT64`. + AlignCountTrue = 16, + /// Align the time series by returning the number of `False` values in + /// each alignment period. This aligner is valid for `GAUGE` metrics with + /// Boolean values. The `value_type` of the output is `INT64`. + AlignCountFalse = 24, + /// Align the time series by returning the ratio of the number of `True` + /// values to the total number of values in each alignment period. This + /// aligner is valid for `GAUGE` metrics with Boolean values. The output + /// value is in the range \[0.0, 1.0\] and has `value_type` `DOUBLE`. + AlignFractionTrue = 17, + /// Align the time series by using [percentile + /// aggregation](). The resulting + /// data point in each alignment period is the 99th percentile of all data + /// points in the period. This aligner is valid for `GAUGE` and `DELTA` + /// metrics with distribution values. The output is a `GAUGE` metric with + /// `value_type` `DOUBLE`. + AlignPercentile99 = 18, + /// Align the time series by using [percentile + /// aggregation](). The resulting + /// data point in each alignment period is the 95th percentile of all data + /// points in the period. This aligner is valid for `GAUGE` and `DELTA` + /// metrics with distribution values. The output is a `GAUGE` metric with + /// `value_type` `DOUBLE`. + AlignPercentile95 = 19, + /// Align the time series by using [percentile + /// aggregation](). The resulting + /// data point in each alignment period is the 50th percentile of all data + /// points in the period. This aligner is valid for `GAUGE` and `DELTA` + /// metrics with distribution values. The output is a `GAUGE` metric with + /// `value_type` `DOUBLE`. + AlignPercentile50 = 20, + /// Align the time series by using [percentile + /// aggregation](). The resulting + /// data point in each alignment period is the 5th percentile of all data + /// points in the period. This aligner is valid for `GAUGE` and `DELTA` + /// metrics with distribution values. The output is a `GAUGE` metric with + /// `value_type` `DOUBLE`. + AlignPercentile05 = 21, + /// Align and convert to a percentage change. This aligner is valid for + /// `GAUGE` and `DELTA` metrics with numeric values. This alignment returns + /// `((current - previous)/previous) * 100`, where the value of `previous` is + /// determined based on the `alignment_period`. + /// + /// If the values of `current` and `previous` are both 0, then the returned + /// value is 0. If only `previous` is 0, the returned value is infinity. + /// + /// A 10-minute moving mean is computed at each point of the alignment period + /// prior to the above calculation to smooth the metric and prevent false + /// positives from very short-lived spikes. The moving mean is only + /// applicable for data whose values are `>= 0`. Any values `< 0` are + /// treated as a missing datapoint, and are ignored. While `DELTA` + /// metrics are accepted by this alignment, special care should be taken that + /// the values for the metric will always be positive. The output is a + /// `GAUGE` metric with `value_type` `DOUBLE`. + AlignPercentChange = 23, + } + impl Aligner { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::AlignNone => "ALIGN_NONE", + Self::AlignDelta => "ALIGN_DELTA", + Self::AlignRate => "ALIGN_RATE", + Self::AlignInterpolate => "ALIGN_INTERPOLATE", + Self::AlignNextOlder => "ALIGN_NEXT_OLDER", + Self::AlignMin => "ALIGN_MIN", + Self::AlignMax => "ALIGN_MAX", + Self::AlignMean => "ALIGN_MEAN", + Self::AlignCount => "ALIGN_COUNT", + Self::AlignSum => "ALIGN_SUM", + Self::AlignStddev => "ALIGN_STDDEV", + Self::AlignCountTrue => "ALIGN_COUNT_TRUE", + Self::AlignCountFalse => "ALIGN_COUNT_FALSE", + Self::AlignFractionTrue => "ALIGN_FRACTION_TRUE", + Self::AlignPercentile99 => "ALIGN_PERCENTILE_99", + Self::AlignPercentile95 => "ALIGN_PERCENTILE_95", + Self::AlignPercentile50 => "ALIGN_PERCENTILE_50", + Self::AlignPercentile05 => "ALIGN_PERCENTILE_05", + Self::AlignPercentChange => "ALIGN_PERCENT_CHANGE", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "ALIGN_NONE" => Some(Self::AlignNone), + "ALIGN_DELTA" => Some(Self::AlignDelta), + "ALIGN_RATE" => Some(Self::AlignRate), + "ALIGN_INTERPOLATE" => Some(Self::AlignInterpolate), + "ALIGN_NEXT_OLDER" => Some(Self::AlignNextOlder), + "ALIGN_MIN" => Some(Self::AlignMin), + "ALIGN_MAX" => Some(Self::AlignMax), + "ALIGN_MEAN" => Some(Self::AlignMean), + "ALIGN_COUNT" => Some(Self::AlignCount), + "ALIGN_SUM" => Some(Self::AlignSum), + "ALIGN_STDDEV" => Some(Self::AlignStddev), + "ALIGN_COUNT_TRUE" => Some(Self::AlignCountTrue), + "ALIGN_COUNT_FALSE" => Some(Self::AlignCountFalse), + "ALIGN_FRACTION_TRUE" => Some(Self::AlignFractionTrue), + "ALIGN_PERCENTILE_99" => Some(Self::AlignPercentile99), + "ALIGN_PERCENTILE_95" => Some(Self::AlignPercentile95), + "ALIGN_PERCENTILE_50" => Some(Self::AlignPercentile50), + "ALIGN_PERCENTILE_05" => Some(Self::AlignPercentile05), + "ALIGN_PERCENT_CHANGE" => Some(Self::AlignPercentChange), + _ => None, + } + } + } + /// A Reducer operation describes how to aggregate data points from multiple + /// time series into a single time series, where the value of each data point + /// in the resulting series is a function of all the already aligned values in + /// the input time series. + #[derive( + Clone, + Copy, + Debug, + PartialEq, + Eq, + Hash, + PartialOrd, + Ord, + ::prost::Enumeration + )] + #[repr(i32)] + pub enum Reducer { + /// No cross-time series reduction. The output of the `Aligner` is + /// returned. + ReduceNone = 0, + /// Reduce by computing the mean value across time series for each + /// alignment period. This reducer is valid for + /// [DELTA][google.api.MetricDescriptor.MetricKind.DELTA] and + /// [GAUGE][google.api.MetricDescriptor.MetricKind.GAUGE] metrics with + /// numeric or distribution values. The `value_type` of the output is + /// [DOUBLE][google.api.MetricDescriptor.ValueType.DOUBLE]. + ReduceMean = 1, + /// Reduce by computing the minimum value across time series for each + /// alignment period. This reducer is valid for `DELTA` and `GAUGE` metrics + /// with numeric values. The `value_type` of the output is the same as the + /// `value_type` of the input. + ReduceMin = 2, + /// Reduce by computing the maximum value across time series for each + /// alignment period. This reducer is valid for `DELTA` and `GAUGE` metrics + /// with numeric values. The `value_type` of the output is the same as the + /// `value_type` of the input. + ReduceMax = 3, + /// Reduce by computing the sum across time series for each + /// alignment period. This reducer is valid for `DELTA` and `GAUGE` metrics + /// with numeric and distribution values. The `value_type` of the output is + /// the same as the `value_type` of the input. + ReduceSum = 4, + /// Reduce by computing the standard deviation across time series + /// for each alignment period. This reducer is valid for `DELTA` and + /// `GAUGE` metrics with numeric or distribution values. The `value_type` + /// of the output is `DOUBLE`. + ReduceStddev = 5, + /// Reduce by computing the number of data points across time series + /// for each alignment period. This reducer is valid for `DELTA` and + /// `GAUGE` metrics of numeric, Boolean, distribution, and string + /// `value_type`. The `value_type` of the output is `INT64`. + ReduceCount = 6, + /// Reduce by computing the number of `True`-valued data points across time + /// series for each alignment period. This reducer is valid for `DELTA` and + /// `GAUGE` metrics of Boolean `value_type`. The `value_type` of the output + /// is `INT64`. + ReduceCountTrue = 7, + /// Reduce by computing the number of `False`-valued data points across time + /// series for each alignment period. This reducer is valid for `DELTA` and + /// `GAUGE` metrics of Boolean `value_type`. The `value_type` of the output + /// is `INT64`. + ReduceCountFalse = 15, + /// Reduce by computing the ratio of the number of `True`-valued data points + /// to the total number of data points for each alignment period. This + /// reducer is valid for `DELTA` and `GAUGE` metrics of Boolean `value_type`. + /// The output value is in the range \[0.0, 1.0\] and has `value_type` + /// `DOUBLE`. + ReduceFractionTrue = 8, + /// Reduce by computing the [99th + /// percentile]() of data points + /// across time series for each alignment period. This reducer is valid for + /// `GAUGE` and `DELTA` metrics of numeric and distribution type. The value + /// of the output is `DOUBLE`. + ReducePercentile99 = 9, + /// Reduce by computing the [95th + /// percentile]() of data points + /// across time series for each alignment period. This reducer is valid for + /// `GAUGE` and `DELTA` metrics of numeric and distribution type. The value + /// of the output is `DOUBLE`. + ReducePercentile95 = 10, + /// Reduce by computing the [50th + /// percentile]() of data points + /// across time series for each alignment period. This reducer is valid for + /// `GAUGE` and `DELTA` metrics of numeric and distribution type. The value + /// of the output is `DOUBLE`. + ReducePercentile50 = 11, + /// Reduce by computing the [5th + /// percentile]() of data points + /// across time series for each alignment period. This reducer is valid for + /// `GAUGE` and `DELTA` metrics of numeric and distribution type. The value + /// of the output is `DOUBLE`. + ReducePercentile05 = 12, + } + impl Reducer { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::ReduceNone => "REDUCE_NONE", + Self::ReduceMean => "REDUCE_MEAN", + Self::ReduceMin => "REDUCE_MIN", + Self::ReduceMax => "REDUCE_MAX", + Self::ReduceSum => "REDUCE_SUM", + Self::ReduceStddev => "REDUCE_STDDEV", + Self::ReduceCount => "REDUCE_COUNT", + Self::ReduceCountTrue => "REDUCE_COUNT_TRUE", + Self::ReduceCountFalse => "REDUCE_COUNT_FALSE", + Self::ReduceFractionTrue => "REDUCE_FRACTION_TRUE", + Self::ReducePercentile99 => "REDUCE_PERCENTILE_99", + Self::ReducePercentile95 => "REDUCE_PERCENTILE_95", + Self::ReducePercentile50 => "REDUCE_PERCENTILE_50", + Self::ReducePercentile05 => "REDUCE_PERCENTILE_05", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "REDUCE_NONE" => Some(Self::ReduceNone), + "REDUCE_MEAN" => Some(Self::ReduceMean), + "REDUCE_MIN" => Some(Self::ReduceMin), + "REDUCE_MAX" => Some(Self::ReduceMax), + "REDUCE_SUM" => Some(Self::ReduceSum), + "REDUCE_STDDEV" => Some(Self::ReduceStddev), + "REDUCE_COUNT" => Some(Self::ReduceCount), + "REDUCE_COUNT_TRUE" => Some(Self::ReduceCountTrue), + "REDUCE_COUNT_FALSE" => Some(Self::ReduceCountFalse), + "REDUCE_FRACTION_TRUE" => Some(Self::ReduceFractionTrue), + "REDUCE_PERCENTILE_99" => Some(Self::ReducePercentile99), + "REDUCE_PERCENTILE_95" => Some(Self::ReducePercentile95), + "REDUCE_PERCENTILE_50" => Some(Self::ReducePercentile50), + "REDUCE_PERCENTILE_05" => Some(Self::ReducePercentile05), + _ => None, + } + } + } +} +/// Specifies an ordering relationship on two arguments, called `left` and +/// `right`. +#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] +#[repr(i32)] +pub enum ComparisonType { + /// No ordering relationship is specified. + ComparisonUnspecified = 0, + /// True if the left argument is greater than the right argument. + ComparisonGt = 1, + /// True if the left argument is greater than or equal to the right argument. + ComparisonGe = 2, + /// True if the left argument is less than the right argument. + ComparisonLt = 3, + /// True if the left argument is less than or equal to the right argument. + ComparisonLe = 4, + /// True if the left argument is equal to the right argument. + ComparisonEq = 5, + /// True if the left argument is not equal to the right argument. + ComparisonNe = 6, +} +impl ComparisonType { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::ComparisonUnspecified => "COMPARISON_UNSPECIFIED", + Self::ComparisonGt => "COMPARISON_GT", + Self::ComparisonGe => "COMPARISON_GE", + Self::ComparisonLt => "COMPARISON_LT", + Self::ComparisonLe => "COMPARISON_LE", + Self::ComparisonEq => "COMPARISON_EQ", + Self::ComparisonNe => "COMPARISON_NE", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "COMPARISON_UNSPECIFIED" => Some(Self::ComparisonUnspecified), + "COMPARISON_GT" => Some(Self::ComparisonGt), + "COMPARISON_GE" => Some(Self::ComparisonGe), + "COMPARISON_LT" => Some(Self::ComparisonLt), + "COMPARISON_LE" => Some(Self::ComparisonLe), + "COMPARISON_EQ" => Some(Self::ComparisonEq), + "COMPARISON_NE" => Some(Self::ComparisonNe), + _ => None, + } + } +} +/// The tier of service for a Metrics Scope. Please see the +/// [service tiers +/// documentation]() for more +/// details. +#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] +#[repr(i32)] +pub enum ServiceTier { + /// An invalid sentinel value, used to indicate that a tier has not + /// been provided explicitly. + Unspecified = 0, + /// The Cloud Monitoring Basic tier, a free tier of service that provides basic + /// features, a moderate allotment of logs, and access to built-in metrics. + /// A number of features are not available in this tier. For more details, + /// see [the service tiers + /// documentation](). + Basic = 1, + /// The Cloud Monitoring Premium tier, a higher, more expensive tier of service + /// that provides access to all Cloud Monitoring features, lets you use Cloud + /// Monitoring with AWS accounts, and has a larger allotments for logs and + /// metrics. For more details, see [the service tiers + /// documentation](). + Premium = 2, +} +impl ServiceTier { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::Unspecified => "SERVICE_TIER_UNSPECIFIED", + Self::Basic => "SERVICE_TIER_BASIC", + Self::Premium => "SERVICE_TIER_PREMIUM", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "SERVICE_TIER_UNSPECIFIED" => Some(Self::Unspecified), + "SERVICE_TIER_BASIC" => Some(Self::Basic), + "SERVICE_TIER_PREMIUM" => Some(Self::Premium), + _ => None, + } + } +} +/// A single data point in a time series. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct Point { + /// The time interval to which the data point applies. For `GAUGE` metrics, + /// the start time is optional, but if it is supplied, it must equal the + /// end time. For `DELTA` metrics, the start + /// and end time should specify a non-zero interval, with subsequent points + /// specifying contiguous and non-overlapping intervals. For `CUMULATIVE` + /// metrics, the start and end time should specify a non-zero interval, with + /// subsequent points specifying the same start time and increasing end times, + /// until an event resets the cumulative value to zero and sets a new start + /// time for the following points. + #[prost(message, optional, tag = "1")] + pub interval: ::core::option::Option, + /// The value of the data point. + #[prost(message, optional, tag = "2")] + pub value: ::core::option::Option, +} +/// A collection of data points that describes the time-varying values +/// of a metric. A time series is identified by a combination of a +/// fully-specified monitored resource and a fully-specified metric. +/// This type is used for both listing and creating time series. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct TimeSeries { + /// The associated metric. A fully-specified metric used to identify the time + /// series. + #[prost(message, optional, tag = "1")] + pub metric: ::core::option::Option, + /// The associated monitored resource. Custom metrics can use only certain + /// monitored resource types in their time series data. For more information, + /// see [Monitored resources for custom + /// metrics](). + #[prost(message, optional, tag = "2")] + pub resource: ::core::option::Option, + /// Output only. The associated monitored resource metadata. When reading a + /// time series, this field will include metadata labels that are explicitly + /// named in the reduction. When creating a time series, this field is ignored. + #[prost(message, optional, tag = "7")] + pub metadata: ::core::option::Option, + /// The metric kind of the time series. When listing time series, this metric + /// kind might be different from the metric kind of the associated metric if + /// this time series is an alignment or reduction of other time series. + /// + /// When creating a time series, this field is optional. If present, it must be + /// the same as the metric kind of the associated metric. If the associated + /// metric's descriptor must be auto-created, then this field specifies the + /// metric kind of the new descriptor and must be either `GAUGE` (the default) + /// or `CUMULATIVE`. + #[prost(enumeration = "super::super::api::metric_descriptor::MetricKind", tag = "3")] + pub metric_kind: i32, + /// The value type of the time series. When listing time series, this value + /// type might be different from the value type of the associated metric if + /// this time series is an alignment or reduction of other time series. + /// + /// When creating a time series, this field is optional. If present, it must be + /// the same as the type of the data in the `points` field. + #[prost(enumeration = "super::super::api::metric_descriptor::ValueType", tag = "4")] + pub value_type: i32, + /// The data points of this time series. When listing time series, points are + /// returned in reverse time order. + /// + /// When creating a time series, this field must contain exactly one point and + /// the point's type must be the same as the value type of the associated + /// metric. If the associated metric's descriptor must be auto-created, then + /// the value type of the descriptor is determined by the point's type, which + /// must be `BOOL`, `INT64`, `DOUBLE`, or `DISTRIBUTION`. + #[prost(message, repeated, tag = "5")] + pub points: ::prost::alloc::vec::Vec, + /// The units in which the metric value is reported. It is only applicable + /// if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The `unit` + /// defines the representation of the stored metric values. + #[prost(string, tag = "8")] + pub unit: ::prost::alloc::string::String, +} +/// A descriptor for the labels and points in a time series. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct TimeSeriesDescriptor { + /// Descriptors for the labels. + #[prost(message, repeated, tag = "1")] + pub label_descriptors: ::prost::alloc::vec::Vec, + /// Descriptors for the point data value columns. + #[prost(message, repeated, tag = "5")] + pub point_descriptors: ::prost::alloc::vec::Vec< + time_series_descriptor::ValueDescriptor, + >, +} +/// Nested message and enum types in `TimeSeriesDescriptor`. +pub mod time_series_descriptor { + /// A descriptor for the value columns in a data point. + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct ValueDescriptor { + /// The value key. + #[prost(string, tag = "1")] + pub key: ::prost::alloc::string::String, + /// The value type. + #[prost( + enumeration = "super::super::super::api::metric_descriptor::ValueType", + tag = "2" + )] + pub value_type: i32, + /// The value stream kind. + #[prost( + enumeration = "super::super::super::api::metric_descriptor::MetricKind", + tag = "3" + )] + pub metric_kind: i32, + /// The unit in which `time_series` point values are reported. `unit` + /// follows the UCUM format for units as seen in + /// + /// `unit` is only valid if `value_type` is INTEGER, DOUBLE, DISTRIBUTION. + #[prost(string, tag = "4")] + pub unit: ::prost::alloc::string::String, + } +} +/// Represents the values of a time series associated with a +/// TimeSeriesDescriptor. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct TimeSeriesData { + /// The values of the labels in the time series identifier, given in the same + /// order as the `label_descriptors` field of the TimeSeriesDescriptor + /// associated with this object. Each value must have a value of the type + /// given in the corresponding entry of `label_descriptors`. + #[prost(message, repeated, tag = "1")] + pub label_values: ::prost::alloc::vec::Vec, + /// The points in the time series. + #[prost(message, repeated, tag = "2")] + pub point_data: ::prost::alloc::vec::Vec, +} +/// Nested message and enum types in `TimeSeriesData`. +pub mod time_series_data { + /// A point's value columns and time interval. Each point has one or more + /// point values corresponding to the entries in `point_descriptors` field in + /// the TimeSeriesDescriptor associated with this object. + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct PointData { + /// The values that make up the point. + #[prost(message, repeated, tag = "1")] + pub values: ::prost::alloc::vec::Vec, + /// The time interval associated with the point. + #[prost(message, optional, tag = "2")] + pub time_interval: ::core::option::Option, + } +} +/// A label value. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct LabelValue { + /// The label value can be a bool, int64, or string. + #[prost(oneof = "label_value::Value", tags = "1, 2, 3")] + pub value: ::core::option::Option, +} +/// Nested message and enum types in `LabelValue`. +pub mod label_value { + /// The label value can be a bool, int64, or string. + #[derive(Clone, PartialEq, ::prost::Oneof)] + pub enum Value { + /// A bool label value. + #[prost(bool, tag = "1")] + BoolValue(bool), + /// An int64 label value. + #[prost(int64, tag = "2")] + Int64Value(i64), + /// A string label value. + #[prost(string, tag = "3")] + StringValue(::prost::alloc::string::String), + } +} +/// An error associated with a query in the time series query language format. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct QueryError { + /// The location of the time series query language text that this error applies + /// to. + #[prost(message, optional, tag = "1")] + pub locator: ::core::option::Option, + /// The error message. + #[prost(string, tag = "2")] + pub message: ::prost::alloc::string::String, +} +/// A locator for text. Indicates a particular part of the text of a request or +/// of an object referenced in the request. +/// +/// For example, suppose the request field `text` contains: +/// +/// text: "The quick brown fox jumps over the lazy dog." +/// +/// Then the locator: +/// +/// source: "text" +/// start_position { +/// line: 1 +/// column: 17 +/// } +/// end_position { +/// line: 1 +/// column: 19 +/// } +/// +/// refers to the part of the text: "fox". +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct TextLocator { + /// The source of the text. The source may be a field in the request, in which + /// case its format is the format of the + /// google.rpc.BadRequest.FieldViolation.field field in + /// It may also be + /// be a source other than the request field (e.g. a macro definition + /// referenced in the text of the query), in which case this is the name of + /// the source (e.g. the macro name). + #[prost(string, tag = "1")] + pub source: ::prost::alloc::string::String, + /// The position of the first byte within the text. + #[prost(message, optional, tag = "2")] + pub start_position: ::core::option::Option, + /// The position of the last byte within the text. + #[prost(message, optional, tag = "3")] + pub end_position: ::core::option::Option, + /// If `source`, `start_position`, and `end_position` describe a call on + /// some object (e.g. a macro in the time series query language text) and a + /// location is to be designated in that object's text, `nested_locator` + /// identifies the location within that object. + #[prost(message, optional, boxed, tag = "4")] + pub nested_locator: ::core::option::Option<::prost::alloc::boxed::Box>, + /// When `nested_locator` is set, this field gives the reason for the nesting. + /// Usually, the reason is a macro invocation. In that case, the macro name + /// (including the leading '@') signals the location of the macro call + /// in the text and a macro argument name (including the leading '$') signals + /// the location of the macro argument inside the macro body that got + /// substituted away. + #[prost(string, tag = "5")] + pub nesting_reason: ::prost::alloc::string::String, +} +/// Nested message and enum types in `TextLocator`. +pub mod text_locator { + /// The position of a byte within the text. + #[derive(Clone, Copy, PartialEq, ::prost::Message)] + pub struct Position { + /// The line, starting with 1, where the byte is positioned. + #[prost(int32, tag = "1")] + pub line: i32, + /// The column within the line, starting with 1, where the byte is + /// positioned. This is a byte index even though the text is UTF-8. + #[prost(int32, tag = "2")] + pub column: i32, + } +} +/// The `ListMonitoredResourceDescriptors` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListMonitoredResourceDescriptorsRequest { + /// Required. The + /// [project]() on which + /// to execute the request. The format is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\] + #[prost(string, tag = "5")] + pub name: ::prost::alloc::string::String, + /// An optional [filter]() + /// describing the descriptors to be returned. The filter can reference the + /// descriptor's type and labels. For example, the following filter returns + /// only Google Compute Engine descriptors that have an `id` label: + /// + /// resource.type = starts_with("gce_") AND resource.label:id + #[prost(string, tag = "2")] + pub filter: ::prost::alloc::string::String, + /// A positive number that is the maximum number of results to return. + #[prost(int32, tag = "3")] + pub page_size: i32, + /// If this field is not empty then it must contain the `nextPageToken` value + /// returned by a previous call to this method. Using this field causes the + /// method to return additional results from the previous method call. + #[prost(string, tag = "4")] + pub page_token: ::prost::alloc::string::String, +} +/// The `ListMonitoredResourceDescriptors` response. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListMonitoredResourceDescriptorsResponse { + /// The monitored resource descriptors that are available to this project + /// and that match `filter`, if present. + #[prost(message, repeated, tag = "1")] + pub resource_descriptors: ::prost::alloc::vec::Vec< + super::super::api::MonitoredResourceDescriptor, + >, + /// If there are more results than have been returned, then this field is set + /// to a non-empty value. To see the additional results, + /// use that value as `page_token` in the next call to this method. + #[prost(string, tag = "2")] + pub next_page_token: ::prost::alloc::string::String, +} +/// The `GetMonitoredResourceDescriptor` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct GetMonitoredResourceDescriptorRequest { + /// Required. The monitored resource descriptor to get. The format is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\]/monitoredResourceDescriptors/\[RESOURCE_TYPE\] + /// + /// The `\[RESOURCE_TYPE\]` is a predefined type, such as + /// `cloudsql_database`. + #[prost(string, tag = "3")] + pub name: ::prost::alloc::string::String, +} +/// The `ListMetricDescriptors` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListMetricDescriptorsRequest { + /// Required. The + /// [project]() on which + /// to execute the request. The format is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\] + #[prost(string, tag = "5")] + pub name: ::prost::alloc::string::String, + /// If this field is empty, all custom and + /// system-defined metric descriptors are returned. + /// Otherwise, the [filter]() + /// specifies which metric descriptors are to be + /// returned. For example, the following filter matches all + /// [custom metrics](): + /// + /// metric.type = starts_with("custom.googleapis.com/") + #[prost(string, tag = "2")] + pub filter: ::prost::alloc::string::String, + /// A positive number that is the maximum number of results to return. The + /// default and maximum value is 10,000. If a page_size <= 0 or > 10,000 is + /// submitted, will instead return a maximum of 10,000 results. + #[prost(int32, tag = "3")] + pub page_size: i32, + /// If this field is not empty then it must contain the `nextPageToken` value + /// returned by a previous call to this method. Using this field causes the + /// method to return additional results from the previous method call. + #[prost(string, tag = "4")] + pub page_token: ::prost::alloc::string::String, +} +/// The `ListMetricDescriptors` response. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListMetricDescriptorsResponse { + /// The metric descriptors that are available to the project + /// and that match the value of `filter`, if present. + #[prost(message, repeated, tag = "1")] + pub metric_descriptors: ::prost::alloc::vec::Vec< + super::super::api::MetricDescriptor, + >, + /// If there are more results than have been returned, then this field is set + /// to a non-empty value. To see the additional results, + /// use that value as `page_token` in the next call to this method. + #[prost(string, tag = "2")] + pub next_page_token: ::prost::alloc::string::String, +} +/// The `GetMetricDescriptor` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct GetMetricDescriptorRequest { + /// Required. The metric descriptor on which to execute the request. The format + /// is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\]/metricDescriptors/\[METRIC_ID\] + /// + /// An example value of `\[METRIC_ID\]` is + /// `"compute.googleapis.com/instance/disk/read_bytes_count"`. + #[prost(string, tag = "3")] + pub name: ::prost::alloc::string::String, +} +/// The `CreateMetricDescriptor` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct CreateMetricDescriptorRequest { + /// Required. The + /// [project]() on which + /// to execute the request. The format is: + /// 4 + /// projects/\[PROJECT_ID_OR_NUMBER\] + #[prost(string, tag = "3")] + pub name: ::prost::alloc::string::String, + /// Required. The new [custom + /// metric]() descriptor. + #[prost(message, optional, tag = "2")] + pub metric_descriptor: ::core::option::Option, +} +/// The `DeleteMetricDescriptor` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct DeleteMetricDescriptorRequest { + /// Required. The metric descriptor on which to execute the request. The format + /// is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\]/metricDescriptors/\[METRIC_ID\] + /// + /// An example of `\[METRIC_ID\]` is: + /// `"custom.googleapis.com/my_test_metric"`. + #[prost(string, tag = "3")] + pub name: ::prost::alloc::string::String, +} +/// The `ListTimeSeries` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListTimeSeriesRequest { + /// Required. The + /// [project](), + /// organization or folder on which to execute the request. The format is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\] + /// organizations/\[ORGANIZATION_ID\] + /// folders/\[FOLDER_ID\] + #[prost(string, tag = "10")] + pub name: ::prost::alloc::string::String, + /// Required. A [monitoring + /// filter]() that specifies + /// which time series should be returned. The filter must specify a single + /// metric type, and can additionally specify metric labels and other + /// information. For example: + /// + /// metric.type = "compute.googleapis.com/instance/cpu/usage_time" AND + /// metric.labels.instance_name = "my-instance-name" + #[prost(string, tag = "2")] + pub filter: ::prost::alloc::string::String, + /// Required. The time interval for which results should be returned. Only time + /// series that contain data points in the specified interval are included in + /// the response. + #[prost(message, optional, tag = "4")] + pub interval: ::core::option::Option, + /// Specifies the alignment of data points in individual time series as + /// well as how to combine the retrieved time series across specified labels. + /// + /// By default (if no `aggregation` is explicitly specified), the raw time + /// series data is returned. + #[prost(message, optional, tag = "5")] + pub aggregation: ::core::option::Option, + /// Apply a second aggregation after `aggregation` is applied. May only be + /// specified if `aggregation` is specified. + #[prost(message, optional, tag = "11")] + pub secondary_aggregation: ::core::option::Option, + /// Unsupported: must be left blank. The points in each time series are + /// currently returned in reverse time order (most recent to oldest). + #[prost(string, tag = "6")] + pub order_by: ::prost::alloc::string::String, + /// Required. Specifies which information is returned about the time series. + #[prost(enumeration = "list_time_series_request::TimeSeriesView", tag = "7")] + pub view: i32, + /// A positive number that is the maximum number of results to return. If + /// `page_size` is empty or more than 100,000 results, the effective + /// `page_size` is 100,000 results. If `view` is set to `FULL`, this is the + /// maximum number of `Points` returned. If `view` is set to `HEADERS`, this is + /// the maximum number of `TimeSeries` returned. + #[prost(int32, tag = "8")] + pub page_size: i32, + /// If this field is not empty then it must contain the `nextPageToken` value + /// returned by a previous call to this method. Using this field causes the + /// method to return additional results from the previous method call. + #[prost(string, tag = "9")] + pub page_token: ::prost::alloc::string::String, +} +/// Nested message and enum types in `ListTimeSeriesRequest`. +pub mod list_time_series_request { + /// Controls which fields are returned by `ListTimeSeries*`. + #[derive( + Clone, + Copy, + Debug, + PartialEq, + Eq, + Hash, + PartialOrd, + Ord, + ::prost::Enumeration + )] + #[repr(i32)] + pub enum TimeSeriesView { + /// Returns the identity of the metric(s), the time series, + /// and the time series data. + Full = 0, + /// Returns the identity of the metric and the time series resource, + /// but not the time series data. + Headers = 1, + } + impl TimeSeriesView { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::Full => "FULL", + Self::Headers => "HEADERS", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "FULL" => Some(Self::Full), + "HEADERS" => Some(Self::Headers), + _ => None, + } + } + } +} +/// The `ListTimeSeries` response. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListTimeSeriesResponse { + /// One or more time series that match the filter included in the request. + #[prost(message, repeated, tag = "1")] + pub time_series: ::prost::alloc::vec::Vec, + /// If there are more results than have been returned, then this field is set + /// to a non-empty value. To see the additional results, + /// use that value as `page_token` in the next call to this method. + #[prost(string, tag = "2")] + pub next_page_token: ::prost::alloc::string::String, + /// Query execution errors that may have caused the time series data returned + /// to be incomplete. + #[prost(message, repeated, tag = "3")] + pub execution_errors: ::prost::alloc::vec::Vec, + /// The unit in which all `time_series` point values are reported. `unit` + /// follows the UCUM format for units as seen in + /// + /// If different `time_series` have different units (for example, because they + /// come from different metric types, or a unit is absent), then `unit` will be + /// "{not_a_unit}". + #[prost(string, tag = "5")] + pub unit: ::prost::alloc::string::String, +} +/// The `CreateTimeSeries` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct CreateTimeSeriesRequest { + /// Required. The + /// [project]() on which + /// to execute the request. The format is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\] + #[prost(string, tag = "3")] + pub name: ::prost::alloc::string::String, + /// Required. The new data to be added to a list of time series. + /// Adds at most one data point to each of several time series. The new data + /// point must be more recent than any other point in its time series. Each + /// `TimeSeries` value must fully specify a unique time series by supplying + /// all label values for the metric and the monitored resource. + /// + /// The maximum number of `TimeSeries` objects per `Create` request is 200. + #[prost(message, repeated, tag = "2")] + pub time_series: ::prost::alloc::vec::Vec, +} +/// DEPRECATED. Used to hold per-time-series error status. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct CreateTimeSeriesError { + /// DEPRECATED. Time series ID that resulted in the `status` error. + #[deprecated] + #[prost(message, optional, tag = "1")] + pub time_series: ::core::option::Option, + /// DEPRECATED. The status of the requested write operation for `time_series`. + #[deprecated] + #[prost(message, optional, tag = "2")] + pub status: ::core::option::Option, +} +/// Summary of the result of a failed request to write data to a time series. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct CreateTimeSeriesSummary { + /// The number of points in the request. + #[prost(int32, tag = "1")] + pub total_point_count: i32, + /// The number of points that were successfully written. + #[prost(int32, tag = "2")] + pub success_point_count: i32, + /// The number of points that failed to be written. Order is not guaranteed. + #[prost(message, repeated, tag = "3")] + pub errors: ::prost::alloc::vec::Vec, +} +/// Nested message and enum types in `CreateTimeSeriesSummary`. +pub mod create_time_series_summary { + /// Detailed information about an error category. + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct Error { + /// The status of the requested write operation. + #[prost(message, optional, tag = "1")] + pub status: ::core::option::Option, + /// The number of points that couldn't be written because of `status`. + #[prost(int32, tag = "2")] + pub point_count: i32, + } +} +/// The `QueryTimeSeries` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct QueryTimeSeriesRequest { + /// Required. The + /// [project]() on which + /// to execute the request. The format is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\] + #[prost(string, tag = "1")] + pub name: ::prost::alloc::string::String, + /// Required. The query in the [Monitoring Query + /// Language]() format. + /// The default time zone is in UTC. + #[prost(string, tag = "7")] + pub query: ::prost::alloc::string::String, + /// A positive number that is the maximum number of time_series_data to return. + #[prost(int32, tag = "9")] + pub page_size: i32, + /// If this field is not empty then it must contain the `nextPageToken` value + /// returned by a previous call to this method. Using this field causes the + /// method to return additional results from the previous method call. + #[prost(string, tag = "10")] + pub page_token: ::prost::alloc::string::String, +} +/// The `QueryTimeSeries` response. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct QueryTimeSeriesResponse { + /// The descriptor for the time series data. + #[prost(message, optional, tag = "8")] + pub time_series_descriptor: ::core::option::Option, + /// The time series data. + #[prost(message, repeated, tag = "9")] + pub time_series_data: ::prost::alloc::vec::Vec, + /// If there are more results than have been returned, then this field is set + /// to a non-empty value. To see the additional results, use that value as + /// `page_token` in the next call to this method. + #[prost(string, tag = "10")] + pub next_page_token: ::prost::alloc::string::String, + /// Query execution errors that may have caused the time series data returned + /// to be incomplete. The available data will be available in the + /// response. + #[prost(message, repeated, tag = "11")] + pub partial_errors: ::prost::alloc::vec::Vec, +} +/// This is an error detail intended to be used with INVALID_ARGUMENT errors. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct QueryErrorList { + /// Errors in parsing the time series query language text. The number of errors + /// in the response may be limited. + #[prost(message, repeated, tag = "1")] + pub errors: ::prost::alloc::vec::Vec, + /// A summary of all the errors. + #[prost(string, tag = "2")] + pub error_summary: ::prost::alloc::string::String, +} +/// Generated client implementations. +pub mod metric_service_client { + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value, + )] + use tonic::codegen::*; + use tonic::codegen::http::Uri; + /// Manages metric descriptors, monitored resource descriptors, and + /// time series data. + #[derive(Debug, Clone)] + pub struct MetricServiceClient { + inner: tonic::client::Grpc, + } + impl MetricServiceClient { + /// Attempt to create a new client by connecting to a given endpoint. + pub async fn connect(dst: D) -> Result + where + D: TryInto, + D::Error: Into, + { + let conn = tonic::transport::Endpoint::new(dst)?.connect().await?; + Ok(Self::new(conn)) + } + } + impl MetricServiceClient + where + T: tonic::client::GrpcService, + T::Error: Into, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, + { + pub fn new(inner: T) -> Self { + let inner = tonic::client::Grpc::new(inner); + Self { inner } + } + pub fn with_origin(inner: T, origin: Uri) -> Self { + let inner = tonic::client::Grpc::with_origin(inner, origin); + Self { inner } + } + pub fn with_interceptor( + inner: T, + interceptor: F, + ) -> MetricServiceClient> + where + F: tonic::service::Interceptor, + T::ResponseBody: Default, + T: tonic::codegen::Service< + http::Request, + Response = http::Response< + >::ResponseBody, + >, + >, + , + >>::Error: Into + std::marker::Send + std::marker::Sync, + { + MetricServiceClient::new(InterceptedService::new(inner, interceptor)) + } + /// Compress requests with the given encoding. + /// + /// This requires the server to support it otherwise it might respond with an + /// error. + #[must_use] + pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self { + self.inner = self.inner.send_compressed(encoding); + self + } + /// Enable decompressing responses. + #[must_use] + pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self { + self.inner = self.inner.accept_compressed(encoding); + self + } + /// Limits the maximum size of a decoded message. + /// + /// Default: `4MB` + #[must_use] + pub fn max_decoding_message_size(mut self, limit: usize) -> Self { + self.inner = self.inner.max_decoding_message_size(limit); + self + } + /// Limits the maximum size of an encoded message. + /// + /// Default: `usize::MAX` + #[must_use] + pub fn max_encoding_message_size(mut self, limit: usize) -> Self { + self.inner = self.inner.max_encoding_message_size(limit); + self + } + /// Lists monitored resource descriptors that match a filter. + pub async fn list_monitored_resource_descriptors( + &mut self, + request: impl tonic::IntoRequest< + super::ListMonitoredResourceDescriptorsRequest, + >, + ) -> std::result::Result< + tonic::Response, + tonic::Status, + > { + self.inner + .ready() + .await + .map_err(|e| { + tonic::Status::unknown( + format!("Service was not ready: {}", e.into()), + ) + })?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static( + "/google.monitoring.v3.MetricService/ListMonitoredResourceDescriptors", + ); + let mut req = request.into_request(); + req.extensions_mut() + .insert( + GrpcMethod::new( + "google.monitoring.v3.MetricService", + "ListMonitoredResourceDescriptors", + ), + ); + self.inner.unary(req, path, codec).await + } + /// Gets a single monitored resource descriptor. + pub async fn get_monitored_resource_descriptor( + &mut self, + request: impl tonic::IntoRequest< + super::GetMonitoredResourceDescriptorRequest, + >, + ) -> std::result::Result< + tonic::Response, + tonic::Status, + > { + self.inner + .ready() + .await + .map_err(|e| { + tonic::Status::unknown( + format!("Service was not ready: {}", e.into()), + ) + })?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static( + "/google.monitoring.v3.MetricService/GetMonitoredResourceDescriptor", + ); + let mut req = request.into_request(); + req.extensions_mut() + .insert( + GrpcMethod::new( + "google.monitoring.v3.MetricService", + "GetMonitoredResourceDescriptor", + ), + ); + self.inner.unary(req, path, codec).await + } + /// Lists metric descriptors that match a filter. + pub async fn list_metric_descriptors( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result< + tonic::Response, + tonic::Status, + > { + self.inner + .ready() + .await + .map_err(|e| { + tonic::Status::unknown( + format!("Service was not ready: {}", e.into()), + ) + })?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static( + "/google.monitoring.v3.MetricService/ListMetricDescriptors", + ); + let mut req = request.into_request(); + req.extensions_mut() + .insert( + GrpcMethod::new( + "google.monitoring.v3.MetricService", + "ListMetricDescriptors", + ), + ); + self.inner.unary(req, path, codec).await + } + /// Gets a single metric descriptor. + pub async fn get_metric_descriptor( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result< + tonic::Response, + tonic::Status, + > { + self.inner + .ready() + .await + .map_err(|e| { + tonic::Status::unknown( + format!("Service was not ready: {}", e.into()), + ) + })?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static( + "/google.monitoring.v3.MetricService/GetMetricDescriptor", + ); + let mut req = request.into_request(); + req.extensions_mut() + .insert( + GrpcMethod::new( + "google.monitoring.v3.MetricService", + "GetMetricDescriptor", + ), + ); + self.inner.unary(req, path, codec).await + } + /// Creates a new metric descriptor. + /// The creation is executed asynchronously. + /// User-created metric descriptors define + /// [custom metrics](https://cloud.google.com/monitoring/custom-metrics). + /// The metric descriptor is updated if it already exists, + /// except that metric labels are never removed. + pub async fn create_metric_descriptor( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result< + tonic::Response, + tonic::Status, + > { + self.inner + .ready() + .await + .map_err(|e| { + tonic::Status::unknown( + format!("Service was not ready: {}", e.into()), + ) + })?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static( + "/google.monitoring.v3.MetricService/CreateMetricDescriptor", + ); + let mut req = request.into_request(); + req.extensions_mut() + .insert( + GrpcMethod::new( + "google.monitoring.v3.MetricService", + "CreateMetricDescriptor", + ), + ); + self.inner.unary(req, path, codec).await + } + /// Deletes a metric descriptor. Only user-created + /// [custom metrics](https://cloud.google.com/monitoring/custom-metrics) can be + /// deleted. + pub async fn delete_metric_descriptor( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result, tonic::Status> { + self.inner + .ready() + .await + .map_err(|e| { + tonic::Status::unknown( + format!("Service was not ready: {}", e.into()), + ) + })?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static( + "/google.monitoring.v3.MetricService/DeleteMetricDescriptor", + ); + let mut req = request.into_request(); + req.extensions_mut() + .insert( + GrpcMethod::new( + "google.monitoring.v3.MetricService", + "DeleteMetricDescriptor", + ), + ); + self.inner.unary(req, path, codec).await + } + /// Lists time series that match a filter. + pub async fn list_time_series( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result< + tonic::Response, + tonic::Status, + > { + self.inner + .ready() + .await + .map_err(|e| { + tonic::Status::unknown( + format!("Service was not ready: {}", e.into()), + ) + })?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static( + "/google.monitoring.v3.MetricService/ListTimeSeries", + ); + let mut req = request.into_request(); + req.extensions_mut() + .insert( + GrpcMethod::new( + "google.monitoring.v3.MetricService", + "ListTimeSeries", + ), + ); + self.inner.unary(req, path, codec).await + } + /// Creates or adds data to one or more time series. + /// The response is empty if all time series in the request were written. + /// If any time series could not be written, a corresponding failure message is + /// included in the error response. + /// This method does not support + /// [resource locations constraint of an organization + /// policy](https://cloud.google.com/resource-manager/docs/organization-policy/defining-locations#setting_the_organization_policy). + pub async fn create_time_series( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result, tonic::Status> { + self.inner + .ready() + .await + .map_err(|e| { + tonic::Status::unknown( + format!("Service was not ready: {}", e.into()), + ) + })?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static( + "/google.monitoring.v3.MetricService/CreateTimeSeries", + ); + let mut req = request.into_request(); + req.extensions_mut() + .insert( + GrpcMethod::new( + "google.monitoring.v3.MetricService", + "CreateTimeSeries", + ), + ); + self.inner.unary(req, path, codec).await + } + /// Creates or adds data to one or more service time series. A service time + /// series is a time series for a metric from a Google Cloud service. The + /// response is empty if all time series in the request were written. If any + /// time series could not be written, a corresponding failure message is + /// included in the error response. This endpoint rejects writes to + /// user-defined metrics. + /// This method is only for use by Google Cloud services. Use + /// [projects.timeSeries.create][google.monitoring.v3.MetricService.CreateTimeSeries] + /// instead. + pub async fn create_service_time_series( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result, tonic::Status> { + self.inner + .ready() + .await + .map_err(|e| { + tonic::Status::unknown( + format!("Service was not ready: {}", e.into()), + ) + })?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static( + "/google.monitoring.v3.MetricService/CreateServiceTimeSeries", + ); + let mut req = request.into_request(); + req.extensions_mut() + .insert( + GrpcMethod::new( + "google.monitoring.v3.MetricService", + "CreateServiceTimeSeries", + ), + ); + self.inner.unary(req, path, codec).await + } + } +} diff --git a/googleapis/src/bytes/google.pubsub.v1.rs b/googleapis/src/bytes/google.pubsub.v1.rs index 0059f567..cd65e813 100644 --- a/googleapis/src/bytes/google.pubsub.v1.rs +++ b/googleapis/src/bytes/google.pubsub.v1.rs @@ -1,6 +1,5 @@ // This file is @generated by prost-build. /// A schema resource. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Schema { /// Required. Name of the schema. @@ -42,9 +41,9 @@ pub mod schema { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Type::Unspecified => "TYPE_UNSPECIFIED", - Type::ProtocolBuffer => "PROTOCOL_BUFFER", - Type::Avro => "AVRO", + Self::Unspecified => "TYPE_UNSPECIFIED", + Self::ProtocolBuffer => "PROTOCOL_BUFFER", + Self::Avro => "AVRO", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -59,7 +58,6 @@ pub mod schema { } } /// Request for the CreateSchema method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateSchemaRequest { /// Required. The name of the project in which to create the schema. @@ -82,7 +80,6 @@ pub struct CreateSchemaRequest { pub schema_id: ::prost::alloc::string::String, } /// Request for the GetSchema method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetSchemaRequest { /// Required. The name of the schema to get. @@ -95,7 +92,6 @@ pub struct GetSchemaRequest { pub view: i32, } /// Request for the `ListSchemas` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSchemasRequest { /// Required. The name of the project in which to list schemas. @@ -117,7 +113,6 @@ pub struct ListSchemasRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListSchemas` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSchemasResponse { /// The resulting schemas. @@ -129,7 +124,6 @@ pub struct ListSchemasResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for the `ListSchemaRevisions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSchemaRevisionsRequest { /// Required. The name of the schema to list revisions for. @@ -149,7 +143,6 @@ pub struct ListSchemaRevisionsRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListSchemaRevisions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSchemaRevisionsResponse { /// The revisions of the schema. @@ -161,7 +154,6 @@ pub struct ListSchemaRevisionsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for CommitSchema method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CommitSchemaRequest { /// Required. The name of the schema we are revising. @@ -173,7 +165,6 @@ pub struct CommitSchemaRequest { pub schema: ::core::option::Option, } /// Request for the `RollbackSchema` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RollbackSchemaRequest { /// Required. The schema being rolled back with revision id. @@ -187,7 +178,6 @@ pub struct RollbackSchemaRequest { pub revision_id: ::prost::alloc::string::String, } /// Request for the `DeleteSchemaRevision` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteSchemaRevisionRequest { /// Required. The name of the schema revision to be deleted, with a revision ID @@ -204,7 +194,6 @@ pub struct DeleteSchemaRevisionRequest { pub revision_id: ::prost::alloc::string::String, } /// Request for the `DeleteSchema` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteSchemaRequest { /// Required. Name of the schema to delete. @@ -213,7 +202,6 @@ pub struct DeleteSchemaRequest { pub name: ::prost::alloc::string::String, } /// Request for the `ValidateSchema` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ValidateSchemaRequest { /// Required. The name of the project in which to validate schemas. @@ -226,11 +214,9 @@ pub struct ValidateSchemaRequest { } /// Response for the `ValidateSchema` method. /// Empty for now. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ValidateSchemaResponse {} /// Request for the `ValidateMessage` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ValidateMessageRequest { /// Required. The name of the project in which to validate schemas. @@ -248,7 +234,6 @@ pub struct ValidateMessageRequest { } /// Nested message and enum types in `ValidateMessageRequest`. pub mod validate_message_request { - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum SchemaSpec { /// Name of the schema against which to validate. @@ -263,7 +248,6 @@ pub mod validate_message_request { } /// Response for the `ValidateMessage` method. /// Empty for now. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ValidateMessageResponse {} /// View of Schema object fields to be returned by GetSchema and ListSchemas. @@ -285,9 +269,9 @@ impl SchemaView { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - SchemaView::Unspecified => "SCHEMA_VIEW_UNSPECIFIED", - SchemaView::Basic => "BASIC", - SchemaView::Full => "FULL", + Self::Unspecified => "SCHEMA_VIEW_UNSPECIFIED", + Self::Basic => "BASIC", + Self::Full => "FULL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -319,9 +303,9 @@ impl Encoding { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Encoding::Unspecified => "ENCODING_UNSPECIFIED", - Encoding::Json => "JSON", - Encoding::Binary => "BINARY", + Self::Unspecified => "ENCODING_UNSPECIFIED", + Self::Json => "JSON", + Self::Binary => "BINARY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -336,7 +320,13 @@ impl Encoding { } /// Generated client implementations. pub mod schema_service_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// Service for doing schema-related operations. @@ -359,8 +349,8 @@ pub mod schema_service_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -378,7 +368,8 @@ pub mod schema_service_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { SchemaServiceClient::new(InterceptedService::new(inner, interceptor)) } @@ -418,9 +409,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/CreateSchema"); let mut req = request.into_request(); @@ -433,9 +425,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/GetSchema"); let mut req = request.into_request(); @@ -448,9 +441,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/ListSchemas"); let mut req = request.into_request(); @@ -463,9 +457,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/ListSchemaRevisions"); let mut req = request.into_request(); @@ -478,9 +473,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/CommitSchema"); let mut req = request.into_request(); @@ -493,9 +489,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/RollbackSchema"); let mut req = request.into_request(); @@ -508,9 +505,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/DeleteSchemaRevision"); let mut req = request.into_request(); @@ -523,9 +521,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/DeleteSchema"); let mut req = request.into_request(); @@ -538,9 +537,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/ValidateSchema"); let mut req = request.into_request(); @@ -553,9 +553,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/ValidateMessage"); let mut req = request.into_request(); @@ -566,7 +567,6 @@ pub mod schema_service_client { } } /// A policy constraining the storage of messages published to the topic. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MessageStoragePolicy { /// Optional. A list of IDs of Google Cloud regions where messages that are @@ -586,7 +586,6 @@ pub struct MessageStoragePolicy { pub enforce_in_transit: bool, } /// Settings for validating messages published against a schema. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct SchemaSettings { /// Required. The name of the schema that messages published should be @@ -610,7 +609,6 @@ pub struct SchemaSettings { pub last_revision_id: ::prost::alloc::string::String, } /// Settings for an ingestion data source on a topic. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct IngestionDataSourceSettings { /// Optional. Platform Logs settings. If unset, no Platform Logs will be @@ -624,7 +622,6 @@ pub struct IngestionDataSourceSettings { /// Nested message and enum types in `IngestionDataSourceSettings`. pub mod ingestion_data_source_settings { /// Ingestion settings for Amazon Kinesis Data Streams. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AwsKinesis { /// Output only. An output-only field that indicates the state of the Kinesis @@ -686,12 +683,12 @@ pub mod ingestion_data_source_settings { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Active => "ACTIVE", - State::KinesisPermissionDenied => "KINESIS_PERMISSION_DENIED", - State::PublishPermissionDenied => "PUBLISH_PERMISSION_DENIED", - State::StreamNotFound => "STREAM_NOT_FOUND", - State::ConsumerNotFound => "CONSUMER_NOT_FOUND", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Active => "ACTIVE", + Self::KinesisPermissionDenied => "KINESIS_PERMISSION_DENIED", + Self::PublishPermissionDenied => "PUBLISH_PERMISSION_DENIED", + Self::StreamNotFound => "STREAM_NOT_FOUND", + Self::ConsumerNotFound => "CONSUMER_NOT_FOUND", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -709,7 +706,6 @@ pub mod ingestion_data_source_settings { } } /// Ingestion settings for Cloud Storage. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CloudStorage { /// Output only. An output-only field that indicates the state of the Cloud @@ -739,7 +735,6 @@ pub mod ingestion_data_source_settings { /// Configuration for reading Cloud Storage data in text format. Each line of /// text as specified by the delimiter will be set to the `data` field of a /// Pub/Sub message. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TextFormat { /// Optional. When unset, '\n' is used. @@ -749,14 +744,12 @@ pub mod ingestion_data_source_settings { /// Configuration for reading Cloud Storage data in Avro binary format. The /// bytes of each object will be set to the `data` field of a Pub/Sub /// message. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AvroFormat {} /// Configuration for reading Cloud Storage data written via [Cloud Storage /// subscriptions](). The /// data and attributes fields of the originally exported Pub/Sub message /// will be restored when publishing. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct PubSubAvroFormat {} /// Possible states for ingestion from Cloud Storage. @@ -792,12 +785,12 @@ pub mod ingestion_data_source_settings { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Active => "ACTIVE", - State::CloudStoragePermissionDenied => "CLOUD_STORAGE_PERMISSION_DENIED", - State::PublishPermissionDenied => "PUBLISH_PERMISSION_DENIED", - State::BucketNotFound => "BUCKET_NOT_FOUND", - State::TooManyObjects => "TOO_MANY_OBJECTS", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Active => "ACTIVE", + Self::CloudStoragePermissionDenied => "CLOUD_STORAGE_PERMISSION_DENIED", + Self::PublishPermissionDenied => "PUBLISH_PERMISSION_DENIED", + Self::BucketNotFound => "BUCKET_NOT_FOUND", + Self::TooManyObjects => "TOO_MANY_OBJECTS", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -814,7 +807,6 @@ pub mod ingestion_data_source_settings { } } /// Defaults to text format. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum InputFormat { /// Optional. Data from Cloud Storage will be interpreted as text. @@ -831,7 +823,6 @@ pub mod ingestion_data_source_settings { } } /// Only one source type can have settings set. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Source { /// Optional. Amazon Kinesis Data Streams. @@ -843,7 +834,6 @@ pub mod ingestion_data_source_settings { } } /// Settings for Platform Logs produced by Pub/Sub. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct PlatformLogsSettings { /// Optional. The minimum severity level of Platform Logs that will be written. @@ -876,12 +866,12 @@ pub mod platform_logs_settings { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Severity::Unspecified => "SEVERITY_UNSPECIFIED", - Severity::Disabled => "DISABLED", - Severity::Debug => "DEBUG", - Severity::Info => "INFO", - Severity::Warning => "WARNING", - Severity::Error => "ERROR", + Self::Unspecified => "SEVERITY_UNSPECIFIED", + Self::Disabled => "DISABLED", + Self::Debug => "DEBUG", + Self::Info => "INFO", + Self::Warning => "WARNING", + Self::Error => "ERROR", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -899,7 +889,6 @@ pub mod platform_logs_settings { } } /// A topic resource. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Topic { /// Required. The name of the topic. It must have the format @@ -972,9 +961,9 @@ pub mod topic { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Active => "ACTIVE", - State::IngestionResourceError => "INGESTION_RESOURCE_ERROR", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Active => "ACTIVE", + Self::IngestionResourceError => "INGESTION_RESOURCE_ERROR", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -996,7 +985,6 @@ pub mod topic { /// more information. See \[quotas and limits\] /// () for more information about message /// limits. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PubsubMessage { /// Optional. The message data field. If this field is empty, the message must @@ -1031,7 +1019,6 @@ pub struct PubsubMessage { pub ordering_key: ::prost::alloc::string::String, } /// Request for the GetTopic method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetTopicRequest { /// Required. The name of the topic to get. @@ -1040,7 +1027,6 @@ pub struct GetTopicRequest { pub topic: ::prost::alloc::string::String, } /// Request for the UpdateTopic method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateTopicRequest { /// Required. The updated topic object. @@ -1055,7 +1041,6 @@ pub struct UpdateTopicRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Request for the Publish method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PublishRequest { /// Required. The messages in the request will be published on this topic. @@ -1067,7 +1052,6 @@ pub struct PublishRequest { pub messages: ::prost::alloc::vec::Vec, } /// Response for the `Publish` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PublishResponse { /// Optional. The server-assigned ID of each published message, in the same @@ -1077,7 +1061,6 @@ pub struct PublishResponse { pub message_ids: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Request for the `ListTopics` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTopicsRequest { /// Required. The name of the project in which to list topics. @@ -1094,7 +1077,6 @@ pub struct ListTopicsRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListTopics` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTopicsResponse { /// Optional. The resulting topics. @@ -1106,7 +1088,6 @@ pub struct ListTopicsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for the `ListTopicSubscriptions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTopicSubscriptionsRequest { /// Required. The name of the topic that subscriptions are attached to. @@ -1123,7 +1104,6 @@ pub struct ListTopicSubscriptionsRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListTopicSubscriptions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTopicSubscriptionsResponse { /// Optional. The names of subscriptions attached to the topic specified in the @@ -1137,7 +1117,6 @@ pub struct ListTopicSubscriptionsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for the `ListTopicSnapshots` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTopicSnapshotsRequest { /// Required. The name of the topic that snapshots are attached to. @@ -1154,7 +1133,6 @@ pub struct ListTopicSnapshotsRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListTopicSnapshots` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTopicSnapshotsResponse { /// Optional. The names of the snapshots that match the request. @@ -1167,7 +1145,6 @@ pub struct ListTopicSnapshotsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for the `DeleteTopic` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteTopicRequest { /// Required. Name of the topic to delete. @@ -1176,7 +1153,6 @@ pub struct DeleteTopicRequest { pub topic: ::prost::alloc::string::String, } /// Request for the DetachSubscription method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DetachSubscriptionRequest { /// Required. The subscription to detach. @@ -1186,13 +1162,11 @@ pub struct DetachSubscriptionRequest { } /// Response for the DetachSubscription method. /// Reserved for future use. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct DetachSubscriptionResponse {} /// A subscription resource. If none of `push_config`, `bigquery_config`, or /// `cloud_storage_config` is set, then the subscriber will pull and ack messages /// using API methods. At most one of these fields may be set. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Subscription { /// Required. The name of the subscription. It must have the format @@ -1344,7 +1318,6 @@ pub struct Subscription { pub mod subscription { /// Information about an associated Analytics Hub subscription /// (). - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AnalyticsHubSubscriptionInfo { /// Optional. The name of the associated Analytics Hub listing resource. @@ -1378,9 +1351,9 @@ pub mod subscription { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Active => "ACTIVE", - State::ResourceError => "RESOURCE_ERROR", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Active => "ACTIVE", + Self::ResourceError => "RESOURCE_ERROR", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1405,7 +1378,6 @@ pub mod subscription { /// Retry Policy is implemented on a best effort basis. At times, the delay /// between consecutive deliveries may not match the configuration. That is, /// delay can be more or less than configured backoff. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct RetryPolicy { /// Optional. The minimum delay between consecutive deliveries of a given @@ -1423,7 +1395,6 @@ pub struct RetryPolicy { /// /// If validation on any of the fields fails at subscription creation/updation, /// the create/update subscription request will fail. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeadLetterPolicy { /// Optional. The name of the topic to which dead letter messages should be @@ -1455,7 +1426,6 @@ pub struct DeadLetterPolicy { } /// A policy that specifies the conditions for resource expiration (i.e., /// automatic resource deletion). -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ExpirationPolicy { /// Optional. Specifies the "time-to-live" duration for an associated resource. @@ -1468,7 +1438,6 @@ pub struct ExpirationPolicy { pub ttl: ::core::option::Option<::prost_types::Duration>, } /// Configuration for a push delivery endpoint. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PushConfig { /// Optional. A URL locating the endpoint to which messages should be pushed. @@ -1515,7 +1484,6 @@ pub mod push_config { /// Contains information needed for generating an /// [OpenID Connect /// token](). - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct OidcToken { /// Optional. [Service account @@ -1538,11 +1506,9 @@ pub mod push_config { /// The payload to the push endpoint is in the form of the JSON representation /// of a PubsubMessage /// (). - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct PubsubWrapper {} /// Sets the `data` field as the HTTP body for delivery. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct NoWrapper { /// Optional. When true, writes the Pub/Sub message metadata to @@ -1556,7 +1522,6 @@ pub mod push_config { /// default to allow requests only from the Pub/Sub system, for example. /// This field is optional and should be set only by users interested in /// authenticated push. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum AuthenticationMethod { /// Optional. If specified, Pub/Sub will generate and attach an OIDC JWT @@ -1567,7 +1532,6 @@ pub mod push_config { } /// The format of the delivered message to the push endpoint is defined by /// the chosen wrapper. When unset, `PubsubWrapper` is used. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum Wrapper { /// Optional. When set, the payload to the push endpoint is in the form of @@ -1581,7 +1545,6 @@ pub mod push_config { } } /// Configuration for a BigQuery subscription. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BigQueryConfig { /// Optional. The name of the table to which to write data, of the form @@ -1657,12 +1620,12 @@ pub mod big_query_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Active => "ACTIVE", - State::PermissionDenied => "PERMISSION_DENIED", - State::NotFound => "NOT_FOUND", - State::SchemaMismatch => "SCHEMA_MISMATCH", - State::InTransitLocationRestriction => "IN_TRANSIT_LOCATION_RESTRICTION", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Active => "ACTIVE", + Self::PermissionDenied => "PERMISSION_DENIED", + Self::NotFound => "NOT_FOUND", + Self::SchemaMismatch => "SCHEMA_MISMATCH", + Self::InTransitLocationRestriction => "IN_TRANSIT_LOCATION_RESTRICTION", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1680,7 +1643,6 @@ pub mod big_query_config { } } /// Configuration for a Cloud Storage subscription. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CloudStorageConfig { /// Required. User-provided name for the Cloud Storage bucket. @@ -1738,12 +1700,10 @@ pub mod cloud_storage_config { /// Configuration for writing message data in text format. /// Message payloads will be written to files as raw text, separated by a /// newline. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct TextConfig {} /// Configuration for writing message data in Avro format. /// Message payloads and metadata will be written to files as an Avro binary. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AvroConfig { /// Optional. When true, write the subscription name, message_id, @@ -1786,12 +1746,12 @@ pub mod cloud_storage_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Active => "ACTIVE", - State::PermissionDenied => "PERMISSION_DENIED", - State::NotFound => "NOT_FOUND", - State::InTransitLocationRestriction => "IN_TRANSIT_LOCATION_RESTRICTION", - State::SchemaMismatch => "SCHEMA_MISMATCH", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Active => "ACTIVE", + Self::PermissionDenied => "PERMISSION_DENIED", + Self::NotFound => "NOT_FOUND", + Self::InTransitLocationRestriction => "IN_TRANSIT_LOCATION_RESTRICTION", + Self::SchemaMismatch => "SCHEMA_MISMATCH", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1808,7 +1768,6 @@ pub mod cloud_storage_config { } } /// Defaults to text format. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum OutputFormat { /// Optional. If set, message data will be written to Cloud Storage in text @@ -1822,7 +1781,6 @@ pub mod cloud_storage_config { } } /// A message and its corresponding acknowledgment ID. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReceivedMessage { /// Optional. This ID can be used to acknowledge the received message. @@ -1851,7 +1809,6 @@ pub struct ReceivedMessage { pub delivery_attempt: i32, } /// Request for the GetSubscription method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetSubscriptionRequest { /// Required. The name of the subscription to get. @@ -1860,7 +1817,6 @@ pub struct GetSubscriptionRequest { pub subscription: ::prost::alloc::string::String, } /// Request for the UpdateSubscription method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateSubscriptionRequest { /// Required. The updated subscription object. @@ -1872,7 +1828,6 @@ pub struct UpdateSubscriptionRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Request for the `ListSubscriptions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSubscriptionsRequest { /// Required. The name of the project in which to list subscriptions. @@ -1889,7 +1844,6 @@ pub struct ListSubscriptionsRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListSubscriptions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSubscriptionsResponse { /// Optional. The subscriptions that match the request. @@ -1902,7 +1856,6 @@ pub struct ListSubscriptionsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for the DeleteSubscription method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteSubscriptionRequest { /// Required. The subscription to delete. @@ -1911,7 +1864,6 @@ pub struct DeleteSubscriptionRequest { pub subscription: ::prost::alloc::string::String, } /// Request for the ModifyPushConfig method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ModifyPushConfigRequest { /// Required. The name of the subscription. @@ -1928,7 +1880,6 @@ pub struct ModifyPushConfigRequest { pub push_config: ::core::option::Option, } /// Request for the `Pull` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PullRequest { /// Required. The subscription from which messages should be pulled. @@ -1952,7 +1903,6 @@ pub struct PullRequest { pub max_messages: i32, } /// Response for the `Pull` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PullResponse { /// Optional. Received Pub/Sub messages. The list will be empty if there are no @@ -1964,7 +1914,6 @@ pub struct PullResponse { pub received_messages: ::prost::alloc::vec::Vec, } /// Request for the ModifyAckDeadline method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ModifyAckDeadlineRequest { /// Required. The name of the subscription. @@ -1987,7 +1936,6 @@ pub struct ModifyAckDeadlineRequest { pub ack_deadline_seconds: i32, } /// Request for the Acknowledge method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AcknowledgeRequest { /// Required. The subscription whose message is being acknowledged. @@ -2003,7 +1951,6 @@ pub struct AcknowledgeRequest { /// Request for the `StreamingPull` streaming RPC method. This request is used to /// establish the initial stream as well as to stream acknowledgements and ack /// deadline modifications from the client to the server. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct StreamingPullRequest { /// Required. The subscription for which to initialize the new stream. This @@ -2079,7 +2026,6 @@ pub struct StreamingPullRequest { } /// Response for the `StreamingPull` method. This response is used to stream /// messages from the server to the client. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct StreamingPullResponse { /// Optional. Received Pub/Sub messages. This will not be empty. @@ -2102,7 +2048,6 @@ pub struct StreamingPullResponse { pub mod streaming_pull_response { /// Acknowledgement IDs sent in one or more previous requests to acknowledge a /// previously received message. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AcknowledgeConfirmation { /// Optional. Successfully processed acknowledgement IDs. @@ -2122,7 +2067,6 @@ pub mod streaming_pull_response { } /// Acknowledgement IDs sent in one or more previous requests to modify the /// deadline for a specific message. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ModifyAckDeadlineConfirmation { /// Optional. Successfully processed acknowledgement IDs. @@ -2138,7 +2082,6 @@ pub mod streaming_pull_response { pub temporary_failed_ack_ids: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Subscription properties sent as part of the response. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct SubscriptionProperties { /// Optional. True iff exactly once delivery is enabled for this @@ -2151,7 +2094,6 @@ pub mod streaming_pull_response { } } /// Request for the `CreateSnapshot` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateSnapshotRequest { /// Required. User-provided name for this snapshot. If the name is not provided @@ -2179,7 +2121,6 @@ pub struct CreateSnapshotRequest { pub labels: ::std::collections::HashMap<::prost::alloc::string::String, ::prost::alloc::string::String>, } /// Request for the UpdateSnapshot method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateSnapshotRequest { /// Required. The updated snapshot object. @@ -2195,7 +2136,6 @@ pub struct UpdateSnapshotRequest { /// operations, which allow you to manage message acknowledgments in bulk. That /// is, you can set the acknowledgment state of messages in an existing /// subscription to the state captured by a snapshot. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Snapshot { /// Optional. The name of the snapshot. @@ -2223,7 +2163,6 @@ pub struct Snapshot { pub labels: ::std::collections::HashMap<::prost::alloc::string::String, ::prost::alloc::string::String>, } /// Request for the GetSnapshot method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetSnapshotRequest { /// Required. The name of the snapshot to get. @@ -2232,7 +2171,6 @@ pub struct GetSnapshotRequest { pub snapshot: ::prost::alloc::string::String, } /// Request for the `ListSnapshots` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSnapshotsRequest { /// Required. The name of the project in which to list snapshots. @@ -2249,7 +2187,6 @@ pub struct ListSnapshotsRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListSnapshots` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSnapshotsResponse { /// Optional. The resulting snapshots. @@ -2262,7 +2199,6 @@ pub struct ListSnapshotsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for the `DeleteSnapshot` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteSnapshotRequest { /// Required. The name of the snapshot to delete. @@ -2271,7 +2207,6 @@ pub struct DeleteSnapshotRequest { pub snapshot: ::prost::alloc::string::String, } /// Request for the `Seek` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct SeekRequest { /// Required. The subscription to affect. @@ -2282,7 +2217,6 @@ pub struct SeekRequest { } /// Nested message and enum types in `SeekRequest`. pub mod seek_request { - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Target { /// Optional. The time to seek to. @@ -2306,12 +2240,17 @@ pub mod seek_request { } } /// Response for the `Seek` method (this response is empty). -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct SeekResponse {} /// Generated client implementations. pub mod publisher_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// The service that an application uses to manipulate topics, and to send @@ -2335,8 +2274,8 @@ pub mod publisher_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -2354,7 +2293,8 @@ pub mod publisher_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { PublisherClient::new(InterceptedService::new(inner, interceptor)) } @@ -2395,9 +2335,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/CreateTopic"); let mut req = request.into_request(); @@ -2411,9 +2352,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/UpdateTopic"); let mut req = request.into_request(); @@ -2427,9 +2369,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/Publish"); let mut req = request.into_request(); @@ -2442,9 +2385,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/GetTopic"); let mut req = request.into_request(); @@ -2457,9 +2401,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/ListTopics"); let mut req = request.into_request(); @@ -2472,9 +2417,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/ListTopicSubscriptions"); let mut req = request.into_request(); @@ -2491,9 +2437,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/ListTopicSnapshots"); let mut req = request.into_request(); @@ -2510,9 +2457,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/DeleteTopic"); let mut req = request.into_request(); @@ -2528,9 +2476,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/DetachSubscription"); let mut req = request.into_request(); @@ -2542,7 +2491,13 @@ pub mod publisher_client { } /// Generated client implementations. pub mod subscriber_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// The service that an application uses to manipulate subscriptions and to @@ -2567,8 +2522,8 @@ pub mod subscriber_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -2586,7 +2541,8 @@ pub mod subscriber_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { SubscriberClient::new(InterceptedService::new(inner, interceptor)) } @@ -2636,9 +2592,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/CreateSubscription"); let mut req = request.into_request(); @@ -2651,9 +2608,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/GetSubscription"); let mut req = request.into_request(); @@ -2668,9 +2626,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/UpdateSubscription"); let mut req = request.into_request(); @@ -2683,9 +2642,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/ListSubscriptions"); let mut req = request.into_request(); @@ -2702,9 +2662,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/DeleteSubscription"); let mut req = request.into_request(); @@ -2721,9 +2682,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/ModifyAckDeadline"); let mut req = request.into_request(); @@ -2742,9 +2704,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/Acknowledge"); let mut req = request.into_request(); @@ -2757,9 +2720,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/Pull"); let mut req = request.into_request(); @@ -2779,9 +2743,10 @@ pub mod subscriber_client { request: impl tonic::IntoStreamingRequest, ) -> std::result::Result>, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/StreamingPull"); let mut req = request.into_streaming_request(); @@ -2799,9 +2764,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/ModifyPushConfig"); let mut req = request.into_request(); @@ -2818,9 +2784,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/GetSnapshot"); let mut req = request.into_request(); @@ -2837,9 +2804,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/ListSnapshots"); let mut req = request.into_request(); @@ -2867,9 +2835,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/CreateSnapshot"); let mut req = request.into_request(); @@ -2887,9 +2856,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/UpdateSnapshot"); let mut req = request.into_request(); @@ -2910,9 +2880,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/DeleteSnapshot"); let mut req = request.into_request(); @@ -2931,9 +2902,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/Seek"); let mut req = request.into_request(); diff --git a/googleapis/src/bytes/google.r#type.rs b/googleapis/src/bytes/google.r#type.rs index 9eb064a3..b439eebc 100644 --- a/googleapis/src/bytes/google.r#type.rs +++ b/googleapis/src/bytes/google.r#type.rs @@ -30,7 +30,6 @@ /// The exact variables and functions that may be referenced within an expression /// are determined by the service that evaluates it. See the service /// documentation for additional information. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Expr { /// Textual representation of an expression in Common Expression Language @@ -64,7 +63,6 @@ pub struct Expr { /// /// Related types are [google.type.TimeOfDay][google.type.TimeOfDay] and /// `google.protobuf.Timestamp`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct Date { /// Year of the date. Must be from 1 to 9999, or 0 to specify a date without diff --git a/googleapis/src/bytes/google.rpc.rs b/googleapis/src/bytes/google.rpc.rs index 3c6f5f40..fe27d475 100644 --- a/googleapis/src/bytes/google.rpc.rs +++ b/googleapis/src/bytes/google.rpc.rs @@ -6,7 +6,6 @@ /// /// You can find out more about this error model and how to work with it in the /// [API Design Guide](). -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Status { /// The status code, which should be an enum value of diff --git a/googleapis/src/bytes/google.spanner.admin.database.v1.rs b/googleapis/src/bytes/google.spanner.admin.database.v1.rs index d0131abc..b74ebaf9 100644 --- a/googleapis/src/bytes/google.spanner.admin.database.v1.rs +++ b/googleapis/src/bytes/google.spanner.admin.database.v1.rs @@ -1,7 +1,6 @@ // This file is @generated by prost-build. /// Encapsulates progress related information for a Cloud Spanner long /// running operation. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct OperationProgress { /// Percent completion of the operation. @@ -17,7 +16,6 @@ pub struct OperationProgress { pub end_time: ::core::option::Option<::prost_types::Timestamp>, } /// Encryption configuration for a Cloud Spanner database. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct EncryptionConfig { /// The Cloud KMS key to be used for encrypting and decrypting @@ -44,7 +42,6 @@ pub struct EncryptionConfig { pub kms_key_names: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Encryption information for a Cloud Spanner database or backup. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct EncryptionInfo { /// Output only. The type of encryption. @@ -96,9 +93,9 @@ pub mod encryption_info { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Type::Unspecified => "TYPE_UNSPECIFIED", - Type::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", - Type::CustomerManagedEncryption => "CUSTOMER_MANAGED_ENCRYPTION", + Self::Unspecified => "TYPE_UNSPECIFIED", + Self::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", + Self::CustomerManagedEncryption => "CUSTOMER_MANAGED_ENCRYPTION", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -131,9 +128,9 @@ impl DatabaseDialect { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - DatabaseDialect::Unspecified => "DATABASE_DIALECT_UNSPECIFIED", - DatabaseDialect::GoogleStandardSql => "GOOGLE_STANDARD_SQL", - DatabaseDialect::Postgresql => "POSTGRESQL", + Self::Unspecified => "DATABASE_DIALECT_UNSPECIFIED", + Self::GoogleStandardSql => "GOOGLE_STANDARD_SQL", + Self::Postgresql => "POSTGRESQL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -147,7 +144,6 @@ impl DatabaseDialect { } } /// A backup of a Cloud Spanner database. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Backup { /// Required for the @@ -317,9 +313,9 @@ pub mod backup { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Creating => "CREATING", - State::Ready => "READY", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Creating => "CREATING", + Self::Ready => "READY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -335,7 +331,6 @@ pub mod backup { } /// The request for /// [CreateBackup][google.spanner.admin.database.v1.DatabaseAdmin.CreateBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateBackupRequest { /// Required. The name of the instance in which the backup will be @@ -364,7 +359,6 @@ pub struct CreateBackupRequest { } /// Metadata type for the operation returned by /// [CreateBackup][google.spanner.admin.database.v1.DatabaseAdmin.CreateBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateBackupMetadata { /// The name of the backup being created. @@ -395,7 +389,6 @@ pub struct CreateBackupMetadata { } /// The request for /// [CopyBackup][google.spanner.admin.database.v1.DatabaseAdmin.CopyBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CopyBackupRequest { /// Required. The name of the destination instance that will contain the backup @@ -432,7 +425,6 @@ pub struct CopyBackupRequest { } /// Metadata type for the operation returned by /// [CopyBackup][google.spanner.admin.database.v1.DatabaseAdmin.CopyBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CopyBackupMetadata { /// The name of the backup being created through the copy operation. @@ -467,7 +459,6 @@ pub struct CopyBackupMetadata { } /// The request for /// [UpdateBackup][google.spanner.admin.database.v1.DatabaseAdmin.UpdateBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateBackupRequest { /// Required. The backup to update. `backup.name`, and the fields to be updated @@ -486,7 +477,6 @@ pub struct UpdateBackupRequest { } /// The request for /// [GetBackup][google.spanner.admin.database.v1.DatabaseAdmin.GetBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetBackupRequest { /// Required. Name of the backup. @@ -497,7 +487,6 @@ pub struct GetBackupRequest { } /// The request for /// [DeleteBackup][google.spanner.admin.database.v1.DatabaseAdmin.DeleteBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteBackupRequest { /// Required. Name of the backup to delete. @@ -508,7 +497,6 @@ pub struct DeleteBackupRequest { } /// The request for /// [ListBackups][google.spanner.admin.database.v1.DatabaseAdmin.ListBackups]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBackupsRequest { /// Required. The instance to list backups from. Values are of the @@ -571,7 +559,6 @@ pub struct ListBackupsRequest { } /// The response for /// [ListBackups][google.spanner.admin.database.v1.DatabaseAdmin.ListBackups]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBackupsResponse { /// The list of matching backups. Backups returned are ordered by `create_time` @@ -586,7 +573,6 @@ pub struct ListBackupsResponse { } /// The request for /// [ListBackupOperations][google.spanner.admin.database.v1.DatabaseAdmin.ListBackupOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBackupOperationsRequest { /// Required. The instance of the backup operations. Values are of @@ -679,7 +665,6 @@ pub struct ListBackupOperationsRequest { } /// The response for /// [ListBackupOperations][google.spanner.admin.database.v1.DatabaseAdmin.ListBackupOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBackupOperationsResponse { /// The list of matching backup [long-running @@ -702,7 +687,6 @@ pub struct ListBackupOperationsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Information about a backup. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BackupInfo { /// Name of the backup. @@ -725,7 +709,6 @@ pub struct BackupInfo { pub source_database: ::prost::alloc::string::String, } /// Encryption configuration for the backup to create. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateBackupEncryptionConfig { /// Required. The encryption type of the backup. @@ -794,12 +777,10 @@ pub mod create_backup_encryption_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - EncryptionType::Unspecified => "ENCRYPTION_TYPE_UNSPECIFIED", - EncryptionType::UseDatabaseEncryption => "USE_DATABASE_ENCRYPTION", - EncryptionType::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", - EncryptionType::CustomerManagedEncryption => { - "CUSTOMER_MANAGED_ENCRYPTION" - } + Self::Unspecified => "ENCRYPTION_TYPE_UNSPECIFIED", + Self::UseDatabaseEncryption => "USE_DATABASE_ENCRYPTION", + Self::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", + Self::CustomerManagedEncryption => "CUSTOMER_MANAGED_ENCRYPTION", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -815,7 +796,6 @@ pub mod create_backup_encryption_config { } } /// Encryption configuration for the copied backup. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CopyBackupEncryptionConfig { /// Required. The encryption type of the backup. @@ -886,14 +866,12 @@ pub mod copy_backup_encryption_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - EncryptionType::Unspecified => "ENCRYPTION_TYPE_UNSPECIFIED", - EncryptionType::UseConfigDefaultOrBackupEncryption => { + Self::Unspecified => "ENCRYPTION_TYPE_UNSPECIFIED", + Self::UseConfigDefaultOrBackupEncryption => { "USE_CONFIG_DEFAULT_OR_BACKUP_ENCRYPTION" } - EncryptionType::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", - EncryptionType::CustomerManagedEncryption => { - "CUSTOMER_MANAGED_ENCRYPTION" - } + Self::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", + Self::CustomerManagedEncryption => "CUSTOMER_MANAGED_ENCRYPTION", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -913,7 +891,6 @@ pub mod copy_backup_encryption_config { /// The specification for full backups. /// A full backup stores the entire contents of the database at a given /// version time. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct FullBackupSpec {} /// The specification for incremental backup chains. @@ -922,11 +899,9 @@ pub struct FullBackupSpec {} /// incremental backup chain consists of a full backup and zero or more /// successive incremental backups. The first backup created for an /// incremental backup chain is always a full backup. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct IncrementalBackupSpec {} /// Defines specifications of the backup schedule. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BackupScheduleSpec { /// Required. @@ -936,7 +911,6 @@ pub struct BackupScheduleSpec { /// Nested message and enum types in `BackupScheduleSpec`. pub mod backup_schedule_spec { /// Required. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum ScheduleSpec { /// Cron style schedule specification. @@ -947,7 +921,6 @@ pub mod backup_schedule_spec { /// BackupSchedule expresses the automated backup creation specification for a /// Spanner database. /// Next ID: 10 -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BackupSchedule { /// Identifier. Output only for the @@ -989,7 +962,6 @@ pub struct BackupSchedule { pub mod backup_schedule { /// Required. Backup type spec determines the type of backup that is created by /// the backup schedule. Currently, only full backups are supported. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum BackupTypeSpec { /// The schedule creates only full backups. @@ -1002,7 +974,6 @@ pub mod backup_schedule { } /// CrontabSpec can be used to specify the version time and frequency at /// which the backup should be created. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CrontabSpec { /// Required. Textual representation of the crontab. User can customize the @@ -1035,7 +1006,6 @@ pub struct CrontabSpec { } /// The request for /// [CreateBackupSchedule][google.spanner.admin.database.v1.DatabaseAdmin.CreateBackupSchedule]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateBackupScheduleRequest { /// Required. The name of the database that this backup schedule applies to. @@ -1052,7 +1022,6 @@ pub struct CreateBackupScheduleRequest { } /// The request for /// [GetBackupSchedule][google.spanner.admin.database.v1.DatabaseAdmin.GetBackupSchedule]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetBackupScheduleRequest { /// Required. The name of the schedule to retrieve. @@ -1063,7 +1032,6 @@ pub struct GetBackupScheduleRequest { } /// The request for /// [DeleteBackupSchedule][google.spanner.admin.database.v1.DatabaseAdmin.DeleteBackupSchedule]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteBackupScheduleRequest { /// Required. The name of the schedule to delete. @@ -1074,7 +1042,6 @@ pub struct DeleteBackupScheduleRequest { } /// The request for /// [ListBackupSchedules][google.spanner.admin.database.v1.DatabaseAdmin.ListBackupSchedules]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBackupSchedulesRequest { /// Required. Database is the parent resource whose backup schedules should be @@ -1096,7 +1063,6 @@ pub struct ListBackupSchedulesRequest { } /// The response for /// [ListBackupSchedules][google.spanner.admin.database.v1.DatabaseAdmin.ListBackupSchedules]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBackupSchedulesResponse { /// The list of backup schedules for a database. @@ -1110,7 +1076,6 @@ pub struct ListBackupSchedulesResponse { } /// The request for /// [UpdateBackupScheduleRequest][google.spanner.admin.database.v1.DatabaseAdmin.UpdateBackupSchedule]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateBackupScheduleRequest { /// Required. The backup schedule to update. `backup_schedule.name`, and the @@ -1127,7 +1092,6 @@ pub struct UpdateBackupScheduleRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Information about the database restore. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RestoreInfo { /// The type of the restore source. @@ -1140,7 +1104,6 @@ pub struct RestoreInfo { /// Nested message and enum types in `RestoreInfo`. pub mod restore_info { /// Information about the source used to restore the database. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum SourceInfo { /// Information about the backup used to restore the database. The backup @@ -1150,7 +1113,6 @@ pub mod restore_info { } } /// A Cloud Spanner database. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Database { /// Required. The name of the database. Values are of the form @@ -1264,10 +1226,10 @@ pub mod database { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Creating => "CREATING", - State::Ready => "READY", - State::ReadyOptimizing => "READY_OPTIMIZING", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Creating => "CREATING", + Self::Ready => "READY", + Self::ReadyOptimizing => "READY_OPTIMIZING", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1284,7 +1246,6 @@ pub mod database { } /// The request for /// [ListDatabases][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabases]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDatabasesRequest { /// Required. The instance whose databases should be listed. @@ -1304,7 +1265,6 @@ pub struct ListDatabasesRequest { } /// The response for /// [ListDatabases][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabases]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDatabasesResponse { /// Databases that matched the request. @@ -1318,7 +1278,6 @@ pub struct ListDatabasesResponse { } /// The request for /// [CreateDatabase][google.spanner.admin.database.v1.DatabaseAdmin.CreateDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateDatabaseRequest { /// Required. The name of the instance that will serve the new database. @@ -1366,7 +1325,6 @@ pub struct CreateDatabaseRequest { } /// Metadata type for the operation returned by /// [CreateDatabase][google.spanner.admin.database.v1.DatabaseAdmin.CreateDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateDatabaseMetadata { /// The database being created. @@ -1375,7 +1333,6 @@ pub struct CreateDatabaseMetadata { } /// The request for /// [GetDatabase][google.spanner.admin.database.v1.DatabaseAdmin.GetDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetDatabaseRequest { /// Required. The name of the requested database. Values are of the form @@ -1385,7 +1342,6 @@ pub struct GetDatabaseRequest { } /// The request for /// [UpdateDatabase][google.spanner.admin.database.v1.DatabaseAdmin.UpdateDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateDatabaseRequest { /// Required. The database to update. @@ -1400,7 +1356,6 @@ pub struct UpdateDatabaseRequest { } /// Metadata type for the operation returned by /// [UpdateDatabase][google.spanner.admin.database.v1.DatabaseAdmin.UpdateDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateDatabaseMetadata { /// The request for @@ -1433,7 +1388,6 @@ pub struct UpdateDatabaseMetadata { /// progress. See the /// [operation_id][google.spanner.admin.database.v1.UpdateDatabaseDdlRequest.operation_id] /// field for more details. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateDatabaseDdlRequest { /// Required. The database to update. @@ -1485,7 +1439,6 @@ pub struct UpdateDatabaseDdlRequest { /// Action information extracted from a DDL statement. This proto is used to /// display the brief info of the DDL statement for the operation /// [UpdateDatabaseDdl][google.spanner.admin.database.v1.DatabaseAdmin.UpdateDatabaseDdl]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DdlStatementActionInfo { /// The action for the DDL statement, e.g. CREATE, ALTER, DROP, GRANT, etc. @@ -1507,7 +1460,6 @@ pub struct DdlStatementActionInfo { } /// Metadata type for the operation returned by /// [UpdateDatabaseDdl][google.spanner.admin.database.v1.DatabaseAdmin.UpdateDatabaseDdl]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateDatabaseDdlMetadata { /// The database being modified. @@ -1543,7 +1495,6 @@ pub struct UpdateDatabaseDdlMetadata { } /// The request for /// [DropDatabase][google.spanner.admin.database.v1.DatabaseAdmin.DropDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DropDatabaseRequest { /// Required. The database to be dropped. @@ -1552,7 +1503,6 @@ pub struct DropDatabaseRequest { } /// The request for /// [GetDatabaseDdl][google.spanner.admin.database.v1.DatabaseAdmin.GetDatabaseDdl]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetDatabaseDdlRequest { /// Required. The database whose schema we wish to get. @@ -1563,7 +1513,6 @@ pub struct GetDatabaseDdlRequest { } /// The response for /// [GetDatabaseDdl][google.spanner.admin.database.v1.DatabaseAdmin.GetDatabaseDdl]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetDatabaseDdlResponse { /// A list of formatted DDL statements defining the schema of the database @@ -1580,7 +1529,6 @@ pub struct GetDatabaseDdlResponse { } /// The request for /// [ListDatabaseOperations][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabaseOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDatabaseOperationsRequest { /// Required. The instance of the database operations. @@ -1648,7 +1596,6 @@ pub struct ListDatabaseOperationsRequest { } /// The response for /// [ListDatabaseOperations][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabaseOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDatabaseOperationsResponse { /// The list of matching database [long-running @@ -1668,7 +1615,6 @@ pub struct ListDatabaseOperationsResponse { } /// The request for /// [RestoreDatabase][google.spanner.admin.database.v1.DatabaseAdmin.RestoreDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RestoreDatabaseRequest { /// Required. The name of the instance in which to create the @@ -1699,7 +1645,6 @@ pub struct RestoreDatabaseRequest { /// Nested message and enum types in `RestoreDatabaseRequest`. pub mod restore_database_request { /// Required. The source from which to restore. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Source { /// Name of the backup from which to restore. Values are of the form @@ -1709,7 +1654,6 @@ pub mod restore_database_request { } } /// Encryption configuration for the restored database. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RestoreDatabaseEncryptionConfig { /// Required. The encryption type of the restored database. @@ -1778,14 +1722,12 @@ pub mod restore_database_encryption_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - EncryptionType::Unspecified => "ENCRYPTION_TYPE_UNSPECIFIED", - EncryptionType::UseConfigDefaultOrBackupEncryption => { + Self::Unspecified => "ENCRYPTION_TYPE_UNSPECIFIED", + Self::UseConfigDefaultOrBackupEncryption => { "USE_CONFIG_DEFAULT_OR_BACKUP_ENCRYPTION" } - EncryptionType::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", - EncryptionType::CustomerManagedEncryption => { - "CUSTOMER_MANAGED_ENCRYPTION" - } + Self::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", + Self::CustomerManagedEncryption => "CUSTOMER_MANAGED_ENCRYPTION", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1804,7 +1746,6 @@ pub mod restore_database_encryption_config { } /// Metadata type for the long-running operation returned by /// [RestoreDatabase][google.spanner.admin.database.v1.DatabaseAdmin.RestoreDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RestoreDatabaseMetadata { /// Name of the database being created and restored to. @@ -1856,7 +1797,6 @@ pub mod restore_database_metadata { /// Information about the source used to restore the database, as specified by /// `source` in /// [RestoreDatabaseRequest][google.spanner.admin.database.v1.RestoreDatabaseRequest]. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum SourceInfo { /// Information about the backup used to restore the database. @@ -1868,7 +1808,6 @@ pub mod restore_database_metadata { /// of optimizations performed on a newly restored database. This long-running /// operation is automatically created by the system after the successful /// completion of a database restore, and cannot be cancelled. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct OptimizeRestoredDatabaseMetadata { /// Name of the restored database being optimized. @@ -1879,7 +1818,6 @@ pub struct OptimizeRestoredDatabaseMetadata { pub progress: ::core::option::Option, } /// A Cloud Spanner database role. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DatabaseRole { /// Required. The name of the database role. Values are of the form @@ -1890,7 +1828,6 @@ pub struct DatabaseRole { } /// The request for /// [ListDatabaseRoles][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabaseRoles]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDatabaseRolesRequest { /// Required. The database whose roles should be listed. @@ -1911,7 +1848,6 @@ pub struct ListDatabaseRolesRequest { } /// The response for /// [ListDatabaseRoles][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabaseRoles]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDatabaseRolesResponse { /// Database roles that matched the request. @@ -1939,8 +1875,8 @@ impl RestoreSourceType { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - RestoreSourceType::TypeUnspecified => "TYPE_UNSPECIFIED", - RestoreSourceType::Backup => "BACKUP", + Self::TypeUnspecified => "TYPE_UNSPECIFIED", + Self::Backup => "BACKUP", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1954,7 +1890,13 @@ impl RestoreSourceType { } /// Generated client implementations. pub mod database_admin_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value, + )] use tonic::codegen::*; use tonic::codegen::http::Uri; /// Cloud Spanner Database Admin API @@ -1983,8 +1925,8 @@ pub mod database_admin_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -2009,7 +1951,7 @@ pub mod database_admin_client { >, , - >>::Error: Into + Send + Sync, + >>::Error: Into + std::marker::Send + std::marker::Sync, { DatabaseAdminClient::new(InterceptedService::new(inner, interceptor)) } @@ -2056,8 +1998,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2094,8 +2035,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2122,8 +2062,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2188,8 +2127,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2226,8 +2164,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2258,8 +2195,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2291,8 +2227,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2330,8 +2265,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2370,8 +2304,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2414,8 +2347,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2456,8 +2388,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2499,8 +2430,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2528,8 +2458,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2557,8 +2486,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2586,8 +2514,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2619,8 +2546,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2666,8 +2592,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2704,8 +2629,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2744,8 +2668,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2775,8 +2698,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2803,8 +2725,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2831,8 +2752,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2859,8 +2779,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2887,8 +2806,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2918,8 +2836,7 @@ pub mod database_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; diff --git a/googleapis/src/bytes/google.spanner.admin.instance.v1.rs b/googleapis/src/bytes/google.spanner.admin.instance.v1.rs index cfc8eb26..27b8f2e3 100644 --- a/googleapis/src/bytes/google.spanner.admin.instance.v1.rs +++ b/googleapis/src/bytes/google.spanner.admin.instance.v1.rs @@ -1,7 +1,6 @@ // This file is @generated by prost-build. /// Encapsulates progress related information for a Cloud Spanner long /// running instance operations. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct OperationProgress { /// Percent completion of the operation. @@ -36,9 +35,9 @@ impl FulfillmentPeriod { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - FulfillmentPeriod::Unspecified => "FULFILLMENT_PERIOD_UNSPECIFIED", - FulfillmentPeriod::Normal => "FULFILLMENT_PERIOD_NORMAL", - FulfillmentPeriod::Extended => "FULFILLMENT_PERIOD_EXTENDED", + Self::Unspecified => "FULFILLMENT_PERIOD_UNSPECIFIED", + Self::Normal => "FULFILLMENT_PERIOD_NORMAL", + Self::Extended => "FULFILLMENT_PERIOD_EXTENDED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -51,7 +50,6 @@ impl FulfillmentPeriod { } } } -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReplicaInfo { /// The location of the serving resources, e.g. "us-central1". @@ -118,10 +116,10 @@ pub mod replica_info { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ReplicaType::TypeUnspecified => "TYPE_UNSPECIFIED", - ReplicaType::ReadWrite => "READ_WRITE", - ReplicaType::ReadOnly => "READ_ONLY", - ReplicaType::Witness => "WITNESS", + Self::TypeUnspecified => "TYPE_UNSPECIFIED", + Self::ReadWrite => "READ_WRITE", + Self::ReadOnly => "READ_ONLY", + Self::Witness => "WITNESS", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -138,7 +136,6 @@ pub mod replica_info { } /// A possible configuration for a Cloud Spanner instance. Configurations /// define the geographic placement of nodes and their replication. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct InstanceConfig { /// A unique identifier for the instance configuration. Values @@ -252,9 +249,9 @@ pub mod instance_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Type::Unspecified => "TYPE_UNSPECIFIED", - Type::GoogleManaged => "GOOGLE_MANAGED", - Type::UserManaged => "USER_MANAGED", + Self::Unspecified => "TYPE_UNSPECIFIED", + Self::GoogleManaged => "GOOGLE_MANAGED", + Self::UserManaged => "USER_MANAGED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -296,9 +293,9 @@ pub mod instance_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Creating => "CREATING", - State::Ready => "READY", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Creating => "CREATING", + Self::Ready => "READY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -313,7 +310,6 @@ pub mod instance_config { } } /// Autoscaling configuration for an instance. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AutoscalingConfig { /// Required. Autoscaling limits for an instance. @@ -334,7 +330,6 @@ pub mod autoscaling_config { /// only scale within that range. Users can either use nodes or processing /// units to specify the limits, but should use the same unit to set both the /// min_limit and max_limit. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AutoscalingLimits { /// The minimum compute capacity for the instance. @@ -349,7 +344,6 @@ pub mod autoscaling_config { /// Nested message and enum types in `AutoscalingLimits`. pub mod autoscaling_limits { /// The minimum compute capacity for the instance. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum MinLimit { /// Minimum number of nodes allocated to the instance. If set, this number @@ -364,7 +358,6 @@ pub mod autoscaling_config { /// The maximum compute capacity for the instance. The maximum compute /// capacity should be less than or equal to 10X the minimum compute /// capacity. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum MaxLimit { /// Maximum number of nodes allocated to the instance. If set, this number @@ -379,7 +372,6 @@ pub mod autoscaling_config { } } /// The autoscaling targets for an instance. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AutoscalingTargets { /// Required. The target high priority cpu utilization percentage that the @@ -397,7 +389,6 @@ pub mod autoscaling_config { } } /// An isolated set of Cloud Spanner resources on which databases can be hosted. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Instance { /// Required. A unique identifier for the instance, which cannot be changed @@ -529,9 +520,9 @@ pub mod instance { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Creating => "CREATING", - State::Ready => "READY", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Creating => "CREATING", + Self::Ready => "READY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -575,10 +566,10 @@ pub mod instance { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Edition::Unspecified => "EDITION_UNSPECIFIED", - Edition::Standard => "STANDARD", - Edition::Enterprise => "ENTERPRISE", - Edition::EnterprisePlus => "ENTERPRISE_PLUS", + Self::Unspecified => "EDITION_UNSPECIFIED", + Self::Standard => "STANDARD", + Self::Enterprise => "ENTERPRISE", + Self::EnterprisePlus => "ENTERPRISE_PLUS", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -595,7 +586,6 @@ pub mod instance { } /// The request for /// [ListInstanceConfigs][google.spanner.admin.instance.v1.InstanceAdmin.ListInstanceConfigs]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstanceConfigsRequest { /// Required. The name of the project for which a list of supported instance @@ -616,7 +606,6 @@ pub struct ListInstanceConfigsRequest { } /// The response for /// [ListInstanceConfigs][google.spanner.admin.instance.v1.InstanceAdmin.ListInstanceConfigs]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstanceConfigsResponse { /// The list of requested instance configurations. @@ -630,7 +619,6 @@ pub struct ListInstanceConfigsResponse { } /// The request for /// [GetInstanceConfigRequest][google.spanner.admin.instance.v1.InstanceAdmin.GetInstanceConfig]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetInstanceConfigRequest { /// Required. The name of the requested instance configuration. Values are of @@ -640,7 +628,6 @@ pub struct GetInstanceConfigRequest { } /// The request for /// [CreateInstanceConfigRequest][InstanceAdmin.CreateInstanceConfigRequest]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateInstanceConfigRequest { /// Required. The name of the project in which to create the instance @@ -667,7 +654,6 @@ pub struct CreateInstanceConfigRequest { } /// The request for /// [UpdateInstanceConfigRequest][InstanceAdmin.UpdateInstanceConfigRequest]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateInstanceConfigRequest { /// Required. The user instance configuration to update, which must always @@ -694,7 +680,6 @@ pub struct UpdateInstanceConfigRequest { } /// The request for /// [DeleteInstanceConfigRequest][InstanceAdmin.DeleteInstanceConfigRequest]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteInstanceConfigRequest { /// Required. The name of the instance configuration to be deleted. @@ -718,7 +703,6 @@ pub struct DeleteInstanceConfigRequest { } /// The request for /// [ListInstanceConfigOperations][google.spanner.admin.instance.v1.InstanceAdmin.ListInstanceConfigOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstanceConfigOperationsRequest { /// Required. The project of the instance configuration operations. @@ -784,7 +768,6 @@ pub struct ListInstanceConfigOperationsRequest { } /// The response for /// [ListInstanceConfigOperations][google.spanner.admin.instance.v1.InstanceAdmin.ListInstanceConfigOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstanceConfigOperationsResponse { /// The list of matching instance configuration [long-running @@ -804,7 +787,6 @@ pub struct ListInstanceConfigOperationsResponse { } /// The request for /// [GetInstance][google.spanner.admin.instance.v1.InstanceAdmin.GetInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetInstanceRequest { /// Required. The name of the requested instance. Values are of the form @@ -820,7 +802,6 @@ pub struct GetInstanceRequest { } /// The request for /// [CreateInstance][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateInstanceRequest { /// Required. The name of the project in which to create the instance. Values @@ -839,7 +820,6 @@ pub struct CreateInstanceRequest { } /// The request for /// [ListInstances][google.spanner.admin.instance.v1.InstanceAdmin.ListInstances]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstancesRequest { /// Required. The name of the project for which a list of instances is @@ -888,7 +868,6 @@ pub struct ListInstancesRequest { } /// The response for /// [ListInstances][google.spanner.admin.instance.v1.InstanceAdmin.ListInstances]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstancesResponse { /// The list of requested instances. @@ -908,7 +887,6 @@ pub struct ListInstancesResponse { } /// The request for /// [UpdateInstance][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateInstanceRequest { /// Required. The instance to update, which must always include the instance @@ -927,7 +905,6 @@ pub struct UpdateInstanceRequest { } /// The request for /// [DeleteInstance][google.spanner.admin.instance.v1.InstanceAdmin.DeleteInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteInstanceRequest { /// Required. The name of the instance to be deleted. Values are of the form @@ -937,7 +914,6 @@ pub struct DeleteInstanceRequest { } /// Metadata type for the operation returned by /// [CreateInstance][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateInstanceMetadata { /// The instance being created. @@ -962,7 +938,6 @@ pub struct CreateInstanceMetadata { } /// Metadata type for the operation returned by /// [UpdateInstance][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateInstanceMetadata { /// The desired end state of the update. @@ -987,7 +962,6 @@ pub struct UpdateInstanceMetadata { } /// Metadata type for the operation returned by /// [CreateInstanceConfig][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstanceConfig]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateInstanceConfigMetadata { /// The target instance configuration end state. @@ -1004,7 +978,6 @@ pub struct CreateInstanceConfigMetadata { } /// Metadata type for the operation returned by /// [UpdateInstanceConfig][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstanceConfig]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateInstanceConfigMetadata { /// The desired instance configuration after updating. @@ -1021,7 +994,6 @@ pub struct UpdateInstanceConfigMetadata { } /// An isolated set of Cloud Spanner resources that databases can define /// placements on. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct InstancePartition { /// Required. A unique identifier for the instance partition. Values are of the @@ -1117,9 +1089,9 @@ pub mod instance_partition { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Creating => "CREATING", - State::Ready => "READY", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Creating => "CREATING", + Self::Ready => "READY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1137,7 +1109,6 @@ pub mod instance_partition { /// node_count or processing_units should be present in the message. See [the /// documentation]() /// for more information about nodes and processing units. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum ComputeCapacity { /// The number of nodes allocated to this instance partition. @@ -1162,7 +1133,6 @@ pub mod instance_partition { } /// Metadata type for the operation returned by /// [CreateInstancePartition][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstancePartition]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateInstancePartitionMetadata { /// The instance partition being created. @@ -1184,7 +1154,6 @@ pub struct CreateInstancePartitionMetadata { } /// The request for /// [CreateInstancePartition][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstancePartition]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateInstancePartitionRequest { /// Required. The name of the instance in which to create the instance @@ -1205,7 +1174,6 @@ pub struct CreateInstancePartitionRequest { } /// The request for /// [DeleteInstancePartition][google.spanner.admin.instance.v1.InstanceAdmin.DeleteInstancePartition]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteInstancePartitionRequest { /// Required. The name of the instance partition to be deleted. @@ -1222,7 +1190,6 @@ pub struct DeleteInstancePartitionRequest { } /// The request for /// [GetInstancePartition][google.spanner.admin.instance.v1.InstanceAdmin.GetInstancePartition]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetInstancePartitionRequest { /// Required. The name of the requested instance partition. Values are of @@ -1233,7 +1200,6 @@ pub struct GetInstancePartitionRequest { } /// The request for /// [UpdateInstancePartition][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstancePartition]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateInstancePartitionRequest { /// Required. The instance partition to update, which must always include the @@ -1253,7 +1219,6 @@ pub struct UpdateInstancePartitionRequest { } /// Metadata type for the operation returned by /// [UpdateInstancePartition][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstancePartition]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateInstancePartitionMetadata { /// The desired end state of the update. @@ -1275,7 +1240,6 @@ pub struct UpdateInstancePartitionMetadata { } /// The request for /// [ListInstancePartitions][google.spanner.admin.instance.v1.InstanceAdmin.ListInstancePartitions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstancePartitionsRequest { /// Required. The instance whose instance partitions should be listed. Values @@ -1303,7 +1267,6 @@ pub struct ListInstancePartitionsRequest { } /// The response for /// [ListInstancePartitions][google.spanner.admin.instance.v1.InstanceAdmin.ListInstancePartitions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstancePartitionsResponse { /// The list of requested instancePartitions. @@ -1323,7 +1286,6 @@ pub struct ListInstancePartitionsResponse { } /// The request for /// [ListInstancePartitionOperations][google.spanner.admin.instance.v1.InstanceAdmin.ListInstancePartitionOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstancePartitionOperationsRequest { /// Required. The parent instance of the instance partition operations. @@ -1396,7 +1358,6 @@ pub struct ListInstancePartitionOperationsRequest { } /// The response for /// [ListInstancePartitionOperations][google.spanner.admin.instance.v1.InstanceAdmin.ListInstancePartitionOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstancePartitionOperationsResponse { /// The list of matching instance partition [long-running @@ -1424,7 +1385,6 @@ pub struct ListInstancePartitionOperationsResponse { } /// The request for /// [MoveInstance][google.spanner.admin.instance.v1.InstanceAdmin.MoveInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MoveInstanceRequest { /// Required. The instance to move. @@ -1438,12 +1398,10 @@ pub struct MoveInstanceRequest { } /// The response for /// [MoveInstance][google.spanner.admin.instance.v1.InstanceAdmin.MoveInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct MoveInstanceResponse {} /// Metadata type for the operation returned by /// [MoveInstance][google.spanner.admin.instance.v1.InstanceAdmin.MoveInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MoveInstanceMetadata { /// The target instance configuration where to move the instance. @@ -1463,7 +1421,13 @@ pub struct MoveInstanceMetadata { } /// Generated client implementations. pub mod instance_admin_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value, + )] use tonic::codegen::*; use tonic::codegen::http::Uri; /// Cloud Spanner Instance Admin API @@ -1506,8 +1470,8 @@ pub mod instance_admin_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -1532,7 +1496,7 @@ pub mod instance_admin_client { >, , - >>::Error: Into + Send + Sync, + >>::Error: Into + std::marker::Send + std::marker::Sync, { InstanceAdminClient::new(InterceptedService::new(inner, interceptor)) } @@ -1579,8 +1543,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1607,8 +1570,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1678,8 +1640,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1752,8 +1713,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1787,8 +1747,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1828,8 +1787,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1859,8 +1817,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1890,8 +1847,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1918,8 +1874,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -1982,8 +1937,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2052,8 +2006,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2090,8 +2043,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2127,8 +2079,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2164,8 +2115,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2204,8 +2154,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2235,8 +2184,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2302,8 +2250,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2336,8 +2283,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2410,8 +2356,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2457,8 +2402,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2548,8 +2492,7 @@ pub mod instance_admin_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; diff --git a/googleapis/src/bytes/google.spanner.v1.rs b/googleapis/src/bytes/google.spanner.v1.rs index 0bef2912..868ad591 100644 --- a/googleapis/src/bytes/google.spanner.v1.rs +++ b/googleapis/src/bytes/google.spanner.v1.rs @@ -1,6 +1,5 @@ // This file is @generated by prost-build. /// The response for [Commit][google.spanner.v1.Spanner.Commit]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct CommitResponse { /// The Cloud Spanner timestamp at which the transaction committed. @@ -15,7 +14,6 @@ pub struct CommitResponse { /// Nested message and enum types in `CommitResponse`. pub mod commit_response { /// Additional statistics about a commit. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct CommitStats { /// The total number of mutations for the transaction. Knowing the @@ -117,7 +115,6 @@ pub mod commit_response { /// /// Note that 100 is passed as the start, and 1 is passed as the end, /// because `Key` is a descending column in the schema. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct KeyRange { /// The start key must be provided. It can be either closed or open. @@ -130,7 +127,6 @@ pub struct KeyRange { /// Nested message and enum types in `KeyRange`. pub mod key_range { /// The start key must be provided. It can be either closed or open. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum StartKeyType { /// If the start is closed, then the range includes all rows whose @@ -143,7 +139,6 @@ pub mod key_range { StartOpen(::prost_types::ListValue), } /// The end key must be provided. It can be either closed or open. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum EndKeyType { /// If the end is closed, then the range includes all rows whose @@ -163,7 +158,6 @@ pub mod key_range { /// If the same key is specified multiple times in the set (for example /// if two ranges, two keys, or a key and a range overlap), Cloud Spanner /// behaves as if the key were only specified once. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct KeySet { /// A list of specific keys. Entries in `keys` should have exactly as @@ -185,7 +179,6 @@ pub struct KeySet { /// A modification to one or more Cloud Spanner rows. Mutations can be /// applied to a Cloud Spanner database by sending them in a /// [Commit][google.spanner.v1.Spanner.Commit] call. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Mutation { /// Required. The operation to perform. @@ -196,7 +189,6 @@ pub struct Mutation { pub mod mutation { /// Arguments to [insert][google.spanner.v1.Mutation.insert], [update][google.spanner.v1.Mutation.update], [insert_or_update][google.spanner.v1.Mutation.insert_or_update], and /// [replace][google.spanner.v1.Mutation.replace] operations. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Write { /// Required. The table whose rows will be written. @@ -221,7 +213,6 @@ pub mod mutation { pub values: ::prost::alloc::vec::Vec<::prost_types::ListValue>, } /// Arguments to [delete][google.spanner.v1.Mutation.delete] operations. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Delete { /// Required. The table whose rows will be deleted. @@ -237,7 +228,6 @@ pub mod mutation { pub key_set: ::core::option::Option, } /// Required. The operation to perform. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Operation { /// Insert new rows in a table. If any of the rows already exist, @@ -275,7 +265,6 @@ pub mod mutation { } } /// Node information for nodes appearing in a [QueryPlan.plan_nodes][google.spanner.v1.QueryPlan.plan_nodes]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PlanNode { /// The `PlanNode`'s index in [node list][google.spanner.v1.QueryPlan.plan_nodes]. @@ -318,7 +307,6 @@ pub struct PlanNode { pub mod plan_node { /// Metadata associated with a parent-child relationship appearing in a /// [PlanNode][google.spanner.v1.PlanNode]. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ChildLink { /// The node to which the link points. @@ -343,7 +331,6 @@ pub mod plan_node { } /// Condensed representation of a node and its subtree. Only present for /// `SCALAR` [PlanNode(s)][google.spanner.v1.PlanNode]. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ShortRepresentation { /// A string representation of the expression subtree rooted at this node. @@ -391,9 +378,9 @@ pub mod plan_node { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Kind::Unspecified => "KIND_UNSPECIFIED", - Kind::Relational => "RELATIONAL", - Kind::Scalar => "SCALAR", + Self::Unspecified => "KIND_UNSPECIFIED", + Self::Relational => "RELATIONAL", + Self::Scalar => "SCALAR", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -408,7 +395,6 @@ pub mod plan_node { } } /// Contains an ordered list of nodes appearing in the query plan. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct QueryPlan { /// The nodes in the query plan. Plan nodes are returned in pre-order starting @@ -741,7 +727,6 @@ pub struct QueryPlan { /// Given the above, Partitioned DML is good fit for large, database-wide, /// operations that are idempotent, such as deleting old rows from a very large /// table. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct TransactionOptions { /// When `exclude_txn_from_change_streams` is set to `true`: @@ -768,7 +753,6 @@ pub struct TransactionOptions { pub mod transaction_options { /// Message type to initiate a read-write transaction. Currently this /// transaction type has no options. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ReadWrite { /// Read lock mode for the transaction. @@ -814,9 +798,9 @@ pub mod transaction_options { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ReadLockMode::Unspecified => "READ_LOCK_MODE_UNSPECIFIED", - ReadLockMode::Pessimistic => "PESSIMISTIC", - ReadLockMode::Optimistic => "OPTIMISTIC", + Self::Unspecified => "READ_LOCK_MODE_UNSPECIFIED", + Self::Pessimistic => "PESSIMISTIC", + Self::Optimistic => "OPTIMISTIC", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -831,11 +815,9 @@ pub mod transaction_options { } } /// Message type to initiate a Partitioned DML transaction. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct PartitionedDml {} /// Message type to initiate a read-only transaction. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ReadOnly { /// If true, the Cloud Spanner-selected read timestamp is included in @@ -850,7 +832,6 @@ pub mod transaction_options { /// Nested message and enum types in `ReadOnly`. pub mod read_only { /// How to choose the timestamp for the read-only transaction. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum TimestampBound { /// Read at a timestamp where all previously committed transactions @@ -914,7 +895,6 @@ pub mod transaction_options { } } /// Required. The type of transaction. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum Mode { /// Transaction may write. @@ -941,7 +921,6 @@ pub mod transaction_options { } } /// A transaction. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Transaction { /// `id` may be used to identify the transaction in subsequent @@ -969,7 +948,6 @@ pub struct Transaction { /// /// See [TransactionOptions][google.spanner.v1.TransactionOptions] for more /// information about transactions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TransactionSelector { /// If no fields are set, the default is a single use transaction @@ -981,7 +959,6 @@ pub struct TransactionSelector { pub mod transaction_selector { /// If no fields are set, the default is a single use transaction /// with strong concurrency. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Selector { /// Execute the read or SQL query in a temporary transaction. @@ -1002,7 +979,6 @@ pub mod transaction_selector { } /// `Type` indicates the type of a Cloud Spanner value, as might be stored in a /// table cell or returned from an SQL query. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Type { /// Required. The [TypeCode][google.spanner.v1.TypeCode] for this type. @@ -1033,7 +1009,6 @@ pub struct Type { pub proto_type_fqn: ::prost::alloc::string::String, } /// `StructType` defines the fields of a [STRUCT][google.spanner.v1.TypeCode.STRUCT] type. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct StructType { /// The list of fields that make up this struct. Order is @@ -1048,7 +1023,6 @@ pub struct StructType { /// Nested message and enum types in `StructType`. pub mod struct_type { /// Message representing a single field of a struct. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Field { /// The name of the field. For reads, this is the column name. For @@ -1142,21 +1116,21 @@ impl TypeCode { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - TypeCode::Unspecified => "TYPE_CODE_UNSPECIFIED", - TypeCode::Bool => "BOOL", - TypeCode::Int64 => "INT64", - TypeCode::Float64 => "FLOAT64", - TypeCode::Float32 => "FLOAT32", - TypeCode::Timestamp => "TIMESTAMP", - TypeCode::Date => "DATE", - TypeCode::String => "STRING", - TypeCode::Bytes => "BYTES", - TypeCode::Array => "ARRAY", - TypeCode::Struct => "STRUCT", - TypeCode::Numeric => "NUMERIC", - TypeCode::Json => "JSON", - TypeCode::Proto => "PROTO", - TypeCode::Enum => "ENUM", + Self::Unspecified => "TYPE_CODE_UNSPECIFIED", + Self::Bool => "BOOL", + Self::Int64 => "INT64", + Self::Float64 => "FLOAT64", + Self::Float32 => "FLOAT32", + Self::Timestamp => "TIMESTAMP", + Self::Date => "DATE", + Self::String => "STRING", + Self::Bytes => "BYTES", + Self::Array => "ARRAY", + Self::Struct => "STRUCT", + Self::Numeric => "NUMERIC", + Self::Json => "JSON", + Self::Proto => "PROTO", + Self::Enum => "ENUM", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1217,10 +1191,10 @@ impl TypeAnnotationCode { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - TypeAnnotationCode::Unspecified => "TYPE_ANNOTATION_CODE_UNSPECIFIED", - TypeAnnotationCode::PgNumeric => "PG_NUMERIC", - TypeAnnotationCode::PgJsonb => "PG_JSONB", - TypeAnnotationCode::PgOid => "PG_OID", + Self::Unspecified => "TYPE_ANNOTATION_CODE_UNSPECIFIED", + Self::PgNumeric => "PG_NUMERIC", + Self::PgJsonb => "PG_JSONB", + Self::PgOid => "PG_OID", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1236,7 +1210,6 @@ impl TypeAnnotationCode { } /// Results from [Read][google.spanner.v1.Spanner.Read] or /// [ExecuteSql][google.spanner.v1.Spanner.ExecuteSql]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ResultSet { /// Metadata about the result set, such as row type information. @@ -1264,7 +1237,6 @@ pub struct ResultSet { /// Partial results from a streaming read or SQL query. Streaming reads and /// SQL queries better tolerate large result sets, large rows, and large /// values, but are a little trickier to consume. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PartialResultSet { /// Metadata about the result set, such as row type information. @@ -1368,7 +1340,6 @@ pub struct PartialResultSet { pub stats: ::core::option::Option, } /// Metadata about a [ResultSet][google.spanner.v1.ResultSet] or [PartialResultSet][google.spanner.v1.PartialResultSet]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ResultSetMetadata { /// Indicates the field names and types for the rows in the result @@ -1399,7 +1370,6 @@ pub struct ResultSetMetadata { pub undeclared_parameters: ::core::option::Option, } /// Additional statistics about a [ResultSet][google.spanner.v1.ResultSet] or [PartialResultSet][google.spanner.v1.PartialResultSet]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ResultSetStats { /// [QueryPlan][google.spanner.v1.QueryPlan] for the query associated with this result. @@ -1423,7 +1393,6 @@ pub struct ResultSetStats { /// Nested message and enum types in `ResultSetStats`. pub mod result_set_stats { /// The number of rows modified by the DML statement. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum RowCount { /// Standard DML returns an exact count of rows that were modified. @@ -1436,7 +1405,6 @@ pub mod result_set_stats { } } /// The request for [CreateSession][google.spanner.v1.Spanner.CreateSession]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateSessionRequest { /// Required. The database in which the new session is created. @@ -1448,7 +1416,6 @@ pub struct CreateSessionRequest { } /// The request for /// [BatchCreateSessions][google.spanner.v1.Spanner.BatchCreateSessions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchCreateSessionsRequest { /// Required. The database in which the new sessions are created. @@ -1468,7 +1435,6 @@ pub struct BatchCreateSessionsRequest { } /// The response for /// [BatchCreateSessions][google.spanner.v1.Spanner.BatchCreateSessions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchCreateSessionsResponse { /// The freshly created sessions. @@ -1476,7 +1442,6 @@ pub struct BatchCreateSessionsResponse { pub session: ::prost::alloc::vec::Vec, } /// A session in the Cloud Spanner API. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Session { /// Output only. The name of the session. This is always system-assigned. @@ -1517,7 +1482,6 @@ pub struct Session { pub multiplexed: bool, } /// The request for [GetSession][google.spanner.v1.Spanner.GetSession]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetSessionRequest { /// Required. The name of the session to retrieve. @@ -1525,7 +1489,6 @@ pub struct GetSessionRequest { pub name: ::prost::alloc::string::String, } /// The request for [ListSessions][google.spanner.v1.Spanner.ListSessions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSessionsRequest { /// Required. The database in which to list sessions. @@ -1555,7 +1518,6 @@ pub struct ListSessionsRequest { pub filter: ::prost::alloc::string::String, } /// The response for [ListSessions][google.spanner.v1.Spanner.ListSessions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSessionsResponse { /// The list of requested sessions. @@ -1568,7 +1530,6 @@ pub struct ListSessionsResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request for [DeleteSession][google.spanner.v1.Spanner.DeleteSession]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteSessionRequest { /// Required. The name of the session to delete. @@ -1576,7 +1537,6 @@ pub struct DeleteSessionRequest { pub name: ::prost::alloc::string::String, } /// Common request options for various APIs. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RequestOptions { /// Priority for the request. @@ -1655,10 +1615,10 @@ pub mod request_options { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Priority::Unspecified => "PRIORITY_UNSPECIFIED", - Priority::Low => "PRIORITY_LOW", - Priority::Medium => "PRIORITY_MEDIUM", - Priority::High => "PRIORITY_HIGH", + Self::Unspecified => "PRIORITY_UNSPECIFIED", + Self::Low => "PRIORITY_LOW", + Self::Medium => "PRIORITY_MEDIUM", + Self::High => "PRIORITY_HIGH", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1678,7 +1638,6 @@ pub mod request_options { /// /// DirectedReadOptions may only be specified for a read-only transaction, /// otherwise the API will return an `INVALID_ARGUMENT` error. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DirectedReadOptions { /// Required. At most one of either include_replicas or exclude_replicas @@ -1706,7 +1665,6 @@ pub mod directed_read_options { /// * `location:us-east1 type:READ_ONLY` --> The "READ_ONLY" type replica(s) /// in location "us-east1" will be used to process /// the request. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReplicaSelection { /// The location or region of the serving requests, e.g. "us-east1". @@ -1746,9 +1704,9 @@ pub mod directed_read_options { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Type::Unspecified => "TYPE_UNSPECIFIED", - Type::ReadWrite => "READ_WRITE", - Type::ReadOnly => "READ_ONLY", + Self::Unspecified => "TYPE_UNSPECIFIED", + Self::ReadWrite => "READ_WRITE", + Self::ReadOnly => "READ_ONLY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1764,7 +1722,6 @@ pub mod directed_read_options { } /// An IncludeReplicas contains a repeated set of ReplicaSelection which /// indicates the order in which replicas should be considered. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct IncludeReplicas { /// The directed read replica selector. @@ -1778,7 +1735,6 @@ pub mod directed_read_options { } /// An ExcludeReplicas contains a repeated set of ReplicaSelection that should /// be excluded from serving requests. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ExcludeReplicas { /// The directed read replica selector. @@ -1787,7 +1743,6 @@ pub mod directed_read_options { } /// Required. At most one of either include_replicas or exclude_replicas /// should be present in the message. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Replicas { /// Include_replicas indicates the order of replicas (as they appear in @@ -1806,7 +1761,6 @@ pub mod directed_read_options { } /// The request for [ExecuteSql][google.spanner.v1.Spanner.ExecuteSql] and /// [ExecuteStreamingSql][google.spanner.v1.Spanner.ExecuteStreamingSql]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ExecuteSqlRequest { /// Required. The session in which the SQL query should be performed. @@ -1907,7 +1861,6 @@ pub struct ExecuteSqlRequest { /// Nested message and enum types in `ExecuteSqlRequest`. pub mod execute_sql_request { /// Query optimizer configuration. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct QueryOptions { /// An option to control the selection of optimizer version. @@ -1991,9 +1944,9 @@ pub mod execute_sql_request { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - QueryMode::Normal => "NORMAL", - QueryMode::Plan => "PLAN", - QueryMode::Profile => "PROFILE", + Self::Normal => "NORMAL", + Self::Plan => "PLAN", + Self::Profile => "PROFILE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -2008,7 +1961,6 @@ pub mod execute_sql_request { } } /// The request for [ExecuteBatchDml][google.spanner.v1.Spanner.ExecuteBatchDml]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ExecuteBatchDmlRequest { /// Required. The session in which the DML statements should be performed. @@ -2046,7 +1998,6 @@ pub struct ExecuteBatchDmlRequest { /// Nested message and enum types in `ExecuteBatchDmlRequest`. pub mod execute_batch_dml_request { /// A single DML statement. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Statement { /// Required. The DML string. @@ -2114,7 +2065,6 @@ pub mod execute_batch_dml_request { /// status. The number of [ResultSet][google.spanner.v1.ResultSet] messages /// indicates that the third statement failed, and the fourth and fifth /// statements were not executed. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ExecuteBatchDmlResponse { /// One [ResultSet][google.spanner.v1.ResultSet] for each statement in the @@ -2135,7 +2085,6 @@ pub struct ExecuteBatchDmlResponse { } /// Options for a PartitionQueryRequest and /// PartitionReadRequest. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct PartitionOptions { /// **Note:** This hint is currently ignored by PartitionQuery and @@ -2158,7 +2107,6 @@ pub struct PartitionOptions { pub max_partitions: i64, } /// The request for [PartitionQuery][google.spanner.v1.Spanner.PartitionQuery] -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PartitionQueryRequest { /// Required. The session used to create the partitions. @@ -2212,7 +2160,6 @@ pub struct PartitionQueryRequest { pub partition_options: ::core::option::Option, } /// The request for [PartitionRead][google.spanner.v1.Spanner.PartitionRead] -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PartitionReadRequest { /// Required. The session used to create the partitions. @@ -2255,7 +2202,6 @@ pub struct PartitionReadRequest { } /// Information returned for each partition returned in a /// PartitionResponse. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Partition { /// This token can be passed to Read, StreamingRead, ExecuteSql, or @@ -2266,7 +2212,6 @@ pub struct Partition { } /// The response for [PartitionQuery][google.spanner.v1.Spanner.PartitionQuery] /// or [PartitionRead][google.spanner.v1.Spanner.PartitionRead] -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PartitionResponse { /// Partitions created by this request. @@ -2278,7 +2223,6 @@ pub struct PartitionResponse { } /// The request for [Read][google.spanner.v1.Spanner.Read] and /// [StreamingRead][google.spanner.v1.Spanner.StreamingRead]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadRequest { /// Required. The session in which the read should be performed. @@ -2402,9 +2346,9 @@ pub mod read_request { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - OrderBy::Unspecified => "ORDER_BY_UNSPECIFIED", - OrderBy::PrimaryKey => "ORDER_BY_PRIMARY_KEY", - OrderBy::NoOrder => "ORDER_BY_NO_ORDER", + Self::Unspecified => "ORDER_BY_UNSPECIFIED", + Self::PrimaryKey => "ORDER_BY_PRIMARY_KEY", + Self::NoOrder => "ORDER_BY_NO_ORDER", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -2481,9 +2425,9 @@ pub mod read_request { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - LockHint::Unspecified => "LOCK_HINT_UNSPECIFIED", - LockHint::Shared => "LOCK_HINT_SHARED", - LockHint::Exclusive => "LOCK_HINT_EXCLUSIVE", + Self::Unspecified => "LOCK_HINT_UNSPECIFIED", + Self::Shared => "LOCK_HINT_SHARED", + Self::Exclusive => "LOCK_HINT_EXCLUSIVE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -2499,7 +2443,6 @@ pub mod read_request { } /// The request for /// [BeginTransaction][google.spanner.v1.Spanner.BeginTransaction]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BeginTransactionRequest { /// Required. The session in which the transaction runs. @@ -2517,7 +2460,6 @@ pub struct BeginTransactionRequest { pub request_options: ::core::option::Option, } /// The request for [Commit][google.spanner.v1.Spanner.Commit]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CommitRequest { /// Required. The session in which the transaction to be committed is running. @@ -2550,7 +2492,6 @@ pub struct CommitRequest { /// Nested message and enum types in `CommitRequest`. pub mod commit_request { /// Required. The transaction in which to commit. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Transaction { /// Commit a previously-started transaction. @@ -2570,7 +2511,6 @@ pub mod commit_request { } } /// The request for [Rollback][google.spanner.v1.Spanner.Rollback]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RollbackRequest { /// Required. The session in which the transaction to roll back is running. @@ -2581,7 +2521,6 @@ pub struct RollbackRequest { pub transaction_id: ::prost::bytes::Bytes, } /// The request for [BatchWrite][google.spanner.v1.Spanner.BatchWrite]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchWriteRequest { /// Required. The session in which the batch request is to be run. @@ -2613,7 +2552,6 @@ pub mod batch_write_request { /// A group of mutations to be committed together. Related mutations should be /// placed in a group. For example, two mutations inserting rows with the same /// primary key prefix in both parent and child tables are related. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MutationGroup { /// Required. The mutations in this group. @@ -2622,7 +2560,6 @@ pub mod batch_write_request { } } /// The result of applying a batch of mutations. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchWriteResponse { /// The mutation groups applied in this batch. The values index into the @@ -2639,7 +2576,13 @@ pub struct BatchWriteResponse { } /// Generated client implementations. pub mod spanner_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value, + )] use tonic::codegen::*; use tonic::codegen::http::Uri; /// Cloud Spanner API @@ -2665,8 +2608,8 @@ pub mod spanner_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -2691,7 +2634,7 @@ pub mod spanner_client { >, , - >>::Error: Into + Send + Sync, + >>::Error: Into + std::marker::Send + std::marker::Sync, { SpannerClient::new(InterceptedService::new(inner, interceptor)) } @@ -2753,8 +2696,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2782,8 +2724,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2809,8 +2750,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2835,8 +2775,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2860,8 +2799,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2895,8 +2833,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2925,8 +2862,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2964,8 +2900,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3000,8 +2935,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3030,8 +2964,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3057,8 +2990,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3095,8 +3027,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3126,8 +3057,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3163,8 +3093,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3202,8 +3131,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3242,8 +3170,7 @@ pub mod spanner_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; diff --git a/googleapis/src/bytes/google.storage.v2.rs b/googleapis/src/bytes/google.storage.v2.rs index f164e142..302b68c6 100644 --- a/googleapis/src/bytes/google.storage.v2.rs +++ b/googleapis/src/bytes/google.storage.v2.rs @@ -1,6 +1,5 @@ // This file is @generated by prost-build. /// Request message for DeleteBucket. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteBucketRequest { /// Required. Name of a bucket to delete. @@ -15,7 +14,6 @@ pub struct DeleteBucketRequest { pub if_metageneration_not_match: ::core::option::Option, } /// Request message for GetBucket. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetBucketRequest { /// Required. Name of a bucket. @@ -36,7 +34,6 @@ pub struct GetBucketRequest { pub read_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Request message for CreateBucket. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateBucketRequest { /// Required. The project to which this bucket will belong. @@ -68,7 +65,6 @@ pub struct CreateBucketRequest { pub predefined_default_object_acl: ::prost::alloc::string::String, } /// Request message for ListBuckets. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBucketsRequest { /// Required. The project whose buckets we are listing. @@ -95,7 +91,6 @@ pub struct ListBucketsRequest { pub read_mask: ::core::option::Option<::prost_types::FieldMask>, } /// The result of a call to Buckets.ListBuckets -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBucketsResponse { /// The list of items. @@ -107,7 +102,6 @@ pub struct ListBucketsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request message for LockBucketRetentionPolicyRequest. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct LockBucketRetentionPolicyRequest { /// Required. Name of a bucket. @@ -119,7 +113,6 @@ pub struct LockBucketRetentionPolicyRequest { pub if_metageneration_match: i64, } /// Request for UpdateBucket method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateBucketRequest { /// Required. The bucket to update. @@ -156,7 +149,6 @@ pub struct UpdateBucketRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Request message for ComposeObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ComposeObjectRequest { /// Required. Properties of the resulting object. @@ -196,7 +188,6 @@ pub struct ComposeObjectRequest { /// Nested message and enum types in `ComposeObjectRequest`. pub mod compose_object_request { /// Description of a source object for a composition request. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct SourceObject { /// Required. The source object's name. All source objects must reside in the @@ -215,7 +206,6 @@ pub mod compose_object_request { /// Nested message and enum types in `SourceObject`. pub mod source_object { /// Preconditions for a source object of a composition request. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ObjectPreconditions { /// Only perform the composition if the generation of the source object @@ -228,7 +218,6 @@ pub mod compose_object_request { } /// Message for deleting an object. /// `bucket` and `object` **must** be set. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteObjectRequest { /// Required. Name of the bucket in which the object resides. @@ -268,7 +257,6 @@ pub struct DeleteObjectRequest { } /// Message for restoring an object. /// `bucket`, `object`, and `generation` **must** be set. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RestoreObjectRequest { /// Required. Name of the bucket in which the object resides. @@ -310,7 +298,6 @@ pub struct RestoreObjectRequest { } /// Message for canceling an in-progress resumable upload. /// `upload_id` **must** be set. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CancelResumableWriteRequest { /// Required. The upload_id of the resumable upload to cancel. This should be @@ -320,11 +307,9 @@ pub struct CancelResumableWriteRequest { } /// Empty response message for canceling an in-progress resumable upload, will be /// extended as needed. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct CancelResumableWriteResponse {} /// Request message for ReadObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadObjectRequest { /// Required. The name of the bucket containing the object to read. @@ -388,7 +373,6 @@ pub struct ReadObjectRequest { pub read_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Request message for GetObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetObjectRequest { /// Required. Name of the bucket in which the object resides. @@ -434,7 +418,6 @@ pub struct GetObjectRequest { pub read_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Response message for ReadObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadObjectResponse { /// A portion of the data for the object. The service **may** leave `data` @@ -459,7 +442,6 @@ pub struct ReadObjectResponse { pub metadata: ::core::option::Option, } /// Describes an attempt to insert an object, possibly over multiple requests. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct WriteObjectSpec { /// Required. Destination object, including its name and its metadata. @@ -500,7 +482,6 @@ pub struct WriteObjectSpec { pub object_size: ::core::option::Option, } /// Request message for WriteObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct WriteObjectRequest { /// Required. The offset from the beginning of the object at which the data @@ -545,7 +526,6 @@ pub struct WriteObjectRequest { /// Nested message and enum types in `WriteObjectRequest`. pub mod write_object_request { /// The first message of each stream should set one of the following. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum FirstMessage { /// For resumable uploads. This should be the `upload_id` returned from a @@ -558,7 +538,6 @@ pub mod write_object_request { WriteObjectSpec(super::WriteObjectSpec), } /// A portion of the data for the object. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Data { /// The data to insert. If a crc32c checksum is provided that doesn't match @@ -568,7 +547,6 @@ pub mod write_object_request { } } /// Response message for WriteObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct WriteObjectResponse { /// The response will set one of the following. @@ -578,7 +556,6 @@ pub struct WriteObjectResponse { /// Nested message and enum types in `WriteObjectResponse`. pub mod write_object_response { /// The response will set one of the following. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum WriteStatus { /// The total number of bytes that have been processed for the given object @@ -592,7 +569,6 @@ pub mod write_object_response { } } /// Request message for BidiWriteObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BidiWriteObjectRequest { /// Required. The offset from the beginning of the object at which the data @@ -654,7 +630,6 @@ pub struct BidiWriteObjectRequest { /// Nested message and enum types in `BidiWriteObjectRequest`. pub mod bidi_write_object_request { /// The first message of each stream should set one of the following. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum FirstMessage { /// For resumable uploads. This should be the `upload_id` returned from a @@ -667,7 +642,6 @@ pub mod bidi_write_object_request { WriteObjectSpec(super::WriteObjectSpec), } /// A portion of the data for the object. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Data { /// The data to insert. If a crc32c checksum is provided that doesn't match @@ -677,7 +651,6 @@ pub mod bidi_write_object_request { } } /// Response message for BidiWriteObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BidiWriteObjectResponse { /// The response will set one of the following. @@ -687,7 +660,6 @@ pub struct BidiWriteObjectResponse { /// Nested message and enum types in `BidiWriteObjectResponse`. pub mod bidi_write_object_response { /// The response will set one of the following. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum WriteStatus { /// The total number of bytes that have been processed for the given object @@ -701,7 +673,6 @@ pub mod bidi_write_object_response { } } /// Request message for ListObjects. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListObjectsRequest { /// Required. Name of the bucket in which to look for objects. @@ -773,7 +744,6 @@ pub struct ListObjectsRequest { pub match_glob: ::prost::alloc::string::String, } /// Request object for `QueryWriteStatus`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct QueryWriteStatusRequest { /// Required. The name of the resume token for the object whose write status is @@ -785,7 +755,6 @@ pub struct QueryWriteStatusRequest { pub common_object_request_params: ::core::option::Option, } /// Response object for `QueryWriteStatus`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct QueryWriteStatusResponse { /// The response will set one of the following. @@ -795,7 +764,6 @@ pub struct QueryWriteStatusResponse { /// Nested message and enum types in `QueryWriteStatusResponse`. pub mod query_write_status_response { /// The response will set one of the following. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum WriteStatus { /// The total number of bytes that have been processed for the given object @@ -818,7 +786,6 @@ pub mod query_write_status_response { /// should be provided in the encryption_algorithm, encryption_key_bytes, and /// encryption_key_sha256_bytes fields of the /// common_object_request_params.customer_encryption field. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RewriteObjectRequest { /// Required. Immutable. The name of the destination object. @@ -940,7 +907,6 @@ pub struct RewriteObjectRequest { pub object_checksums: ::core::option::Option, } /// A rewrite response. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RewriteResponse { /// The total bytes written so far, which can be used to provide a waiting user @@ -965,7 +931,6 @@ pub struct RewriteResponse { pub resource: ::core::option::Option, } /// Request message StartResumableWrite. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct StartResumableWriteRequest { /// Required. The destination bucket, object, and metadata, as well as any @@ -983,7 +948,6 @@ pub struct StartResumableWriteRequest { pub object_checksums: ::core::option::Option, } /// Response object for `StartResumableWrite`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct StartResumableWriteResponse { /// The upload_id of the newly started resumable write operation. This @@ -992,7 +956,6 @@ pub struct StartResumableWriteResponse { pub upload_id: ::prost::alloc::string::String, } /// Request message for UpdateObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateObjectRequest { /// Required. The object to update. @@ -1041,7 +1004,6 @@ pub struct UpdateObjectRequest { pub common_object_request_params: ::core::option::Option, } /// Request message for GetServiceAccount. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetServiceAccountRequest { /// Required. Project ID, in the format of "projects/{projectIdentifier}". @@ -1052,7 +1014,6 @@ pub struct GetServiceAccountRequest { /// A service account, owned by Cloud Storage, which may be used when taking /// action on behalf of a given project, for example to publish Pub/Sub /// notifications or to retrieve security keys. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ServiceAccount { /// The ID of the notification. @@ -1060,7 +1021,6 @@ pub struct ServiceAccount { pub email_address: ::prost::alloc::string::String, } /// Request message for CreateHmacKey. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateHmacKeyRequest { /// Required. The project that the HMAC-owning service account lives in, in the @@ -1073,7 +1033,6 @@ pub struct CreateHmacKeyRequest { pub service_account_email: ::prost::alloc::string::String, } /// Create hmac response. The only time the secret for an HMAC will be returned. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateHmacKeyResponse { /// Key metadata. @@ -1085,7 +1044,6 @@ pub struct CreateHmacKeyResponse { pub secret_key_bytes: ::prost::bytes::Bytes, } /// Request object to delete a given HMAC key. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteHmacKeyRequest { /// Required. The identifying key for the HMAC to delete. @@ -1098,7 +1056,6 @@ pub struct DeleteHmacKeyRequest { pub project: ::prost::alloc::string::String, } /// Request object to get metadata on a given HMAC key. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetHmacKeyRequest { /// Required. The identifying key for the HMAC to delete. @@ -1111,7 +1068,6 @@ pub struct GetHmacKeyRequest { pub project: ::prost::alloc::string::String, } /// Request to fetch a list of HMAC keys under a given project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListHmacKeysRequest { /// Required. The project to list HMAC keys for, in the format of @@ -1133,7 +1089,6 @@ pub struct ListHmacKeysRequest { pub show_deleted_keys: bool, } /// Hmac key list response with next page information. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListHmacKeysResponse { /// The list of items. @@ -1148,7 +1103,6 @@ pub struct ListHmacKeysResponse { /// HmacKeyMetadata.state is required and the only writable field in /// UpdateHmacKey operation. Specifying fields other than state will result in an /// error. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateHmacKeyRequest { /// Required. The HMAC key to update. @@ -1164,7 +1118,6 @@ pub struct UpdateHmacKeyRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Hmac Key Metadata, which includes all information other than the secret. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct HmacKeyMetadata { /// Immutable. Resource name ID of the key in the format @@ -1198,7 +1151,6 @@ pub struct HmacKeyMetadata { pub etag: ::prost::alloc::string::String, } /// Parameters that can be passed to any object request. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CommonObjectRequestParams { /// Encryption algorithm used with the Customer-Supplied Encryption Keys @@ -1215,7 +1167,6 @@ pub struct CommonObjectRequestParams { pub encryption_key_sha256_bytes: ::prost::bytes::Bytes, } /// Shared constants. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ServiceConstants {} /// Nested message and enum types in `ServiceConstants`. @@ -1290,37 +1241,37 @@ pub mod service_constants { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Values::Unspecified => "VALUES_UNSPECIFIED", - Values::MaxReadChunkBytes => "MAX_READ_CHUNK_BYTES", - Values::MaxObjectSizeMb => "MAX_OBJECT_SIZE_MB", - Values::MaxCustomMetadataFieldNameBytes => { + Self::Unspecified => "VALUES_UNSPECIFIED", + Self::MaxReadChunkBytes => "MAX_READ_CHUNK_BYTES", + Self::MaxObjectSizeMb => "MAX_OBJECT_SIZE_MB", + Self::MaxCustomMetadataFieldNameBytes => { "MAX_CUSTOM_METADATA_FIELD_NAME_BYTES" } - Values::MaxCustomMetadataFieldValueBytes => { + Self::MaxCustomMetadataFieldValueBytes => { "MAX_CUSTOM_METADATA_FIELD_VALUE_BYTES" } - Values::MaxCustomMetadataTotalSizeBytes => { + Self::MaxCustomMetadataTotalSizeBytes => { "MAX_CUSTOM_METADATA_TOTAL_SIZE_BYTES" } - Values::MaxBucketMetadataTotalSizeBytes => { + Self::MaxBucketMetadataTotalSizeBytes => { "MAX_BUCKET_METADATA_TOTAL_SIZE_BYTES" } - Values::MaxNotificationConfigsPerBucket => { + Self::MaxNotificationConfigsPerBucket => { "MAX_NOTIFICATION_CONFIGS_PER_BUCKET" } - Values::MaxNotificationCustomAttributes => { + Self::MaxNotificationCustomAttributes => { "MAX_NOTIFICATION_CUSTOM_ATTRIBUTES" } - Values::MaxNotificationCustomAttributeKeyLength => { + Self::MaxNotificationCustomAttributeKeyLength => { "MAX_NOTIFICATION_CUSTOM_ATTRIBUTE_KEY_LENGTH" } - Values::MaxLabelsEntriesCount => "MAX_LABELS_ENTRIES_COUNT", - Values::MaxLabelsKeyValueLength => "MAX_LABELS_KEY_VALUE_LENGTH", - Values::MaxLabelsKeyValueBytes => "MAX_LABELS_KEY_VALUE_BYTES", - Values::MaxObjectIdsPerDeleteObjectsRequest => { + Self::MaxLabelsEntriesCount => "MAX_LABELS_ENTRIES_COUNT", + Self::MaxLabelsKeyValueLength => "MAX_LABELS_KEY_VALUE_LENGTH", + Self::MaxLabelsKeyValueBytes => "MAX_LABELS_KEY_VALUE_BYTES", + Self::MaxObjectIdsPerDeleteObjectsRequest => { "MAX_OBJECT_IDS_PER_DELETE_OBJECTS_REQUEST" } - Values::SplitTokenMaxValidDays => "SPLIT_TOKEN_MAX_VALID_DAYS", + Self::SplitTokenMaxValidDays => "SPLIT_TOKEN_MAX_VALID_DAYS", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1363,7 +1314,6 @@ pub mod service_constants { } } /// A bucket. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Bucket { /// Immutable. The name of the bucket. @@ -1524,7 +1474,6 @@ pub struct Bucket { /// Nested message and enum types in `Bucket`. pub mod bucket { /// Billing properties of a bucket. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct Billing { /// When set to true, Requester Pays is enabled for this bucket. @@ -1535,7 +1484,6 @@ pub mod bucket { /// For more on Cloud Storage and CORS, see /// /// For more on CORS in general, see - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Cors { /// The list of Origins eligible to receive CORS response headers. See @@ -1560,7 +1508,6 @@ pub mod bucket { pub max_age_seconds: i32, } /// Encryption properties of a bucket. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Encryption { /// The name of the Cloud KMS key that will be used to encrypt objects @@ -1569,7 +1516,6 @@ pub mod bucket { pub default_kms_key: ::prost::alloc::string::String, } /// Bucket restriction options. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct IamConfig { /// Bucket restriction options currently enforced on the bucket. @@ -1586,7 +1532,6 @@ pub mod bucket { pub mod iam_config { /// Settings for Uniform Bucket level access. /// See - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct UniformBucketLevelAccess { /// If set, access checks only use bucket-level IAM policies or above. @@ -1602,7 +1547,6 @@ pub mod bucket { } /// Lifecycle properties of a bucket. /// For more information, see - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Lifecycle { /// A lifecycle management rule, which is made of an action to take and the @@ -1614,7 +1558,6 @@ pub mod bucket { pub mod lifecycle { /// A lifecycle Rule, combining an action to take on an object and a /// condition which will trigger that action. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Rule { /// The action to take. @@ -1627,7 +1570,6 @@ pub mod bucket { /// Nested message and enum types in `Rule`. pub mod rule { /// An action to take on an object. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Action { /// Type of the action. Currently, only `Delete`, `SetStorageClass`, and @@ -1640,7 +1582,6 @@ pub mod bucket { pub storage_class: ::prost::alloc::string::String, } /// A condition of an object which triggers some action. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Condition { /// Age of an object (in days). This condition is satisfied when an @@ -1714,7 +1655,6 @@ pub mod bucket { } } /// Logging-related properties of a bucket. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Logging { /// The destination bucket where the current bucket's logs should be placed, @@ -1726,7 +1666,6 @@ pub mod bucket { pub log_object_prefix: ::prost::alloc::string::String, } /// Retention policy properties of a bucket. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct RetentionPolicy { /// Server-determined value that indicates the time from which policy was @@ -1745,7 +1684,6 @@ pub mod bucket { pub retention_duration: ::core::option::Option<::prost_types::Duration>, } /// Soft delete policy properties of a bucket. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct SoftDeletePolicy { /// The period of time that soft-deleted objects in the bucket must be @@ -1760,7 +1698,6 @@ pub mod bucket { /// Properties of a bucket related to versioning. /// For more on Cloud Storage versioning, see /// - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct Versioning { /// While set to true, versioning is fully enabled for this bucket. @@ -1770,7 +1707,6 @@ pub mod bucket { /// Properties of a bucket related to accessing the contents as a static /// website. For more on hosting a static website via Cloud Storage, see /// - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Website { /// If the requested object path is missing, the service will ensure the path @@ -1790,7 +1726,6 @@ pub mod bucket { /// Configuration for Custom Dual Regions. It should specify precisely two /// eligible regions within the same Multiregion. More information on regions /// may be found [ - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CustomPlacementConfig { /// List of locations to use for data placement. @@ -1798,7 +1733,6 @@ pub mod bucket { pub data_locations: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Configuration for a bucket's Autoclass feature. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Autoclass { /// Enables Autoclass. @@ -1825,7 +1759,6 @@ pub mod bucket { >, } /// Configuration for a bucket's hierarchical namespace feature. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct HierarchicalNamespace { /// Optional. Enables the hierarchical namespace feature. @@ -1834,7 +1767,6 @@ pub mod bucket { } } /// An access-control entry. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BucketAccessControl { /// The access permission for the entity. @@ -1888,7 +1820,6 @@ pub struct BucketAccessControl { } /// Message used to convey content being read or written, along with an optional /// checksum. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ChecksummedData { /// Optional. The data. @@ -1899,7 +1830,6 @@ pub struct ChecksummedData { pub crc32c: ::core::option::Option, } /// Message used for storing full (not subrange) object checksums. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ObjectChecksums { /// CRC32C digest of the object data. Computed by the Cloud Storage service for @@ -1920,7 +1850,6 @@ pub struct ObjectChecksums { } /// Describes the Customer-Supplied Encryption Key mechanism used to store an /// Object's data at rest. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CustomerEncryption { /// The encryption algorithm. @@ -1932,7 +1861,6 @@ pub struct CustomerEncryption { pub key_sha256_bytes: ::prost::bytes::Bytes, } /// An object. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Object { /// Immutable. The name of this object. Nearly any sequence of unicode @@ -2093,7 +2021,6 @@ pub struct Object { pub hard_delete_time: ::core::option::Option<::prost_types::Timestamp>, } /// An access-control entry. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ObjectAccessControl { /// The access permission for the entity. One of the following values: @@ -2149,7 +2076,6 @@ pub struct ObjectAccessControl { pub project_team: ::core::option::Option, } /// The result of a call to Objects.ListObjects -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListObjectsResponse { /// The list of items. @@ -2165,7 +2091,6 @@ pub struct ListObjectsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Represents the Viewers, Editors, or Owners of a given project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ProjectTeam { /// The project number. @@ -2176,7 +2101,6 @@ pub struct ProjectTeam { pub team: ::prost::alloc::string::String, } /// The owner of a specific resource. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Owner { /// The entity, in the form `user-`*userId*. @@ -2187,7 +2111,6 @@ pub struct Owner { pub entity_id: ::prost::alloc::string::String, } /// Specifies a requested range of bytes to download. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ContentRange { /// The starting offset of the object data. This value is inclusive. @@ -2201,7 +2124,6 @@ pub struct ContentRange { pub complete_length: i64, } /// Request message for DeleteNotificationConfig. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteNotificationConfigRequest { /// Required. The parent bucket of the NotificationConfig. @@ -2209,7 +2131,6 @@ pub struct DeleteNotificationConfigRequest { pub name: ::prost::alloc::string::String, } /// Request message for GetNotificationConfig. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetNotificationConfigRequest { /// Required. The parent bucket of the NotificationConfig. @@ -2219,7 +2140,6 @@ pub struct GetNotificationConfigRequest { pub name: ::prost::alloc::string::String, } /// Request message for CreateNotificationConfig. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateNotificationConfigRequest { /// Required. The bucket to which this NotificationConfig belongs. @@ -2230,7 +2150,6 @@ pub struct CreateNotificationConfigRequest { pub notification_config: ::core::option::Option, } /// Request message for ListNotifications. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListNotificationConfigsRequest { /// Required. Name of a Google Cloud Storage bucket. @@ -2250,7 +2169,6 @@ pub struct ListNotificationConfigsRequest { pub page_token: ::prost::alloc::string::String, } /// The result of a call to ListNotificationConfigs -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListNotificationConfigsResponse { /// The list of items. @@ -2262,7 +2180,6 @@ pub struct ListNotificationConfigsResponse { pub next_page_token: ::prost::alloc::string::String, } /// A directive to publish Pub/Sub notifications upon changes to a bucket. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct NotificationConfig { /// Required. The resource name of this NotificationConfig. @@ -2302,7 +2219,13 @@ pub struct NotificationConfig { } /// Generated client implementations. pub mod storage_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value, + )] use tonic::codegen::*; use tonic::codegen::http::Uri; /// ## API Overview and Naming Syntax @@ -2345,8 +2268,8 @@ pub mod storage_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -2371,7 +2294,7 @@ pub mod storage_client { >, , - >>::Error: Into + Send + Sync, + >>::Error: Into + std::marker::Send + std::marker::Sync, { StorageClient::new(InterceptedService::new(inner, interceptor)) } @@ -2415,8 +2338,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2438,8 +2360,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2461,8 +2382,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2487,8 +2407,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2510,8 +2429,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2545,8 +2463,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2575,8 +2492,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2609,8 +2525,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2634,8 +2549,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2658,8 +2572,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2686,8 +2599,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2709,8 +2621,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2742,8 +2653,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2767,8 +2677,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2793,8 +2702,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2817,8 +2725,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2903,8 +2810,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2945,8 +2851,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2971,8 +2876,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -2998,8 +2902,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3026,8 +2929,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3066,8 +2968,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3083,6 +2984,7 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Retrieves the name of a project's Google Cloud Storage service account. + #[deprecated] pub async fn get_service_account( &mut self, request: impl tonic::IntoRequest, @@ -3091,8 +2993,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3108,6 +3009,7 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Creates a new HMAC key for the given service account. + #[deprecated] pub async fn create_hmac_key( &mut self, request: impl tonic::IntoRequest, @@ -3119,8 +3021,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3134,6 +3035,7 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Deletes a given HMAC key. Key must be in an INACTIVE state. + #[deprecated] pub async fn delete_hmac_key( &mut self, request: impl tonic::IntoRequest, @@ -3142,8 +3044,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3157,6 +3058,7 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Gets an existing HMAC key metadata for the given id. + #[deprecated] pub async fn get_hmac_key( &mut self, request: impl tonic::IntoRequest, @@ -3168,8 +3070,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3183,6 +3084,7 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Lists HMAC keys under a given project with the additional filters provided. + #[deprecated] pub async fn list_hmac_keys( &mut self, request: impl tonic::IntoRequest, @@ -3194,8 +3096,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3209,6 +3110,7 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Updates a given HMAC key state between ACTIVE and INACTIVE. + #[deprecated] pub async fn update_hmac_key( &mut self, request: impl tonic::IntoRequest, @@ -3220,8 +3122,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3235,6 +3136,7 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Permanently deletes a NotificationConfig. + #[deprecated] pub async fn delete_notification_config( &mut self, request: impl tonic::IntoRequest, @@ -3243,8 +3145,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3263,6 +3164,7 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// View a NotificationConfig. + #[deprecated] pub async fn get_notification_config( &mut self, request: impl tonic::IntoRequest, @@ -3274,8 +3176,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3294,6 +3195,7 @@ pub mod storage_client { /// These NotificationConfigs, when triggered, publish messages to the /// specified Pub/Sub topics. See /// https://cloud.google.com/storage/docs/pubsub-notifications. + #[deprecated] pub async fn create_notification_config( &mut self, request: impl tonic::IntoRequest, @@ -3305,8 +3207,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; @@ -3325,6 +3226,7 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Retrieves a list of NotificationConfigs for a given bucket. + #[deprecated] pub async fn list_notification_configs( &mut self, request: impl tonic::IntoRequest, @@ -3336,8 +3238,7 @@ pub mod storage_client { .ready() .await .map_err(|e| { - tonic::Status::new( - tonic::Code::Unknown, + tonic::Status::unknown( format!("Service was not ready: {}", e.into()), ) })?; diff --git a/googleapis/src/google.api.rs b/googleapis/src/google.api.rs index cd38789a..0ce83e47 100644 --- a/googleapis/src/google.api.rs +++ b/googleapis/src/google.api.rs @@ -2,7 +2,6 @@ /// Defines the HTTP configuration for an API service. It contains a list of /// [HttpRule][google.api.HttpRule], each specifying the mapping of an RPC method /// to one or more HTTP REST API methods. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Http { /// A list of HTTP configuration rules that apply to individual API methods. @@ -283,7 +282,6 @@ pub struct Http { /// If an API needs to use a JSON array for request or response body, it can map /// the request or response body to a repeated field. However, some gRPC /// Transcoding implementations may not support this feature. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct HttpRule { /// Selects a method to which this rule applies. @@ -324,7 +322,6 @@ pub mod http_rule { /// Determines the URL pattern is matched by this rules. This pattern can be /// used with any of the {get|put|post|delete|patch} methods. A custom method /// can be defined using the 'custom' field. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Pattern { /// Maps to HTTP GET. Used for listing and getting information about @@ -352,7 +349,6 @@ pub mod http_rule { } } /// A custom pattern is used for defining custom HTTP verb. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CustomHttpPattern { /// The name of this custom HTTP verb. @@ -412,14 +408,14 @@ impl LaunchStage { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - LaunchStage::Unspecified => "LAUNCH_STAGE_UNSPECIFIED", - LaunchStage::Unimplemented => "UNIMPLEMENTED", - LaunchStage::Prelaunch => "PRELAUNCH", - LaunchStage::EarlyAccess => "EARLY_ACCESS", - LaunchStage::Alpha => "ALPHA", - LaunchStage::Beta => "BETA", - LaunchStage::Ga => "GA", - LaunchStage::Deprecated => "DEPRECATED", + Self::Unspecified => "LAUNCH_STAGE_UNSPECIFIED", + Self::Unimplemented => "UNIMPLEMENTED", + Self::Prelaunch => "PRELAUNCH", + Self::EarlyAccess => "EARLY_ACCESS", + Self::Alpha => "ALPHA", + Self::Beta => "BETA", + Self::Ga => "GA", + Self::Deprecated => "DEPRECATED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -438,7 +434,6 @@ impl LaunchStage { } } /// Required information for every language. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CommonLanguageSettings { /// Link to automatically generated reference documentation. Example: @@ -451,7 +446,6 @@ pub struct CommonLanguageSettings { pub destinations: ::prost::alloc::vec::Vec, } /// Details about how and where to publish client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ClientLibrarySettings { /// Version of the API to apply these settings to. This is the full protobuf @@ -494,7 +488,6 @@ pub struct ClientLibrarySettings { /// This message configures the settings for publishing [Google Cloud Client /// libraries]() /// generated from the service config. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Publishing { /// A list of API method settings, e.g. the behavior for methods that use the @@ -543,7 +536,6 @@ pub struct Publishing { pub rest_reference_documentation_uri: ::prost::alloc::string::String, } /// Settings for Java client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct JavaSettings { /// The package name to use in Java. Clobbers the java_package option @@ -574,16 +566,13 @@ pub struct JavaSettings { /// - google.pubsub.v1.Publisher: TopicAdmin /// - google.pubsub.v1.Subscriber: SubscriptionAdmin #[prost(map = "string, string", tag = "2")] - pub service_class_names: ::std::collections::HashMap< - ::prost::alloc::string::String, - ::prost::alloc::string::String, - >, + pub service_class_names: + ::std::collections::HashMap<::prost::alloc::string::String, ::prost::alloc::string::String>, /// Some settings. #[prost(message, optional, tag = "3")] pub common: ::core::option::Option, } /// Settings for C++ client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CppSettings { /// Some settings. @@ -591,7 +580,6 @@ pub struct CppSettings { pub common: ::core::option::Option, } /// Settings for Php client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PhpSettings { /// Some settings. @@ -599,7 +587,6 @@ pub struct PhpSettings { pub common: ::core::option::Option, } /// Settings for Python client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PythonSettings { /// Some settings. @@ -607,16 +594,13 @@ pub struct PythonSettings { pub common: ::core::option::Option, /// Experimental features to be included during client library generation. #[prost(message, optional, tag = "2")] - pub experimental_features: ::core::option::Option< - python_settings::ExperimentalFeatures, - >, + pub experimental_features: ::core::option::Option, } /// Nested message and enum types in `PythonSettings`. pub mod python_settings { /// Experimental features to be included during client library generation. /// These fields will be deprecated once the feature graduates and is enabled /// by default. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ExperimentalFeatures { /// Enables generation of asynchronous REST clients if `rest` transport is @@ -628,7 +612,6 @@ pub mod python_settings { } } /// Settings for Node client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct NodeSettings { /// Some settings. @@ -636,7 +619,6 @@ pub struct NodeSettings { pub common: ::core::option::Option, } /// Settings for Dotnet client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DotnetSettings { /// Some settings. @@ -648,20 +630,14 @@ pub struct DotnetSettings { /// fully-qualified.) /// Example: Subscriber to SubscriberServiceApi. #[prost(map = "string, string", tag = "2")] - pub renamed_services: ::std::collections::HashMap< - ::prost::alloc::string::String, - ::prost::alloc::string::String, - >, + pub renamed_services: ::std::collections::HashMap<::prost::alloc::string::String, ::prost::alloc::string::String>, /// Map from full resource types to the effective short name /// for the resource. This is used when otherwise resource /// named from different services would cause naming collisions. /// Example entry: /// "datalabeling.googleapis.com/Dataset": "DataLabelingDataset" #[prost(map = "string, string", tag = "3")] - pub renamed_resources: ::std::collections::HashMap< - ::prost::alloc::string::String, - ::prost::alloc::string::String, - >, + pub renamed_resources: ::std::collections::HashMap<::prost::alloc::string::String, ::prost::alloc::string::String>, /// List of full resource types to ignore during generation. /// This is typically used for API-specific Location resources, /// which should be handled by the generator as if they were actually @@ -672,9 +648,7 @@ pub struct DotnetSettings { /// Namespaces which must be aliased in snippets due to /// a known (but non-generator-predictable) naming collision #[prost(string, repeated, tag = "5")] - pub forced_namespace_aliases: ::prost::alloc::vec::Vec< - ::prost::alloc::string::String, - >, + pub forced_namespace_aliases: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, /// Method signatures (in the form "service.method(signature)") /// which are provided separately, so shouldn't be generated. /// Snippets *calling* these methods are still generated, however. @@ -682,7 +656,6 @@ pub struct DotnetSettings { pub handwritten_signatures: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Settings for Ruby client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RubySettings { /// Some settings. @@ -690,7 +663,6 @@ pub struct RubySettings { pub common: ::core::option::Option, } /// Settings for Go client libraries. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GoSettings { /// Some settings. @@ -698,7 +670,6 @@ pub struct GoSettings { pub common: ::core::option::Option, } /// Describes the generator configuration for a method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MethodSettings { /// The fully qualified name of the method, for which the options below apply. @@ -749,7 +720,6 @@ pub mod method_settings { /// All default values below are from those used in the client library /// generators (e.g. /// [Java]()). - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct LongRunning { /// Initial delay after which the first poll request will be made. @@ -800,16 +770,14 @@ impl ClientLibraryOrganization { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ClientLibraryOrganization::Unspecified => { - "CLIENT_LIBRARY_ORGANIZATION_UNSPECIFIED" - } - ClientLibraryOrganization::Cloud => "CLOUD", - ClientLibraryOrganization::Ads => "ADS", - ClientLibraryOrganization::Photos => "PHOTOS", - ClientLibraryOrganization::StreetView => "STREET_VIEW", - ClientLibraryOrganization::Shopping => "SHOPPING", - ClientLibraryOrganization::Geo => "GEO", - ClientLibraryOrganization::GenerativeAi => "GENERATIVE_AI", + Self::Unspecified => "CLIENT_LIBRARY_ORGANIZATION_UNSPECIFIED", + Self::Cloud => "CLOUD", + Self::Ads => "ADS", + Self::Photos => "PHOTOS", + Self::StreetView => "STREET_VIEW", + Self::Shopping => "SHOPPING", + Self::Geo => "GEO", + Self::GenerativeAi => "GENERATIVE_AI", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -847,11 +815,9 @@ impl ClientLibraryDestination { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ClientLibraryDestination::Unspecified => { - "CLIENT_LIBRARY_DESTINATION_UNSPECIFIED" - } - ClientLibraryDestination::Github => "GITHUB", - ClientLibraryDestination::PackageManager => "PACKAGE_MANAGER", + Self::Unspecified => "CLIENT_LIBRARY_DESTINATION_UNSPECIFIED", + Self::Github => "GITHUB", + Self::PackageManager => "PACKAGE_MANAGER", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -927,15 +893,15 @@ impl FieldBehavior { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - FieldBehavior::Unspecified => "FIELD_BEHAVIOR_UNSPECIFIED", - FieldBehavior::Optional => "OPTIONAL", - FieldBehavior::Required => "REQUIRED", - FieldBehavior::OutputOnly => "OUTPUT_ONLY", - FieldBehavior::InputOnly => "INPUT_ONLY", - FieldBehavior::Immutable => "IMMUTABLE", - FieldBehavior::UnorderedList => "UNORDERED_LIST", - FieldBehavior::NonEmptyDefault => "NON_EMPTY_DEFAULT", - FieldBehavior::Identifier => "IDENTIFIER", + Self::Unspecified => "FIELD_BEHAVIOR_UNSPECIFIED", + Self::Optional => "OPTIONAL", + Self::Required => "REQUIRED", + Self::OutputOnly => "OUTPUT_ONLY", + Self::InputOnly => "INPUT_ONLY", + Self::Immutable => "IMMUTABLE", + Self::UnorderedList => "UNORDERED_LIST", + Self::NonEmptyDefault => "NON_EMPTY_DEFAULT", + Self::Identifier => "IDENTIFIER", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1001,7 +967,6 @@ impl FieldBehavior { /// pattern: "folders/{folder}/logs/{log}" /// pattern: "organizations/{organization}/logs/{log}" /// pattern: "billingAccounts/{billing_account}/logs/{log}" -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ResourceDescriptor { /// The resource type. It must be in the format of @@ -1088,17 +1053,7 @@ pub struct ResourceDescriptor { pub mod resource_descriptor { /// A description of the historical or future-looking state of the /// resource pattern. - #[derive( - Clone, - Copy, - Debug, - PartialEq, - Eq, - Hash, - PartialOrd, - Ord, - ::prost::Enumeration - )] + #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] #[repr(i32)] pub enum History { /// The "unset" value. @@ -1118,9 +1073,9 @@ pub mod resource_descriptor { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - History::Unspecified => "HISTORY_UNSPECIFIED", - History::OriginallySinglePattern => "ORIGINALLY_SINGLE_PATTERN", - History::FutureMultiPattern => "FUTURE_MULTI_PATTERN", + Self::Unspecified => "HISTORY_UNSPECIFIED", + Self::OriginallySinglePattern => "ORIGINALLY_SINGLE_PATTERN", + Self::FutureMultiPattern => "FUTURE_MULTI_PATTERN", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1134,17 +1089,7 @@ pub mod resource_descriptor { } } /// A flag representing a specific style that a resource claims to conform to. - #[derive( - Clone, - Copy, - Debug, - PartialEq, - Eq, - Hash, - PartialOrd, - Ord, - ::prost::Enumeration - )] + #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] #[repr(i32)] pub enum Style { /// The unspecified value. Do not use. @@ -1166,8 +1111,8 @@ pub mod resource_descriptor { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Style::Unspecified => "STYLE_UNSPECIFIED", - Style::DeclarativeFriendly => "DECLARATIVE_FRIENDLY", + Self::Unspecified => "STYLE_UNSPECIFIED", + Self::DeclarativeFriendly => "DECLARATIVE_FRIENDLY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1182,7 +1127,6 @@ pub mod resource_descriptor { } /// Defines a proto annotation that describes a string field that refers to /// an API resource. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ResourceReference { /// The resource type that the annotated field references. @@ -1580,7 +1524,6 @@ pub struct ResourceReference { /// /// x-goog-request-params: /// table_location=instances/instance_bar&routing_id=prof_qux -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RoutingRule { /// A collection of Routing Parameter specifications. @@ -1593,7 +1536,6 @@ pub struct RoutingRule { pub routing_parameters: ::prost::alloc::vec::Vec, } /// A projection from an input message to the GRPC or REST header. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RoutingParameter { /// A request field to extract the header key-value pair from. @@ -1656,3 +1598,656 @@ pub struct RoutingParameter { #[prost(string, tag = "2")] pub path_template: ::prost::alloc::string::String, } +/// A description of a label. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct LabelDescriptor { + /// The label key. + #[prost(string, tag = "1")] + pub key: ::prost::alloc::string::String, + /// The type of data that can be assigned to the label. + #[prost(enumeration = "label_descriptor::ValueType", tag = "2")] + pub value_type: i32, + /// A human-readable description for the label. + #[prost(string, tag = "3")] + pub description: ::prost::alloc::string::String, +} +/// Nested message and enum types in `LabelDescriptor`. +pub mod label_descriptor { + /// Value types that can be used as label values. + #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] + #[repr(i32)] + pub enum ValueType { + /// A variable-length string. This is the default. + String = 0, + /// Boolean; true or false. + Bool = 1, + /// A 64-bit signed integer. + Int64 = 2, + } + impl ValueType { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::String => "STRING", + Self::Bool => "BOOL", + Self::Int64 => "INT64", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "STRING" => Some(Self::String), + "BOOL" => Some(Self::Bool), + "INT64" => Some(Self::Int64), + _ => None, + } + } + } +} +/// Defines a metric type and its schema. Once a metric descriptor is created, +/// deleting or altering it stops data collection and makes the metric type's +/// existing data unusable. +/// +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct MetricDescriptor { + /// The resource name of the metric descriptor. + #[prost(string, tag = "1")] + pub name: ::prost::alloc::string::String, + /// The metric type, including its DNS name prefix. The type is not + /// URL-encoded. All user-defined metric types have the DNS name + /// `custom.googleapis.com` or `external.googleapis.com`. Metric types should + /// use a natural hierarchical grouping. For example: + /// + /// "custom.googleapis.com/invoice/paid/amount" + /// "external.googleapis.com/prometheus/up" + /// "appengine.googleapis.com/http/server/response_latencies" + #[prost(string, tag = "8")] + pub r#type: ::prost::alloc::string::String, + /// The set of labels that can be used to describe a specific + /// instance of this metric type. For example, the + /// `appengine.googleapis.com/http/server/response_latencies` metric + /// type has a label for the HTTP response code, `response_code`, so + /// you can look at latencies for successful responses or just + /// for responses that failed. + #[prost(message, repeated, tag = "2")] + pub labels: ::prost::alloc::vec::Vec, + /// Whether the metric records instantaneous values, changes to a value, etc. + /// Some combinations of `metric_kind` and `value_type` might not be supported. + #[prost(enumeration = "metric_descriptor::MetricKind", tag = "3")] + pub metric_kind: i32, + /// Whether the measurement is an integer, a floating-point number, etc. + /// Some combinations of `metric_kind` and `value_type` might not be supported. + #[prost(enumeration = "metric_descriptor::ValueType", tag = "4")] + pub value_type: i32, + /// The units in which the metric value is reported. It is only applicable + /// if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The `unit` + /// defines the representation of the stored metric values. + /// + /// Different systems might scale the values to be more easily displayed (so a + /// value of `0.02kBy` _might_ be displayed as `20By`, and a value of + /// `3523kBy` _might_ be displayed as `3.5MBy`). However, if the `unit` is + /// `kBy`, then the value of the metric is always in thousands of bytes, no + /// matter how it might be displayed. + /// + /// If you want a custom metric to record the exact number of CPU-seconds used + /// by a job, you can create an `INT64 CUMULATIVE` metric whose `unit` is + /// `s{CPU}` (or equivalently `1s{CPU}` or just `s`). If the job uses 12,005 + /// CPU-seconds, then the value is written as `12005`. + /// + /// Alternatively, if you want a custom metric to record data in a more + /// granular way, you can create a `DOUBLE CUMULATIVE` metric whose `unit` is + /// `ks{CPU}`, and then write the value `12.005` (which is `12005/1000`), + /// or use `Kis{CPU}` and write `11.723` (which is `12005/1024`). + /// + /// The supported units are a subset of [The Unified Code for Units of + /// Measure]() standard: + /// + /// **Basic units (UNIT)** + /// + /// * `bit` bit + /// * `By` byte + /// * `s` second + /// * `min` minute + /// * `h` hour + /// * `d` day + /// * `1` dimensionless + /// + /// **Prefixes (PREFIX)** + /// + /// * `k` kilo (10^3) + /// * `M` mega (10^6) + /// * `G` giga (10^9) + /// * `T` tera (10^12) + /// * `P` peta (10^15) + /// * `E` exa (10^18) + /// * `Z` zetta (10^21) + /// * `Y` yotta (10^24) + /// + /// * `m` milli (10^-3) + /// * `u` micro (10^-6) + /// * `n` nano (10^-9) + /// * `p` pico (10^-12) + /// * `f` femto (10^-15) + /// * `a` atto (10^-18) + /// * `z` zepto (10^-21) + /// * `y` yocto (10^-24) + /// + /// * `Ki` kibi (2^10) + /// * `Mi` mebi (2^20) + /// * `Gi` gibi (2^30) + /// * `Ti` tebi (2^40) + /// * `Pi` pebi (2^50) + /// + /// **Grammar** + /// + /// The grammar also includes these connectors: + /// + /// * `/` division or ratio (as an infix operator). For examples, + /// `kBy/{email}` or `MiBy/10ms` (although you should almost never + /// have `/s` in a metric `unit`; rates should always be computed at + /// query time from the underlying cumulative or delta value). + /// * `.` multiplication or composition (as an infix operator). For + /// examples, `GBy.d` or `k{watt}.h`. + /// + /// The grammar for a unit is as follows: + /// + /// Expression = Component { "." Component } { "/" Component } ; + /// + /// Component = ( \[ PREFIX \] UNIT | "%" ) \[ Annotation \] + /// | Annotation + /// | "1" + /// ; + /// + /// Annotation = "{" NAME "}" ; + /// + /// Notes: + /// + /// * `Annotation` is just a comment if it follows a `UNIT`. If the annotation + /// is used alone, then the unit is equivalent to `1`. For examples, + /// `{request}/s == 1/s`, `By{transmitted}/s == By/s`. + /// * `NAME` is a sequence of non-blank printable ASCII characters not + /// containing `{` or `}`. + /// * `1` represents a unitary [dimensionless + /// unit]() of 1, such + /// as in `1/s`. It is typically used when none of the basic units are + /// appropriate. For example, "new users per day" can be represented as + /// `1/d` or `{new-users}/d` (and a metric value `5` would mean "5 new + /// users). Alternatively, "thousands of page views per day" would be + /// represented as `1000/d` or `k1/d` or `k{page_views}/d` (and a metric + /// value of `5.3` would mean "5300 page views per day"). + /// * `%` represents dimensionless value of 1/100, and annotates values giving + /// a percentage (so the metric values are typically in the range of 0..100, + /// and a metric value `3` means "3 percent"). + /// * `10^2.%` indicates a metric contains a ratio, typically in the range + /// 0..1, that will be multiplied by 100 and displayed as a percentage + /// (so a metric value `0.03` means "3 percent"). + #[prost(string, tag = "5")] + pub unit: ::prost::alloc::string::String, + /// A detailed description of the metric, which can be used in documentation. + #[prost(string, tag = "6")] + pub description: ::prost::alloc::string::String, + /// A concise name for the metric, which can be displayed in user interfaces. + /// Use sentence case without an ending period, for example "Request count". + /// This field is optional but it is recommended to be set for any metrics + /// associated with user-visible concepts, such as Quota. + #[prost(string, tag = "7")] + pub display_name: ::prost::alloc::string::String, + /// Optional. Metadata which can be used to guide usage of the metric. + #[prost(message, optional, tag = "10")] + pub metadata: ::core::option::Option, + /// Optional. The launch stage of the metric definition. + #[prost(enumeration = "LaunchStage", tag = "12")] + pub launch_stage: i32, + /// Read-only. If present, then a [time + /// series][google.monitoring.v3.TimeSeries], which is identified partially by + /// a metric type and a + /// [MonitoredResourceDescriptor][google.api.MonitoredResourceDescriptor], that + /// is associated with this metric type can only be associated with one of the + /// monitored resource types listed here. + #[prost(string, repeated, tag = "13")] + pub monitored_resource_types: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, +} +/// Nested message and enum types in `MetricDescriptor`. +pub mod metric_descriptor { + /// Additional annotations that can be used to guide the usage of a metric. + #[derive(Clone, Copy, PartialEq, ::prost::Message)] + pub struct MetricDescriptorMetadata { + /// Deprecated. Must use the + /// [MetricDescriptor.launch_stage][google.api.MetricDescriptor.launch_stage] + /// instead. + #[deprecated] + #[prost(enumeration = "super::LaunchStage", tag = "1")] + pub launch_stage: i32, + /// The sampling period of metric data points. For metrics which are written + /// periodically, consecutive data points are stored at this time interval, + /// excluding data loss due to errors. Metrics with a higher granularity have + /// a smaller sampling period. + #[prost(message, optional, tag = "2")] + pub sample_period: ::core::option::Option<::prost_types::Duration>, + /// The delay of data points caused by ingestion. Data points older than this + /// age are guaranteed to be ingested and available to be read, excluding + /// data loss due to errors. + #[prost(message, optional, tag = "3")] + pub ingest_delay: ::core::option::Option<::prost_types::Duration>, + } + /// The kind of measurement. It describes how the data is reported. + /// For information on setting the start time and end time based on + /// the MetricKind, see [TimeInterval][google.monitoring.v3.TimeInterval]. + #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] + #[repr(i32)] + pub enum MetricKind { + /// Do not use this default value. + Unspecified = 0, + /// An instantaneous measurement of a value. + Gauge = 1, + /// The change in a value during a time interval. + Delta = 2, + /// A value accumulated over a time interval. Cumulative + /// measurements in a time series should have the same start time + /// and increasing end times, until an event resets the cumulative + /// value to zero and sets a new start time for the following + /// points. + Cumulative = 3, + } + impl MetricKind { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::Unspecified => "METRIC_KIND_UNSPECIFIED", + Self::Gauge => "GAUGE", + Self::Delta => "DELTA", + Self::Cumulative => "CUMULATIVE", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "METRIC_KIND_UNSPECIFIED" => Some(Self::Unspecified), + "GAUGE" => Some(Self::Gauge), + "DELTA" => Some(Self::Delta), + "CUMULATIVE" => Some(Self::Cumulative), + _ => None, + } + } + } + /// The value type of a metric. + #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] + #[repr(i32)] + pub enum ValueType { + /// Do not use this default value. + Unspecified = 0, + /// The value is a boolean. + /// This value type can be used only if the metric kind is `GAUGE`. + Bool = 1, + /// The value is a signed 64-bit integer. + Int64 = 2, + /// The value is a double precision floating point number. + Double = 3, + /// The value is a text string. + /// This value type can be used only if the metric kind is `GAUGE`. + String = 4, + /// The value is a [`Distribution`][google.api.Distribution]. + Distribution = 5, + /// The value is money. + Money = 6, + } + impl ValueType { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::Unspecified => "VALUE_TYPE_UNSPECIFIED", + Self::Bool => "BOOL", + Self::Int64 => "INT64", + Self::Double => "DOUBLE", + Self::String => "STRING", + Self::Distribution => "DISTRIBUTION", + Self::Money => "MONEY", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "VALUE_TYPE_UNSPECIFIED" => Some(Self::Unspecified), + "BOOL" => Some(Self::Bool), + "INT64" => Some(Self::Int64), + "DOUBLE" => Some(Self::Double), + "STRING" => Some(Self::String), + "DISTRIBUTION" => Some(Self::Distribution), + "MONEY" => Some(Self::Money), + _ => None, + } + } + } +} +/// A specific metric, identified by specifying values for all of the +/// labels of a [`MetricDescriptor`][google.api.MetricDescriptor]. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct Metric { + /// An existing metric type, see + /// [google.api.MetricDescriptor][google.api.MetricDescriptor]. For example, + /// `custom.googleapis.com/invoice/paid/amount`. + #[prost(string, tag = "3")] + pub r#type: ::prost::alloc::string::String, + /// The set of label values that uniquely identify this metric. All + /// labels listed in the `MetricDescriptor` must be assigned values. + #[prost(map = "string, string", tag = "2")] + pub labels: ::std::collections::HashMap<::prost::alloc::string::String, ::prost::alloc::string::String>, +} +/// An object that describes the schema of a +/// [MonitoredResource][google.api.MonitoredResource] object using a type name +/// and a set of labels. For example, the monitored resource descriptor for +/// Google Compute Engine VM instances has a type of +/// `"gce_instance"` and specifies the use of the labels `"instance_id"` and +/// `"zone"` to identify particular VM instances. +/// +/// Different APIs can support different monitored resource types. APIs generally +/// provide a `list` method that returns the monitored resource descriptors used +/// by the API. +/// +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct MonitoredResourceDescriptor { + /// Optional. The resource name of the monitored resource descriptor: + /// `"projects/{project_id}/monitoredResourceDescriptors/{type}"` where + /// {type} is the value of the `type` field in this object and + /// {project_id} is a project ID that provides API-specific context for + /// accessing the type. APIs that do not use project information can use the + /// resource name format `"monitoredResourceDescriptors/{type}"`. + #[prost(string, tag = "5")] + pub name: ::prost::alloc::string::String, + /// Required. The monitored resource type. For example, the type + /// `"cloudsql_database"` represents databases in Google Cloud SQL. + /// For a list of types, see [Monitored resource + /// types]() + /// and [Logging resource + /// types](). + #[prost(string, tag = "1")] + pub r#type: ::prost::alloc::string::String, + /// Optional. A concise name for the monitored resource type that might be + /// displayed in user interfaces. It should be a Title Cased Noun Phrase, + /// without any article or other determiners. For example, + /// `"Google Cloud SQL Database"`. + #[prost(string, tag = "2")] + pub display_name: ::prost::alloc::string::String, + /// Optional. A detailed description of the monitored resource type that might + /// be used in documentation. + #[prost(string, tag = "3")] + pub description: ::prost::alloc::string::String, + /// Required. A set of labels used to describe instances of this monitored + /// resource type. For example, an individual Google Cloud SQL database is + /// identified by values for the labels `"database_id"` and `"zone"`. + #[prost(message, repeated, tag = "4")] + pub labels: ::prost::alloc::vec::Vec, + /// Optional. The launch stage of the monitored resource definition. + #[prost(enumeration = "LaunchStage", tag = "7")] + pub launch_stage: i32, +} +/// An object representing a resource that can be used for monitoring, logging, +/// billing, or other purposes. Examples include virtual machine instances, +/// databases, and storage devices such as disks. The `type` field identifies a +/// [MonitoredResourceDescriptor][google.api.MonitoredResourceDescriptor] object +/// that describes the resource's schema. Information in the `labels` field +/// identifies the actual resource and its attributes according to the schema. +/// For example, a particular Compute Engine VM instance could be represented by +/// the following object, because the +/// [MonitoredResourceDescriptor][google.api.MonitoredResourceDescriptor] for +/// `"gce_instance"` has labels +/// `"project_id"`, `"instance_id"` and `"zone"`: +/// +/// { "type": "gce_instance", +/// "labels": { "project_id": "my-project", +/// "instance_id": "12345678901234", +/// "zone": "us-central1-a" }} +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct MonitoredResource { + /// Required. The monitored resource type. This field must match + /// the `type` field of a + /// [MonitoredResourceDescriptor][google.api.MonitoredResourceDescriptor] + /// object. For example, the type of a Compute Engine VM instance is + /// `gce_instance`. Some descriptors include the service name in the type; for + /// example, the type of a Datastream stream is + /// `datastream.googleapis.com/Stream`. + #[prost(string, tag = "1")] + pub r#type: ::prost::alloc::string::String, + /// Required. Values for all of the labels listed in the associated monitored + /// resource descriptor. For example, Compute Engine VM instances use the + /// labels `"project_id"`, `"instance_id"`, and `"zone"`. + #[prost(map = "string, string", tag = "2")] + pub labels: ::std::collections::HashMap<::prost::alloc::string::String, ::prost::alloc::string::String>, +} +/// Auxiliary metadata for a [MonitoredResource][google.api.MonitoredResource] +/// object. [MonitoredResource][google.api.MonitoredResource] objects contain the +/// minimum set of information to uniquely identify a monitored resource +/// instance. There is some other useful auxiliary metadata. Monitoring and +/// Logging use an ingestion pipeline to extract metadata for cloud resources of +/// all types, and store the metadata in this message. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct MonitoredResourceMetadata { + /// Output only. Values for predefined system metadata labels. + /// System labels are a kind of metadata extracted by Google, including + /// "machine_image", "vpc", "subnet_id", + /// "security_group", "name", etc. + /// System label values can be only strings, Boolean values, or a list of + /// strings. For example: + /// + /// { "name": "my-test-instance", + /// "security_group": \["a", "b", "c"\], + /// "spot_instance": false } + #[prost(message, optional, tag = "1")] + pub system_labels: ::core::option::Option<::prost_types::Struct>, + /// Output only. A map of user-defined metadata labels. + #[prost(map = "string, string", tag = "2")] + pub user_labels: ::std::collections::HashMap<::prost::alloc::string::String, ::prost::alloc::string::String>, +} +/// `Distribution` contains summary statistics for a population of values. It +/// optionally contains a histogram representing the distribution of those values +/// across a set of buckets. +/// +/// The summary statistics are the count, mean, sum of the squared deviation from +/// the mean, the minimum, and the maximum of the set of population of values. +/// The histogram is based on a sequence of buckets and gives a count of values +/// that fall into each bucket. The boundaries of the buckets are given either +/// explicitly or by formulas for buckets of fixed or exponentially increasing +/// widths. +/// +/// Although it is not forbidden, it is generally a bad idea to include +/// non-finite values (infinities or NaNs) in the population of values, as this +/// will render the `mean` and `sum_of_squared_deviation` fields meaningless. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct Distribution { + /// The number of values in the population. Must be non-negative. This value + /// must equal the sum of the values in `bucket_counts` if a histogram is + /// provided. + #[prost(int64, tag = "1")] + pub count: i64, + /// The arithmetic mean of the values in the population. If `count` is zero + /// then this field must be zero. + #[prost(double, tag = "2")] + pub mean: f64, + /// The sum of squared deviations from the mean of the values in the + /// population. For values x_i this is: + /// + /// Sum[i=1..n]((x_i - mean)^2) + /// + /// Knuth, "The Art of Computer Programming", Vol. 2, page 232, 3rd edition + /// describes Welford's method for accumulating this sum in one pass. + /// + /// If `count` is zero then this field must be zero. + #[prost(double, tag = "3")] + pub sum_of_squared_deviation: f64, + /// If specified, contains the range of the population values. The field + /// must not be present if the `count` is zero. + #[prost(message, optional, tag = "4")] + pub range: ::core::option::Option, + /// Defines the histogram bucket boundaries. If the distribution does not + /// contain a histogram, then omit this field. + #[prost(message, optional, tag = "6")] + pub bucket_options: ::core::option::Option, + /// The number of values in each bucket of the histogram, as described in + /// `bucket_options`. If the distribution does not have a histogram, then omit + /// this field. If there is a histogram, then the sum of the values in + /// `bucket_counts` must equal the value in the `count` field of the + /// distribution. + /// + /// If present, `bucket_counts` should contain N values, where N is the number + /// of buckets specified in `bucket_options`. If you supply fewer than N + /// values, the remaining values are assumed to be 0. + /// + /// The order of the values in `bucket_counts` follows the bucket numbering + /// schemes described for the three bucket types. The first value must be the + /// count for the underflow bucket (number 0). The next N-2 values are the + /// counts for the finite buckets (number 1 through N-2). The N'th value in + /// `bucket_counts` is the count for the overflow bucket (number N-1). + #[prost(int64, repeated, tag = "7")] + pub bucket_counts: ::prost::alloc::vec::Vec, + /// Must be in increasing order of `value` field. + #[prost(message, repeated, tag = "10")] + pub exemplars: ::prost::alloc::vec::Vec, +} +/// Nested message and enum types in `Distribution`. +pub mod distribution { + /// The range of the population values. + #[derive(Clone, Copy, PartialEq, ::prost::Message)] + pub struct Range { + /// The minimum of the population values. + #[prost(double, tag = "1")] + pub min: f64, + /// The maximum of the population values. + #[prost(double, tag = "2")] + pub max: f64, + } + /// `BucketOptions` describes the bucket boundaries used to create a histogram + /// for the distribution. The buckets can be in a linear sequence, an + /// exponential sequence, or each bucket can be specified explicitly. + /// `BucketOptions` does not include the number of values in each bucket. + /// + /// A bucket has an inclusive lower bound and exclusive upper bound for the + /// values that are counted for that bucket. The upper bound of a bucket must + /// be strictly greater than the lower bound. The sequence of N buckets for a + /// distribution consists of an underflow bucket (number 0), zero or more + /// finite buckets (number 1 through N - 2) and an overflow bucket (number N - + /// 1). The buckets are contiguous: the lower bound of bucket i (i > 0) is the + /// same as the upper bound of bucket i - 1. The buckets span the whole range + /// of finite values: lower bound of the underflow bucket is -infinity and the + /// upper bound of the overflow bucket is +infinity. The finite buckets are + /// so-called because both bounds are finite. + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct BucketOptions { + /// Exactly one of these three fields must be set. + #[prost(oneof = "bucket_options::Options", tags = "1, 2, 3")] + pub options: ::core::option::Option, + } + /// Nested message and enum types in `BucketOptions`. + pub mod bucket_options { + /// Specifies a linear sequence of buckets that all have the same width + /// (except overflow and underflow). Each bucket represents a constant + /// absolute uncertainty on the specific value in the bucket. + /// + /// There are `num_finite_buckets + 2` (= N) buckets. Bucket `i` has the + /// following boundaries: + /// + /// Upper bound (0 <= i < N-1): offset + (width * i). + /// + /// Lower bound (1 <= i < N): offset + (width * (i - 1)). + #[derive(Clone, Copy, PartialEq, ::prost::Message)] + pub struct Linear { + /// Must be greater than 0. + #[prost(int32, tag = "1")] + pub num_finite_buckets: i32, + /// Must be greater than 0. + #[prost(double, tag = "2")] + pub width: f64, + /// Lower bound of the first bucket. + #[prost(double, tag = "3")] + pub offset: f64, + } + /// Specifies an exponential sequence of buckets that have a width that is + /// proportional to the value of the lower bound. Each bucket represents a + /// constant relative uncertainty on a specific value in the bucket. + /// + /// There are `num_finite_buckets + 2` (= N) buckets. Bucket `i` has the + /// following boundaries: + /// + /// Upper bound (0 <= i < N-1): scale * (growth_factor ^ i). + /// + /// Lower bound (1 <= i < N): scale * (growth_factor ^ (i - 1)). + #[derive(Clone, Copy, PartialEq, ::prost::Message)] + pub struct Exponential { + /// Must be greater than 0. + #[prost(int32, tag = "1")] + pub num_finite_buckets: i32, + /// Must be greater than 1. + #[prost(double, tag = "2")] + pub growth_factor: f64, + /// Must be greater than 0. + #[prost(double, tag = "3")] + pub scale: f64, + } + /// Specifies a set of buckets with arbitrary widths. + /// + /// There are `size(bounds) + 1` (= N) buckets. Bucket `i` has the following + /// boundaries: + /// + /// Upper bound (0 <= i < N-1): bounds\[i\] + /// Lower bound (1 <= i < N); bounds\[i - 1\] + /// + /// The `bounds` field must contain at least one element. If `bounds` has + /// only one element, then there are no finite buckets, and that single + /// element is the common boundary of the overflow and underflow buckets. + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct Explicit { + /// The values must be monotonically increasing. + #[prost(double, repeated, tag = "1")] + pub bounds: ::prost::alloc::vec::Vec, + } + /// Exactly one of these three fields must be set. + #[derive(Clone, PartialEq, ::prost::Oneof)] + pub enum Options { + /// The linear bucket. + #[prost(message, tag = "1")] + LinearBuckets(Linear), + /// The exponential buckets. + #[prost(message, tag = "2")] + ExponentialBuckets(Exponential), + /// The explicit buckets. + #[prost(message, tag = "3")] + ExplicitBuckets(Explicit), + } + } + /// Exemplars are example points that may be used to annotate aggregated + /// distribution values. They are metadata that gives information about a + /// particular value added to a Distribution bucket, such as a trace ID that + /// was active when a value was added. They may contain further information, + /// such as a example values and timestamps, origin, etc. + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct Exemplar { + /// Value of the exemplar point. This value determines to which bucket the + /// exemplar belongs. + #[prost(double, tag = "1")] + pub value: f64, + /// The observation (sampling) time of the above value. + #[prost(message, optional, tag = "2")] + pub timestamp: ::core::option::Option<::prost_types::Timestamp>, + /// Contextual information about the example value. Examples are: + /// + /// Trace: type.googleapis.com/google.monitoring.v3.SpanContext + /// + /// Literal string: type.googleapis.com/google.protobuf.StringValue + /// + /// Labels dropped during aggregation: + /// type.googleapis.com/google.monitoring.v3.DroppedLabels + /// + /// There may be only a single attachment of any given message type in a + /// single exemplar, and this is enforced by the system. + #[prost(message, repeated, tag = "3")] + pub attachments: ::prost::alloc::vec::Vec<::prost_types::Any>, + } +} diff --git a/googleapis/src/google.cloud.bigquery.storage.v1.rs b/googleapis/src/google.cloud.bigquery.storage.v1.rs index d0842b97..f4035e81 100644 --- a/googleapis/src/google.cloud.bigquery.storage.v1.rs +++ b/googleapis/src/google.cloud.bigquery.storage.v1.rs @@ -5,7 +5,6 @@ /// /// /// See code samples on how this message can be deserialized. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ArrowSchema { /// IPC serialized Arrow schema. @@ -13,7 +12,6 @@ pub struct ArrowSchema { pub serialized_schema: ::prost::alloc::vec::Vec, } /// Arrow RecordBatch. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ArrowRecordBatch { /// IPC-serialized Arrow RecordBatch. @@ -26,7 +24,6 @@ pub struct ArrowRecordBatch { pub row_count: i64, } /// Contains options specific to Arrow Serialization. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ArrowSerializationOptions { /// The compression codec to use for Arrow buffers in serialized record @@ -54,9 +51,9 @@ pub mod arrow_serialization_options { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - CompressionCodec::CompressionUnspecified => "COMPRESSION_UNSPECIFIED", - CompressionCodec::Lz4Frame => "LZ4_FRAME", - CompressionCodec::Zstd => "ZSTD", + Self::CompressionUnspecified => "COMPRESSION_UNSPECIFIED", + Self::Lz4Frame => "LZ4_FRAME", + Self::Zstd => "ZSTD", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -71,7 +68,6 @@ pub mod arrow_serialization_options { } } /// Avro schema. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AvroSchema { /// Json serialized schema, as described at @@ -80,7 +76,6 @@ pub struct AvroSchema { pub schema: ::prost::alloc::string::String, } /// Avro rows. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AvroRows { /// Binary serialized rows in a block. @@ -93,7 +88,6 @@ pub struct AvroRows { pub row_count: i64, } /// Contains options specific to Avro Serialization. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AvroSerializationOptions { /// Enable displayName attribute in Avro schema. @@ -110,7 +104,6 @@ pub struct AvroSerializationOptions { pub enable_display_name_attribute: bool, } /// ProtoSchema describes the schema of the serialized protocol buffer data rows. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ProtoSchema { /// Descriptor for input message. The provided descriptor must be self @@ -125,7 +118,6 @@ pub struct ProtoSchema { #[prost(message, optional, tag = "1")] pub proto_descriptor: ::core::option::Option<::prost_types::DescriptorProto>, } -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ProtoRows { /// A sequence of rows serialized as a Protocol Buffer. @@ -138,7 +130,6 @@ pub struct ProtoRows { /// Schema of a table. This schema is a subset of /// google.cloud.bigquery.v2.TableSchema containing information necessary to /// generate valid message to write to BigQuery. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TableSchema { /// Describes the fields in a table. @@ -146,7 +137,6 @@ pub struct TableSchema { pub fields: ::prost::alloc::vec::Vec, } /// TableFieldSchema defines a single field/column within a table schema. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TableFieldSchema { /// Required. The field name. The name must contain only letters (a-z, A-Z), @@ -234,7 +224,6 @@ pub struct TableFieldSchema { /// Nested message and enum types in `TableFieldSchema`. pub mod table_field_schema { /// Represents the type of a field element. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct FieldElementType { /// Required. The type of a field element. @@ -286,23 +275,23 @@ pub mod table_field_schema { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Type::Unspecified => "TYPE_UNSPECIFIED", - Type::String => "STRING", - Type::Int64 => "INT64", - Type::Double => "DOUBLE", - Type::Struct => "STRUCT", - Type::Bytes => "BYTES", - Type::Bool => "BOOL", - Type::Timestamp => "TIMESTAMP", - Type::Date => "DATE", - Type::Time => "TIME", - Type::Datetime => "DATETIME", - Type::Geography => "GEOGRAPHY", - Type::Numeric => "NUMERIC", - Type::Bignumeric => "BIGNUMERIC", - Type::Interval => "INTERVAL", - Type::Json => "JSON", - Type::Range => "RANGE", + Self::Unspecified => "TYPE_UNSPECIFIED", + Self::String => "STRING", + Self::Int64 => "INT64", + Self::Double => "DOUBLE", + Self::Struct => "STRUCT", + Self::Bytes => "BYTES", + Self::Bool => "BOOL", + Self::Timestamp => "TIMESTAMP", + Self::Date => "DATE", + Self::Time => "TIME", + Self::Datetime => "DATETIME", + Self::Geography => "GEOGRAPHY", + Self::Numeric => "NUMERIC", + Self::Bignumeric => "BIGNUMERIC", + Self::Interval => "INTERVAL", + Self::Json => "JSON", + Self::Range => "RANGE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -345,10 +334,10 @@ pub mod table_field_schema { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Mode::Unspecified => "MODE_UNSPECIFIED", - Mode::Nullable => "NULLABLE", - Mode::Required => "REQUIRED", - Mode::Repeated => "REPEATED", + Self::Unspecified => "MODE_UNSPECIFIED", + Self::Nullable => "NULLABLE", + Self::Required => "REQUIRED", + Self::Repeated => "REPEATED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -364,7 +353,6 @@ pub mod table_field_schema { } } /// Information about the ReadSession. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadSession { /// Output only. Unique identifier for the session, in the form @@ -434,7 +422,6 @@ pub struct ReadSession { /// Nested message and enum types in `ReadSession`. pub mod read_session { /// Additional attributes when reading a table. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct TableModifiers { /// The snapshot time of the table. If not set, interpreted as now. @@ -442,7 +429,6 @@ pub mod read_session { pub snapshot_time: ::core::option::Option<::prost_types::Timestamp>, } /// Options dictating how we read a table. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TableReadOptions { /// Optional. The names of the fields in the table to be returned. If no @@ -546,8 +532,8 @@ pub mod read_session { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ResponseCompressionCodec::Unspecified => "RESPONSE_COMPRESSION_CODEC_UNSPECIFIED", - ResponseCompressionCodec::Lz4 => "RESPONSE_COMPRESSION_CODEC_LZ4", + Self::Unspecified => "RESPONSE_COMPRESSION_CODEC_UNSPECIFIED", + Self::Lz4 => "RESPONSE_COMPRESSION_CODEC_LZ4", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -559,7 +545,6 @@ pub mod read_session { } } } - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum OutputFormatSerializationOptions { /// Optional. Options specific to the Apache Arrow output format. @@ -573,7 +558,6 @@ pub mod read_session { /// The schema for the read. If read_options.selected_fields is set, the /// schema may be different from the table schema as it will only contain /// the selected fields. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Schema { /// Output only. Avro schema. @@ -587,7 +571,6 @@ pub mod read_session { /// Information about a single stream that gets data out of the storage system. /// Most of the information about `ReadStream` instances is aggregated, making /// `ReadStream` lightweight. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadStream { /// Output only. Name of the stream, in the form @@ -596,7 +579,6 @@ pub struct ReadStream { pub name: ::prost::alloc::string::String, } /// Information about a single stream that gets data inside the storage system. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct WriteStream { /// Output only. Name of the stream, in the form @@ -654,10 +636,10 @@ pub mod write_stream { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Type::Unspecified => "TYPE_UNSPECIFIED", - Type::Committed => "COMMITTED", - Type::Pending => "PENDING", - Type::Buffered => "BUFFERED", + Self::Unspecified => "TYPE_UNSPECIFIED", + Self::Committed => "COMMITTED", + Self::Pending => "PENDING", + Self::Buffered => "BUFFERED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -688,8 +670,8 @@ pub mod write_stream { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - WriteMode::Unspecified => "WRITE_MODE_UNSPECIFIED", - WriteMode::Insert => "INSERT", + Self::Unspecified => "WRITE_MODE_UNSPECIFIED", + Self::Insert => "INSERT", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -722,9 +704,9 @@ impl DataFormat { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - DataFormat::Unspecified => "DATA_FORMAT_UNSPECIFIED", - DataFormat::Avro => "AVRO", - DataFormat::Arrow => "ARROW", + Self::Unspecified => "DATA_FORMAT_UNSPECIFIED", + Self::Avro => "AVRO", + Self::Arrow => "ARROW", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -760,9 +742,9 @@ impl WriteStreamView { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - WriteStreamView::Unspecified => "WRITE_STREAM_VIEW_UNSPECIFIED", - WriteStreamView::Basic => "BASIC", - WriteStreamView::Full => "FULL", + Self::Unspecified => "WRITE_STREAM_VIEW_UNSPECIFIED", + Self::Basic => "BASIC", + Self::Full => "FULL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -776,7 +758,6 @@ impl WriteStreamView { } } /// Request message for `CreateReadSession`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateReadSessionRequest { /// Required. The request project that owns the session, in the form of @@ -810,7 +791,6 @@ pub struct CreateReadSessionRequest { pub preferred_min_stream_count: i32, } /// Request message for `ReadRows`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadRowsRequest { /// Required. Stream to read rows from. @@ -823,7 +803,6 @@ pub struct ReadRowsRequest { pub offset: i64, } /// Information on if the current connection is being throttled. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ThrottleState { /// How much this connection is being throttled. Zero means no throttling, @@ -832,7 +811,6 @@ pub struct ThrottleState { pub throttle_percent: i32, } /// Estimated stream statistics for a given read Stream. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct StreamStats { /// Represents the progress of the current stream. @@ -841,7 +819,6 @@ pub struct StreamStats { } /// Nested message and enum types in `StreamStats`. pub mod stream_stats { - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct Progress { /// The fraction of rows assigned to the stream that have been processed by @@ -866,7 +843,6 @@ pub mod stream_stats { } /// Response from calling `ReadRows` may include row data, progress and /// throttling information. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadRowsResponse { /// Number of serialized rows in the rows block. @@ -909,7 +885,6 @@ pub struct ReadRowsResponse { /// Nested message and enum types in `ReadRowsResponse`. pub mod read_rows_response { /// Row data is returned in format specified during session creation. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Rows { /// Serialized row data in AVRO format. @@ -924,7 +899,6 @@ pub mod read_rows_response { /// the selected fields. This schema is equivalent to the one returned by /// CreateSession. This field is only populated in the first ReadRowsResponse /// RPC. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Schema { /// Output only. Avro schema. @@ -936,7 +910,6 @@ pub mod read_rows_response { } } /// Request message for `SplitReadStream`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct SplitReadStreamRequest { /// Required. Name of the stream to split. @@ -953,7 +926,6 @@ pub struct SplitReadStreamRequest { pub fraction: f64, } /// Response message for `SplitReadStream`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct SplitReadStreamResponse { /// Primary stream, which contains the beginning portion of @@ -967,7 +939,6 @@ pub struct SplitReadStreamResponse { pub remainder_stream: ::core::option::Option, } /// Request message for `CreateWriteStream`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateWriteStreamRequest { /// Required. Reference to the table to which the stream belongs, in the format @@ -987,7 +958,6 @@ pub struct CreateWriteStreamRequest { /// /// The size of a single AppendRowsRequest must be less than 10 MB in size. /// Requests larger than this return an error, typically `INVALID_ARGUMENT`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AppendRowsRequest { /// Required. The write_stream identifies the append operation. It must be @@ -1079,7 +1049,6 @@ pub struct AppendRowsRequest { pub mod append_rows_request { /// ProtoData contains the data rows and schema when constructing append /// requests. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ProtoData { /// The protocol buffer schema used to serialize the data. Provide this value @@ -1121,9 +1090,9 @@ pub mod append_rows_request { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - MissingValueInterpretation::Unspecified => "MISSING_VALUE_INTERPRETATION_UNSPECIFIED", - MissingValueInterpretation::NullValue => "NULL_VALUE", - MissingValueInterpretation::DefaultValue => "DEFAULT_VALUE", + Self::Unspecified => "MISSING_VALUE_INTERPRETATION_UNSPECIFIED", + Self::NullValue => "NULL_VALUE", + Self::DefaultValue => "DEFAULT_VALUE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1140,7 +1109,6 @@ pub mod append_rows_request { /// request and currently, it will be ignored if specified in following /// requests. Following requests must have data in the same format as the /// initial request. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Rows { /// Rows in proto format. @@ -1149,7 +1117,6 @@ pub mod append_rows_request { } } /// Response message for `AppendRows`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AppendRowsResponse { /// If backend detects a schema update, pass it to user so that user can @@ -1172,7 +1139,6 @@ pub struct AppendRowsResponse { /// Nested message and enum types in `AppendRowsResponse`. pub mod append_rows_response { /// AppendResult is returned for successful append requests. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AppendResult { /// The row offset at which the last append occurred. The offset will not be @@ -1180,7 +1146,6 @@ pub mod append_rows_response { #[prost(message, optional, tag = "1")] pub offset: ::core::option::Option, } - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Response { /// Result if the append is successful. @@ -1211,7 +1176,6 @@ pub mod append_rows_response { } } /// Request message for `GetWriteStreamRequest`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetWriteStreamRequest { /// Required. Name of the stream to get, in the form of @@ -1224,7 +1188,6 @@ pub struct GetWriteStreamRequest { pub view: i32, } /// Request message for `BatchCommitWriteStreams`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchCommitWriteStreamsRequest { /// Required. Parent table that all the streams should belong to, in the form @@ -1236,7 +1199,6 @@ pub struct BatchCommitWriteStreamsRequest { pub write_streams: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Response message for `BatchCommitWriteStreams`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchCommitWriteStreamsResponse { /// The time at which streams were committed in microseconds granularity. @@ -1253,7 +1215,6 @@ pub struct BatchCommitWriteStreamsResponse { pub stream_errors: ::prost::alloc::vec::Vec, } /// Request message for invoking `FinalizeWriteStream`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct FinalizeWriteStreamRequest { /// Required. Name of the stream to finalize, in the form of @@ -1262,7 +1223,6 @@ pub struct FinalizeWriteStreamRequest { pub name: ::prost::alloc::string::String, } /// Response message for `FinalizeWriteStream`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct FinalizeWriteStreamResponse { /// Number of rows in the finalized stream. @@ -1270,7 +1230,6 @@ pub struct FinalizeWriteStreamResponse { pub row_count: i64, } /// Request message for `FlushRows`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct FlushRowsRequest { /// Required. The stream that is the target of the flush operation. @@ -1282,7 +1241,6 @@ pub struct FlushRowsRequest { pub offset: ::core::option::Option, } /// Respond message for `FlushRows`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct FlushRowsResponse { /// The rows before this offset (including this offset) are flushed. @@ -1293,7 +1251,6 @@ pub struct FlushRowsResponse { /// as error details in the returned rpc Status. In particular, the use of error /// codes allows more structured error handling, and reduces the need to evaluate /// unstructured error text strings. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct StorageError { /// BigQuery Storage specific error code. @@ -1356,21 +1313,21 @@ pub mod storage_error { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - StorageErrorCode::Unspecified => "STORAGE_ERROR_CODE_UNSPECIFIED", - StorageErrorCode::TableNotFound => "TABLE_NOT_FOUND", - StorageErrorCode::StreamAlreadyCommitted => "STREAM_ALREADY_COMMITTED", - StorageErrorCode::StreamNotFound => "STREAM_NOT_FOUND", - StorageErrorCode::InvalidStreamType => "INVALID_STREAM_TYPE", - StorageErrorCode::InvalidStreamState => "INVALID_STREAM_STATE", - StorageErrorCode::StreamFinalized => "STREAM_FINALIZED", - StorageErrorCode::SchemaMismatchExtraFields => "SCHEMA_MISMATCH_EXTRA_FIELDS", - StorageErrorCode::OffsetAlreadyExists => "OFFSET_ALREADY_EXISTS", - StorageErrorCode::OffsetOutOfRange => "OFFSET_OUT_OF_RANGE", - StorageErrorCode::CmekNotProvided => "CMEK_NOT_PROVIDED", - StorageErrorCode::InvalidCmekProvided => "INVALID_CMEK_PROVIDED", - StorageErrorCode::CmekEncryptionError => "CMEK_ENCRYPTION_ERROR", - StorageErrorCode::KmsServiceError => "KMS_SERVICE_ERROR", - StorageErrorCode::KmsPermissionDenied => "KMS_PERMISSION_DENIED", + Self::Unspecified => "STORAGE_ERROR_CODE_UNSPECIFIED", + Self::TableNotFound => "TABLE_NOT_FOUND", + Self::StreamAlreadyCommitted => "STREAM_ALREADY_COMMITTED", + Self::StreamNotFound => "STREAM_NOT_FOUND", + Self::InvalidStreamType => "INVALID_STREAM_TYPE", + Self::InvalidStreamState => "INVALID_STREAM_STATE", + Self::StreamFinalized => "STREAM_FINALIZED", + Self::SchemaMismatchExtraFields => "SCHEMA_MISMATCH_EXTRA_FIELDS", + Self::OffsetAlreadyExists => "OFFSET_ALREADY_EXISTS", + Self::OffsetOutOfRange => "OFFSET_OUT_OF_RANGE", + Self::CmekNotProvided => "CMEK_NOT_PROVIDED", + Self::InvalidCmekProvided => "INVALID_CMEK_PROVIDED", + Self::CmekEncryptionError => "CMEK_ENCRYPTION_ERROR", + Self::KmsServiceError => "KMS_SERVICE_ERROR", + Self::KmsPermissionDenied => "KMS_PERMISSION_DENIED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1397,7 +1354,6 @@ pub mod storage_error { } } /// The message that presents row level error info in a request. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RowError { /// Index of the malformed row in the request. @@ -1428,8 +1384,8 @@ pub mod row_error { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - RowErrorCode::Unspecified => "ROW_ERROR_CODE_UNSPECIFIED", - RowErrorCode::FieldsError => "FIELDS_ERROR", + Self::Unspecified => "ROW_ERROR_CODE_UNSPECIFIED", + Self::FieldsError => "FIELDS_ERROR", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1444,7 +1400,13 @@ pub mod row_error { } /// Generated client implementations. pub mod big_query_read_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// BigQuery Read API. @@ -1469,8 +1431,8 @@ pub mod big_query_read_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -1488,7 +1450,8 @@ pub mod big_query_read_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { BigQueryReadClient::new(InterceptedService::new(inner, interceptor)) } @@ -1546,9 +1509,10 @@ pub mod big_query_read_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.cloud.bigquery.storage.v1.BigQueryRead/CreateReadSession", @@ -1572,9 +1536,10 @@ pub mod big_query_read_client { request: impl tonic::IntoRequest, ) -> std::result::Result>, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.bigquery.storage.v1.BigQueryRead/ReadRows"); let mut req = request.into_request(); @@ -1598,9 +1563,10 @@ pub mod big_query_read_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.bigquery.storage.v1.BigQueryRead/SplitReadStream"); @@ -1615,7 +1581,13 @@ pub mod big_query_read_client { } /// Generated client implementations. pub mod big_query_write_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// BigQuery Write API. @@ -1643,8 +1615,8 @@ pub mod big_query_write_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -1662,7 +1634,8 @@ pub mod big_query_write_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { BigQueryWriteClient::new(InterceptedService::new(inner, interceptor)) } @@ -1707,9 +1680,10 @@ pub mod big_query_write_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.cloud.bigquery.storage.v1.BigQueryWrite/CreateWriteStream", @@ -1757,9 +1731,10 @@ pub mod big_query_write_client { request: impl tonic::IntoStreamingRequest, ) -> std::result::Result>, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.bigquery.storage.v1.BigQueryWrite/AppendRows"); @@ -1773,9 +1748,10 @@ pub mod big_query_write_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.bigquery.storage.v1.BigQueryWrite/GetWriteStream"); @@ -1792,9 +1768,10 @@ pub mod big_query_write_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.cloud.bigquery.storage.v1.BigQueryWrite/FinalizeWriteStream", @@ -1816,9 +1793,10 @@ pub mod big_query_write_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.cloud.bigquery.storage.v1.BigQueryWrite/BatchCommitWriteStreams", @@ -1842,9 +1820,10 @@ pub mod big_query_write_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.bigquery.storage.v1.BigQueryWrite/FlushRows"); diff --git a/googleapis/src/google.cloud.kms.v1.rs b/googleapis/src/google.cloud.kms.v1.rs index c1216f1b..1e913a58 100644 --- a/googleapis/src/google.cloud.kms.v1.rs +++ b/googleapis/src/google.cloud.kms.v1.rs @@ -1,7 +1,6 @@ // This file is @generated by prost-build. /// A [KeyRing][google.cloud.kms.v1.KeyRing] is a toplevel logical grouping of /// [CryptoKeys][google.cloud.kms.v1.CryptoKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct KeyRing { /// Output only. The resource name for the @@ -20,7 +19,6 @@ pub struct KeyRing { /// A [CryptoKey][google.cloud.kms.v1.CryptoKey] is made up of zero or more /// [versions][google.cloud.kms.v1.CryptoKeyVersion], which represent the actual /// key material used in cryptographic operations. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CryptoKey { /// Output only. The resource name for this @@ -162,12 +160,12 @@ pub mod crypto_key { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - CryptoKeyPurpose::Unspecified => "CRYPTO_KEY_PURPOSE_UNSPECIFIED", - CryptoKeyPurpose::EncryptDecrypt => "ENCRYPT_DECRYPT", - CryptoKeyPurpose::AsymmetricSign => "ASYMMETRIC_SIGN", - CryptoKeyPurpose::AsymmetricDecrypt => "ASYMMETRIC_DECRYPT", - CryptoKeyPurpose::RawEncryptDecrypt => "RAW_ENCRYPT_DECRYPT", - CryptoKeyPurpose::Mac => "MAC", + Self::Unspecified => "CRYPTO_KEY_PURPOSE_UNSPECIFIED", + Self::EncryptDecrypt => "ENCRYPT_DECRYPT", + Self::AsymmetricSign => "ASYMMETRIC_SIGN", + Self::AsymmetricDecrypt => "ASYMMETRIC_DECRYPT", + Self::RawEncryptDecrypt => "RAW_ENCRYPT_DECRYPT", + Self::Mac => "MAC", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -184,7 +182,6 @@ pub mod crypto_key { } } /// Controls the rate of automatic rotation. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum RotationSchedule { /// [next_rotation_time][google.cloud.kms.v1.CryptoKey.next_rotation_time] @@ -209,7 +206,6 @@ pub mod crypto_key { /// with /// [CreateCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.CreateCryptoKeyVersion] /// or automatically as a result of auto-rotation. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct CryptoKeyVersionTemplate { /// [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] to use when creating @@ -234,7 +230,6 @@ pub struct CryptoKeyVersionTemplate { /// Contains an HSM-generated attestation about a key operation. For more /// information, see \[Verifying attestations\] /// (). -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct KeyOperationAttestation { /// Output only. The format of the attestation data. @@ -253,7 +248,6 @@ pub mod key_operation_attestation { /// Certificate chains needed to verify the attestation. /// Certificates in chains are PEM-encoded and are ordered based on /// - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CertificateChains { /// Cavium certificate chain corresponding to the attestation. @@ -289,9 +283,9 @@ pub mod key_operation_attestation { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - AttestationFormat::Unspecified => "ATTESTATION_FORMAT_UNSPECIFIED", - AttestationFormat::CaviumV1Compressed => "CAVIUM_V1_COMPRESSED", - AttestationFormat::CaviumV2Compressed => "CAVIUM_V2_COMPRESSED", + Self::Unspecified => "ATTESTATION_FORMAT_UNSPECIFIED", + Self::CaviumV1Compressed => "CAVIUM_V1_COMPRESSED", + Self::CaviumV2Compressed => "CAVIUM_V2_COMPRESSED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -316,7 +310,6 @@ pub mod key_operation_attestation { /// [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] can never be viewed /// or exported. It can only be used to encrypt, decrypt, or sign data when an /// authorized user or application invokes Cloud KMS. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CryptoKeyVersion { /// Output only. The resource name for this @@ -546,42 +539,42 @@ pub mod crypto_key_version { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - CryptoKeyVersionAlgorithm::Unspecified => "CRYPTO_KEY_VERSION_ALGORITHM_UNSPECIFIED", - CryptoKeyVersionAlgorithm::GoogleSymmetricEncryption => "GOOGLE_SYMMETRIC_ENCRYPTION", - CryptoKeyVersionAlgorithm::Aes128Gcm => "AES_128_GCM", - CryptoKeyVersionAlgorithm::Aes256Gcm => "AES_256_GCM", - CryptoKeyVersionAlgorithm::Aes128Cbc => "AES_128_CBC", - CryptoKeyVersionAlgorithm::Aes256Cbc => "AES_256_CBC", - CryptoKeyVersionAlgorithm::Aes128Ctr => "AES_128_CTR", - CryptoKeyVersionAlgorithm::Aes256Ctr => "AES_256_CTR", - CryptoKeyVersionAlgorithm::RsaSignPss2048Sha256 => "RSA_SIGN_PSS_2048_SHA256", - CryptoKeyVersionAlgorithm::RsaSignPss3072Sha256 => "RSA_SIGN_PSS_3072_SHA256", - CryptoKeyVersionAlgorithm::RsaSignPss4096Sha256 => "RSA_SIGN_PSS_4096_SHA256", - CryptoKeyVersionAlgorithm::RsaSignPss4096Sha512 => "RSA_SIGN_PSS_4096_SHA512", - CryptoKeyVersionAlgorithm::RsaSignPkcs12048Sha256 => "RSA_SIGN_PKCS1_2048_SHA256", - CryptoKeyVersionAlgorithm::RsaSignPkcs13072Sha256 => "RSA_SIGN_PKCS1_3072_SHA256", - CryptoKeyVersionAlgorithm::RsaSignPkcs14096Sha256 => "RSA_SIGN_PKCS1_4096_SHA256", - CryptoKeyVersionAlgorithm::RsaSignPkcs14096Sha512 => "RSA_SIGN_PKCS1_4096_SHA512", - CryptoKeyVersionAlgorithm::RsaSignRawPkcs12048 => "RSA_SIGN_RAW_PKCS1_2048", - CryptoKeyVersionAlgorithm::RsaSignRawPkcs13072 => "RSA_SIGN_RAW_PKCS1_3072", - CryptoKeyVersionAlgorithm::RsaSignRawPkcs14096 => "RSA_SIGN_RAW_PKCS1_4096", - CryptoKeyVersionAlgorithm::RsaDecryptOaep2048Sha256 => "RSA_DECRYPT_OAEP_2048_SHA256", - CryptoKeyVersionAlgorithm::RsaDecryptOaep3072Sha256 => "RSA_DECRYPT_OAEP_3072_SHA256", - CryptoKeyVersionAlgorithm::RsaDecryptOaep4096Sha256 => "RSA_DECRYPT_OAEP_4096_SHA256", - CryptoKeyVersionAlgorithm::RsaDecryptOaep4096Sha512 => "RSA_DECRYPT_OAEP_4096_SHA512", - CryptoKeyVersionAlgorithm::RsaDecryptOaep2048Sha1 => "RSA_DECRYPT_OAEP_2048_SHA1", - CryptoKeyVersionAlgorithm::RsaDecryptOaep3072Sha1 => "RSA_DECRYPT_OAEP_3072_SHA1", - CryptoKeyVersionAlgorithm::RsaDecryptOaep4096Sha1 => "RSA_DECRYPT_OAEP_4096_SHA1", - CryptoKeyVersionAlgorithm::EcSignP256Sha256 => "EC_SIGN_P256_SHA256", - CryptoKeyVersionAlgorithm::EcSignP384Sha384 => "EC_SIGN_P384_SHA384", - CryptoKeyVersionAlgorithm::EcSignSecp256k1Sha256 => "EC_SIGN_SECP256K1_SHA256", - CryptoKeyVersionAlgorithm::EcSignEd25519 => "EC_SIGN_ED25519", - CryptoKeyVersionAlgorithm::HmacSha256 => "HMAC_SHA256", - CryptoKeyVersionAlgorithm::HmacSha1 => "HMAC_SHA1", - CryptoKeyVersionAlgorithm::HmacSha384 => "HMAC_SHA384", - CryptoKeyVersionAlgorithm::HmacSha512 => "HMAC_SHA512", - CryptoKeyVersionAlgorithm::HmacSha224 => "HMAC_SHA224", - CryptoKeyVersionAlgorithm::ExternalSymmetricEncryption => "EXTERNAL_SYMMETRIC_ENCRYPTION", + Self::Unspecified => "CRYPTO_KEY_VERSION_ALGORITHM_UNSPECIFIED", + Self::GoogleSymmetricEncryption => "GOOGLE_SYMMETRIC_ENCRYPTION", + Self::Aes128Gcm => "AES_128_GCM", + Self::Aes256Gcm => "AES_256_GCM", + Self::Aes128Cbc => "AES_128_CBC", + Self::Aes256Cbc => "AES_256_CBC", + Self::Aes128Ctr => "AES_128_CTR", + Self::Aes256Ctr => "AES_256_CTR", + Self::RsaSignPss2048Sha256 => "RSA_SIGN_PSS_2048_SHA256", + Self::RsaSignPss3072Sha256 => "RSA_SIGN_PSS_3072_SHA256", + Self::RsaSignPss4096Sha256 => "RSA_SIGN_PSS_4096_SHA256", + Self::RsaSignPss4096Sha512 => "RSA_SIGN_PSS_4096_SHA512", + Self::RsaSignPkcs12048Sha256 => "RSA_SIGN_PKCS1_2048_SHA256", + Self::RsaSignPkcs13072Sha256 => "RSA_SIGN_PKCS1_3072_SHA256", + Self::RsaSignPkcs14096Sha256 => "RSA_SIGN_PKCS1_4096_SHA256", + Self::RsaSignPkcs14096Sha512 => "RSA_SIGN_PKCS1_4096_SHA512", + Self::RsaSignRawPkcs12048 => "RSA_SIGN_RAW_PKCS1_2048", + Self::RsaSignRawPkcs13072 => "RSA_SIGN_RAW_PKCS1_3072", + Self::RsaSignRawPkcs14096 => "RSA_SIGN_RAW_PKCS1_4096", + Self::RsaDecryptOaep2048Sha256 => "RSA_DECRYPT_OAEP_2048_SHA256", + Self::RsaDecryptOaep3072Sha256 => "RSA_DECRYPT_OAEP_3072_SHA256", + Self::RsaDecryptOaep4096Sha256 => "RSA_DECRYPT_OAEP_4096_SHA256", + Self::RsaDecryptOaep4096Sha512 => "RSA_DECRYPT_OAEP_4096_SHA512", + Self::RsaDecryptOaep2048Sha1 => "RSA_DECRYPT_OAEP_2048_SHA1", + Self::RsaDecryptOaep3072Sha1 => "RSA_DECRYPT_OAEP_3072_SHA1", + Self::RsaDecryptOaep4096Sha1 => "RSA_DECRYPT_OAEP_4096_SHA1", + Self::EcSignP256Sha256 => "EC_SIGN_P256_SHA256", + Self::EcSignP384Sha384 => "EC_SIGN_P384_SHA384", + Self::EcSignSecp256k1Sha256 => "EC_SIGN_SECP256K1_SHA256", + Self::EcSignEd25519 => "EC_SIGN_ED25519", + Self::HmacSha256 => "HMAC_SHA256", + Self::HmacSha1 => "HMAC_SHA1", + Self::HmacSha384 => "HMAC_SHA384", + Self::HmacSha512 => "HMAC_SHA512", + Self::HmacSha224 => "HMAC_SHA224", + Self::ExternalSymmetricEncryption => "EXTERNAL_SYMMETRIC_ENCRYPTION", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -695,17 +688,17 @@ pub mod crypto_key_version { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - CryptoKeyVersionState::Unspecified => "CRYPTO_KEY_VERSION_STATE_UNSPECIFIED", - CryptoKeyVersionState::PendingGeneration => "PENDING_GENERATION", - CryptoKeyVersionState::Enabled => "ENABLED", - CryptoKeyVersionState::Disabled => "DISABLED", - CryptoKeyVersionState::Destroyed => "DESTROYED", - CryptoKeyVersionState::DestroyScheduled => "DESTROY_SCHEDULED", - CryptoKeyVersionState::PendingImport => "PENDING_IMPORT", - CryptoKeyVersionState::ImportFailed => "IMPORT_FAILED", - CryptoKeyVersionState::GenerationFailed => "GENERATION_FAILED", - CryptoKeyVersionState::PendingExternalDestruction => "PENDING_EXTERNAL_DESTRUCTION", - CryptoKeyVersionState::ExternalDestructionFailed => "EXTERNAL_DESTRUCTION_FAILED", + Self::Unspecified => "CRYPTO_KEY_VERSION_STATE_UNSPECIFIED", + Self::PendingGeneration => "PENDING_GENERATION", + Self::Enabled => "ENABLED", + Self::Disabled => "DISABLED", + Self::Destroyed => "DESTROYED", + Self::DestroyScheduled => "DESTROY_SCHEDULED", + Self::PendingImport => "PENDING_IMPORT", + Self::ImportFailed => "IMPORT_FAILED", + Self::GenerationFailed => "GENERATION_FAILED", + Self::PendingExternalDestruction => "PENDING_EXTERNAL_DESTRUCTION", + Self::ExternalDestructionFailed => "EXTERNAL_DESTRUCTION_FAILED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -752,8 +745,8 @@ pub mod crypto_key_version { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - CryptoKeyVersionView::Unspecified => "CRYPTO_KEY_VERSION_VIEW_UNSPECIFIED", - CryptoKeyVersionView::Full => "FULL", + Self::Unspecified => "CRYPTO_KEY_VERSION_VIEW_UNSPECIFIED", + Self::Full => "FULL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -769,7 +762,6 @@ pub mod crypto_key_version { /// The public keys for a given /// [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion]. Obtained via /// [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PublicKey { /// The public key, encoded in PEM format. For more information, see the @@ -845,7 +837,6 @@ pub struct PublicKey { /// /// For more information, see /// [Importing a key](). -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportJob { /// Output only. The resource name for this @@ -906,7 +897,6 @@ pub mod import_job { /// The public key component of the wrapping key. For details of the type of /// key this public key corresponds to, see the /// [ImportMethod][google.cloud.kms.v1.ImportJob.ImportMethod]. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct WrappingPublicKey { /// The public key, encoded in PEM format. For more information, see the [RFC @@ -971,13 +961,13 @@ pub mod import_job { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ImportMethod::Unspecified => "IMPORT_METHOD_UNSPECIFIED", - ImportMethod::RsaOaep3072Sha1Aes256 => "RSA_OAEP_3072_SHA1_AES_256", - ImportMethod::RsaOaep4096Sha1Aes256 => "RSA_OAEP_4096_SHA1_AES_256", - ImportMethod::RsaOaep3072Sha256Aes256 => "RSA_OAEP_3072_SHA256_AES_256", - ImportMethod::RsaOaep4096Sha256Aes256 => "RSA_OAEP_4096_SHA256_AES_256", - ImportMethod::RsaOaep3072Sha256 => "RSA_OAEP_3072_SHA256", - ImportMethod::RsaOaep4096Sha256 => "RSA_OAEP_4096_SHA256", + Self::Unspecified => "IMPORT_METHOD_UNSPECIFIED", + Self::RsaOaep3072Sha1Aes256 => "RSA_OAEP_3072_SHA1_AES_256", + Self::RsaOaep4096Sha1Aes256 => "RSA_OAEP_4096_SHA1_AES_256", + Self::RsaOaep3072Sha256Aes256 => "RSA_OAEP_3072_SHA256_AES_256", + Self::RsaOaep4096Sha256Aes256 => "RSA_OAEP_4096_SHA256_AES_256", + Self::RsaOaep3072Sha256 => "RSA_OAEP_3072_SHA256", + Self::RsaOaep4096Sha256 => "RSA_OAEP_4096_SHA256", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1022,10 +1012,10 @@ pub mod import_job { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ImportJobState::Unspecified => "IMPORT_JOB_STATE_UNSPECIFIED", - ImportJobState::PendingGeneration => "PENDING_GENERATION", - ImportJobState::Active => "ACTIVE", - ImportJobState::Expired => "EXPIRED", + Self::Unspecified => "IMPORT_JOB_STATE_UNSPECIFIED", + Self::PendingGeneration => "PENDING_GENERATION", + Self::Active => "ACTIVE", + Self::Expired => "EXPIRED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1046,7 +1036,6 @@ pub mod import_job { /// protection level and /// [EXTERNAL_VPC][google.cloud.kms.v1.ProtectionLevel.EXTERNAL_VPC] protection /// levels. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ExternalProtectionLevelOptions { /// The URI for an external resource that this @@ -1065,7 +1054,6 @@ pub struct ExternalProtectionLevelOptions { /// specifies zero or more allowed /// [AccessReason][google.cloud.kms.v1.AccessReason] values for encrypt, decrypt, /// and sign operations on a [CryptoKey][google.cloud.kms.v1.CryptoKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct KeyAccessJustificationsPolicy { /// The list of allowed reasons for access to a @@ -1100,11 +1088,11 @@ impl ProtectionLevel { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ProtectionLevel::Unspecified => "PROTECTION_LEVEL_UNSPECIFIED", - ProtectionLevel::Software => "SOFTWARE", - ProtectionLevel::Hsm => "HSM", - ProtectionLevel::External => "EXTERNAL", - ProtectionLevel::ExternalVpc => "EXTERNAL_VPC", + Self::Unspecified => "PROTECTION_LEVEL_UNSPECIFIED", + Self::Software => "SOFTWARE", + Self::Hsm => "HSM", + Self::External => "EXTERNAL", + Self::ExternalVpc => "EXTERNAL_VPC", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1183,18 +1171,18 @@ impl AccessReason { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - AccessReason::ReasonUnspecified => "REASON_UNSPECIFIED", - AccessReason::CustomerInitiatedSupport => "CUSTOMER_INITIATED_SUPPORT", - AccessReason::GoogleInitiatedService => "GOOGLE_INITIATED_SERVICE", - AccessReason::ThirdPartyDataRequest => "THIRD_PARTY_DATA_REQUEST", - AccessReason::GoogleInitiatedReview => "GOOGLE_INITIATED_REVIEW", - AccessReason::CustomerInitiatedAccess => "CUSTOMER_INITIATED_ACCESS", - AccessReason::GoogleInitiatedSystemOperation => "GOOGLE_INITIATED_SYSTEM_OPERATION", - AccessReason::ReasonNotExpected => "REASON_NOT_EXPECTED", - AccessReason::ModifiedCustomerInitiatedAccess => "MODIFIED_CUSTOMER_INITIATED_ACCESS", - AccessReason::ModifiedGoogleInitiatedSystemOperation => "MODIFIED_GOOGLE_INITIATED_SYSTEM_OPERATION", - AccessReason::GoogleResponseToProductionAlert => "GOOGLE_RESPONSE_TO_PRODUCTION_ALERT", - AccessReason::CustomerAuthorizedWorkflowServicing => "CUSTOMER_AUTHORIZED_WORKFLOW_SERVICING", + Self::ReasonUnspecified => "REASON_UNSPECIFIED", + Self::CustomerInitiatedSupport => "CUSTOMER_INITIATED_SUPPORT", + Self::GoogleInitiatedService => "GOOGLE_INITIATED_SERVICE", + Self::ThirdPartyDataRequest => "THIRD_PARTY_DATA_REQUEST", + Self::GoogleInitiatedReview => "GOOGLE_INITIATED_REVIEW", + Self::CustomerInitiatedAccess => "CUSTOMER_INITIATED_ACCESS", + Self::GoogleInitiatedSystemOperation => "GOOGLE_INITIATED_SYSTEM_OPERATION", + Self::ReasonNotExpected => "REASON_NOT_EXPECTED", + Self::ModifiedCustomerInitiatedAccess => "MODIFIED_CUSTOMER_INITIATED_ACCESS", + Self::ModifiedGoogleInitiatedSystemOperation => "MODIFIED_GOOGLE_INITIATED_SYSTEM_OPERATION", + Self::GoogleResponseToProductionAlert => "GOOGLE_RESPONSE_TO_PRODUCTION_ALERT", + Self::CustomerAuthorizedWorkflowServicing => "CUSTOMER_AUTHORIZED_WORKFLOW_SERVICING", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1218,7 +1206,6 @@ impl AccessReason { } /// Request message for /// [KeyManagementService.ListKeyRings][google.cloud.kms.v1.KeyManagementService.ListKeyRings]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListKeyRingsRequest { /// Required. The resource name of the location associated with the @@ -1254,7 +1241,6 @@ pub struct ListKeyRingsRequest { } /// Request message for /// [KeyManagementService.ListCryptoKeys][google.cloud.kms.v1.KeyManagementService.ListCryptoKeys]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListCryptoKeysRequest { /// Required. The resource name of the [KeyRing][google.cloud.kms.v1.KeyRing] @@ -1292,7 +1278,6 @@ pub struct ListCryptoKeysRequest { } /// Request message for /// [KeyManagementService.ListCryptoKeyVersions][google.cloud.kms.v1.KeyManagementService.ListCryptoKeyVersions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListCryptoKeyVersionsRequest { /// Required. The resource name of the @@ -1331,7 +1316,6 @@ pub struct ListCryptoKeyVersionsRequest { } /// Request message for /// [KeyManagementService.ListImportJobs][google.cloud.kms.v1.KeyManagementService.ListImportJobs]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListImportJobsRequest { /// Required. The resource name of the [KeyRing][google.cloud.kms.v1.KeyRing] @@ -1366,7 +1350,6 @@ pub struct ListImportJobsRequest { } /// Response message for /// [KeyManagementService.ListKeyRings][google.cloud.kms.v1.KeyManagementService.ListKeyRings]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListKeyRingsResponse { /// The list of [KeyRings][google.cloud.kms.v1.KeyRing]. @@ -1384,7 +1367,6 @@ pub struct ListKeyRingsResponse { } /// Response message for /// [KeyManagementService.ListCryptoKeys][google.cloud.kms.v1.KeyManagementService.ListCryptoKeys]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListCryptoKeysResponse { /// The list of [CryptoKeys][google.cloud.kms.v1.CryptoKey]. @@ -1402,7 +1384,6 @@ pub struct ListCryptoKeysResponse { } /// Response message for /// [KeyManagementService.ListCryptoKeyVersions][google.cloud.kms.v1.KeyManagementService.ListCryptoKeyVersions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListCryptoKeyVersionsResponse { /// The list of [CryptoKeyVersions][google.cloud.kms.v1.CryptoKeyVersion]. @@ -1421,7 +1402,6 @@ pub struct ListCryptoKeyVersionsResponse { } /// Response message for /// [KeyManagementService.ListImportJobs][google.cloud.kms.v1.KeyManagementService.ListImportJobs]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListImportJobsResponse { /// The list of [ImportJobs][google.cloud.kms.v1.ImportJob]. @@ -1439,7 +1419,6 @@ pub struct ListImportJobsResponse { } /// Request message for /// [KeyManagementService.GetKeyRing][google.cloud.kms.v1.KeyManagementService.GetKeyRing]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetKeyRingRequest { /// Required. The [name][google.cloud.kms.v1.KeyRing.name] of the @@ -1449,7 +1428,6 @@ pub struct GetKeyRingRequest { } /// Request message for /// [KeyManagementService.GetCryptoKey][google.cloud.kms.v1.KeyManagementService.GetCryptoKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetCryptoKeyRequest { /// Required. The [name][google.cloud.kms.v1.CryptoKey.name] of the @@ -1459,7 +1437,6 @@ pub struct GetCryptoKeyRequest { } /// Request message for /// [KeyManagementService.GetCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.GetCryptoKeyVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetCryptoKeyVersionRequest { /// Required. The [name][google.cloud.kms.v1.CryptoKeyVersion.name] of the @@ -1469,7 +1446,6 @@ pub struct GetCryptoKeyVersionRequest { } /// Request message for /// [KeyManagementService.GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetPublicKeyRequest { /// Required. The [name][google.cloud.kms.v1.CryptoKeyVersion.name] of the @@ -1479,7 +1455,6 @@ pub struct GetPublicKeyRequest { } /// Request message for /// [KeyManagementService.GetImportJob][google.cloud.kms.v1.KeyManagementService.GetImportJob]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetImportJobRequest { /// Required. The [name][google.cloud.kms.v1.ImportJob.name] of the @@ -1489,7 +1464,6 @@ pub struct GetImportJobRequest { } /// Request message for /// [KeyManagementService.CreateKeyRing][google.cloud.kms.v1.KeyManagementService.CreateKeyRing]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateKeyRingRequest { /// Required. The resource name of the location associated with the @@ -1508,7 +1482,6 @@ pub struct CreateKeyRingRequest { } /// Request message for /// [KeyManagementService.CreateCryptoKey][google.cloud.kms.v1.KeyManagementService.CreateCryptoKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateCryptoKeyRequest { /// Required. The [name][google.cloud.kms.v1.KeyRing.name] of the KeyRing @@ -1536,7 +1509,6 @@ pub struct CreateCryptoKeyRequest { } /// Request message for /// [KeyManagementService.CreateCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.CreateCryptoKeyVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateCryptoKeyVersionRequest { /// Required. The [name][google.cloud.kms.v1.CryptoKey.name] of the @@ -1551,7 +1523,6 @@ pub struct CreateCryptoKeyVersionRequest { } /// Request message for /// [KeyManagementService.ImportCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.ImportCryptoKeyVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportCryptoKeyVersionRequest { /// Required. The [name][google.cloud.kms.v1.CryptoKey.name] of the @@ -1647,7 +1618,6 @@ pub mod import_crypto_key_version_request { /// This field is legacy. Use the field /// [wrapped_key][google.cloud.kms.v1.ImportCryptoKeyVersionRequest.wrapped_key] /// instead. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum WrappedKeyMaterial { /// Optional. This field has the same meaning as @@ -1660,7 +1630,6 @@ pub mod import_crypto_key_version_request { } /// Request message for /// [KeyManagementService.CreateImportJob][google.cloud.kms.v1.KeyManagementService.CreateImportJob]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateImportJobRequest { /// Required. The [name][google.cloud.kms.v1.KeyRing.name] of the @@ -1679,7 +1648,6 @@ pub struct CreateImportJobRequest { } /// Request message for /// [KeyManagementService.UpdateCryptoKey][google.cloud.kms.v1.KeyManagementService.UpdateCryptoKey]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateCryptoKeyRequest { /// Required. [CryptoKey][google.cloud.kms.v1.CryptoKey] with updated values. @@ -1691,7 +1659,6 @@ pub struct UpdateCryptoKeyRequest { } /// Request message for /// [KeyManagementService.UpdateCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.UpdateCryptoKeyVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateCryptoKeyVersionRequest { /// Required. [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] with @@ -1704,7 +1671,6 @@ pub struct UpdateCryptoKeyVersionRequest { } /// Request message for /// [KeyManagementService.UpdateCryptoKeyPrimaryVersion][google.cloud.kms.v1.KeyManagementService.UpdateCryptoKeyPrimaryVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateCryptoKeyPrimaryVersionRequest { /// Required. The resource name of the @@ -1718,7 +1684,6 @@ pub struct UpdateCryptoKeyPrimaryVersionRequest { } /// Request message for /// [KeyManagementService.DestroyCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.DestroyCryptoKeyVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DestroyCryptoKeyVersionRequest { /// Required. The resource name of the @@ -1728,7 +1693,6 @@ pub struct DestroyCryptoKeyVersionRequest { } /// Request message for /// [KeyManagementService.RestoreCryptoKeyVersion][google.cloud.kms.v1.KeyManagementService.RestoreCryptoKeyVersion]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RestoreCryptoKeyVersionRequest { /// Required. The resource name of the @@ -1738,7 +1702,6 @@ pub struct RestoreCryptoKeyVersionRequest { } /// Request message for /// [KeyManagementService.Encrypt][google.cloud.kms.v1.KeyManagementService.Encrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct EncryptRequest { /// Required. The resource name of the @@ -1823,7 +1786,6 @@ pub struct EncryptRequest { } /// Request message for /// [KeyManagementService.Decrypt][google.cloud.kms.v1.KeyManagementService.Decrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DecryptRequest { /// Required. The resource name of the @@ -1884,7 +1846,6 @@ pub struct DecryptRequest { } /// Request message for /// [KeyManagementService.RawEncrypt][google.cloud.kms.v1.KeyManagementService.RawEncrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RawEncryptRequest { /// Required. The resource name of the @@ -1982,7 +1943,6 @@ pub struct RawEncryptRequest { } /// Request message for /// [KeyManagementService.RawDecrypt][google.cloud.kms.v1.KeyManagementService.RawDecrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RawDecryptRequest { /// Required. The resource name of the @@ -2063,7 +2023,6 @@ pub struct RawDecryptRequest { } /// Request message for /// [KeyManagementService.AsymmetricSign][google.cloud.kms.v1.KeyManagementService.AsymmetricSign]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AsymmetricSignRequest { /// Required. The resource name of the @@ -2131,7 +2090,6 @@ pub struct AsymmetricSignRequest { } /// Request message for /// [KeyManagementService.AsymmetricDecrypt][google.cloud.kms.v1.KeyManagementService.AsymmetricDecrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AsymmetricDecryptRequest { /// Required. The resource name of the @@ -2168,7 +2126,6 @@ pub struct AsymmetricDecryptRequest { } /// Request message for /// [KeyManagementService.MacSign][google.cloud.kms.v1.KeyManagementService.MacSign]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MacSignRequest { /// Required. The resource name of the @@ -2202,7 +2159,6 @@ pub struct MacSignRequest { } /// Request message for /// [KeyManagementService.MacVerify][google.cloud.kms.v1.KeyManagementService.MacVerify]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MacVerifyRequest { /// Required. The resource name of the @@ -2259,7 +2215,6 @@ pub struct MacVerifyRequest { } /// Request message for /// [KeyManagementService.GenerateRandomBytes][google.cloud.kms.v1.KeyManagementService.GenerateRandomBytes]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GenerateRandomBytesRequest { /// The project-specific location in which to generate random bytes. @@ -2279,7 +2234,6 @@ pub struct GenerateRandomBytesRequest { } /// Response message for /// [KeyManagementService.Encrypt][google.cloud.kms.v1.KeyManagementService.Encrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct EncryptResponse { /// The resource name of the @@ -2346,7 +2300,6 @@ pub struct EncryptResponse { } /// Response message for /// [KeyManagementService.Decrypt][google.cloud.kms.v1.KeyManagementService.Decrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DecryptResponse { /// The decrypted data originally supplied in @@ -2383,7 +2336,6 @@ pub struct DecryptResponse { } /// Response message for /// [KeyManagementService.RawEncrypt][google.cloud.kms.v1.KeyManagementService.RawEncrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RawEncryptResponse { /// The encrypted data. In the case of AES-GCM, the authentication tag @@ -2484,7 +2436,6 @@ pub struct RawEncryptResponse { } /// Response message for /// [KeyManagementService.RawDecrypt][google.cloud.kms.v1.KeyManagementService.RawDecrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RawDecryptResponse { /// The decrypted data. @@ -2560,7 +2511,6 @@ pub struct RawDecryptResponse { } /// Response message for /// [KeyManagementService.AsymmetricSign][google.cloud.kms.v1.KeyManagementService.AsymmetricSign]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AsymmetricSignResponse { /// The created signature. @@ -2625,7 +2575,6 @@ pub struct AsymmetricSignResponse { } /// Response message for /// [KeyManagementService.AsymmetricDecrypt][google.cloud.kms.v1.KeyManagementService.AsymmetricDecrypt]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AsymmetricDecryptResponse { /// The decrypted data originally encrypted with the matching public key. @@ -2670,7 +2619,6 @@ pub struct AsymmetricDecryptResponse { } /// Response message for /// [KeyManagementService.MacSign][google.cloud.kms.v1.KeyManagementService.MacSign]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MacSignResponse { /// The resource name of the @@ -2719,7 +2667,6 @@ pub struct MacSignResponse { } /// Response message for /// [KeyManagementService.MacVerify][google.cloud.kms.v1.KeyManagementService.MacVerify]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MacVerifyResponse { /// The resource name of the @@ -2780,7 +2727,6 @@ pub struct MacVerifyResponse { } /// Response message for /// [KeyManagementService.GenerateRandomBytes][google.cloud.kms.v1.KeyManagementService.GenerateRandomBytes]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GenerateRandomBytesResponse { /// The generated data. @@ -2803,7 +2749,6 @@ pub struct GenerateRandomBytesResponse { pub data_crc32c: ::core::option::Option, } /// A [Digest][google.cloud.kms.v1.Digest] holds a cryptographic message digest. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Digest { /// Required. The message digest. @@ -2813,7 +2758,6 @@ pub struct Digest { /// Nested message and enum types in `Digest`. pub mod digest { /// Required. The message digest. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Digest { /// A message digest produced with the SHA-256 algorithm. @@ -2829,7 +2773,6 @@ pub mod digest { } /// Cloud KMS metadata for the given /// [google.cloud.location.Location][google.cloud.location.Location]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct LocationMetadata { /// Indicates whether [CryptoKeys][google.cloud.kms.v1.CryptoKey] with @@ -2847,7 +2790,13 @@ pub struct LocationMetadata { } /// Generated client implementations. pub mod key_management_service_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// Google Cloud Key Management Service @@ -2881,8 +2830,8 @@ pub mod key_management_service_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -2900,7 +2849,8 @@ pub mod key_management_service_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { KeyManagementServiceClient::new(InterceptedService::new(inner, interceptor)) } @@ -2940,9 +2890,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/ListKeyRings"); let mut req = request.into_request(); @@ -2955,9 +2906,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/ListCryptoKeys"); let mut req = request.into_request(); @@ -2970,9 +2922,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/ListCryptoKeyVersions"); @@ -2988,9 +2941,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/ListImportJobs"); let mut req = request.into_request(); @@ -3003,9 +2957,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/GetKeyRing"); let mut req = request.into_request(); @@ -3020,9 +2975,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/GetCryptoKey"); let mut req = request.into_request(); @@ -3036,9 +2992,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/GetCryptoKeyVersion"); @@ -3059,9 +3016,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/GetPublicKey"); let mut req = request.into_request(); @@ -3074,9 +3032,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/GetImportJob"); let mut req = request.into_request(); @@ -3090,9 +3049,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/CreateKeyRing"); let mut req = request.into_request(); @@ -3110,9 +3070,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/CreateCryptoKey"); @@ -3131,9 +3092,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.cloud.kms.v1.KeyManagementService/CreateCryptoKeyVersion", @@ -3157,9 +3119,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.cloud.kms.v1.KeyManagementService/ImportCryptoKeyVersion", @@ -3180,9 +3143,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/CreateImportJob"); @@ -3196,9 +3160,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/UpdateCryptoKey"); @@ -3223,9 +3188,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.cloud.kms.v1.KeyManagementService/UpdateCryptoKeyVersion", @@ -3247,9 +3213,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.cloud.kms.v1.KeyManagementService/UpdateCryptoKeyPrimaryVersion", @@ -3286,9 +3253,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.cloud.kms.v1.KeyManagementService/DestroyCryptoKeyVersion", @@ -3313,9 +3281,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.cloud.kms.v1.KeyManagementService/RestoreCryptoKeyVersion", @@ -3335,9 +3304,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/Encrypt"); let mut req = request.into_request(); @@ -3353,9 +3323,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/Decrypt"); let mut req = request.into_request(); @@ -3373,9 +3344,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/RawEncrypt"); let mut req = request.into_request(); @@ -3391,9 +3363,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/RawDecrypt"); let mut req = request.into_request(); @@ -3410,9 +3383,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/AsymmetricSign"); let mut req = request.into_request(); @@ -3429,9 +3403,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/AsymmetricDecrypt"); @@ -3447,9 +3422,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/MacSign"); let mut req = request.into_request(); @@ -3465,9 +3441,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/MacVerify"); let mut req = request.into_request(); @@ -3481,9 +3458,10 @@ pub mod key_management_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.KeyManagementService/GenerateRandomBytes"); @@ -3498,7 +3476,6 @@ pub mod key_management_service_client { } /// Request message for /// [EkmService.ListEkmConnections][google.cloud.kms.v1.EkmService.ListEkmConnections]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListEkmConnectionsRequest { /// Required. The resource name of the location associated with the @@ -3534,7 +3511,6 @@ pub struct ListEkmConnectionsRequest { } /// Response message for /// [EkmService.ListEkmConnections][google.cloud.kms.v1.EkmService.ListEkmConnections]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListEkmConnectionsResponse { /// The list of [EkmConnections][google.cloud.kms.v1.EkmConnection]. @@ -3552,7 +3528,6 @@ pub struct ListEkmConnectionsResponse { } /// Request message for /// [EkmService.GetEkmConnection][google.cloud.kms.v1.EkmService.GetEkmConnection]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetEkmConnectionRequest { /// Required. The [name][google.cloud.kms.v1.EkmConnection.name] of the @@ -3562,7 +3537,6 @@ pub struct GetEkmConnectionRequest { } /// Request message for /// [EkmService.CreateEkmConnection][google.cloud.kms.v1.EkmService.CreateEkmConnection]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateEkmConnectionRequest { /// Required. The resource name of the location associated with the @@ -3581,7 +3555,6 @@ pub struct CreateEkmConnectionRequest { } /// Request message for /// [EkmService.UpdateEkmConnection][google.cloud.kms.v1.EkmService.UpdateEkmConnection]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateEkmConnectionRequest { /// Required. [EkmConnection][google.cloud.kms.v1.EkmConnection] with updated @@ -3594,7 +3567,6 @@ pub struct UpdateEkmConnectionRequest { } /// Request message for /// [EkmService.GetEkmConfig][google.cloud.kms.v1.EkmService.GetEkmConfig]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetEkmConfigRequest { /// Required. The [name][google.cloud.kms.v1.EkmConfig.name] of the @@ -3604,7 +3576,6 @@ pub struct GetEkmConfigRequest { } /// Request message for /// [EkmService.UpdateEkmConfig][google.cloud.kms.v1.EkmService.UpdateEkmConfig]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateEkmConfigRequest { /// Required. [EkmConfig][google.cloud.kms.v1.EkmConfig] with updated values. @@ -3616,7 +3587,6 @@ pub struct UpdateEkmConfigRequest { } /// A [Certificate][google.cloud.kms.v1.Certificate] represents an X.509 /// certificate used to authenticate HTTPS connections to EKM replicas. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Certificate { /// Required. The raw certificate bytes in DER format. @@ -3662,7 +3632,6 @@ pub struct Certificate { /// [EXTERNAL_VPC][CryptoKeyVersion.ProtectionLevel.EXTERNAL_VPC], as well as /// performing cryptographic operations using keys created within the /// [EkmConnection][google.cloud.kms.v1.EkmConnection]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct EkmConnection { /// Output only. The resource name for the @@ -3704,7 +3673,6 @@ pub mod ekm_connection { /// A [ServiceResolver][google.cloud.kms.v1.EkmConnection.ServiceResolver] /// represents an EKM replica that can be reached within an /// [EkmConnection][google.cloud.kms.v1.EkmConnection]. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ServiceResolver { /// Required. The resource name of the Service Directory service pointing to @@ -3773,9 +3741,9 @@ pub mod ekm_connection { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - KeyManagementMode::Unspecified => "KEY_MANAGEMENT_MODE_UNSPECIFIED", - KeyManagementMode::Manual => "MANUAL", - KeyManagementMode::CloudKms => "CLOUD_KMS", + Self::Unspecified => "KEY_MANAGEMENT_MODE_UNSPECIFIED", + Self::Manual => "MANUAL", + Self::CloudKms => "CLOUD_KMS", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -3796,7 +3764,6 @@ pub mod ekm_connection { /// [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] of /// [EXTERNAL_VPC][CryptoKeyVersion.ProtectionLevel.EXTERNAL_VPC] in a given /// project and location. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct EkmConfig { /// Output only. The resource name for the @@ -3812,7 +3779,6 @@ pub struct EkmConfig { } /// Request message for /// [EkmService.VerifyConnectivity][google.cloud.kms.v1.EkmService.VerifyConnectivity]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct VerifyConnectivityRequest { /// Required. The [name][google.cloud.kms.v1.EkmConnection.name] of the @@ -3822,12 +3788,17 @@ pub struct VerifyConnectivityRequest { } /// Response message for /// [EkmService.VerifyConnectivity][google.cloud.kms.v1.EkmService.VerifyConnectivity]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct VerifyConnectivityResponse {} /// Generated client implementations. pub mod ekm_service_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// Google Cloud Key Management EKM Service @@ -3854,8 +3825,8 @@ pub mod ekm_service_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -3873,7 +3844,8 @@ pub mod ekm_service_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { EkmServiceClient::new(InterceptedService::new(inner, interceptor)) } @@ -3913,9 +3885,10 @@ pub mod ekm_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.EkmService/ListEkmConnections"); let mut req = request.into_request(); @@ -3929,9 +3902,10 @@ pub mod ekm_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.EkmService/GetEkmConnection"); let mut req = request.into_request(); @@ -3945,9 +3919,10 @@ pub mod ekm_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.EkmService/CreateEkmConnection"); let mut req = request.into_request(); @@ -3960,9 +3935,10 @@ pub mod ekm_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.EkmService/UpdateEkmConnection"); let mut req = request.into_request(); @@ -3976,9 +3952,10 @@ pub mod ekm_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.EkmService/GetEkmConfig"); let mut req = request.into_request(); @@ -3992,9 +3969,10 @@ pub mod ekm_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.EkmService/UpdateEkmConfig"); let mut req = request.into_request(); @@ -4011,9 +3989,10 @@ pub mod ekm_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.cloud.kms.v1.EkmService/VerifyConnectivity"); let mut req = request.into_request(); diff --git a/googleapis/src/google.devtools.artifactregistry.v1.rs b/googleapis/src/google.devtools.artifactregistry.v1.rs index dd9d13ea..85e620d4 100644 --- a/googleapis/src/google.devtools.artifactregistry.v1.rs +++ b/googleapis/src/google.devtools.artifactregistry.v1.rs @@ -5,7 +5,6 @@ /// * imageSizeBytes /// * mediaType /// * buildTime -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DockerImage { /// Required. registry_location, project_id, repository_name and image id forms @@ -54,7 +53,6 @@ pub struct DockerImage { pub update_time: ::core::option::Option<::prost_types::Timestamp>, } /// The request to list docker images. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDockerImagesRequest { /// Required. The name of the parent resource whose docker images will be @@ -72,7 +70,6 @@ pub struct ListDockerImagesRequest { pub order_by: ::prost::alloc::string::String, } /// The response from listing docker images. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDockerImagesResponse { /// The docker images returned. @@ -84,7 +81,6 @@ pub struct ListDockerImagesResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to get docker images. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetDockerImageRequest { /// Required. The name of the docker images. @@ -92,7 +88,6 @@ pub struct GetDockerImageRequest { pub name: ::prost::alloc::string::String, } /// MavenArtifact represents a maven artifact. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MavenArtifact { /// Required. registry_location, project_id, repository_name and maven_artifact @@ -129,7 +124,6 @@ pub struct MavenArtifact { pub update_time: ::core::option::Option<::prost_types::Timestamp>, } /// The request to list maven artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListMavenArtifactsRequest { /// Required. The name of the parent resource whose maven artifacts will be @@ -144,7 +138,6 @@ pub struct ListMavenArtifactsRequest { pub page_token: ::prost::alloc::string::String, } /// The response from listing maven artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListMavenArtifactsResponse { /// The maven artifacts returned. @@ -156,7 +149,6 @@ pub struct ListMavenArtifactsResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to get maven artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetMavenArtifactRequest { /// Required. The name of the maven artifact. @@ -164,7 +156,6 @@ pub struct GetMavenArtifactRequest { pub name: ::prost::alloc::string::String, } /// NpmPackage represents an npm artifact. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct NpmPackage { /// Required. registry_location, project_id, repository_name and npm_package @@ -193,7 +184,6 @@ pub struct NpmPackage { pub update_time: ::core::option::Option<::prost_types::Timestamp>, } /// The request to list npm packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListNpmPackagesRequest { /// Required. The name of the parent resource whose npm packages will be @@ -208,7 +198,6 @@ pub struct ListNpmPackagesRequest { pub page_token: ::prost::alloc::string::String, } /// The response from listing npm packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListNpmPackagesResponse { /// The npm packages returned. @@ -220,7 +209,6 @@ pub struct ListNpmPackagesResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to get npm packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetNpmPackageRequest { /// Required. The name of the npm package. @@ -228,7 +216,6 @@ pub struct GetNpmPackageRequest { pub name: ::prost::alloc::string::String, } /// PythonPackage represents a python artifact. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PythonPackage { /// Required. registry_location, project_id, repository_name and python_package @@ -261,7 +248,6 @@ pub struct PythonPackage { pub update_time: ::core::option::Option<::prost_types::Timestamp>, } /// The request to list python packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListPythonPackagesRequest { /// Required. The name of the parent resource whose python packages will be @@ -276,7 +262,6 @@ pub struct ListPythonPackagesRequest { pub page_token: ::prost::alloc::string::String, } /// The response from listing python packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListPythonPackagesResponse { /// The python packages returned. @@ -288,7 +273,6 @@ pub struct ListPythonPackagesResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to get python packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetPythonPackageRequest { /// Required. The name of the python package. @@ -296,7 +280,6 @@ pub struct GetPythonPackageRequest { pub name: ::prost::alloc::string::String, } /// A detailed representation of a Yum artifact. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct YumArtifact { /// Output only. The Artifact Registry resource name of the artifact. @@ -332,9 +315,9 @@ pub mod yum_artifact { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - PackageType::Unspecified => "PACKAGE_TYPE_UNSPECIFIED", - PackageType::Binary => "BINARY", - PackageType::Source => "SOURCE", + Self::Unspecified => "PACKAGE_TYPE_UNSPECIFIED", + Self::Binary => "BINARY", + Self::Source => "SOURCE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -349,7 +332,6 @@ pub mod yum_artifact { } } /// Google Cloud Storage location where the artifacts currently reside. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportYumArtifactsGcsSource { /// Cloud Storage paths URI (e.g., gs://my_bucket//my_object). @@ -360,7 +342,6 @@ pub struct ImportYumArtifactsGcsSource { pub use_wildcards: bool, } /// The request to import new yum artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportYumArtifactsRequest { /// The name of the parent resource where the artifacts will be imported. @@ -373,7 +354,6 @@ pub struct ImportYumArtifactsRequest { /// Nested message and enum types in `ImportYumArtifactsRequest`. pub mod import_yum_artifacts_request { /// The source location of the package binaries. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Source { /// Google Cloud Storage location where input content is located. @@ -382,7 +362,6 @@ pub mod import_yum_artifacts_request { } } /// Error information explaining why a package was not imported. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportYumArtifactsErrorInfo { /// The detailed error status. @@ -395,7 +374,6 @@ pub struct ImportYumArtifactsErrorInfo { /// Nested message and enum types in `ImportYumArtifactsErrorInfo`. pub mod import_yum_artifacts_error_info { /// The source that was not imported. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Source { /// Google Cloud Storage location requested. @@ -404,7 +382,6 @@ pub mod import_yum_artifacts_error_info { } } /// The response message from importing YUM artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportYumArtifactsResponse { /// The yum artifacts imported. @@ -415,11 +392,9 @@ pub struct ImportYumArtifactsResponse { pub errors: ::prost::alloc::vec::Vec, } /// The operation metadata for importing artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ImportYumArtifactsMetadata {} /// The Artifact Registry VPC SC config that apply to a Project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct VpcscConfig { /// The name of the project's VPC SC Config. @@ -460,9 +435,9 @@ pub mod vpcsc_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - VpcscPolicy::Unspecified => "VPCSC_POLICY_UNSPECIFIED", - VpcscPolicy::Deny => "DENY", - VpcscPolicy::Allow => "ALLOW", + Self::Unspecified => "VPCSC_POLICY_UNSPECIFIED", + Self::Deny => "DENY", + Self::Allow => "ALLOW", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -477,7 +452,6 @@ pub mod vpcsc_config { } } /// Gets the VPC SC config for a project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetVpcscConfigRequest { /// Required. The name of the VPCSCConfig resource. @@ -485,7 +459,6 @@ pub struct GetVpcscConfigRequest { pub name: ::prost::alloc::string::String, } /// Sets the VPCSC config of the project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateVpcscConfigRequest { /// The project config. @@ -498,7 +471,6 @@ pub struct UpdateVpcscConfigRequest { /// A detailed representation of an Apt artifact. Information in the record /// is derived from the archive's control file. /// See -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AptArtifact { /// Output only. The Artifact Registry resource name of the artifact. @@ -540,9 +512,9 @@ pub mod apt_artifact { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - PackageType::Unspecified => "PACKAGE_TYPE_UNSPECIFIED", - PackageType::Binary => "BINARY", - PackageType::Source => "SOURCE", + Self::Unspecified => "PACKAGE_TYPE_UNSPECIFIED", + Self::Binary => "BINARY", + Self::Source => "SOURCE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -557,7 +529,6 @@ pub mod apt_artifact { } } /// Google Cloud Storage location where the artifacts currently reside. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportAptArtifactsGcsSource { /// Cloud Storage paths URI (e.g., gs://my_bucket//my_object). @@ -568,7 +539,6 @@ pub struct ImportAptArtifactsGcsSource { pub use_wildcards: bool, } /// The request to import new apt artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportAptArtifactsRequest { /// The name of the parent resource where the artifacts will be imported. @@ -581,7 +551,6 @@ pub struct ImportAptArtifactsRequest { /// Nested message and enum types in `ImportAptArtifactsRequest`. pub mod import_apt_artifacts_request { /// The source location of the package binaries. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Source { /// Google Cloud Storage location where input content is located. @@ -590,7 +559,6 @@ pub mod import_apt_artifacts_request { } } /// Error information explaining why a package was not imported. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportAptArtifactsErrorInfo { /// The detailed error status. @@ -603,7 +571,6 @@ pub struct ImportAptArtifactsErrorInfo { /// Nested message and enum types in `ImportAptArtifactsErrorInfo`. pub mod import_apt_artifacts_error_info { /// The source that was not imported. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Source { /// Google Cloud Storage location requested. @@ -612,7 +579,6 @@ pub mod import_apt_artifacts_error_info { } } /// The response message from importing APT artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ImportAptArtifactsResponse { /// The Apt artifacts imported. @@ -623,11 +589,9 @@ pub struct ImportAptArtifactsResponse { pub errors: ::prost::alloc::vec::Vec, } /// The operation metadata for importing artifacts. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ImportAptArtifactsMetadata {} /// A hash of file content. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Hash { /// The algorithm used to compute the hash value. @@ -657,9 +621,9 @@ pub mod hash { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - HashType::Unspecified => "HASH_TYPE_UNSPECIFIED", - HashType::Sha256 => "SHA256", - HashType::Md5 => "MD5", + Self::Unspecified => "HASH_TYPE_UNSPECIFIED", + Self::Sha256 => "SHA256", + Self::Md5 => "MD5", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -674,7 +638,6 @@ pub mod hash { } } /// Files store content that is potentially associated with Packages or Versions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct File { /// The name of the file, for example: @@ -703,7 +666,6 @@ pub struct File { pub fetch_time: ::core::option::Option<::prost_types::Timestamp>, } /// The request to list files. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListFilesRequest { /// Required. The name of the repository whose files will be listed. For @@ -735,7 +697,6 @@ pub struct ListFilesRequest { pub order_by: ::prost::alloc::string::String, } /// The response from listing files. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListFilesResponse { /// The files returned. @@ -747,7 +708,6 @@ pub struct ListFilesResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to retrieve a file. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetFileRequest { /// Required. The name of the file to retrieve. @@ -755,7 +715,6 @@ pub struct GetFileRequest { pub name: ::prost::alloc::string::String, } /// Packages are named collections of versions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Package { /// The name of the package, for example: @@ -775,7 +734,6 @@ pub struct Package { pub update_time: ::core::option::Option<::prost_types::Timestamp>, } /// The request to list packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListPackagesRequest { /// Required. The name of the parent resource whose packages will be listed. @@ -789,7 +747,6 @@ pub struct ListPackagesRequest { pub page_token: ::prost::alloc::string::String, } /// The response from listing packages. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListPackagesResponse { /// The packages returned. @@ -801,7 +758,6 @@ pub struct ListPackagesResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to retrieve a package. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetPackageRequest { /// Required. The name of the package to retrieve. @@ -809,7 +765,6 @@ pub struct GetPackageRequest { pub name: ::prost::alloc::string::String, } /// The request to delete a package. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeletePackageRequest { /// Required. The name of the package to delete. @@ -817,7 +772,6 @@ pub struct DeletePackageRequest { pub name: ::prost::alloc::string::String, } /// Artifact policy configuration for the repository contents. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpstreamPolicy { /// The user-provided ID of the upstream policy. @@ -834,7 +788,6 @@ pub struct UpstreamPolicy { /// CleanupPolicyCondition is a set of conditions attached to a CleanupPolicy. /// If multiple entries are set, all must be satisfied for the condition to be /// satisfied. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CleanupPolicyCondition { /// Match versions by tag status. @@ -878,10 +831,10 @@ pub mod cleanup_policy_condition { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - TagState::Unspecified => "TAG_STATE_UNSPECIFIED", - TagState::Tagged => "TAGGED", - TagState::Untagged => "UNTAGGED", - TagState::Any => "ANY", + Self::Unspecified => "TAG_STATE_UNSPECIFIED", + Self::Tagged => "TAGGED", + Self::Untagged => "UNTAGGED", + Self::Any => "ANY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -898,7 +851,6 @@ pub mod cleanup_policy_condition { } /// CleanupPolicyMostRecentVersions is an alternate condition of a CleanupPolicy /// for retaining a minimum number of versions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CleanupPolicyMostRecentVersions { /// List of package name prefixes that will apply this rule. @@ -909,7 +861,6 @@ pub struct CleanupPolicyMostRecentVersions { pub keep_count: ::core::option::Option, } /// Artifact policy configuration for repository cleanup policies. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CleanupPolicy { /// The user-provided ID of the cleanup policy. @@ -941,9 +892,9 @@ pub mod cleanup_policy { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Action::Unspecified => "ACTION_UNSPECIFIED", - Action::Delete => "DELETE", - Action::Keep => "KEEP", + Self::Unspecified => "ACTION_UNSPECIFIED", + Self::Delete => "DELETE", + Self::Keep => "KEEP", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -956,7 +907,6 @@ pub mod cleanup_policy { } } } - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum ConditionType { /// Policy condition for matching versions. @@ -969,7 +919,6 @@ pub mod cleanup_policy { } } /// Virtual repository configuration. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct VirtualRepositoryConfig { /// Policies that configure the upstream artifacts distributed by the Virtual @@ -978,7 +927,6 @@ pub struct VirtualRepositoryConfig { pub upstream_policies: ::prost::alloc::vec::Vec, } /// Remote repository configuration. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RemoteRepositoryConfig { /// The description of the remote source. @@ -994,7 +942,6 @@ pub struct RemoteRepositoryConfig { /// Nested message and enum types in `RemoteRepositoryConfig`. pub mod remote_repository_config { /// The credentials to access the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpstreamCredentials { #[prost(oneof = "upstream_credentials::Credentials", tags = "1")] @@ -1003,7 +950,6 @@ pub mod remote_repository_config { /// Nested message and enum types in `UpstreamCredentials`. pub mod upstream_credentials { /// Username and password credentials. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UsernamePasswordCredentials { /// The username to access the remote repository. @@ -1015,7 +961,6 @@ pub mod remote_repository_config { #[prost(string, tag = "2")] pub password_secret_version: ::prost::alloc::string::String, } - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Credentials { /// Use username and password to access the remote repository. @@ -1024,7 +969,6 @@ pub mod remote_repository_config { } } /// Configuration for a Docker remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct DockerRepository { /// Address of the remote repository. @@ -1050,8 +994,8 @@ pub mod remote_repository_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - PublicRepository::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", - PublicRepository::DockerHub => "DOCKER_HUB", + Self::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", + Self::DockerHub => "DOCKER_HUB", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1064,7 +1008,6 @@ pub mod remote_repository_config { } } /// Address of the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum Upstream { /// One of the publicly available Docker repositories supported by Artifact @@ -1074,7 +1017,6 @@ pub mod remote_repository_config { } } /// Configuration for a Maven remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct MavenRepository { /// Address of the remote repository. @@ -1100,8 +1042,8 @@ pub mod remote_repository_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - PublicRepository::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", - PublicRepository::MavenCentral => "MAVEN_CENTRAL", + Self::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", + Self::MavenCentral => "MAVEN_CENTRAL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1114,7 +1056,6 @@ pub mod remote_repository_config { } } /// Address of the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum Upstream { /// One of the publicly available Maven repositories supported by Artifact @@ -1124,7 +1065,6 @@ pub mod remote_repository_config { } } /// Configuration for a Npm remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct NpmRepository { /// Address of the remote repository @@ -1149,8 +1089,8 @@ pub mod remote_repository_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - PublicRepository::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", - PublicRepository::Npmjs => "NPMJS", + Self::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", + Self::Npmjs => "NPMJS", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1163,7 +1103,6 @@ pub mod remote_repository_config { } } /// Address of the remote repository - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum Upstream { /// One of the publicly available Npm repositories supported by Artifact @@ -1173,7 +1112,6 @@ pub mod remote_repository_config { } } /// Configuration for a Python remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct PythonRepository { /// Address of the remote repository. @@ -1198,8 +1136,8 @@ pub mod remote_repository_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - PublicRepository::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", - PublicRepository::Pypi => "PYPI", + Self::Unspecified => "PUBLIC_REPOSITORY_UNSPECIFIED", + Self::Pypi => "PYPI", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1212,7 +1150,6 @@ pub mod remote_repository_config { } } /// Address of the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum Upstream { /// One of the publicly available Python repositories supported by Artifact @@ -1222,7 +1159,6 @@ pub mod remote_repository_config { } } /// Configuration for an Apt remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AptRepository { /// Address of the remote repository. @@ -1233,7 +1169,6 @@ pub mod remote_repository_config { pub mod apt_repository { /// Publicly available Apt repositories constructed from a common repository /// base and a custom repository path. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PublicRepository { /// A common public repository base for Apt. @@ -1263,9 +1198,9 @@ pub mod remote_repository_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - RepositoryBase::Unspecified => "REPOSITORY_BASE_UNSPECIFIED", - RepositoryBase::Debian => "DEBIAN", - RepositoryBase::Ubuntu => "UBUNTU", + Self::Unspecified => "REPOSITORY_BASE_UNSPECIFIED", + Self::Debian => "DEBIAN", + Self::Ubuntu => "UBUNTU", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1280,7 +1215,6 @@ pub mod remote_repository_config { } } /// Address of the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Upstream { /// One of the publicly available Apt repositories supported by Artifact @@ -1290,7 +1224,6 @@ pub mod remote_repository_config { } } /// Configuration for a Yum remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct YumRepository { /// Address of the remote repository. @@ -1301,7 +1234,6 @@ pub mod remote_repository_config { pub mod yum_repository { /// Publicly available Yum repositories constructed from a common repository /// base and a custom repository path. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PublicRepository { /// A common public repository base for Yum. @@ -1339,13 +1271,13 @@ pub mod remote_repository_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - RepositoryBase::Unspecified => "REPOSITORY_BASE_UNSPECIFIED", - RepositoryBase::Centos => "CENTOS", - RepositoryBase::CentosDebug => "CENTOS_DEBUG", - RepositoryBase::CentosVault => "CENTOS_VAULT", - RepositoryBase::CentosStream => "CENTOS_STREAM", - RepositoryBase::Rocky => "ROCKY", - RepositoryBase::Epel => "EPEL", + Self::Unspecified => "REPOSITORY_BASE_UNSPECIFIED", + Self::Centos => "CENTOS", + Self::CentosDebug => "CENTOS_DEBUG", + Self::CentosVault => "CENTOS_VAULT", + Self::CentosStream => "CENTOS_STREAM", + Self::Rocky => "ROCKY", + Self::Epel => "EPEL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1364,7 +1296,6 @@ pub mod remote_repository_config { } } /// Address of the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Upstream { /// One of the publicly available Yum repositories supported by Artifact @@ -1374,7 +1305,6 @@ pub mod remote_repository_config { } } /// Settings specific to the remote repository. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum RemoteSource { /// Specific settings for a Docker remote repository. @@ -1398,7 +1328,6 @@ pub mod remote_repository_config { } } /// A Repository for storing artifacts with a specific format. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Repository { /// The name of the repository, for example: @@ -1464,7 +1393,6 @@ pub mod repository { /// MavenRepositoryConfig is maven related repository details. /// Provides additional configuration details for repositories of the maven /// format type. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct MavenRepositoryConfig { /// The repository with this flag will allow publishing @@ -1497,9 +1425,9 @@ pub mod repository { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - VersionPolicy::Unspecified => "VERSION_POLICY_UNSPECIFIED", - VersionPolicy::Release => "RELEASE", - VersionPolicy::Snapshot => "SNAPSHOT", + Self::Unspecified => "VERSION_POLICY_UNSPECIFIED", + Self::Release => "RELEASE", + Self::Snapshot => "SNAPSHOT", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1516,7 +1444,6 @@ pub mod repository { /// DockerRepositoryConfig is docker related repository details. /// Provides additional configuration details for repositories of the docker /// format type. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct DockerRepositoryConfig { /// The repository which enabled this flag prevents all tags from being @@ -1555,15 +1482,15 @@ pub mod repository { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Format::Unspecified => "FORMAT_UNSPECIFIED", - Format::Docker => "DOCKER", - Format::Maven => "MAVEN", - Format::Npm => "NPM", - Format::Apt => "APT", - Format::Yum => "YUM", - Format::Python => "PYTHON", - Format::Kfp => "KFP", - Format::Go => "GO", + Self::Unspecified => "FORMAT_UNSPECIFIED", + Self::Docker => "DOCKER", + Self::Maven => "MAVEN", + Self::Npm => "NPM", + Self::Apt => "APT", + Self::Yum => "YUM", + Self::Python => "PYTHON", + Self::Kfp => "KFP", + Self::Go => "GO", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1603,10 +1530,10 @@ pub mod repository { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Mode::Unspecified => "MODE_UNSPECIFIED", - Mode::StandardRepository => "STANDARD_REPOSITORY", - Mode::VirtualRepository => "VIRTUAL_REPOSITORY", - Mode::RemoteRepository => "REMOTE_REPOSITORY", + Self::Unspecified => "MODE_UNSPECIFIED", + Self::StandardRepository => "STANDARD_REPOSITORY", + Self::VirtualRepository => "VIRTUAL_REPOSITORY", + Self::RemoteRepository => "REMOTE_REPOSITORY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1621,7 +1548,6 @@ pub mod repository { } } /// Repository-specific configurations. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum FormatConfig { /// Maven repository config contains repository level configuration @@ -1635,7 +1561,6 @@ pub mod repository { } /// Repository configuration specific to the Mode value being selected (Remote /// or Virtual) - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum ModeConfig { /// Configuration specific for a Virtual Repository. @@ -1647,7 +1572,6 @@ pub mod repository { } } /// The request to list repositories. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListRepositoriesRequest { /// Required. The name of the parent resource whose repositories will be @@ -1662,7 +1586,6 @@ pub struct ListRepositoriesRequest { pub page_token: ::prost::alloc::string::String, } /// The response from listing repositories. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListRepositoriesResponse { /// The repositories returned. @@ -1674,7 +1597,6 @@ pub struct ListRepositoriesResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to retrieve a repository. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetRepositoryRequest { /// Required. The name of the repository to retrieve. @@ -1682,7 +1604,6 @@ pub struct GetRepositoryRequest { pub name: ::prost::alloc::string::String, } /// The request to create a new repository. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateRepositoryRequest { /// Required. The name of the parent resource where the repository will be @@ -1697,7 +1618,6 @@ pub struct CreateRepositoryRequest { pub repository: ::core::option::Option, } /// The request to update a repository. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateRepositoryRequest { /// The repository that replaces the resource on the server. @@ -1710,7 +1630,6 @@ pub struct UpdateRepositoryRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// The request to delete a repository. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteRepositoryRequest { /// Required. The name of the repository to delete. @@ -1718,7 +1637,6 @@ pub struct DeleteRepositoryRequest { pub name: ::prost::alloc::string::String, } /// The Artifact Registry settings that apply to a Project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ProjectSettings { /// The name of the project's settings. @@ -1756,10 +1674,10 @@ pub mod project_settings { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - RedirectionState::Unspecified => "REDIRECTION_STATE_UNSPECIFIED", - RedirectionState::RedirectionFromGcrIoDisabled => "REDIRECTION_FROM_GCR_IO_DISABLED", - RedirectionState::RedirectionFromGcrIoEnabled => "REDIRECTION_FROM_GCR_IO_ENABLED", - RedirectionState::RedirectionFromGcrIoFinalized => "REDIRECTION_FROM_GCR_IO_FINALIZED", + Self::Unspecified => "REDIRECTION_STATE_UNSPECIFIED", + Self::RedirectionFromGcrIoDisabled => "REDIRECTION_FROM_GCR_IO_DISABLED", + Self::RedirectionFromGcrIoEnabled => "REDIRECTION_FROM_GCR_IO_ENABLED", + Self::RedirectionFromGcrIoFinalized => "REDIRECTION_FROM_GCR_IO_FINALIZED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1775,7 +1693,6 @@ pub mod project_settings { } } /// Gets the redirection status for a project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetProjectSettingsRequest { /// Required. The name of the projectSettings resource. @@ -1783,7 +1700,6 @@ pub struct GetProjectSettingsRequest { pub name: ::prost::alloc::string::String, } /// Sets the settings of the project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateProjectSettingsRequest { /// The project settings. @@ -1795,7 +1711,6 @@ pub struct UpdateProjectSettingsRequest { } /// Tags point to a version and represent an alternative name that can be used /// to access the version. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Tag { /// The name of the tag, for example: @@ -1813,7 +1728,6 @@ pub struct Tag { pub version: ::prost::alloc::string::String, } /// The request to list tags. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTagsRequest { /// The name of the parent package whose tags will be listed. @@ -1840,7 +1754,6 @@ pub struct ListTagsRequest { pub page_token: ::prost::alloc::string::String, } /// The response from listing tags. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTagsResponse { /// The tags returned. @@ -1852,7 +1765,6 @@ pub struct ListTagsResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to retrieve a tag. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetTagRequest { /// The name of the tag to retrieve. @@ -1860,7 +1772,6 @@ pub struct GetTagRequest { pub name: ::prost::alloc::string::String, } /// The request to create a new tag. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateTagRequest { /// The name of the parent resource where the tag will be created. @@ -1874,7 +1785,6 @@ pub struct CreateTagRequest { pub tag: ::core::option::Option, } /// The request to create or update a tag. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateTagRequest { /// The tag that replaces the resource on the server. @@ -1887,7 +1797,6 @@ pub struct UpdateTagRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// The request to delete a tag. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteTagRequest { /// The name of the tag to delete. @@ -1897,7 +1806,6 @@ pub struct DeleteTagRequest { /// The body of a version resource. A version resource represents a /// collection of components, such as files and other data. This may correspond /// to a version in many package management schemes. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Version { /// The name of the version, for example: @@ -1928,7 +1836,6 @@ pub struct Version { pub metadata: ::core::option::Option<::prost_types::Struct>, } /// The request to list versions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListVersionsRequest { /// The name of the parent resource whose versions will be listed. @@ -1948,7 +1855,6 @@ pub struct ListVersionsRequest { pub order_by: ::prost::alloc::string::String, } /// The response from listing versions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListVersionsResponse { /// The versions returned. @@ -1960,7 +1866,6 @@ pub struct ListVersionsResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request to retrieve a version. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetVersionRequest { /// The name of the version to retrieve. @@ -1971,7 +1876,6 @@ pub struct GetVersionRequest { pub view: i32, } /// The request to delete a version. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteVersionRequest { /// The name of the version to delete. @@ -1983,7 +1887,6 @@ pub struct DeleteVersionRequest { pub force: bool, } /// The request to delete multiple versions across a repository. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchDeleteVersionsRequest { /// The name of the repository holding all requested versions. @@ -1998,7 +1901,6 @@ pub struct BatchDeleteVersionsRequest { pub validate_only: bool, } /// The metadata of an LRO from deleting multiple versions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchDeleteVersionsMetadata { /// The versions the operation failed to delete. @@ -2025,9 +1927,9 @@ impl VersionView { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - VersionView::Unspecified => "VERSION_VIEW_UNSPECIFIED", - VersionView::Basic => "BASIC", - VersionView::Full => "FULL", + Self::Unspecified => "VERSION_VIEW_UNSPECIFIED", + Self::Basic => "BASIC", + Self::Full => "FULL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -2041,12 +1943,17 @@ impl VersionView { } } /// Metadata type for longrunning-operations, currently empty. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct OperationMetadata {} /// Generated client implementations. pub mod artifact_registry_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// The Artifact Registry API service. @@ -2081,8 +1988,8 @@ pub mod artifact_registry_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -2100,7 +2007,8 @@ pub mod artifact_registry_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { ArtifactRegistryClient::new(InterceptedService::new(inner, interceptor)) } @@ -2140,9 +2048,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/ListDockerImages", @@ -2159,9 +2068,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/GetDockerImage", @@ -2178,9 +2088,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/ListMavenArtifacts", @@ -2197,9 +2108,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/GetMavenArtifact", @@ -2216,9 +2128,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/ListNpmPackages", @@ -2235,9 +2148,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/GetNpmPackage", @@ -2254,9 +2168,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/ListPythonPackages", @@ -2273,9 +2188,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/GetPythonPackage", @@ -2296,9 +2212,10 @@ pub mod artifact_registry_client { request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/ImportAptArtifacts", @@ -2319,9 +2236,10 @@ pub mod artifact_registry_client { request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/ImportYumArtifacts", @@ -2338,9 +2256,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/ListRepositories", @@ -2357,9 +2276,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/GetRepository", @@ -2378,9 +2298,10 @@ pub mod artifact_registry_client { request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/CreateRepository", @@ -2397,9 +2318,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/UpdateRepository", @@ -2419,9 +2341,10 @@ pub mod artifact_registry_client { request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/DeleteRepository", @@ -2438,9 +2361,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/ListPackages", @@ -2457,9 +2381,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/GetPackage", @@ -2478,9 +2403,10 @@ pub mod artifact_registry_client { request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/DeletePackage", @@ -2497,9 +2423,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/ListVersions", @@ -2516,9 +2443,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/GetVersion", @@ -2537,9 +2465,10 @@ pub mod artifact_registry_client { request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/DeleteVersion", @@ -2558,9 +2487,10 @@ pub mod artifact_registry_client { request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/BatchDeleteVersions", @@ -2577,9 +2507,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.devtools.artifactregistry.v1.ArtifactRegistry/ListFiles"); @@ -2595,9 +2526,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.devtools.artifactregistry.v1.ArtifactRegistry/GetFile"); @@ -2613,9 +2545,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.devtools.artifactregistry.v1.ArtifactRegistry/ListTags"); @@ -2631,9 +2564,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.devtools.artifactregistry.v1.ArtifactRegistry/GetTag"); @@ -2649,9 +2583,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.devtools.artifactregistry.v1.ArtifactRegistry/CreateTag"); @@ -2667,9 +2602,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.devtools.artifactregistry.v1.ArtifactRegistry/UpdateTag"); @@ -2685,9 +2621,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.devtools.artifactregistry.v1.ArtifactRegistry/DeleteTag"); @@ -2703,9 +2640,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/SetIamPolicy", @@ -2722,9 +2660,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/GetIamPolicy", @@ -2744,9 +2683,10 @@ pub mod artifact_registry_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/TestIamPermissions", @@ -2763,9 +2703,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/GetProjectSettings", @@ -2782,9 +2723,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/UpdateProjectSettings", @@ -2801,9 +2743,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/GetVPCSCConfig", @@ -2820,9 +2763,10 @@ pub mod artifact_registry_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.devtools.artifactregistry.v1.ArtifactRegistry/UpdateVPCSCConfig", diff --git a/googleapis/src/google.iam.v1.rs b/googleapis/src/google.iam.v1.rs index e6457016..b721f241 100644 --- a/googleapis/src/google.iam.v1.rs +++ b/googleapis/src/google.iam.v1.rs @@ -1,6 +1,5 @@ // This file is @generated by prost-build. /// Encapsulates settings provided to GetIamPolicy. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct GetPolicyOptions { /// Optional. The maximum policy version that will be used to format the @@ -97,7 +96,6 @@ pub struct GetPolicyOptions { /// /// For a description of IAM and its features, see the /// [IAM documentation](). -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Policy { /// Specifies the format of the policy. @@ -158,7 +156,6 @@ pub struct Policy { pub etag: ::prost::alloc::vec::Vec, } /// Associates `members`, or principals, with a `role`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Binding { /// Role that is assigned to the list of `members`, or principals. @@ -277,7 +274,6 @@ pub struct Binding { /// For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ /// logging. It also exempts `jose@example.com` from DATA_READ logging, and /// `aliya@example.com` from DATA_WRITE logging. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AuditConfig { /// Specifies a service that will be enabled for audit logging. @@ -308,7 +304,6 @@ pub struct AuditConfig { /// /// This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting /// jose@example.com from DATA_READ logging. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AuditLogConfig { /// The log type that this config enables. @@ -344,10 +339,10 @@ pub mod audit_log_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - LogType::Unspecified => "LOG_TYPE_UNSPECIFIED", - LogType::AdminRead => "ADMIN_READ", - LogType::DataWrite => "DATA_WRITE", - LogType::DataRead => "DATA_READ", + Self::Unspecified => "LOG_TYPE_UNSPECIFIED", + Self::AdminRead => "ADMIN_READ", + Self::DataWrite => "DATA_WRITE", + Self::DataRead => "DATA_READ", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -363,7 +358,6 @@ pub mod audit_log_config { } } /// The difference delta between two policies. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PolicyDelta { /// The delta for Bindings between two policies. @@ -375,7 +369,6 @@ pub struct PolicyDelta { } /// One delta entry for Binding. Each individual change (only one member in each /// entry) to a binding will be a separate entry. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BindingDelta { /// The action that was performed on a Binding. @@ -416,9 +409,9 @@ pub mod binding_delta { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Action::Unspecified => "ACTION_UNSPECIFIED", - Action::Add => "ADD", - Action::Remove => "REMOVE", + Self::Unspecified => "ACTION_UNSPECIFIED", + Self::Add => "ADD", + Self::Remove => "REMOVE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -434,7 +427,6 @@ pub mod binding_delta { } /// One delta entry for AuditConfig. Each individual change (only one /// exempted_member in each entry) to a AuditConfig will be a separate entry. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AuditConfigDelta { /// The action that was performed on an audit configuration in a policy. @@ -478,9 +470,9 @@ pub mod audit_config_delta { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Action::Unspecified => "ACTION_UNSPECIFIED", - Action::Add => "ADD", - Action::Remove => "REMOVE", + Self::Unspecified => "ACTION_UNSPECIFIED", + Self::Add => "ADD", + Self::Remove => "REMOVE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -495,7 +487,6 @@ pub mod audit_config_delta { } } /// Request message for `SetIamPolicy` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct SetIamPolicyRequest { /// REQUIRED: The resource for which the policy is being specified. @@ -517,7 +508,6 @@ pub struct SetIamPolicyRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Request message for `GetIamPolicy` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetIamPolicyRequest { /// REQUIRED: The resource for which the policy is being requested. @@ -530,7 +520,6 @@ pub struct GetIamPolicyRequest { pub options: ::core::option::Option, } /// Request message for `TestIamPermissions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TestIamPermissionsRequest { /// REQUIRED: The resource for which the policy detail is being requested. @@ -545,7 +534,6 @@ pub struct TestIamPermissionsRequest { pub permissions: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Response message for `TestIamPermissions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TestIamPermissionsResponse { /// A subset of `TestPermissionsRequest.permissions` that the caller is @@ -555,7 +543,13 @@ pub struct TestIamPermissionsResponse { } /// Generated client implementations. pub mod iam_policy_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// API Overview @@ -603,8 +597,8 @@ pub mod iam_policy_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -622,7 +616,8 @@ pub mod iam_policy_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { IamPolicyClient::new(InterceptedService::new(inner, interceptor)) } @@ -665,9 +660,10 @@ pub mod iam_policy_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.iam.v1.IAMPolicy/SetIamPolicy"); let mut req = request.into_request(); @@ -682,9 +678,10 @@ pub mod iam_policy_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.iam.v1.IAMPolicy/GetIamPolicy"); let mut req = request.into_request(); @@ -703,9 +700,10 @@ pub mod iam_policy_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.iam.v1.IAMPolicy/TestIamPermissions"); let mut req = request.into_request(); diff --git a/googleapis/src/google.longrunning.rs b/googleapis/src/google.longrunning.rs index cce443aa..6d38a988 100644 --- a/googleapis/src/google.longrunning.rs +++ b/googleapis/src/google.longrunning.rs @@ -1,7 +1,6 @@ // This file is @generated by prost-build. /// This resource represents a long-running operation that is the result of a /// network API call. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Operation { /// The server-assigned name, which is only unique within the same service that @@ -31,7 +30,6 @@ pub mod operation { /// The operation result, which can be either an `error` or a valid `response`. /// If `done` == `false`, neither `error` nor `response` is set. /// If `done` == `true`, exactly one of `error` or `response` is set. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Result { /// The error result of the operation in case of failure or cancellation. @@ -50,7 +48,6 @@ pub mod operation { } } /// The request message for [Operations.GetOperation][google.longrunning.Operations.GetOperation]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetOperationRequest { /// The name of the operation resource. @@ -58,7 +55,6 @@ pub struct GetOperationRequest { pub name: ::prost::alloc::string::String, } /// The request message for [Operations.ListOperations][google.longrunning.Operations.ListOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListOperationsRequest { /// The name of the operation's parent resource. @@ -75,7 +71,6 @@ pub struct ListOperationsRequest { pub page_token: ::prost::alloc::string::String, } /// The response message for [Operations.ListOperations][google.longrunning.Operations.ListOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListOperationsResponse { /// A list of operations that matches the specified filter in the request. @@ -86,7 +81,6 @@ pub struct ListOperationsResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request message for [Operations.CancelOperation][google.longrunning.Operations.CancelOperation]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CancelOperationRequest { /// The name of the operation resource to be cancelled. @@ -94,7 +88,6 @@ pub struct CancelOperationRequest { pub name: ::prost::alloc::string::String, } /// The request message for [Operations.DeleteOperation][google.longrunning.Operations.DeleteOperation]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteOperationRequest { /// The name of the operation resource to be deleted. @@ -102,7 +95,6 @@ pub struct DeleteOperationRequest { pub name: ::prost::alloc::string::String, } /// The request message for [Operations.WaitOperation][google.longrunning.Operations.WaitOperation]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct WaitOperationRequest { /// The name of the operation resource to wait on. @@ -125,7 +117,6 @@ pub struct WaitOperationRequest { /// metadata_type: "LongRunningRecognizeMetadata" /// }; /// } -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct OperationInfo { /// Required. The message name of the primary return type for this @@ -150,7 +141,13 @@ pub struct OperationInfo { } /// Generated client implementations. pub mod operations_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// Manages long-running operations with an API service. @@ -181,8 +178,8 @@ pub mod operations_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -200,7 +197,8 @@ pub mod operations_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { OperationsClient::new(InterceptedService::new(inner, interceptor)) } @@ -249,9 +247,10 @@ pub mod operations_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.longrunning.Operations/ListOperations"); let mut req = request.into_request(); @@ -266,9 +265,10 @@ pub mod operations_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.longrunning.Operations/GetOperation"); let mut req = request.into_request(); @@ -284,9 +284,10 @@ pub mod operations_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.longrunning.Operations/DeleteOperation"); let mut req = request.into_request(); @@ -308,9 +309,10 @@ pub mod operations_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.longrunning.Operations/CancelOperation"); let mut req = request.into_request(); @@ -331,9 +333,10 @@ pub mod operations_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.longrunning.Operations/WaitOperation"); let mut req = request.into_request(); diff --git a/googleapis/src/google.monitoring.v3.rs b/googleapis/src/google.monitoring.v3.rs new file mode 100644 index 00000000..25746276 --- /dev/null +++ b/googleapis/src/google.monitoring.v3.rs @@ -0,0 +1,1465 @@ +// This file is @generated by prost-build. +/// A single strongly-typed value. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct TypedValue { + /// The typed value field. + #[prost(oneof = "typed_value::Value", tags = "1, 2, 3, 4, 5")] + pub value: ::core::option::Option, +} +/// Nested message and enum types in `TypedValue`. +pub mod typed_value { + /// The typed value field. + #[derive(Clone, PartialEq, ::prost::Oneof)] + pub enum Value { + /// A Boolean value: `true` or `false`. + #[prost(bool, tag = "1")] + BoolValue(bool), + /// A 64-bit integer. Its range is approximately ±9.2x1018. + #[prost(int64, tag = "2")] + Int64Value(i64), + /// A 64-bit double-precision floating-point number. Its magnitude + /// is approximately ±10±300 and it has 16 + /// significant digits of precision. + #[prost(double, tag = "3")] + DoubleValue(f64), + /// A variable-length string value. + #[prost(string, tag = "4")] + StringValue(::prost::alloc::string::String), + /// A distribution value. + #[prost(message, tag = "5")] + DistributionValue(super::super::super::api::Distribution), + } +} +/// Describes a time interval: +/// +/// * Reads: A half-open time interval. It includes the end time but +/// excludes the start time: `(startTime, endTime]`. The start time +/// must be specified, must be earlier than the end time, and should be +/// no older than the data retention period for the metric. +/// * Writes: A closed time interval. It extends from the start time to the end +/// time, +/// and includes both: `\[startTime, endTime\]`. Valid time intervals +/// depend on the +/// [`MetricKind`]() +/// of the metric value. The end time must not be earlier than the start +/// time, and the end time must not be more than 25 hours in the past or more +/// than five minutes in the future. +/// * For `GAUGE` metrics, the `startTime` value is technically optional; if +/// no value is specified, the start time defaults to the value of the +/// end time, and the interval represents a single point in time. If both +/// start and end times are specified, they must be identical. Such an +/// interval is valid only for `GAUGE` metrics, which are point-in-time +/// measurements. The end time of a new interval must be at least a +/// millisecond after the end time of the previous interval. +/// * For `DELTA` metrics, the start time and end time must specify a +/// non-zero interval, with subsequent points specifying contiguous and +/// non-overlapping intervals. For `DELTA` metrics, the start time of +/// the next interval must be at least a millisecond after the end time +/// of the previous interval. +/// * For `CUMULATIVE` metrics, the start time and end time must specify a +/// non-zero interval, with subsequent points specifying the same +/// start time and increasing end times, until an event resets the +/// cumulative value to zero and sets a new start time for the following +/// points. The new start time must be at least a millisecond after the +/// end time of the previous interval. +/// * The start time of a new interval must be at least a millisecond after +/// the +/// end time of the previous interval because intervals are closed. If the +/// start time of a new interval is the same as the end time of the +/// previous interval, then data written at the new start time could +/// overwrite data written at the previous end time. +#[derive(Clone, Copy, PartialEq, ::prost::Message)] +pub struct TimeInterval { + /// Required. The end of the time interval. + #[prost(message, optional, tag = "2")] + pub end_time: ::core::option::Option<::prost_types::Timestamp>, + /// Optional. The beginning of the time interval. The default value + /// for the start time is the end time. The start time must not be + /// later than the end time. + #[prost(message, optional, tag = "1")] + pub start_time: ::core::option::Option<::prost_types::Timestamp>, +} +/// Describes how to combine multiple time series to provide a different view of +/// the data. Aggregation of time series is done in two steps. First, each time +/// series in the set is _aligned_ to the same time interval boundaries, then the +/// set of time series is optionally _reduced_ in number. +/// +/// Alignment consists of applying the `per_series_aligner` operation +/// to each time series after its data has been divided into regular +/// `alignment_period` time intervals. This process takes _all_ of the data +/// points in an alignment period, applies a mathematical transformation such as +/// averaging, minimum, maximum, delta, etc., and converts them into a single +/// data point per period. +/// +/// Reduction is when the aligned and transformed time series can optionally be +/// combined, reducing the number of time series through similar mathematical +/// transformations. Reduction involves applying a `cross_series_reducer` to +/// all the time series, optionally sorting the time series into subsets with +/// `group_by_fields`, and applying the reducer to each subset. +/// +/// The raw time series data can contain a huge amount of information from +/// multiple sources. Alignment and reduction transforms this mass of data into +/// a more manageable and representative collection of data, for example "the +/// 95% latency across the average of all tasks in a cluster". This +/// representative data can be more easily graphed and comprehended, and the +/// individual time series data is still available for later drilldown. For more +/// details, see [Filtering and +/// aggregation](). +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct Aggregation { + /// The `alignment_period` specifies a time interval, in seconds, that is used + /// to divide the data in all the + /// [time series][google.monitoring.v3.TimeSeries] into consistent blocks of + /// time. This will be done before the per-series aligner can be applied to + /// the data. + /// + /// The value must be at least 60 seconds. If a per-series + /// aligner other than `ALIGN_NONE` is specified, this field is required or an + /// error is returned. If no per-series aligner is specified, or the aligner + /// `ALIGN_NONE` is specified, then this field is ignored. + /// + /// The maximum value of the `alignment_period` is 104 weeks (2 years) for + /// charts, and 90,000 seconds (25 hours) for alerting policies. + #[prost(message, optional, tag = "1")] + pub alignment_period: ::core::option::Option<::prost_types::Duration>, + /// An `Aligner` describes how to bring the data points in a single + /// time series into temporal alignment. Except for `ALIGN_NONE`, all + /// alignments cause all the data points in an `alignment_period` to be + /// mathematically grouped together, resulting in a single data point for + /// each `alignment_period` with end timestamp at the end of the period. + /// + /// Not all alignment operations may be applied to all time series. The valid + /// choices depend on the `metric_kind` and `value_type` of the original time + /// series. Alignment can change the `metric_kind` or the `value_type` of + /// the time series. + /// + /// Time series data must be aligned in order to perform cross-time + /// series reduction. If `cross_series_reducer` is specified, then + /// `per_series_aligner` must be specified and not equal to `ALIGN_NONE` + /// and `alignment_period` must be specified; otherwise, an error is + /// returned. + #[prost(enumeration = "aggregation::Aligner", tag = "2")] + pub per_series_aligner: i32, + /// The reduction operation to be used to combine time series into a single + /// time series, where the value of each data point in the resulting series is + /// a function of all the already aligned values in the input time series. + /// + /// Not all reducer operations can be applied to all time series. The valid + /// choices depend on the `metric_kind` and the `value_type` of the original + /// time series. Reduction can yield a time series with a different + /// `metric_kind` or `value_type` than the input time series. + /// + /// Time series data must first be aligned (see `per_series_aligner`) in order + /// to perform cross-time series reduction. If `cross_series_reducer` is + /// specified, then `per_series_aligner` must be specified, and must not be + /// `ALIGN_NONE`. An `alignment_period` must also be specified; otherwise, an + /// error is returned. + #[prost(enumeration = "aggregation::Reducer", tag = "4")] + pub cross_series_reducer: i32, + /// The set of fields to preserve when `cross_series_reducer` is + /// specified. The `group_by_fields` determine how the time series are + /// partitioned into subsets prior to applying the aggregation + /// operation. Each subset contains time series that have the same + /// value for each of the grouping fields. Each individual time + /// series is a member of exactly one subset. The + /// `cross_series_reducer` is applied to each subset of time series. + /// It is not possible to reduce across different resource types, so + /// this field implicitly contains `resource.type`. Fields not + /// specified in `group_by_fields` are aggregated away. If + /// `group_by_fields` is not specified and all the time series have + /// the same resource type, then the time series are aggregated into + /// a single output time series. If `cross_series_reducer` is not + /// defined, this field is ignored. + #[prost(string, repeated, tag = "5")] + pub group_by_fields: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, +} +/// Nested message and enum types in `Aggregation`. +pub mod aggregation { + /// The `Aligner` specifies the operation that will be applied to the data + /// points in each alignment period in a time series. Except for + /// `ALIGN_NONE`, which specifies that no operation be applied, each alignment + /// operation replaces the set of data values in each alignment period with + /// a single value: the result of applying the operation to the data values. + /// An aligned time series has a single data value at the end of each + /// `alignment_period`. + /// + /// An alignment operation can change the data type of the values, too. For + /// example, if you apply a counting operation to boolean values, the data + /// `value_type` in the original time series is `BOOLEAN`, but the `value_type` + /// in the aligned result is `INT64`. + #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] + #[repr(i32)] + pub enum Aligner { + /// No alignment. Raw data is returned. Not valid if cross-series reduction + /// is requested. The `value_type` of the result is the same as the + /// `value_type` of the input. + AlignNone = 0, + /// Align and convert to + /// [DELTA][google.api.MetricDescriptor.MetricKind.DELTA]. + /// The output is `delta = y1 - y0`. + /// + /// This alignment is valid for + /// [CUMULATIVE][google.api.MetricDescriptor.MetricKind.CUMULATIVE] and + /// `DELTA` metrics. If the selected alignment period results in periods + /// with no data, then the aligned value for such a period is created by + /// interpolation. The `value_type` of the aligned result is the same as + /// the `value_type` of the input. + AlignDelta = 1, + /// Align and convert to a rate. The result is computed as + /// `rate = (y1 - y0)/(t1 - t0)`, or "delta over time". + /// Think of this aligner as providing the slope of the line that passes + /// through the value at the start and at the end of the `alignment_period`. + /// + /// This aligner is valid for `CUMULATIVE` + /// and `DELTA` metrics with numeric values. If the selected alignment + /// period results in periods with no data, then the aligned value for + /// such a period is created by interpolation. The output is a `GAUGE` + /// metric with `value_type` `DOUBLE`. + /// + /// If, by "rate", you mean "percentage change", see the + /// `ALIGN_PERCENT_CHANGE` aligner instead. + AlignRate = 2, + /// Align by interpolating between adjacent points around the alignment + /// period boundary. This aligner is valid for `GAUGE` metrics with + /// numeric values. The `value_type` of the aligned result is the same as the + /// `value_type` of the input. + AlignInterpolate = 3, + /// Align by moving the most recent data point before the end of the + /// alignment period to the boundary at the end of the alignment + /// period. This aligner is valid for `GAUGE` metrics. The `value_type` of + /// the aligned result is the same as the `value_type` of the input. + AlignNextOlder = 4, + /// Align the time series by returning the minimum value in each alignment + /// period. This aligner is valid for `GAUGE` and `DELTA` metrics with + /// numeric values. The `value_type` of the aligned result is the same as + /// the `value_type` of the input. + AlignMin = 10, + /// Align the time series by returning the maximum value in each alignment + /// period. This aligner is valid for `GAUGE` and `DELTA` metrics with + /// numeric values. The `value_type` of the aligned result is the same as + /// the `value_type` of the input. + AlignMax = 11, + /// Align the time series by returning the mean value in each alignment + /// period. This aligner is valid for `GAUGE` and `DELTA` metrics with + /// numeric values. The `value_type` of the aligned result is `DOUBLE`. + AlignMean = 12, + /// Align the time series by returning the number of values in each alignment + /// period. This aligner is valid for `GAUGE` and `DELTA` metrics with + /// numeric or Boolean values. The `value_type` of the aligned result is + /// `INT64`. + AlignCount = 13, + /// Align the time series by returning the sum of the values in each + /// alignment period. This aligner is valid for `GAUGE` and `DELTA` + /// metrics with numeric and distribution values. The `value_type` of the + /// aligned result is the same as the `value_type` of the input. + AlignSum = 14, + /// Align the time series by returning the standard deviation of the values + /// in each alignment period. This aligner is valid for `GAUGE` and + /// `DELTA` metrics with numeric values. The `value_type` of the output is + /// `DOUBLE`. + AlignStddev = 15, + /// Align the time series by returning the number of `True` values in + /// each alignment period. This aligner is valid for `GAUGE` metrics with + /// Boolean values. The `value_type` of the output is `INT64`. + AlignCountTrue = 16, + /// Align the time series by returning the number of `False` values in + /// each alignment period. This aligner is valid for `GAUGE` metrics with + /// Boolean values. The `value_type` of the output is `INT64`. + AlignCountFalse = 24, + /// Align the time series by returning the ratio of the number of `True` + /// values to the total number of values in each alignment period. This + /// aligner is valid for `GAUGE` metrics with Boolean values. The output + /// value is in the range \[0.0, 1.0\] and has `value_type` `DOUBLE`. + AlignFractionTrue = 17, + /// Align the time series by using [percentile + /// aggregation](). The resulting + /// data point in each alignment period is the 99th percentile of all data + /// points in the period. This aligner is valid for `GAUGE` and `DELTA` + /// metrics with distribution values. The output is a `GAUGE` metric with + /// `value_type` `DOUBLE`. + AlignPercentile99 = 18, + /// Align the time series by using [percentile + /// aggregation](). The resulting + /// data point in each alignment period is the 95th percentile of all data + /// points in the period. This aligner is valid for `GAUGE` and `DELTA` + /// metrics with distribution values. The output is a `GAUGE` metric with + /// `value_type` `DOUBLE`. + AlignPercentile95 = 19, + /// Align the time series by using [percentile + /// aggregation](). The resulting + /// data point in each alignment period is the 50th percentile of all data + /// points in the period. This aligner is valid for `GAUGE` and `DELTA` + /// metrics with distribution values. The output is a `GAUGE` metric with + /// `value_type` `DOUBLE`. + AlignPercentile50 = 20, + /// Align the time series by using [percentile + /// aggregation](). The resulting + /// data point in each alignment period is the 5th percentile of all data + /// points in the period. This aligner is valid for `GAUGE` and `DELTA` + /// metrics with distribution values. The output is a `GAUGE` metric with + /// `value_type` `DOUBLE`. + AlignPercentile05 = 21, + /// Align and convert to a percentage change. This aligner is valid for + /// `GAUGE` and `DELTA` metrics with numeric values. This alignment returns + /// `((current - previous)/previous) * 100`, where the value of `previous` is + /// determined based on the `alignment_period`. + /// + /// If the values of `current` and `previous` are both 0, then the returned + /// value is 0. If only `previous` is 0, the returned value is infinity. + /// + /// A 10-minute moving mean is computed at each point of the alignment period + /// prior to the above calculation to smooth the metric and prevent false + /// positives from very short-lived spikes. The moving mean is only + /// applicable for data whose values are `>= 0`. Any values `< 0` are + /// treated as a missing datapoint, and are ignored. While `DELTA` + /// metrics are accepted by this alignment, special care should be taken that + /// the values for the metric will always be positive. The output is a + /// `GAUGE` metric with `value_type` `DOUBLE`. + AlignPercentChange = 23, + } + impl Aligner { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::AlignNone => "ALIGN_NONE", + Self::AlignDelta => "ALIGN_DELTA", + Self::AlignRate => "ALIGN_RATE", + Self::AlignInterpolate => "ALIGN_INTERPOLATE", + Self::AlignNextOlder => "ALIGN_NEXT_OLDER", + Self::AlignMin => "ALIGN_MIN", + Self::AlignMax => "ALIGN_MAX", + Self::AlignMean => "ALIGN_MEAN", + Self::AlignCount => "ALIGN_COUNT", + Self::AlignSum => "ALIGN_SUM", + Self::AlignStddev => "ALIGN_STDDEV", + Self::AlignCountTrue => "ALIGN_COUNT_TRUE", + Self::AlignCountFalse => "ALIGN_COUNT_FALSE", + Self::AlignFractionTrue => "ALIGN_FRACTION_TRUE", + Self::AlignPercentile99 => "ALIGN_PERCENTILE_99", + Self::AlignPercentile95 => "ALIGN_PERCENTILE_95", + Self::AlignPercentile50 => "ALIGN_PERCENTILE_50", + Self::AlignPercentile05 => "ALIGN_PERCENTILE_05", + Self::AlignPercentChange => "ALIGN_PERCENT_CHANGE", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "ALIGN_NONE" => Some(Self::AlignNone), + "ALIGN_DELTA" => Some(Self::AlignDelta), + "ALIGN_RATE" => Some(Self::AlignRate), + "ALIGN_INTERPOLATE" => Some(Self::AlignInterpolate), + "ALIGN_NEXT_OLDER" => Some(Self::AlignNextOlder), + "ALIGN_MIN" => Some(Self::AlignMin), + "ALIGN_MAX" => Some(Self::AlignMax), + "ALIGN_MEAN" => Some(Self::AlignMean), + "ALIGN_COUNT" => Some(Self::AlignCount), + "ALIGN_SUM" => Some(Self::AlignSum), + "ALIGN_STDDEV" => Some(Self::AlignStddev), + "ALIGN_COUNT_TRUE" => Some(Self::AlignCountTrue), + "ALIGN_COUNT_FALSE" => Some(Self::AlignCountFalse), + "ALIGN_FRACTION_TRUE" => Some(Self::AlignFractionTrue), + "ALIGN_PERCENTILE_99" => Some(Self::AlignPercentile99), + "ALIGN_PERCENTILE_95" => Some(Self::AlignPercentile95), + "ALIGN_PERCENTILE_50" => Some(Self::AlignPercentile50), + "ALIGN_PERCENTILE_05" => Some(Self::AlignPercentile05), + "ALIGN_PERCENT_CHANGE" => Some(Self::AlignPercentChange), + _ => None, + } + } + } + /// A Reducer operation describes how to aggregate data points from multiple + /// time series into a single time series, where the value of each data point + /// in the resulting series is a function of all the already aligned values in + /// the input time series. + #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] + #[repr(i32)] + pub enum Reducer { + /// No cross-time series reduction. The output of the `Aligner` is + /// returned. + ReduceNone = 0, + /// Reduce by computing the mean value across time series for each + /// alignment period. This reducer is valid for + /// [DELTA][google.api.MetricDescriptor.MetricKind.DELTA] and + /// [GAUGE][google.api.MetricDescriptor.MetricKind.GAUGE] metrics with + /// numeric or distribution values. The `value_type` of the output is + /// [DOUBLE][google.api.MetricDescriptor.ValueType.DOUBLE]. + ReduceMean = 1, + /// Reduce by computing the minimum value across time series for each + /// alignment period. This reducer is valid for `DELTA` and `GAUGE` metrics + /// with numeric values. The `value_type` of the output is the same as the + /// `value_type` of the input. + ReduceMin = 2, + /// Reduce by computing the maximum value across time series for each + /// alignment period. This reducer is valid for `DELTA` and `GAUGE` metrics + /// with numeric values. The `value_type` of the output is the same as the + /// `value_type` of the input. + ReduceMax = 3, + /// Reduce by computing the sum across time series for each + /// alignment period. This reducer is valid for `DELTA` and `GAUGE` metrics + /// with numeric and distribution values. The `value_type` of the output is + /// the same as the `value_type` of the input. + ReduceSum = 4, + /// Reduce by computing the standard deviation across time series + /// for each alignment period. This reducer is valid for `DELTA` and + /// `GAUGE` metrics with numeric or distribution values. The `value_type` + /// of the output is `DOUBLE`. + ReduceStddev = 5, + /// Reduce by computing the number of data points across time series + /// for each alignment period. This reducer is valid for `DELTA` and + /// `GAUGE` metrics of numeric, Boolean, distribution, and string + /// `value_type`. The `value_type` of the output is `INT64`. + ReduceCount = 6, + /// Reduce by computing the number of `True`-valued data points across time + /// series for each alignment period. This reducer is valid for `DELTA` and + /// `GAUGE` metrics of Boolean `value_type`. The `value_type` of the output + /// is `INT64`. + ReduceCountTrue = 7, + /// Reduce by computing the number of `False`-valued data points across time + /// series for each alignment period. This reducer is valid for `DELTA` and + /// `GAUGE` metrics of Boolean `value_type`. The `value_type` of the output + /// is `INT64`. + ReduceCountFalse = 15, + /// Reduce by computing the ratio of the number of `True`-valued data points + /// to the total number of data points for each alignment period. This + /// reducer is valid for `DELTA` and `GAUGE` metrics of Boolean `value_type`. + /// The output value is in the range \[0.0, 1.0\] and has `value_type` + /// `DOUBLE`. + ReduceFractionTrue = 8, + /// Reduce by computing the [99th + /// percentile]() of data points + /// across time series for each alignment period. This reducer is valid for + /// `GAUGE` and `DELTA` metrics of numeric and distribution type. The value + /// of the output is `DOUBLE`. + ReducePercentile99 = 9, + /// Reduce by computing the [95th + /// percentile]() of data points + /// across time series for each alignment period. This reducer is valid for + /// `GAUGE` and `DELTA` metrics of numeric and distribution type. The value + /// of the output is `DOUBLE`. + ReducePercentile95 = 10, + /// Reduce by computing the [50th + /// percentile]() of data points + /// across time series for each alignment period. This reducer is valid for + /// `GAUGE` and `DELTA` metrics of numeric and distribution type. The value + /// of the output is `DOUBLE`. + ReducePercentile50 = 11, + /// Reduce by computing the [5th + /// percentile]() of data points + /// across time series for each alignment period. This reducer is valid for + /// `GAUGE` and `DELTA` metrics of numeric and distribution type. The value + /// of the output is `DOUBLE`. + ReducePercentile05 = 12, + } + impl Reducer { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::ReduceNone => "REDUCE_NONE", + Self::ReduceMean => "REDUCE_MEAN", + Self::ReduceMin => "REDUCE_MIN", + Self::ReduceMax => "REDUCE_MAX", + Self::ReduceSum => "REDUCE_SUM", + Self::ReduceStddev => "REDUCE_STDDEV", + Self::ReduceCount => "REDUCE_COUNT", + Self::ReduceCountTrue => "REDUCE_COUNT_TRUE", + Self::ReduceCountFalse => "REDUCE_COUNT_FALSE", + Self::ReduceFractionTrue => "REDUCE_FRACTION_TRUE", + Self::ReducePercentile99 => "REDUCE_PERCENTILE_99", + Self::ReducePercentile95 => "REDUCE_PERCENTILE_95", + Self::ReducePercentile50 => "REDUCE_PERCENTILE_50", + Self::ReducePercentile05 => "REDUCE_PERCENTILE_05", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "REDUCE_NONE" => Some(Self::ReduceNone), + "REDUCE_MEAN" => Some(Self::ReduceMean), + "REDUCE_MIN" => Some(Self::ReduceMin), + "REDUCE_MAX" => Some(Self::ReduceMax), + "REDUCE_SUM" => Some(Self::ReduceSum), + "REDUCE_STDDEV" => Some(Self::ReduceStddev), + "REDUCE_COUNT" => Some(Self::ReduceCount), + "REDUCE_COUNT_TRUE" => Some(Self::ReduceCountTrue), + "REDUCE_COUNT_FALSE" => Some(Self::ReduceCountFalse), + "REDUCE_FRACTION_TRUE" => Some(Self::ReduceFractionTrue), + "REDUCE_PERCENTILE_99" => Some(Self::ReducePercentile99), + "REDUCE_PERCENTILE_95" => Some(Self::ReducePercentile95), + "REDUCE_PERCENTILE_50" => Some(Self::ReducePercentile50), + "REDUCE_PERCENTILE_05" => Some(Self::ReducePercentile05), + _ => None, + } + } + } +} +/// Specifies an ordering relationship on two arguments, called `left` and +/// `right`. +#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] +#[repr(i32)] +pub enum ComparisonType { + /// No ordering relationship is specified. + ComparisonUnspecified = 0, + /// True if the left argument is greater than the right argument. + ComparisonGt = 1, + /// True if the left argument is greater than or equal to the right argument. + ComparisonGe = 2, + /// True if the left argument is less than the right argument. + ComparisonLt = 3, + /// True if the left argument is less than or equal to the right argument. + ComparisonLe = 4, + /// True if the left argument is equal to the right argument. + ComparisonEq = 5, + /// True if the left argument is not equal to the right argument. + ComparisonNe = 6, +} +impl ComparisonType { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::ComparisonUnspecified => "COMPARISON_UNSPECIFIED", + Self::ComparisonGt => "COMPARISON_GT", + Self::ComparisonGe => "COMPARISON_GE", + Self::ComparisonLt => "COMPARISON_LT", + Self::ComparisonLe => "COMPARISON_LE", + Self::ComparisonEq => "COMPARISON_EQ", + Self::ComparisonNe => "COMPARISON_NE", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "COMPARISON_UNSPECIFIED" => Some(Self::ComparisonUnspecified), + "COMPARISON_GT" => Some(Self::ComparisonGt), + "COMPARISON_GE" => Some(Self::ComparisonGe), + "COMPARISON_LT" => Some(Self::ComparisonLt), + "COMPARISON_LE" => Some(Self::ComparisonLe), + "COMPARISON_EQ" => Some(Self::ComparisonEq), + "COMPARISON_NE" => Some(Self::ComparisonNe), + _ => None, + } + } +} +/// The tier of service for a Metrics Scope. Please see the +/// [service tiers +/// documentation]() for more +/// details. +#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] +#[repr(i32)] +pub enum ServiceTier { + /// An invalid sentinel value, used to indicate that a tier has not + /// been provided explicitly. + Unspecified = 0, + /// The Cloud Monitoring Basic tier, a free tier of service that provides basic + /// features, a moderate allotment of logs, and access to built-in metrics. + /// A number of features are not available in this tier. For more details, + /// see [the service tiers + /// documentation](). + Basic = 1, + /// The Cloud Monitoring Premium tier, a higher, more expensive tier of service + /// that provides access to all Cloud Monitoring features, lets you use Cloud + /// Monitoring with AWS accounts, and has a larger allotments for logs and + /// metrics. For more details, see [the service tiers + /// documentation](). + Premium = 2, +} +impl ServiceTier { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::Unspecified => "SERVICE_TIER_UNSPECIFIED", + Self::Basic => "SERVICE_TIER_BASIC", + Self::Premium => "SERVICE_TIER_PREMIUM", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "SERVICE_TIER_UNSPECIFIED" => Some(Self::Unspecified), + "SERVICE_TIER_BASIC" => Some(Self::Basic), + "SERVICE_TIER_PREMIUM" => Some(Self::Premium), + _ => None, + } + } +} +/// A single data point in a time series. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct Point { + /// The time interval to which the data point applies. For `GAUGE` metrics, + /// the start time is optional, but if it is supplied, it must equal the + /// end time. For `DELTA` metrics, the start + /// and end time should specify a non-zero interval, with subsequent points + /// specifying contiguous and non-overlapping intervals. For `CUMULATIVE` + /// metrics, the start and end time should specify a non-zero interval, with + /// subsequent points specifying the same start time and increasing end times, + /// until an event resets the cumulative value to zero and sets a new start + /// time for the following points. + #[prost(message, optional, tag = "1")] + pub interval: ::core::option::Option, + /// The value of the data point. + #[prost(message, optional, tag = "2")] + pub value: ::core::option::Option, +} +/// A collection of data points that describes the time-varying values +/// of a metric. A time series is identified by a combination of a +/// fully-specified monitored resource and a fully-specified metric. +/// This type is used for both listing and creating time series. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct TimeSeries { + /// The associated metric. A fully-specified metric used to identify the time + /// series. + #[prost(message, optional, tag = "1")] + pub metric: ::core::option::Option, + /// The associated monitored resource. Custom metrics can use only certain + /// monitored resource types in their time series data. For more information, + /// see [Monitored resources for custom + /// metrics](). + #[prost(message, optional, tag = "2")] + pub resource: ::core::option::Option, + /// Output only. The associated monitored resource metadata. When reading a + /// time series, this field will include metadata labels that are explicitly + /// named in the reduction. When creating a time series, this field is ignored. + #[prost(message, optional, tag = "7")] + pub metadata: ::core::option::Option, + /// The metric kind of the time series. When listing time series, this metric + /// kind might be different from the metric kind of the associated metric if + /// this time series is an alignment or reduction of other time series. + /// + /// When creating a time series, this field is optional. If present, it must be + /// the same as the metric kind of the associated metric. If the associated + /// metric's descriptor must be auto-created, then this field specifies the + /// metric kind of the new descriptor and must be either `GAUGE` (the default) + /// or `CUMULATIVE`. + #[prost(enumeration = "super::super::api::metric_descriptor::MetricKind", tag = "3")] + pub metric_kind: i32, + /// The value type of the time series. When listing time series, this value + /// type might be different from the value type of the associated metric if + /// this time series is an alignment or reduction of other time series. + /// + /// When creating a time series, this field is optional. If present, it must be + /// the same as the type of the data in the `points` field. + #[prost(enumeration = "super::super::api::metric_descriptor::ValueType", tag = "4")] + pub value_type: i32, + /// The data points of this time series. When listing time series, points are + /// returned in reverse time order. + /// + /// When creating a time series, this field must contain exactly one point and + /// the point's type must be the same as the value type of the associated + /// metric. If the associated metric's descriptor must be auto-created, then + /// the value type of the descriptor is determined by the point's type, which + /// must be `BOOL`, `INT64`, `DOUBLE`, or `DISTRIBUTION`. + #[prost(message, repeated, tag = "5")] + pub points: ::prost::alloc::vec::Vec, + /// The units in which the metric value is reported. It is only applicable + /// if the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The `unit` + /// defines the representation of the stored metric values. + #[prost(string, tag = "8")] + pub unit: ::prost::alloc::string::String, +} +/// A descriptor for the labels and points in a time series. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct TimeSeriesDescriptor { + /// Descriptors for the labels. + #[prost(message, repeated, tag = "1")] + pub label_descriptors: ::prost::alloc::vec::Vec, + /// Descriptors for the point data value columns. + #[prost(message, repeated, tag = "5")] + pub point_descriptors: ::prost::alloc::vec::Vec, +} +/// Nested message and enum types in `TimeSeriesDescriptor`. +pub mod time_series_descriptor { + /// A descriptor for the value columns in a data point. + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct ValueDescriptor { + /// The value key. + #[prost(string, tag = "1")] + pub key: ::prost::alloc::string::String, + /// The value type. + #[prost(enumeration = "super::super::super::api::metric_descriptor::ValueType", tag = "2")] + pub value_type: i32, + /// The value stream kind. + #[prost(enumeration = "super::super::super::api::metric_descriptor::MetricKind", tag = "3")] + pub metric_kind: i32, + /// The unit in which `time_series` point values are reported. `unit` + /// follows the UCUM format for units as seen in + /// + /// `unit` is only valid if `value_type` is INTEGER, DOUBLE, DISTRIBUTION. + #[prost(string, tag = "4")] + pub unit: ::prost::alloc::string::String, + } +} +/// Represents the values of a time series associated with a +/// TimeSeriesDescriptor. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct TimeSeriesData { + /// The values of the labels in the time series identifier, given in the same + /// order as the `label_descriptors` field of the TimeSeriesDescriptor + /// associated with this object. Each value must have a value of the type + /// given in the corresponding entry of `label_descriptors`. + #[prost(message, repeated, tag = "1")] + pub label_values: ::prost::alloc::vec::Vec, + /// The points in the time series. + #[prost(message, repeated, tag = "2")] + pub point_data: ::prost::alloc::vec::Vec, +} +/// Nested message and enum types in `TimeSeriesData`. +pub mod time_series_data { + /// A point's value columns and time interval. Each point has one or more + /// point values corresponding to the entries in `point_descriptors` field in + /// the TimeSeriesDescriptor associated with this object. + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct PointData { + /// The values that make up the point. + #[prost(message, repeated, tag = "1")] + pub values: ::prost::alloc::vec::Vec, + /// The time interval associated with the point. + #[prost(message, optional, tag = "2")] + pub time_interval: ::core::option::Option, + } +} +/// A label value. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct LabelValue { + /// The label value can be a bool, int64, or string. + #[prost(oneof = "label_value::Value", tags = "1, 2, 3")] + pub value: ::core::option::Option, +} +/// Nested message and enum types in `LabelValue`. +pub mod label_value { + /// The label value can be a bool, int64, or string. + #[derive(Clone, PartialEq, ::prost::Oneof)] + pub enum Value { + /// A bool label value. + #[prost(bool, tag = "1")] + BoolValue(bool), + /// An int64 label value. + #[prost(int64, tag = "2")] + Int64Value(i64), + /// A string label value. + #[prost(string, tag = "3")] + StringValue(::prost::alloc::string::String), + } +} +/// An error associated with a query in the time series query language format. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct QueryError { + /// The location of the time series query language text that this error applies + /// to. + #[prost(message, optional, tag = "1")] + pub locator: ::core::option::Option, + /// The error message. + #[prost(string, tag = "2")] + pub message: ::prost::alloc::string::String, +} +/// A locator for text. Indicates a particular part of the text of a request or +/// of an object referenced in the request. +/// +/// For example, suppose the request field `text` contains: +/// +/// text: "The quick brown fox jumps over the lazy dog." +/// +/// Then the locator: +/// +/// source: "text" +/// start_position { +/// line: 1 +/// column: 17 +/// } +/// end_position { +/// line: 1 +/// column: 19 +/// } +/// +/// refers to the part of the text: "fox". +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct TextLocator { + /// The source of the text. The source may be a field in the request, in which + /// case its format is the format of the + /// google.rpc.BadRequest.FieldViolation.field field in + /// It may also be + /// be a source other than the request field (e.g. a macro definition + /// referenced in the text of the query), in which case this is the name of + /// the source (e.g. the macro name). + #[prost(string, tag = "1")] + pub source: ::prost::alloc::string::String, + /// The position of the first byte within the text. + #[prost(message, optional, tag = "2")] + pub start_position: ::core::option::Option, + /// The position of the last byte within the text. + #[prost(message, optional, tag = "3")] + pub end_position: ::core::option::Option, + /// If `source`, `start_position`, and `end_position` describe a call on + /// some object (e.g. a macro in the time series query language text) and a + /// location is to be designated in that object's text, `nested_locator` + /// identifies the location within that object. + #[prost(message, optional, boxed, tag = "4")] + pub nested_locator: ::core::option::Option<::prost::alloc::boxed::Box>, + /// When `nested_locator` is set, this field gives the reason for the nesting. + /// Usually, the reason is a macro invocation. In that case, the macro name + /// (including the leading '@') signals the location of the macro call + /// in the text and a macro argument name (including the leading '$') signals + /// the location of the macro argument inside the macro body that got + /// substituted away. + #[prost(string, tag = "5")] + pub nesting_reason: ::prost::alloc::string::String, +} +/// Nested message and enum types in `TextLocator`. +pub mod text_locator { + /// The position of a byte within the text. + #[derive(Clone, Copy, PartialEq, ::prost::Message)] + pub struct Position { + /// The line, starting with 1, where the byte is positioned. + #[prost(int32, tag = "1")] + pub line: i32, + /// The column within the line, starting with 1, where the byte is + /// positioned. This is a byte index even though the text is UTF-8. + #[prost(int32, tag = "2")] + pub column: i32, + } +} +/// The `ListMonitoredResourceDescriptors` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListMonitoredResourceDescriptorsRequest { + /// Required. The + /// [project]() on which + /// to execute the request. The format is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\] + #[prost(string, tag = "5")] + pub name: ::prost::alloc::string::String, + /// An optional [filter]() + /// describing the descriptors to be returned. The filter can reference the + /// descriptor's type and labels. For example, the following filter returns + /// only Google Compute Engine descriptors that have an `id` label: + /// + /// resource.type = starts_with("gce_") AND resource.label:id + #[prost(string, tag = "2")] + pub filter: ::prost::alloc::string::String, + /// A positive number that is the maximum number of results to return. + #[prost(int32, tag = "3")] + pub page_size: i32, + /// If this field is not empty then it must contain the `nextPageToken` value + /// returned by a previous call to this method. Using this field causes the + /// method to return additional results from the previous method call. + #[prost(string, tag = "4")] + pub page_token: ::prost::alloc::string::String, +} +/// The `ListMonitoredResourceDescriptors` response. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListMonitoredResourceDescriptorsResponse { + /// The monitored resource descriptors that are available to this project + /// and that match `filter`, if present. + #[prost(message, repeated, tag = "1")] + pub resource_descriptors: ::prost::alloc::vec::Vec, + /// If there are more results than have been returned, then this field is set + /// to a non-empty value. To see the additional results, + /// use that value as `page_token` in the next call to this method. + #[prost(string, tag = "2")] + pub next_page_token: ::prost::alloc::string::String, +} +/// The `GetMonitoredResourceDescriptor` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct GetMonitoredResourceDescriptorRequest { + /// Required. The monitored resource descriptor to get. The format is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\]/monitoredResourceDescriptors/\[RESOURCE_TYPE\] + /// + /// The `\[RESOURCE_TYPE\]` is a predefined type, such as + /// `cloudsql_database`. + #[prost(string, tag = "3")] + pub name: ::prost::alloc::string::String, +} +/// The `ListMetricDescriptors` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListMetricDescriptorsRequest { + /// Required. The + /// [project]() on which + /// to execute the request. The format is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\] + #[prost(string, tag = "5")] + pub name: ::prost::alloc::string::String, + /// If this field is empty, all custom and + /// system-defined metric descriptors are returned. + /// Otherwise, the [filter]() + /// specifies which metric descriptors are to be + /// returned. For example, the following filter matches all + /// [custom metrics](): + /// + /// metric.type = starts_with("custom.googleapis.com/") + #[prost(string, tag = "2")] + pub filter: ::prost::alloc::string::String, + /// A positive number that is the maximum number of results to return. The + /// default and maximum value is 10,000. If a page_size <= 0 or > 10,000 is + /// submitted, will instead return a maximum of 10,000 results. + #[prost(int32, tag = "3")] + pub page_size: i32, + /// If this field is not empty then it must contain the `nextPageToken` value + /// returned by a previous call to this method. Using this field causes the + /// method to return additional results from the previous method call. + #[prost(string, tag = "4")] + pub page_token: ::prost::alloc::string::String, +} +/// The `ListMetricDescriptors` response. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListMetricDescriptorsResponse { + /// The metric descriptors that are available to the project + /// and that match the value of `filter`, if present. + #[prost(message, repeated, tag = "1")] + pub metric_descriptors: ::prost::alloc::vec::Vec, + /// If there are more results than have been returned, then this field is set + /// to a non-empty value. To see the additional results, + /// use that value as `page_token` in the next call to this method. + #[prost(string, tag = "2")] + pub next_page_token: ::prost::alloc::string::String, +} +/// The `GetMetricDescriptor` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct GetMetricDescriptorRequest { + /// Required. The metric descriptor on which to execute the request. The format + /// is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\]/metricDescriptors/\[METRIC_ID\] + /// + /// An example value of `\[METRIC_ID\]` is + /// `"compute.googleapis.com/instance/disk/read_bytes_count"`. + #[prost(string, tag = "3")] + pub name: ::prost::alloc::string::String, +} +/// The `CreateMetricDescriptor` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct CreateMetricDescriptorRequest { + /// Required. The + /// [project]() on which + /// to execute the request. The format is: + /// 4 + /// projects/\[PROJECT_ID_OR_NUMBER\] + #[prost(string, tag = "3")] + pub name: ::prost::alloc::string::String, + /// Required. The new [custom + /// metric]() descriptor. + #[prost(message, optional, tag = "2")] + pub metric_descriptor: ::core::option::Option, +} +/// The `DeleteMetricDescriptor` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct DeleteMetricDescriptorRequest { + /// Required. The metric descriptor on which to execute the request. The format + /// is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\]/metricDescriptors/\[METRIC_ID\] + /// + /// An example of `\[METRIC_ID\]` is: + /// `"custom.googleapis.com/my_test_metric"`. + #[prost(string, tag = "3")] + pub name: ::prost::alloc::string::String, +} +/// The `ListTimeSeries` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListTimeSeriesRequest { + /// Required. The + /// [project](), + /// organization or folder on which to execute the request. The format is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\] + /// organizations/\[ORGANIZATION_ID\] + /// folders/\[FOLDER_ID\] + #[prost(string, tag = "10")] + pub name: ::prost::alloc::string::String, + /// Required. A [monitoring + /// filter]() that specifies + /// which time series should be returned. The filter must specify a single + /// metric type, and can additionally specify metric labels and other + /// information. For example: + /// + /// metric.type = "compute.googleapis.com/instance/cpu/usage_time" AND + /// metric.labels.instance_name = "my-instance-name" + #[prost(string, tag = "2")] + pub filter: ::prost::alloc::string::String, + /// Required. The time interval for which results should be returned. Only time + /// series that contain data points in the specified interval are included in + /// the response. + #[prost(message, optional, tag = "4")] + pub interval: ::core::option::Option, + /// Specifies the alignment of data points in individual time series as + /// well as how to combine the retrieved time series across specified labels. + /// + /// By default (if no `aggregation` is explicitly specified), the raw time + /// series data is returned. + #[prost(message, optional, tag = "5")] + pub aggregation: ::core::option::Option, + /// Apply a second aggregation after `aggregation` is applied. May only be + /// specified if `aggregation` is specified. + #[prost(message, optional, tag = "11")] + pub secondary_aggregation: ::core::option::Option, + /// Unsupported: must be left blank. The points in each time series are + /// currently returned in reverse time order (most recent to oldest). + #[prost(string, tag = "6")] + pub order_by: ::prost::alloc::string::String, + /// Required. Specifies which information is returned about the time series. + #[prost(enumeration = "list_time_series_request::TimeSeriesView", tag = "7")] + pub view: i32, + /// A positive number that is the maximum number of results to return. If + /// `page_size` is empty or more than 100,000 results, the effective + /// `page_size` is 100,000 results. If `view` is set to `FULL`, this is the + /// maximum number of `Points` returned. If `view` is set to `HEADERS`, this is + /// the maximum number of `TimeSeries` returned. + #[prost(int32, tag = "8")] + pub page_size: i32, + /// If this field is not empty then it must contain the `nextPageToken` value + /// returned by a previous call to this method. Using this field causes the + /// method to return additional results from the previous method call. + #[prost(string, tag = "9")] + pub page_token: ::prost::alloc::string::String, +} +/// Nested message and enum types in `ListTimeSeriesRequest`. +pub mod list_time_series_request { + /// Controls which fields are returned by `ListTimeSeries*`. + #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] + #[repr(i32)] + pub enum TimeSeriesView { + /// Returns the identity of the metric(s), the time series, + /// and the time series data. + Full = 0, + /// Returns the identity of the metric and the time series resource, + /// but not the time series data. + Headers = 1, + } + impl TimeSeriesView { + /// String value of the enum field names used in the ProtoBuf definition. + /// + /// The values are not transformed in any way and thus are considered stable + /// (if the ProtoBuf definition does not change) and safe for programmatic use. + pub fn as_str_name(&self) -> &'static str { + match self { + Self::Full => "FULL", + Self::Headers => "HEADERS", + } + } + /// Creates an enum from field names used in the ProtoBuf definition. + pub fn from_str_name(value: &str) -> ::core::option::Option { + match value { + "FULL" => Some(Self::Full), + "HEADERS" => Some(Self::Headers), + _ => None, + } + } + } +} +/// The `ListTimeSeries` response. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct ListTimeSeriesResponse { + /// One or more time series that match the filter included in the request. + #[prost(message, repeated, tag = "1")] + pub time_series: ::prost::alloc::vec::Vec, + /// If there are more results than have been returned, then this field is set + /// to a non-empty value. To see the additional results, + /// use that value as `page_token` in the next call to this method. + #[prost(string, tag = "2")] + pub next_page_token: ::prost::alloc::string::String, + /// Query execution errors that may have caused the time series data returned + /// to be incomplete. + #[prost(message, repeated, tag = "3")] + pub execution_errors: ::prost::alloc::vec::Vec, + /// The unit in which all `time_series` point values are reported. `unit` + /// follows the UCUM format for units as seen in + /// + /// If different `time_series` have different units (for example, because they + /// come from different metric types, or a unit is absent), then `unit` will be + /// "{not_a_unit}". + #[prost(string, tag = "5")] + pub unit: ::prost::alloc::string::String, +} +/// The `CreateTimeSeries` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct CreateTimeSeriesRequest { + /// Required. The + /// [project]() on which + /// to execute the request. The format is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\] + #[prost(string, tag = "3")] + pub name: ::prost::alloc::string::String, + /// Required. The new data to be added to a list of time series. + /// Adds at most one data point to each of several time series. The new data + /// point must be more recent than any other point in its time series. Each + /// `TimeSeries` value must fully specify a unique time series by supplying + /// all label values for the metric and the monitored resource. + /// + /// The maximum number of `TimeSeries` objects per `Create` request is 200. + #[prost(message, repeated, tag = "2")] + pub time_series: ::prost::alloc::vec::Vec, +} +/// DEPRECATED. Used to hold per-time-series error status. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct CreateTimeSeriesError { + /// DEPRECATED. Time series ID that resulted in the `status` error. + #[deprecated] + #[prost(message, optional, tag = "1")] + pub time_series: ::core::option::Option, + /// DEPRECATED. The status of the requested write operation for `time_series`. + #[deprecated] + #[prost(message, optional, tag = "2")] + pub status: ::core::option::Option, +} +/// Summary of the result of a failed request to write data to a time series. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct CreateTimeSeriesSummary { + /// The number of points in the request. + #[prost(int32, tag = "1")] + pub total_point_count: i32, + /// The number of points that were successfully written. + #[prost(int32, tag = "2")] + pub success_point_count: i32, + /// The number of points that failed to be written. Order is not guaranteed. + #[prost(message, repeated, tag = "3")] + pub errors: ::prost::alloc::vec::Vec, +} +/// Nested message and enum types in `CreateTimeSeriesSummary`. +pub mod create_time_series_summary { + /// Detailed information about an error category. + #[derive(Clone, PartialEq, ::prost::Message)] + pub struct Error { + /// The status of the requested write operation. + #[prost(message, optional, tag = "1")] + pub status: ::core::option::Option, + /// The number of points that couldn't be written because of `status`. + #[prost(int32, tag = "2")] + pub point_count: i32, + } +} +/// The `QueryTimeSeries` request. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct QueryTimeSeriesRequest { + /// Required. The + /// [project]() on which + /// to execute the request. The format is: + /// + /// projects/\[PROJECT_ID_OR_NUMBER\] + #[prost(string, tag = "1")] + pub name: ::prost::alloc::string::String, + /// Required. The query in the [Monitoring Query + /// Language]() format. + /// The default time zone is in UTC. + #[prost(string, tag = "7")] + pub query: ::prost::alloc::string::String, + /// A positive number that is the maximum number of time_series_data to return. + #[prost(int32, tag = "9")] + pub page_size: i32, + /// If this field is not empty then it must contain the `nextPageToken` value + /// returned by a previous call to this method. Using this field causes the + /// method to return additional results from the previous method call. + #[prost(string, tag = "10")] + pub page_token: ::prost::alloc::string::String, +} +/// The `QueryTimeSeries` response. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct QueryTimeSeriesResponse { + /// The descriptor for the time series data. + #[prost(message, optional, tag = "8")] + pub time_series_descriptor: ::core::option::Option, + /// The time series data. + #[prost(message, repeated, tag = "9")] + pub time_series_data: ::prost::alloc::vec::Vec, + /// If there are more results than have been returned, then this field is set + /// to a non-empty value. To see the additional results, use that value as + /// `page_token` in the next call to this method. + #[prost(string, tag = "10")] + pub next_page_token: ::prost::alloc::string::String, + /// Query execution errors that may have caused the time series data returned + /// to be incomplete. The available data will be available in the + /// response. + #[prost(message, repeated, tag = "11")] + pub partial_errors: ::prost::alloc::vec::Vec, +} +/// This is an error detail intended to be used with INVALID_ARGUMENT errors. +#[derive(Clone, PartialEq, ::prost::Message)] +pub struct QueryErrorList { + /// Errors in parsing the time series query language text. The number of errors + /// in the response may be limited. + #[prost(message, repeated, tag = "1")] + pub errors: ::prost::alloc::vec::Vec, + /// A summary of all the errors. + #[prost(string, tag = "2")] + pub error_summary: ::prost::alloc::string::String, +} +/// Generated client implementations. +pub mod metric_service_client { + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] + use tonic::codegen::http::Uri; + use tonic::codegen::*; + /// Manages metric descriptors, monitored resource descriptors, and + /// time series data. + #[derive(Debug, Clone)] + pub struct MetricServiceClient { + inner: tonic::client::Grpc, + } + impl MetricServiceClient { + /// Attempt to create a new client by connecting to a given endpoint. + pub async fn connect(dst: D) -> Result + where + D: TryInto, + D::Error: Into, + { + let conn = tonic::transport::Endpoint::new(dst)?.connect().await?; + Ok(Self::new(conn)) + } + } + impl MetricServiceClient + where + T: tonic::client::GrpcService, + T::Error: Into, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, + { + pub fn new(inner: T) -> Self { + let inner = tonic::client::Grpc::new(inner); + Self { inner } + } + pub fn with_origin(inner: T, origin: Uri) -> Self { + let inner = tonic::client::Grpc::with_origin(inner, origin); + Self { inner } + } + pub fn with_interceptor(inner: T, interceptor: F) -> MetricServiceClient> + where + F: tonic::service::Interceptor, + T::ResponseBody: Default, + T: tonic::codegen::Service< + http::Request, + Response = http::Response<>::ResponseBody>, + >, + >>::Error: + Into + std::marker::Send + std::marker::Sync, + { + MetricServiceClient::new(InterceptedService::new(inner, interceptor)) + } + /// Compress requests with the given encoding. + /// + /// This requires the server to support it otherwise it might respond with an + /// error. + #[must_use] + pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self { + self.inner = self.inner.send_compressed(encoding); + self + } + /// Enable decompressing responses. + #[must_use] + pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self { + self.inner = self.inner.accept_compressed(encoding); + self + } + /// Limits the maximum size of a decoded message. + /// + /// Default: `4MB` + #[must_use] + pub fn max_decoding_message_size(mut self, limit: usize) -> Self { + self.inner = self.inner.max_decoding_message_size(limit); + self + } + /// Limits the maximum size of an encoded message. + /// + /// Default: `usize::MAX` + #[must_use] + pub fn max_encoding_message_size(mut self, limit: usize) -> Self { + self.inner = self.inner.max_encoding_message_size(limit); + self + } + /// Lists monitored resource descriptors that match a filter. + pub async fn list_monitored_resource_descriptors( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result, tonic::Status> + { + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static( + "/google.monitoring.v3.MetricService/ListMonitoredResourceDescriptors", + ); + let mut req = request.into_request(); + req.extensions_mut().insert(GrpcMethod::new( + "google.monitoring.v3.MetricService", + "ListMonitoredResourceDescriptors", + )); + self.inner.unary(req, path, codec).await + } + /// Gets a single monitored resource descriptor. + pub async fn get_monitored_resource_descriptor( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result, tonic::Status> + { + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static( + "/google.monitoring.v3.MetricService/GetMonitoredResourceDescriptor", + ); + let mut req = request.into_request(); + req.extensions_mut().insert(GrpcMethod::new( + "google.monitoring.v3.MetricService", + "GetMonitoredResourceDescriptor", + )); + self.inner.unary(req, path, codec).await + } + /// Lists metric descriptors that match a filter. + pub async fn list_metric_descriptors( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result, tonic::Status> { + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; + let codec = tonic::codec::ProstCodec::default(); + let path = + http::uri::PathAndQuery::from_static("/google.monitoring.v3.MetricService/ListMetricDescriptors"); + let mut req = request.into_request(); + req.extensions_mut() + .insert(GrpcMethod::new("google.monitoring.v3.MetricService", "ListMetricDescriptors")); + self.inner.unary(req, path, codec).await + } + /// Gets a single metric descriptor. + pub async fn get_metric_descriptor( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result, tonic::Status> { + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static("/google.monitoring.v3.MetricService/GetMetricDescriptor"); + let mut req = request.into_request(); + req.extensions_mut() + .insert(GrpcMethod::new("google.monitoring.v3.MetricService", "GetMetricDescriptor")); + self.inner.unary(req, path, codec).await + } + /// Creates a new metric descriptor. + /// The creation is executed asynchronously. + /// User-created metric descriptors define + /// [custom metrics](https://cloud.google.com/monitoring/custom-metrics). + /// The metric descriptor is updated if it already exists, + /// except that metric labels are never removed. + pub async fn create_metric_descriptor( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result, tonic::Status> { + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; + let codec = tonic::codec::ProstCodec::default(); + let path = + http::uri::PathAndQuery::from_static("/google.monitoring.v3.MetricService/CreateMetricDescriptor"); + let mut req = request.into_request(); + req.extensions_mut() + .insert(GrpcMethod::new("google.monitoring.v3.MetricService", "CreateMetricDescriptor")); + self.inner.unary(req, path, codec).await + } + /// Deletes a metric descriptor. Only user-created + /// [custom metrics](https://cloud.google.com/monitoring/custom-metrics) can be + /// deleted. + pub async fn delete_metric_descriptor( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result, tonic::Status> { + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; + let codec = tonic::codec::ProstCodec::default(); + let path = + http::uri::PathAndQuery::from_static("/google.monitoring.v3.MetricService/DeleteMetricDescriptor"); + let mut req = request.into_request(); + req.extensions_mut() + .insert(GrpcMethod::new("google.monitoring.v3.MetricService", "DeleteMetricDescriptor")); + self.inner.unary(req, path, codec).await + } + /// Lists time series that match a filter. + pub async fn list_time_series( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result, tonic::Status> { + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static("/google.monitoring.v3.MetricService/ListTimeSeries"); + let mut req = request.into_request(); + req.extensions_mut() + .insert(GrpcMethod::new("google.monitoring.v3.MetricService", "ListTimeSeries")); + self.inner.unary(req, path, codec).await + } + /// Creates or adds data to one or more time series. + /// The response is empty if all time series in the request were written. + /// If any time series could not be written, a corresponding failure message is + /// included in the error response. + /// This method does not support + /// [resource locations constraint of an organization + /// policy](https://cloud.google.com/resource-manager/docs/organization-policy/defining-locations#setting_the_organization_policy). + pub async fn create_time_series( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result, tonic::Status> { + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; + let codec = tonic::codec::ProstCodec::default(); + let path = http::uri::PathAndQuery::from_static("/google.monitoring.v3.MetricService/CreateTimeSeries"); + let mut req = request.into_request(); + req.extensions_mut() + .insert(GrpcMethod::new("google.monitoring.v3.MetricService", "CreateTimeSeries")); + self.inner.unary(req, path, codec).await + } + /// Creates or adds data to one or more service time series. A service time + /// series is a time series for a metric from a Google Cloud service. The + /// response is empty if all time series in the request were written. If any + /// time series could not be written, a corresponding failure message is + /// included in the error response. This endpoint rejects writes to + /// user-defined metrics. + /// This method is only for use by Google Cloud services. Use + /// [projects.timeSeries.create][google.monitoring.v3.MetricService.CreateTimeSeries] + /// instead. + pub async fn create_service_time_series( + &mut self, + request: impl tonic::IntoRequest, + ) -> std::result::Result, tonic::Status> { + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; + let codec = tonic::codec::ProstCodec::default(); + let path = + http::uri::PathAndQuery::from_static("/google.monitoring.v3.MetricService/CreateServiceTimeSeries"); + let mut req = request.into_request(); + req.extensions_mut() + .insert(GrpcMethod::new("google.monitoring.v3.MetricService", "CreateServiceTimeSeries")); + self.inner.unary(req, path, codec).await + } + } +} diff --git a/googleapis/src/google.pubsub.v1.rs b/googleapis/src/google.pubsub.v1.rs index d24df08a..df9bb004 100644 --- a/googleapis/src/google.pubsub.v1.rs +++ b/googleapis/src/google.pubsub.v1.rs @@ -1,6 +1,5 @@ // This file is @generated by prost-build. /// A schema resource. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Schema { /// Required. Name of the schema. @@ -42,9 +41,9 @@ pub mod schema { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Type::Unspecified => "TYPE_UNSPECIFIED", - Type::ProtocolBuffer => "PROTOCOL_BUFFER", - Type::Avro => "AVRO", + Self::Unspecified => "TYPE_UNSPECIFIED", + Self::ProtocolBuffer => "PROTOCOL_BUFFER", + Self::Avro => "AVRO", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -59,7 +58,6 @@ pub mod schema { } } /// Request for the CreateSchema method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateSchemaRequest { /// Required. The name of the project in which to create the schema. @@ -82,7 +80,6 @@ pub struct CreateSchemaRequest { pub schema_id: ::prost::alloc::string::String, } /// Request for the GetSchema method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetSchemaRequest { /// Required. The name of the schema to get. @@ -95,7 +92,6 @@ pub struct GetSchemaRequest { pub view: i32, } /// Request for the `ListSchemas` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSchemasRequest { /// Required. The name of the project in which to list schemas. @@ -117,7 +113,6 @@ pub struct ListSchemasRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListSchemas` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSchemasResponse { /// The resulting schemas. @@ -129,7 +124,6 @@ pub struct ListSchemasResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for the `ListSchemaRevisions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSchemaRevisionsRequest { /// Required. The name of the schema to list revisions for. @@ -149,7 +143,6 @@ pub struct ListSchemaRevisionsRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListSchemaRevisions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSchemaRevisionsResponse { /// The revisions of the schema. @@ -161,7 +154,6 @@ pub struct ListSchemaRevisionsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for CommitSchema method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CommitSchemaRequest { /// Required. The name of the schema we are revising. @@ -173,7 +165,6 @@ pub struct CommitSchemaRequest { pub schema: ::core::option::Option, } /// Request for the `RollbackSchema` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RollbackSchemaRequest { /// Required. The schema being rolled back with revision id. @@ -187,7 +178,6 @@ pub struct RollbackSchemaRequest { pub revision_id: ::prost::alloc::string::String, } /// Request for the `DeleteSchemaRevision` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteSchemaRevisionRequest { /// Required. The name of the schema revision to be deleted, with a revision ID @@ -204,7 +194,6 @@ pub struct DeleteSchemaRevisionRequest { pub revision_id: ::prost::alloc::string::String, } /// Request for the `DeleteSchema` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteSchemaRequest { /// Required. Name of the schema to delete. @@ -213,7 +202,6 @@ pub struct DeleteSchemaRequest { pub name: ::prost::alloc::string::String, } /// Request for the `ValidateSchema` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ValidateSchemaRequest { /// Required. The name of the project in which to validate schemas. @@ -226,11 +214,9 @@ pub struct ValidateSchemaRequest { } /// Response for the `ValidateSchema` method. /// Empty for now. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ValidateSchemaResponse {} /// Request for the `ValidateMessage` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ValidateMessageRequest { /// Required. The name of the project in which to validate schemas. @@ -248,7 +234,6 @@ pub struct ValidateMessageRequest { } /// Nested message and enum types in `ValidateMessageRequest`. pub mod validate_message_request { - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum SchemaSpec { /// Name of the schema against which to validate. @@ -263,7 +248,6 @@ pub mod validate_message_request { } /// Response for the `ValidateMessage` method. /// Empty for now. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ValidateMessageResponse {} /// View of Schema object fields to be returned by GetSchema and ListSchemas. @@ -285,9 +269,9 @@ impl SchemaView { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - SchemaView::Unspecified => "SCHEMA_VIEW_UNSPECIFIED", - SchemaView::Basic => "BASIC", - SchemaView::Full => "FULL", + Self::Unspecified => "SCHEMA_VIEW_UNSPECIFIED", + Self::Basic => "BASIC", + Self::Full => "FULL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -319,9 +303,9 @@ impl Encoding { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Encoding::Unspecified => "ENCODING_UNSPECIFIED", - Encoding::Json => "JSON", - Encoding::Binary => "BINARY", + Self::Unspecified => "ENCODING_UNSPECIFIED", + Self::Json => "JSON", + Self::Binary => "BINARY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -336,7 +320,13 @@ impl Encoding { } /// Generated client implementations. pub mod schema_service_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// Service for doing schema-related operations. @@ -359,8 +349,8 @@ pub mod schema_service_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -378,7 +368,8 @@ pub mod schema_service_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { SchemaServiceClient::new(InterceptedService::new(inner, interceptor)) } @@ -418,9 +409,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/CreateSchema"); let mut req = request.into_request(); @@ -433,9 +425,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/GetSchema"); let mut req = request.into_request(); @@ -448,9 +441,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/ListSchemas"); let mut req = request.into_request(); @@ -463,9 +457,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/ListSchemaRevisions"); let mut req = request.into_request(); @@ -478,9 +473,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/CommitSchema"); let mut req = request.into_request(); @@ -493,9 +489,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/RollbackSchema"); let mut req = request.into_request(); @@ -508,9 +505,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/DeleteSchemaRevision"); let mut req = request.into_request(); @@ -523,9 +521,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/DeleteSchema"); let mut req = request.into_request(); @@ -538,9 +537,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/ValidateSchema"); let mut req = request.into_request(); @@ -553,9 +553,10 @@ pub mod schema_service_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.SchemaService/ValidateMessage"); let mut req = request.into_request(); @@ -566,7 +567,6 @@ pub mod schema_service_client { } } /// A policy constraining the storage of messages published to the topic. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MessageStoragePolicy { /// Optional. A list of IDs of Google Cloud regions where messages that are @@ -586,7 +586,6 @@ pub struct MessageStoragePolicy { pub enforce_in_transit: bool, } /// Settings for validating messages published against a schema. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct SchemaSettings { /// Required. The name of the schema that messages published should be @@ -610,7 +609,6 @@ pub struct SchemaSettings { pub last_revision_id: ::prost::alloc::string::String, } /// Settings for an ingestion data source on a topic. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct IngestionDataSourceSettings { /// Optional. Platform Logs settings. If unset, no Platform Logs will be @@ -624,7 +622,6 @@ pub struct IngestionDataSourceSettings { /// Nested message and enum types in `IngestionDataSourceSettings`. pub mod ingestion_data_source_settings { /// Ingestion settings for Amazon Kinesis Data Streams. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AwsKinesis { /// Output only. An output-only field that indicates the state of the Kinesis @@ -686,12 +683,12 @@ pub mod ingestion_data_source_settings { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Active => "ACTIVE", - State::KinesisPermissionDenied => "KINESIS_PERMISSION_DENIED", - State::PublishPermissionDenied => "PUBLISH_PERMISSION_DENIED", - State::StreamNotFound => "STREAM_NOT_FOUND", - State::ConsumerNotFound => "CONSUMER_NOT_FOUND", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Active => "ACTIVE", + Self::KinesisPermissionDenied => "KINESIS_PERMISSION_DENIED", + Self::PublishPermissionDenied => "PUBLISH_PERMISSION_DENIED", + Self::StreamNotFound => "STREAM_NOT_FOUND", + Self::ConsumerNotFound => "CONSUMER_NOT_FOUND", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -709,7 +706,6 @@ pub mod ingestion_data_source_settings { } } /// Ingestion settings for Cloud Storage. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CloudStorage { /// Output only. An output-only field that indicates the state of the Cloud @@ -739,7 +735,6 @@ pub mod ingestion_data_source_settings { /// Configuration for reading Cloud Storage data in text format. Each line of /// text as specified by the delimiter will be set to the `data` field of a /// Pub/Sub message. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TextFormat { /// Optional. When unset, '\n' is used. @@ -749,14 +744,12 @@ pub mod ingestion_data_source_settings { /// Configuration for reading Cloud Storage data in Avro binary format. The /// bytes of each object will be set to the `data` field of a Pub/Sub /// message. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AvroFormat {} /// Configuration for reading Cloud Storage data written via [Cloud Storage /// subscriptions](). The /// data and attributes fields of the originally exported Pub/Sub message /// will be restored when publishing. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct PubSubAvroFormat {} /// Possible states for ingestion from Cloud Storage. @@ -792,12 +785,12 @@ pub mod ingestion_data_source_settings { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Active => "ACTIVE", - State::CloudStoragePermissionDenied => "CLOUD_STORAGE_PERMISSION_DENIED", - State::PublishPermissionDenied => "PUBLISH_PERMISSION_DENIED", - State::BucketNotFound => "BUCKET_NOT_FOUND", - State::TooManyObjects => "TOO_MANY_OBJECTS", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Active => "ACTIVE", + Self::CloudStoragePermissionDenied => "CLOUD_STORAGE_PERMISSION_DENIED", + Self::PublishPermissionDenied => "PUBLISH_PERMISSION_DENIED", + Self::BucketNotFound => "BUCKET_NOT_FOUND", + Self::TooManyObjects => "TOO_MANY_OBJECTS", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -814,7 +807,6 @@ pub mod ingestion_data_source_settings { } } /// Defaults to text format. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum InputFormat { /// Optional. Data from Cloud Storage will be interpreted as text. @@ -831,7 +823,6 @@ pub mod ingestion_data_source_settings { } } /// Only one source type can have settings set. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Source { /// Optional. Amazon Kinesis Data Streams. @@ -843,7 +834,6 @@ pub mod ingestion_data_source_settings { } } /// Settings for Platform Logs produced by Pub/Sub. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct PlatformLogsSettings { /// Optional. The minimum severity level of Platform Logs that will be written. @@ -876,12 +866,12 @@ pub mod platform_logs_settings { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Severity::Unspecified => "SEVERITY_UNSPECIFIED", - Severity::Disabled => "DISABLED", - Severity::Debug => "DEBUG", - Severity::Info => "INFO", - Severity::Warning => "WARNING", - Severity::Error => "ERROR", + Self::Unspecified => "SEVERITY_UNSPECIFIED", + Self::Disabled => "DISABLED", + Self::Debug => "DEBUG", + Self::Info => "INFO", + Self::Warning => "WARNING", + Self::Error => "ERROR", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -899,7 +889,6 @@ pub mod platform_logs_settings { } } /// A topic resource. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Topic { /// Required. The name of the topic. It must have the format @@ -972,9 +961,9 @@ pub mod topic { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Active => "ACTIVE", - State::IngestionResourceError => "INGESTION_RESOURCE_ERROR", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Active => "ACTIVE", + Self::IngestionResourceError => "INGESTION_RESOURCE_ERROR", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -996,7 +985,6 @@ pub mod topic { /// more information. See \[quotas and limits\] /// () for more information about message /// limits. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PubsubMessage { /// Optional. The message data field. If this field is empty, the message must @@ -1031,7 +1019,6 @@ pub struct PubsubMessage { pub ordering_key: ::prost::alloc::string::String, } /// Request for the GetTopic method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetTopicRequest { /// Required. The name of the topic to get. @@ -1040,7 +1027,6 @@ pub struct GetTopicRequest { pub topic: ::prost::alloc::string::String, } /// Request for the UpdateTopic method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateTopicRequest { /// Required. The updated topic object. @@ -1055,7 +1041,6 @@ pub struct UpdateTopicRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Request for the Publish method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PublishRequest { /// Required. The messages in the request will be published on this topic. @@ -1067,7 +1052,6 @@ pub struct PublishRequest { pub messages: ::prost::alloc::vec::Vec, } /// Response for the `Publish` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PublishResponse { /// Optional. The server-assigned ID of each published message, in the same @@ -1077,7 +1061,6 @@ pub struct PublishResponse { pub message_ids: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Request for the `ListTopics` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTopicsRequest { /// Required. The name of the project in which to list topics. @@ -1094,7 +1077,6 @@ pub struct ListTopicsRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListTopics` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTopicsResponse { /// Optional. The resulting topics. @@ -1106,7 +1088,6 @@ pub struct ListTopicsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for the `ListTopicSubscriptions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTopicSubscriptionsRequest { /// Required. The name of the topic that subscriptions are attached to. @@ -1123,7 +1104,6 @@ pub struct ListTopicSubscriptionsRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListTopicSubscriptions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTopicSubscriptionsResponse { /// Optional. The names of subscriptions attached to the topic specified in the @@ -1137,7 +1117,6 @@ pub struct ListTopicSubscriptionsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for the `ListTopicSnapshots` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTopicSnapshotsRequest { /// Required. The name of the topic that snapshots are attached to. @@ -1154,7 +1133,6 @@ pub struct ListTopicSnapshotsRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListTopicSnapshots` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListTopicSnapshotsResponse { /// Optional. The names of the snapshots that match the request. @@ -1167,7 +1145,6 @@ pub struct ListTopicSnapshotsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for the `DeleteTopic` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteTopicRequest { /// Required. Name of the topic to delete. @@ -1176,7 +1153,6 @@ pub struct DeleteTopicRequest { pub topic: ::prost::alloc::string::String, } /// Request for the DetachSubscription method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DetachSubscriptionRequest { /// Required. The subscription to detach. @@ -1186,13 +1162,11 @@ pub struct DetachSubscriptionRequest { } /// Response for the DetachSubscription method. /// Reserved for future use. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct DetachSubscriptionResponse {} /// A subscription resource. If none of `push_config`, `bigquery_config`, or /// `cloud_storage_config` is set, then the subscriber will pull and ack messages /// using API methods. At most one of these fields may be set. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Subscription { /// Required. The name of the subscription. It must have the format @@ -1344,7 +1318,6 @@ pub struct Subscription { pub mod subscription { /// Information about an associated Analytics Hub subscription /// (). - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AnalyticsHubSubscriptionInfo { /// Optional. The name of the associated Analytics Hub listing resource. @@ -1378,9 +1351,9 @@ pub mod subscription { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Active => "ACTIVE", - State::ResourceError => "RESOURCE_ERROR", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Active => "ACTIVE", + Self::ResourceError => "RESOURCE_ERROR", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1405,7 +1378,6 @@ pub mod subscription { /// Retry Policy is implemented on a best effort basis. At times, the delay /// between consecutive deliveries may not match the configuration. That is, /// delay can be more or less than configured backoff. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct RetryPolicy { /// Optional. The minimum delay between consecutive deliveries of a given @@ -1423,7 +1395,6 @@ pub struct RetryPolicy { /// /// If validation on any of the fields fails at subscription creation/updation, /// the create/update subscription request will fail. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeadLetterPolicy { /// Optional. The name of the topic to which dead letter messages should be @@ -1455,7 +1426,6 @@ pub struct DeadLetterPolicy { } /// A policy that specifies the conditions for resource expiration (i.e., /// automatic resource deletion). -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ExpirationPolicy { /// Optional. Specifies the "time-to-live" duration for an associated resource. @@ -1468,7 +1438,6 @@ pub struct ExpirationPolicy { pub ttl: ::core::option::Option<::prost_types::Duration>, } /// Configuration for a push delivery endpoint. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PushConfig { /// Optional. A URL locating the endpoint to which messages should be pushed. @@ -1515,7 +1484,6 @@ pub mod push_config { /// Contains information needed for generating an /// [OpenID Connect /// token](). - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct OidcToken { /// Optional. [Service account @@ -1538,11 +1506,9 @@ pub mod push_config { /// The payload to the push endpoint is in the form of the JSON representation /// of a PubsubMessage /// (). - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct PubsubWrapper {} /// Sets the `data` field as the HTTP body for delivery. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct NoWrapper { /// Optional. When true, writes the Pub/Sub message metadata to @@ -1556,7 +1522,6 @@ pub mod push_config { /// default to allow requests only from the Pub/Sub system, for example. /// This field is optional and should be set only by users interested in /// authenticated push. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum AuthenticationMethod { /// Optional. If specified, Pub/Sub will generate and attach an OIDC JWT @@ -1567,7 +1532,6 @@ pub mod push_config { } /// The format of the delivered message to the push endpoint is defined by /// the chosen wrapper. When unset, `PubsubWrapper` is used. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum Wrapper { /// Optional. When set, the payload to the push endpoint is in the form of @@ -1581,7 +1545,6 @@ pub mod push_config { } } /// Configuration for a BigQuery subscription. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BigQueryConfig { /// Optional. The name of the table to which to write data, of the form @@ -1657,12 +1620,12 @@ pub mod big_query_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Active => "ACTIVE", - State::PermissionDenied => "PERMISSION_DENIED", - State::NotFound => "NOT_FOUND", - State::SchemaMismatch => "SCHEMA_MISMATCH", - State::InTransitLocationRestriction => "IN_TRANSIT_LOCATION_RESTRICTION", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Active => "ACTIVE", + Self::PermissionDenied => "PERMISSION_DENIED", + Self::NotFound => "NOT_FOUND", + Self::SchemaMismatch => "SCHEMA_MISMATCH", + Self::InTransitLocationRestriction => "IN_TRANSIT_LOCATION_RESTRICTION", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1680,7 +1643,6 @@ pub mod big_query_config { } } /// Configuration for a Cloud Storage subscription. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CloudStorageConfig { /// Required. User-provided name for the Cloud Storage bucket. @@ -1738,12 +1700,10 @@ pub mod cloud_storage_config { /// Configuration for writing message data in text format. /// Message payloads will be written to files as raw text, separated by a /// newline. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct TextConfig {} /// Configuration for writing message data in Avro format. /// Message payloads and metadata will be written to files as an Avro binary. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AvroConfig { /// Optional. When true, write the subscription name, message_id, @@ -1786,12 +1746,12 @@ pub mod cloud_storage_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Active => "ACTIVE", - State::PermissionDenied => "PERMISSION_DENIED", - State::NotFound => "NOT_FOUND", - State::InTransitLocationRestriction => "IN_TRANSIT_LOCATION_RESTRICTION", - State::SchemaMismatch => "SCHEMA_MISMATCH", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Active => "ACTIVE", + Self::PermissionDenied => "PERMISSION_DENIED", + Self::NotFound => "NOT_FOUND", + Self::InTransitLocationRestriction => "IN_TRANSIT_LOCATION_RESTRICTION", + Self::SchemaMismatch => "SCHEMA_MISMATCH", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1808,7 +1768,6 @@ pub mod cloud_storage_config { } } /// Defaults to text format. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum OutputFormat { /// Optional. If set, message data will be written to Cloud Storage in text @@ -1822,7 +1781,6 @@ pub mod cloud_storage_config { } } /// A message and its corresponding acknowledgment ID. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReceivedMessage { /// Optional. This ID can be used to acknowledge the received message. @@ -1851,7 +1809,6 @@ pub struct ReceivedMessage { pub delivery_attempt: i32, } /// Request for the GetSubscription method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetSubscriptionRequest { /// Required. The name of the subscription to get. @@ -1860,7 +1817,6 @@ pub struct GetSubscriptionRequest { pub subscription: ::prost::alloc::string::String, } /// Request for the UpdateSubscription method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateSubscriptionRequest { /// Required. The updated subscription object. @@ -1872,7 +1828,6 @@ pub struct UpdateSubscriptionRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Request for the `ListSubscriptions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSubscriptionsRequest { /// Required. The name of the project in which to list subscriptions. @@ -1889,7 +1844,6 @@ pub struct ListSubscriptionsRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListSubscriptions` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSubscriptionsResponse { /// Optional. The subscriptions that match the request. @@ -1902,7 +1856,6 @@ pub struct ListSubscriptionsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for the DeleteSubscription method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteSubscriptionRequest { /// Required. The subscription to delete. @@ -1911,7 +1864,6 @@ pub struct DeleteSubscriptionRequest { pub subscription: ::prost::alloc::string::String, } /// Request for the ModifyPushConfig method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ModifyPushConfigRequest { /// Required. The name of the subscription. @@ -1928,7 +1880,6 @@ pub struct ModifyPushConfigRequest { pub push_config: ::core::option::Option, } /// Request for the `Pull` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PullRequest { /// Required. The subscription from which messages should be pulled. @@ -1952,7 +1903,6 @@ pub struct PullRequest { pub max_messages: i32, } /// Response for the `Pull` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PullResponse { /// Optional. Received Pub/Sub messages. The list will be empty if there are no @@ -1964,7 +1914,6 @@ pub struct PullResponse { pub received_messages: ::prost::alloc::vec::Vec, } /// Request for the ModifyAckDeadline method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ModifyAckDeadlineRequest { /// Required. The name of the subscription. @@ -1987,7 +1936,6 @@ pub struct ModifyAckDeadlineRequest { pub ack_deadline_seconds: i32, } /// Request for the Acknowledge method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AcknowledgeRequest { /// Required. The subscription whose message is being acknowledged. @@ -2003,7 +1951,6 @@ pub struct AcknowledgeRequest { /// Request for the `StreamingPull` streaming RPC method. This request is used to /// establish the initial stream as well as to stream acknowledgements and ack /// deadline modifications from the client to the server. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct StreamingPullRequest { /// Required. The subscription for which to initialize the new stream. This @@ -2079,7 +2026,6 @@ pub struct StreamingPullRequest { } /// Response for the `StreamingPull` method. This response is used to stream /// messages from the server to the client. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct StreamingPullResponse { /// Optional. Received Pub/Sub messages. This will not be empty. @@ -2102,7 +2048,6 @@ pub struct StreamingPullResponse { pub mod streaming_pull_response { /// Acknowledgement IDs sent in one or more previous requests to acknowledge a /// previously received message. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct AcknowledgeConfirmation { /// Optional. Successfully processed acknowledgement IDs. @@ -2122,7 +2067,6 @@ pub mod streaming_pull_response { } /// Acknowledgement IDs sent in one or more previous requests to modify the /// deadline for a specific message. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ModifyAckDeadlineConfirmation { /// Optional. Successfully processed acknowledgement IDs. @@ -2138,7 +2082,6 @@ pub mod streaming_pull_response { pub temporary_failed_ack_ids: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Subscription properties sent as part of the response. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct SubscriptionProperties { /// Optional. True iff exactly once delivery is enabled for this @@ -2151,7 +2094,6 @@ pub mod streaming_pull_response { } } /// Request for the `CreateSnapshot` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateSnapshotRequest { /// Required. User-provided name for this snapshot. If the name is not provided @@ -2179,7 +2121,6 @@ pub struct CreateSnapshotRequest { pub labels: ::std::collections::HashMap<::prost::alloc::string::String, ::prost::alloc::string::String>, } /// Request for the UpdateSnapshot method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateSnapshotRequest { /// Required. The updated snapshot object. @@ -2195,7 +2136,6 @@ pub struct UpdateSnapshotRequest { /// operations, which allow you to manage message acknowledgments in bulk. That /// is, you can set the acknowledgment state of messages in an existing /// subscription to the state captured by a snapshot. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Snapshot { /// Optional. The name of the snapshot. @@ -2223,7 +2163,6 @@ pub struct Snapshot { pub labels: ::std::collections::HashMap<::prost::alloc::string::String, ::prost::alloc::string::String>, } /// Request for the GetSnapshot method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetSnapshotRequest { /// Required. The name of the snapshot to get. @@ -2232,7 +2171,6 @@ pub struct GetSnapshotRequest { pub snapshot: ::prost::alloc::string::String, } /// Request for the `ListSnapshots` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSnapshotsRequest { /// Required. The name of the project in which to list snapshots. @@ -2249,7 +2187,6 @@ pub struct ListSnapshotsRequest { pub page_token: ::prost::alloc::string::String, } /// Response for the `ListSnapshots` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSnapshotsResponse { /// Optional. The resulting snapshots. @@ -2262,7 +2199,6 @@ pub struct ListSnapshotsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request for the `DeleteSnapshot` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteSnapshotRequest { /// Required. The name of the snapshot to delete. @@ -2271,7 +2207,6 @@ pub struct DeleteSnapshotRequest { pub snapshot: ::prost::alloc::string::String, } /// Request for the `Seek` method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct SeekRequest { /// Required. The subscription to affect. @@ -2282,7 +2217,6 @@ pub struct SeekRequest { } /// Nested message and enum types in `SeekRequest`. pub mod seek_request { - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Target { /// Optional. The time to seek to. @@ -2306,12 +2240,17 @@ pub mod seek_request { } } /// Response for the `Seek` method (this response is empty). -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct SeekResponse {} /// Generated client implementations. pub mod publisher_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// The service that an application uses to manipulate topics, and to send @@ -2335,8 +2274,8 @@ pub mod publisher_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -2354,7 +2293,8 @@ pub mod publisher_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { PublisherClient::new(InterceptedService::new(inner, interceptor)) } @@ -2395,9 +2335,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/CreateTopic"); let mut req = request.into_request(); @@ -2411,9 +2352,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/UpdateTopic"); let mut req = request.into_request(); @@ -2427,9 +2369,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/Publish"); let mut req = request.into_request(); @@ -2442,9 +2385,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/GetTopic"); let mut req = request.into_request(); @@ -2457,9 +2401,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/ListTopics"); let mut req = request.into_request(); @@ -2472,9 +2417,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/ListTopicSubscriptions"); let mut req = request.into_request(); @@ -2491,9 +2437,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/ListTopicSnapshots"); let mut req = request.into_request(); @@ -2510,9 +2457,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/DeleteTopic"); let mut req = request.into_request(); @@ -2528,9 +2476,10 @@ pub mod publisher_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Publisher/DetachSubscription"); let mut req = request.into_request(); @@ -2542,7 +2491,13 @@ pub mod publisher_client { } /// Generated client implementations. pub mod subscriber_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// The service that an application uses to manipulate subscriptions and to @@ -2567,8 +2522,8 @@ pub mod subscriber_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -2586,7 +2541,8 @@ pub mod subscriber_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { SubscriberClient::new(InterceptedService::new(inner, interceptor)) } @@ -2636,9 +2592,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/CreateSubscription"); let mut req = request.into_request(); @@ -2651,9 +2608,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/GetSubscription"); let mut req = request.into_request(); @@ -2668,9 +2626,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/UpdateSubscription"); let mut req = request.into_request(); @@ -2683,9 +2642,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/ListSubscriptions"); let mut req = request.into_request(); @@ -2702,9 +2662,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/DeleteSubscription"); let mut req = request.into_request(); @@ -2721,9 +2682,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/ModifyAckDeadline"); let mut req = request.into_request(); @@ -2742,9 +2704,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/Acknowledge"); let mut req = request.into_request(); @@ -2757,9 +2720,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/Pull"); let mut req = request.into_request(); @@ -2779,9 +2743,10 @@ pub mod subscriber_client { request: impl tonic::IntoStreamingRequest, ) -> std::result::Result>, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/StreamingPull"); let mut req = request.into_streaming_request(); @@ -2799,9 +2764,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/ModifyPushConfig"); let mut req = request.into_request(); @@ -2818,9 +2784,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/GetSnapshot"); let mut req = request.into_request(); @@ -2837,9 +2804,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/ListSnapshots"); let mut req = request.into_request(); @@ -2867,9 +2835,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/CreateSnapshot"); let mut req = request.into_request(); @@ -2887,9 +2856,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/UpdateSnapshot"); let mut req = request.into_request(); @@ -2910,9 +2880,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/DeleteSnapshot"); let mut req = request.into_request(); @@ -2931,9 +2902,10 @@ pub mod subscriber_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.pubsub.v1.Subscriber/Seek"); let mut req = request.into_request(); diff --git a/googleapis/src/google.r#type.rs b/googleapis/src/google.r#type.rs index 9eb064a3..b439eebc 100644 --- a/googleapis/src/google.r#type.rs +++ b/googleapis/src/google.r#type.rs @@ -30,7 +30,6 @@ /// The exact variables and functions that may be referenced within an expression /// are determined by the service that evaluates it. See the service /// documentation for additional information. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Expr { /// Textual representation of an expression in Common Expression Language @@ -64,7 +63,6 @@ pub struct Expr { /// /// Related types are [google.type.TimeOfDay][google.type.TimeOfDay] and /// `google.protobuf.Timestamp`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct Date { /// Year of the date. Must be from 1 to 9999, or 0 to specify a date without diff --git a/googleapis/src/google.rpc.rs b/googleapis/src/google.rpc.rs index 3c6f5f40..fe27d475 100644 --- a/googleapis/src/google.rpc.rs +++ b/googleapis/src/google.rpc.rs @@ -6,7 +6,6 @@ /// /// You can find out more about this error model and how to work with it in the /// [API Design Guide](). -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Status { /// The status code, which should be an enum value of diff --git a/googleapis/src/google.spanner.admin.database.v1.rs b/googleapis/src/google.spanner.admin.database.v1.rs index 6d20627f..67a4ca97 100644 --- a/googleapis/src/google.spanner.admin.database.v1.rs +++ b/googleapis/src/google.spanner.admin.database.v1.rs @@ -1,7 +1,6 @@ // This file is @generated by prost-build. /// Encapsulates progress related information for a Cloud Spanner long /// running operation. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct OperationProgress { /// Percent completion of the operation. @@ -17,7 +16,6 @@ pub struct OperationProgress { pub end_time: ::core::option::Option<::prost_types::Timestamp>, } /// Encryption configuration for a Cloud Spanner database. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct EncryptionConfig { /// The Cloud KMS key to be used for encrypting and decrypting @@ -44,7 +42,6 @@ pub struct EncryptionConfig { pub kms_key_names: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Encryption information for a Cloud Spanner database or backup. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct EncryptionInfo { /// Output only. The type of encryption. @@ -84,9 +81,9 @@ pub mod encryption_info { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Type::Unspecified => "TYPE_UNSPECIFIED", - Type::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", - Type::CustomerManagedEncryption => "CUSTOMER_MANAGED_ENCRYPTION", + Self::Unspecified => "TYPE_UNSPECIFIED", + Self::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", + Self::CustomerManagedEncryption => "CUSTOMER_MANAGED_ENCRYPTION", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -119,9 +116,9 @@ impl DatabaseDialect { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - DatabaseDialect::Unspecified => "DATABASE_DIALECT_UNSPECIFIED", - DatabaseDialect::GoogleStandardSql => "GOOGLE_STANDARD_SQL", - DatabaseDialect::Postgresql => "POSTGRESQL", + Self::Unspecified => "DATABASE_DIALECT_UNSPECIFIED", + Self::GoogleStandardSql => "GOOGLE_STANDARD_SQL", + Self::Postgresql => "POSTGRESQL", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -135,7 +132,6 @@ impl DatabaseDialect { } } /// A backup of a Cloud Spanner database. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Backup { /// Required for the @@ -295,9 +291,9 @@ pub mod backup { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Creating => "CREATING", - State::Ready => "READY", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Creating => "CREATING", + Self::Ready => "READY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -313,7 +309,6 @@ pub mod backup { } /// The request for /// [CreateBackup][google.spanner.admin.database.v1.DatabaseAdmin.CreateBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateBackupRequest { /// Required. The name of the instance in which the backup will be @@ -342,7 +337,6 @@ pub struct CreateBackupRequest { } /// Metadata type for the operation returned by /// [CreateBackup][google.spanner.admin.database.v1.DatabaseAdmin.CreateBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateBackupMetadata { /// The name of the backup being created. @@ -373,7 +367,6 @@ pub struct CreateBackupMetadata { } /// The request for /// [CopyBackup][google.spanner.admin.database.v1.DatabaseAdmin.CopyBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CopyBackupRequest { /// Required. The name of the destination instance that will contain the backup @@ -410,7 +403,6 @@ pub struct CopyBackupRequest { } /// Metadata type for the operation returned by /// [CopyBackup][google.spanner.admin.database.v1.DatabaseAdmin.CopyBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CopyBackupMetadata { /// The name of the backup being created through the copy operation. @@ -445,7 +437,6 @@ pub struct CopyBackupMetadata { } /// The request for /// [UpdateBackup][google.spanner.admin.database.v1.DatabaseAdmin.UpdateBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateBackupRequest { /// Required. The backup to update. `backup.name`, and the fields to be updated @@ -464,7 +455,6 @@ pub struct UpdateBackupRequest { } /// The request for /// [GetBackup][google.spanner.admin.database.v1.DatabaseAdmin.GetBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetBackupRequest { /// Required. Name of the backup. @@ -475,7 +465,6 @@ pub struct GetBackupRequest { } /// The request for /// [DeleteBackup][google.spanner.admin.database.v1.DatabaseAdmin.DeleteBackup]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteBackupRequest { /// Required. Name of the backup to delete. @@ -486,7 +475,6 @@ pub struct DeleteBackupRequest { } /// The request for /// [ListBackups][google.spanner.admin.database.v1.DatabaseAdmin.ListBackups]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBackupsRequest { /// Required. The instance to list backups from. Values are of the @@ -549,7 +537,6 @@ pub struct ListBackupsRequest { } /// The response for /// [ListBackups][google.spanner.admin.database.v1.DatabaseAdmin.ListBackups]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBackupsResponse { /// The list of matching backups. Backups returned are ordered by `create_time` @@ -564,7 +551,6 @@ pub struct ListBackupsResponse { } /// The request for /// [ListBackupOperations][google.spanner.admin.database.v1.DatabaseAdmin.ListBackupOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBackupOperationsRequest { /// Required. The instance of the backup operations. Values are of @@ -657,7 +643,6 @@ pub struct ListBackupOperationsRequest { } /// The response for /// [ListBackupOperations][google.spanner.admin.database.v1.DatabaseAdmin.ListBackupOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBackupOperationsResponse { /// The list of matching backup [long-running @@ -678,7 +663,6 @@ pub struct ListBackupOperationsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Information about a backup. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BackupInfo { /// Name of the backup. @@ -701,7 +685,6 @@ pub struct BackupInfo { pub source_database: ::prost::alloc::string::String, } /// Encryption configuration for the backup to create. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateBackupEncryptionConfig { /// Required. The encryption type of the backup. @@ -760,10 +743,10 @@ pub mod create_backup_encryption_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - EncryptionType::Unspecified => "ENCRYPTION_TYPE_UNSPECIFIED", - EncryptionType::UseDatabaseEncryption => "USE_DATABASE_ENCRYPTION", - EncryptionType::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", - EncryptionType::CustomerManagedEncryption => "CUSTOMER_MANAGED_ENCRYPTION", + Self::Unspecified => "ENCRYPTION_TYPE_UNSPECIFIED", + Self::UseDatabaseEncryption => "USE_DATABASE_ENCRYPTION", + Self::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", + Self::CustomerManagedEncryption => "CUSTOMER_MANAGED_ENCRYPTION", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -779,7 +762,6 @@ pub mod create_backup_encryption_config { } } /// Encryption configuration for the copied backup. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CopyBackupEncryptionConfig { /// Required. The encryption type of the backup. @@ -840,10 +822,10 @@ pub mod copy_backup_encryption_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - EncryptionType::Unspecified => "ENCRYPTION_TYPE_UNSPECIFIED", - EncryptionType::UseConfigDefaultOrBackupEncryption => "USE_CONFIG_DEFAULT_OR_BACKUP_ENCRYPTION", - EncryptionType::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", - EncryptionType::CustomerManagedEncryption => "CUSTOMER_MANAGED_ENCRYPTION", + Self::Unspecified => "ENCRYPTION_TYPE_UNSPECIFIED", + Self::UseConfigDefaultOrBackupEncryption => "USE_CONFIG_DEFAULT_OR_BACKUP_ENCRYPTION", + Self::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", + Self::CustomerManagedEncryption => "CUSTOMER_MANAGED_ENCRYPTION", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -861,7 +843,6 @@ pub mod copy_backup_encryption_config { /// The specification for full backups. /// A full backup stores the entire contents of the database at a given /// version time. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct FullBackupSpec {} /// The specification for incremental backup chains. @@ -870,11 +851,9 @@ pub struct FullBackupSpec {} /// incremental backup chain consists of a full backup and zero or more /// successive incremental backups. The first backup created for an /// incremental backup chain is always a full backup. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct IncrementalBackupSpec {} /// Defines specifications of the backup schedule. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BackupScheduleSpec { /// Required. @@ -884,7 +863,6 @@ pub struct BackupScheduleSpec { /// Nested message and enum types in `BackupScheduleSpec`. pub mod backup_schedule_spec { /// Required. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum ScheduleSpec { /// Cron style schedule specification. @@ -895,7 +873,6 @@ pub mod backup_schedule_spec { /// BackupSchedule expresses the automated backup creation specification for a /// Spanner database. /// Next ID: 10 -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BackupSchedule { /// Identifier. Output only for the @@ -937,7 +914,6 @@ pub struct BackupSchedule { pub mod backup_schedule { /// Required. Backup type spec determines the type of backup that is created by /// the backup schedule. Currently, only full backups are supported. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum BackupTypeSpec { /// The schedule creates only full backups. @@ -950,7 +926,6 @@ pub mod backup_schedule { } /// CrontabSpec can be used to specify the version time and frequency at /// which the backup should be created. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CrontabSpec { /// Required. Textual representation of the crontab. User can customize the @@ -983,7 +958,6 @@ pub struct CrontabSpec { } /// The request for /// [CreateBackupSchedule][google.spanner.admin.database.v1.DatabaseAdmin.CreateBackupSchedule]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateBackupScheduleRequest { /// Required. The name of the database that this backup schedule applies to. @@ -1000,7 +974,6 @@ pub struct CreateBackupScheduleRequest { } /// The request for /// [GetBackupSchedule][google.spanner.admin.database.v1.DatabaseAdmin.GetBackupSchedule]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetBackupScheduleRequest { /// Required. The name of the schedule to retrieve. @@ -1011,7 +984,6 @@ pub struct GetBackupScheduleRequest { } /// The request for /// [DeleteBackupSchedule][google.spanner.admin.database.v1.DatabaseAdmin.DeleteBackupSchedule]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteBackupScheduleRequest { /// Required. The name of the schedule to delete. @@ -1022,7 +994,6 @@ pub struct DeleteBackupScheduleRequest { } /// The request for /// [ListBackupSchedules][google.spanner.admin.database.v1.DatabaseAdmin.ListBackupSchedules]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBackupSchedulesRequest { /// Required. Database is the parent resource whose backup schedules should be @@ -1044,7 +1015,6 @@ pub struct ListBackupSchedulesRequest { } /// The response for /// [ListBackupSchedules][google.spanner.admin.database.v1.DatabaseAdmin.ListBackupSchedules]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBackupSchedulesResponse { /// The list of backup schedules for a database. @@ -1058,7 +1028,6 @@ pub struct ListBackupSchedulesResponse { } /// The request for /// [UpdateBackupScheduleRequest][google.spanner.admin.database.v1.DatabaseAdmin.UpdateBackupSchedule]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateBackupScheduleRequest { /// Required. The backup schedule to update. `backup_schedule.name`, and the @@ -1075,7 +1044,6 @@ pub struct UpdateBackupScheduleRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Information about the database restore. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RestoreInfo { /// The type of the restore source. @@ -1088,7 +1056,6 @@ pub struct RestoreInfo { /// Nested message and enum types in `RestoreInfo`. pub mod restore_info { /// Information about the source used to restore the database. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum SourceInfo { /// Information about the backup used to restore the database. The backup @@ -1098,7 +1065,6 @@ pub mod restore_info { } } /// A Cloud Spanner database. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Database { /// Required. The name of the database. Values are of the form @@ -1202,10 +1168,10 @@ pub mod database { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Creating => "CREATING", - State::Ready => "READY", - State::ReadyOptimizing => "READY_OPTIMIZING", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Creating => "CREATING", + Self::Ready => "READY", + Self::ReadyOptimizing => "READY_OPTIMIZING", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1222,7 +1188,6 @@ pub mod database { } /// The request for /// [ListDatabases][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabases]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDatabasesRequest { /// Required. The instance whose databases should be listed. @@ -1242,7 +1207,6 @@ pub struct ListDatabasesRequest { } /// The response for /// [ListDatabases][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabases]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDatabasesResponse { /// Databases that matched the request. @@ -1256,7 +1220,6 @@ pub struct ListDatabasesResponse { } /// The request for /// [CreateDatabase][google.spanner.admin.database.v1.DatabaseAdmin.CreateDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateDatabaseRequest { /// Required. The name of the instance that will serve the new database. @@ -1304,7 +1267,6 @@ pub struct CreateDatabaseRequest { } /// Metadata type for the operation returned by /// [CreateDatabase][google.spanner.admin.database.v1.DatabaseAdmin.CreateDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateDatabaseMetadata { /// The database being created. @@ -1313,7 +1275,6 @@ pub struct CreateDatabaseMetadata { } /// The request for /// [GetDatabase][google.spanner.admin.database.v1.DatabaseAdmin.GetDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetDatabaseRequest { /// Required. The name of the requested database. Values are of the form @@ -1323,7 +1284,6 @@ pub struct GetDatabaseRequest { } /// The request for /// [UpdateDatabase][google.spanner.admin.database.v1.DatabaseAdmin.UpdateDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateDatabaseRequest { /// Required. The database to update. @@ -1338,7 +1298,6 @@ pub struct UpdateDatabaseRequest { } /// Metadata type for the operation returned by /// [UpdateDatabase][google.spanner.admin.database.v1.DatabaseAdmin.UpdateDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateDatabaseMetadata { /// The request for @@ -1371,7 +1330,6 @@ pub struct UpdateDatabaseMetadata { /// progress. See the /// [operation_id][google.spanner.admin.database.v1.UpdateDatabaseDdlRequest.operation_id] /// field for more details. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateDatabaseDdlRequest { /// Required. The database to update. @@ -1423,7 +1381,6 @@ pub struct UpdateDatabaseDdlRequest { /// Action information extracted from a DDL statement. This proto is used to /// display the brief info of the DDL statement for the operation /// [UpdateDatabaseDdl][google.spanner.admin.database.v1.DatabaseAdmin.UpdateDatabaseDdl]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DdlStatementActionInfo { /// The action for the DDL statement, e.g. CREATE, ALTER, DROP, GRANT, etc. @@ -1445,7 +1402,6 @@ pub struct DdlStatementActionInfo { } /// Metadata type for the operation returned by /// [UpdateDatabaseDdl][google.spanner.admin.database.v1.DatabaseAdmin.UpdateDatabaseDdl]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateDatabaseDdlMetadata { /// The database being modified. @@ -1481,7 +1437,6 @@ pub struct UpdateDatabaseDdlMetadata { } /// The request for /// [DropDatabase][google.spanner.admin.database.v1.DatabaseAdmin.DropDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DropDatabaseRequest { /// Required. The database to be dropped. @@ -1490,7 +1445,6 @@ pub struct DropDatabaseRequest { } /// The request for /// [GetDatabaseDdl][google.spanner.admin.database.v1.DatabaseAdmin.GetDatabaseDdl]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetDatabaseDdlRequest { /// Required. The database whose schema we wish to get. @@ -1501,7 +1455,6 @@ pub struct GetDatabaseDdlRequest { } /// The response for /// [GetDatabaseDdl][google.spanner.admin.database.v1.DatabaseAdmin.GetDatabaseDdl]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetDatabaseDdlResponse { /// A list of formatted DDL statements defining the schema of the database @@ -1518,7 +1471,6 @@ pub struct GetDatabaseDdlResponse { } /// The request for /// [ListDatabaseOperations][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabaseOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDatabaseOperationsRequest { /// Required. The instance of the database operations. @@ -1586,7 +1538,6 @@ pub struct ListDatabaseOperationsRequest { } /// The response for /// [ListDatabaseOperations][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabaseOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDatabaseOperationsResponse { /// The list of matching database [long-running @@ -1604,7 +1555,6 @@ pub struct ListDatabaseOperationsResponse { } /// The request for /// [RestoreDatabase][google.spanner.admin.database.v1.DatabaseAdmin.RestoreDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RestoreDatabaseRequest { /// Required. The name of the instance in which to create the @@ -1635,7 +1585,6 @@ pub struct RestoreDatabaseRequest { /// Nested message and enum types in `RestoreDatabaseRequest`. pub mod restore_database_request { /// Required. The source from which to restore. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Source { /// Name of the backup from which to restore. Values are of the form @@ -1645,7 +1594,6 @@ pub mod restore_database_request { } } /// Encryption configuration for the restored database. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RestoreDatabaseEncryptionConfig { /// Required. The encryption type of the restored database. @@ -1701,10 +1649,10 @@ pub mod restore_database_encryption_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - EncryptionType::Unspecified => "ENCRYPTION_TYPE_UNSPECIFIED", - EncryptionType::UseConfigDefaultOrBackupEncryption => "USE_CONFIG_DEFAULT_OR_BACKUP_ENCRYPTION", - EncryptionType::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", - EncryptionType::CustomerManagedEncryption => "CUSTOMER_MANAGED_ENCRYPTION", + Self::Unspecified => "ENCRYPTION_TYPE_UNSPECIFIED", + Self::UseConfigDefaultOrBackupEncryption => "USE_CONFIG_DEFAULT_OR_BACKUP_ENCRYPTION", + Self::GoogleDefaultEncryption => "GOOGLE_DEFAULT_ENCRYPTION", + Self::CustomerManagedEncryption => "CUSTOMER_MANAGED_ENCRYPTION", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1721,7 +1669,6 @@ pub mod restore_database_encryption_config { } /// Metadata type for the long-running operation returned by /// [RestoreDatabase][google.spanner.admin.database.v1.DatabaseAdmin.RestoreDatabase]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RestoreDatabaseMetadata { /// Name of the database being created and restored to. @@ -1773,7 +1720,6 @@ pub mod restore_database_metadata { /// Information about the source used to restore the database, as specified by /// `source` in /// [RestoreDatabaseRequest][google.spanner.admin.database.v1.RestoreDatabaseRequest]. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum SourceInfo { /// Information about the backup used to restore the database. @@ -1785,7 +1731,6 @@ pub mod restore_database_metadata { /// of optimizations performed on a newly restored database. This long-running /// operation is automatically created by the system after the successful /// completion of a database restore, and cannot be cancelled. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct OptimizeRestoredDatabaseMetadata { /// Name of the restored database being optimized. @@ -1796,7 +1741,6 @@ pub struct OptimizeRestoredDatabaseMetadata { pub progress: ::core::option::Option, } /// A Cloud Spanner database role. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DatabaseRole { /// Required. The name of the database role. Values are of the form @@ -1807,7 +1751,6 @@ pub struct DatabaseRole { } /// The request for /// [ListDatabaseRoles][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabaseRoles]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDatabaseRolesRequest { /// Required. The database whose roles should be listed. @@ -1828,7 +1771,6 @@ pub struct ListDatabaseRolesRequest { } /// The response for /// [ListDatabaseRoles][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabaseRoles]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListDatabaseRolesResponse { /// Database roles that matched the request. @@ -1856,8 +1798,8 @@ impl RestoreSourceType { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - RestoreSourceType::TypeUnspecified => "TYPE_UNSPECIFIED", - RestoreSourceType::Backup => "BACKUP", + Self::TypeUnspecified => "TYPE_UNSPECIFIED", + Self::Backup => "BACKUP", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1871,7 +1813,13 @@ impl RestoreSourceType { } /// Generated client implementations. pub mod database_admin_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// Cloud Spanner Database Admin API @@ -1900,8 +1848,8 @@ pub mod database_admin_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -1919,7 +1867,8 @@ pub mod database_admin_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { DatabaseAdminClient::new(InterceptedService::new(inner, interceptor)) } @@ -1959,9 +1908,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/ListDatabases"); @@ -1987,9 +1937,10 @@ pub mod database_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/CreateDatabase"); @@ -2005,9 +1956,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/GetDatabase"); @@ -2059,9 +2011,10 @@ pub mod database_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/UpdateDatabase"); @@ -2087,9 +2040,10 @@ pub mod database_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.database.v1.DatabaseAdmin/UpdateDatabaseDdl", @@ -2110,9 +2064,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/DropDatabase"); @@ -2130,9 +2085,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/GetDatabaseDdl"); @@ -2155,9 +2111,10 @@ pub mod database_admin_client { request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/SetIamPolicy"); @@ -2181,9 +2138,10 @@ pub mod database_admin_client { request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/GetIamPolicy"); @@ -2211,9 +2169,10 @@ pub mod database_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.database.v1.DatabaseAdmin/TestIamPermissions", @@ -2244,9 +2203,10 @@ pub mod database_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/CreateBackup"); @@ -2277,9 +2237,10 @@ pub mod database_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/CopyBackup"); @@ -2294,9 +2255,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/GetBackup"); @@ -2311,9 +2273,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/UpdateBackup"); @@ -2330,9 +2293,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/DeleteBackup"); @@ -2350,9 +2314,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/ListBackups"); @@ -2385,9 +2350,10 @@ pub mod database_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.database.v1.DatabaseAdmin/RestoreDatabase"); @@ -2410,9 +2376,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.database.v1.DatabaseAdmin/ListDatabaseOperations", @@ -2438,9 +2405,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.database.v1.DatabaseAdmin/ListBackupOperations", @@ -2457,9 +2425,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.database.v1.DatabaseAdmin/ListDatabaseRoles", @@ -2476,9 +2445,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.database.v1.DatabaseAdmin/CreateBackupSchedule", @@ -2495,9 +2465,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.database.v1.DatabaseAdmin/GetBackupSchedule", @@ -2514,9 +2485,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.database.v1.DatabaseAdmin/UpdateBackupSchedule", @@ -2533,9 +2505,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.database.v1.DatabaseAdmin/DeleteBackupSchedule", @@ -2552,9 +2525,10 @@ pub mod database_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.database.v1.DatabaseAdmin/ListBackupSchedules", diff --git a/googleapis/src/google.spanner.admin.instance.v1.rs b/googleapis/src/google.spanner.admin.instance.v1.rs index b6d52431..276561ee 100644 --- a/googleapis/src/google.spanner.admin.instance.v1.rs +++ b/googleapis/src/google.spanner.admin.instance.v1.rs @@ -1,7 +1,6 @@ // This file is @generated by prost-build. /// Encapsulates progress related information for a Cloud Spanner long /// running instance operations. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct OperationProgress { /// Percent completion of the operation. @@ -36,9 +35,9 @@ impl FulfillmentPeriod { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - FulfillmentPeriod::Unspecified => "FULFILLMENT_PERIOD_UNSPECIFIED", - FulfillmentPeriod::Normal => "FULFILLMENT_PERIOD_NORMAL", - FulfillmentPeriod::Extended => "FULFILLMENT_PERIOD_EXTENDED", + Self::Unspecified => "FULFILLMENT_PERIOD_UNSPECIFIED", + Self::Normal => "FULFILLMENT_PERIOD_NORMAL", + Self::Extended => "FULFILLMENT_PERIOD_EXTENDED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -51,7 +50,6 @@ impl FulfillmentPeriod { } } } -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReplicaInfo { /// The location of the serving resources, e.g. "us-central1". @@ -108,10 +106,10 @@ pub mod replica_info { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ReplicaType::TypeUnspecified => "TYPE_UNSPECIFIED", - ReplicaType::ReadWrite => "READ_WRITE", - ReplicaType::ReadOnly => "READ_ONLY", - ReplicaType::Witness => "WITNESS", + Self::TypeUnspecified => "TYPE_UNSPECIFIED", + Self::ReadWrite => "READ_WRITE", + Self::ReadOnly => "READ_ONLY", + Self::Witness => "WITNESS", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -128,7 +126,6 @@ pub mod replica_info { } /// A possible configuration for a Cloud Spanner instance. Configurations /// define the geographic placement of nodes and their replication. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct InstanceConfig { /// A unique identifier for the instance configuration. Values @@ -229,9 +226,9 @@ pub mod instance_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Type::Unspecified => "TYPE_UNSPECIFIED", - Type::GoogleManaged => "GOOGLE_MANAGED", - Type::UserManaged => "USER_MANAGED", + Self::Unspecified => "TYPE_UNSPECIFIED", + Self::GoogleManaged => "GOOGLE_MANAGED", + Self::UserManaged => "USER_MANAGED", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -263,9 +260,9 @@ pub mod instance_config { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Creating => "CREATING", - State::Ready => "READY", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Creating => "CREATING", + Self::Ready => "READY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -280,7 +277,6 @@ pub mod instance_config { } } /// Autoscaling configuration for an instance. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AutoscalingConfig { /// Required. Autoscaling limits for an instance. @@ -297,7 +293,6 @@ pub mod autoscaling_config { /// only scale within that range. Users can either use nodes or processing /// units to specify the limits, but should use the same unit to set both the /// min_limit and max_limit. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AutoscalingLimits { /// The minimum compute capacity for the instance. @@ -312,7 +307,6 @@ pub mod autoscaling_config { /// Nested message and enum types in `AutoscalingLimits`. pub mod autoscaling_limits { /// The minimum compute capacity for the instance. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum MinLimit { /// Minimum number of nodes allocated to the instance. If set, this number @@ -327,7 +321,6 @@ pub mod autoscaling_config { /// The maximum compute capacity for the instance. The maximum compute /// capacity should be less than or equal to 10X the minimum compute /// capacity. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum MaxLimit { /// Maximum number of nodes allocated to the instance. If set, this number @@ -342,7 +335,6 @@ pub mod autoscaling_config { } } /// The autoscaling targets for an instance. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct AutoscalingTargets { /// Required. The target high priority cpu utilization percentage that the @@ -360,7 +352,6 @@ pub mod autoscaling_config { } } /// An isolated set of Cloud Spanner resources on which databases can be hosted. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Instance { /// Required. A unique identifier for the instance, which cannot be changed @@ -479,9 +470,9 @@ pub mod instance { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Creating => "CREATING", - State::Ready => "READY", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Creating => "CREATING", + Self::Ready => "READY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -515,10 +506,10 @@ pub mod instance { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Edition::Unspecified => "EDITION_UNSPECIFIED", - Edition::Standard => "STANDARD", - Edition::Enterprise => "ENTERPRISE", - Edition::EnterprisePlus => "ENTERPRISE_PLUS", + Self::Unspecified => "EDITION_UNSPECIFIED", + Self::Standard => "STANDARD", + Self::Enterprise => "ENTERPRISE", + Self::EnterprisePlus => "ENTERPRISE_PLUS", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -535,7 +526,6 @@ pub mod instance { } /// The request for /// [ListInstanceConfigs][google.spanner.admin.instance.v1.InstanceAdmin.ListInstanceConfigs]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstanceConfigsRequest { /// Required. The name of the project for which a list of supported instance @@ -556,7 +546,6 @@ pub struct ListInstanceConfigsRequest { } /// The response for /// [ListInstanceConfigs][google.spanner.admin.instance.v1.InstanceAdmin.ListInstanceConfigs]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstanceConfigsResponse { /// The list of requested instance configurations. @@ -570,7 +559,6 @@ pub struct ListInstanceConfigsResponse { } /// The request for /// [GetInstanceConfigRequest][google.spanner.admin.instance.v1.InstanceAdmin.GetInstanceConfig]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetInstanceConfigRequest { /// Required. The name of the requested instance configuration. Values are of @@ -580,7 +568,6 @@ pub struct GetInstanceConfigRequest { } /// The request for /// [CreateInstanceConfigRequest][InstanceAdmin.CreateInstanceConfigRequest]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateInstanceConfigRequest { /// Required. The name of the project in which to create the instance @@ -607,7 +594,6 @@ pub struct CreateInstanceConfigRequest { } /// The request for /// [UpdateInstanceConfigRequest][InstanceAdmin.UpdateInstanceConfigRequest]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateInstanceConfigRequest { /// Required. The user instance configuration to update, which must always @@ -634,7 +620,6 @@ pub struct UpdateInstanceConfigRequest { } /// The request for /// [DeleteInstanceConfigRequest][InstanceAdmin.DeleteInstanceConfigRequest]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteInstanceConfigRequest { /// Required. The name of the instance configuration to be deleted. @@ -658,7 +643,6 @@ pub struct DeleteInstanceConfigRequest { } /// The request for /// [ListInstanceConfigOperations][google.spanner.admin.instance.v1.InstanceAdmin.ListInstanceConfigOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstanceConfigOperationsRequest { /// Required. The project of the instance configuration operations. @@ -724,7 +708,6 @@ pub struct ListInstanceConfigOperationsRequest { } /// The response for /// [ListInstanceConfigOperations][google.spanner.admin.instance.v1.InstanceAdmin.ListInstanceConfigOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstanceConfigOperationsResponse { /// The list of matching instance configuration [long-running @@ -742,7 +725,6 @@ pub struct ListInstanceConfigOperationsResponse { } /// The request for /// [GetInstance][google.spanner.admin.instance.v1.InstanceAdmin.GetInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetInstanceRequest { /// Required. The name of the requested instance. Values are of the form @@ -758,7 +740,6 @@ pub struct GetInstanceRequest { } /// The request for /// [CreateInstance][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateInstanceRequest { /// Required. The name of the project in which to create the instance. Values @@ -777,7 +758,6 @@ pub struct CreateInstanceRequest { } /// The request for /// [ListInstances][google.spanner.admin.instance.v1.InstanceAdmin.ListInstances]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstancesRequest { /// Required. The name of the project for which a list of instances is @@ -826,7 +806,6 @@ pub struct ListInstancesRequest { } /// The response for /// [ListInstances][google.spanner.admin.instance.v1.InstanceAdmin.ListInstances]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstancesResponse { /// The list of requested instances. @@ -846,7 +825,6 @@ pub struct ListInstancesResponse { } /// The request for /// [UpdateInstance][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateInstanceRequest { /// Required. The instance to update, which must always include the instance @@ -865,7 +843,6 @@ pub struct UpdateInstanceRequest { } /// The request for /// [DeleteInstance][google.spanner.admin.instance.v1.InstanceAdmin.DeleteInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteInstanceRequest { /// Required. The name of the instance to be deleted. Values are of the form @@ -875,7 +852,6 @@ pub struct DeleteInstanceRequest { } /// Metadata type for the operation returned by /// [CreateInstance][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateInstanceMetadata { /// The instance being created. @@ -900,7 +876,6 @@ pub struct CreateInstanceMetadata { } /// Metadata type for the operation returned by /// [UpdateInstance][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateInstanceMetadata { /// The desired end state of the update. @@ -925,7 +900,6 @@ pub struct UpdateInstanceMetadata { } /// Metadata type for the operation returned by /// [CreateInstanceConfig][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstanceConfig]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateInstanceConfigMetadata { /// The target instance configuration end state. @@ -942,7 +916,6 @@ pub struct CreateInstanceConfigMetadata { } /// Metadata type for the operation returned by /// [UpdateInstanceConfig][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstanceConfig]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateInstanceConfigMetadata { /// The desired instance configuration after updating. @@ -959,7 +932,6 @@ pub struct UpdateInstanceConfigMetadata { } /// An isolated set of Cloud Spanner resources that databases can define /// placements on. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct InstancePartition { /// Required. A unique identifier for the instance partition. Values are of the @@ -1045,9 +1017,9 @@ pub mod instance_partition { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - State::Unspecified => "STATE_UNSPECIFIED", - State::Creating => "CREATING", - State::Ready => "READY", + Self::Unspecified => "STATE_UNSPECIFIED", + Self::Creating => "CREATING", + Self::Ready => "READY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1065,7 +1037,6 @@ pub mod instance_partition { /// node_count or processing_units should be present in the message. See [the /// documentation]() /// for more information about nodes and processing units. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum ComputeCapacity { /// The number of nodes allocated to this instance partition. @@ -1090,7 +1061,6 @@ pub mod instance_partition { } /// Metadata type for the operation returned by /// [CreateInstancePartition][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstancePartition]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateInstancePartitionMetadata { /// The instance partition being created. @@ -1112,7 +1082,6 @@ pub struct CreateInstancePartitionMetadata { } /// The request for /// [CreateInstancePartition][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstancePartition]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateInstancePartitionRequest { /// Required. The name of the instance in which to create the instance @@ -1133,7 +1102,6 @@ pub struct CreateInstancePartitionRequest { } /// The request for /// [DeleteInstancePartition][google.spanner.admin.instance.v1.InstanceAdmin.DeleteInstancePartition]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteInstancePartitionRequest { /// Required. The name of the instance partition to be deleted. @@ -1150,7 +1118,6 @@ pub struct DeleteInstancePartitionRequest { } /// The request for /// [GetInstancePartition][google.spanner.admin.instance.v1.InstanceAdmin.GetInstancePartition]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetInstancePartitionRequest { /// Required. The name of the requested instance partition. Values are of @@ -1161,7 +1128,6 @@ pub struct GetInstancePartitionRequest { } /// The request for /// [UpdateInstancePartition][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstancePartition]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateInstancePartitionRequest { /// Required. The instance partition to update, which must always include the @@ -1181,7 +1147,6 @@ pub struct UpdateInstancePartitionRequest { } /// Metadata type for the operation returned by /// [UpdateInstancePartition][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstancePartition]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateInstancePartitionMetadata { /// The desired end state of the update. @@ -1203,7 +1168,6 @@ pub struct UpdateInstancePartitionMetadata { } /// The request for /// [ListInstancePartitions][google.spanner.admin.instance.v1.InstanceAdmin.ListInstancePartitions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstancePartitionsRequest { /// Required. The instance whose instance partitions should be listed. Values @@ -1231,7 +1195,6 @@ pub struct ListInstancePartitionsRequest { } /// The response for /// [ListInstancePartitions][google.spanner.admin.instance.v1.InstanceAdmin.ListInstancePartitions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstancePartitionsResponse { /// The list of requested instancePartitions. @@ -1251,7 +1214,6 @@ pub struct ListInstancePartitionsResponse { } /// The request for /// [ListInstancePartitionOperations][google.spanner.admin.instance.v1.InstanceAdmin.ListInstancePartitionOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstancePartitionOperationsRequest { /// Required. The parent instance of the instance partition operations. @@ -1324,7 +1286,6 @@ pub struct ListInstancePartitionOperationsRequest { } /// The response for /// [ListInstancePartitionOperations][google.spanner.admin.instance.v1.InstanceAdmin.ListInstancePartitionOperations]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListInstancePartitionOperationsResponse { /// The list of matching instance partition [long-running @@ -1348,7 +1309,6 @@ pub struct ListInstancePartitionOperationsResponse { } /// The request for /// [MoveInstance][google.spanner.admin.instance.v1.InstanceAdmin.MoveInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MoveInstanceRequest { /// Required. The instance to move. @@ -1362,12 +1322,10 @@ pub struct MoveInstanceRequest { } /// The response for /// [MoveInstance][google.spanner.admin.instance.v1.InstanceAdmin.MoveInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct MoveInstanceResponse {} /// Metadata type for the operation returned by /// [MoveInstance][google.spanner.admin.instance.v1.InstanceAdmin.MoveInstance]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MoveInstanceMetadata { /// The target instance configuration where to move the instance. @@ -1387,7 +1345,13 @@ pub struct MoveInstanceMetadata { } /// Generated client implementations. pub mod instance_admin_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// Cloud Spanner Instance Admin API @@ -1430,8 +1394,8 @@ pub mod instance_admin_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -1449,7 +1413,8 @@ pub mod instance_admin_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { InstanceAdminClient::new(InterceptedService::new(inner, interceptor)) } @@ -1489,9 +1454,10 @@ pub mod instance_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.instance.v1.InstanceAdmin/ListInstanceConfigs", @@ -1508,9 +1474,10 @@ pub mod instance_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.instance.v1.InstanceAdmin/GetInstanceConfig", @@ -1570,9 +1537,10 @@ pub mod instance_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.instance.v1.InstanceAdmin/CreateInstanceConfig", @@ -1635,9 +1603,10 @@ pub mod instance_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.instance.v1.InstanceAdmin/UpdateInstanceConfig", @@ -1661,9 +1630,10 @@ pub mod instance_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.instance.v1.InstanceAdmin/DeleteInstanceConfig", @@ -1690,9 +1660,10 @@ pub mod instance_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.instance.v1.InstanceAdmin/ListInstanceConfigOperations", @@ -1709,9 +1680,10 @@ pub mod instance_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.instance.v1.InstanceAdmin/ListInstances"); @@ -1727,9 +1699,10 @@ pub mod instance_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.instance.v1.InstanceAdmin/ListInstancePartitions", @@ -1746,9 +1719,10 @@ pub mod instance_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.instance.v1.InstanceAdmin/GetInstance"); @@ -1798,9 +1772,10 @@ pub mod instance_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.instance.v1.InstanceAdmin/CreateInstance"); @@ -1858,9 +1833,10 @@ pub mod instance_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.instance.v1.InstanceAdmin/UpdateInstance"); @@ -1886,9 +1862,10 @@ pub mod instance_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.instance.v1.InstanceAdmin/DeleteInstance"); @@ -1909,9 +1886,10 @@ pub mod instance_admin_client { request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.instance.v1.InstanceAdmin/SetIamPolicy"); @@ -1932,9 +1910,10 @@ pub mod instance_admin_client { request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.instance.v1.InstanceAdmin/GetIamPolicy"); @@ -1958,9 +1937,10 @@ pub mod instance_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.instance.v1.InstanceAdmin/TestIamPermissions", @@ -1977,9 +1957,10 @@ pub mod instance_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.instance.v1.InstanceAdmin/GetInstancePartition", @@ -2035,9 +2016,10 @@ pub mod instance_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.instance.v1.InstanceAdmin/CreateInstancePartition", @@ -2060,9 +2042,10 @@ pub mod instance_admin_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.instance.v1.InstanceAdmin/DeleteInstancePartition", @@ -2125,9 +2108,10 @@ pub mod instance_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.instance.v1.InstanceAdmin/UpdateInstancePartition", @@ -2159,9 +2143,10 @@ pub mod instance_admin_client { request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static( "/google.spanner.admin.instance.v1.InstanceAdmin/ListInstancePartitionOperations", @@ -2241,9 +2226,10 @@ pub mod instance_admin_client { tonic::Response, tonic::Status, > { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.admin.instance.v1.InstanceAdmin/MoveInstance"); diff --git a/googleapis/src/google.spanner.v1.rs b/googleapis/src/google.spanner.v1.rs index f079b66b..99057994 100644 --- a/googleapis/src/google.spanner.v1.rs +++ b/googleapis/src/google.spanner.v1.rs @@ -1,6 +1,5 @@ // This file is @generated by prost-build. /// The response for [Commit][google.spanner.v1.Spanner.Commit]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct CommitResponse { /// The Cloud Spanner timestamp at which the transaction committed. @@ -15,7 +14,6 @@ pub struct CommitResponse { /// Nested message and enum types in `CommitResponse`. pub mod commit_response { /// Additional statistics about a commit. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct CommitStats { /// The total number of mutations for the transaction. Knowing the @@ -117,7 +115,6 @@ pub mod commit_response { /// /// Note that 100 is passed as the start, and 1 is passed as the end, /// because `Key` is a descending column in the schema. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct KeyRange { /// The start key must be provided. It can be either closed or open. @@ -130,7 +127,6 @@ pub struct KeyRange { /// Nested message and enum types in `KeyRange`. pub mod key_range { /// The start key must be provided. It can be either closed or open. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum StartKeyType { /// If the start is closed, then the range includes all rows whose @@ -143,7 +139,6 @@ pub mod key_range { StartOpen(::prost_types::ListValue), } /// The end key must be provided. It can be either closed or open. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum EndKeyType { /// If the end is closed, then the range includes all rows whose @@ -163,7 +158,6 @@ pub mod key_range { /// If the same key is specified multiple times in the set (for example /// if two ranges, two keys, or a key and a range overlap), Cloud Spanner /// behaves as if the key were only specified once. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct KeySet { /// A list of specific keys. Entries in `keys` should have exactly as @@ -185,7 +179,6 @@ pub struct KeySet { /// A modification to one or more Cloud Spanner rows. Mutations can be /// applied to a Cloud Spanner database by sending them in a /// [Commit][google.spanner.v1.Spanner.Commit] call. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Mutation { /// Required. The operation to perform. @@ -196,7 +189,6 @@ pub struct Mutation { pub mod mutation { /// Arguments to [insert][google.spanner.v1.Mutation.insert], [update][google.spanner.v1.Mutation.update], [insert_or_update][google.spanner.v1.Mutation.insert_or_update], and /// [replace][google.spanner.v1.Mutation.replace] operations. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Write { /// Required. The table whose rows will be written. @@ -221,7 +213,6 @@ pub mod mutation { pub values: ::prost::alloc::vec::Vec<::prost_types::ListValue>, } /// Arguments to [delete][google.spanner.v1.Mutation.delete] operations. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Delete { /// Required. The table whose rows will be deleted. @@ -237,7 +228,6 @@ pub mod mutation { pub key_set: ::core::option::Option, } /// Required. The operation to perform. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Operation { /// Insert new rows in a table. If any of the rows already exist, @@ -275,7 +265,6 @@ pub mod mutation { } } /// Node information for nodes appearing in a [QueryPlan.plan_nodes][google.spanner.v1.QueryPlan.plan_nodes]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PlanNode { /// The `PlanNode`'s index in [node list][google.spanner.v1.QueryPlan.plan_nodes]. @@ -318,7 +307,6 @@ pub struct PlanNode { pub mod plan_node { /// Metadata associated with a parent-child relationship appearing in a /// [PlanNode][google.spanner.v1.PlanNode]. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ChildLink { /// The node to which the link points. @@ -343,7 +331,6 @@ pub mod plan_node { } /// Condensed representation of a node and its subtree. Only present for /// `SCALAR` [PlanNode(s)][google.spanner.v1.PlanNode]. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ShortRepresentation { /// A string representation of the expression subtree rooted at this node. @@ -381,9 +368,9 @@ pub mod plan_node { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Kind::Unspecified => "KIND_UNSPECIFIED", - Kind::Relational => "RELATIONAL", - Kind::Scalar => "SCALAR", + Self::Unspecified => "KIND_UNSPECIFIED", + Self::Relational => "RELATIONAL", + Self::Scalar => "SCALAR", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -398,7 +385,6 @@ pub mod plan_node { } } /// Contains an ordered list of nodes appearing in the query plan. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct QueryPlan { /// The nodes in the query plan. Plan nodes are returned in pre-order starting @@ -731,7 +717,6 @@ pub struct QueryPlan { /// Given the above, Partitioned DML is good fit for large, database-wide, /// operations that are idempotent, such as deleting old rows from a very large /// table. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct TransactionOptions { /// When `exclude_txn_from_change_streams` is set to `true`: @@ -758,7 +743,6 @@ pub struct TransactionOptions { pub mod transaction_options { /// Message type to initiate a read-write transaction. Currently this /// transaction type has no options. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ReadWrite { /// Read lock mode for the transaction. @@ -794,9 +778,9 @@ pub mod transaction_options { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - ReadLockMode::Unspecified => "READ_LOCK_MODE_UNSPECIFIED", - ReadLockMode::Pessimistic => "PESSIMISTIC", - ReadLockMode::Optimistic => "OPTIMISTIC", + Self::Unspecified => "READ_LOCK_MODE_UNSPECIFIED", + Self::Pessimistic => "PESSIMISTIC", + Self::Optimistic => "OPTIMISTIC", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -811,11 +795,9 @@ pub mod transaction_options { } } /// Message type to initiate a Partitioned DML transaction. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct PartitionedDml {} /// Message type to initiate a read-only transaction. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ReadOnly { /// If true, the Cloud Spanner-selected read timestamp is included in @@ -830,7 +812,6 @@ pub mod transaction_options { /// Nested message and enum types in `ReadOnly`. pub mod read_only { /// How to choose the timestamp for the read-only transaction. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum TimestampBound { /// Read at a timestamp where all previously committed transactions @@ -894,7 +875,6 @@ pub mod transaction_options { } } /// Required. The type of transaction. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum Mode { /// Transaction may write. @@ -921,7 +901,6 @@ pub mod transaction_options { } } /// A transaction. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Transaction { /// `id` may be used to identify the transaction in subsequent @@ -949,7 +928,6 @@ pub struct Transaction { /// /// See [TransactionOptions][google.spanner.v1.TransactionOptions] for more /// information about transactions. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TransactionSelector { /// If no fields are set, the default is a single use transaction @@ -961,7 +939,6 @@ pub struct TransactionSelector { pub mod transaction_selector { /// If no fields are set, the default is a single use transaction /// with strong concurrency. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Selector { /// Execute the read or SQL query in a temporary transaction. @@ -982,7 +959,6 @@ pub mod transaction_selector { } /// `Type` indicates the type of a Cloud Spanner value, as might be stored in a /// table cell or returned from an SQL query. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Type { /// Required. The [TypeCode][google.spanner.v1.TypeCode] for this type. @@ -1013,7 +989,6 @@ pub struct Type { pub proto_type_fqn: ::prost::alloc::string::String, } /// `StructType` defines the fields of a [STRUCT][google.spanner.v1.TypeCode.STRUCT] type. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct StructType { /// The list of fields that make up this struct. Order is @@ -1028,7 +1003,6 @@ pub struct StructType { /// Nested message and enum types in `StructType`. pub mod struct_type { /// Message representing a single field of a struct. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Field { /// The name of the field. For reads, this is the column name. For @@ -1122,21 +1096,21 @@ impl TypeCode { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - TypeCode::Unspecified => "TYPE_CODE_UNSPECIFIED", - TypeCode::Bool => "BOOL", - TypeCode::Int64 => "INT64", - TypeCode::Float64 => "FLOAT64", - TypeCode::Float32 => "FLOAT32", - TypeCode::Timestamp => "TIMESTAMP", - TypeCode::Date => "DATE", - TypeCode::String => "STRING", - TypeCode::Bytes => "BYTES", - TypeCode::Array => "ARRAY", - TypeCode::Struct => "STRUCT", - TypeCode::Numeric => "NUMERIC", - TypeCode::Json => "JSON", - TypeCode::Proto => "PROTO", - TypeCode::Enum => "ENUM", + Self::Unspecified => "TYPE_CODE_UNSPECIFIED", + Self::Bool => "BOOL", + Self::Int64 => "INT64", + Self::Float64 => "FLOAT64", + Self::Float32 => "FLOAT32", + Self::Timestamp => "TIMESTAMP", + Self::Date => "DATE", + Self::String => "STRING", + Self::Bytes => "BYTES", + Self::Array => "ARRAY", + Self::Struct => "STRUCT", + Self::Numeric => "NUMERIC", + Self::Json => "JSON", + Self::Proto => "PROTO", + Self::Enum => "ENUM", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1197,10 +1171,10 @@ impl TypeAnnotationCode { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - TypeAnnotationCode::Unspecified => "TYPE_ANNOTATION_CODE_UNSPECIFIED", - TypeAnnotationCode::PgNumeric => "PG_NUMERIC", - TypeAnnotationCode::PgJsonb => "PG_JSONB", - TypeAnnotationCode::PgOid => "PG_OID", + Self::Unspecified => "TYPE_ANNOTATION_CODE_UNSPECIFIED", + Self::PgNumeric => "PG_NUMERIC", + Self::PgJsonb => "PG_JSONB", + Self::PgOid => "PG_OID", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1216,7 +1190,6 @@ impl TypeAnnotationCode { } /// Results from [Read][google.spanner.v1.Spanner.Read] or /// [ExecuteSql][google.spanner.v1.Spanner.ExecuteSql]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ResultSet { /// Metadata about the result set, such as row type information. @@ -1244,7 +1217,6 @@ pub struct ResultSet { /// Partial results from a streaming read or SQL query. Streaming reads and /// SQL queries better tolerate large result sets, large rows, and large /// values, but are a little trickier to consume. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PartialResultSet { /// Metadata about the result set, such as row type information. @@ -1348,7 +1320,6 @@ pub struct PartialResultSet { pub stats: ::core::option::Option, } /// Metadata about a [ResultSet][google.spanner.v1.ResultSet] or [PartialResultSet][google.spanner.v1.PartialResultSet]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ResultSetMetadata { /// Indicates the field names and types for the rows in the result @@ -1379,7 +1350,6 @@ pub struct ResultSetMetadata { pub undeclared_parameters: ::core::option::Option, } /// Additional statistics about a [ResultSet][google.spanner.v1.ResultSet] or [PartialResultSet][google.spanner.v1.PartialResultSet]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ResultSetStats { /// [QueryPlan][google.spanner.v1.QueryPlan] for the query associated with this result. @@ -1403,7 +1373,6 @@ pub struct ResultSetStats { /// Nested message and enum types in `ResultSetStats`. pub mod result_set_stats { /// The number of rows modified by the DML statement. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Oneof)] pub enum RowCount { /// Standard DML returns an exact count of rows that were modified. @@ -1416,7 +1385,6 @@ pub mod result_set_stats { } } /// The request for [CreateSession][google.spanner.v1.Spanner.CreateSession]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateSessionRequest { /// Required. The database in which the new session is created. @@ -1428,7 +1396,6 @@ pub struct CreateSessionRequest { } /// The request for /// [BatchCreateSessions][google.spanner.v1.Spanner.BatchCreateSessions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchCreateSessionsRequest { /// Required. The database in which the new sessions are created. @@ -1448,7 +1415,6 @@ pub struct BatchCreateSessionsRequest { } /// The response for /// [BatchCreateSessions][google.spanner.v1.Spanner.BatchCreateSessions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchCreateSessionsResponse { /// The freshly created sessions. @@ -1456,7 +1422,6 @@ pub struct BatchCreateSessionsResponse { pub session: ::prost::alloc::vec::Vec, } /// A session in the Cloud Spanner API. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Session { /// Output only. The name of the session. This is always system-assigned. @@ -1494,7 +1459,6 @@ pub struct Session { pub multiplexed: bool, } /// The request for [GetSession][google.spanner.v1.Spanner.GetSession]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetSessionRequest { /// Required. The name of the session to retrieve. @@ -1502,7 +1466,6 @@ pub struct GetSessionRequest { pub name: ::prost::alloc::string::String, } /// The request for [ListSessions][google.spanner.v1.Spanner.ListSessions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSessionsRequest { /// Required. The database in which to list sessions. @@ -1532,7 +1495,6 @@ pub struct ListSessionsRequest { pub filter: ::prost::alloc::string::String, } /// The response for [ListSessions][google.spanner.v1.Spanner.ListSessions]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListSessionsResponse { /// The list of requested sessions. @@ -1545,7 +1507,6 @@ pub struct ListSessionsResponse { pub next_page_token: ::prost::alloc::string::String, } /// The request for [DeleteSession][google.spanner.v1.Spanner.DeleteSession]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteSessionRequest { /// Required. The name of the session to delete. @@ -1553,7 +1514,6 @@ pub struct DeleteSessionRequest { pub name: ::prost::alloc::string::String, } /// Common request options for various APIs. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RequestOptions { /// Priority for the request. @@ -1622,10 +1582,10 @@ pub mod request_options { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Priority::Unspecified => "PRIORITY_UNSPECIFIED", - Priority::Low => "PRIORITY_LOW", - Priority::Medium => "PRIORITY_MEDIUM", - Priority::High => "PRIORITY_HIGH", + Self::Unspecified => "PRIORITY_UNSPECIFIED", + Self::Low => "PRIORITY_LOW", + Self::Medium => "PRIORITY_MEDIUM", + Self::High => "PRIORITY_HIGH", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1645,7 +1605,6 @@ pub mod request_options { /// /// DirectedReadOptions may only be specified for a read-only transaction, /// otherwise the API will return an `INVALID_ARGUMENT` error. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DirectedReadOptions { /// Required. At most one of either include_replicas or exclude_replicas @@ -1673,7 +1632,6 @@ pub mod directed_read_options { /// * `location:us-east1 type:READ_ONLY` --> The "READ_ONLY" type replica(s) /// in location "us-east1" will be used to process /// the request. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReplicaSelection { /// The location or region of the serving requests, e.g. "us-east1". @@ -1703,9 +1661,9 @@ pub mod directed_read_options { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Type::Unspecified => "TYPE_UNSPECIFIED", - Type::ReadWrite => "READ_WRITE", - Type::ReadOnly => "READ_ONLY", + Self::Unspecified => "TYPE_UNSPECIFIED", + Self::ReadWrite => "READ_WRITE", + Self::ReadOnly => "READ_ONLY", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1721,7 +1679,6 @@ pub mod directed_read_options { } /// An IncludeReplicas contains a repeated set of ReplicaSelection which /// indicates the order in which replicas should be considered. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct IncludeReplicas { /// The directed read replica selector. @@ -1735,7 +1692,6 @@ pub mod directed_read_options { } /// An ExcludeReplicas contains a repeated set of ReplicaSelection that should /// be excluded from serving requests. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ExcludeReplicas { /// The directed read replica selector. @@ -1744,7 +1700,6 @@ pub mod directed_read_options { } /// Required. At most one of either include_replicas or exclude_replicas /// should be present in the message. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Replicas { /// Include_replicas indicates the order of replicas (as they appear in @@ -1763,7 +1718,6 @@ pub mod directed_read_options { } /// The request for [ExecuteSql][google.spanner.v1.Spanner.ExecuteSql] and /// [ExecuteStreamingSql][google.spanner.v1.Spanner.ExecuteStreamingSql]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ExecuteSqlRequest { /// Required. The session in which the SQL query should be performed. @@ -1864,7 +1818,6 @@ pub struct ExecuteSqlRequest { /// Nested message and enum types in `ExecuteSqlRequest`. pub mod execute_sql_request { /// Query optimizer configuration. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct QueryOptions { /// An option to control the selection of optimizer version. @@ -1938,9 +1891,9 @@ pub mod execute_sql_request { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - QueryMode::Normal => "NORMAL", - QueryMode::Plan => "PLAN", - QueryMode::Profile => "PROFILE", + Self::Normal => "NORMAL", + Self::Plan => "PLAN", + Self::Profile => "PROFILE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1955,7 +1908,6 @@ pub mod execute_sql_request { } } /// The request for [ExecuteBatchDml][google.spanner.v1.Spanner.ExecuteBatchDml]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ExecuteBatchDmlRequest { /// Required. The session in which the DML statements should be performed. @@ -1993,7 +1945,6 @@ pub struct ExecuteBatchDmlRequest { /// Nested message and enum types in `ExecuteBatchDmlRequest`. pub mod execute_batch_dml_request { /// A single DML statement. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Statement { /// Required. The DML string. @@ -2058,7 +2009,6 @@ pub mod execute_batch_dml_request { /// status. The number of [ResultSet][google.spanner.v1.ResultSet] messages /// indicates that the third statement failed, and the fourth and fifth /// statements were not executed. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ExecuteBatchDmlResponse { /// One [ResultSet][google.spanner.v1.ResultSet] for each statement in the @@ -2079,7 +2029,6 @@ pub struct ExecuteBatchDmlResponse { } /// Options for a PartitionQueryRequest and /// PartitionReadRequest. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct PartitionOptions { /// **Note:** This hint is currently ignored by PartitionQuery and @@ -2102,7 +2051,6 @@ pub struct PartitionOptions { pub max_partitions: i64, } /// The request for [PartitionQuery][google.spanner.v1.Spanner.PartitionQuery] -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PartitionQueryRequest { /// Required. The session used to create the partitions. @@ -2156,7 +2104,6 @@ pub struct PartitionQueryRequest { pub partition_options: ::core::option::Option, } /// The request for [PartitionRead][google.spanner.v1.Spanner.PartitionRead] -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PartitionReadRequest { /// Required. The session used to create the partitions. @@ -2199,7 +2146,6 @@ pub struct PartitionReadRequest { } /// Information returned for each partition returned in a /// PartitionResponse. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Partition { /// This token can be passed to Read, StreamingRead, ExecuteSql, or @@ -2210,7 +2156,6 @@ pub struct Partition { } /// The response for [PartitionQuery][google.spanner.v1.Spanner.PartitionQuery] /// or [PartitionRead][google.spanner.v1.Spanner.PartitionRead] -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct PartitionResponse { /// Partitions created by this request. @@ -2222,7 +2167,6 @@ pub struct PartitionResponse { } /// The request for [Read][google.spanner.v1.Spanner.Read] and /// [StreamingRead][google.spanner.v1.Spanner.StreamingRead]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadRequest { /// Required. The session in which the read should be performed. @@ -2336,9 +2280,9 @@ pub mod read_request { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - OrderBy::Unspecified => "ORDER_BY_UNSPECIFIED", - OrderBy::PrimaryKey => "ORDER_BY_PRIMARY_KEY", - OrderBy::NoOrder => "ORDER_BY_NO_ORDER", + Self::Unspecified => "ORDER_BY_UNSPECIFIED", + Self::PrimaryKey => "ORDER_BY_PRIMARY_KEY", + Self::NoOrder => "ORDER_BY_NO_ORDER", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -2405,9 +2349,9 @@ pub mod read_request { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - LockHint::Unspecified => "LOCK_HINT_UNSPECIFIED", - LockHint::Shared => "LOCK_HINT_SHARED", - LockHint::Exclusive => "LOCK_HINT_EXCLUSIVE", + Self::Unspecified => "LOCK_HINT_UNSPECIFIED", + Self::Shared => "LOCK_HINT_SHARED", + Self::Exclusive => "LOCK_HINT_EXCLUSIVE", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -2423,7 +2367,6 @@ pub mod read_request { } /// The request for /// [BeginTransaction][google.spanner.v1.Spanner.BeginTransaction]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BeginTransactionRequest { /// Required. The session in which the transaction runs. @@ -2441,7 +2384,6 @@ pub struct BeginTransactionRequest { pub request_options: ::core::option::Option, } /// The request for [Commit][google.spanner.v1.Spanner.Commit]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CommitRequest { /// Required. The session in which the transaction to be committed is running. @@ -2474,7 +2416,6 @@ pub struct CommitRequest { /// Nested message and enum types in `CommitRequest`. pub mod commit_request { /// Required. The transaction in which to commit. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Transaction { /// Commit a previously-started transaction. @@ -2494,7 +2435,6 @@ pub mod commit_request { } } /// The request for [Rollback][google.spanner.v1.Spanner.Rollback]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RollbackRequest { /// Required. The session in which the transaction to roll back is running. @@ -2505,7 +2445,6 @@ pub struct RollbackRequest { pub transaction_id: ::prost::alloc::vec::Vec, } /// The request for [BatchWrite][google.spanner.v1.Spanner.BatchWrite]. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchWriteRequest { /// Required. The session in which the batch request is to be run. @@ -2537,7 +2476,6 @@ pub mod batch_write_request { /// A group of mutations to be committed together. Related mutations should be /// placed in a group. For example, two mutations inserting rows with the same /// primary key prefix in both parent and child tables are related. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct MutationGroup { /// Required. The mutations in this group. @@ -2546,7 +2484,6 @@ pub mod batch_write_request { } } /// The result of applying a batch of mutations. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BatchWriteResponse { /// The mutation groups applied in this batch. The values index into the @@ -2563,7 +2500,13 @@ pub struct BatchWriteResponse { } /// Generated client implementations. pub mod spanner_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// Cloud Spanner API @@ -2589,8 +2532,8 @@ pub mod spanner_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -2608,7 +2551,8 @@ pub mod spanner_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { SpannerClient::new(InterceptedService::new(inner, interceptor)) } @@ -2666,9 +2610,10 @@ pub mod spanner_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/CreateSession"); let mut req = request.into_request(); @@ -2684,9 +2629,10 @@ pub mod spanner_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/BatchCreateSessions"); let mut req = request.into_request(); @@ -2701,9 +2647,10 @@ pub mod spanner_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/GetSession"); let mut req = request.into_request(); @@ -2716,9 +2663,10 @@ pub mod spanner_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/ListSessions"); let mut req = request.into_request(); @@ -2733,9 +2681,10 @@ pub mod spanner_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/DeleteSession"); let mut req = request.into_request(); @@ -2760,9 +2709,10 @@ pub mod spanner_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/ExecuteSql"); let mut req = request.into_request(); @@ -2780,9 +2730,10 @@ pub mod spanner_client { request: impl tonic::IntoRequest, ) -> std::result::Result>, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/ExecuteStreamingSql"); let mut req = request.into_request(); @@ -2806,9 +2757,10 @@ pub mod spanner_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/ExecuteBatchDml"); let mut req = request.into_request(); @@ -2834,9 +2786,10 @@ pub mod spanner_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/Read"); let mut req = request.into_request(); @@ -2854,9 +2807,10 @@ pub mod spanner_client { request: impl tonic::IntoRequest, ) -> std::result::Result>, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/StreamingRead"); let mut req = request.into_request(); @@ -2873,9 +2827,10 @@ pub mod spanner_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/BeginTransaction"); let mut req = request.into_request(); @@ -2901,9 +2856,10 @@ pub mod spanner_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/Commit"); let mut req = request.into_request(); @@ -2924,9 +2880,10 @@ pub mod spanner_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/Rollback"); let mut req = request.into_request(); @@ -2950,9 +2907,10 @@ pub mod spanner_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/PartitionQuery"); let mut req = request.into_request(); @@ -2978,9 +2936,10 @@ pub mod spanner_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/PartitionRead"); let mut req = request.into_request(); @@ -3008,9 +2967,10 @@ pub mod spanner_client { request: impl tonic::IntoRequest, ) -> std::result::Result>, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.spanner.v1.Spanner/BatchWrite"); let mut req = request.into_request(); diff --git a/googleapis/src/google.storage.v2.rs b/googleapis/src/google.storage.v2.rs index 02365287..8770af23 100644 --- a/googleapis/src/google.storage.v2.rs +++ b/googleapis/src/google.storage.v2.rs @@ -1,6 +1,5 @@ // This file is @generated by prost-build. /// Request message for DeleteBucket. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteBucketRequest { /// Required. Name of a bucket to delete. @@ -15,7 +14,6 @@ pub struct DeleteBucketRequest { pub if_metageneration_not_match: ::core::option::Option, } /// Request message for GetBucket. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetBucketRequest { /// Required. Name of a bucket. @@ -36,7 +34,6 @@ pub struct GetBucketRequest { pub read_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Request message for CreateBucket. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateBucketRequest { /// Required. The project to which this bucket will belong. @@ -68,7 +65,6 @@ pub struct CreateBucketRequest { pub predefined_default_object_acl: ::prost::alloc::string::String, } /// Request message for ListBuckets. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBucketsRequest { /// Required. The project whose buckets we are listing. @@ -95,7 +91,6 @@ pub struct ListBucketsRequest { pub read_mask: ::core::option::Option<::prost_types::FieldMask>, } /// The result of a call to Buckets.ListBuckets -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListBucketsResponse { /// The list of items. @@ -107,7 +102,6 @@ pub struct ListBucketsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Request message for LockBucketRetentionPolicyRequest. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct LockBucketRetentionPolicyRequest { /// Required. Name of a bucket. @@ -119,7 +113,6 @@ pub struct LockBucketRetentionPolicyRequest { pub if_metageneration_match: i64, } /// Request for UpdateBucket method. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateBucketRequest { /// Required. The bucket to update. @@ -156,7 +149,6 @@ pub struct UpdateBucketRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Request message for ComposeObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ComposeObjectRequest { /// Required. Properties of the resulting object. @@ -196,7 +188,6 @@ pub struct ComposeObjectRequest { /// Nested message and enum types in `ComposeObjectRequest`. pub mod compose_object_request { /// Description of a source object for a composition request. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct SourceObject { /// Required. The source object's name. All source objects must reside in the @@ -213,7 +204,6 @@ pub mod compose_object_request { /// Nested message and enum types in `SourceObject`. pub mod source_object { /// Preconditions for a source object of a composition request. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ObjectPreconditions { /// Only perform the composition if the generation of the source object @@ -226,7 +216,6 @@ pub mod compose_object_request { } /// Message for deleting an object. /// `bucket` and `object` **must** be set. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteObjectRequest { /// Required. Name of the bucket in which the object resides. @@ -266,7 +255,6 @@ pub struct DeleteObjectRequest { } /// Message for restoring an object. /// `bucket`, `object`, and `generation` **must** be set. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RestoreObjectRequest { /// Required. Name of the bucket in which the object resides. @@ -308,7 +296,6 @@ pub struct RestoreObjectRequest { } /// Message for canceling an in-progress resumable upload. /// `upload_id` **must** be set. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CancelResumableWriteRequest { /// Required. The upload_id of the resumable upload to cancel. This should be @@ -318,11 +305,9 @@ pub struct CancelResumableWriteRequest { } /// Empty response message for canceling an in-progress resumable upload, will be /// extended as needed. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct CancelResumableWriteResponse {} /// Request message for ReadObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadObjectRequest { /// Required. The name of the bucket containing the object to read. @@ -386,7 +371,6 @@ pub struct ReadObjectRequest { pub read_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Request message for GetObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetObjectRequest { /// Required. Name of the bucket in which the object resides. @@ -432,7 +416,6 @@ pub struct GetObjectRequest { pub read_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Response message for ReadObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ReadObjectResponse { /// A portion of the data for the object. The service **may** leave `data` @@ -457,7 +440,6 @@ pub struct ReadObjectResponse { pub metadata: ::core::option::Option, } /// Describes an attempt to insert an object, possibly over multiple requests. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct WriteObjectSpec { /// Required. Destination object, including its name and its metadata. @@ -498,7 +480,6 @@ pub struct WriteObjectSpec { pub object_size: ::core::option::Option, } /// Request message for WriteObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct WriteObjectRequest { /// Required. The offset from the beginning of the object at which the data @@ -543,7 +524,6 @@ pub struct WriteObjectRequest { /// Nested message and enum types in `WriteObjectRequest`. pub mod write_object_request { /// The first message of each stream should set one of the following. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum FirstMessage { /// For resumable uploads. This should be the `upload_id` returned from a @@ -556,7 +536,6 @@ pub mod write_object_request { WriteObjectSpec(super::WriteObjectSpec), } /// A portion of the data for the object. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Data { /// The data to insert. If a crc32c checksum is provided that doesn't match @@ -566,7 +545,6 @@ pub mod write_object_request { } } /// Response message for WriteObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct WriteObjectResponse { /// The response will set one of the following. @@ -576,7 +554,6 @@ pub struct WriteObjectResponse { /// Nested message and enum types in `WriteObjectResponse`. pub mod write_object_response { /// The response will set one of the following. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum WriteStatus { /// The total number of bytes that have been processed for the given object @@ -590,7 +567,6 @@ pub mod write_object_response { } } /// Request message for BidiWriteObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BidiWriteObjectRequest { /// Required. The offset from the beginning of the object at which the data @@ -652,7 +628,6 @@ pub struct BidiWriteObjectRequest { /// Nested message and enum types in `BidiWriteObjectRequest`. pub mod bidi_write_object_request { /// The first message of each stream should set one of the following. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum FirstMessage { /// For resumable uploads. This should be the `upload_id` returned from a @@ -665,7 +640,6 @@ pub mod bidi_write_object_request { WriteObjectSpec(super::WriteObjectSpec), } /// A portion of the data for the object. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum Data { /// The data to insert. If a crc32c checksum is provided that doesn't match @@ -675,7 +649,6 @@ pub mod bidi_write_object_request { } } /// Response message for BidiWriteObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BidiWriteObjectResponse { /// The response will set one of the following. @@ -685,7 +658,6 @@ pub struct BidiWriteObjectResponse { /// Nested message and enum types in `BidiWriteObjectResponse`. pub mod bidi_write_object_response { /// The response will set one of the following. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum WriteStatus { /// The total number of bytes that have been processed for the given object @@ -699,7 +671,6 @@ pub mod bidi_write_object_response { } } /// Request message for ListObjects. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListObjectsRequest { /// Required. Name of the bucket in which to look for objects. @@ -771,7 +742,6 @@ pub struct ListObjectsRequest { pub match_glob: ::prost::alloc::string::String, } /// Request object for `QueryWriteStatus`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct QueryWriteStatusRequest { /// Required. The name of the resume token for the object whose write status is @@ -783,7 +753,6 @@ pub struct QueryWriteStatusRequest { pub common_object_request_params: ::core::option::Option, } /// Response object for `QueryWriteStatus`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct QueryWriteStatusResponse { /// The response will set one of the following. @@ -793,7 +762,6 @@ pub struct QueryWriteStatusResponse { /// Nested message and enum types in `QueryWriteStatusResponse`. pub mod query_write_status_response { /// The response will set one of the following. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum WriteStatus { /// The total number of bytes that have been processed for the given object @@ -816,7 +784,6 @@ pub mod query_write_status_response { /// should be provided in the encryption_algorithm, encryption_key_bytes, and /// encryption_key_sha256_bytes fields of the /// common_object_request_params.customer_encryption field. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RewriteObjectRequest { /// Required. Immutable. The name of the destination object. @@ -938,7 +905,6 @@ pub struct RewriteObjectRequest { pub object_checksums: ::core::option::Option, } /// A rewrite response. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct RewriteResponse { /// The total bytes written so far, which can be used to provide a waiting user @@ -963,7 +929,6 @@ pub struct RewriteResponse { pub resource: ::core::option::Option, } /// Request message StartResumableWrite. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct StartResumableWriteRequest { /// Required. The destination bucket, object, and metadata, as well as any @@ -981,7 +946,6 @@ pub struct StartResumableWriteRequest { pub object_checksums: ::core::option::Option, } /// Response object for `StartResumableWrite`. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct StartResumableWriteResponse { /// The upload_id of the newly started resumable write operation. This @@ -990,7 +954,6 @@ pub struct StartResumableWriteResponse { pub upload_id: ::prost::alloc::string::String, } /// Request message for UpdateObject. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateObjectRequest { /// Required. The object to update. @@ -1039,7 +1002,6 @@ pub struct UpdateObjectRequest { pub common_object_request_params: ::core::option::Option, } /// Request message for GetServiceAccount. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetServiceAccountRequest { /// Required. Project ID, in the format of "projects/{projectIdentifier}". @@ -1050,7 +1012,6 @@ pub struct GetServiceAccountRequest { /// A service account, owned by Cloud Storage, which may be used when taking /// action on behalf of a given project, for example to publish Pub/Sub /// notifications or to retrieve security keys. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ServiceAccount { /// The ID of the notification. @@ -1058,7 +1019,6 @@ pub struct ServiceAccount { pub email_address: ::prost::alloc::string::String, } /// Request message for CreateHmacKey. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateHmacKeyRequest { /// Required. The project that the HMAC-owning service account lives in, in the @@ -1071,7 +1031,6 @@ pub struct CreateHmacKeyRequest { pub service_account_email: ::prost::alloc::string::String, } /// Create hmac response. The only time the secret for an HMAC will be returned. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateHmacKeyResponse { /// Key metadata. @@ -1083,7 +1042,6 @@ pub struct CreateHmacKeyResponse { pub secret_key_bytes: ::prost::alloc::vec::Vec, } /// Request object to delete a given HMAC key. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteHmacKeyRequest { /// Required. The identifying key for the HMAC to delete. @@ -1096,7 +1054,6 @@ pub struct DeleteHmacKeyRequest { pub project: ::prost::alloc::string::String, } /// Request object to get metadata on a given HMAC key. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetHmacKeyRequest { /// Required. The identifying key for the HMAC to delete. @@ -1109,7 +1066,6 @@ pub struct GetHmacKeyRequest { pub project: ::prost::alloc::string::String, } /// Request to fetch a list of HMAC keys under a given project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListHmacKeysRequest { /// Required. The project to list HMAC keys for, in the format of @@ -1131,7 +1087,6 @@ pub struct ListHmacKeysRequest { pub show_deleted_keys: bool, } /// Hmac key list response with next page information. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListHmacKeysResponse { /// The list of items. @@ -1146,7 +1101,6 @@ pub struct ListHmacKeysResponse { /// HmacKeyMetadata.state is required and the only writable field in /// UpdateHmacKey operation. Specifying fields other than state will result in an /// error. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct UpdateHmacKeyRequest { /// Required. The HMAC key to update. @@ -1162,7 +1116,6 @@ pub struct UpdateHmacKeyRequest { pub update_mask: ::core::option::Option<::prost_types::FieldMask>, } /// Hmac Key Metadata, which includes all information other than the secret. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct HmacKeyMetadata { /// Immutable. Resource name ID of the key in the format @@ -1196,7 +1149,6 @@ pub struct HmacKeyMetadata { pub etag: ::prost::alloc::string::String, } /// Parameters that can be passed to any object request. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CommonObjectRequestParams { /// Encryption algorithm used with the Customer-Supplied Encryption Keys @@ -1213,7 +1165,6 @@ pub struct CommonObjectRequestParams { pub encryption_key_sha256_bytes: ::prost::alloc::vec::Vec, } /// Shared constants. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ServiceConstants {} /// Nested message and enum types in `ServiceConstants`. @@ -1278,21 +1229,21 @@ pub mod service_constants { /// (if the ProtoBuf definition does not change) and safe for programmatic use. pub fn as_str_name(&self) -> &'static str { match self { - Values::Unspecified => "VALUES_UNSPECIFIED", - Values::MaxReadChunkBytes => "MAX_READ_CHUNK_BYTES", - Values::MaxObjectSizeMb => "MAX_OBJECT_SIZE_MB", - Values::MaxCustomMetadataFieldNameBytes => "MAX_CUSTOM_METADATA_FIELD_NAME_BYTES", - Values::MaxCustomMetadataFieldValueBytes => "MAX_CUSTOM_METADATA_FIELD_VALUE_BYTES", - Values::MaxCustomMetadataTotalSizeBytes => "MAX_CUSTOM_METADATA_TOTAL_SIZE_BYTES", - Values::MaxBucketMetadataTotalSizeBytes => "MAX_BUCKET_METADATA_TOTAL_SIZE_BYTES", - Values::MaxNotificationConfigsPerBucket => "MAX_NOTIFICATION_CONFIGS_PER_BUCKET", - Values::MaxNotificationCustomAttributes => "MAX_NOTIFICATION_CUSTOM_ATTRIBUTES", - Values::MaxNotificationCustomAttributeKeyLength => "MAX_NOTIFICATION_CUSTOM_ATTRIBUTE_KEY_LENGTH", - Values::MaxLabelsEntriesCount => "MAX_LABELS_ENTRIES_COUNT", - Values::MaxLabelsKeyValueLength => "MAX_LABELS_KEY_VALUE_LENGTH", - Values::MaxLabelsKeyValueBytes => "MAX_LABELS_KEY_VALUE_BYTES", - Values::MaxObjectIdsPerDeleteObjectsRequest => "MAX_OBJECT_IDS_PER_DELETE_OBJECTS_REQUEST", - Values::SplitTokenMaxValidDays => "SPLIT_TOKEN_MAX_VALID_DAYS", + Self::Unspecified => "VALUES_UNSPECIFIED", + Self::MaxReadChunkBytes => "MAX_READ_CHUNK_BYTES", + Self::MaxObjectSizeMb => "MAX_OBJECT_SIZE_MB", + Self::MaxCustomMetadataFieldNameBytes => "MAX_CUSTOM_METADATA_FIELD_NAME_BYTES", + Self::MaxCustomMetadataFieldValueBytes => "MAX_CUSTOM_METADATA_FIELD_VALUE_BYTES", + Self::MaxCustomMetadataTotalSizeBytes => "MAX_CUSTOM_METADATA_TOTAL_SIZE_BYTES", + Self::MaxBucketMetadataTotalSizeBytes => "MAX_BUCKET_METADATA_TOTAL_SIZE_BYTES", + Self::MaxNotificationConfigsPerBucket => "MAX_NOTIFICATION_CONFIGS_PER_BUCKET", + Self::MaxNotificationCustomAttributes => "MAX_NOTIFICATION_CUSTOM_ATTRIBUTES", + Self::MaxNotificationCustomAttributeKeyLength => "MAX_NOTIFICATION_CUSTOM_ATTRIBUTE_KEY_LENGTH", + Self::MaxLabelsEntriesCount => "MAX_LABELS_ENTRIES_COUNT", + Self::MaxLabelsKeyValueLength => "MAX_LABELS_KEY_VALUE_LENGTH", + Self::MaxLabelsKeyValueBytes => "MAX_LABELS_KEY_VALUE_BYTES", + Self::MaxObjectIdsPerDeleteObjectsRequest => "MAX_OBJECT_IDS_PER_DELETE_OBJECTS_REQUEST", + Self::SplitTokenMaxValidDays => "SPLIT_TOKEN_MAX_VALID_DAYS", } } /// Creates an enum from field names used in the ProtoBuf definition. @@ -1319,7 +1270,6 @@ pub mod service_constants { } } /// A bucket. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Bucket { /// Immutable. The name of the bucket. @@ -1477,7 +1427,6 @@ pub struct Bucket { /// Nested message and enum types in `Bucket`. pub mod bucket { /// Billing properties of a bucket. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct Billing { /// When set to true, Requester Pays is enabled for this bucket. @@ -1488,7 +1437,6 @@ pub mod bucket { /// For more on Cloud Storage and CORS, see /// /// For more on CORS in general, see - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Cors { /// The list of Origins eligible to receive CORS response headers. See @@ -1513,7 +1461,6 @@ pub mod bucket { pub max_age_seconds: i32, } /// Encryption properties of a bucket. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Encryption { /// The name of the Cloud KMS key that will be used to encrypt objects @@ -1522,7 +1469,6 @@ pub mod bucket { pub default_kms_key: ::prost::alloc::string::String, } /// Bucket restriction options. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct IamConfig { /// Bucket restriction options currently enforced on the bucket. @@ -1537,7 +1483,6 @@ pub mod bucket { pub mod iam_config { /// Settings for Uniform Bucket level access. /// See - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct UniformBucketLevelAccess { /// If set, access checks only use bucket-level IAM policies or above. @@ -1553,7 +1498,6 @@ pub mod bucket { } /// Lifecycle properties of a bucket. /// For more information, see - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Lifecycle { /// A lifecycle management rule, which is made of an action to take and the @@ -1565,7 +1509,6 @@ pub mod bucket { pub mod lifecycle { /// A lifecycle Rule, combining an action to take on an object and a /// condition which will trigger that action. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Rule { /// The action to take. @@ -1578,7 +1521,6 @@ pub mod bucket { /// Nested message and enum types in `Rule`. pub mod rule { /// An action to take on an object. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Action { /// Type of the action. Currently, only `Delete`, `SetStorageClass`, and @@ -1591,7 +1533,6 @@ pub mod bucket { pub storage_class: ::prost::alloc::string::String, } /// A condition of an object which triggers some action. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Condition { /// Age of an object (in days). This condition is satisfied when an @@ -1653,7 +1594,6 @@ pub mod bucket { } } /// Logging-related properties of a bucket. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Logging { /// The destination bucket where the current bucket's logs should be placed, @@ -1665,7 +1605,6 @@ pub mod bucket { pub log_object_prefix: ::prost::alloc::string::String, } /// Retention policy properties of a bucket. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct RetentionPolicy { /// Server-determined value that indicates the time from which policy was @@ -1684,7 +1623,6 @@ pub mod bucket { pub retention_duration: ::core::option::Option<::prost_types::Duration>, } /// Soft delete policy properties of a bucket. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct SoftDeletePolicy { /// The period of time that soft-deleted objects in the bucket must be @@ -1699,7 +1637,6 @@ pub mod bucket { /// Properties of a bucket related to versioning. /// For more on Cloud Storage versioning, see /// - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct Versioning { /// While set to true, versioning is fully enabled for this bucket. @@ -1709,7 +1646,6 @@ pub mod bucket { /// Properties of a bucket related to accessing the contents as a static /// website. For more on hosting a static website via Cloud Storage, see /// - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Website { /// If the requested object path is missing, the service will ensure the path @@ -1729,7 +1665,6 @@ pub mod bucket { /// Configuration for Custom Dual Regions. It should specify precisely two /// eligible regions within the same Multiregion. More information on regions /// may be found [ - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CustomPlacementConfig { /// List of locations to use for data placement. @@ -1737,7 +1672,6 @@ pub mod bucket { pub data_locations: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, } /// Configuration for a bucket's Autoclass feature. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Autoclass { /// Enables Autoclass. @@ -1760,7 +1694,6 @@ pub mod bucket { pub terminal_storage_class_update_time: ::core::option::Option<::prost_types::Timestamp>, } /// Configuration for a bucket's hierarchical namespace feature. - #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct HierarchicalNamespace { /// Optional. Enables the hierarchical namespace feature. @@ -1769,7 +1702,6 @@ pub mod bucket { } } /// An access-control entry. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct BucketAccessControl { /// The access permission for the entity. @@ -1823,7 +1755,6 @@ pub struct BucketAccessControl { } /// Message used to convey content being read or written, along with an optional /// checksum. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ChecksummedData { /// Optional. The data. @@ -1834,7 +1765,6 @@ pub struct ChecksummedData { pub crc32c: ::core::option::Option, } /// Message used for storing full (not subrange) object checksums. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ObjectChecksums { /// CRC32C digest of the object data. Computed by the Cloud Storage service for @@ -1855,7 +1785,6 @@ pub struct ObjectChecksums { } /// Describes the Customer-Supplied Encryption Key mechanism used to store an /// Object's data at rest. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CustomerEncryption { /// The encryption algorithm. @@ -1867,7 +1796,6 @@ pub struct CustomerEncryption { pub key_sha256_bytes: ::prost::alloc::vec::Vec, } /// An object. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Object { /// Immutable. The name of this object. Nearly any sequence of unicode @@ -2025,7 +1953,6 @@ pub struct Object { pub hard_delete_time: ::core::option::Option<::prost_types::Timestamp>, } /// An access-control entry. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ObjectAccessControl { /// The access permission for the entity. One of the following values: @@ -2081,7 +2008,6 @@ pub struct ObjectAccessControl { pub project_team: ::core::option::Option, } /// The result of a call to Objects.ListObjects -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListObjectsResponse { /// The list of items. @@ -2097,7 +2023,6 @@ pub struct ListObjectsResponse { pub next_page_token: ::prost::alloc::string::String, } /// Represents the Viewers, Editors, or Owners of a given project. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ProjectTeam { /// The project number. @@ -2108,7 +2033,6 @@ pub struct ProjectTeam { pub team: ::prost::alloc::string::String, } /// The owner of a specific resource. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Owner { /// The entity, in the form `user-`*userId*. @@ -2119,7 +2043,6 @@ pub struct Owner { pub entity_id: ::prost::alloc::string::String, } /// Specifies a requested range of bytes to download. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, Copy, PartialEq, ::prost::Message)] pub struct ContentRange { /// The starting offset of the object data. This value is inclusive. @@ -2133,7 +2056,6 @@ pub struct ContentRange { pub complete_length: i64, } /// Request message for DeleteNotificationConfig. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct DeleteNotificationConfigRequest { /// Required. The parent bucket of the NotificationConfig. @@ -2141,7 +2063,6 @@ pub struct DeleteNotificationConfigRequest { pub name: ::prost::alloc::string::String, } /// Request message for GetNotificationConfig. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct GetNotificationConfigRequest { /// Required. The parent bucket of the NotificationConfig. @@ -2151,7 +2072,6 @@ pub struct GetNotificationConfigRequest { pub name: ::prost::alloc::string::String, } /// Request message for CreateNotificationConfig. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct CreateNotificationConfigRequest { /// Required. The bucket to which this NotificationConfig belongs. @@ -2162,7 +2082,6 @@ pub struct CreateNotificationConfigRequest { pub notification_config: ::core::option::Option, } /// Request message for ListNotifications. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListNotificationConfigsRequest { /// Required. Name of a Google Cloud Storage bucket. @@ -2182,7 +2101,6 @@ pub struct ListNotificationConfigsRequest { pub page_token: ::prost::alloc::string::String, } /// The result of a call to ListNotificationConfigs -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct ListNotificationConfigsResponse { /// The list of items. @@ -2194,7 +2112,6 @@ pub struct ListNotificationConfigsResponse { pub next_page_token: ::prost::alloc::string::String, } /// A directive to publish Pub/Sub notifications upon changes to a bucket. -#[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct NotificationConfig { /// Required. The resource name of this NotificationConfig. @@ -2231,7 +2148,13 @@ pub struct NotificationConfig { } /// Generated client implementations. pub mod storage_client { - #![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)] + #![allow( + unused_variables, + dead_code, + missing_docs, + clippy::wildcard_imports, + clippy::let_unit_value + )] use tonic::codegen::http::Uri; use tonic::codegen::*; /// ## API Overview and Naming Syntax @@ -2274,8 +2197,8 @@ pub mod storage_client { where T: tonic::client::GrpcService, T::Error: Into, - T::ResponseBody: Body + Send + 'static, - ::Error: Into + Send, + T::ResponseBody: Body + std::marker::Send + 'static, + ::Error: Into + std::marker::Send, { pub fn new(inner: T) -> Self { let inner = tonic::client::Grpc::new(inner); @@ -2293,7 +2216,8 @@ pub mod storage_client { http::Request, Response = http::Response<>::ResponseBody>, >, - >>::Error: Into + Send + Sync, + >>::Error: + Into + std::marker::Send + std::marker::Sync, { StorageClient::new(InterceptedService::new(inner, interceptor)) } @@ -2333,9 +2257,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/DeleteBucket"); let mut req = request.into_request(); @@ -2348,9 +2273,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/GetBucket"); let mut req = request.into_request(); @@ -2363,9 +2289,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/CreateBucket"); let mut req = request.into_request(); @@ -2378,9 +2305,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/ListBuckets"); let mut req = request.into_request(); @@ -2393,9 +2321,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/LockBucketRetentionPolicy"); let mut req = request.into_request(); @@ -2410,9 +2339,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/GetIamPolicy"); let mut req = request.into_request(); @@ -2427,9 +2357,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/SetIamPolicy"); let mut req = request.into_request(); @@ -2449,9 +2380,10 @@ pub mod storage_client { request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/TestIamPermissions"); let mut req = request.into_request(); @@ -2464,9 +2396,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/UpdateBucket"); let mut req = request.into_request(); @@ -2480,9 +2413,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/ComposeObject"); let mut req = request.into_request(); @@ -2500,9 +2434,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/DeleteObject"); let mut req = request.into_request(); @@ -2515,9 +2450,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/RestoreObject"); let mut req = request.into_request(); @@ -2537,9 +2473,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/CancelResumableWrite"); let mut req = request.into_request(); @@ -2552,9 +2489,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/GetObject"); let mut req = request.into_request(); @@ -2568,9 +2506,10 @@ pub mod storage_client { request: impl tonic::IntoRequest, ) -> std::result::Result>, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/ReadObject"); let mut req = request.into_request(); @@ -2584,9 +2523,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/UpdateObject"); let mut req = request.into_request(); @@ -2657,9 +2597,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoStreamingRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/WriteObject"); let mut req = request.into_streaming_request(); @@ -2687,9 +2628,10 @@ pub mod storage_client { request: impl tonic::IntoStreamingRequest, ) -> std::result::Result>, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/BidiWriteObject"); let mut req = request.into_streaming_request(); @@ -2702,9 +2644,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/ListObjects"); let mut req = request.into_request(); @@ -2718,9 +2661,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/RewriteObject"); let mut req = request.into_request(); @@ -2735,9 +2679,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/StartResumableWrite"); let mut req = request.into_request(); @@ -2762,9 +2707,10 @@ pub mod storage_client { &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/QueryWriteStatus"); let mut req = request.into_request(); @@ -2773,13 +2719,15 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Retrieves the name of a project's Google Cloud Storage service account. + #[deprecated] pub async fn get_service_account( &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/GetServiceAccount"); let mut req = request.into_request(); @@ -2788,13 +2736,15 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Creates a new HMAC key for the given service account. + #[deprecated] pub async fn create_hmac_key( &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/CreateHmacKey"); let mut req = request.into_request(); @@ -2803,13 +2753,15 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Deletes a given HMAC key. Key must be in an INACTIVE state. + #[deprecated] pub async fn delete_hmac_key( &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/DeleteHmacKey"); let mut req = request.into_request(); @@ -2818,13 +2770,15 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Gets an existing HMAC key metadata for the given id. + #[deprecated] pub async fn get_hmac_key( &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/GetHmacKey"); let mut req = request.into_request(); @@ -2833,13 +2787,15 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Lists HMAC keys under a given project with the additional filters provided. + #[deprecated] pub async fn list_hmac_keys( &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/ListHmacKeys"); let mut req = request.into_request(); @@ -2848,13 +2804,15 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Updates a given HMAC key state between ACTIVE and INACTIVE. + #[deprecated] pub async fn update_hmac_key( &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/UpdateHmacKey"); let mut req = request.into_request(); @@ -2863,13 +2821,15 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Permanently deletes a NotificationConfig. + #[deprecated] pub async fn delete_notification_config( &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/DeleteNotificationConfig"); let mut req = request.into_request(); @@ -2878,13 +2838,15 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// View a NotificationConfig. + #[deprecated] pub async fn get_notification_config( &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/GetNotificationConfig"); let mut req = request.into_request(); @@ -2896,13 +2858,15 @@ pub mod storage_client { /// These NotificationConfigs, when triggered, publish messages to the /// specified Pub/Sub topics. See /// https://cloud.google.com/storage/docs/pubsub-notifications. + #[deprecated] pub async fn create_notification_config( &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/CreateNotificationConfig"); let mut req = request.into_request(); @@ -2911,13 +2875,15 @@ pub mod storage_client { self.inner.unary(req, path, codec).await } /// Retrieves a list of NotificationConfigs for a given bucket. + #[deprecated] pub async fn list_notification_configs( &mut self, request: impl tonic::IntoRequest, ) -> std::result::Result, tonic::Status> { - self.inner.ready().await.map_err(|e| { - tonic::Status::new(tonic::Code::Unknown, format!("Service was not ready: {}", e.into())) - })?; + self.inner + .ready() + .await + .map_err(|e| tonic::Status::unknown(format!("Service was not ready: {}", e.into())))?; let codec = tonic::codec::ProstCodec::default(); let path = http::uri::PathAndQuery::from_static("/google.storage.v2.Storage/ListNotificationConfigs"); let mut req = request.into_request(); diff --git a/googleapis/src/lib.rs b/googleapis/src/lib.rs index e28842b1..b0470208 100644 --- a/googleapis/src/lib.rs +++ b/googleapis/src/lib.rs @@ -1,5 +1,8 @@ #![allow(clippy::doc_lazy_continuation)] +#[path = "google.api.rs"] +pub mod api; + #[path = "google.rpc.rs"] pub mod rpc; @@ -85,3 +88,10 @@ pub mod cloud { pub mod v1; } } + +#[cfg(feature = "monitoring")] +#[path = ""] +pub mod monitoring { + #[path = "google.monitoring.v3.rs"] + pub mod v3; +} diff --git a/monitoring/Cargo.toml b/monitoring/Cargo.toml new file mode 100644 index 00000000..51fa9772 --- /dev/null +++ b/monitoring/Cargo.toml @@ -0,0 +1,44 @@ +[package] +name = "google-cloud-monitoring" +version = "0.1.0" +authors = ["AndrĂ© Eriksson "] +edition = "2021" +repository = "https://github.com/yoshidan/google-cloud-rust/tree/main/monitoring" +keywords = ["gcp","monitoring","googleapis","google-cloud-rust"] +license = "MIT" +readme = "README.md" +description = "Google Cloud Platform monitoring client library." +documentation = "https://docs.rs/google-cloud-monitoring/latest/google_cloud_monitoring/" + +[dependencies] +tracing = "0.1" +prost-types = "0.13" +tokio = "1.32" +async-channel = "1.9" +async-stream = "0.3" +thiserror = "1.0" +tokio-util = "0.7" + +google-cloud-token = { version = "0.1.2", path = "../foundation/token" } +google-cloud-gax = { version = "0.19.2", path = "../foundation/gax" } +google-cloud-googleapis = { version = "0.16.0", path = "../googleapis", features = ["monitoring"]} + +google-cloud-auth = { optional = true, version = "0.17", path="../foundation/auth", default-features=false } + +[dev-dependencies] +tokio = { version="1.32", features=["rt-multi-thread"] } +rand = "0.8.5" +tracing-subscriber = "0.3" +serial_test = "3.1" +uuid = { version="1.4", features=["v4"] } +ctor = "0.1.26" +futures-util = "0.3" + +[features] +default = ["auth", "default-tls"] +default-tls = ["google-cloud-auth?/default-tls"] +rustls-tls = ["google-cloud-auth?/rustls-tls"] +external-account = ["google-cloud-auth?/external-account"] +trace = [] +bytes = ["google-cloud-googleapis/bytes"] +auth = ["google-cloud-auth"] diff --git a/monitoring/LICENSE b/monitoring/LICENSE new file mode 100644 index 00000000..bfa31cdf --- /dev/null +++ b/monitoring/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2024 AndrĂ© Eriksson + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/monitoring/README.md b/monitoring/README.md new file mode 100644 index 00000000..4684b26e --- /dev/null +++ b/monitoring/README.md @@ -0,0 +1,53 @@ +# google-cloud-monitoring + +Google Cloud Platform monitoring library. + +[![crates.io](https://img.shields.io/crates/v/google-cloud-monitoring.svg)](https://crates.io/crates/google-cloud-monitoring) + + +* [About Cloud Monitoring](https://cloud.google.com/monitoring/) +* [Cloud Monitoring API Documentation](https://cloud.google.com/monitoring/docs) + +## Installation + +```toml +[dependencies] +google-cloud-monitoring = "version" +``` + +## Quickstart + +### Authentication +There are two ways to create a client that is authenticated against the google cloud. + +#### Automatically + +The function `with_auth()` will try and read the credentials from a file specified in the environment variable `GOOGLE_APPLICATION_CREDENTIALS`, `GOOGLE_APPLICATION_CREDENTIALS_JSON` or +from a metadata server. + +This is also described in [google-cloud-auth](https://github.com/yoshidan/google-cloud-rust/blob/main/foundation/auth/README.md) + +```rust +use google_cloud_monitoring::client::{ClientConfig, Client}; + +async fn run() { + let config = ClientConfig::default().with_auth().await.unwrap(); + let client = Client::new(config).await.unwrap(); +} +``` + +### Manually + +When you can't use the `gcloud` authentication but you have a different way to get your credentials (e.g a different environment variable) +you can parse your own version of the 'credentials-file' and use it like that: + +```rust +use google_cloud_auth::credentials::CredentialsFile; +// or google_cloud_monitoring::client::google_cloud_auth::credentials::CredentialsFile +use google_cloud_monitoring::client::{ClientConfig, Client}; + +async fn run(cred: CredentialsFile) { + let config = ClientConfig::default().with_credentials(cred).await.unwrap(); + let client = Client::new(config).await.unwrap(); +} +``` diff --git a/monitoring/src/apiv1/conn_pool.rs b/monitoring/src/apiv1/conn_pool.rs new file mode 100644 index 00000000..fe9b985a --- /dev/null +++ b/monitoring/src/apiv1/conn_pool.rs @@ -0,0 +1,37 @@ +use google_cloud_gax::conn::{Channel, Environment}; +use google_cloud_gax::conn::{ConnectionManager as GRPCConnectionManager, ConnectionOptions, Error}; + +pub const AUDIENCE: &str = "https://monitoring.googleapis.com/"; +pub const MONITORING: &str = "monitoring.googleapis.com"; +pub const SCOPES: [&str; 4] = [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/monitoring", + "https://www.googleapis.com/auth/monitoring.read", + "https://www.googleapis.com/auth/monitoring.write", +]; + +#[derive(Debug)] +pub struct ConnectionManager { + inner: GRPCConnectionManager, +} + +impl ConnectionManager { + pub async fn new( + pool_size: usize, + domain: &str, + environment: &Environment, + conn_options: &ConnectionOptions, + ) -> Result { + Ok(ConnectionManager { + inner: GRPCConnectionManager::new(pool_size, domain, AUDIENCE, environment, conn_options).await?, + }) + } + + pub fn num(&self) -> usize { + self.inner.num() + } + + pub fn conn(&self) -> Channel { + self.inner.conn() + } +} diff --git a/monitoring/src/apiv1/metric_service_client.rs b/monitoring/src/apiv1/metric_service_client.rs new file mode 100644 index 00000000..d62522f8 --- /dev/null +++ b/monitoring/src/apiv1/metric_service_client.rs @@ -0,0 +1,47 @@ +use std::sync::Arc; + +use google_cloud_gax::conn::Channel; +use google_cloud_gax::create_request; +use google_cloud_gax::grpc::Response; +use google_cloud_gax::grpc::Status; +use google_cloud_gax::retry::{invoke, MapErr, RetrySetting}; +use google_cloud_googleapis::monitoring::v3::metric_service_client::MetricServiceClient as InternalMetricServiceClient; +use google_cloud_googleapis::monitoring::v3::CreateTimeSeriesRequest; + +use crate::apiv1::conn_pool::ConnectionManager; + +#[derive(Clone, Debug)] +pub(crate) struct MetricServiceClient { + cm: Arc, +} + +#[allow(dead_code)] +impl MetricServiceClient { + /// create new metric client + pub fn new(cm: ConnectionManager) -> Self { + Self { cm: Arc::new(cm) } + } + + #[inline] + fn client(&self) -> InternalMetricServiceClient { + InternalMetricServiceClient::new(self.cm.conn()) + } + + /// create_time_series creates or adds data to one or more time series. + /// If any time series could not be written, a corresponding failure message is + /// included in the error response. + #[cfg_attr(feature = "trace", tracing::instrument(skip_all))] + pub async fn create_time_series( + &self, + req: CreateTimeSeriesRequest, + retry: Option, + ) -> Result, Status> { + let name = &req.name; + let action = || async { + let mut client = self.client(); + let request = create_request(format!("name={name}"), req.clone()); + client.create_time_series(request).await.map_transient_err() + }; + invoke(retry, action).await + } +} diff --git a/monitoring/src/apiv1/mod.rs b/monitoring/src/apiv1/mod.rs new file mode 100644 index 00000000..bdd0068e --- /dev/null +++ b/monitoring/src/apiv1/mod.rs @@ -0,0 +1,13 @@ +use google_cloud_gax::grpc::Code; +use google_cloud_gax::retry::RetrySetting; + +pub mod conn_pool; +pub mod metric_service_client; + +pub fn default_retry_setting() -> RetrySetting { + let mut setting = RetrySetting::default(); + setting.codes.push(Code::DeadlineExceeded); + setting.codes.push(Code::Internal); + setting.codes.push(Code::ResourceExhausted); + setting +} diff --git a/monitoring/src/client.rs b/monitoring/src/client.rs new file mode 100644 index 00000000..6f4c3ba0 --- /dev/null +++ b/monitoring/src/client.rs @@ -0,0 +1,129 @@ +use google_cloud_gax::conn::{ConnectionOptions, Environment}; +use google_cloud_gax::grpc::Status; +use google_cloud_gax::retry::RetrySetting; +use google_cloud_googleapis::monitoring::v3::{CreateTimeSeriesRequest, TimeSeries}; +use google_cloud_token::NopeTokenSourceProvider; + +use crate::apiv1::conn_pool::{ConnectionManager, MONITORING}; +use crate::apiv1::metric_service_client::MetricServiceClient; + +#[derive(Debug)] +pub struct ClientConfig { + /// gRPC channel pool size + pub pool_size: Option, + /// Monitoring project_id + pub project_id: Option, + /// Runtime project info + pub environment: Environment, + /// Overriding service endpoint + pub endpoint: String, + /// gRPC connection option + pub connection_option: ConnectionOptions, +} + +impl Default for ClientConfig { + fn default() -> Self { + Self { + pool_size: Some(4), + environment: Environment::GoogleCloud(Box::new(NopeTokenSourceProvider {})), + project_id: None, + endpoint: MONITORING.to_string(), + connection_option: ConnectionOptions::default(), + } + } +} + +#[cfg(feature = "auth")] +pub use google_cloud_auth; + +#[cfg(feature = "auth")] +impl ClientConfig { + pub async fn with_auth(mut self) -> Result { + if let Environment::GoogleCloud(_) = self.environment { + let ts = google_cloud_auth::token::DefaultTokenSourceProvider::new(Self::auth_config()).await?; + self.project_id = self.project_id.or(ts.project_id.clone()); + self.environment = Environment::GoogleCloud(Box::new(ts)) + } + Ok(self) + } + + pub async fn with_credentials( + mut self, + credentials: google_cloud_auth::credentials::CredentialsFile, + ) -> Result { + if let Environment::GoogleCloud(_) = self.environment { + let ts = google_cloud_auth::token::DefaultTokenSourceProvider::new_with_credentials( + Self::auth_config(), + Box::new(credentials), + ) + .await?; + self.project_id = self.project_id.or(ts.project_id.clone()); + self.environment = Environment::GoogleCloud(Box::new(ts)) + } + Ok(self) + } + + fn auth_config() -> google_cloud_auth::project::Config<'static> { + google_cloud_auth::project::Config::default() + .with_audience(crate::apiv1::conn_pool::AUDIENCE) + .with_scopes(&crate::apiv1::conn_pool::SCOPES) + } +} + +#[derive(thiserror::Error, Debug)] +pub enum Error { + #[error(transparent)] + GAX(#[from] google_cloud_gax::conn::Error), + #[error("Project ID was not found")] + ProjectIdNotFound, +} + +/// Client is a Google Cloud Monitoring client scoped to a single project. +/// +/// Clients should be reused rather than being created as needed. +/// A Client may be shared by multiple tasks. +#[derive(Clone, Debug)] +pub struct Client { + project_id: String, + msc: MetricServiceClient, +} + +impl Client { + /// new creates a monitoring client. See [`ClientConfig`] for more information. + pub async fn new(config: ClientConfig) -> Result { + let pool_size = config.pool_size.unwrap_or_default(); + + let msc = MetricServiceClient::new( + ConnectionManager::new( + pool_size, + config.endpoint.as_str(), + &config.environment, + &config.connection_option, + ) + .await?, + ); + Ok(Self { + project_id: config.project_id.ok_or(Error::ProjectIdNotFound)?, + msc, + }) + } + + /// create_time_series creates or adds data to one or more time series. + /// If any time series could not be written, a corresponding failure message is + /// included in the error response. + pub async fn create_time_series( + &self, + time_series: Vec, + retry: Option, + ) -> Result<(), Status> { + let req = CreateTimeSeriesRequest { + name: self.fully_qualified_project_name(), + time_series, + }; + self.msc.create_time_series(req, retry).await.map(|_| ()) + } + + fn fully_qualified_project_name(&self) -> String { + format!("projects/{}", self.project_id) + } +} diff --git a/monitoring/src/lib.rs b/monitoring/src/lib.rs new file mode 100644 index 00000000..1237d1f6 --- /dev/null +++ b/monitoring/src/lib.rs @@ -0,0 +1,46 @@ +//! # google-cloud-monitoring +//! +//! Google Cloud Platform monitoring library. +//! +//! * [About Cloud Monitoring](https://cloud.google.com/monitoring/) +//! * [Cloud Monitoring API Documentation](https://cloud.google.com/monitoring/docs) +//! +//! ## Quickstart +//! +//! ### Authentication +//! There are two ways to create a client that is authenticated against the google cloud. +//! +//! #### Automatically +//! +//! The function `with_auth()` will try and read the credentials from a file specified in the environment variable `GOOGLE_APPLICATION_CREDENTIALS`, `GOOGLE_APPLICATION_CREDENTIALS_JSON` or +//! from a metadata server. +//! +//! This is also described in [google-cloud-auth](https://github.com/yoshidan/google-cloud-rust/blob/main/foundation/auth/README.md) +//! +//! ```rust +//! use google_cloud_monitoring::client::{ClientConfig, Client}; +//! +//! async fn run() { +//! let config = ClientConfig::default().with_auth().await.unwrap(); +//! let client = Client::new(config).await.unwrap(); +//! } +//! ``` +//! +//! ### Manually +//! +//! When you cant use the `gcloud` authentication but you have a different way to get your credentials (e.g a different environment variable) +//! you can parse your own version of the 'credentials-file' and use it like that: +//! +//! ```rust +//! use google_cloud_auth::credentials::CredentialsFile; +//! // or google_cloud_monitoring::client::google_cloud_auth::credentials::CredentialsFile +//! use google_cloud_monitoring::client::{ClientConfig, Client}; +//! +//! async fn run(cred: CredentialsFile) { +//! let config = ClientConfig::default().with_credentials(cred).await.unwrap(); +//! let client = Client::new(config).await.unwrap(); +//! } +//! ``` +//! +pub mod apiv1; +pub mod client;