2 Commits

Author SHA1 Message Date
Kevin Mai-Husan Chia
fbb344d78c Accept session id from url params in API /notarize (#16)
* feat: accept sessionId in url

Required by the browser to pass session id with Websocket API

* feat: server accept session id entirely through url params

* Update openapi.yaml and README for url param sessionId

* Update src/domain/notary.rs

Co-authored-by: Christopher Chong <t.kleinchong@gmail.com>

* Update tests/integration_test.rs

Co-authored-by: Christopher Chong <t.kleinchong@gmail.com>

---------

Co-authored-by: Christopher Chong <t.kleinchong@gmail.com>
2023-10-11 11:02:29 +08:00
Christopher Chong
9b9bce8412 Implement websocket and http apis. (#6)
* Add logic to promote to http and then downgrade to tcp for notarization.

* Fix client hang issueno

* Change channel message type.

* Fix response parsing from notary.

* Fix websocket implementation and use upgrade protocol for raw tcp.

* Modify test to mimick browser extension for websocket test.

* Refactor tcp client handling.

* Add global store for persistent data.

* Finish websocket handler and test.

* Add comments.

* Add more comments and documentation.

* Add openapi.yaml.

* Modify README.

* Add architecture explanation.

* Modify README.

* Fix PR based on comments.

* Combine tcp and websocket extractors.

* Refactor and fix documentations.
2023-08-30 14:52:25 +08:00