You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a resource created on an application, which lists multiple methods for the same method type.
I'm doing this because I want to validate the same endpoint, with a POST request, based on:
Header query match
Parameter query match
JSON Path
and I couldn't find a way to keep them all enabled at the same time (only one of them would work at a time).
So my dashboard currently looks like this:
Notice that the "Add breed image payload validation" POST is with status "Mocked".
When testing the request, however, I'm getting the following error:
guites@local:~$ curl -X POST http://localhost:8080/castlemock/mock/rest/project/FJnf4e/application/PbRJXP/api/breed/{breed}/images
{"timestamp":"2023-12-14T20:57:12.197+00:00","status":500,"error":"Internal Server Error","path":"/castlemock/mock/rest/project/FJnf4e/application/PbRJXP/api/breed/breed/images"}
checking the docker logs gives me the following:
2023-12-14 20:57:12.195 ERROR 1 --- [nio-8080-exec-9] o.s.b.w.s.s.ErrorPageFilter : Forwarding to error page from request [/mock/rest/project/FJnf4e/application/PbRJXP/api/breed/breed/images] due to exception [The requested REST method, Add breed image path parameter validation, is disabled]
com.castlemock.web.mock.rest.model.RestException: The requested REST method, Add breed image path parameter validation, is disabled
at com.castlemock.web.mock.rest.controller.mock.AbstractRestServiceController.process(AbstractRestServiceController.java:141) ~[web-mock-rest-1.65.jar:?]
at com.castlemock.web.mock.rest.controller.mock.RestServiceController.postMethod(RestServiceController.java:88) ~[web-mock-rest-1.65.jar:?]
at jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103) ~[?:?]
...
...
It says " Forwarding to error page from request [/mock/rest/project/FJnf4e/application/PbRJXP/api/breed/breed/images] due to exception [The requested REST method, Add breed image path parameter validation, is disabled]".
Well that is true, it is disabled, but shouldn't it default to the one that is enabled?
First of all, thank you guys for the project.
Describe the bug
I have a resource created on an application, which lists multiple methods for the same method type.
I'm doing this because I want to validate the same endpoint, with a POST request, based on:
and I couldn't find a way to keep them all enabled at the same time (only one of them would work at a time).
So my dashboard currently looks like this:
Notice that the "Add breed image payload validation" POST is with status "Mocked".
When testing the request, however, I'm getting the following error:
checking the docker logs gives me the following:
It says " Forwarding to error page from request [/mock/rest/project/FJnf4e/application/PbRJXP/api/breed/breed/images] due to exception [The requested REST method, Add breed image path parameter validation, is disabled]".
Well that is true, it is disabled, but shouldn't it default to the one that is enabled?
To Reproduce
Steps to reproduce the behavior:
Expected behavior
I expected the other enabled method for the same method type to take over and work.
Screenshots
If applicable, add screenshots to help explain your problem.
Castle Mock
Java:
openjdk 21-ea 2023-09-19
OpenJDK Runtime Environment (build 21-ea+29-2411)
OpenJDK 64-Bit Server VM (build 21-ea+29-2411, mixed mode, sharing)
Running from docker, with
castlemock/castlemock:latest
.Desktop (please complete the following information):
The text was updated successfully, but these errors were encountered: