pub struct ServiceIdentity {
pub service_id: String,
pub name: String,
pub service_type: ServiceType,
pub tenant_id: TenantId,
pub cert_fingerprint: Option<String>,
pub environment: Environment,
pub created_at: DateTime<Utc>,
}Expand description
Service identity
Fields§
§service_id: StringService ID
name: StringService name
service_type: ServiceTypeService type
tenant_id: TenantIdTenant ID
cert_fingerprint: Option<String>Certificate fingerprint (for mTLS)
environment: EnvironmentEnvironment
created_at: DateTime<Utc>Created at
Implementations§
Source§impl ServiceIdentity
impl ServiceIdentity
Sourcepub fn new(
name: String,
service_type: ServiceType,
tenant_id: TenantId,
environment: Environment,
) -> Self
pub fn new( name: String, service_type: ServiceType, tenant_id: TenantId, environment: Environment, ) -> Self
Create new service identity
Sourcepub fn with_cert_fingerprint(self, fingerprint: String) -> Self
pub fn with_cert_fingerprint(self, fingerprint: String) -> Self
Set certificate fingerprint
Sourcepub fn identity_hash(&self) -> String
pub fn identity_hash(&self) -> String
Calculate identity hash (for verification)
Trait Implementations§
Source§impl Clone for ServiceIdentity
impl Clone for ServiceIdentity
Source§fn clone(&self) -> ServiceIdentity
fn clone(&self) -> ServiceIdentity
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 ServiceIdentity
impl Debug for ServiceIdentity
Source§impl<'de> Deserialize<'de> for ServiceIdentity
impl<'de> Deserialize<'de> for ServiceIdentity
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
impl Eq for ServiceIdentity
Source§impl Hash for ServiceIdentity
impl Hash for ServiceIdentity
Source§impl PartialEq for ServiceIdentity
impl PartialEq for ServiceIdentity
Source§fn eq(&self, other: &ServiceIdentity) -> bool
fn eq(&self, other: &ServiceIdentity) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for ServiceIdentity
impl Serialize for ServiceIdentity
impl StructuralPartialEq for ServiceIdentity
Auto Trait Implementations§
impl Freeze for ServiceIdentity
impl RefUnwindSafe for ServiceIdentity
impl Send for ServiceIdentity
impl Sync for ServiceIdentity
impl Unpin for ServiceIdentity
impl UnsafeUnpin for ServiceIdentity
impl UnwindSafe for ServiceIdentity
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