无效的URI:URI字符串太长httpget
下午好。我遇到了一个问题。我需要将一个微服务的get请求中的列表发送到另一个字符串,这些字符串是5到10个字符,但是我在此列表中有2000个项目。返回一个错误,即URL太长。当试图找到问题的答案时,我发现最大长度为2083个字符。由于这是一个获取请求,因此无法使用身体。如何在Get请求中将如此大的数据发送到另一个微服务?
Good afternoon. I ran into a problem. I need to send a List in a GET request from one microservice to another, these strings are from 5 to 10 characters, but I have 2000 items in this list. Returns an error that the URL is too long. When trying to find the answer to the problem, I found out that the maximum length is 2083 characters. Since this is a GET request and there is no way to use the body. How can I send such a large amount of data to another microservice in a GET request?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
谢谢您的建议。
我再次查看了这个问题,并认为获得请求并不是必需的。但是,我决定使用补丁而不是帖子,因为我不想将其与其他适当的帖子请求混淆,并且在其他任何地方都没有使用补丁。
Thank you Wouter de Kort ♦ for the suggestion.
I looked at the problem again and decided GET request wasn't really necessary. However, I decided to use PATCH instead of POST because I didn't want to confuse it with other proper POST requests and I didn't use PATCH anywhere else.