pub trait Service: Sync + Send {
// Required methods
fn name(&self) -> &'static str;
fn spawn<'async_trait>(
self: Arc<Self>,
runtime: Runtime,
) -> Pin<Box<dyn Future<Output = ServiceResult> + Send + 'async_trait>>
where Self: 'async_trait;
fn terminate(self: Arc<Self>);
fn join<'async_trait>(
self: Arc<Self>,
) -> Pin<Box<dyn Future<Output = ServiceResult> + Send + 'async_trait>>
where Self: 'async_trait;
}
Expand description
Service is a core component of the Kaspa NG application responsible for running application services and communication between these services.