You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openwhisk.apache.org by ra...@apache.org on 2018/06/06 14:00:41 UTC

[incubator-openwhisk] branch master updated: Only get action metadata when working with rules. (#3718)

This is an automated email from the ASF dual-hosted git repository.

rabbah pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-openwhisk.git


The following commit(s) were added to refs/heads/master by this push:
     new 583b154  Only get action metadata when working with rules. (#3718)
583b154 is described below

commit 583b154661ff0bb46b7c85a1ba92c2ec285b714d
Author: Markus Thömmes <ma...@me.com>
AuthorDate: Wed Jun 6 16:00:19 2018 +0200

    Only get action metadata when working with rules. (#3718)
    
    Working with rules only requires to make sure certain actions exist. We only need their metadata, not the full blown action including its code.
---
 core/controller/src/main/scala/whisk/core/controller/Rules.scala | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/core/controller/src/main/scala/whisk/core/controller/Rules.scala b/core/controller/src/main/scala/whisk/core/controller/Rules.scala
index 87fe771..c041ef0 100644
--- a/core/controller/src/main/scala/whisk/core/controller/Rules.scala
+++ b/core/controller/src/main/scala/whisk/core/controller/Rules.scala
@@ -393,7 +393,7 @@ trait WhiskRulesApi extends WhiskCollectionAPI with ReferencedEntities {
    * @return future that completes with references trigger and action if they exist
    */
   private def checkTriggerAndActionExist(trigger: FullyQualifiedEntityName, action: FullyQualifiedEntityName)(
-    implicit transid: TransactionId): Future[(WhiskTrigger, WhiskAction)] = {
+    implicit transid: TransactionId): Future[(WhiskTrigger, WhiskActionMetaData)] = {
 
     for {
       triggerExists <- WhiskTrigger.get(entityStore, trigger.toDocId) recoverWith {
@@ -408,7 +408,7 @@ trait WhiskRulesApi extends WhiskCollectionAPI with ReferencedEntities {
       }
 
       actionExists <- WhiskAction.resolveAction(entityStore, action) flatMap { resolvedName =>
-        WhiskAction.get(entityStore, resolvedName.toDocId)
+        WhiskActionMetaData.get(entityStore, resolvedName.toDocId)
       } recoverWith {
         case _: NoDocumentException =>
           Future.failed {

-- 
To stop receiving notification emails like this one, please contact
rabbah@apache.org.