Questions tagged [mockserver-netty]

12 questions
2
votes
1 answer

How to return custom object with byte array field using MockServer?

I am using MockServer org.mock-server mockserver-netty 5.10.0 I'd like to return custom object with which contain many…
TuGordoBello
  • 4,350
  • 9
  • 52
  • 78
1
vote
0 answers

Reducing log level to INFO for Karate Netty Server

I am running the Karate Netty Mock Server as forward proxy server in my QA environment. Our QA environment is prod-alike and gets a huge amount of traffic. I was wondering if there is a way to reduce the log levels to INFO rather than DEBUG ? Also I…
1
vote
2 answers

Changing Request Headers when Karate Netty Server is used as a forward proxy server

I have a use case where I am running the Karate Netty server as a forward proxy server to forward requests to a target Tomcat server. I noted that the hostname header gets set to the Karate Netty Server while forwarding the request which causes the…
1
vote
0 answers

java.lang.ClassNotFoundException: org.mockserver.version.Version

I am trying to start mock server with mockserver-netty-5.13.2 from shell, java version: 11.0.9 Rough shell code like this: java -version echo "start shell before java -jar line" java -jar ./mockserver-netty-5.13.2.jar -serverPort 9090 -logLevel…
1
vote
1 answer

Starting Karate Mock server with karate standalone jar

I am trying to use Karate Mock Server to replace my Wiremock server to mock API calls. Since I need to start Karate as a server, I am wondering what are the minimum maven dependencies I need to start the karate server? Do I just need Karate Netty…
1
vote
0 answers

Mockserver fails to read request: unknown message format

I need to test some REST client. For that purpose I'm using org.mockserver.integration.ClientAndServer I start my server. Create some expectation. After that I mock my client. Run this client. But when server receives request I see in…
Igor_M
  • 308
  • 2
  • 12
0
votes
0 answers

mock-server running as war inside Tomcat

I am running Tomcat 10.1.6 and deployed mockserver-war-5.15.0.war. I get the following exception Exception jakarta.servlet.ServletException: Class [org.mockserver.mockservlet.MockServerServlet] is not a Servlet …
jprism
  • 3,239
  • 3
  • 40
  • 56
0
votes
0 answers

Unable to use Mustache template with Mockserver alternate response

I have a MockServer 5.14.0 (Netty) application running as a Docker container. I'm trying to setup an expectation that based on a given GET request by identifier, if the resource exists, return the dataset available for the same, otherwise a…
x80486
  • 6,627
  • 5
  • 52
  • 111
0
votes
1 answer

MockServer with test specific session id

I use SpringBoot and Java to write e2e tests for my API. Along the flow, I am doing an HTTP call to a storage API (S3), and I am mocking it using MockServer. This is the HttpClient and how I am creating my post request: public class HttpClient { …
0
votes
1 answer

MockServer -> Return custom object response

I am trying to return custom object response from mockserver. In client side, I am expecting to get response as "GetChannelsResponse". ResponseEntity response = restTemplate.exchange(url, HttpMethod.GET, request, A.class); Here is the model…
0
votes
1 answer

MockServer unexpectedly responds with empty body

Let's see a test, which is using MockServer (org.mock-server:mockserver-netty:5.10.0) for mocking responses. It is expected that the response body will be equal to string "something". Nevertheless, this test fails, because the response body is an…
diziaq
  • 6,881
  • 16
  • 54
  • 96
-1
votes
1 answer

MockServer with IPv6

I'm running a client issuing some request against MockServer. When calling MockServer with its IPv4 address everything works well but when calling it via IPv6 MockServer throws an exception: 021-07-23 13:57:39 5.11.1 SEVERE 8889 exception…
stefan
  • 658
  • 2
  • 9
  • 31