h3. What
Configure mockbackend, such as wiremock to have an FCM endpoint, with reasonable HTTP response
h3. Why
For stress-testing we should not talk directly to FCM, but against some other mock tool, like wiremock
h3. How
* start wiremock , like: {code} java -jar wiremock-standalone-2.4.1.jar --port 9090 {code} * import a rule for faking FCM backend response , like: {code} curl -X POST --data '{ "request": { "url": "/fcm/send", "method": "POST" }, "response": { "status": 200, "fixedDelayMilliseconds": 20000, "jsonBody": {"multicast_id": 108,"success": 1,"failure": 0,"canonical_ids": 0,"results": [{ "message_id": "1:08"}]}, "headers": {"Content-Type": "application/json"}}}' http://localhost:9090/__admin/mappings/new {code}
h3. Result/Verification
Fake/Mock route is present |
|