[Cubicweb] Enhancing `bulk` writes in CubicWeb
aurelien.campeas at logilab.fr
Wed May 7 11:15:03 CEST 2014
On 06/05/2014 10:55, Aurélien Campéas wrote:
> On 05/05/2014 22:48, Adrien Di Mascio wrote:
>> On Fri, May 2, 2014 at 3:05 PM, Aurélien Campéas
>> <aurelien.campeas at logilab.fr <mailto:aurelien.campeas at logilab.fr>> wrote:
>> The API is as such:
>> * `insert_entities` (etype, entitiesdicts, postprocessentity)
>> * `insert_relations` (rtype, fromtoentities)
>> * `run_deferred_hooks` (errorslist)
>> What exactly does run_deferred_hooks() do ?
> That's an idea still in flux.
> The base idea is to run the hooks in a follow-up transaction
> (they got collected with all relevant information in the
> initial transaction).
> The current implementation quite violates this and, in
> the initial transaction, performs the "vectorized" version
> of these hooks.
> Hence we really can "defer" only the vectorized ones right now.
> They just run at pre-commit time, like a big Op.
Hum, but of course I will have to finish the work & make
non "vectorized" hook/op combos run in the follow-up transactions.
This includes, e.g. fti & notification hooks.
More information about the Cubicweb