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
The examples for starting the server in this project always using Server.make.
If I want to use some custom http pipeline , How can I achieve the same?
the client can send requests in payload compressed based on the content-encoding header. For example, if the contents are compressed in gzipped format, then the content-encoding header would be gzip. Netty provides HttpContentDecompressor channel handler for this feature.
Similarly the server can also send response in compressed format based on the Accept-Encoding header in the request. For this Netty provides HttpContentCompressor channelHandler for this feature.
I've an example here. The code is on github here. you can run the project by using gradle just-netty:runMain to run the server. The example of client to call the server is here
In my current organization we use HttpContentCompressor and HttpContentDecompressor in our server and also has some additional handler in pipeline.
IMHO, zio-http should allow users to provide option for defining custom HttpPipeline. In cases if the users didn't provide additional pipeline , then Server.make should use default pipeline.
Please let me know if I'm not clear in this problem description.
Activity
rajcspsg commentedon Dec 29, 2021
Let me add more details to this issue -
the client can send requests in payload compressed based on the content-encoding header. For example, if the contents are compressed in gzipped format, then the content-encoding header would be
gzip. Netty provides HttpContentDecompressor channel handler for this feature.Similarly the server can also send response in compressed format based on the Accept-Encoding header in the request. For this Netty provides HttpContentCompressor channelHandler for this feature.
I've an example here. The code is on github here. you can run the project by using
gradle just-netty:runMainto run the server. The example of client to call the server is hereIn my current organization we use HttpContentCompressor and HttpContentDecompressor in our server and also has some additional handler in pipeline.
IMHO, zio-http should allow users to provide option for defining custom HttpPipeline. In cases if the users didn't provide additional pipeline , then
Server.makeshould use default pipeline.Please let me know if I'm not clear in this problem description.
tusharmath commentedon Jan 20, 2022
This seems like something we should have in ZIO Http.