pub struct ServiceBoundary {
pub name: String,
pub workspace_id: Uuid,
pub base_path: String,
pub reality_level: ServiceRealityLevel,
pub config: HashMap<String, Value>,
pub dependencies: Vec<String>,
}Expand description
Service boundary definition
Defines a service in the federation, including its workspace mapping, base path, and reality level configuration.
Fields§
§name: StringService name
workspace_id: UuidWorkspace ID this service maps to
base_path: StringBase path for this service (e.g., “/auth”, “/payments”)
reality_level: ServiceRealityLevelReality level for this service
config: HashMap<String, Value>Service-specific configuration
dependencies: Vec<String>Inter-service dependencies
Implementations§
Source§impl ServiceBoundary
impl ServiceBoundary
Sourcepub fn new(
name: String,
workspace_id: Uuid,
base_path: String,
reality_level: ServiceRealityLevel,
) -> Self
pub fn new( name: String, workspace_id: Uuid, base_path: String, reality_level: ServiceRealityLevel, ) -> Self
Create a new service boundary
Sourcepub fn matches_path(&self, path: &str) -> bool
pub fn matches_path(&self, path: &str) -> bool
Check if a path matches this service
Sourcepub fn extract_service_path(&self, full_path: &str) -> Option<String>
pub fn extract_service_path(&self, full_path: &str) -> Option<String>
Extract service-specific path from full path
Trait Implementations§
Source§impl Clone for ServiceBoundary
impl Clone for ServiceBoundary
Source§fn clone(&self) -> ServiceBoundary
fn clone(&self) -> ServiceBoundary
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 ServiceBoundary
impl Debug for ServiceBoundary
Source§impl<'de> Deserialize<'de> for ServiceBoundary
impl<'de> Deserialize<'de> for ServiceBoundary
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
Auto Trait Implementations§
impl Freeze for ServiceBoundary
impl RefUnwindSafe for ServiceBoundary
impl Send for ServiceBoundary
impl Sync for ServiceBoundary
impl Unpin for ServiceBoundary
impl UnsafeUnpin for ServiceBoundary
impl UnwindSafe for ServiceBoundary
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
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>
Converts
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>
Converts
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