I am using HttpURLConnection for communication with server and using HttpResponseCache for caching, when server respond with 304 (HTTP_NOT_MODIFIED), i got empty body, but according to documentation of HttpURLConnection and HttpResponseCache, in case 304 HttpUrlConnection will fetch the response for the same URL in the cache. While the request for url is cached and i confirmed it. when url is called first time i get proper response (data) while after cached when i called url, Why i am getting empty body (no data).
Related Questions in ANDROID
- Creating global Class holder
- Flutter + Dart: Editing name of a tab shows up a black screen
- android-pdf-viewer Received status code 401 from server: Unauthorized
- Sdk 34 WRITE_EXTERNAL_STORAGE not working
- ussd reader in Recket Native module
- Incorrect display of LinearGradientBrush in IOS
- The Binary Version Of its metadata is 1.8.0, expected Version is 1.6.0 build error
- I can't make TextInput to auto expand properly in Android
- Creating multiple instances of a class with different initializing values in Flutter
- How to create a lottie animation
- making android analyze with coverity sast tool
- Flutter plugin development android src not opening after opening example
- I initialize my ViewModel in the Activity with several fragments as tabs, but the fragments(tabs) return null for the updated livedata
- Node.js Server + Socket.IO + Android Mobile Applicatoin XHR Polling Error...?
- How I can use the shared preferences class?
Related Questions in HTTPURLCONNECTION
- Java HttpURLConnection cannot set Content-Length
- Cant read the whole response from the HttpURLConnection I want to achieve that for My Proxy Server?
- Android Studio HttpURLConnection every second request is empty on host
- getResponseCode returns null
- Jenkins Groovy HttpURLConnection PUT request failing while creating writer
- Android Volley library for secure requests
- HTTP connection failure when calling local API from .Net MAUI view
- What is the most efficient way to call rest service multiple times in a loop
- Not able to intercept methods of java.net.HttpURLConnection class in Java 17
- How to Access Set-Cookie Values with httpUrlConnection.getHeaderFields() When Headers Are Empty Due to HTTP Only Cookie Restrictions?
- Trying to get initial cookie value for a non authenticated website but it's throwing 403, using HttpURLConnection
- How to read EXCEL FILE with RESTRICTED permissions from URL in java?
- Spring Cloud Open Feign: HttpURLConnection and Apache HttpClient
- Overlapping bars and X-axis labels not showing correctly, also need to set Y-axis max value dynamically
- Android HttpUrlConnection not working in release
Related Questions in HTTPRESPONSECACHE
- Saving the response cache to the server in Net 5
- Is there a way to use any IDistributedCache as a ResponseCache in .net core?
- Does an HTTP request get cached when in the API ResponseCache NoStore = true? On a particular API endpoint
- WebAPI core 2.0 Cache by post params
- How to force caching with HttpsURLConnection and HttpResponseCache on Android?
- Use LRU Image Caching In Conjuction With HTTPResponseCache for Disk and Memory Caching
- Subclassing com.android.okhttp.AndroidShimResponseCache in application
- Caching of response messages
- Android CacheResponse: get file path?
- Laravel 5.1 Object oriented ajax response caching
- com.squareup.okhttp.HttpResponseCache Cannot resolve symbol 'HttpResponseCache'
- Using HttpResponseCache makes app crash
- HTTPResponseCache stores but never hits
- How to update OkHttp cache
- Can I stop HTTPResponseCache behaving like a shared cache in regard to Cache-Control headers?
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Popular Tags
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
I fixed the issue by downloading volley library from official google code repository this is the link https://android.googlesource.com/platform/frameworks/volley/+/master.
Actually the volley source code available at github is customized and cause many issues (github link: https://github.com/mcxiaoke/android-volley), never download from that link.