pub struct Crawl<'a> { /* private fields */ }Expand description
/v1/crawl — the Dragnet whole-site crawl. One crawl fans a seed URL across
a bounded in-process worker pool; extracted pages aggregate under a synthetic
per-crawl workflow (CrawlJob::data_workflow_id) read back through the Data API.
Implementations§
Source§impl Crawl<'_>
impl Crawl<'_>
Sourcepub async fn start(&self, params: CrawlStartParams) -> Result<CrawlJob>
pub async fn start(&self, params: CrawlStartParams) -> Result<CrawlJob>
POST /v1/crawl — validate the seed, mint the synthetic dataset workflow +
the crawl row, and kick the crawl off. Returns the queued CrawlJob view
(with workflow_id/data_workflow_id set). An empty url is a 400
WritError::Api.
Sourcepub async fn get(&self, id: i64) -> Result<CrawlJob>
pub async fn get(&self, id: i64) -> Result<CrawlJob>
GET /v1/crawl/:id — one crawl’s live status view (404 if missing).
Sourcepub async fn cancel(&self, id: i64) -> Result<CrawlCancel>
pub async fn cancel(&self, id: i64) -> Result<CrawlCancel>
POST /v1/crawl/:id/cancel — request cancellation. Returns the refreshed
view plus CrawlCancel::cancel_requested_now (never a 409; 404 if
missing).
Trait Implementations§
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for Crawl<'a>
impl<'a> !UnwindSafe for Crawl<'a>
impl<'a> Freeze for Crawl<'a>
impl<'a> Send for Crawl<'a>
impl<'a> Sync for Crawl<'a>
impl<'a> Unpin for Crawl<'a>
impl<'a> UnsafeUnpin for Crawl<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more