#[non_exhaustive]pub struct RuntimeConfig {
pub version: String,
pub container_image: String,
pub properties: HashMap<String, String>,
pub repository_config: Option<RepositoryConfig>,
pub autotuning_config: Option<AutotuningConfig>,
pub cohort: String,
/* private fields */
}Expand description
Runtime configuration for a workload.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.version: StringOptional. Version of the batch runtime.
container_image: StringOptional. Optional custom container image for the job runtime environment. If not specified, a default container image will be used.
properties: HashMap<String, String>Optional. A mapping of property names to values, which are used to configure workload execution.
repository_config: Option<RepositoryConfig>Optional. Dependency repository configuration.
autotuning_config: Option<AutotuningConfig>Optional. Autotuning configuration of the workload.
cohort: StringOptional. Cohort identifier. Identifies families of the workloads having the same shape, e.g. daily ETL jobs.
Implementations§
Source§impl RuntimeConfig
impl RuntimeConfig
pub fn new() -> Self
Sourcepub fn set_version<T: Into<String>>(self, v: T) -> Self
pub fn set_version<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_container_image<T: Into<String>>(self, v: T) -> Self
pub fn set_container_image<T: Into<String>>(self, v: T) -> Self
Sets the value of container_image.
§Example
ⓘ
let x = RuntimeConfig::new().set_container_image("example");Sourcepub fn set_properties<T, K, V>(self, v: T) -> Self
pub fn set_properties<T, K, V>(self, v: T) -> Self
Sets the value of properties.
§Example
ⓘ
let x = RuntimeConfig::new().set_properties([
("key0", "abc"),
("key1", "xyz"),
]);Sourcepub fn set_repository_config<T>(self, v: T) -> Selfwhere
T: Into<RepositoryConfig>,
pub fn set_repository_config<T>(self, v: T) -> Selfwhere
T: Into<RepositoryConfig>,
Sets the value of repository_config.
§Example
ⓘ
use google_cloud_dataproc_v1::model::RepositoryConfig;
let x = RuntimeConfig::new().set_repository_config(RepositoryConfig::default()/* use setters */);Sourcepub fn set_or_clear_repository_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<RepositoryConfig>,
pub fn set_or_clear_repository_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<RepositoryConfig>,
Sets or clears the value of repository_config.
§Example
ⓘ
use google_cloud_dataproc_v1::model::RepositoryConfig;
let x = RuntimeConfig::new().set_or_clear_repository_config(Some(RepositoryConfig::default()/* use setters */));
let x = RuntimeConfig::new().set_or_clear_repository_config(None::<RepositoryConfig>);Sourcepub fn set_autotuning_config<T>(self, v: T) -> Selfwhere
T: Into<AutotuningConfig>,
pub fn set_autotuning_config<T>(self, v: T) -> Selfwhere
T: Into<AutotuningConfig>,
Sets the value of autotuning_config.
§Example
ⓘ
use google_cloud_dataproc_v1::model::AutotuningConfig;
let x = RuntimeConfig::new().set_autotuning_config(AutotuningConfig::default()/* use setters */);Sourcepub fn set_or_clear_autotuning_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<AutotuningConfig>,
pub fn set_or_clear_autotuning_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<AutotuningConfig>,
Sets or clears the value of autotuning_config.
§Example
ⓘ
use google_cloud_dataproc_v1::model::AutotuningConfig;
let x = RuntimeConfig::new().set_or_clear_autotuning_config(Some(AutotuningConfig::default()/* use setters */));
let x = RuntimeConfig::new().set_or_clear_autotuning_config(None::<AutotuningConfig>);Trait Implementations§
Source§impl Clone for RuntimeConfig
impl Clone for RuntimeConfig
Source§fn clone(&self) -> RuntimeConfig
fn clone(&self) -> RuntimeConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RuntimeConfig
impl Debug for RuntimeConfig
Source§impl Default for RuntimeConfig
impl Default for RuntimeConfig
Source§fn default() -> RuntimeConfig
fn default() -> RuntimeConfig
Returns the “default value” for a type. Read more
Source§impl Message for RuntimeConfig
impl Message for RuntimeConfig
Source§impl PartialEq for RuntimeConfig
impl PartialEq for RuntimeConfig
impl StructuralPartialEq for RuntimeConfig
Auto Trait Implementations§
impl Freeze for RuntimeConfig
impl RefUnwindSafe for RuntimeConfig
impl Send for RuntimeConfig
impl Sync for RuntimeConfig
impl Unpin for RuntimeConfig
impl UnwindSafe for RuntimeConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more