Nix 2.26.3
Nix, the purely functional package manager; unstable internal interfaces
 
Loading...
Searching...
No Matches
nix::DrvOutputSubstitutionGoal Class Reference

#include <drv-output-substitution-goal.hh>

Inheritance diagram for nix::DrvOutputSubstitutionGoal:
nix::Goal

Public Types

typedef void(DrvOutputSubstitutionGoal::* GoalState) ()
 
- Public Types inherited from nix::Goal
enum  ExitCode {
  ecBusy , ecSuccess , ecFailed , ecNoSubstituters ,
  ecIncompleteClosure
}
 
using handle_type = std::coroutine_handle<promise_type>
 

Public Member Functions

 DrvOutputSubstitutionGoal (const DrvOutput &id, Worker &worker, RepairFlag repair=NoRepair, std::optional< ContentAddress > ca=std::nullopt)
 
Co init () override
 
Co realisationFetched (std::shared_ptr< const Realisation > outputInfo, nix::ref< nix::Store > sub)
 
void timedOut (Error &&ex) override
 
std::string key () override
 
void handleEOF (Descriptor fd) override
 
JobCategory jobCategory () const override
 Hint for the scheduler, which concurrency limit applies.
 
- Public Member Functions inherited from nix::Goal
Co init_wrapper ()
 
Done amDone (ExitCode result, std::optional< Error > ex={})
 
virtual void cleanup ()
 
BuildResult getBuildResult (const DerivedPath &) const
 
 Goal (Worker &worker, DerivedPath path)
 
void work ()
 
void addWaitee (GoalPtr waitee)
 
virtual void waiteeDone (GoalPtr waitee, ExitCode result)
 
virtual void handleChildOutput (Descriptor fd, std::string_view data)
 
void trace (std::string_view s)
 
std::string getName () const
 

Public Attributes

GoalState state
 
- Public Attributes inherited from nix::Goal
Workerworker
 
Goals waitees
 
WeakGoals waiters
 
size_t nrFailed = 0
 
size_t nrNoSubstituters = 0
 
size_t nrIncompleteClosure = 0
 
std::string name
 
ExitCode exitCode = ecBusy
 
std::optional< Cotop_co
 
std::optional< Error > ex
 

Additional Inherited Members

- Protected Attributes inherited from nix::Goal
BuildResult buildResult
 

Detailed Description

Substitution of a derivation output. This is done in three steps:

  1. Fetch the output info from a substituter
  2. Substitute the corresponding output path
  3. Register the output info

Member Function Documentation

◆ handleEOF()

void nix::DrvOutputSubstitutionGoal::handleEOF ( Descriptor fd)
overridevirtual

Reimplemented from nix::Goal.

◆ init()

Goal::Co nix::DrvOutputSubstitutionGoal::init ( )
overridevirtual

The entry point for the goal

Implements nix::Goal.

◆ jobCategory()

JobCategory nix::DrvOutputSubstitutionGoal::jobCategory ( ) const
inlineoverridevirtual

Hint for the scheduler, which concurrency limit applies.

See also
JobCategory

Implements nix::Goal.

◆ key()

std::string nix::DrvOutputSubstitutionGoal::key ( )
overridevirtual

Implements nix::Goal.

◆ timedOut()

void nix::DrvOutputSubstitutionGoal::timedOut ( Error && ex)
inlineoverridevirtual

Callback in case of a timeout. It should wake up its waiters, get rid of any running child processes that are being monitored by the worker (important!), etc.

Implements nix::Goal.


The documentation for this class was generated from the following files: