You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openwhisk.apache.org by pd...@apache.org on 2018/05/21 19:22:10 UTC

[incubator-openwhisk-wskdeploy] branch master updated: Resolves issue #916 (#917)

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

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


The following commit(s) were added to refs/heads/master by this push:
     new 8caf15f  Resolves issue #916 (#917)
8caf15f is described below

commit 8caf15f28c459d88b35632d392dcc32efc6408f6
Author: Pavel Kravchenko <kp...@il.ibm.com>
AuthorDate: Mon May 21 22:22:08 2018 +0300

    Resolves issue #916 (#917)
---
 deployers/manifestreader.go | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/deployers/manifestreader.go b/deployers/manifestreader.go
index c19fd68..220924d 100644
--- a/deployers/manifestreader.go
+++ b/deployers/manifestreader.go
@@ -295,8 +295,13 @@ func (reader *ManifestReader) SetApis(ar []*whisk.ApiCreateRequest) error {
 	defer dep.mt.Unlock()
 
 	for _, api := range ar {
-		dep.Deployment.Apis[api.ApiDoc.Action.Name] = api
+		apiPath := api.ApiDoc.ApiName + api.ApiDoc.GatewayBasePath + api.ApiDoc.GatewayRelPath + api.ApiDoc.GatewayMethod
+
+		// uniqueness issue when using action name as key as there can be multiple APIs pointing to same action.
+		// using apiPath instead as it is uniqueue
+		dep.Deployment.Apis[apiPath] = api
 	}
+
 	return nil
 }
 

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