incubator-callback-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Drew Walters <>
Subject Re: Changes to requesting a PERSISTENT file system in Cordova-Android
Date Wed, 22 Feb 2012 20:58:34 GMT
I'm curious about the statement of this being inline with what
BlackBerry does.  Is this referring to the File API as implemented in
Cordova on BlackBerry or something.  Reason I ask is that currently
the Cordova implementation returns an SDCard location for both
temporary and persistent requests when an SDCard is available.

Speaking as someone who has an Android device with limited on phone
storage, I would prefer apps to store data on the micro sd card :)

On Wed, Feb 22, 2012 at 2:29 PM, Joe Bowser <> wrote:
> On Feb 22, 2012 11:56 AM, "Filip Maj" <> wrote:
>> The arguments Joe presented to me on changing the location of the storage
>> were compelling. Joe, can you reiterate them on the list so we all know
>> what's up?
> The main argument was that "Persistent" and "Temporary" are completely
> meaningless when your data always persists unless you have user
> intervention.  Therefore, I'm using the definition of temporary as anything
> that we can't guarantee will exist later because other processes can access
> it/storage can be removed/etc.  Namely that this is volatile storage.
> Since the data in /data/data/<namespace> is protected by UNIX permissions,
> only the user and the app can modify this, therefore this is more
> persistent than anything on the /sdcard.  This is also inline with what
> Blackberry when I asked Fil "What do the other platforms do?"
> Honestly, there needs to be something more descriptive than "Persistent"
> and "Temporary" in the spec, since this isn't clear.
>> I believe we need to change them eventually. Now how do we go about doing
>> this? A deprecation-style message and a clear roadmap / delivery with a
>> specific release?
>> On 12-02-22 11:50 AM, "Simon MacDonald" <> wrote:
>> >I agree with your points but I'm worried that we are making a change for
>> >current PhoneGap Android developers. They are assuming their data is on
>> >the
>> >/sdcard and now we are moving the location of their root filesystem. That
>> >means they'll need to write code to move any files from the /sdcard to the
>> >internal storage directory as they update their app from PhoneGap 1.4.1 to
>> >Apache Cordova 1.5.0. Alternatively, we could put a check into Cordova to
>> >do this work for them.
>> >
>> >IIRC the internal storage directory is protected via the UNIX filesystem
>> >permissions so if I wanted to store a image/audio/video file and call an
>> >intent to view/play the file it wouldn't work.
>> >
> That's true.  But if I had something that wiped my SD Card, whatever data I
> have there is saved and that it'll still be there if I remove the SD Card
> out of an HTC phone, for example.
>> >Also, with the temporary storage on
>> >/sdcard/Android/data/<package_name>/cache/ it will be cleaned up when the
>> >user uninstalls the application.
> Is this behaviour documented anywhere?  I've seen literally hundreds of
> apps that pollute the /sdcard space with crap.
>> >
>> >Anyway, I'm not adverse to making the move I just want to make sure we
>> >think through all the ramifications of the change.
> Do we know how widely this feature is used? Can we need to get more info on
> the API in general and weigh which parts we can easily break and which
> parts are verboten. I'm definitely open to suggestions on how to do it,
> since that'd be better than the "People use this" argument, since I'm sure
> there's people who use ALL of the APIs.
> Joe

View raw message