bdoyle0182 opened a new issue #4842: Race Condition with Activation Completion 
Ack Back to Controller and Activation Write to Couchdb?
URL: https://github.com/apache/openwhisk/issues/4842
 
 
   I might just be misunderstanding the code base here, but my understanding is 
that in ContainerProxy; the ack that is sent back to the controller on 
`completed*` that is used by the Controller to mark the activation as 
successful is done concurrently with the activation write to couchdb. 
Specifically the `sendActiveAck` and `storeActivation` functions respectively. 
Does this cause a race condition where the the `sendActiveAck` that produces 
the message to `completed*` could complete and then the invoker dies before the 
activation is written to couchdb and thus the activation is never persisted? I 
assume this is either intentional or I have some misunderstanding. 
   
   Our system listens on the `completed*` topics to know when the activations 
are finished, but it would be a problem for us if something could theoretically 
be put on the `completed*` topic and then potentially never get persisted 
because an invoker goes down or is restarted in that small window. It seems 
like the new approach with ActivationPersisterService #4632 would solve the 
problem at least for our use case because we could listen on the new 
`activations` topic for a notification on when an activation is completed or 
the `completed-others*` (I'm not sure which one applies) because whatever that 
topic is now directly feeds the writes to the primary persistence storage so it 
would be guaranteed to eventually make it there.
   
   Also a note on the ActivationPersisterService, a very big fan of anything 
that lets us control / configure / limit load on couchdb :)

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to