Re: [whatwg] Comment on 6.6 Offline Web Applications

2010-06-03 Thread Michael Nordman
There is a way for the application to remove itself from the cache. If
fetching the manifestUrl returns a 404 or 410 response, all traces of that
manifestUrl are deleted from the cache. See section 6.6.4.

On Thu, Jun 3, 2010 at 12:30 PM, Peter Beverloo  wrote:

> On Thu, Jun 3, 2010 at 15:01, Daniel Glazman
>  wrote:
> >
> > Hi there,
> >
> > I noticed the Application Cache does not allow to remove
> > a single cached web application from the cache. Is that on
> > purpose?
> > I am under the impression the cache is here more an offline
> > storage for webapps than a normal cache, and that in the long
> > run browsers will have to implement an "Offline Web Apps" manager.
> > Since the user is supposedly already provided with a dialog
> > asking permission to make a webapp available offline, it makes
> > sense to give him/her a way to remove a single application from
> > the cache.
> >
> > 
>
> Section 6.6.7 talks about expiration of cached data [1], but also
> includes a few notes about removing items from the store. It
> specifically states that user-agents could have a "delete
> site-specific data" feature which also covers removing application
> caches, but also hints towards a feature that removes caches on
> request of the user.
>
> The API does not state a way allowing an application to remove itself
> from the cache, which could be desirable for web authors. If there's
> interest for such an addition I'm willing to make a proposal, as it
> isn't hard to think about use-cases for such a feature.
>
> Regards,
> Peter Beverloo
>
> [1]
> http://www.whatwg.org/specs/web-apps/current-work/multipage/offline.html#expiring-application-caches
>


Re: [whatwg] Comment on 6.6 Offline Web Applications

2010-06-03 Thread Peter Beverloo
On Thu, Jun 3, 2010 at 15:01, Daniel Glazman
 wrote:
>
> Hi there,
>
> I noticed the Application Cache does not allow to remove
> a single cached web application from the cache. Is that on
> purpose?
> I am under the impression the cache is here more an offline
> storage for webapps than a normal cache, and that in the long
> run browsers will have to implement an "Offline Web Apps" manager.
> Since the user is supposedly already provided with a dialog
> asking permission to make a webapp available offline, it makes
> sense to give him/her a way to remove a single application from
> the cache.
>
> 

Section 6.6.7 talks about expiration of cached data [1], but also
includes a few notes about removing items from the store. It
specifically states that user-agents could have a "delete
site-specific data" feature which also covers removing application
caches, but also hints towards a feature that removes caches on
request of the user.

The API does not state a way allowing an application to remove itself
from the cache, which could be desirable for web authors. If there's
interest for such an addition I'm willing to make a proposal, as it
isn't hard to think about use-cases for such a feature.

Regards,
Peter Beverloo

[1] 
http://www.whatwg.org/specs/web-apps/current-work/multipage/offline.html#expiring-application-caches