Hi all. I’m using wiremock as standalone app, usin...
# help
d
Hi all. I’m using wiremock as standalone app, using docker-compose container configuration. I need some stubs to have state. For example
POST /resource
and afterwards on
GET /resource/{id}
I want to return the same state which is returned on
POST /resource
. Can someone help me with some guides how to achieve this using wiremock? What will be the best approach, is there some extension that supports this? Thanks!
l
Hi, There is an extension by @Dirk Bolte that supports this: https://github.com/wiremock/wiremock-extension-state There is also a demo project in that repo which might give you a good start - https://github.com/wiremock/wiremock-extension-state/tree/develop/demo If you want to see this in action, there was a really cool webinar where @Dirk Bolte and @Oleg Nenashev go through what the extension can do and demonstrate a frontend using wiremock with the extension:

https://www.youtube.com/watch?v=OUrMEpzHbvY

👍 1
d
Thanks for the fast response! I’ll go through it. I hope I’ll figure it out easily.
l
No worries. I haven’t used it myself but ask any questions you have here and we can help the best we can
🙌 2
d
Works perfectly! Thank you so much.
👍 3