Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Connection has been closed BEFORE response, while sending request body #1695

Closed
niuzhimin opened this issue Jun 25, 2021 · 13 comments
Closed
Labels
status/duplicate This is a duplicate of another issue type/bug A general bug

Comments

@niuzhimin
Copy link

niuzhimin commented Jun 25, 2021

Description:

First of all, this error is reported by gateway gateway

The reason for the error is that the size of the image uploaded on the web service exceeds the configuration of spring. Servlet. Multipart. Max file size = 10MB, but it is intercepted in the file Upload Interceptor of the web service and gives a friendly response. I don't know why the gateway reported this mistake

Ask the great God to answer

@niuzhimin niuzhimin added status/need-triage A new issue that still need to be evaluated as a whole type/bug A general bug labels Jun 25, 2021
@violetagg
Copy link
Member

@niuzhimin Most probably this is a duplicate to #1478. Please check your Spring Cloud Gateway version.

@violetagg violetagg added for/user-attention This issue needs user attention (feedback, rework, etc...) and removed status/need-triage A new issue that still need to be evaluated as a whole labels Jun 25, 2021
@niuzhimin
Copy link
Author

@violetagg The spring cloud gateway version is 2.1.1 I just had a look #1478 I don't see the solution。Can you give us a detailed answer please

@niuzhimin
Copy link
Author

@violetagg Why and how to solve this problem? Is it related to the gateway version?

1 similar comment
@niuzhimin
Copy link
Author

@violetagg Why and how to solve this problem? Is it related to the gateway version?

@violetagg
Copy link
Member

violetagg commented Jun 25, 2021

@niuzhimin This has been fixed in Reactor Netty v1.0.4 which is Spring Cloud Gateway v3.0.2. Yes you need to update your Spring Cloud Gateway version.

The fix that was made is that you will receive the original error from the server i.e. error code 400, describing that the upload size is invalid.

@niuzhimin
Copy link
Author

What is the corresponding version of springboot?

@violetagg
Copy link
Member

What is the corresponding version of springboot?

Spring Boot v2.4.3/v2.5.0

@niuzhimin
Copy link
Author

Does it have to be this high?

@violetagg
Copy link
Member

Does it have to be this high?

I didn't get it

Reactor Netty 1.0.4 (where the fix was included for the first time) is available with Spring Boot v2.4.3.
Spring Boot v2.5.0 contains the fix from the very beginning.

@niuzhimin
Copy link
Author

Well, I mean, is it compatible with other versions? If the spring boot version is 2.4.3, the cloud service version must be the latest. Is there any other solution? As long as the gateway does not report an error and gives a friendly prompt that the upload of files is restricted

@violetagg
Copy link
Member

Well, I mean, is it compatible with other versions? If the spring boot version is 2.4.3, the cloud service version must be the latest. Is there any other solution? As long as the gateway does not report an error and gives a friendly prompt that the upload of files is restricted

That should be discussed with Spring Cloud Gateway maintainers ...

@niuzhimin
Copy link
Author

OK, thank you very much for your help, beautiful lady

@violetagg
Copy link
Member

@niuzhimin Let me close this issue as duplicate. We can reopen it, if it is needed.

@violetagg violetagg added status/duplicate This is a duplicate of another issue and removed for/user-attention This issue needs user attention (feedback, rework, etc...) labels Jun 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status/duplicate This is a duplicate of another issue type/bug A general bug
Projects
None yet
Development

No branches or pull requests

2 participants