You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@openwhisk.apache.org by GitBox <gi...@apache.org> on 2018/05/28 09:07:51 UTC

[GitHub] markusthoemmes commented on a change in pull request #3619: Provide an activation store SPI

markusthoemmes commented on a change in pull request #3619: Provide an activation store SPI
URL: https://github.com/apache/incubator-openwhisk/pull/3619#discussion_r191121516
 
 

 ##########
 File path: tests/src/test/scala/whisk/core/controller/test/ControllerTestCommon.scala
 ##########
 @@ -98,11 +97,69 @@ protected trait ControllerTestCommon
     }, dbOpTimeout)
   }
 
-  def deleteActivation(doc: DocId)(implicit transid: TransactionId) = {
-    Await.result(WhiskActivation.get(activationStore, doc) flatMap { doc =>
-      logging.debug(this, s"deleting ${doc.docinfo}")
-      WhiskActivation.del(activationStore, doc.docinfo)
-    }, dbOpTimeout)
+  def getActivation(activationId: ActivationId)(implicit transid: TransactionId,
+                                                timeout: Duration = 10 seconds): WhiskActivation = {
+    val activationFuture = activationStore.get(activationId)
+    val activation = Await.result(activationFuture, timeout)
+    assert(activation != null)
 
 Review comment:
   How can activation be `null` here?

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


With regards,
Apache Git Services