pub struct GatewayConfigSpec {
pub enabled: bool,
pub routes: Vec<GatewayRoute>,
pub catalog: Option<GatewayCatalogSource>,
pub auth_scheme: String,
pub inference_path_prefix: String,
}Expand description
On-disk gateway configuration: the exact shape accepted under
gateway: in a profile YAML document.
Produced by serde deserialization; never holds a loaded catalog.
Project to the runtime GatewayConfig via Self::resolve once a
profile_dir is available.
Fields§
§enabled: bool§routes: Vec<GatewayRoute>§catalog: Option<GatewayCatalogSource>§auth_scheme: String§inference_path_prefix: StringImplementations§
Source§impl GatewayConfigSpec
impl GatewayConfigSpec
Sourcepub fn resolve(self, profile_dir: &Path) -> GatewayResult<GatewayConfig>
pub fn resolve(self, profile_dir: &Path) -> GatewayResult<GatewayConfig>
Project the on-disk spec to the runtime GatewayConfig by reading
and validating any external catalog file referenced by
GatewayCatalogSource::Path.
Trait Implementations§
Source§impl Clone for GatewayConfigSpec
impl Clone for GatewayConfigSpec
Source§fn clone(&self) -> GatewayConfigSpec
fn clone(&self) -> GatewayConfigSpec
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 GatewayConfigSpec
impl Debug for GatewayConfigSpec
Source§impl Default for GatewayConfigSpec
impl Default for GatewayConfigSpec
Source§impl<'de> Deserialize<'de> for GatewayConfigSpec
impl<'de> Deserialize<'de> for GatewayConfigSpec
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl JsonSchema for GatewayConfigSpec
impl JsonSchema for GatewayConfigSpec
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreAuto Trait Implementations§
impl Freeze for GatewayConfigSpec
impl RefUnwindSafe for GatewayConfigSpec
impl Send for GatewayConfigSpec
impl Sync for GatewayConfigSpec
impl Unpin for GatewayConfigSpec
impl UnsafeUnpin for GatewayConfigSpec
impl UnwindSafe for GatewayConfigSpec
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