pub trait VersionExt<PrivateCfg>:
Send
+ Sync
+ 'static
+ Clone {
type Response: IntoResponse;
// Required method
fn get_version(&self, cfg: &AppConfig<PrivateCfg>) -> Self::Response;
}Expand description
Trait to implement custom /version response
Required Associated Types§
Sourcetype Response: IntoResponse
type Response: IntoResponse
return type for health check
Required Methods§
Sourcefn get_version(&self, cfg: &AppConfig<PrivateCfg>) -> Self::Response
fn get_version(&self, cfg: &AppConfig<PrivateCfg>) -> Self::Response
returns Self::Response in response to configured endpoint. Default: /version.
For more information see crate::configuration::ManagementConfig
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.