Package coprs :: Package logic :: Module batches_logic :: Class BatchesLogic
[hide private]
[frames] | no frames]

Class BatchesLogic

source code

Batch logic entrypoint

Class Methods [hide private]
 
get_batch_or_create(cls, build_id, requestor, modify=False)
Put the build into a new batch, and return the batch.
source code
 
pending_batch_trees(cls)
Get all the currently processing batches, together with all the dependency batches which are already finished -- and keep them ordered in list based on theirs ID and dependencies.
source code
 
batch_chain(cls, batch_id)
Return the batch_with batch_id, and all the transitively blocking batches in one list.
source code
Static Methods [hide private]
 
pending_batches()
Query for all still not-finished batches, order by id ASC
source code
Method Details [hide private]

get_batch_or_create(cls, build_id, requestor, modify=False)
Class Method

source code 

Put the build into a new batch, and return the batch. If the build is already assigned to any batch, do nothing and return the batch.

Locks the build for updates, may block!