How to optimize the performance of my application when doing Httpclient resquisitions

Asked

Viewed 128 times

0

I’m developing an app using Xamarin.Forms, but I have a problem. Settings like color, company name, cover image and soon comes through a request for a call to web service whose return is a JSON, but every time I have to pull this information, which can affect the performance of my server. Is there any way to optimize this, such as a cache in which I request only once and whenever there is an update of the information?

  • You may be able to save to a localstorage. https://developer.xamarin.com/api/property/WebKit.WKWebsiteDataType.LocalStorage/

2 answers

0

Probably what should consume your most server-side traffic and memory is sending serialized images. In Xamarin you can use Ffimageloading, which has an image cache system, and you can use it to avoid recovering them from the server every time you run the application.

https://github.com/luberda-molinet/FFImageLoading

  • Thank you, but I would also like to store Json in cache so that the user does not download every time he enters the app.

0

Another option I recommend is at the start of the application you download the pro app images and solves your problem..

Browser other questions tagged

You are not signed in. Login or sign up in order to post.