Package portage :: Package dbapi :: Module _MergeProcess :: Class MergeProcess
[hide private]

Class MergeProcess

source code

                           object --+                        
                                    |                        
           util.SlotObject.SlotObject --+                    
                                        |                    
_emerge.AsynchronousTask.AsynchronousTask --+                
                                            |                
    _emerge.AbstractPollTask.AbstractPollTask --+            
                                                |            
                    _emerge.SubProcess.SubProcess --+        
                                                    |        
                    _emerge.SpawnProcess.SpawnProcess --+    
                                                        |    
                      util._async.ForkProcess.ForkProcess --+
                                                            |
                                                           MergeProcess

Merge packages in a subprocess, so the Scheduler can run in the main thread while files are moved or copied asynchronously.

Instance Methods [hide private]
 
_start(self) source code
 
_lock_vdb(self)
Lock the vdb if FEATURES=parallel-install is NOT enabled, otherwise do nothing.
source code
 
_unlock_vdb(self)
Unlock the vdb if we hold a lock, otherwise do nothing.
source code
 
_elog_output_handler(self, fd, event) source code
 
_spawn(self, args, fd_pipes, **kwargs)
Fork a subprocess, apply local settings, and call dblink.merge().
source code
 
_unregister(self)
Unregister from the scheduler and close open files.
source code

Inherited from util._async.ForkProcess.ForkProcess (private): _run

Inherited from _emerge.SubProcess.SubProcess: isAlive

Inherited from _emerge.AsynchronousTask.AsynchronousTask: addExitListener, addStartListener, cancel, poll, removeExitListener, removeStartListener, start, wait

Inherited from util.SlotObject.SlotObject: __init__, copy

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
Properties [hide private]
  _buf
  _elog_keys
  _elog_reader_fd
  _elog_reg_id
  _locked_vdb
  blockers
  infloc
  mycat
  mydbapi
  myebuild
  mypkg
  pkgloc
  prev_mtimes
  settings
  treetype
  unmerge
  vartree

Inherited from _emerge.SpawnProcess.SpawnProcess: args, cgroup, close_fds, env, fd_pipes, gid, groups, logfile, opt_name, path_lookup, pre_exec, uid, umask, unshare_ipc, unshare_net

Inherited from _emerge.SubProcess.SubProcess: pid

Inherited from _emerge.AbstractPollTask.AbstractPollTask: scheduler

Inherited from _emerge.AsynchronousTask.AsynchronousTask: background, cancelled, returncode

Inherited from object: __class__

Method Details [hide private]

_start(self)

source code 
Overrides: _emerge.AsynchronousTask.AsynchronousTask._start

_lock_vdb(self)

source code 

Lock the vdb if FEATURES=parallel-install is NOT enabled, otherwise do nothing. This is implemented with vardbapi.lock(), which supports reentrance by the subprocess that we spawn.

_spawn(self, args, fd_pipes, **kwargs)

source code 

Fork a subprocess, apply local settings, and call dblink.merge(). TODO: Share code with ForkProcess.

Overrides: _emerge.SpawnProcess.SpawnProcess._spawn

_unregister(self)

source code 

Unregister from the scheduler and close open files.

Overrides: _emerge.AbstractPollTask.AbstractPollTask._unregister