pub trait ScanTrigger:
Send
+ Sync
+ 'static {
// Required method
fn trigger<'a>(
&'a self,
source: ScanTriggerSource,
project_id: Option<String>,
repo: Option<String>,
run_overrides: Option<ScanRunOverrides>,
) -> ScanFuture<'a>;
}Expand description
Plug that lets the API hand off a manual scan request to the daemon that owns the run dispatcher. The daemon wires the production impl; tests substitute a stub.
Required Methods§
Sourcefn trigger<'a>(
&'a self,
source: ScanTriggerSource,
project_id: Option<String>,
repo: Option<String>,
run_overrides: Option<ScanRunOverrides>,
) -> ScanFuture<'a>
fn trigger<'a>( &'a self, source: ScanTriggerSource, project_id: Option<String>, repo: Option<String>, run_overrides: Option<ScanRunOverrides>, ) -> ScanFuture<'a>
Kick off a scan. Returns the freshly minted run id.
sourcerecords the surface that requested the scan; the daemon stamps it ontoruns.triggered_by.project_id, when set, restricts the run to repos belonging to that project;repofurther narrows to a single repo. Passing both unset scans every enabled repo.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".