[GitHub] tysonnorris commented on a change in pull request #3812: ContainerClient + akka http alternative to HttpUtils

2018-07-16 Thread GitBox
tysonnorris commented on a change in pull request #3812: ContainerClient + akka 
http alternative to HttpUtils
URL: 
https://github.com/apache/incubator-openwhisk/pull/3812#discussion_r202899653
 
 

 ##
 File path: 
common/scala/src/main/scala/whisk/core/containerpool/ContainerClient.scala
 ##
 @@ -0,0 +1,213 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package whisk.core.containerpool
+
+import akka.actor.ActorSystem
+import akka.http.scaladsl.marshallers.sprayjson.SprayJsonSupport._
+import akka.http.scaladsl.marshalling.Marshal
+import akka.http.scaladsl.model.HttpMethods
+import akka.http.scaladsl.model.HttpRequest
+import akka.http.scaladsl.model.HttpResponse
+import akka.http.scaladsl.model.MessageEntity
+import akka.http.scaladsl.model.StatusCodes
+import akka.http.scaladsl.model.headers.Connection
+import akka.http.scaladsl.unmarshalling.Unmarshal
+import akka.stream.StreamTcpException
+import akka.stream.scaladsl.Sink
+import akka.stream.scaladsl.Source
+import akka.util.ByteString
+import scala.concurrent.Await
+import scala.concurrent.ExecutionContext
+import scala.concurrent.Future
+import scala.concurrent.TimeoutException
+import scala.concurrent.duration._
+import scala.util.Try
+import scala.util.control.NonFatal
+import spray.json._
+import whisk.common.Logging
+import whisk.common.TransactionId
+import whisk.core.entity.ActivationResponse.ContainerHttpError
+import whisk.core.entity.ActivationResponse._
+import whisk.core.entity.ByteSize
+import whisk.core.entity.size.SizeLong
+import whisk.http.PoolingRestClient
+
+trait ContainerClient {
+  def close(): Unit
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId): Future[Either[ContainerHttpError, 
ContainerResponse]]
+
+}
+
+/**
+ * This HTTP client is used only in the invoker to communicate with the action 
container.
+ * It allows to POST a JSON object and receive JSON object back; that is the
+ * content type and the accept headers are both 'application/json.
+ * The reason we still use this class for the action container is a mysterious 
hang
+ * in the Akka http client where a future fails to properly timeout and we 
have not
+ * determined why that is.
+ *
+ * @param hostname the host name
+ * @param timeout the timeout in msecs to wait for a response
+ * @param maxResponse the maximum size in bytes the connection will accept
+ * @param queueSize once all connections are used, how big of queue to allow 
for additional requests
+ * @param retryInterval duration between retries for TCP connection errors
+ */
+protected class PoolingContainerClient(
+  hostname: String,
+  port: Int,
+  timeout: FiniteDuration,
+  maxResponse: ByteSize,
+  queueSize: Int,
+  retryInterval: FiniteDuration = 100.milliseconds)(implicit logging: Logging, 
as: ActorSystem)
+extends PoolingRestClient("http", hostname, port, queueSize, timeout = 
Some(timeout))
+with ContainerClient
+with AutoCloseable {
+
+  def close() = shutdown()
+
+  /**
+   * Posts to hostname/endpoint the given JSON object.
+   * Waits up to timeout before aborting on a good connection.
+   * If the endpoint is not ready, retry up to timeout.
+   * Every retry reduces the available timeout so that this method should not
+   * wait longer than the total timeout (within a small slack allowance).
+   *
+   * @param endpoint the path the api call relative to hostname
+   * @param body the JSON value to post (this is usually a JSON objecT)
+   * @param retry whether or not to retry on connection failure
+   * @return Left(Error Message) or Right(Status Code, Response as UTF-8 
String)
+   */
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId): Future[Either[ContainerHttpError, 
ContainerResponse]] = {
+
+//create the request
+val req = Marshal(body).to[MessageEntity].map { b =>
+  //DO NOT reuse the connection (in case of paused containers)
+  //For details on Connection: Close handling, see:
+  // - 
https://doc.akka.io/docs/akka-http/current/common/http-model.html#http-headers
+  // - 

[GitHub] codecov-io edited a comment on issue #3812: ContainerClient + akka http alternative to HttpUtils

2018-07-16 Thread GitBox
codecov-io edited a comment on issue #3812: ContainerClient + akka http 
alternative to HttpUtils
URL: 
https://github.com/apache/incubator-openwhisk/pull/3812#issuecomment-401212372
 
 
   # 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=h1)
 Report
   > Merging 
[#3812](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=desc)
 into 
[master](https://codecov.io/gh/apache/incubator-openwhisk/commit/e96c1bbd5a0f54c923f0153116f7c1f165275e94?src=pr=desc)
 will **decrease** coverage by `4.6%`.
   > The diff coverage is `55.55%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/graphs/tree.svg?token=l0YmsiSAso=650=pr=150)](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=tree)
   
   ```diff
   @@Coverage Diff @@
   ##   master#3812  +/-   ##
   ==
   - Coverage   75.78%   71.17%   -4.61% 
   ==
 Files 145  146   +1 
 Lines6897 6939  +42 
 Branches  418  432  +14 
   ==
   - Hits 5227 4939 -288 
   - Misses   1670 2000 +330
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=tree)
 | Coverage Δ | |
   |---|---|---|
   | 
[...containerpool/kubernetes/KubernetesContainer.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29yZS9pbnZva2VyL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9rdWJlcm5ldGVzL0t1YmVybmV0ZXNDb250YWluZXIuc2NhbGE=)
 | `91.66% <ø> (ø)` | :arrow_up: |
   | 
[...la/whisk/core/containerpool/ContainerFactory.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9Db250YWluZXJGYWN0b3J5LnNjYWxh)
 | `100% <ø> (ø)` | :arrow_up: |
   | 
[...la/src/main/scala/whisk/core/mesos/MesosTask.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvbWVzb3MvTWVzb3NUYXNrLnNjYWxh)
 | `86.11% <ø> (ø)` | :arrow_up: |
   | 
[...sk/core/containerpool/docker/DockerContainer.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29yZS9pbnZva2VyL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9kb2NrZXIvRG9ja2VyQ29udGFpbmVyLnNjYWxh)
 | `79.16% <0%> (+2.13%)` | :arrow_up: |
   | 
[.../src/main/scala/whisk/http/PoolingRestClient.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2h0dHAvUG9vbGluZ1Jlc3RDbGllbnQuc2NhbGE=)
 | `90.9% <100%> (+1.62%)` | :arrow_up: |
   | 
[...n/scala/whisk/core/database/CouchDbRestStore.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvQ291Y2hEYlJlc3RTdG9yZS5zY2FsYQ==)
 | `73.23% <100%> (ø)` | :arrow_up: |
   | 
[...ain/scala/whisk/core/containerpool/HttpUtils.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9IdHRwVXRpbHMuc2NhbGE=)
 | `69.81% <14.28%> (+18.9%)` | :arrow_up: |
   | 
[...ain/scala/whisk/core/containerpool/Container.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9Db250YWluZXIuc2NhbGE=)
 | `76.56% <25%> (+0.37%)` | :arrow_up: |
   | 
[...ala/whisk/core/containerpool/ContainerClient.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9Db250YWluZXJDbGllbnQuc2NhbGE=)
 | `67.5% <67.5%> (ø)` | |
   | 
[...core/database/cosmosdb/RxObservableImplicits.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvUnhPYnNlcnZhYmxlSW1wbGljaXRzLnNjYWxh)
 | `0% <0%> (-100%)` | :arrow_down: |
   | ... and [7 
more](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree-more)
 | |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=continue).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=footer).
 Last update 
[e96c1bb...fb0b337](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=lastupdated).
 Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


[GitHub] tysonnorris commented on a change in pull request #3812: ContainerClient + akka http alternative to HttpUtils

2018-07-16 Thread GitBox
tysonnorris commented on a change in pull request #3812: ContainerClient + akka 
http alternative to HttpUtils
URL: 
https://github.com/apache/incubator-openwhisk/pull/3812#discussion_r202899222
 
 

 ##
 File path: 
common/scala/src/main/scala/whisk/core/containerpool/ContainerClient.scala
 ##
 @@ -0,0 +1,212 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package whisk.core.containerpool
+
+import akka.actor.ActorSystem
+import akka.http.scaladsl.marshallers.sprayjson.SprayJsonSupport._
+import akka.http.scaladsl.marshalling.Marshal
+import akka.http.scaladsl.model.HttpMethods
+import akka.http.scaladsl.model.HttpRequest
+import akka.http.scaladsl.model.HttpResponse
+import akka.http.scaladsl.model.MessageEntity
+import akka.http.scaladsl.model.StatusCodes
+import akka.http.scaladsl.model.headers.Connection
+import akka.http.scaladsl.unmarshalling.Unmarshal
+import akka.stream.StreamTcpException
+import akka.stream.scaladsl.Sink
+import akka.stream.scaladsl.Source
+import akka.util.ByteString
+import scala.concurrent.Await
+import scala.concurrent.ExecutionContext
+import scala.concurrent.Future
+import scala.concurrent.TimeoutException
+import scala.concurrent.duration._
+import scala.util.Try
+import spray.json._
+import whisk.common.Logging
+import whisk.common.TransactionId
+import whisk.core.entity.ActivationResponse.ContainerHttpError
+import whisk.core.entity.ActivationResponse._
+import whisk.core.entity.ByteSize
+import whisk.core.entity.size.SizeLong
+import whisk.http.PoolingRestClient
+
+trait ContainerClient {
+  def close(): Unit
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId): Future[Either[ContainerHttpError, 
ContainerResponse]]
+
+}
+
+/**
+ * This HTTP client is used only in the invoker to communicate with the action 
container.
+ * It allows to POST a JSON object and receive JSON object back; that is the
+ * content type and the accept headers are both 'application/json.
+ * The reason we still use this class for the action container is a mysterious 
hang
+ * in the Akka http client where a future fails to properly timeout and we 
have not
+ * determined why that is.
+ *
+ * @param hostname the host name
+ * @param timeout the timeout in msecs to wait for a response
+ * @param maxResponse the maximum size in bytes the connection will accept
+ * @param queueSize once all connections are used, how big of queue to allow 
for additional requests
+ * @param retryInterval duration between retries for TCP connection errors
+ */
+protected class PoolingContainerClient(
+  hostname: String,
+  port: Int,
+  timeout: FiniteDuration,
+  maxResponse: ByteSize,
+  queueSize: Int,
+  retryInterval: FiniteDuration = 100.milliseconds)(implicit logging: Logging, 
as: ActorSystem)
+extends PoolingRestClient("http", hostname, port, queueSize, timeout = 
Some(timeout))
+with ContainerClient
+with AutoCloseable {
+
+  def close() = shutdown()
+
+  /**
+   * Posts to hostname/endpoint the given JSON object.
+   * Waits up to timeout before aborting on a good connection.
+   * If the endpoint is not ready, retry up to timeout.
+   * Every retry reduces the available timeout so that this method should not
+   * wait longer than the total timeout (within a small slack allowance).
+   *
+   * @param endpoint the path the api call relative to hostname
+   * @param body the JSON value to post (this is usually a JSON objecT)
+   * @param retry whether or not to retry on connection failure
+   * @return Left(Error Message) or Right(Status Code, Response as UTF-8 
String)
+   */
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId): Future[Either[ContainerHttpError, 
ContainerResponse]] = {
+
+//create the request
+val req = Marshal(body).to[MessageEntity].map { b =>
+  //DO NOT reuse the connection (in case of paused containers)
+  //For details on Connection: Close handling, see:
+  // - 
https://doc.akka.io/docs/akka-http/current/common/http-model.html#http-headers
+  // - 

[GitHub] chetanmeh commented on a change in pull request #3812: ContainerClient + akka http alternative to HttpUtils

2018-07-16 Thread GitBox
chetanmeh commented on a change in pull request #3812: ContainerClient + akka 
http alternative to HttpUtils
URL: 
https://github.com/apache/incubator-openwhisk/pull/3812#discussion_r202896470
 
 

 ##
 File path: 
common/scala/src/main/scala/whisk/core/containerpool/ContainerClient.scala
 ##
 @@ -0,0 +1,212 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package whisk.core.containerpool
+
+import akka.actor.ActorSystem
+import akka.http.scaladsl.marshallers.sprayjson.SprayJsonSupport._
+import akka.http.scaladsl.marshalling.Marshal
+import akka.http.scaladsl.model.HttpMethods
+import akka.http.scaladsl.model.HttpRequest
+import akka.http.scaladsl.model.HttpResponse
+import akka.http.scaladsl.model.MessageEntity
+import akka.http.scaladsl.model.StatusCodes
+import akka.http.scaladsl.model.headers.Connection
+import akka.http.scaladsl.unmarshalling.Unmarshal
+import akka.stream.StreamTcpException
+import akka.stream.scaladsl.Sink
+import akka.stream.scaladsl.Source
+import akka.util.ByteString
+import scala.concurrent.Await
+import scala.concurrent.ExecutionContext
+import scala.concurrent.Future
+import scala.concurrent.TimeoutException
+import scala.concurrent.duration._
+import scala.util.Try
+import spray.json._
+import whisk.common.Logging
+import whisk.common.TransactionId
+import whisk.core.entity.ActivationResponse.ContainerHttpError
+import whisk.core.entity.ActivationResponse._
+import whisk.core.entity.ByteSize
+import whisk.core.entity.size.SizeLong
+import whisk.http.PoolingRestClient
+
+trait ContainerClient {
+  def close(): Unit
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId): Future[Either[ContainerHttpError, 
ContainerResponse]]
+
+}
+
+/**
+ * This HTTP client is used only in the invoker to communicate with the action 
container.
+ * It allows to POST a JSON object and receive JSON object back; that is the
+ * content type and the accept headers are both 'application/json.
+ * The reason we still use this class for the action container is a mysterious 
hang
+ * in the Akka http client where a future fails to properly timeout and we 
have not
+ * determined why that is.
+ *
+ * @param hostname the host name
+ * @param timeout the timeout in msecs to wait for a response
+ * @param maxResponse the maximum size in bytes the connection will accept
+ * @param queueSize once all connections are used, how big of queue to allow 
for additional requests
+ * @param retryInterval duration between retries for TCP connection errors
+ */
+protected class PoolingContainerClient(
+  hostname: String,
+  port: Int,
+  timeout: FiniteDuration,
+  maxResponse: ByteSize,
+  queueSize: Int,
+  retryInterval: FiniteDuration = 100.milliseconds)(implicit logging: Logging, 
as: ActorSystem)
+extends PoolingRestClient("http", hostname, port, queueSize, timeout = 
Some(timeout))
+with ContainerClient
+with AutoCloseable {
+
+  def close() = shutdown()
+
+  /**
+   * Posts to hostname/endpoint the given JSON object.
+   * Waits up to timeout before aborting on a good connection.
+   * If the endpoint is not ready, retry up to timeout.
+   * Every retry reduces the available timeout so that this method should not
+   * wait longer than the total timeout (within a small slack allowance).
+   *
+   * @param endpoint the path the api call relative to hostname
+   * @param body the JSON value to post (this is usually a JSON objecT)
+   * @param retry whether or not to retry on connection failure
+   * @return Left(Error Message) or Right(Status Code, Response as UTF-8 
String)
+   */
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId): Future[Either[ContainerHttpError, 
ContainerResponse]] = {
+
+//create the request
+val req = Marshal(body).to[MessageEntity].map { b =>
+  //DO NOT reuse the connection (in case of paused containers)
+  //For details on Connection: Close handling, see:
+  // - 
https://doc.akka.io/docs/akka-http/current/common/http-model.html#http-headers
+  // - 

[GitHub] chetanmeh commented on a change in pull request #3882: Use invoker id for metrics instead of the hostname.

2018-07-16 Thread GitBox
chetanmeh commented on a change in pull request #3882: Use invoker id for 
metrics instead of the hostname.
URL: 
https://github.com/apache/incubator-openwhisk/pull/3882#discussion_r202895597
 
 

 ##
 File path: core/invoker/src/main/scala/whisk/core/invoker/Invoker.scala
 ##
 @@ -125,6 +124,14 @@ object Invoker {
 
 new 
InstanceIdAssigner(config.zookeeperHosts).getId(invokerUniqueName.get)
   }
+
+// Replace the hostname of the invoker to the assigned id of the invoker.
+val newKamonConfig = Kamon.config
 
 Review comment:
   Nit can this be refactored to a method `initKamon(hostId:String)`. Further 
should this be moved to a util method in `whisk.common` such it is also used in 
Controller which also has this notion of id to identify 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] tysonnorris commented on a change in pull request #3812: ContainerClient + akka http alternative to HttpUtils

2018-07-16 Thread GitBox
tysonnorris commented on a change in pull request #3812: ContainerClient + akka 
http alternative to HttpUtils
URL: 
https://github.com/apache/incubator-openwhisk/pull/3812#discussion_r202895105
 
 

 ##
 File path: 
common/scala/src/main/scala/whisk/core/containerpool/ContainerClient.scala
 ##
 @@ -0,0 +1,240 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package whisk.core.containerpool
+
+import akka.actor.ActorSystem
+import akka.http.scaladsl.marshallers.sprayjson.SprayJsonSupport._
+import akka.http.scaladsl.marshalling.Marshal
+import akka.http.scaladsl.model.HttpMethods
+import akka.http.scaladsl.model.HttpRequest
+import akka.http.scaladsl.model.HttpResponse
+import akka.http.scaladsl.model.MessageEntity
+import akka.http.scaladsl.model.StatusCodes
+import akka.http.scaladsl.model.headers.Connection
+import akka.http.scaladsl.unmarshalling.Unmarshal
+import akka.stream.scaladsl.Sink
+import akka.stream.scaladsl.Source
+import akka.util.ByteString
+import scala.concurrent.Await
+import scala.concurrent.ExecutionContext
+import scala.concurrent.Future
+import scala.concurrent.Promise
+import scala.concurrent.TimeoutException
+import scala.concurrent.duration._
+import scala.util.Try
+import scala.util.control.NoStackTrace
+import spray.json._
+import whisk.common.Logging
+import whisk.common.TransactionId
+import whisk.core.entity.ActivationResponse.ContainerHttpError
+import whisk.core.entity.ActivationResponse._
+import whisk.core.entity.ByteSize
+import whisk.core.entity.size.SizeLong
+import whisk.http.PoolingRestClient
+
+trait ContainerClient {
+  def close(): Unit
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId): Future[Either[ContainerHttpError, 
ContainerResponse]]
+
+}
+
+/**
+ * This HTTP client is used only in the invoker to communicate with the action 
container.
+ * It allows to POST a JSON object and receive JSON object back; that is the
+ * content type and the accept headers are both 'application/json.
+ * The reason we still use this class for the action container is a mysterious 
hang
+ * in the Akka http client where a future fails to properly timeout and we 
have not
+ * determined why that is.
+ *
+ * @param hostname the host name
+ * @param timeout the timeout in msecs to wait for a response
+ * @param maxResponse the maximum size in bytes the connection will accept
+ * @param queueSize once all connections are used, how big of queue to allow 
for additional requests
+ * @param retryInterval duration between retries for TCP connection errors
+ */
+protected class PoolingContainerClient(
+  hostname: String,
+  port: Int,
+  timeout: FiniteDuration,
+  maxResponse: ByteSize,
+  queueSize: Int,
+  retryInterval: FiniteDuration = 100.milliseconds)(implicit logging: Logging, 
as: ActorSystem)
+extends PoolingRestClient("http", hostname, port, queueSize)
+with ContainerClient {
+
+  def close() = shutdown()
+
+  /**
+   * Posts to hostname/endpoint the given JSON object.
+   * Waits up to timeout before aborting on a good connection.
+   * If the endpoint is not ready, retry up to timeout.
+   * Every retry reduces the available timeout so that this method should not
+   * wait longer than the total timeout (within a small slack allowance).
+   *
+   * @param endpoint the path the api call relative to hostname
+   * @param body the JSON value to post (this is usually a JSON objecT)
+   * @param retry whether or not to retry on connection failure
+   * @return Left(Error Message) or Right(Status Code, Response as UTF-8 
String)
+   */
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId): Future[Either[ContainerHttpError, 
ContainerResponse]] = {
+
+//create the request
+val req = Marshal(body).to[MessageEntity].map { b =>
+  //DO NOT reuse the connection (in case of paused containers)
+  //For details on Connection: Close handling, see:
+  // - 
https://doc.akka.io/docs/akka-http/current/common/http-model.html#http-headers
+  // - 
http://github.com/akka/akka-http/tree/v10.1.3/akka-http-core/src/test/scala/akka/http/impl/engine/rendering/ResponseRendererSpec.scala#L470-L571
+  

[GitHub] StrayCat1 commented on issue #257: External zookeeper kafka

2018-07-16 Thread GitBox
StrayCat1 commented on issue #257: External zookeeper kafka
URL: 
https://github.com/apache/incubator-openwhisk-deploy-kube/pull/257#issuecomment-405451276
 
 
   I didn't document or test [the changes to 
_helpers.tpl](https://github.com/apache/incubator-openwhisk-deploy-kube/pull/257/commits/a14dddcdbe82806dfed7752d4c6faa1ec45a1f0a#diff-faa55e3a77183978b971e57a0ac048f2)
 well enough. 
   
   My use case includes deploying this OpenWhisk chart as dependency of another 
chart, so after  disabling the kafka and zookeeper defined in these charts, all 
I needed to do was define `kafka_host`, `zookeeper_connect`, and 
`zookeeper_zero_host` in my `_helpers.tpl`, but theoretically these changes 
would allow someone to deploy this chart into the same namespace as an existing 
zookeeper and kafka service by configuring their hostnames in `mycluster.yml` 
like this
   ```yaml
   kafka:
 external: true
 name: 
   
   zookeeper:
 external: true
 name: 
   ```


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] codecov-io edited a comment on issue #3812: ContainerClient + akka http alternative to HttpUtils

2018-07-16 Thread GitBox
codecov-io edited a comment on issue #3812: ContainerClient + akka http 
alternative to HttpUtils
URL: 
https://github.com/apache/incubator-openwhisk/pull/3812#issuecomment-401212372
 
 
   # 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=h1)
 Report
   > Merging 
[#3812](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=desc)
 into 
[master](https://codecov.io/gh/apache/incubator-openwhisk/commit/4a0b4cdc595abe9acd8cdd68b56ac440ea443bc9?src=pr=desc)
 will **decrease** coverage by `3.25%`.
   > The diff coverage is `58.75%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/graphs/tree.svg?height=150=650=l0YmsiSAso=pr)](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=tree)
   
   ```diff
   @@Coverage Diff @@
   ##   master#3812  +/-   ##
   ==
   - Coverage   74.45%   71.19%   -3.26% 
   ==
 Files 137  146   +9 
 Lines6471 6947 +476 
 Branches  408  429  +21 
   ==
   + Hits 4818 4946 +128 
   - Misses   1653 2001 +348
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=tree)
 | Coverage Δ | |
   |---|---|---|
   | 
[...la/whisk/core/containerpool/ContainerFactory.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9Db250YWluZXJGYWN0b3J5LnNjYWxh)
 | `100% <ø> (ø)` | :arrow_up: |
   | 
[...containerpool/kubernetes/KubernetesContainer.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29yZS9pbnZva2VyL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9rdWJlcm5ldGVzL0t1YmVybmV0ZXNDb250YWluZXIuc2NhbGE=)
 | `91.66% <ø> (ø)` | :arrow_up: |
   | 
[...la/src/main/scala/whisk/core/mesos/MesosTask.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvbWVzb3MvTWVzb3NUYXNrLnNjYWxh)
 | `86.11% <ø> (ø)` | :arrow_up: |
   | 
[...sk/core/containerpool/docker/DockerContainer.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29yZS9pbnZva2VyL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9kb2NrZXIvRG9ja2VyQ29udGFpbmVyLnNjYWxh)
 | `79.16% <0%> (+2.13%)` | :arrow_up: |
   | 
[...n/scala/whisk/core/database/CouchDbRestStore.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvQ291Y2hEYlJlc3RTdG9yZS5zY2FsYQ==)
 | `73.23% <100%> (ø)` | :arrow_up: |
   | 
[.../src/main/scala/whisk/http/PoolingRestClient.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2h0dHAvUG9vbGluZ1Jlc3RDbGllbnQuc2NhbGE=)
 | `90.9% <100%> (+1.62%)` | :arrow_up: |
   | 
[...ain/scala/whisk/core/containerpool/HttpUtils.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9IdHRwVXRpbHMuc2NhbGE=)
 | `69.81% <14.28%> (+18.9%)` | :arrow_up: |
   | 
[...ain/scala/whisk/core/containerpool/Container.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9Db250YWluZXIuc2NhbGE=)
 | `76.56% <25%> (+0.37%)` | :arrow_up: |
   | 
[...ala/whisk/core/containerpool/ContainerClient.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9Db250YWluZXJDbGllbnQuc2NhbGE=)
 | `70.83% <70.83%> (ø)` | |
   | 
[.../src/main/scala/whisk/core/entity/InstanceId.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZW50aXR5L0luc3RhbmNlSWQuc2NhbGE=)
 | `88.88% <0%> (-11.12%)` | :arrow_down: |
   | ... and [20 
more](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree-more)
 | |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=continue).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=footer).
 Last update 
[4a0b4cd...af68ed1](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=lastupdated).
 Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


[GitHub] tysonnorris commented on a change in pull request #3812: ContainerClient + akka http alternative to HttpUtils

2018-07-16 Thread GitBox
tysonnorris commented on a change in pull request #3812: ContainerClient + akka 
http alternative to HttpUtils
URL: 
https://github.com/apache/incubator-openwhisk/pull/3812#discussion_r202885345
 
 

 ##
 File path: 
common/scala/src/main/scala/whisk/core/containerpool/ContainerClient.scala
 ##
 @@ -0,0 +1,240 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package whisk.core.containerpool
+
+import akka.actor.ActorSystem
+import akka.http.scaladsl.marshallers.sprayjson.SprayJsonSupport._
+import akka.http.scaladsl.marshalling.Marshal
+import akka.http.scaladsl.model.HttpMethods
+import akka.http.scaladsl.model.HttpRequest
+import akka.http.scaladsl.model.HttpResponse
+import akka.http.scaladsl.model.MessageEntity
+import akka.http.scaladsl.model.StatusCodes
+import akka.http.scaladsl.model.headers.Connection
+import akka.http.scaladsl.unmarshalling.Unmarshal
+import akka.stream.scaladsl.Sink
+import akka.stream.scaladsl.Source
+import akka.util.ByteString
+import scala.concurrent.Await
+import scala.concurrent.ExecutionContext
+import scala.concurrent.Future
+import scala.concurrent.Promise
+import scala.concurrent.TimeoutException
+import scala.concurrent.duration._
+import scala.util.Try
+import scala.util.control.NoStackTrace
+import spray.json._
+import whisk.common.Logging
+import whisk.common.TransactionId
+import whisk.core.entity.ActivationResponse.ContainerHttpError
+import whisk.core.entity.ActivationResponse._
+import whisk.core.entity.ByteSize
+import whisk.core.entity.size.SizeLong
+import whisk.http.PoolingRestClient
+
+trait ContainerClient {
+  def close(): Unit
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId): Future[Either[ContainerHttpError, 
ContainerResponse]]
+
+}
+
+/**
+ * This HTTP client is used only in the invoker to communicate with the action 
container.
+ * It allows to POST a JSON object and receive JSON object back; that is the
+ * content type and the accept headers are both 'application/json.
+ * The reason we still use this class for the action container is a mysterious 
hang
+ * in the Akka http client where a future fails to properly timeout and we 
have not
+ * determined why that is.
+ *
+ * @param hostname the host name
+ * @param timeout the timeout in msecs to wait for a response
+ * @param maxResponse the maximum size in bytes the connection will accept
+ * @param queueSize once all connections are used, how big of queue to allow 
for additional requests
+ * @param retryInterval duration between retries for TCP connection errors
+ */
+protected class PoolingContainerClient(
+  hostname: String,
+  port: Int,
+  timeout: FiniteDuration,
+  maxResponse: ByteSize,
+  queueSize: Int,
+  retryInterval: FiniteDuration = 100.milliseconds)(implicit logging: Logging, 
as: ActorSystem)
+extends PoolingRestClient("http", hostname, port, queueSize)
+with ContainerClient {
+
+  def close() = shutdown()
+
+  /**
+   * Posts to hostname/endpoint the given JSON object.
+   * Waits up to timeout before aborting on a good connection.
+   * If the endpoint is not ready, retry up to timeout.
+   * Every retry reduces the available timeout so that this method should not
+   * wait longer than the total timeout (within a small slack allowance).
+   *
+   * @param endpoint the path the api call relative to hostname
+   * @param body the JSON value to post (this is usually a JSON objecT)
+   * @param retry whether or not to retry on connection failure
+   * @return Left(Error Message) or Right(Status Code, Response as UTF-8 
String)
+   */
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId): Future[Either[ContainerHttpError, 
ContainerResponse]] = {
+
+//create the request
+val req = Marshal(body).to[MessageEntity].map { b =>
+  //DO NOT reuse the connection (in case of paused containers)
+  //For details on Connection: Close handling, see:
+  // - 
https://doc.akka.io/docs/akka-http/current/common/http-model.html#http-headers
+  // - 
http://github.com/akka/akka-http/tree/v10.1.3/akka-http-core/src/test/scala/akka/http/impl/engine/rendering/ResponseRendererSpec.scala#L470-L571
+  

[GitHub] tysonnorris commented on a change in pull request #3812: ContainerClient + akka http alternative to HttpUtils

2018-07-16 Thread GitBox
tysonnorris commented on a change in pull request #3812: ContainerClient + akka 
http alternative to HttpUtils
URL: 
https://github.com/apache/incubator-openwhisk/pull/3812#discussion_r202884192
 
 

 ##
 File path: 
common/scala/src/main/scala/whisk/core/containerpool/ContainerClient.scala
 ##
 @@ -0,0 +1,205 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package whisk.core.containerpool
+
+import akka.actor.ActorSystem
+import akka.http.scaladsl.marshallers.sprayjson.SprayJsonSupport._
+import akka.http.scaladsl.marshalling.Marshal
+import akka.http.scaladsl.model.HttpMethods
+import akka.http.scaladsl.model.HttpRequest
+import akka.http.scaladsl.model.HttpResponse
+import akka.http.scaladsl.model.MessageEntity
+import akka.http.scaladsl.unmarshalling.Unmarshal
+import scala.concurrent.Await
+import scala.concurrent.ExecutionContext
+import scala.concurrent.Future
+import scala.concurrent.Promise
+import scala.concurrent.TimeoutException
+import scala.concurrent.duration._
+import scala.util.Try
+import scala.util.control.NoStackTrace
+import spray.json._
+import whisk.common.Logging
+import whisk.common.TransactionId
+import whisk.core.entity.ActivationResponse.ContainerHttpError
+import whisk.core.entity.ActivationResponse._
+import whisk.core.entity.ByteSize
+import whisk.core.entity.size.SizeLong
+import whisk.http.PoolingRestClient
+
+trait ContainerClient {
+  def close(): Unit
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId,
+ec: ExecutionContext): Future[Either[ContainerHttpError, 
ContainerResponse]]
+
+}
+
+/**
+ * This HTTP client is used only in the invoker to communicate with the action 
container.
+ * It allows to POST a JSON object and receive JSON object back; that is the
+ * content type and the accept headers are both 'application/json.
+ * The reason we still use this class for the action container is a mysterious 
hang
+ * in the Akka http client where a future fails to properly timeout and we 
have not
+ * determined why that is.
+ *
+ * @param hostname the host name
+ * @param timeout the timeout in msecs to wait for a response
+ * @param maxResponse the maximum size in bytes the connection will accept
+ * @param queueSize once all connections are used, how big of queue to allow 
for additional requests
+ * @param retryInterval duration between retries for TCP connection errors
+ */
+protected class PoolingContainerClient(
+  hostname: String,
+  port: Int,
+  timeout: FiniteDuration,
+  maxResponse: ByteSize,
+  queueSize: Int,
+  retryInterval: FiniteDuration = 100.milliseconds)(implicit logging: Logging, 
as: ActorSystem)
+extends PoolingRestClient("http", hostname, port, queueSize)
+with ContainerClient {
+
+  def close() = shutdown()
+
+  /**
+   * Posts to hostname/endpoint the given JSON object.
+   * Waits up to timeout before aborting on a good connection.
+   * If the endpoint is not ready, retry up to timeout.
+   * Every retry reduces the available timeout so that this method should not
+   * wait longer than the total timeout (within a small slack allowance).
+   *
+   * @param endpoint the path the api call relative to hostname
+   * @param body the JSON value to post (this is usually a JSON objecT)
+   * @param retry whether or not to retry on connection failure
+   * @return Left(Error Message) or Right(Status Code, Response as UTF-8 
String)
+   */
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId,
+ec: ExecutionContext): Future[Either[ContainerHttpError, 
ContainerResponse]] = {
+
+//create the request
+val req = Marshal(body).to[MessageEntity].map { b =>
+  HttpRequest(HttpMethods.POST, endpoint, entity = b)
+}
+
+//Begin retry handling
+
+//Handle retries by:
+// - tracking request as a promise
+// - attaching a timeout to fail the promise
+// - create a function to enqueue the request
+// - retry (using same function) on StreamTcpException (only if retry == 
true)
+
+val promise = Promise[HttpResponse]
+
+// Timeout includes all retries.
+as.scheduler.scheduleOnce(timeout) {
+  promise.tryFailure(new 

[GitHub] tysonnorris commented on a change in pull request #3812: ContainerClient + akka http alternative to HttpUtils

2018-07-16 Thread GitBox
tysonnorris commented on a change in pull request #3812: ContainerClient + akka 
http alternative to HttpUtils
URL: 
https://github.com/apache/incubator-openwhisk/pull/3812#discussion_r202883397
 
 

 ##
 File path: 
common/scala/src/main/scala/whisk/core/containerpool/ContainerClient.scala
 ##
 @@ -0,0 +1,205 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package whisk.core.containerpool
+
+import akka.actor.ActorSystem
+import akka.http.scaladsl.marshallers.sprayjson.SprayJsonSupport._
+import akka.http.scaladsl.marshalling.Marshal
+import akka.http.scaladsl.model.HttpMethods
+import akka.http.scaladsl.model.HttpRequest
+import akka.http.scaladsl.model.HttpResponse
+import akka.http.scaladsl.model.MessageEntity
+import akka.http.scaladsl.unmarshalling.Unmarshal
+import scala.concurrent.Await
+import scala.concurrent.ExecutionContext
+import scala.concurrent.Future
+import scala.concurrent.Promise
+import scala.concurrent.TimeoutException
+import scala.concurrent.duration._
+import scala.util.Try
+import scala.util.control.NoStackTrace
+import spray.json._
+import whisk.common.Logging
+import whisk.common.TransactionId
+import whisk.core.entity.ActivationResponse.ContainerHttpError
+import whisk.core.entity.ActivationResponse._
+import whisk.core.entity.ByteSize
+import whisk.core.entity.size.SizeLong
+import whisk.http.PoolingRestClient
+
+trait ContainerClient {
+  def close(): Unit
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId,
+ec: ExecutionContext): Future[Either[ContainerHttpError, 
ContainerResponse]]
+
+}
+
+/**
+ * This HTTP client is used only in the invoker to communicate with the action 
container.
+ * It allows to POST a JSON object and receive JSON object back; that is the
+ * content type and the accept headers are both 'application/json.
+ * The reason we still use this class for the action container is a mysterious 
hang
+ * in the Akka http client where a future fails to properly timeout and we 
have not
+ * determined why that is.
+ *
+ * @param hostname the host name
+ * @param timeout the timeout in msecs to wait for a response
+ * @param maxResponse the maximum size in bytes the connection will accept
+ * @param queueSize once all connections are used, how big of queue to allow 
for additional requests
+ * @param retryInterval duration between retries for TCP connection errors
+ */
+protected class PoolingContainerClient(
+  hostname: String,
+  port: Int,
+  timeout: FiniteDuration,
+  maxResponse: ByteSize,
+  queueSize: Int,
+  retryInterval: FiniteDuration = 100.milliseconds)(implicit logging: Logging, 
as: ActorSystem)
+extends PoolingRestClient("http", hostname, port, queueSize)
+with ContainerClient {
+
+  def close() = shutdown()
+
+  /**
+   * Posts to hostname/endpoint the given JSON object.
+   * Waits up to timeout before aborting on a good connection.
+   * If the endpoint is not ready, retry up to timeout.
+   * Every retry reduces the available timeout so that this method should not
+   * wait longer than the total timeout (within a small slack allowance).
+   *
+   * @param endpoint the path the api call relative to hostname
+   * @param body the JSON value to post (this is usually a JSON objecT)
+   * @param retry whether or not to retry on connection failure
+   * @return Left(Error Message) or Right(Status Code, Response as UTF-8 
String)
+   */
+  def post(endpoint: String, body: JsValue, retry: Boolean)(
+implicit tid: TransactionId,
+ec: ExecutionContext): Future[Either[ContainerHttpError, 
ContainerResponse]] = {
+
+//create the request
+val req = Marshal(body).to[MessageEntity].map { b =>
+  HttpRequest(HttpMethods.POST, endpoint, entity = b)
+}
+
+//Begin retry handling
+
+//Handle retries by:
+// - tracking request as a promise
+// - attaching a timeout to fail the promise
+// - create a function to enqueue the request
+// - retry (using same function) on StreamTcpException (only if retry == 
true)
+
+val promise = Promise[HttpResponse]
+
+// Timeout includes all retries.
+as.scheduler.scheduleOnce(timeout) {
+  promise.tryFailure(new 

[GitHub] nerdguru opened a new issue #258: Where should the come from for GKE nginx ingress?

2018-07-16 Thread GitBox
nerdguru opened a new issue #258: Where should the  come from for GKE 
nginx ingress?
URL: https://github.com/apache/incubator-openwhisk-deploy-kube/issues/258
 
 
   On the new instructions for Google ingress:
   
   
https://github.com/apache/incubator-openwhisk-deploy-kube/blob/master/docs/ingress.md
   
   Where should the  come from?  When you deploy a standard GKE 
cluster, you get an IP address of the master node, but not a domain.  Or am I 
misreading something?
   


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] StrayCat1 opened a new pull request #257: External zookeeper kafka

2018-07-16 Thread GitBox
StrayCat1 opened a new pull request #257: External zookeeper kafka
URL: https://github.com/apache/incubator-openwhisk-deploy-kube/pull/257
 
 
   These changes allow users to deploy the OpenWhisk chart to a cluster with 
existing zookeeper and kafka services.  
   
   If kafka and zookeeper are toggled off, the parent chart must define 
kafka_host, zookeeper_connect, and zookeeper_zero_host in _helpers.tpl so the 
openwhisk components can find them. 


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] codecov-io edited a comment on issue #3812: ContainerClient + akka http alternative to HttpUtils

2018-07-16 Thread GitBox
codecov-io edited a comment on issue #3812: ContainerClient + akka http 
alternative to HttpUtils
URL: 
https://github.com/apache/incubator-openwhisk/pull/3812#issuecomment-401212372
 
 
   # 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=h1)
 Report
   > Merging 
[#3812](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=desc)
 into 
[master](https://codecov.io/gh/apache/incubator-openwhisk/commit/4a0b4cdc595abe9acd8cdd68b56ac440ea443bc9?src=pr=desc)
 will **decrease** coverage by `3.42%`.
   > The diff coverage is `54.05%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/graphs/tree.svg?width=650=150=pr=l0YmsiSAso)](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=tree)
   
   ```diff
   @@Coverage Diff @@
   ##   master#3812  +/-   ##
   ==
   - Coverage   74.45%   71.02%   -3.43% 
   ==
 Files 137  146   +9 
 Lines6471 6941 +470 
 Branches  408  421  +13 
   ==
   + Hits 4818 4930 +112 
   - Misses   1653 2011 +358
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=tree)
 | Coverage Δ | |
   |---|---|---|
   | 
[...containerpool/kubernetes/KubernetesContainer.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29yZS9pbnZva2VyL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9rdWJlcm5ldGVzL0t1YmVybmV0ZXNDb250YWluZXIuc2NhbGE=)
 | `91.66% <ø> (ø)` | :arrow_up: |
   | 
[...la/whisk/core/containerpool/ContainerFactory.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9Db250YWluZXJGYWN0b3J5LnNjYWxh)
 | `100% <ø> (ø)` | :arrow_up: |
   | 
[...la/src/main/scala/whisk/core/mesos/MesosTask.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvbWVzb3MvTWVzb3NUYXNrLnNjYWxh)
 | `86.11% <ø> (ø)` | :arrow_up: |
   | 
[...sk/core/containerpool/docker/DockerContainer.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29yZS9pbnZva2VyL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9kb2NrZXIvRG9ja2VyQ29udGFpbmVyLnNjYWxh)
 | `79.16% <0%> (+2.13%)` | :arrow_up: |
   | 
[...n/scala/whisk/core/database/CouchDbRestStore.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvQ291Y2hEYlJlc3RTdG9yZS5zY2FsYQ==)
 | `73.23% <100%> (ø)` | :arrow_up: |
   | 
[.../src/main/scala/whisk/http/PoolingRestClient.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2h0dHAvUG9vbGluZ1Jlc3RDbGllbnQuc2NhbGE=)
 | `90.9% <100%> (+1.62%)` | :arrow_up: |
   | 
[...ain/scala/whisk/core/containerpool/HttpUtils.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9IdHRwVXRpbHMuc2NhbGE=)
 | `52.83% <14.28%> (+1.92%)` | :arrow_up: |
   | 
[...ain/scala/whisk/core/containerpool/Container.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9Db250YWluZXIuc2NhbGE=)
 | `76.56% <25%> (+0.37%)` | :arrow_up: |
   | 
[...ala/whisk/core/containerpool/ContainerClient.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udGFpbmVycG9vbC9Db250YWluZXJDbGllbnQuc2NhbGE=)
 | `64.28% <64.28%> (ø)` | |
   | 
[.../src/main/scala/whisk/core/entity/InstanceId.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZW50aXR5L0luc3RhbmNlSWQuc2NhbGE=)
 | `88.88% <0%> (-11.12%)` | :arrow_down: |
   | ... and [19 
more](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812/diff?src=pr=tree-more)
 | |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=continue).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=footer).
 Last update 
[4a0b4cd...d8301b7](https://codecov.io/gh/apache/incubator-openwhisk/pull/3812?src=pr=lastupdated).
 Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


[GitHub] alexkli commented on issue #3883: Make it easier to use webpack with JS actions

2018-07-16 Thread GitBox
alexkli commented on issue #3883: Make it easier to use webpack with JS actions
URL: 
https://github.com/apache/incubator-openwhisk/issues/3883#issuecomment-405342652
 
 
   Related: https://github.com/serverless/serverless-openwhisk/issues/118


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] macdonst opened a new issue #3883: Make it easier to use webpack with JS actions

2018-07-16 Thread GitBox
macdonst opened a new issue #3883: Make it easier to use webpack with JS actions
URL: https://github.com/apache/incubator-openwhisk/issues/3883
 
 
   
   
   ## Environment details:
   
   * all deployments   
   * all versions
   
   ## Steps to reproduce the issue:
   
   1.   Create a JS action following [Package an action as a single 
bundle](https://github.com/apache/incubator-openwhisk/blob/master/docs/actions-node.md#package-an-action-as-a-single-bundle)
 instructions.
   2.   Include a package like `request-promise` that's [already 
included](https://github.com/apache/incubator-openwhisk/blob/master/docs/actions-node.md#nodejs-version-6-environment)
 in the OpenWhisk container.
   3.   Build the action
   
   
   ## Provide the expected results and outputs:
   
   It would be great if right out of the box your JS action would exclude any 
packages in the container. For instance when I exclude `request-promise` the 
action is 2kb.
   
   ```
   webpack v4.13.0
   
   1e71fd7ad002a3195f86
 size name  module  status
 167 B0 ./src/config.js built
 42 B 1 external "request-promise"  built
 1.42 kB  2 ./src/stockAPI.js   built
 992 B3 ./src/index.js  built
   
 size name  asset   status
 2.05 kB  main  bundle.js   emitted
   
 Δt 106ms
   ```
   
   
   ## Provide the actual results and outputs:
   
   But when I don't specify `request-promise` as an external the action is 
770kb:
   
   ```
   webpack v4.13.0
   
   2dfdb6782288d2371fc3
 size name  module  status
 42 B 1 external "util" built
 42 B 3 external "crypto"   built
 42 B 9 external "url"  built
 42 B 16external "stream"   built
 42 B 20external "http" built
 42 B 31external "querystring"  built
 42 B 35external "https"built
 42 B 47external "net"  built
 42 B 63external "fs"   built
 42 B 65external "tls"  built
 167 B87./src/config.js built
 42 B 88external "os"   built
 42 B 174   external "zlib" built
 1.42 kB  224   ./src/stockAPI.js   built
 992 B225   ./src/index.js  built
   
 size name  asset   status
 733 kB   main  bundle.js   emitted
   
 Δt 6940ms (211 modules hidden)
   ```
   
   ## Additional information you deem important:
   
   Yes, I know I can go into webpack and list the pre-installed node packages 
as externals like so:
   
   ```javascript
   module.exports = {
 entry: './src/index.js',
 output: {
   path: path.resolve(__dirname, '..', 'dist'),
   filename: 'bundle.js'
 },
 target: 'node',
 externals: [ 'request-promise' ]
   };
   ```
   
   but wouldn't life be so much easier if all the packages that are installed 
in the node container were in a single npm package? This way you could easily 
exclude all the dependent packages in webpack and it would make maintenance of 
the packages in the container easier.
   
   For instance I created a package 
[simon-runtime-deps](https://www.npmjs.com/package/simon-runtime-deps) which 
includes all 55 dependencies from the node 6 container. This allows me to 
create a quick script to externalize those dependencies in webpack:
   
   ```javascript
   var path = require('path');
   var nodeExternals = require('simon-runtime-deps');
   
   module.exports = {
 entry: './src/index.js',
 output: {
   path: path.resolve(__dirname, '..', 'dist'),
   filename: 'bundle.js'
 },
 target: 'node',
 externals: [nodeExternals()]
   };
   ```
   
   This approach could also have the added benefit of simplifying the 
`package.json` or `Dockerfile` so you wouldn't have some many dependencies to 
maintain.
   
   We could have an `openwhisk-node8-dependencies` package as a base and 
vendors can add their own packages `bluemix-node8-dependencies` for example.


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] codecov-io commented on issue #3882: Use invoker id for metrics instead of the hostname.

2018-07-16 Thread GitBox
codecov-io commented on issue #3882: Use invoker id for metrics instead of the 
hostname.
URL: 
https://github.com/apache/incubator-openwhisk/pull/3882#issuecomment-405291454
 
 
   # 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882?src=pr=h1)
 Report
   > Merging 
[#3882](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882?src=pr=desc)
 into 
[master](https://codecov.io/gh/apache/incubator-openwhisk/commit/e96c1bbd5a0f54c923f0153116f7c1f165275e94?src=pr=desc)
 will **decrease** coverage by `4.81%`.
   > The diff coverage is `0%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882/graphs/tree.svg?token=l0YmsiSAso=650=150=pr)](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882?src=pr=tree)
   
   ```diff
   @@Coverage Diff @@
   ##   master#3882  +/-   ##
   ==
   - Coverage   75.78%   70.97%   -4.82% 
   ==
 Files 145  145  
 Lines6897 6900   +3 
 Branches  418  416   -2 
   ==
   - Hits 5227 4897 -330 
   - Misses   1670 2003 +333
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882?src=pr=tree)
 | Coverage Δ | |
   |---|---|---|
   | 
[...er/src/main/scala/whisk/core/invoker/Invoker.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882/diff?src=pr=tree#diff-Y29yZS9pbnZva2VyL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvaW52b2tlci9JbnZva2VyLnNjYWxh)
 | `0% <0%> (ø)` | :arrow_up: |
   | 
[...core/database/cosmosdb/RxObservableImplicits.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvUnhPYnNlcnZhYmxlSW1wbGljaXRzLnNjYWxh)
 | `0% <0%> (-100%)` | :arrow_down: |
   | 
[...core/database/cosmosdb/CosmosDBArtifactStore.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlLnNjYWxh)
 | `0% <0%> (-95.08%)` | :arrow_down: |
   | 
[...sk/core/database/cosmosdb/CosmosDBViewMapper.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJWaWV3TWFwcGVyLnNjYWxh)
 | `0% <0%> (-92.6%)` | :arrow_down: |
   | 
[...whisk/core/database/cosmosdb/CosmosDBSupport.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJTdXBwb3J0LnNjYWxh)
 | `0% <0%> (-81.82%)` | :arrow_down: |
   | 
[...abase/cosmosdb/CosmosDBArtifactStoreProvider.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlUHJvdmlkZXIuc2NhbGE=)
 | `0% <0%> (-58.83%)` | :arrow_down: |
   | 
[...la/whisk/core/database/cosmosdb/CosmosDBUtil.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJVdGlsLnNjYWxh)
 | `92% <0%> (-4%)` | :arrow_down: |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882?src=pr=continue).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882?src=pr=footer).
 Last update 
[e96c1bb...cccb825](https://codecov.io/gh/apache/incubator-openwhisk/pull/3882?src=pr=lastupdated).
 Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


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 edited a comment on issue #3835: Limit of binary actions is too low.

2018-07-16 Thread GitBox
cbickel edited a comment on issue #3835: Limit of binary actions is too low.
URL: 
https://github.com/apache/incubator-openwhisk/pull/3835#issuecomment-403448140
 
 
   PG5#514  


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] jasonpet commented on issue #274: Remove required access to the whole couchdb database.

2018-07-16 Thread GitBox
jasonpet commented on issue #274: Remove required access to the whole couchdb 
database.
URL: 
https://github.com/apache/incubator-openwhisk-package-kafka/pull/274#issuecomment-405254698
 
 
   @abaruni - please review and verify that this PR will not cause any issues.


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 edited a comment on issue #3880: Modify that web action in the bound package can be accessed.

2018-07-16 Thread GitBox
rabbah edited a comment on issue #3880: Modify that web action in the bound 
package can be accessed.
URL: 
https://github.com/apache/incubator-openwhisk/pull/3880#issuecomment-405220811
 
 
   Thanks for trying this. There are some issues to be aware of for packaged 
actions as web actions via bindings. The lack of support isn’t a bug (it was 
intentional at the time). This has come up before so it’s worthwhile to try and 
enable this. 
   
   1. If an action isn’t already a web action in the package, it can’t be 
accessed as a web action through the binding. That is a subject that binds the 
action can’t make it a web action (unless they already own it). So the 
creator/sharer of the package decides which of the actions to make available as 
web actions. Inherently this could create a dependence the subject can't 
control.
   
   2. The entitlement check for a web action today is straightforward: 
namespace must own both and so implicitly entitled to them. With a binding you 
need to check if the binding continues to have rights to the bound package.
   
   3. And of course you’ll need to add tests for the change/new feature. 
   
   


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] upgle commented on issue #3880: [WIP] Modify that web action in the bound package can be accessed.

2018-07-16 Thread GitBox
upgle commented on issue #3880: [WIP] Modify that web action in the bound 
package can be accessed.
URL: 
https://github.com/apache/incubator-openwhisk/pull/3880#issuecomment-405235462
 
 
   @rabbah 
   Thank you for your feedback and sorry that I thought it was a bug. 
   I will add some test codes including the rights check and suggest it again.
   
   


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 edited a comment on issue #3880: Fix a bug that web action in the bound package cannot be accessed.

2018-07-16 Thread GitBox
rabbah edited a comment on issue #3880: Fix a bug that web action in the bound 
package cannot be accessed.
URL: 
https://github.com/apache/incubator-openwhisk/pull/3880#issuecomment-405220811
 
 
   Thanks for trying this. There are some issues to be aware of for packaged 
actions as web actions via bindings. The lack of support isn’t a bug (it was 
intentional at the time). This has come up before so it’s worthwhile to try and 
enable this. 
   
   1. If an action isn’t already a web action in the package, it can’t be 
accessed as a web action through the binding. That is a subject that binds the 
action can’t make it a web action (unless they already own it). So the 
creator/sharer of the package will have to decide which of the actions to make 
available as web actions. 
   
   2. The entitlement check for a web action today is straightforward: 
namespace must own both and so implicitly entitled to them. With a binding you 
need to check if the binding continues to have rights to the bound package.
   
   3. And of course you’ll need to add tests for the change/new feature. 
   
   


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 #3880: Fix a bug that web action in the bound package cannot be accessed.

2018-07-16 Thread GitBox
rabbah commented on issue #3880: Fix a bug that web action in the bound package 
cannot be accessed.
URL: 
https://github.com/apache/incubator-openwhisk/pull/3880#issuecomment-405220811
 
 
   Thanks for trying this. There are some issues to be aware of packaged 
actions as web actions via bindings. The lack of support isn’t a bug (it was 
intentional at the time). This has come up before so it’s worthwhile to try and 
enable this. 
   
   1. If an action isn’t already a web action in the package, it can’t be 
accessed as a webaction through the biding. That is a subject that binds the 
action can’t make it a web action (unless they already own it). So the 
creator/shares of the package will have to decide which of the actions to make 
available as web actions. 
   
   2. The entitlement check for a web action today is straightforward: 
namespace must own both and so implicitly entitled to them. With a binding you 
need to check if the binding continues to have rights to the bound package.
   
   3. And of course you’ll need to add tests for the change/new feature. 
   
   


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] codecov-io edited a comment on issue #3881: Limit TLS protocols used for kafka and controller

2018-07-16 Thread GitBox
codecov-io edited a comment on issue #3881: Limit TLS protocols used for kafka 
and controller
URL: 
https://github.com/apache/incubator-openwhisk/pull/3881#issuecomment-405218984
 
 
   # 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=h1)
 Report
   > Merging 
[#3881](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=desc)
 into 
[master](https://codecov.io/gh/apache/incubator-openwhisk/commit/e96c1bbd5a0f54c923f0153116f7c1f165275e94?src=pr=desc)
 will **decrease** coverage by `4.78%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/graphs/tree.svg?token=l0YmsiSAso=pr=150=650)](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=tree)
   
   ```diff
   @@Coverage Diff@@
   ##   master   #3881  +/-   ##
   =
   - Coverage   75.78% 71%   -4.79% 
   =
 Files 145 145  
 Lines68976897  
 Branches  418 418  
   =
   - Hits 52274897 -330 
   - Misses   16702000 +330
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=tree)
 | Coverage Δ | |
   |---|---|---|
   | 
[...core/database/cosmosdb/RxObservableImplicits.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvUnhPYnNlcnZhYmxlSW1wbGljaXRzLnNjYWxh)
 | `0% <0%> (-100%)` | :arrow_down: |
   | 
[...core/database/cosmosdb/CosmosDBArtifactStore.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlLnNjYWxh)
 | `0% <0%> (-95.08%)` | :arrow_down: |
   | 
[...sk/core/database/cosmosdb/CosmosDBViewMapper.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJWaWV3TWFwcGVyLnNjYWxh)
 | `0% <0%> (-92.6%)` | :arrow_down: |
   | 
[...whisk/core/database/cosmosdb/CosmosDBSupport.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJTdXBwb3J0LnNjYWxh)
 | `0% <0%> (-81.82%)` | :arrow_down: |
   | 
[...abase/cosmosdb/CosmosDBArtifactStoreProvider.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlUHJvdmlkZXIuc2NhbGE=)
 | `0% <0%> (-58.83%)` | :arrow_down: |
   | 
[...la/whisk/core/database/cosmosdb/CosmosDBUtil.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJVdGlsLnNjYWxh)
 | `92% <0%> (-4%)` | :arrow_down: |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=continue).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=footer).
 Last update 
[e96c1bb...c857527](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=lastupdated).
 Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


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] codecov-io commented on issue #3881: Limit TLS protocols used for kafka and controller

2018-07-16 Thread GitBox
codecov-io commented on issue #3881: Limit TLS protocols used for kafka and 
controller
URL: 
https://github.com/apache/incubator-openwhisk/pull/3881#issuecomment-405218984
 
 
   # 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=h1)
 Report
   > Merging 
[#3881](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=desc)
 into 
[master](https://codecov.io/gh/apache/incubator-openwhisk/commit/e96c1bbd5a0f54c923f0153116f7c1f165275e94?src=pr=desc)
 will **decrease** coverage by `4.78%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/graphs/tree.svg?width=650=pr=l0YmsiSAso=150)](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=tree)
   
   ```diff
   @@Coverage Diff@@
   ##   master   #3881  +/-   ##
   =
   - Coverage   75.78% 71%   -4.79% 
   =
 Files 145 145  
 Lines68976897  
 Branches  418 418  
   =
   - Hits 52274897 -330 
   - Misses   16702000 +330
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=tree)
 | Coverage Δ | |
   |---|---|---|
   | 
[...core/database/cosmosdb/RxObservableImplicits.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvUnhPYnNlcnZhYmxlSW1wbGljaXRzLnNjYWxh)
 | `0% <0%> (-100%)` | :arrow_down: |
   | 
[...core/database/cosmosdb/CosmosDBArtifactStore.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlLnNjYWxh)
 | `0% <0%> (-95.08%)` | :arrow_down: |
   | 
[...sk/core/database/cosmosdb/CosmosDBViewMapper.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJWaWV3TWFwcGVyLnNjYWxh)
 | `0% <0%> (-92.6%)` | :arrow_down: |
   | 
[...whisk/core/database/cosmosdb/CosmosDBSupport.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJTdXBwb3J0LnNjYWxh)
 | `0% <0%> (-81.82%)` | :arrow_down: |
   | 
[...abase/cosmosdb/CosmosDBArtifactStoreProvider.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlUHJvdmlkZXIuc2NhbGE=)
 | `0% <0%> (-58.83%)` | :arrow_down: |
   | 
[...la/whisk/core/database/cosmosdb/CosmosDBUtil.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJVdGlsLnNjYWxh)
 | `92% <0%> (-4%)` | :arrow_down: |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=continue).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=footer).
 Last update 
[e96c1bb...c857527](https://codecov.io/gh/apache/incubator-openwhisk/pull/3881?src=pr=lastupdated).
 Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


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] codecov-io commented on issue #3880: Fix a bug that web action in the bound package cannot be accessed.

2018-07-16 Thread GitBox
codecov-io commented on issue #3880: Fix a bug that web action in the bound 
package cannot be accessed.
URL: 
https://github.com/apache/incubator-openwhisk/pull/3880#issuecomment-405214016
 
 
   # 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880?src=pr=h1)
 Report
   > Merging 
[#3880](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880?src=pr=desc)
 into 
[master](https://codecov.io/gh/apache/incubator-openwhisk/commit/e96c1bbd5a0f54c923f0153116f7c1f165275e94?src=pr=desc)
 will **decrease** coverage by `4.72%`.
   > The diff coverage is `0%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880/graphs/tree.svg?width=650=pr=l0YmsiSAso=150)](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880?src=pr=tree)
   
   ```diff
   @@Coverage Diff @@
   ##   master#3880  +/-   ##
   ==
   - Coverage   75.78%   71.06%   -4.73% 
   ==
 Files 145  145  
 Lines6897 6898   +1 
 Branches  418  421   +3 
   ==
   - Hits 5227 4902 -325 
   - Misses   1670 1996 +326
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880?src=pr=tree)
 | Coverage Δ | |
   |---|---|---|
   | 
[.../main/scala/whisk/core/controller/WebActions.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880/diff?src=pr=tree#diff-Y29yZS9jb250cm9sbGVyL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udHJvbGxlci9XZWJBY3Rpb25zLnNjYWxh)
 | `88.18% <0%> (-0.35%)` | :arrow_down: |
   | 
[...core/database/cosmosdb/RxObservableImplicits.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvUnhPYnNlcnZhYmxlSW1wbGljaXRzLnNjYWxh)
 | `0% <0%> (-100%)` | :arrow_down: |
   | 
[...core/database/cosmosdb/CosmosDBArtifactStore.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlLnNjYWxh)
 | `0% <0%> (-95.08%)` | :arrow_down: |
   | 
[...sk/core/database/cosmosdb/CosmosDBViewMapper.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJWaWV3TWFwcGVyLnNjYWxh)
 | `0% <0%> (-92.6%)` | :arrow_down: |
   | 
[...whisk/core/database/cosmosdb/CosmosDBSupport.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJTdXBwb3J0LnNjYWxh)
 | `0% <0%> (-81.82%)` | :arrow_down: |
   | 
[...abase/cosmosdb/CosmosDBArtifactStoreProvider.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlUHJvdmlkZXIuc2NhbGE=)
 | `0% <0%> (-58.83%)` | :arrow_down: |
   | 
[...la/whisk/core/database/cosmosdb/CosmosDBUtil.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJVdGlsLnNjYWxh)
 | `92% <0%> (-4%)` | :arrow_down: |
   | 
[...whisk/connector/kafka/KafkaMessagingProvider.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2Nvbm5lY3Rvci9rYWZrYS9LYWZrYU1lc3NhZ2luZ1Byb3ZpZGVyLnNjYWxh)
 | `84.61% <0%> (+15.38%)` | :arrow_up: |
   | 
[...n/scala/src/main/scala/whisk/common/CausedBy.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvbW1vbi9DYXVzZWRCeS5zY2FsYQ==)
 | `100% <0%> (+100%)` | :arrow_up: |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880?src=pr=continue).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880?src=pr=footer).
 Last update 
[e96c1bb...459a12c](https://codecov.io/gh/apache/incubator-openwhisk/pull/3880?src=pr=lastupdated).
 Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


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 

[GitHub] vvraskin commented on issue #3881: Limit TLS protocols used for kafka and controller

2018-07-16 Thread GitBox
vvraskin commented on issue #3881: Limit TLS protocols used for kafka and 
controller
URL: 
https://github.com/apache/incubator-openwhisk/pull/3881#issuecomment-405212419
 
 
   PG3/2533 is :white_check_mark:


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] vvraskin opened a new pull request #3881: Limit TLS protocols used for kafka and controller

2018-07-16 Thread GitBox
vvraskin opened a new pull request #3881: Limit TLS protocols used for kafka 
and controller
URL: https://github.com/apache/incubator-openwhisk/pull/3881
 
 
   
   This PR limits tls protocols to be used while talking via SSL with 
Controller and Kafka.
   From now on TLS 1.2 will be the only allowed protocol mainly because of the 
weak cipher suites used in the previous version, e.g. MD5.  
   
   ## Description
   
   
   
   ## Related issue and scope
   
   - [ ] I opened an issue to propose and discuss this change (#)
   
   ## My changes affect the following components
   
   
   - [ ] API
   - [ ] Controller
   - [ ] Message Bus (e.g., Kafka)
   - [ ] Loadbalancer
   - [ ] Invoker
   - [ ] Intrinsic actions (e.g., sequences, conductors)
   - [ ] Data stores (e.g., CouchDB)
   - [ ] Tests
   - [x] Deployment
   - [ ] CLI
   - [ ] General tooling
   - [ ] Documentation
   
   ## Types of changes
   
   - [ ] Bug fix (generally a non-breaking change which closes an issue).
   - [x] Enhancement or new feature (adds new functionality).
   - [ ] Breaking change (a bug fix or enhancement which changes existing 
behavior).
   
   ## Checklist:
   
   
   - [x] I signed an [Apache 
CLA](https://github.com/apache/incubator-openwhisk/blob/master/CONTRIBUTING.md).
   - [x] I reviewed the [style 
guides](https://github.com/apache/incubator-openwhisk/wiki/Contributing:-Git-guidelines#code-readiness)
 and followed the recommendations (Travis CI will check :).
   - [ ] I added tests to cover my changes.
   - [ ] My changes require further changes to the documentation.
   - [ ] I updated the documentation where 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] codecov-io edited a comment on issue #3876: Use separate db users for deployed components.

2018-07-16 Thread GitBox
codecov-io edited a comment on issue #3876: Use separate db users for deployed 
components.
URL: 
https://github.com/apache/incubator-openwhisk/pull/3876#issuecomment-404749269
 
 
   # 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876?src=pr=h1)
 Report
   > Merging 
[#3876](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876?src=pr=desc)
 into 
[master](https://codecov.io/gh/apache/incubator-openwhisk/commit/967f00525149544628961eb1a8a1e404679167b7?src=pr=desc)
 will **decrease** coverage by `4.78%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876/graphs/tree.svg?height=150=650=l0YmsiSAso=pr)](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876?src=pr=tree)
   
   ```diff
   @@Coverage Diff @@
   ##   master#3876  +/-   ##
   ==
   - Coverage   75.81%   71.03%   -4.79% 
   ==
 Files 146  146  
 Lines6902 6902  
 Branches  428  428  
   ==
   - Hits 5233 4903 -330 
   - Misses   1669 1999 +330
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876?src=pr=tree)
 | Coverage Δ | |
   |---|---|---|
   | 
[...core/database/cosmosdb/RxObservableImplicits.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvUnhPYnNlcnZhYmxlSW1wbGljaXRzLnNjYWxh)
 | `0% <0%> (-100%)` | :arrow_down: |
   | 
[...core/database/cosmosdb/CosmosDBArtifactStore.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlLnNjYWxh)
 | `0% <0%> (-95.08%)` | :arrow_down: |
   | 
[...sk/core/database/cosmosdb/CosmosDBViewMapper.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJWaWV3TWFwcGVyLnNjYWxh)
 | `0% <0%> (-92.6%)` | :arrow_down: |
   | 
[...whisk/core/database/cosmosdb/CosmosDBSupport.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJTdXBwb3J0LnNjYWxh)
 | `0% <0%> (-81.82%)` | :arrow_down: |
   | 
[...abase/cosmosdb/CosmosDBArtifactStoreProvider.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlUHJvdmlkZXIuc2NhbGE=)
 | `0% <0%> (-58.83%)` | :arrow_down: |
   | 
[...la/whisk/core/database/cosmosdb/CosmosDBUtil.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJVdGlsLnNjYWxh)
 | `92% <0%> (-4%)` | :arrow_down: |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876?src=pr=continue).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876?src=pr=footer).
 Last update 
[967f005...558834e](https://codecov.io/gh/apache/incubator-openwhisk/pull/3876?src=pr=lastupdated).
 Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


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 opened a new issue #276: Improve Promise usage by using chaining

2018-07-16 Thread GitBox
markusthoemmes opened a new issue #276: Improve Promise usage by using chaining
URL: https://github.com/apache/incubator-openwhisk-package-kafka/issues/276
 
 
   Promises in the actions are plumbed together in a non-consistent way. 
Sometimes they use `then`/`catch` chaining, sometimes they are constructed 
globally and then `resolve`/`reject` is used. Sometimes, both ways are even 
mixed together.
   
   We should review the code and fix all usages of Promises to use chaining. 
That's more readable in general and gives more guarantees on the Promise being 
actually resolved at some point.


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 opened a new issue #275: Improve logging in the kafkaFeedWeb.js

2018-07-16 Thread GitBox
markusthoemmes opened a new issue #275: Improve logging in the kafkaFeedWeb.js
URL: https://github.com/apache/incubator-openwhisk-package-kafka/issues/275
 
 
   That action does quite a few things and some of those are chained. It'd be 
helpful to increase the amount of logs written by each step to be able to 
deduct failures if a specific step hangs.


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 closed pull request #3829: Introduce SPI to swap authentication directives

2018-07-16 Thread GitBox
markusthoemmes closed pull request #3829: Introduce SPI to swap authentication 
directives
URL: https://github.com/apache/incubator-openwhisk/pull/3829
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/ansible/group_vars/all b/ansible/group_vars/all
index dc5d942de1..729a683527 100644
--- a/ansible/group_vars/all
+++ b/ansible/group_vars/all
@@ -78,6 +78,8 @@ controller:
   seedNodes: "{{ groups['controllers'] | map('extract', hostvars, 
'ansible_host') | list }}"
   loadbalancer:
 spi: "{{ controller_loadbalancer_spi | default('') }}"
+  authentication:
+spi: "{{ controller_authentication_spi | default('') }}"
   loglevel: "{{ controller_loglevel | default(whisk_loglevel) | 
default('INFO') }}"
   entitlement:
 spi: "{{ controller_entitlement_spi | default('') }}"
diff --git a/ansible/roles/controller/tasks/deploy.yml 
b/ansible/roles/controller/tasks/deploy.yml
index e4b08853d2..990c18c5a8 100644
--- a/ansible/roles/controller/tasks/deploy.yml
+++ b/ansible/roles/controller/tasks/deploy.yml
@@ -233,6 +233,7 @@
 "{{ controller.loadbalancer.spi }}"
   "CONFIG_whisk_spi_EntitlementSpiProvider": "{{ 
controller.entitlement.spi }}"
 
+  "CONFIG_whisk_spi_AuthenticationDirectiveProvider": "{{ 
controller.authentication.spi }}"
   "CONFIG_logback_log_level": "{{ controller.loglevel }}"
 
   "CONFIG_whisk_transactions_header": "{{ transactions.header }}"
diff --git a/common/scala/src/main/resources/reference.conf 
b/common/scala/src/main/resources/reference.conf
index b658f8736f..2f2d898ae3 100644
--- a/common/scala/src/main/resources/reference.conf
+++ b/common/scala/src/main/resources/reference.conf
@@ -9,6 +9,7 @@ whisk.spi {
   LogStoreProvider = 
whisk.core.containerpool.logging.DockerToActivationLogStoreProvider
   LoadBalancerProvider = whisk.core.loadBalancer.ShardingContainerPoolBalancer
   EntitlementSpiProvider = whisk.core.entitlement.LocalEntitlementProvider
+  AuthenticationDirectiveProvider = 
whisk.core.controller.BasicAuthenticationDirective
 }
 
 dispatchers {
diff --git 
a/core/controller/src/main/scala/whisk/core/controller/AuthenticatedRoute.scala 
b/core/controller/src/main/scala/whisk/core/controller/AuthenticatedRoute.scala
index 69a63f4fa6..295dc89952 100644
--- 
a/core/controller/src/main/scala/whisk/core/controller/AuthenticatedRoute.scala
+++ 
b/core/controller/src/main/scala/whisk/core/controller/AuthenticatedRoute.scala
@@ -17,40 +17,11 @@
 
 package whisk.core.controller
 
-import scala.concurrent.ExecutionContext
-import scala.concurrent.Future
-
 import akka.http.scaladsl.server.Route
-import akka.http.scaladsl.server.Directives._
-import akka.http.scaladsl.model.headers.BasicHttpCredentials
-import akka.http.scaladsl.server.directives._
-import akka.http.scaladsl.server.directives.AuthenticationResult
-import akka.http.scaladsl.model.headers._
 
 import whisk.common.TransactionId
 import whisk.core.entity.Identity
 
-/** A common trait for secured routes */
-trait AuthenticatedRoute {
-
-  /** An execution context for futures */
-  protected implicit val executionContext: ExecutionContext
-
-  /** Creates HTTP BasicAuth handler */
-  def basicAuth[A](verify: Option[BasicHttpCredentials] => Future[Option[A]]) 
= {
-authenticateOrRejectWithChallenge[BasicHttpCredentials, A] { creds =>
-  verify(creds).map {
-case Some(t) => AuthenticationResult.success(t)
-case None=> 
AuthenticationResult.failWithChallenge(HttpChallenges.basic("OpenWhisk secure 
realm"))
-  }
-}
-  }
-
-  /** Validates credentials against database of subjects */
-  protected def validateCredentials(credentials: Option[BasicHttpCredentials])(
-implicit transid: TransactionId): Future[Option[Identity]]
-}
-
 /** A trait for authenticated routes. */
 trait AuthenticatedRouteProvider {
   def routes(user: Identity)(implicit transid: TransactionId): Route
diff --git 
a/core/controller/src/main/scala/whisk/core/controller/Authenticate.scala 
b/core/controller/src/main/scala/whisk/core/controller/BasicAuthenticationDirective.scala
similarity index 58%
rename from 
core/controller/src/main/scala/whisk/core/controller/Authenticate.scala
rename to 
core/controller/src/main/scala/whisk/core/controller/BasicAuthenticationDirective.scala
index bcf4b21c90..90cf006cbd 100644
--- a/core/controller/src/main/scala/whisk/core/controller/Authenticate.scala
+++ 
b/core/controller/src/main/scala/whisk/core/controller/BasicAuthenticationDirective.scala
@@ -17,35 +17,23 @@
 
 package whisk.core.controller
 
-import akka.http.scaladsl.model.headers.BasicHttpCredentials
 import akka.http.scaladsl.model.headers._
-
-import scala.concurrent.ExecutionContext
-import scala.concurrent.Future
-import scala.util.Try
-
-import 

[GitHub] mpmunasinghe opened a new pull request #1: Adding initial sources for Ballerina runtime

2018-07-16 Thread GitBox
mpmunasinghe opened a new pull request #1: Adding initial sources for Ballerina 
runtime
URL: https://github.com/apache/incubator-openwhisk-runtime-ballerina/pull/1
 
 
   - This PR includes the runtime repo structure and source code for Ballerina. 
   - Runtime support for Ballerina 0.975.0 is enabled within this 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] mhenke1 commented on issue #3829: Introduce SPI to swap authentication directives

2018-07-16 Thread GitBox
mhenke1 commented on issue #3829: Introduce SPI to swap authentication 
directives
URL: 
https://github.com/apache/incubator-openwhisk/pull/3829#issuecomment-405181577
 
 
   [PG 3:2532 is ✅ ]


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] codecov-io edited a comment on issue #3835: Limit of binary actions is too low.

2018-07-16 Thread GitBox
codecov-io edited a comment on issue #3835: Limit of binary actions is too low.
URL: 
https://github.com/apache/incubator-openwhisk/pull/3835#issuecomment-402953140
 
 
   # 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=h1)
 Report
   > Merging 
[#3835](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=desc)
 into 
[master](https://codecov.io/gh/apache/incubator-openwhisk/commit/967f00525149544628961eb1a8a1e404679167b7?src=pr=desc)
 will **decrease** coverage by `4.74%`.
   > The diff coverage is `100%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/graphs/tree.svg?width=650=l0YmsiSAso=150=pr)](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=tree)
   
   ```diff
   @@Coverage Diff @@
   ##   master#3835  +/-   ##
   ==
   - Coverage   75.81%   71.06%   -4.75% 
   ==
 Files 146  146  
 Lines6902 6906   +4 
 Branches  428  428  
   ==
   - Hits 5233 4908 -325 
   - Misses   1669 1998 +329
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=tree)
 | Coverage Δ | |
   |---|---|---|
   | 
[...src/main/scala/whisk/core/entity/WhiskEntity.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZW50aXR5L1doaXNrRW50aXR5LnNjYWxh)
 | `91.66% <ø> (ø)` | :arrow_up: |
   | 
[.../scala/src/main/scala/whisk/core/entity/Exec.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZW50aXR5L0V4ZWMuc2NhbGE=)
 | `83.87% <100%> (+0.1%)` | :arrow_up: |
   | 
[.../scala/src/main/scala/whisk/core/WhiskConfig.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvV2hpc2tDb25maWcuc2NhbGE=)
 | `92.06% <100%> (+0.06%)` | :arrow_up: |
   | 
[.../scala/src/main/scala/whisk/core/entity/Size.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZW50aXR5L1NpemUuc2NhbGE=)
 | `96.29% <100%> (+0.14%)` | :arrow_up: |
   | 
[...a/src/main/scala/whisk/core/entity/Parameter.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZW50aXR5L1BhcmFtZXRlci5zY2FsYQ==)
 | `95.34% <100%> (ø)` | :arrow_up: |
   | 
[...core/database/cosmosdb/RxObservableImplicits.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvUnhPYnNlcnZhYmxlSW1wbGljaXRzLnNjYWxh)
 | `0% <0%> (-100%)` | :arrow_down: |
   | 
[...core/database/cosmosdb/CosmosDBArtifactStore.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlLnNjYWxh)
 | `0% <0%> (-95.08%)` | :arrow_down: |
   | 
[...sk/core/database/cosmosdb/CosmosDBViewMapper.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJWaWV3TWFwcGVyLnNjYWxh)
 | `0% <0%> (-92.6%)` | :arrow_down: |
   | 
[...whisk/core/database/cosmosdb/CosmosDBSupport.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJTdXBwb3J0LnNjYWxh)
 | `0% <0%> (-81.82%)` | :arrow_down: |
   | 
[...abase/cosmosdb/CosmosDBArtifactStoreProvider.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlUHJvdmlkZXIuc2NhbGE=)
 | `0% <0%> (-58.83%)` | :arrow_down: |
   | ... and [2 
more](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree-more)
 | |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=continue).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=footer).
 Last update 
[967f005...69cd891](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=lastupdated).
 Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


[GitHub] codecov-io edited a comment on issue #3835: Limit of binary actions is too low.

2018-07-16 Thread GitBox
codecov-io edited a comment on issue #3835: Limit of binary actions is too low.
URL: 
https://github.com/apache/incubator-openwhisk/pull/3835#issuecomment-402953140
 
 
   # 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=h1)
 Report
   > Merging 
[#3835](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=desc)
 into 
[master](https://codecov.io/gh/apache/incubator-openwhisk/commit/967f00525149544628961eb1a8a1e404679167b7?src=pr=desc)
 will **decrease** coverage by `4.74%`.
   > The diff coverage is `100%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/graphs/tree.svg?src=pr=l0YmsiSAso=650=150)](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=tree)
   
   ```diff
   @@Coverage Diff @@
   ##   master#3835  +/-   ##
   ==
   - Coverage   75.81%   71.06%   -4.75% 
   ==
 Files 146  146  
 Lines6902 6906   +4 
 Branches  428  428  
   ==
   - Hits 5233 4908 -325 
   - Misses   1669 1998 +329
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=tree)
 | Coverage Δ | |
   |---|---|---|
   | 
[...src/main/scala/whisk/core/entity/WhiskEntity.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZW50aXR5L1doaXNrRW50aXR5LnNjYWxh)
 | `91.66% <ø> (ø)` | :arrow_up: |
   | 
[.../scala/src/main/scala/whisk/core/entity/Size.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZW50aXR5L1NpemUuc2NhbGE=)
 | `96.29% <100%> (+0.14%)` | :arrow_up: |
   | 
[...a/src/main/scala/whisk/core/entity/Parameter.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZW50aXR5L1BhcmFtZXRlci5zY2FsYQ==)
 | `95.34% <100%> (ø)` | :arrow_up: |
   | 
[.../scala/src/main/scala/whisk/core/entity/Exec.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZW50aXR5L0V4ZWMuc2NhbGE=)
 | `83.87% <100%> (+0.1%)` | :arrow_up: |
   | 
[.../scala/src/main/scala/whisk/core/WhiskConfig.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvV2hpc2tDb25maWcuc2NhbGE=)
 | `92.06% <100%> (+0.06%)` | :arrow_up: |
   | 
[...core/database/cosmosdb/RxObservableImplicits.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvUnhPYnNlcnZhYmxlSW1wbGljaXRzLnNjYWxh)
 | `0% <0%> (-100%)` | :arrow_down: |
   | 
[...core/database/cosmosdb/CosmosDBArtifactStore.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlLnNjYWxh)
 | `0% <0%> (-95.08%)` | :arrow_down: |
   | 
[...sk/core/database/cosmosdb/CosmosDBViewMapper.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJWaWV3TWFwcGVyLnNjYWxh)
 | `0% <0%> (-92.6%)` | :arrow_down: |
   | 
[...whisk/core/database/cosmosdb/CosmosDBSupport.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJTdXBwb3J0LnNjYWxh)
 | `0% <0%> (-81.82%)` | :arrow_down: |
   | 
[...abase/cosmosdb/CosmosDBArtifactStoreProvider.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlUHJvdmlkZXIuc2NhbGE=)
 | `0% <0%> (-58.83%)` | :arrow_down: |
   | ... and [2 
more](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835/diff?src=pr=tree-more)
 | |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=continue).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=footer).
 Last update 
[967f005...69cd891](https://codecov.io/gh/apache/incubator-openwhisk/pull/3835?src=pr=lastupdated).
 Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


[GitHub] jthomas closed pull request #124: v3.16.0 NPM version bump

2018-07-16 Thread GitBox
jthomas closed pull request #124: v3.16.0 NPM version bump
URL: https://github.com/apache/incubator-openwhisk-client-js/pull/124
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/package.json b/package.json
index 6458306..0fabf59 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
 {
   "name": "openwhisk",
-  "version": "3.15.0",
+  "version": "3.16.0",
   "description": "JavaScript client library for the OpenWhisk platform",
   "main": "lib/main.js",
   "typings": "lib/main.d.ts",


 


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 closed issue #123: 3.16.0 release

2018-07-16 Thread GitBox
jthomas closed issue #123: 3.16.0 release
URL: https://github.com/apache/incubator-openwhisk-client-js/issues/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] cbickel opened a new pull request #274: Remove required access to the whole couchdb database.

2018-07-16 Thread GitBox
cbickel opened a new pull request #274: Remove required access to the whole 
couchdb database.
URL: https://github.com/apache/incubator-openwhisk-package-kafka/pull/274
 
 
   Currently the kafka-trigger needs admin access on the whole couch-database, 
to get all databases that exist. If not all permissions are granted, the 
provider fails to start.
   With this change, the access on all databases is not needed anymore, but 
only on the required database.


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] codecov-io edited a comment on issue #3829: Introduce SPI to swap authentication directives

2018-07-16 Thread GitBox
codecov-io edited a comment on issue #3829: Introduce SPI to swap 
authentication directives
URL: 
https://github.com/apache/incubator-openwhisk/pull/3829#issuecomment-402040451
 
 
   # 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829?src=pr=h1)
 Report
   > Merging 
[#3829](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829?src=pr=desc)
 into 
[master](https://codecov.io/gh/apache/incubator-openwhisk/commit/967f00525149544628961eb1a8a1e404679167b7?src=pr=desc)
 will **decrease** coverage by `4.81%`.
   > The diff coverage is `0%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829/graphs/tree.svg?height=150=l0YmsiSAso=650=pr)](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829?src=pr=tree)
   
   ```diff
   @@Coverage Diff@@
   ##   master   #3829  +/-   ##
   =
   - Coverage   75.81% 71%   -4.82% 
   =
 Files 146 145   -1 
 Lines69026897   -5 
 Branches  428 418  -10 
   =
   - Hits 52334897 -336 
   - Misses   16692000 +331
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829?src=pr=tree)
 | Coverage Δ | |
   |---|---|---|
   | 
[...core/controller/BasicAuthenticationDirective.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829/diff?src=pr=tree#diff-Y29yZS9jb250cm9sbGVyL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udHJvbGxlci9CYXNpY0F1dGhlbnRpY2F0aW9uRGlyZWN0aXZlLnNjYWxh)
 | `61.53% <0%> (ø)` | |
   | 
[...rc/main/scala/whisk/core/controller/RestAPIs.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829/diff?src=pr=tree#diff-Y29yZS9jb250cm9sbGVyL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvY29udHJvbGxlci9SZXN0QVBJcy5zY2FsYQ==)
 | `43.9% <0%> (-1.67%)` | :arrow_down: |
   | 
[...core/database/cosmosdb/RxObservableImplicits.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvUnhPYnNlcnZhYmxlSW1wbGljaXRzLnNjYWxh)
 | `0% <0%> (-100%)` | :arrow_down: |
   | 
[...core/database/cosmosdb/CosmosDBArtifactStore.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlLnNjYWxh)
 | `0% <0%> (-95.08%)` | :arrow_down: |
   | 
[...sk/core/database/cosmosdb/CosmosDBViewMapper.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJWaWV3TWFwcGVyLnNjYWxh)
 | `0% <0%> (-92.6%)` | :arrow_down: |
   | 
[...whisk/core/database/cosmosdb/CosmosDBSupport.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJTdXBwb3J0LnNjYWxh)
 | `0% <0%> (-81.82%)` | :arrow_down: |
   | 
[...abase/cosmosdb/CosmosDBArtifactStoreProvider.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJBcnRpZmFjdFN0b3JlUHJvdmlkZXIuc2NhbGE=)
 | `0% <0%> (-58.83%)` | :arrow_down: |
   | 
[...la/whisk/core/database/cosmosdb/CosmosDBUtil.scala](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829/diff?src=pr=tree#diff-Y29tbW9uL3NjYWxhL3NyYy9tYWluL3NjYWxhL3doaXNrL2NvcmUvZGF0YWJhc2UvY29zbW9zZGIvQ29zbW9zREJVdGlsLnNjYWxh)
 | `92% <0%> (-4%)` | :arrow_down: |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829?src=pr=continue).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829?src=pr=footer).
 Last update 
[967f005...43f501c](https://codecov.io/gh/apache/incubator-openwhisk/pull/3829?src=pr=lastupdated).
 Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


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