Any clues on how to do it ?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You have two options, you can use either / or both.
1) Cache the call at the web service. You need to ensure that the cache is indexed against the exact parameters used so you don’t send back “the wrong answer” to a request.
For example “http://webservice/GetSomething/983” should only cache the result of “GetSomething” where the id parameter is 983. If another request for 983 comes in, you can use your cache, otherwise you’ll make a new request.
2) Cache the response at the client. Be careful about doing this with large volumes of data as you’ll start consuming too much memory. Essentially, you create a JavaScript cache for the response data – you’ll still need to bear in mind the parameters used for the call to ensure you don’t use an item in the cache that was called using different parameters.