-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add query cancellation, remove async process
- Loading branch information
Michael Ionov
committed
May 25, 2024
1 parent
5fcd686
commit 0a60dd8
Showing
24 changed files
with
437 additions
and
306 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,4 @@ | ||
pub mod connections; | ||
pub mod queries; | ||
pub mod task; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
use tauri::AppHandle; | ||
use tracing::info; | ||
|
||
use crate::{ | ||
state::ServiceAccess, | ||
utils::error::{CommandResult, Error}, | ||
}; | ||
|
||
#[tauri::command] | ||
pub async fn cancel_task_token(app_handle: AppHandle, ids: Vec<String>) -> CommandResult<()> { | ||
info!(?ids, "Cancelling task token"); | ||
for id in ids.iter() { | ||
app_handle | ||
.cancel_token(id.clone()) | ||
.await | ||
.map_err(Error::from)?; | ||
} | ||
Ok(()) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
pub mod state; | ||
pub mod database; | ||
pub mod utils; | ||
pub mod engine; | ||
pub mod handlers; | ||
pub mod query; | ||
pub mod queues; | ||
pub mod engine; | ||
pub mod state; | ||
pub mod utils; |
Oops, something went wrong.