You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kie.apache.org by "MarianMacik (via GitHub)" <gi...@apache.org> on 2023/09/27 15:19:14 UTC
[GitHub] [incubator-kie-kogito-docs] MarianMacik commented on a diff in pull request #507: [KOGITO-9838] Add a troubleshooting guide for remove service invocations
MarianMacik commented on code in PR #507:
URL: https://github.com/apache/incubator-kie-kogito-docs/pull/507#discussion_r1338776525
##########
serverlessworkflow/modules/ROOT/pages/service-orchestration/troubleshooting.adoc:
##########
@@ -0,0 +1,70 @@
+= Troubleshooting Remote Service Invocations
+:compat-mode!:
+// Metadata:
+:description: Troubleshooting remote service invocations
+:keywords: workflow, serverless, openapi, services, json, http, tls, https
+// Links:
+:apache_http_client_url: https://hc.apache.org/httpcomponents-client-5.2.x/
+
+This document describes an ongoing list of known issues while invoking remote services from workflows such as OpenAPI functions.
+
+== Turning HTTP tracing on
+
+Under the hood, {product_name} uses link:{apache_http_client_url}[Apache HTTP Client]. You can turn HTTP requests and responses tracing by setting the following property:
+
+.Turning HTTP tracing on
+[source,properties]
+----
+quarkus.log.category."org.apache.http".level=DEBUG
+----
+
+Reset the application so the log configuration is propagated. After that, you can find HTTP tracing in your logs.
+
+.HTTP Request trace
+[source,log,subs="attributes+"]
+----
+...
+2023-09-25 19:00:55,242 DEBUG Executing request POST /v2/models/yolo-model/infer HTTP/1.1
+...
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> POST /v2/models/yolo-model/infer HTTP/1.1 <1>
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> Accept: application/json
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> Content-Type: application/json
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> kogitoprocid: inferencepipeline <2>
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> kogitoprocinstanceid: 85114b2d-9f64-496a-bf1d-d3a0760cde8e <3>
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> kogitoprocist: Active
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> kogitoproctype: SW
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> kogitoprocversion: 1.0
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> Content-Length: 23177723
+2023-09-25 19:00:55,244 DEBUG http-outgoing-0 >> Host: yolo-model-opendatahub-model.apps.trustyai.dzzt.p1.openshiftapps.com
+...
+----
+
+1. The path where the client will make the HTTP invocation
+2. The workflow definition id
+3. The workflow instance (execution) id
+
+In the example above, you have access to every portion of the HTTP request and can verify if something is wrong during the message creation.
+For example, you can use the `kogitoprocinstanceid` header to trace this HTTP message in the logs.
+
+For responses, you should be able to see the details below the request body:
+
+.HTTP Response trace
+[source,log,subs="attributes+"]
+----
+...
+2023-09-25 19:01:00,738 DEBUG http-outgoing-0 << "HTTP/1.1 500 Internal Server Error[\r][\n]"
Review Comment:
```suggestion
2023-09-25 19:01:00,738 DEBUG http-outgoing-0 << "HTTP/1.1 500 Internal Server Error[\r][\n]" <1>
```
##########
serverlessworkflow/modules/ROOT/pages/service-orchestration/troubleshooting.adoc:
##########
@@ -0,0 +1,70 @@
+= Troubleshooting Remote Service Invocations
+:compat-mode!:
+// Metadata:
+:description: Troubleshooting remote service invocations
+:keywords: workflow, serverless, openapi, services, json, http, tls, https
+// Links:
+:apache_http_client_url: https://hc.apache.org/httpcomponents-client-5.2.x/
+
+This document describes an ongoing list of known issues while invoking remote services from workflows such as OpenAPI functions.
+
+== Turning HTTP tracing on
+
+Under the hood, {product_name} uses link:{apache_http_client_url}[Apache HTTP Client]. You can turn HTTP requests and responses tracing by setting the following property:
+
+.Turning HTTP tracing on
+[source,properties]
+----
+quarkus.log.category."org.apache.http".level=DEBUG
+----
+
+Reset the application so the log configuration is propagated. After that, you can find HTTP tracing in your logs.
+
+.HTTP Request trace
+[source,log,subs="attributes+"]
+----
+...
+2023-09-25 19:00:55,242 DEBUG Executing request POST /v2/models/yolo-model/infer HTTP/1.1
+...
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> POST /v2/models/yolo-model/infer HTTP/1.1 <1>
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> Accept: application/json
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> Content-Type: application/json
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> kogitoprocid: inferencepipeline <2>
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> kogitoprocinstanceid: 85114b2d-9f64-496a-bf1d-d3a0760cde8e <3>
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> kogitoprocist: Active
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> kogitoproctype: SW
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> kogitoprocversion: 1.0
+2023-09-25 19:00:55,243 DEBUG http-outgoing-0 >> Content-Length: 23177723
+2023-09-25 19:00:55,244 DEBUG http-outgoing-0 >> Host: yolo-model-opendatahub-model.apps.trustyai.dzzt.p1.openshiftapps.com
+...
+----
+
+1. The path where the client will make the HTTP invocation
+2. The workflow definition id
+3. The workflow instance (execution) id
+
+In the example above, you have access to every portion of the HTTP request and can verify if something is wrong during the message creation.
+For example, you can use the `kogitoprocinstanceid` header to trace this HTTP message in the logs.
+
+For responses, you should be able to see the details below the request body:
+
+.HTTP Response trace
+[source,log,subs="attributes+"]
+----
+...
+2023-09-25 19:01:00,738 DEBUG http-outgoing-0 << "HTTP/1.1 500 Internal Server Error[\r][\n]"
+2023-09-25 19:01:00,738 DEBUG http-outgoing-0 << "content-type: application/json[\r][\n]"
+2023-09-25 19:01:00,738 DEBUG http-outgoing-0 << "date: Mon, 25 Sep 2023 19:01:00 GMT[\r][\n]"
+2023-09-25 19:01:00,738 DEBUG http-outgoing-0 << "content-length: 186[\r][\n]"
+2023-09-25 19:01:00,738 DEBUG http-outgoing-0 << "set-cookie: 276e4597d7fcb3b2cba7b5f037eeacf5=5427fafade21f8e7a4ee1fa6c221cf40; path=/; HttpOnly; Secure; SameSite=None[\r][\n]"
+2023-09-25 19:01:00,738 DEBUG http-outgoing-0 << "[\r][\n]"
+2023-09-25 19:01:00,738 DEBUG http-outgoing-0 << "{"code":13, "message":"Failed to load Model due to adapter error: Error calling stat on model file: stat /models/yolo-model__isvc-1295fd6ba9/yolov5s-seg.onnx: no such file or directory"}" <1>
Review Comment:
```suggestion
2023-09-25 19:01:00,738 DEBUG http-outgoing-0 << "{"code":13, "message":"Failed to load Model due to adapter error: Error calling stat on model file: stat /models/yolo-model__isvc-1295fd6ba9/yolov5s-seg.onnx: no such file or directory"}" <2>
```
##########
serverlessworkflow/modules/ROOT/nav.adoc:
##########
@@ -31,6 +31,7 @@
*** xref:service-orchestration/configuring-openapi-services-endpoints.adoc[Advanced Configuration]
*** xref:service-orchestration/working-with-openapi-callbacks.adoc[Callbacks]
** xref:service-orchestration/orchestration-of-grpc-services.adoc[gRPC]
+** xref:service-orchestration/troubleshooting.adoc[Troubleshooting]
Review Comment:
Shouldn't this be under the "Orchestration of OpenAPI-based services"? Because it is connected with just OpenAPI afaik, not with GRPC for example.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@kie.apache.org
For additional commands, e-mail: commits-help@kie.apache.org