ios - Clear NSURLSession Cache -
i'm using nsurlsession perform http post nsmutableurlrequest, using datataskwithrequest:completionhandler: method. when perform request first time, things take reasonable amount of time complete , show feedback in completion handler. on next time same request fired, happens instantaneously little time in between, leads me believe system caching contents of data task.
as don't need view returned data, nsurlsession best way this? needs work watchkit, nsurlsession does, why chose in fist place. preferably find way clear cache after each request. if need be, switch nsurlconnection, best. thanks!
ephemeral mode not use cache.
nsurlsessionconfiguration *ephemeralconfigobject = [nsurlsessionconfiguration ephemeralsessionconfiguration];
Comments
Post a Comment