rabbah commented on a change in pull request #3199: One tid for the whole 
system.
URL: 
https://github.com/apache/incubator-openwhisk/pull/3199#discussion_r185511237
 
 

 ##########
 File path: common/scala/src/main/scala/whisk/http/BasicHttpService.scala
 ##########
 @@ -97,7 +105,20 @@ trait BasicHttpService extends Directives with 
TransactionCounter {
       case Some(value) => value.toLowerCase == "on"
       case None        => false
     }
-    extract(_ => transid(extraLogging))
+    extract { req =>
+      val tid =
+        req.request.headers
+          .find(_.name == TransactionId.generatorConfig.header)
+          .map(_.value)
+          .filterNot(_.startsWith(TransactionId.systemPrefix))
+          .getOrElse {
+            // As this is only a fallback, because the tid should be generated 
by nginx, this shouldn't be used.
 
 Review comment:
   did you consider if we should add a log warning when a header is missing?

----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

Reply via email to