The update contains several improvements to the
HttpClientimplementation, which should improve performance of the library a lot:
- all handlers now use one static
HttpClientis built to use it that way, and there is also no problem with multiple request handled by that instance. So everyone should use it in that way
- the library is now actively enforcing gzip/deflate compression to make responses faster, especially when requesting bigger lists of items (if you want do deactivate it on the managed implementation, pass in
falsewith the new
useCompressionparameter with your call to the
- deserialization by default now happens directly from the
HttpResponsestream instead of first converting it to a string
- added an API to pass in your own
HttpClientinstance instead of the managed one (you could even use one static instance for your whole app this way to improve performance even further). To do so, just use the newly added method
SetCustomClient(HttpClient client)on your handler instances.
I made this changes working without breaking existing implementations. Just by updating the library, you will get a better performance.
Happy coding, everyone!
If you want to see the library in a live app, you can download my official blog reader app (which is written around it as a