xukiw opened a new issue #7810:
URL: https://github.com/apache/dolphinscheduler/issues/7810


   ### Search before asking
   
   - [X] I had searched in the 
[issues](https://github.com/apache/dolphinscheduler/issues?q=is%3Aissue) and 
found no similar issues.
   
   
   ### What happened
   
   It seems that the result returned by the request is not saved to varpool,the 
handle method:
   public void handle() throws Exception {
   
           String threadLoggerInfoName = String.format(TASK_LOG_INFO_FORMAT, 
taskExecutionContext.getTaskAppId());
           Thread.currentThread().setName(threadLoggerInfoName);
   
           long startTime = System.currentTimeMillis();
           String formatTimeStamp = DateUtils.formatTimeStamp(startTime);
           String statusCode = null;
           String body = null;
   
           try (CloseableHttpClient client = createHttpClient();
                CloseableHttpResponse response = sendRequest(client)) {
               statusCode = String.valueOf(getStatusCode(response));
               body = getResponseBody(response);
               exitStatusCode = validResponse(body, statusCode);
               long costTime = System.currentTimeMillis() - startTime;
               logger.info("startTime: {}, httpUrl: {}, httpMethod: {}, 
costTime : {} milliseconds, statusCode : {}, body : {}, log : {}",
                       formatTimeStamp, httpParameters.getUrl(),
                       httpParameters.getHttpMethod(), costTime, statusCode, 
body, output);
           } catch (Exception e) {
               appendMessage(e.toString());
               exitStatusCode = -1;
               logger.error("httpUrl[" + httpParameters.getUrl() + "] 
connection failed:" + output, e);
               throw e;
           }
   
       }
   
   ### What you expected to happen
   
   Save the http response to varpool。
   
   ### How to reproduce
   
   Create a successor task after the HTTP task。
   
   ### Anything else
   
   _No response_
   
   ### Version
   
   2.0.1
   
   ### Are you willing to submit PR?
   
   - [ ] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [X] I agree to follow this project's [Code of 
Conduct](https://www.apache.org/foundation/policies/conduct)
   


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

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to