Closed nneves closed 11 years ago
Got the sync version of the current REST endpoints implemented, new callback queue list will hook to rest.js:jsonStream channel to listen to printer/system response messages and reply back to the Client/Browser via the callback!
Also, from the UI side things got hooked up to the current channel already implemented for the socket.io/WebSockets channel.
Current available REST endpoint only support async requests and would response with a {"response": "ok"}; message without waiting for the printer response (ack from the rest app and not from the printer), data was then fetched from socket.io channel.
Getting this a bit more cleaned, REST should have async ans sync endpoint versions, where the sync should only respond to request after the printer response has been triggered (using a callback queue for that effect).