You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
This is not an issue, but a refactor
The wws-server uses the wws-worker crate to get a response for the different requests. To run the worker module, it requires to transform the input from a HttpRequest to WasmInput (JSON) and the output from WasmOutput (JSON) to a HttpResponse.
The input transformation is done in the wws-worker while the output is managed by the wws-server. This is an incosistent behavior.
Describe the solution you'd like
We should establish the right boundaries and moving transformations to a single place. I would say the wws-worker shouldn't require on actix-web. For this reason, the input transformations must be moved to wws-server and keep wws-worker to work only with WasmInput and WasmOutput structs.
Describe alternatives you've considered
I also considered to move the output transformation logic to the wws-worker crate. However, this approach reduces the reusability of the wws-worker crate as it now depends to actix-web.
Is your feature request related to a problem? Please describe.
This is not an issue, but a refactor
The
wws-server
uses thewws-worker
crate to get a response for the different requests. To run the worker module, it requires to transform the input from aHttpRequest
toWasmInput (JSON)
and the output fromWasmOutput (JSON)
to aHttpResponse
.The input transformation is done in the
wws-worker
while the output is managed by thewws-server
. This is an incosistent behavior.Describe the solution you'd like
We should establish the right boundaries and moving transformations to a single place. I would say the
wws-worker
shouldn't require onactix-web
. For this reason, the input transformations must be moved towws-server
and keepwws-worker
to work only withWasmInput
andWasmOutput
structs.Describe alternatives you've considered
I also considered to move the output transformation logic to the
wws-worker
crate. However, this approach reduces the reusability of thewws-worker
crate as it now depends toactix-web
.Additional context
This conversation started on #106 (comment)
The text was updated successfully, but these errors were encountered: