bdoyle0182 commented on a change in pull request #4986:
URL: https://github.com/apache/openwhisk/pull/4986#discussion_r496900111



##########
File path: 
common/scala/src/main/scala/org/apache/openwhisk/core/entity/WhiskAction.scala
##########
@@ -548,8 +632,12 @@ object WhiskAction extends DocumentFactory[WhiskAction] 
with WhiskEntityQueries[
       wp flatMap { resolvedPkg =>
         // fully resolved name for the action
         val fqnAction = resolvedPkg.fullyQualifiedName(withVersion = 
false).add(actionName)
+        val action = WhiskActionVersionList.get(fqnAction, 
entityStore).flatMap { result =>
+          val docId = result.matchedDocId(version).getOrElse(fqnAction.toDocId)
+          WhiskAction.get(entityStore, docId)

Review comment:
       yes exactly, having a client specified default version allows them to 
follow a safe release process. They can deploy their function, run tests on it, 
and then update the default version to start accepting traffic when they're 
ready. And then can also easily rollback by changing the default version back.
   
   of course if all of your invoke requests can include the version you can do 
all of that without needing to maintain a default version, but not every client 
use case may have that level of control over their incoming traffic to be able 
to update the version on all invoke requests.
   
   As I said though I think it's a great follow up feature since it's 
additional work to store. Just defaulting to a latest version is already much 
better for deployment management than what exists.




----------------------------------------------------------------
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]


Reply via email to