Crate cooklang_sync_client

Source

Modules§

chunker
connection
errors
file_watcher
indexer
models
registry
remote
schema
syncer

Functions§

extract_uid_from_jwt
run
Synchronous alias to async run function. Intended to used by external (written in other languages) callers.
run_async
Runs local files watch and sync from/to remote continuously.
run_download_once
Runs one-off download of updates from remote server. Note, it’s not very efficient as requires to re-initialize DB connection, chunker, remote client, etc every time it runs.
run_upload_once
Runs one-off upload of updates to remote server. Note, it’s not very efficient as requires to re-initialize DB connection, chunker, remote client, etc every time it runs.
wait_remote_update
Connects to the server and waits either when wait_time expires or when there’s a remote update for this client. Note, it doesn’t do the update itself, you need to use run_download_once after this function completes.