#[non_exhaustive]pub struct HttpGetAction {
pub path: String,
pub port: i32,
pub host: String,
pub scheme: String,
pub http_headers: Vec<HttpHeader>,
/* private fields */
}Available on crate features
dataset-service or job-service or model-garden-service or model-service or pipeline-service only.Expand description
HttpGetAction describes an action based on HTTP Get requests.
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.path: StringPath to access on the HTTP server.
port: i32Number of the port to access on the container. Number must be in the range 1 to 65535.
host: StringHost name to connect to, defaults to the model serving container’s IP. You probably want to set “Host” in httpHeaders instead.
scheme: StringScheme to use for connecting to the host. Defaults to HTTP. Acceptable values are “HTTP” or “HTTPS”.
http_headers: Vec<HttpHeader>Custom headers to set in the request. HTTP allows repeated headers.
Implementations§
Source§impl HttpGetAction
impl HttpGetAction
pub fn new() -> Self
Sourcepub fn set_scheme<T: Into<String>>(self, v: T) -> Self
pub fn set_scheme<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_http_headers<T, V>(self, v: T) -> Self
pub fn set_http_headers<T, V>(self, v: T) -> Self
Sets the value of http_headers.
§Example
ⓘ
use google_cloud_aiplatform_v1::model::probe::HttpHeader;
let x = HttpGetAction::new()
.set_http_headers([
HttpHeader::default()/* use setters */,
HttpHeader::default()/* use (different) setters */,
]);Trait Implementations§
Source§impl Clone for HttpGetAction
impl Clone for HttpGetAction
Source§fn clone(&self) -> HttpGetAction
fn clone(&self) -> HttpGetAction
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 HttpGetAction
impl Debug for HttpGetAction
Source§impl Default for HttpGetAction
impl Default for HttpGetAction
Source§fn default() -> HttpGetAction
fn default() -> HttpGetAction
Returns the “default value” for a type. Read more
Source§impl Message for HttpGetAction
impl Message for HttpGetAction
Source§impl PartialEq for HttpGetAction
impl PartialEq for HttpGetAction
impl StructuralPartialEq for HttpGetAction
Auto Trait Implementations§
impl Freeze for HttpGetAction
impl RefUnwindSafe for HttpGetAction
impl Send for HttpGetAction
impl Sync for HttpGetAction
impl Unpin for HttpGetAction
impl UnwindSafe for HttpGetAction
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