Paul Campbell
fd762e2bd2
All checks were successful
Rust / build (push) Successful in 1m50s
ci/woodpecker/push/cron-docker-builder Pipeline was successful
ci/woodpecker/push/push-next Pipeline was successful
ci/woodpecker/push/tag-created Pipeline was successful
ci/woodpecker/cron/cron-docker-builder Pipeline was successful
ci/woodpecker/cron/push-next Pipeline was successful
ci/woodpecker/cron/tag-created Pipeline was successful
Closes kemitix/git-next#94 Controlled shutdown includes attempting to unregister webhooks.
23 lines
807 B
Rust
23 lines
807 B
Rust
//-
|
|
use derive_more::Constructor;
|
|
use git_next_actor_macros::message;
|
|
use git_next_config::server::{ServerConfig, ServerStorage};
|
|
use std::net::SocketAddr;
|
|
|
|
// receive server config
|
|
message!(ReceiveServerConfig: ServerConfig: "Notification of newly loaded server configuration.
|
|
|
|
This message will prompt the `git-next` server to stop and restart all repo-actors.
|
|
|
|
Contains the new server configuration.");
|
|
|
|
// receive valid server config
|
|
#[derive(Clone, Debug, PartialEq, Eq, Constructor)]
|
|
pub struct ValidServerConfig {
|
|
pub server_config: ServerConfig,
|
|
pub socket_address: SocketAddr,
|
|
pub server_storage: ServerStorage,
|
|
}
|
|
message!(ReceiveValidServerConfig: ValidServerConfig: "Notification of validated server configuration.");
|
|
|
|
message!(Shutdown: "Notification to shutdown the server actor");
|