• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Liutauras Vilda
  • Bear Bibeault
  • Paul Clapham
  • Jeanne Boyarsky
  • Devaka Cooray
  • Junilu Lacar
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Ron McLeod
  • Tim Holloway
  • Claude Moore
  • Stephan van Hulst
  • Winston Gutkowski
  • Carey Brown
  • Frits Walraven

Using Wiremock post ends in IOException Buffer size exceeded  RSS feed

Ranch Hand
Posts: 45
Eclipse IDE Java Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Wiremock is a fantastic tool to simulate a REST-Api. I have tried many examples and they work quite well. But I have a problem while simulating a multipart-post-service. As far as I have understood it correctly this would be the way to configure the stup:

I don't want to consider any specifactions of the multipart-request-body, so I think there is no need to use withMultipartRequestBody.But when I post the data I get the following error:

java.io.IOException: Buffer size exceeded: no line terminator at org.eclipse.jetty.util.ReadLineInputStream.readLine(ReadLineInputStream.java:55)
at org.eclipse.jetty.util.MultiPartInputStreamParser$Base64InputStream.read(MultiPartInputStreamParser.java:805)
at org.eclipse.jetty.util.MultiPartInputStreamParser.parse(MultiPartInputStreamParser.java:638)
at org.eclipse.jetty.util.MultiPartInputStreamParser.getParts(MultiPartInputStreamParser.java:400)
at org.eclipse.jetty.server.Request.getParts(Request.java:2147)
at org.eclipse.jetty.server.Request.getParts(Request.java:2099)
at com.github.tomakehurst.wiremock.servlet.WireMockHttpServletRequestAdapter.safelyGetRequestParts(WireMockHttpServletRequestAdapter.java:295)...

How can I solve the problem and why Wiremock starts parsing the http-body?

Thanks in advance.

Wanna see my flashlight? How about this tiny ad?
ScroogeXHTML 8.2 - easy to use RTF to HTML converter library
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!