- probe endpoint -> creates info about video
- long running operation -> use asynchronous API
- using REST endpoint to push request into MQ
- actual probe operation is asynchronous, consuming MQ
-
push probe url as new requested operation into MQ
-
return immediately
-
Can be tested with
curl localhost:8080/probe -XPOST -H "Content-Type: application/json" -d '{ "url": "http://localhost/videos/5.mp4"}'
- receive probe operations from MQ
- download video, store locally in temp file
- probe with ffmpeg
- saves results into video info service
- cleanup temp file
- CRUD information about video
- REST endpoints
- called by probe worker to add video information
-
example
curl "http://localhost:8081/infos?name=2.mp4"