Hi Team, I have been trying some solution but no l...
# help
f
Hi Team, I have been trying some solution but no luck on getting post body using wire mock , i have been trying to add post body for '.body(BodyInserters.fromMultipartData(builder.build())' vbut keep getting 500, would really appreciate any help
o
Hello, could you please share the whole response initialization code?
f
return <http://client.post|client.post>().body(BodyInserters.fromMultipartData(builder.build()).retrive().bodyToMono(TestClass.class).onErrorMap(e-> throw cx exception).block()
MultipartBodyBuilder builder= new MultipartBodyBuilder(); builder.asyncPart("content",Flux<DataBufffer> content, DataBuffer.class).filename('test.pdf').contentType(MediaType.Application_pdf);builder.part("accessList","testaccess");
this one is builder part
if I comment out body part, wire mock test passed w/o any error
but with body in post its giving me 500
o
Normally services are not expected to respond with information in POST, so maybe it's automatic assertion just for this request type. Do you see any information in the log?
f
Thanks Oleg, , I will check out assertion and update you
I did comment out assertion but we are still getting same 500 internal server error , with original stack trace : at reactor.netty.http.client.HttpClientOperations.inInbountNext
o
Could you please provide the full stacktrace? Including the error message in the log if possible
f
sure , will do