HttpResponseCache
HttpResponseCache copied to clipboard
PUT request method are not caching
Hi , The PUT request methods are not caching i dont understand what is the problem with it ,and the same is not working in the case of using android.net.http.HttpResponseCache.There is no problem with the POST and GET methods.Can you please help me from this issue
Hey, are you sure POST is working for you? I can't get POSTs to work as well, I can see the reason in the code:
if (requestMethod.equals(HttpEngine.POST)
|| requestMethod.equals(HttpEngine.PUT)
|| requestMethod.equals(HttpEngine.DELETE)) {
try {
cache.remove(key);
} catch (IOException ignored) {
// The cache cannot be written.
}
return null;
can anybody tell me what is the complexity of supporting POST requests as well? any good reason to not cache them?