pub struct OsSchedulerHintsBuilder<'a> { /* private fields */ }
Expand description
Builder for OsSchedulerHints
.
Implementations§
Source§impl<'a> OsSchedulerHintsBuilder<'a>
impl<'a> OsSchedulerHintsBuilder<'a>
Sourcepub fn build_near_host_ip<VALUE: Into<Cow<'a, str>>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn build_near_host_ip<VALUE: Into<Cow<'a, str>>>( &mut self, value: VALUE, ) -> &mut Self
Schedule the server on a host in the network specified with this
parameter and a cidr (os:scheduler_hints.cidr
). It is available when
SimpleCIDRAffinityFilter
is available on cloud side.
Sourcepub fn cidr<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self
pub fn cidr<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self
Schedule the server on a host in the network specified with an IP
address (os:scheduler_hints:build_near_host_ip
) and this parameter.
If os:scheduler_hints:build_near_host_ip
is specified and this
parameter is omitted, /24
is used. It is available when
SimpleCIDRAffinityFilter
is available on cloud side.
Sourcepub fn different_cell<VALUE: Into<Vec<Cow<'a, str>>>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn different_cell<VALUE: Into<Vec<Cow<'a, str>>>>( &mut self, value: VALUE, ) -> &mut Self
A list of cell routes or a cell route (string). Schedule the server in
a cell that is not specified. It is available when
DifferentCellFilter
is available on cloud side that is cell v1
environment.
Sourcepub fn different_host<VALUE: Into<Vec<Cow<'a, str>>>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn different_host<VALUE: Into<Vec<Cow<'a, str>>>>( &mut self, value: VALUE, ) -> &mut Self
A list of server UUIDs or a server UUID. Schedule the server on a
different host from a set of servers. It is available when
DifferentHostFilter
is available on cloud side.
Sourcepub fn group<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self
pub fn group<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self
The server group UUID. Schedule the server according to a policy of the
server group (anti-affinity
, affinity
, soft-anti-affinity
or
soft-affinity
). It is available when ServerGroupAffinityFilter
,
ServerGroupAntiAffinityFilter
, ServerGroupSoftAntiAffinityWeigher
,
ServerGroupSoftAffinityWeigher
are available on cloud side.
Sourcepub fn query<VALUE: Into<Value>>(&mut self, value: VALUE) -> &mut Self
pub fn query<VALUE: Into<Value>>(&mut self, value: VALUE) -> &mut Self
Schedule the server by using a custom filter in JSON format. For example:
"query": "[\">=\",\"$free_ram_mb\",1024]"
It is available when JsonFilter
is available on cloud side.
Sourcepub fn same_host<VALUE: Into<Vec<Cow<'a, str>>>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn same_host<VALUE: Into<Vec<Cow<'a, str>>>>( &mut self, value: VALUE, ) -> &mut Self
A list of server UUIDs or a server UUID. Schedule the server on the
same host as another server in a set of servers. It is available when
SameHostFilter
is available on cloud side.
Sourcepub fn target_cell<VALUE: Into<Cow<'a, str>>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn target_cell<VALUE: Into<Cow<'a, str>>>( &mut self, value: VALUE, ) -> &mut Self
A target cell name. Schedule the server in a host in the cell
specified. It is available when TargetCellFilter
is available on
cloud side that is cell v1 environment.
Sourcepub fn build(
&self,
) -> Result<OsSchedulerHints<'a>, OsSchedulerHintsBuilderError>
pub fn build( &self, ) -> Result<OsSchedulerHints<'a>, OsSchedulerHintsBuilderError>
Trait Implementations§
Source§impl<'a> Clone for OsSchedulerHintsBuilder<'a>
impl<'a> Clone for OsSchedulerHintsBuilder<'a>
Source§fn clone(&self) -> OsSchedulerHintsBuilder<'a>
fn clone(&self) -> OsSchedulerHintsBuilder<'a>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreAuto Trait Implementations§
impl<'a> Freeze for OsSchedulerHintsBuilder<'a>
impl<'a> RefUnwindSafe for OsSchedulerHintsBuilder<'a>
impl<'a> Send for OsSchedulerHintsBuilder<'a>
impl<'a> Sync for OsSchedulerHintsBuilder<'a>
impl<'a> Unpin for OsSchedulerHintsBuilder<'a>
impl<'a> UnwindSafe for OsSchedulerHintsBuilder<'a>
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more