()
| 776 | } |
| 777 | |
| 778 | fn runtime() -> anyhow::Result<tokio::runtime::Runtime> { |
| 779 | tokio::runtime::Builder::new_multi_thread() |
| 780 | .enable_all() |
| 781 | .build() |
| 782 | .context("failed to create database-owner runtime") |
| 783 | } |
| 784 | |
| 785 | /// Start the repository owner or reconnect when another process won election. |
| 786 | pub(crate) fn start_or_reconnect(repository: &Path) -> anyhow::Result<OwnerResponse> { |