pub struct DiskWatcherConfig {
pub recursive_mode: Option<DiskWatcherRecursiveMode>,
pub poll_interval: Option<Duration>,
pub report_invalidation_reason: bool,
}Fields§
§recursive_mode: Option<DiskWatcherRecursiveMode>Whether to let the [notify::Watcher] recurse into subdirectories itself, or to track and
watch each directory we care about ourselves.
None picks a default based on the platform and Self::poll_interval, which is
normally what you want.
The TURBO_TASKS_FORCE_WATCH_MODE environment variable will override this configuration
value (intended for debugging purposes).
poll_interval: Option<Duration>Poll the filesystem at this interval instead of using the platform’s native file watching, for cases where native watching doesn’t work (e.g. some Docker setups). This is slow and inefficient, it should only be used as a last resort.
None disables polling, using the platform’s native watcher ([RecommendedWatcher])
instead of [PollWatcher].
report_invalidation_reason: boolAttach an [InvalidationReason] to every invalidation the watcher causes ([WatchStart],
[WatchChange], or [InvalidateRescan]), so that it can be reported to the user.
This costs an extra allocation per invalidated path, so it’s only worth enabling when something actually consumes the reasons.
Trait Implementations§
Source§impl<'__de, __Context> BorrowDecode<'__de, __Context> for DiskWatcherConfig
impl<'__de, __Context> BorrowDecode<'__de, __Context> for DiskWatcherConfig
Source§fn borrow_decode<__D: BorrowDecoder<'__de, Context = __Context>>(
decoder: &mut __D,
) -> Result<Self, DecodeError>
fn borrow_decode<__D: BorrowDecoder<'__de, Context = __Context>>( decoder: &mut __D, ) -> Result<Self, DecodeError>
Source§impl Clone for DiskWatcherConfig
impl Clone for DiskWatcherConfig
Source§fn clone(&self) -> DiskWatcherConfig
fn clone(&self) -> DiskWatcherConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for DiskWatcherConfig
Source§impl Debug for DiskWatcherConfig
impl Debug for DiskWatcherConfig
Source§impl<__Context> Decode<__Context> for DiskWatcherConfig
impl<__Context> Decode<__Context> for DiskWatcherConfig
Source§impl Default for DiskWatcherConfig
impl Default for DiskWatcherConfig
Source§fn default() -> DiskWatcherConfig
fn default() -> DiskWatcherConfig
Source§impl Encode for DiskWatcherConfig
impl Encode for DiskWatcherConfig
impl Eq for DiskWatcherConfig
Source§impl Hash for DiskWatcherConfig
impl Hash for DiskWatcherConfig
impl NonLocalValue for DiskWatcherConfig
Source§impl PartialEq for DiskWatcherConfig
impl PartialEq for DiskWatcherConfig
impl StructuralPartialEq for DiskWatcherConfig
Source§impl TaskInput for DiskWatcherConfig
impl TaskInput for DiskWatcherConfig
Source§fn is_transient(&self) -> bool
fn is_transient(&self) -> bool
Vc] (or any subtype of [Vc]) pointing
to a cell owned by a transient task. Read more§fn resolve_input(&self) -> impl Future<Output = Result<Self, Error>> + Send
fn resolve_input(&self) -> impl Future<Output = Result<Self, Error>> + Send
Vc]s nested inside of this object, cloning the object in
the process. If the input is unresolved ([TaskInput::is_resolved]) a “local” resolution
task is created that runs this method.§fn is_resolved(&self) -> bool
fn is_resolved(&self) -> bool
Source§impl TraceRawVcs for DiskWatcherConfig
impl TraceRawVcs for DiskWatcherConfig
fn trace_raw_vcs(&self, __context__: &mut TraceRawVcsContext)
fn get_raw_vcs(&self) -> Vec<RawVc>
Auto Trait Implementations§
impl Freeze for DiskWatcherConfig
impl RefUnwindSafe for DiskWatcherConfig
impl Send for DiskWatcherConfig
impl Sync for DiskWatcherConfig
impl Unpin for DiskWatcherConfig
impl UnsafeUnpin for DiskWatcherConfig
impl UnwindSafe for DiskWatcherConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DynEq for T
§impl<T> DynPartialEq for T
impl<T> DynPartialEq for T
fn dyn_partial_eq(&self, other: &(dyn Any + 'static)) -> bool
§impl<T> DynTaskInputs for T
impl<T> DynTaskInputs for T
fn dyn_type_name(&self) -> &'static str
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
impl<T> ErasedDestructor for Twhere
T: 'static,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more