This commit is contained in:
John Smith
2022-02-06 21:18:42 -05:00
parent d660d86884
commit 70960fa592
53 changed files with 2062 additions and 2316 deletions

View File

@@ -36,7 +36,10 @@ fn convert_update(
rpc_update: crate::veilid_client_capnp::veilid_update::Builder,
) {
match update {
veilid_core::VeilidUpdate::Log(_ll, _s) => {
veilid_core::VeilidUpdate::Log {
log_level: _,
message: _,
} => {
panic!("Should not be logging to api in server!");
}
veilid_core::VeilidUpdate::Attachment(state) => {

View File

@@ -24,9 +24,6 @@ pub fn shutdown() {
pub async fn run_veilid_server(settings: Settings, logs: VeilidLogs) -> Result<(), String> {
let settingsr = settings.read();
// Create Veilid Core
let veilid_core = veilid_core::VeilidCore::new();
// Create client api state change pipe
let (sender, receiver): (
Sender<veilid_core::VeilidUpdate>,
@@ -49,8 +46,7 @@ pub async fn run_veilid_server(settings: Settings, logs: VeilidLogs) -> Result<(
};
// Start Veilid Core and get API
let veilid_api = veilid_core
.startup(vcs)
let veilid_api = veilid_core::api_startup(vcs)
.await
.map_err(|e| format!("VeilidCore startup failed: {}", e))?;