jmatthews-bts-hub opened a new issue, #5610:
URL: https://github.com/apache/hop/issues/5610

   ### Apache Hop version?
   
   2.13 +
   
   ### Java version?
   
   17.0.6
   
   ### Operating system
   
   Windows
   
   ### What happened?
   
   In our use case, we use the Workflow HTTP action to call a URL and retrieve 
a document in response, which is saved to a temp directory. The request 
requires several headers to be set. In testing, we found that the HTTP action 
always resulted in a 403 Forbidden response, though when we tested this through 
an HTTP client like Postman, it would succeed. 
   After debugging, we discovered the following code in the ActionHttp class 
(at least in 2.13 and current hop version, might have been this way for a long 
time)
   
   <img width="582" height="435" alt="Image" 
src="https://github.com/user-attachments/assets/ba404eaa-507d-441d-8940-996894a7220a";
 />
   
   The for loop that adds headers to the URLConnection uses "j" as the 
iterator, but when selecting from the headers list, it uses "i". It appears 
that, for each iteration, "i" is always 0, so only the _first header_ in the 
list is ultimately added.
   
   We have previously used PDI as a component in our Java application, and have 
been working to migrate to Hop in an upcoming release, but this actually breaks 
a fairly important feature for us. Hoping this can be addressed quickly. Thank 
you.
   
   ### Issue Priority
   
   Priority: 2
   
   ### Issue Component
   
   Component: Actions


-- 
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