[GitHub] rabbah commented on a change in pull request #2604: (WIP) Give more information in Activation lists

2017-08-11 Thread git
rabbah commented on a change in pull request #2604: (WIP) Give more information 
in Activation lists
URL: 
https://github.com/apache/incubator-openwhisk/pull/2604#discussion_r132737302
 
 

 ##
 File path: common/scala/src/main/scala/whisk/core/entity/WhiskActivation.scala
 ##
 @@ -62,7 +62,8 @@ case class WhiskActivation(
 version: SemVer = SemVer(),
 publish: Boolean = false,
 annotations: Parameters = Parameters(),
-duration: Option[Long] = None)
+duration: Option[Long] = None,
+entityType: String)
 
 Review comment:
   you can recover the type the entity type this way:
   
   1. action activations have an end and duration.
   2. triggers have no end or duration.
   3. rules have no end or duration, but have a caused field.
   
   furthermore - your change will break against a production deployment because 
it's a schema change.
   since it's not necessary i won't expand on how to deal with that 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:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rabbah commented on a change in pull request #2604: (WIP) Give more information in Activation lists

2017-08-11 Thread git
rabbah commented on a change in pull request #2604: (WIP) Give more information 
in Activation lists
URL: 
https://github.com/apache/incubator-openwhisk/pull/2604#discussion_r132738438
 
 

 ##
 File path: common/scala/src/main/scala/whisk/core/entity/WhiskActivation.scala
 ##
 @@ -62,7 +62,8 @@ case class WhiskActivation(
 version: SemVer = SemVer(),
 publish: Boolean = false,
 annotations: Parameters = Parameters(),
-duration: Option[Long] = None)
+duration: Option[Long] = None,
+entityType: String)
 
 Review comment:
   bummer! thank you for the improvements to the CLI in that case -- these were 
some long outstanding features/improvements we hadn't gotten to, I didn't 
realize you are leaving so soon.
   
 

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:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rabbah commented on a change in pull request #2604: (WIP) Give more information in Activation lists

2017-08-11 Thread git
rabbah commented on a change in pull request #2604: (WIP) Give more information 
in Activation lists
URL: 
https://github.com/apache/incubator-openwhisk/pull/2604#discussion_r132738226
 
 

 ##
 File path: common/scala/src/main/scala/whisk/core/entity/WhiskActivation.scala
 ##
 @@ -62,7 +62,8 @@ case class WhiskActivation(
 version: SemVer = SemVer(),
 publish: Boolean = false,
 annotations: Parameters = Parameters(),
-duration: Option[Long] = None)
+duration: Option[Long] = None,
+entityType: String)
 
 Review comment:
   no worries that's why we review :D
 

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:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rabbah commented on a change in pull request #2604: (WIP) Give more information in Activation lists

2017-08-11 Thread git
rabbah commented on a change in pull request #2604: (WIP) Give more information 
in Activation lists
URL: 
https://github.com/apache/incubator-openwhisk/pull/2604#discussion_r132738116
 
 

 ##
 File path: ansible/files/whisks_design_document_for_activations_db.json
 ##
 @@ -2,7 +2,7 @@
   "_id": "_design/whisks",
   "views": {
 "all": {
-  "map": "function (doc) {\n  var PATHSEP = \"/\";\n  var isActivation = 
function (doc) { return (doc.activationId !== undefined) };\n  var collection = 
function (doc) {\nif (isActivation(doc)) return \"activations\";\n
return \"??\";\n  };\n\n  if (isActivation(doc)) try {\nvar ns = 
doc.namespace.split(PATHSEP);\nvar root = ns[0]; ns.shift();\nvar type 
= collection(doc);\nvar date = new Date(doc.start || doc.updated);\nvar 
value = {collection: type, namespace: doc.namespace, name: doc.name, version: 
doc.version, publish: doc.publish, annotations: doc.annotations};\n
value.activationId = doc.activationId;\nemit([root, date], value);\n  } 
catch (e) {}\n}\n"
+  "map": "function (doc) {\n  var PATHSEP = \"/\";\n  var isActivation = 
function (doc) { return (doc.activationId !== undefined) };\n  var collection = 
function (doc) {\nif (isActivation(doc)) return \"activations\";\n
return \"??\";\n  };\n\n  if (isActivation(doc)) try {\nvar ns = 
doc.namespace.split(PATHSEP);\nvar root = ns[0]; ns.shift();\nvar type 
= collection(doc);\nvar date = new Date(doc.start || doc.updated);\nvar 
value = {collection: type, namespace: doc.namespace, name: doc.name, version: 
doc.version, publish: doc.publish, annotations: doc.annotations, entityType: 
doc.entityType};\nvalue.activationId = doc.activationId;\nemit([root, 
date], value);\n  } catch (e) {}\n}\n"
 
 Review comment:
   let's avoid any changes to the activation view unless there's a very good 
reason for it.
 

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:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rabbah commented on a change in pull request #2604: (WIP) Give more information in Activation lists

2017-08-11 Thread git
rabbah commented on a change in pull request #2604: (WIP) Give more information 
in Activation lists
URL: 
https://github.com/apache/incubator-openwhisk/pull/2604#discussion_r132737843
 
 

 ##
 File path: tests/src/test/scala/system/basic/WskBasicTests.scala
 ##
 @@ -185,6 +185,27 @@ class WskBasicTests
 stderr should include regex (s"""Unable to get package '$name': The 
requested resource does not exist. \\(code \\d+\\)""")
 }
 
+it should "return a list of alphabetized packages" in 
withAssetCleaner(wskprops) {
 
 Review comment:
   FYI: general functionality/usage tests don't believe in the system package; 
only tests that are generally associated with system health should be here.
   
   this looks like just a bad merge/need to rebase.
 

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:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rabbah commented on a change in pull request #2604: (WIP) Give more information in Activation lists

2017-08-11 Thread git
rabbah commented on a change in pull request #2604: (WIP) Give more information 
in Activation lists
URL: 
https://github.com/apache/incubator-openwhisk/pull/2604#discussion_r132737302
 
 

 ##
 File path: common/scala/src/main/scala/whisk/core/entity/WhiskActivation.scala
 ##
 @@ -62,7 +62,8 @@ case class WhiskActivation(
 version: SemVer = SemVer(),
 publish: Boolean = false,
 annotations: Parameters = Parameters(),
-duration: Option[Long] = None)
+duration: Option[Long] = None,
+entityType: String)
 
 Review comment:
   no no no - we are not doing that :)
   
   1. action activations have an end and duration.
   2. triggers have no end or duration.
   3. rules have no end or duration, but have a caused field.
   
   you can recover the type this way.
   
   furthermore - your change will break against a production deployment because 
it's a schema change.
   since it's not necessary i won't expand on how to deal with that 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:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rabbah commented on a change in pull request #2604: (WIP) Give more information in Activation lists

2017-08-11 Thread git
rabbah commented on a change in pull request #2604: (WIP) Give more information 
in Activation lists
URL: 
https://github.com/apache/incubator-openwhisk/pull/2604#discussion_r132737302
 
 

 ##
 File path: common/scala/src/main/scala/whisk/core/entity/WhiskActivation.scala
 ##
 @@ -62,7 +62,8 @@ case class WhiskActivation(
 version: SemVer = SemVer(),
 publish: Boolean = false,
 annotations: Parameters = Parameters(),
-duration: Option[Long] = None)
+duration: Option[Long] = None,
+entityType: String)
 
 Review comment:
   no no no - we are not doing that.
   
   1. action activations have an end and duration.
   2. triggers have no end or duration.
   3. rules have no end or duration, but have a caused field.
   
   you can recover the type this way.
   
   furthermore - your change will break against a production deployment because 
it's a schema change.
   since it's not necessary i won't expand on how to deal with that 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:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rabbah commented on a change in pull request #2604: (WIP) Give more information in Activation lists

2017-08-11 Thread git
rabbah commented on a change in pull request #2604: (WIP) Give more information 
in Activation lists
URL: 
https://github.com/apache/incubator-openwhisk/pull/2604#discussion_r132737302
 
 

 ##
 File path: common/scala/src/main/scala/whisk/core/entity/WhiskActivation.scala
 ##
 @@ -62,7 +62,8 @@ case class WhiskActivation(
 version: SemVer = SemVer(),
 publish: Boolean = false,
 annotations: Parameters = Parameters(),
-duration: Option[Long] = None)
+duration: Option[Long] = None,
+entityType: String)
 
 Review comment:
   no no no - we are not doing that.
 

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:
us...@infra.apache.org


With regards,
Apache Git Services