[GitHub] jasonpet commented on issue #123: Avoid that trigger is fired too often if request to OpenWhisk is too ?
jasonpet commented on issue #123: Avoid that trigger is fired too often if request to OpenWhisk is too ? URL: https://github.com/apache/incubator-openwhisk-package-cloudant/pull/123#issuecomment-321551647 @csantanapr - can you please merge this? 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] dubeejw commented on issue #2424: Allow optional leading slash in CLI commands
dubeejw commented on issue #2424: Allow optional leading slash in CLI commands URL: https://github.com/apache/incubator-openwhisk/pull/2424#issuecomment-321573610 @underwoodb-sd-ibm, test is in the correct suite. 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] cbickel opened a new pull request #2600: Remove databases of old ReplicatorTests that failed
cbickel opened a new pull request #2600: Remove databases of old ReplicatorTests that failed URL: https://github.com/apache/incubator-openwhisk/pull/2600 This PR does a cleanup before the ReplicatorTests starts. In addition, it fixes the retry method in the replicator-script. PG4#661 started. 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] markusthoemmes commented on a change in pull request #2600: Remove databases of old ReplicatorTests that failed
markusthoemmes commented on a change in pull request #2600: Remove databases of old ReplicatorTests that failed URL: https://github.com/apache/incubator-openwhisk/pull/2600#discussion_r132454181 ## File path: tests/src/test/scala/whisk/core/database/test/ReplicatorTests.scala ## @@ -130,6 +130,17 @@ class ReplicatorTests extends FlatSpec } } +// Do cleanups of possibly existing databases +val dbs = replicatorClient.dbs().futureValue +dbs shouldBe 'right +dbs.right.get.filter(dbname => dbname.contains(testDbPrefix)).map(dbName => removeDatabase(dbName)) + +val docs = replicatorClient.getAllDocs().futureValue +docs shouldBe 'right +docs.right.get.fields("rows").convertTo[List[JsObject]] +.filter(_.fields("id").convertTo[String].contains(testDbPrefix)) Review comment: Should that be `startsWith(testDbPrefix)` for good measure? Might need to do `startsWith("backup_" + testDbProfix) || startsWith("continuous_" + testDbPrefix)` 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] houshengbo commented on a change in pull request #2557: Fix ansible script for distributed environment
houshengbo commented on a change in pull request #2557: Fix ansible script for distributed environment URL: https://github.com/apache/incubator-openwhisk/pull/2557#discussion_r132459758 ## File path: ansible/roles/cli/tasks/deploy.yml ## @@ -24,8 +24,4 @@ copy: src={{ openwhisk_cli.local.location }}/content.json dest={{ cli.nginxdir }}/ when: cli_installation_mode == "local" -- name: "copy the binaries from a local directory to Nginx directory" Review comment: I agree. It is a duplicate line of script. We can remove 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] underwoodb-sd-ibm commented on issue #2424: Allow optional leading slash in CLI commands
underwoodb-sd-ibm commented on issue #2424: Allow optional leading slash in CLI commands URL: https://github.com/apache/incubator-openwhisk/pull/2424#issuecomment-321575776 @csantanapr - I'm assuming we need to wait for @rabbah to give the ok, but is it possible to merge this guy when/if you have time? Thanks! 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] spattewar commented on issue #2567: Openwhisk Local Installation on Ubuntu 14 Failed !!! Please help
spattewar commented on issue #2567: Openwhisk Local Installation on Ubuntu 14 Failed !!! Please help URL: https://github.com/apache/incubator-openwhisk/issues/2567#issuecomment-321549258 @devbv @rabbah please help when you get time. I was able to reintall nginx. Then tear down the containers. ran openwhisk with the clean mode and then openwhisk.yml and it seems to work now. But even though I have set the API Host property and the auth certificate I cannot run the wsk command without the -i flag. Can you help me with the steps to make this more secure? I was able to create action and run the action. thank you for your time. Regards 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] cbickel opened a new pull request #2601: Invalidate Caches between controllers with Kafka
cbickel opened a new pull request #2601: Invalidate Caches between controllers with Kafka URL: https://github.com/apache/incubator-openwhisk/pull/2601 This PR adds the ability to invalidate caches between controllers on updating and deleting the cache on one of the controllers. It also adds the case class `CacheKey`, to use a particular key for the WhiskCache instead of `Any`. This PR is dependant on #2338 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] underwoodb-sd-ibm commented on issue #2326: Alphabetize listings in CLI
underwoodb-sd-ibm commented on issue #2326: Alphabetize listings in CLI URL: https://github.com/apache/incubator-openwhisk/pull/2326#issuecomment-321589687 PG1 1939 - Passed 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] underwoodb-sd-ibm commented on issue #2326: Alphabetize listings in CLI
underwoodb-sd-ibm commented on issue #2326: Alphabetize listings in CLI URL: https://github.com/apache/incubator-openwhisk/pull/2326#issuecomment-321589607 Update: added code to allow `wsk list` and `wsk namespace get` to properly print rule status. Inadvertently closes #2598. 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] csantanapr closed pull request #66: change cli to curl for integration script
csantanapr closed pull request #66: change cli to curl for integration script URL: https://github.com/apache/incubator-openwhisk-client-js/pull/66 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] tleyden opened a new issue #25: Not adding "api" to the URL
tleyden opened a new issue #25: Not adding "api" to the URL URL: https://github.com/apache/incubator-openwhisk-client-go/issues/25 I'm running against Bluemix, and trying to list activations with: ``` config, err := WhiskConfigFromEnvironment() if err != nil { return nil, err } client, _ := whisk.NewClient(http.DefaultClient, config) activations, resp, err := client.Activations.List(nil) ``` In `WhiskConfigFromEnvironment()` I?m setting `config.AUTH` and `config.APIHOST` based on what?s in my `~/.wskprops` file. However it's getting a 404 because it's trying to go to `http://openwhisk.ng.bluemix.net/v1/namespaces/_/activations`, which is missing `api` in the base url. If I run `wsk -d activation list` I can see that it goes to `https://openwhisk.ng.bluemix.net/api/v1/namespaces/_/activations?limit=30=0`. I verified that it fixes the issue w/ this (hacky) workaround: ``` requestUrlString := strings.Replace(requestUrl.String(), "v1", "api/v1", 1) req, err := http.NewRequest(method, requestUrlString, buf) ``` After that change, `client.Activations.List(nil)` returns the list of activations. 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] underwoodb-sd-ibm commented on issue #2326: Alphabetize listings in CLI
underwoodb-sd-ibm commented on issue #2326: Alphabetize listings in CLI URL: https://github.com/apache/incubator-openwhisk/pull/2326#issuecomment-321377908 PG1 1938 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] ningyougang commented on issue #2567: Openwhisk Local Installation on Ubuntu 14 Failed !!! Please help
ningyougang commented on issue #2567: Openwhisk Local Installation on Ubuntu 14 Failed !!! Please help URL: https://github.com/apache/incubator-openwhisk/issues/2567#issuecomment-321736320 @spattewar , @rabbah * First rebase your codes from upstream, because there has many more changes. * Second, guess your reason. * May be the reason that your controller points to the couchdb's auth db name not exist using `docker inspect controller0` to find the ENV:`DB_WHISK_AUTHS`, it is the auth db name which your controller points to. then, login into `http://:5984/_utils/` to check whether exist. (i seen in the log , the name is very long: `root_guruvirtues-hp-elitebook-8560w-sn717up-aba_whisks`) * May be the reason that: if auth db name is right, check `whisk.system/routemgmt` exist. Anyway, after rebase the codes from master, above question will be lost 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] xingzhou commented on issue #43: WIP: configure/deploy via helm charts
xingzhou commented on issue #43: WIP: configure/deploy via helm charts URL: https://github.com/apache/incubator-openwhisk-deploy-kube/pull/43#issuecomment-321465582 just created another ticket in k8s official charts repo: https://github.com/kubernetes/charts/issues/1648 Once this is stable, can we also submit a PR in kubernetes charts repo? 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] xingzhou commented on issue #43: WIP: configure/deploy via helm charts
xingzhou commented on issue #43: WIP: configure/deploy via helm charts URL: https://github.com/apache/incubator-openwhisk-deploy-kube/pull/43#issuecomment-321470270 @berndtj, are you still working on this? as we are also trying to write a chart to deploy open whisk, not sure if we can cooperate together? /cc @DanLavine 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] xingzhou commented on issue #43: WIP: configure/deploy via helm charts
xingzhou commented on issue #43: WIP: configure/deploy via helm charts URL: https://github.com/apache/incubator-openwhisk-deploy-kube/pull/43#issuecomment-321470270 @berndtj, are you still working on this? as we are also trying to write a chart to deploy open whisk, not sure if we can cooperate together? 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] cbickel opened a new pull request #123: Avoid that trigger is fired too often if request to OpenWhisk is too ?
cbickel opened a new pull request #123: Avoid that trigger is fired too often if request to OpenWhisk is too ? URL: https://github.com/apache/incubator-openwhisk-package-cloudant/pull/123 ?slow. If updates from Cloudant arrive faster than the requests to OpenWhisk take, more triggers are fired then specified. 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] markusthoemmes commented on a change in pull request #2584: SPI for Loadbalancer
markusthoemmes commented on a change in pull request #2584: SPI for Loadbalancer URL: https://github.com/apache/incubator-openwhisk/pull/2584#discussion_r132405059 ## File path: common/scala/src/main/scala/whisk/core/database/CouchDbStoreProvider.scala ## @@ -18,16 +18,18 @@ package whisk.core.database import akka.actor.ActorSystem +import scala.collection.mutable import spray.json.RootJsonFormat import whisk.common.Logging import whisk.core.WhiskConfig import whisk.spi.Dependencies -import whisk.spi.SpiFactory +import whisk.spi.SingletonSpiFactory /** * A CouchDB implementation of ArtifactStoreProvider */ class CouchDbStoreProvider extends ArtifactStoreProvider { +protected[database] val stores = mutable.Map [String, CouchDbRestStore[_]]() Review comment: Whitespace: ```scala protected[database] val stores = mutable.Map[String, CouchDbRestStore[_]]() ``` Could this be private? 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] markusthoemmes commented on a change in pull request #2584: SPI for Loadbalancer
markusthoemmes commented on a change in pull request #2584: SPI for Loadbalancer URL: https://github.com/apache/incubator-openwhisk/pull/2584#discussion_r132405059 ## File path: common/scala/src/main/scala/whisk/core/database/CouchDbStoreProvider.scala ## @@ -18,16 +18,18 @@ package whisk.core.database import akka.actor.ActorSystem +import scala.collection.mutable import spray.json.RootJsonFormat import whisk.common.Logging import whisk.core.WhiskConfig import whisk.spi.Dependencies -import whisk.spi.SpiFactory +import whisk.spi.SingletonSpiFactory /** * A CouchDB implementation of ArtifactStoreProvider */ class CouchDbStoreProvider extends ArtifactStoreProvider { +protected[database] val stores = mutable.Map [String, CouchDbRestStore[_]]() Review comment: Whitespace: ```scala protected[database] val stores = mutable.Map[String, CouchDbRestStore[_]]() ``` Could this be private? 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] markusthoemmes commented on a change in pull request #2584: SPI for Loadbalancer
markusthoemmes commented on a change in pull request #2584: SPI for Loadbalancer URL: https://github.com/apache/incubator-openwhisk/pull/2584#discussion_r132406663 ## File path: core/controller/src/main/scala/whisk/core/loadBalancer/LoadBalancerService.scala ## @@ -77,16 +82,32 @@ trait LoadBalancer { */ def publish(action: ExecutableWhiskAction, msg: ActivationMessage)(implicit transid: TransactionId): Future[Future[Either[ActivationId, WhiskActivation]]] +/** + * Return a message indicating the health of the containers and/or container pool in general + * @return a Future[String] representing the heal response that will be sent to the client + */ +def getHealthResponse: Future[JsObject] +} + +class LoadBalancerServiceProvider extends LoadBalancerProvider { +override def getLoadBalancer(config: WhiskConfig, instance: InstanceId) +(implicit logging: Logging, actorSystem: ActorSystem): LoadBalancer = new LoadBalancerService(config, instance) +} + +object LoadBalancerServiceProvider extends SpiFactory[LoadBalancerProvider]{ +override def apply(dependencies: Dependencies): LoadBalancerProvider = new LoadBalancerServiceProvider } class LoadBalancerService( config: WhiskConfig, -instance: InstanceId, -entityStore: EntityStore)( +instance: InstanceId)( implicit val actorSystem: ActorSystem, logging: Logging) extends LoadBalancer { +/** Used to manage an action for testing invoker health */ +val entityStore = WhiskEntityStore.datastore(config) Review comment: What's the rationale for generating a new one (and deduplicate via the SPI) vs. passing it through the `Dependencies` object? (Not necessarily arguing against this, just curiosity) 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] jthomas commented on issue #66: change cli to curl for integration script
jthomas commented on issue #66: change cli to curl for integration script URL: https://github.com/apache/incubator-openwhisk-client-js/pull/66#issuecomment-321489431 ? 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] markusthoemmes commented on a change in pull request #2584: SPI for Loadbalancer
markusthoemmes commented on a change in pull request #2584: SPI for Loadbalancer URL: https://github.com/apache/incubator-openwhisk/pull/2584#discussion_r132404422 ## File path: core/controller/src/main/scala/whisk/core/loadBalancer/LoadBalancerService.scala ## @@ -31,17 +31,19 @@ import akka.actor.ActorSystem import akka.actor.Props import akka.pattern.ask import akka.util.Timeout +import spray.json.DefaultJsonProtocol._ +import spray.json._ import whisk.common.Logging import whisk.common.LoggingMarkers import whisk.common.TransactionId import whisk.core.WhiskConfig import whisk.core.WhiskConfig._ import whisk.core.connector.MessagingProvider -import whisk.core.connector.{ ActivationMessage, CompletionMessage } +import whisk.core.connector.{ActivationMessage, CompletionMessage} Review comment: Can you try to adjust this formatting? 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] markusthoemmes commented on a change in pull request #2584: SPI for Loadbalancer
markusthoemmes commented on a change in pull request #2584: SPI for Loadbalancer URL: https://github.com/apache/incubator-openwhisk/pull/2584#discussion_r132404790 ## File path: common/scala/src/main/scala/whisk/core/database/CouchDbRestStore.scala ## @@ -52,7 +52,8 @@ class CouchDbRestStore[DocumentAbstraction <: DocumentSerializer]( dbPort: Int, dbUsername: String, dbPassword: String, -dbName: String)(implicit system: ActorSystem, val logging: Logging, jsonFormat: RootJsonFormat[DocumentAbstraction]) +dbName: String, +cleanup:(String)=>Unit)(implicit system: ActorSystem, val logging: Logging, jsonFormat: RootJsonFormat[DocumentAbstraction]) Review comment: Why do you need to pass the `dbName` in? When you open the client you automatically have it at hand. `shutdown: => Unit` should suffice (note the whitespace please) 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] markusthoemmes commented on a change in pull request #2584: SPI for Loadbalancer
markusthoemmes commented on a change in pull request #2584: SPI for Loadbalancer URL: https://github.com/apache/incubator-openwhisk/pull/2584#discussion_r132406052 ## File path: core/controller/src/main/scala/whisk/core/loadBalancer/LoadBalancerService.scala ## @@ -275,6 +296,14 @@ class LoadBalancerService( private def generateHash(namespace: EntityName, action: ExecutableWhiskAction): Int = { (namespace.asString.hashCode() ^ action.fullyQualifiedName(false).asString.hashCode()).abs } + +/** Returns a Map of invoker instance -> invoker state */ +override def getHealthResponse(): Future[JsObject] = { +val res = allInvokers.map(_.map { +case (instance, state) => s"invoker${instance.toInt}" -> state.asString +}.toMap.toJson.asJsObject) +res Review comment: There is no need to store the intermediary result: ```scala override def getHealthResponse(): Future[JsObject] = allInvokers.map(_.map { case (instance, state) => s"invoker${instance.toInt}" -> state.asString }.toMap.toJson.asJsObject) ``` Also please refrain from using java style getter names like `getHealthResponse`. I suggest `LoadBalancer.healthStatus()`. 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] csantanapr closed pull request #123: Avoid that trigger is fired too often if request to OpenWhisk is too ?
csantanapr closed pull request #123: Avoid that trigger is fired too often if request to OpenWhisk is too ? URL: https://github.com/apache/incubator-openwhisk-package-cloudant/pull/123 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] underwoodb-sd-ibm commented on issue #2490: CLI summaries for actions without annotations
underwoodb-sd-ibm commented on issue #2490: CLI summaries for actions without annotations URL: https://github.com/apache/incubator-openwhisk/pull/2490#issuecomment-321587741 @dubeejw - fixed :) 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] houshengbo opened a new pull request #314: Pull the openwhisk images instead of building them in Travis
houshengbo opened a new pull request #314: Pull the openwhisk images instead of building them in Travis URL: https://github.com/apache/incubator-openwhisk-wskdeploy/pull/314 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] drcariel commented on issue #2591: User-Agent CLI/version header
drcariel commented on issue #2591: User-Agent CLI/version header URL: https://github.com/apache/incubator-openwhisk/pull/2591#issuecomment-321606362 Thanks for the input @mdeuser , not sure why I found it so difficult the first time round. 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] berndtj commented on issue #43: WIP: configure/deploy via helm charts
berndtj commented on issue #43: WIP: configure/deploy via helm charts URL: https://github.com/apache/incubator-openwhisk-deploy-kube/pull/43#issuecomment-321608571 I/we are working on it. I was on PTO for the past couple weeks, and I delegated to a colleague. That said, I'm sure he would like some help with it. I'm trying to get his github ID so that you can connect. I also chatted with @DanLavine on slack yesterday about this. I think the one concern he has about a single config file for all deployment types could be overcome. It may require an additional tool, but that would be a separate effort that this could easily work with. 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] drcariel commented on a change in pull request #2591: User-Agent CLI/version header
drcariel commented on a change in pull request #2591: User-Agent CLI/version header URL: https://github.com/apache/incubator-openwhisk/pull/2591#discussion_r132558633 ## File path: tools/cli/go-whisk/whisk/api.go ## @@ -43,7 +43,6 @@ type ApiListRequestOptions struct { Skipint `url:"skip"` Docsbool `url:"docs,omitempty"` } -//type ApiListResponse RetApiArray type ApiListResponse RetApiArray Review comment: Some lingering cleanup from the experimental-api removal PR 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] bjustin-ibm commented on issue #3: CI with travis
bjustin-ibm commented on issue #3: CI with travis URL: https://github.com/apache/incubator-openwhisk-client-js/issues/3#issuecomment-321666223 Resolved by #59 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] bjustin-ibm closed issue #3: CI with travis
bjustin-ibm closed issue #3: CI with travis URL: https://github.com/apache/incubator-openwhisk-client-js/issues/3 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] bjustin-ibm commented on issue #2: integration tests require manual setup and cleanup
bjustin-ibm commented on issue #2: integration tests require manual setup and cleanup URL: https://github.com/apache/incubator-openwhisk-client-js/issues/2#issuecomment-321666525 Resolved by #59 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] bjustin-ibm closed issue #2: integration tests require manual setup and cleanup
bjustin-ibm closed issue #2: integration tests require manual setup and cleanup URL: https://github.com/apache/incubator-openwhisk-client-js/issues/2 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] houshengbo closed pull request #46: Deploy CouchDB manually
houshengbo closed pull request #46: Deploy CouchDB manually URL: https://github.com/apache/incubator-openwhisk-deploy-kube/pull/46 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] houshengbo opened a new issue #315: Use case of trigger rule does not configure the pramters of the action with the correct values
houshengbo opened a new issue #315: Use case of trigger rule does not configure the pramters of the action with the correct values URL: https://github.com/apache/incubator-openwhisk-wskdeploy/issues/315 In our test case of trigger rule, one action helloworld/greeting will be created with the default inputs name: Bernie and place: Vermont. However, the keys name and place have been added, but the values are not added. Here is the information of the action created, if I run the command: ./wskdeploy -m tests/usecases/triggerrule/manifest.yml -d tests/usecases/triggerrule/deployment.yml { "namespace": "whisk.system/helloworld", "name": "greeting", "version": "0.0.1", "exec": { "kind": "nodejs:6", "code": "/**\n * Return a simple greeting message for someone.\n *\n * @param name A person's name.\n * @param place Where the person is from.\n */\nfunction main(params) {\nvar name = params.name || params.payload || 'stranger';\nvar place = params.place || 'somewhere';\nreturn {payload: 'Hello, ' + name + ' from ' + place + '!'};\n}\n" }, "annotations": [ { "key": "exec", "value": "nodejs:6" } ], "parameters": [ { "key": "name", "value": "string" }, { "key": "place", "value": "string" } ], "limits": { "timeout": 6, "memory": 256, "logs": 10 }, "publish": false } 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] houshengbo commented on issue #315: Use case of trigger rule does not configure the pramters of the action with the correct values
houshengbo commented on issue #315: Use case of trigger rule does not configure the pramters of the action with the correct values URL: https://github.com/apache/incubator-openwhisk-wskdeploy/issues/315#issuecomment-321668718 @lzbj Please take a look at this issue. 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] houshengbo opened a new pull request #26: Update the Travis configuration avoiding building locally
houshengbo opened a new pull request #26: Update the Travis configuration avoiding building locally URL: https://github.com/apache/incubator-openwhisk-client-go/pull/26 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] jessealva commented on issue #2326: Alphabetize listings in CLI
jessealva commented on issue #2326: Alphabetize listings in CLI URL: https://github.com/apache/incubator-openwhisk/pull/2326#issuecomment-321643101 Looks like this also resolves #2598 Just looked at the change history after talking to Brandon and can verify it will fix that issue as well. 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] tleyden commented on issue #25: Not adding "api" to the URL
tleyden commented on issue #25: Not adding "api" to the URL URL: https://github.com/apache/incubator-openwhisk-client-go/issues/25#issuecomment-321594084 Another workaround that works is to add the `api` to the url before setting the `config.BaseURL` variable. If that's the recommend way to use the API, then the docs on the `config.BaseURL` should probably be updated to reflect that. Currently it's a bit confusing since it says: ``` type Config struct { BaseURL *url.URL // NOTE :: Default is "openwhisk.ng.bluemix.net" .. } ``` (which would mean that the default val is broken) 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] bjustin-ibm commented on issue #210: How to use message feed
bjustin-ibm commented on issue #210: How to use message feed URL: https://github.com/apache/incubator-openwhisk-package-kafka/issues/210#issuecomment-321548728 > Setting up a Message Hub package outside Bluemix > Is this install Message Hub package on the local host outside Bluemix? No. This only installs the related actions into your OpenWhisk. It does not create a Message Hub or Kafka instance that you can use. > I can sign in Bluemix with my username and password, why can not authenticate with Message Hub with the same username and password You have to first provision a Message Hub instance in Bluemix. When you do this, a set of Message Hub credentials (that are different from your Bluemix username and password) will be generated. You will need to use these credentials when creating the trigger. Please refer to the [Getting Started with Message Hub](https://console.bluemix.net/docs/services/MessageHub/index.html#messagehub) documentation. > I can create docker image kafkafeedprovider successfully > but when I run script docker_run.sh, there is an error It appears that you are using an older version of the feed provider that used to require a `CLOUDANT_USER` environment variable. Please update your repository to the latest in the master branch, then rebuild the image, and start a new container. 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] houshengbo closed pull request #2557: Fix ansible script for distributed environment
houshengbo closed pull request #2557: Fix ansible script for distributed environment URL: https://github.com/apache/incubator-openwhisk/pull/2557 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] cbickel commented on a change in pull request #2600: Remove databases of old ReplicatorTests that failed
cbickel commented on a change in pull request #2600: Remove databases of old ReplicatorTests that failed URL: https://github.com/apache/incubator-openwhisk/pull/2600#discussion_r132475988 ## File path: tests/src/test/scala/whisk/core/database/test/ReplicatorTests.scala ## @@ -130,6 +130,17 @@ class ReplicatorTests extends FlatSpec } } +// Do cleanups of possibly existing databases +val dbs = replicatorClient.dbs().futureValue +dbs shouldBe 'right +dbs.right.get.filter(dbname => dbname.contains(testDbPrefix)).map(dbName => removeDatabase(dbName)) + +val docs = replicatorClient.getAllDocs().futureValue +docs shouldBe 'right +docs.right.get.fields("rows").convertTo[List[JsObject]] +.filter(_.fields("id").convertTo[String].contains(testDbPrefix)) Review comment: The problem is, that the test creates databases with the prefix "continous_testDbPrefix", "backup_timestamp_testDbPrefix" and "testDbPrefix". The testDbPrefix is already a combination of the string "replicatorTests" and the dbPrefix of the environment. That's why I just use contains instead of handling all cases. 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] houshengbo opened a new pull request #95: Pull the openwhisk image instead of building it
houshengbo opened a new pull request #95: Pull the openwhisk image instead of building it URL: https://github.com/apache/incubator-openwhisk-cli/pull/95 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] zhy989 commented on issue #210: How to use message feed
zhy989 commented on issue #210: How to use message feed URL: https://github.com/apache/incubator-openwhisk-package-kafka/issues/210#issuecomment-321508475 @bjustin-ibm thanks in case 1: Should I register a new account on the local host for message hub? in case 2: I tried this CLI "wsk trigger create MyKafkaTrigger -f /whisk.system/messaging/kafkaFeed -p brokers "mykafkahost:9092,mykafkahost:9093" -p topic mytopic -p isJSONData true -i", and got the same error - wsk trigger create MyKafkaTrigger -f /whisk.system/messaging/kafkaFeed -p brokers "mykafkahost:9092,mykafkahost:9093" -p topic mytopic -p isJSONData true -i ok: invoked /whisk.system/messaging/kafkaFeed with id fff3cab0fde142e98ac81ba3a98db38c { "activationId": "fff3cab0fde142e98ac81ba3a98db38c", "annotations": [ { "key": "limits", "value": { "logs": 10, "memory": 256, "timeout": 6 } }, { "key": "path", "value": "whisk.system/messaging/kafkaFeed" } ], "duration": 991, "end": 1502359181855, "logs": [], "name": "kafkaFeed", "namespace": "whisk.system", "publish": false, "response": { "result": { "error": "Error: error happened in your connection" }, "status": "application error", "success": false }, "start": 1502359180864, "subject": "whisk.system", "version": "0.0.2" } ok: invoked /whisk.system/messaging/kafkaFeed with id c0cb00c7f1964151a2aabd5f35ef8d4f { "activationId": "c0cb00c7f1964151a2aabd5f35ef8d4f", "annotations": [ { "key": "limits", "value": { "logs": 10, "memory": 256, "timeout": 6 } }, { "key": "path", "value": "whisk.system/messaging/kafkaFeed" } ], "duration": 501, "end": 1502359182811, "logs": [], "name": "kafkaFeed", "namespace": "whisk.system", "publish": false, "response": { "result": {}, "status": "success", "success": true }, "start": 1502359182310, "subject": "whisk.system", "version": "0.0.2" } ok: deleted trigger MyKafkaTrigger - wsk -i activation logs fff3cab0fde142e98ac81ba3a98db38c 2017-08-10T09:59:41.851044685Z stdout: Error creating trigger: { 2017-08-10T09:59:41.851069919Z stdout: "name": "StatusCodeError", 2017-08-10T09:59:41.851073662Z stdout: "statusCode": 500, 2017-08-10T09:59:41.851076502Z stdout: "message": "500 - \"Error: error happened in your connection\"", 2017-08-10T09:59:41.851081688Z stdout: "error": "Error: error happened in your connection", 2017-08-10T09:59:41.851084534Z stdout: "options": { 2017-08-10T09:59:41.851087266Z stdout: "method": "PUT", 2017-08-10T09:59:41.851090286Z stdout: "url": "https://172.17.0.1/api/v1/web/whisk.system/messagingWeb/kafkaFeedWeb.http;, 2017-08-10T09:59:41.85109325Z stdout: "rejectUnauthorized": false, 2017-08-10T09:59:41.851095837Z stdout: "json": true, 2017-08-10T09:59:41.851098218Z stdout: "body": { 2017-08-10T09:59:41.851100973Z stdout: "authKey": "789c46b1-71f6-4ed5-8c54-816aa4f8c502:abczO3xZCLrMN6v2BKK1dXYFpXlPkccOFqm12CdAsMgRU4VrNZ9lyGVCGuMDGIwP", 2017-08-10T09:59:41.851103755Z stdout: "isJSONData": true, 2017-08-10T09:59:41.851107298Z stdout: "brokers": "mykafkahost:9092,mykafkahost:9093", 2017-08-10T09:59:41.851109876Z stdout: "topic": "mytopic", 2017-08-10T09:59:41.851112397Z stdout: "triggerName": "/whisk.system/MyKafkaTrigger" 2017-08-10T09:59:41.851115008Z stdout: }, 2017-08-10T09:59:41.851117353Z stdout: "headers": { 2017-08-10T09:59:41.851119788Z stdout: "Content-Type": "application/json", 2017-08-10T09:59:41.851122322Z stdout: "Accept": "text/plain", 2017-08-10T09:59:41.851150998Z stdout: "User-Agent": "whisk" 2017-08-10T09:59:41.851155301Z stdout: }, 2017-08-10T09:59:41.851157521Z stdout: "simple": true, 2017-08-10T09:59:41.851160009Z stdout: "resolveWithFullResponse": false, 2017-08-10T09:59:41.851162485Z stdout: "transform2xxOnly": false 2017-08-10T09:59:41.851164913Z stdout: }, 2017-08-10T09:59:41.851167255Z stdout: "response": { 2017-08-10T09:59:41.851170448Z stdout: "statusCode": 500, 2017-08-10T09:59:41.851172917Z stdout: "body": "Error: error happened in your connection", 2017-08-10T09:59:41.85117544Z stdout: "headers": { 2017-08-10T09:59:41.851177892Z stdout: "server": "nginx/1.11.13", 2017-08-10T09:59:41.851180284Z stdout: "date": "Thu, 10 Aug 2017 09:59:41 GMT", 2017-08-10T09:59:41.851182731Z stdout: "content-type": "text/plain",
[GitHub] underwoodb-sd-ibm commented on issue #2326: Alphabetize listings in CLI
underwoodb-sd-ibm commented on issue #2326: Alphabetize listings in CLI URL: https://github.com/apache/incubator-openwhisk/pull/2326#issuecomment-321532534 @rabbah, test has been moved to `WskBasicUsageTests`. Please confirm where I put it in the test is satisfactory, and if so, I'll tag Carlos for merging. 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] underwoodb-sd-ibm commented on issue #2490: CLI summaries for actions without annotations
underwoodb-sd-ibm commented on issue #2490: CLI summaries for actions without annotations URL: https://github.com/apache/incubator-openwhisk/pull/2490#issuecomment-321532624 @rabbah, test has been moved to WskBasicUsageTests. Please confirm where I put it in the test is satisfactory, and if so, I'll tag Carlos for merging. Thanks! 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] underwoodb-sd-ibm commented on issue #2424: Allow optional leading slash in CLI commands
underwoodb-sd-ibm commented on issue #2424: Allow optional leading slash in CLI commands URL: https://github.com/apache/incubator-openwhisk/pull/2424#issuecomment-321532783 @rabbah, tests have been moved to WskBasicUsageTests. Please confirm where I put it in the test is satisfactory, and if so, I'll tag Carlos for merging. Thanks! 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] underwoodb-sd-ibm commented on issue #2326: Alphabetize listings in CLI
underwoodb-sd-ibm commented on issue #2326: Alphabetize listings in CLI URL: https://github.com/apache/incubator-openwhisk/pull/2326#issuecomment-321532534 @rabbah, test has been moved to `WskBasicUsageTests`. Please confirm where I put it in the test is satisfactory, and if so, I'll tag Carlos for merging. 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] csantanapr closed pull request #93: Sync openwhisk
csantanapr closed pull request #93: Sync openwhisk URL: https://github.com/apache/incubator-openwhisk-cli/pull/93 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] xingzhou commented on issue #43: WIP: configure/deploy via helm charts
xingzhou commented on issue #43: WIP: configure/deploy via helm charts URL: https://github.com/apache/incubator-openwhisk-deploy-kube/pull/43#issuecomment-321723470 yeap, I agree. But anyway, we would still look forward to working out a separate charts deployment solution first, please let me know the developer's id so that we can have some conversation over this topic, thank you. 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 issue #2567: Openwhisk Local Installation on Ubuntu 14 Failed !!! Please help
rabbah commented on issue #2567: Openwhisk Local Installation on Ubuntu 14 Failed !!! Please help URL: https://github.com/apache/incubator-openwhisk/issues/2567#issuecomment-321723909 If you dont want to use -i, you can create signed certificate (cerbot?). @ningyougang @style95 might have other suggestions. 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] zachschultz commented on issue #291: Do not print "Done!" after deployment phase; use only success/failure (binary)
zachschultz commented on issue #291: Do not print "Done!" after deployment phase; use only success/failure (binary) URL: https://github.com/apache/incubator-openwhisk-wskdeploy/issues/291#issuecomment-321646359 For Blueprints work this would be very helpful, when my wskdeploy action runs on OW it's hard to handle the case where a trigger wasn't deployed if it existed already, as the overall result from wskdeploy is still "Done!..." 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 closed pull request #2326: Alphabetize listings in CLI
rabbah closed pull request #2326: Alphabetize listings in CLI URL: https://github.com/apache/incubator-openwhisk/pull/2326 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] lzbj commented on issue #315: Use case of trigger rule does not configure the pramters of the action with the correct values
lzbj commented on issue #315: Use case of trigger rule does not configure the pramters of the action with the correct values URL: https://github.com/apache/incubator-openwhisk-wskdeploy/issues/315#issuecomment-321714940 Ok, I'll take a look once I finished current bugs fix. 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 closed issue #2270: wsk action get --summary only works for actions with annotations
rabbah closed issue #2270: wsk action get --summary only works for actions with annotations URL: https://github.com/apache/incubator-openwhisk/issues/2270 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 closed pull request #2424: Allow optional leading slash in CLI commands
rabbah closed pull request #2424: Allow optional leading slash in CLI commands URL: https://github.com/apache/incubator-openwhisk/pull/2424 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 closed issue #2328: CLI support fully qualified name with 3 parts with no leading slash.
rabbah closed issue #2328: CLI support fully qualified name with 3 parts with no leading slash. URL: https://github.com/apache/incubator-openwhisk/issues/2328 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 #2326: Alphabetize listings in CLI
rabbah commented on a change in pull request #2326: Alphabetize listings in CLI URL: https://github.com/apache/incubator-openwhisk/pull/2326#discussion_r132605989 ## File path: tests/src/test/scala/whisk/core/cli/test/WskBasicUsageTests.scala ## @@ -959,6 +959,141 @@ class WskBasicUsageTests }, 5, Some(1 second)) } +it should "return a list of alphabetized actions" in withAssetCleaner(wskprops) { +(wp, assetHelper) => +// Declare 4 actions, create them out of alphabetical order +val actionName = "actionAlphaTest" +for (i <- 1 to 3) { +val name = s"$actionName$i" +assetHelper.withCleaner(wsk.action, name) { +(action, name) => +action.create(name, defaultAction) +} +} +retry({ +val original = wsk.action.list(nameSort = Some(true)).stdout +// Create list with action names in correct order +val scalaSorted = List(s"${actionName}1", s"${actionName}2", s"${actionName}3") +// Filter out everything not previously created +val regex = s"${actionName}[1-3]".r +// Retrieve action names into list as found in original +val list = (regex.findAllMatchIn(original)).toList +scalaSorted.toString shouldEqual list.toString Review comment: i'm guessing `.toString` here isn't necessary. 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] pritidesai commented on a change in pull request #298: Fix Parameter Resolution (both schema) & documentation for the triggerrule use case
pritidesai commented on a change in pull request #298: Fix Parameter Resolution (both schema) & documentation for the triggerrule use case URL: https://github.com/apache/incubator-openwhisk-wskdeploy/pull/298#discussion_r132602321 ## File path: parsers/manifest_parser.go ## @@ -403,19 +425,151 @@ func (action *Action) ComposeWskAction(manipath string) (*whisk.Action, error) { return wskaction, err } -// Resolve parameter input -func ResolveParameter(param *Parameter) interface{} { - value := utils.GetEnvVar(param.Value) + +// TODO(): Support other valid Package Manifest types +// TODO(): i.e., json (valid), timestamp, version, string256, string64, string16 +// TODO(): Support JSON schema validation for type: json +// TODO(): Support OpenAPI schema validation + +var validParameterNameMap = map[string]string{ + "string": "string", + "int": "integer", + "float": "float", + "bool": "boolean", + "int8": "integer", + "int16": "integer", + "int32": "integer", + "int64": "integer", + "float32": "float", + "float64": "float", +} + + +var typeDefaultValueMap = map[string]interface{} { + "string": "", + "integer": 0, + "float": 0.0, + "boolean": false, + // TODO() Support these types + their validation + // timestamp + // null + // version + // string256 + // string64 + // string16 + // json + // scalar-unit + // schema + // object +} + +func isValidParameterType(typeName string) bool { + _, isValid := typeDefaultValueMap[typeName] + return isValid +} + +// TODO(): throw errors +func getTypeDefaultValue(typeName string) interface{} { + + if val, ok := typeDefaultValueMap[typeName]; ok { + return val + } else { + // TODO() throw an error "type not found" + } +return nil +} + +func ResolveParamTypeFromValue(value interface{}) (string, error) { +// Note: string is the default type if not specified. + var paramType string = "string" + var err error = nil + + if value != nil { + actualType := reflect.TypeOf(value).Kind().String() + + // See if the actual type of the value is valid + if normalizedTypeName, found := validParameterNameMap[actualType]; found { + // use the full spec. name + paramType = normalizedTypeName + + } else { + // raise an error if param is not a known type + err = utils.NewParserErr("",-1, "Parameter value is not a known type. [" + actualType + "]") + } + } else { + + // TODO: The value may be supplied later, we need to support non-fatal warnings + // raise an error if param is nil + //err = utils.NewParserErr("",-1,"Paramter value is nil.") + } + return paramType, err +} + +// Resolve input parameter (i.e., type, value, default) +// Note: parameter values may set later (overriddNen) by an (optional) Deployment file +func ResolveParameter(paramName string, param *Parameter) (interface{}, error) { + + var errorParser error + var tempType string + // default parameter value to empty string + var value interface{} = "" + + // Trace Parameter struct before any resolution + //dumpParameter(paramName, param, "BEFORE") + + // Parameters can be single OR multi-line declarations which must be processed/validated differently + if !param.multiline { + // we have a single-line parameter declaration + // We need to identify parameter Type here for later validation + param.Type, errorParser = ResolveParamTypeFromValue(param.Value) + + } else { + // we have a multi-line parameter declaration + + // if we do not have a value, but have a default, use it for the value +if param.Value == nil && param.Default !=nil { + param.Value = param.Default + } + + // if we also have a type at this point, verify value (and/or default) matches type, if not error + // Note: if either the value or default is in conflict with the type then this is an error + tempType, errorParser = ResolveParamTypeFromValue(param.Value) Review comment: Here the comment says error should be thrown if we have a mismatch of specified "type" and "type" of the value. Try running it with an example of Parameter{Value: 11, Type: string}. ResolveParamTypeFromValue(11) determines the normalized type name which is "integer" and sets tempType to "integer". There is no check on actualType and type of the value done. This is how struct Parameter looks like: ``` (*parsers.Parameter)(0xc420163570)({ Type: (string) (len=6)
[GitHub] drcariel commented on issue #2591: User-Agent CLI/version header
drcariel commented on issue #2591: User-Agent CLI/version header URL: https://github.com/apache/incubator-openwhisk/pull/2591#issuecomment-321714021 PG2~1937 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 #2591: User-Agent CLI/version header
rabbah commented on a change in pull request #2591: User-Agent CLI/version header URL: https://github.com/apache/incubator-openwhisk/pull/2591#discussion_r132605285 ## File path: core/controller/src/main/scala/whisk/core/controller/WebActions.scala ## @@ -326,7 +326,7 @@ trait WhiskWebActionsApi private val defaultCorsResponse = List( `Access-Control-Allow-Origin`(AllOrigins), `Access-Control-Allow-Methods`(OPTIONS, GET, DELETE, POST, PUT, HEAD, PATCH), -`Access-Control-Allow-Headers`(`Authorization`.name, `Content-Type`.name)) +`Access-Control-Allow-Headers`(`Authorization`.name, `Content-Type`.name, `User-Agent`.name)) Review comment: do we want this for a web action? 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 #2591: User-Agent CLI/version header
rabbah commented on a change in pull request #2591: User-Agent CLI/version header URL: https://github.com/apache/incubator-openwhisk/pull/2591#discussion_r132605304 ## File path: core/controller/src/main/scala/whisk/core/controller/RestAPIs.scala ## @@ -121,7 +121,7 @@ protected[controller] object RestApiCommons { */ protected[controller] trait RespondWithHeaders extends Directives { val allowOrigin = `Access-Control-Allow-Origin`(AllOrigins) -val allowHeaders = `Access-Control-Allow-Headers`("Authorization", "Content-Type") +val allowHeaders = `Access-Control-Allow-Headers`("Authorization", "Content-Type", "User-Agent") Review comment: what is the value of the controller accepting the user-agent? should nginx just drop this header? 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 #2591: User-Agent CLI/version header
rabbah commented on a change in pull request #2591: User-Agent CLI/version header URL: https://github.com/apache/incubator-openwhisk/pull/2591#discussion_r132605304 ## File path: core/controller/src/main/scala/whisk/core/controller/RestAPIs.scala ## @@ -121,7 +121,7 @@ protected[controller] object RestApiCommons { */ protected[controller] trait RespondWithHeaders extends Directives { val allowOrigin = `Access-Control-Allow-Origin`(AllOrigins) -val allowHeaders = `Access-Control-Allow-Headers`("Authorization", "Content-Type") +val allowHeaders = `Access-Control-Allow-Headers`("Authorization", "Content-Type", "User-Agent") Review comment: what is the value of the controller accepting the user-agent header? should nginx just drop this header? 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 closed pull request #2599: Remove the additional ansible script in deploy for local CLI mode
rabbah closed pull request #2599: Remove the additional ansible script in deploy for local CLI mode URL: https://github.com/apache/incubator-openwhisk/pull/2599 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 closed pull request #2490: CLI summaries for actions without annotations
rabbah closed pull request #2490: CLI summaries for actions without annotations URL: https://github.com/apache/incubator-openwhisk/pull/2490 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] zhy989 commented on issue #210: How to use message feed
zhy989 commented on issue #210: How to use message feed URL: https://github.com/apache/incubator-openwhisk-package-kafka/issues/210#issuecomment-321508475 @bjustin-ibm thanks in case 1: Should I register a new accoun on the local host for message hub? in case 2: I tried this CLI "wsk trigger create MyKafkaTrigger -f /whisk.system/messaging/kafkaFeed -p brokers "mykafkahost:9092,mykafkahost:9093" -p topic mytopic -p isJSONData true -i", and got the same error - wsk trigger create MyKafkaTrigger -f /whisk.system/messaging/kafkaFeed -p brokers "mykafkahost:9092,mykafkahost:9093" -p topic mytopic -p isJSONData true -i ok: invoked /whisk.system/messaging/kafkaFeed with id fff3cab0fde142e98ac81ba3a98db38c { "activationId": "fff3cab0fde142e98ac81ba3a98db38c", "annotations": [ { "key": "limits", "value": { "logs": 10, "memory": 256, "timeout": 6 } }, { "key": "path", "value": "whisk.system/messaging/kafkaFeed" } ], "duration": 991, "end": 1502359181855, "logs": [], "name": "kafkaFeed", "namespace": "whisk.system", "publish": false, "response": { "result": { "error": "Error: error happened in your connection" }, "status": "application error", "success": false }, "start": 1502359180864, "subject": "whisk.system", "version": "0.0.2" } ok: invoked /whisk.system/messaging/kafkaFeed with id c0cb00c7f1964151a2aabd5f35ef8d4f { "activationId": "c0cb00c7f1964151a2aabd5f35ef8d4f", "annotations": [ { "key": "limits", "value": { "logs": 10, "memory": 256, "timeout": 6 } }, { "key": "path", "value": "whisk.system/messaging/kafkaFeed" } ], "duration": 501, "end": 1502359182811, "logs": [], "name": "kafkaFeed", "namespace": "whisk.system", "publish": false, "response": { "result": {}, "status": "success", "success": true }, "start": 1502359182310, "subject": "whisk.system", "version": "0.0.2" } ok: deleted trigger MyKafkaTrigger - wsk -i activation logs fff3cab0fde142e98ac81ba3a98db38c 2017-08-10T09:59:41.851044685Z stdout: Error creating trigger: { 2017-08-10T09:59:41.851069919Z stdout: "name": "StatusCodeError", 2017-08-10T09:59:41.851073662Z stdout: "statusCode": 500, 2017-08-10T09:59:41.851076502Z stdout: "message": "500 - \"Error: error happened in your connection\"", 2017-08-10T09:59:41.851081688Z stdout: "error": "Error: error happened in your connection", 2017-08-10T09:59:41.851084534Z stdout: "options": { 2017-08-10T09:59:41.851087266Z stdout: "method": "PUT", 2017-08-10T09:59:41.851090286Z stdout: "url": "https://172.17.0.1/api/v1/web/whisk.system/messagingWeb/kafkaFeedWeb.http;, 2017-08-10T09:59:41.85109325Z stdout: "rejectUnauthorized": false, 2017-08-10T09:59:41.851095837Z stdout: "json": true, 2017-08-10T09:59:41.851098218Z stdout: "body": { 2017-08-10T09:59:41.851100973Z stdout: "authKey": "789c46b1-71f6-4ed5-8c54-816aa4f8c502:abczO3xZCLrMN6v2BKK1dXYFpXlPkccOFqm12CdAsMgRU4VrNZ9lyGVCGuMDGIwP", 2017-08-10T09:59:41.851103755Z stdout: "isJSONData": true, 2017-08-10T09:59:41.851107298Z stdout: "brokers": "mykafkahost:9092,mykafkahost:9093", 2017-08-10T09:59:41.851109876Z stdout: "topic": "mytopic", 2017-08-10T09:59:41.851112397Z stdout: "triggerName": "/whisk.system/MyKafkaTrigger" 2017-08-10T09:59:41.851115008Z stdout: }, 2017-08-10T09:59:41.851117353Z stdout: "headers": { 2017-08-10T09:59:41.851119788Z stdout: "Content-Type": "application/json", 2017-08-10T09:59:41.851122322Z stdout: "Accept": "text/plain", 2017-08-10T09:59:41.851150998Z stdout: "User-Agent": "whisk" 2017-08-10T09:59:41.851155301Z stdout: }, 2017-08-10T09:59:41.851157521Z stdout: "simple": true, 2017-08-10T09:59:41.851160009Z stdout: "resolveWithFullResponse": false, 2017-08-10T09:59:41.851162485Z stdout: "transform2xxOnly": false 2017-08-10T09:59:41.851164913Z stdout: }, 2017-08-10T09:59:41.851167255Z stdout: "response": { 2017-08-10T09:59:41.851170448Z stdout: "statusCode": 500, 2017-08-10T09:59:41.851172917Z stdout: "body": "Error: error happened in your connection", 2017-08-10T09:59:41.85117544Z stdout: "headers": { 2017-08-10T09:59:41.851177892Z stdout: "server": "nginx/1.11.13", 2017-08-10T09:59:41.851180284Z stdout: "date": "Thu, 10 Aug 2017 09:59:41 GMT", 2017-08-10T09:59:41.851182731Z stdout: "content-type": "text/plain",
[GitHub] bjustin-ibm commented on issue #210: How to use message feed
bjustin-ibm commented on issue #210: How to use message feed URL: https://github.com/apache/incubator-openwhisk-package-kafka/issues/210#issuecomment-321523192 Please keep in mind that this feed provider (the code in this repo) interacts with an external service - either a Message Hub instance or generic Kafka cluster. This feed provider cannot work without having the external service created and in working order. Following the [README](https://github.com/apache/incubator-openwhisk-package-kafka/blob/master/README.md) and running the example commands (which only have example parameter values) will almost definitely not work without being changed so that the parameter values match your specific instance of Kafka or Message Hub. I suggest you first become familiar with Kafka and/or Message Hub before attempting to run this software. > Should I register a new account on the local host for message hub? Message Hub is the name of a service hosted in IBM Bluemix. It is essentially Bluemix-hosted Kafka, and is not something you can run locally. Please see the following for details: https://developer.ibm.com/messaging/message-hub/ > Should I start up the catalog_kafkatrigger container before create the trigger ? if do and how to start up that container? Yes, if you are trying to build and run your own instance of the feed provider service, please carefully follow this development guide: https://github.com/bjustin-ibm/openwhisk-package-kafka/blob/1aa6ae1684930d5175fa0ce36886b2e7db123248/devGuide.md However, please be sure you have a working Kafka or Message Hub instance created, configured, tested, and working before attempting this. 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] underwoodb-sd-ibm commented on issue #2326: Alphabetize listings in CLI
underwoodb-sd-ibm commented on issue #2326: Alphabetize listings in CLI URL: https://github.com/apache/incubator-openwhisk/pull/2326#issuecomment-321536578 @dubeejw - please confirm that the issue you raised with the ToHeaderString() functions have been addressed properly? Thanks 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] zhy989 commented on issue #210: How to use message feed
zhy989 commented on issue #210: How to use message feed URL: https://github.com/apache/incubator-openwhisk-package-kafka/issues/210#issuecomment-321536519 @bjustin-ibm thanks in case 1 - Setting up a Message Hub package outside Bluemix Is this install Message Hub package on the local host outside Bluemix? I can sign in Bluemix with my username and password, why can not authenticate with Message Hub with the same username and password when I run the CLI "wsk -i trigger create MyMessageHubTrigger -f myMessageHub/messageHubFeed -p topic mytopic -p isJSONData true -p"? 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] tysonnorris commented on a change in pull request #2584: SPI for Loadbalancer
tysonnorris commented on a change in pull request #2584: SPI for Loadbalancer URL: https://github.com/apache/incubator-openwhisk/pull/2584#discussion_r132442155 ## File path: common/scala/src/main/scala/whisk/core/database/CouchDbStoreProvider.scala ## @@ -18,16 +18,18 @@ package whisk.core.database import akka.actor.ActorSystem +import scala.collection.mutable import spray.json.RootJsonFormat import whisk.common.Logging import whisk.core.WhiskConfig import whisk.spi.Dependencies -import whisk.spi.SpiFactory +import whisk.spi.SingletonSpiFactory /** * A CouchDB implementation of ArtifactStoreProvider */ class CouchDbStoreProvider extends ArtifactStoreProvider { +protected[database] val stores = mutable.Map [String, CouchDbRestStore[_]]() Review comment: yes 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] zhy989 commented on issue #210: How to use message feed
zhy989 commented on issue #210: How to use message feed URL: https://github.com/apache/incubator-openwhisk-package-kafka/issues/210#issuecomment-321536519 @bjustin-ibm thanks in case 1 - Setting up a Message Hub package outside Bluemix Is this install Message Hub package on the local host outside Bluemix? I can sign in Bluemix with my username and password, why can not authenticate with Message Hub with the same username and password when I run the CLI "wsk -i trigger create MyMessageHubTrigger -f myMessageHub/messageHubFeed -p topic mytopic -p isJSONData true -p"? in case 2 I try to run the example for "https://github.com/bjustin-ibm/openwhisk-package-kafka/blob/1aa6ae1684930d5175fa0ce36886b2e7db123248/devGuide.md; I can create docker image kafkafeedprovider successfully but when I run script docker_run.sh, there is an error: - cat docker_run.sh WSK_HOME=/openwhisk DB_PROTOCOL=`awk -F "=" '/db_protocol/ {print $2}' $WSK_HOME/ansible/db_local.ini` DB_HOST=`awk -F "=" '/db_host/ {print $2}' $WSK_HOME/ansible/db_local.ini` DB_PORT=`awk -F "=" '/db_port/ {print $2}' $WSK_HOME/ansible/db_local.ini` DB_USER=`awk -F "=" '/db_username/ {print $2}' $WSK_HOME/ansible/db_local.ini` DB_PWD=`awk -F "=" '/db_password/ {print $2}' $WSK_HOME/ansible/db_local.ini` DB_PREFIX=test docker run -e DB_URL="https://172.17.0.1:5984; -e DB_USER=$DB_USER -e DB_PASS=$DB_PWD -p 81:5000 kafkafeedprovider - Traceback (most recent call last): File "app.py", line 24, in from consumer import Consumer File "/KafkaFeedProvider/consumer.py", line 24, in from database import Database File "/KafkaFeedProvider/database.py", line 23, in class Database: File "/KafkaFeedProvider/database.py", line 26, in Database username = os.environ['CLOUDANT_USER'] File "/usr/lib/python2.7/UserDict.py", line 40, in __getitem__ raise KeyError(key) KeyError: 'CLOUDANT_USER' In here it must be CLOUDANT_USER ? couchdb_user can not ? 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