pub struct ServerDef {
pub cluster: Option<ClusterDef>,
pub job_name: String,
pub task_index: i32,
pub default_session_config: Option<ConfigProto>,
pub protocol: String,
}
Expand description
Defines the configuration of a single TensorFlow server.
Fields§
§cluster: Option<ClusterDef>
The cluster of which this server is a member.
job_name: String
The name of the job of which this server is a member.
NOTE(mrry): The cluster
field must contain a JobDef
with a name
field
that matches this name.
task_index: i32
The task index of this server in its job.
NOTE: The cluster
field must contain a JobDef
with a matching name
and a mapping in its tasks
field for this index.
default_session_config: Option<ConfigProto>
The default configuration for sessions that run on this server.
protocol: String
The protocol to be used by this server.
Acceptable values include: “grpc”, “grpc+verbs”.
Trait Implementations§
Source§impl Message for ServerDef
impl Message for ServerDef
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
Source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Encodes the message to a buffer. Read more
Source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Encodes the message with a length-delimiter to a buffer. Read more
Source§fn decode<B>(buf: B) -> Result<Self, DecodeError>
fn decode<B>(buf: B) -> Result<Self, DecodeError>
Decodes an instance of the message from a buffer. Read more
Source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
Decodes a length-delimited instance of the message from the buffer.
Source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
Decodes an instance of the message from a buffer, and merges it into
self
. Read moreSource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
Decodes a length-delimited instance of the message from buffer, and
merges it into
self
.impl StructuralPartialEq for ServerDef
Auto Trait Implementations§
impl Freeze for ServerDef
impl RefUnwindSafe for ServerDef
impl Send for ServerDef
impl Sync for ServerDef
impl Unpin for ServerDef
impl UnwindSafe for ServerDef
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