The Frank application signature is currently undergoing a change from 'Request -> Async<'Response> to 'Request -> 'Response, where the 'Response includes a Body type that is:
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| type Body = | |
| | Bytes of byte[] | |
| | AsyncBytes of Async<byte[]> | |
| | Segment of ArraySegment<byte> | |
| | AsyncSegment of Async<ArraySegment<byte>> | |
| | Str of string | |
| | AsyncStr of Async<string> | |
| | Sequence of seq<Body> | |
| | AsyncSequence of AsyncSeq<Body> |
Now to your questions:
Q: Why are you getting rid of the async processing?
A: I’m not. Most requests have already pulled in all the data required for processing, so wrapping the entire transaction in an Async needlessly is just waste. The Body of the 'Response can now be either Async or not, which can further wrap asynchronous access to the 'Request body.