1

I am getting Multipart request from UI to upload csv file but call is going through one orchestrator service (dropwizard-version : 0.9.2) to target service (dropwizard-version : 1.2.2) for upload. While adding support for Multipart request in orchestrator service using MultipartRequestEntity, call is failing at target service with error -

[2022-03-08 16:23:44,474] io.dropwizard.jersey.errors.LoggingExceptionMapper: Error handling a request: 4c0693ee31713edf
! java.util.concurrent.TimeoutException: Idle timeout expired: 30005/30000 ms
! at org.eclipse.jetty.io.IdleTimeout.checkIdleTimeout(IdleTimeout.java:166)
! at org.eclipse.jetty.io.IdleTimeout$1.run(IdleTimeout.java:50)

Expected Request at Resource Layer for both services :

public void request(@FormDataParam("file") InputStream body,
@FormDataParam("file") FormDataContentDisposition fileDetails,
@FormDataParam("comment") String comment){}                                 

Is there any solution for this?

Abhishek
  • 11
  • 1
  • It says in the exception. `Idle timeout expired: 30005/30000 ms` Something took longer than 30 seconds to process. I would either go find out why it takes 30 seconds and see if I can do something about that. Or increase the timeout. – Erik Mar 11 '22 at 14:15

1 Answers1

0

In this case tried using JerseyClient instead of HTTP Client in orchestrator service for making call to target service, created temporary csv file in orchestrator service and sent updated Headers (Content-Type, Content-Encoding, Content-Length, Content-Language, Host) while making call to target service, which is working fine.

Abhishek
  • 11
  • 1
  • 1
    Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Apr 11 '22 at 06:32