Giter Club home page Giter Club logo

cordova-usercache's People

Contributors

jgreenlee avatar louisg1337 avatar mrozuru avatar shankari avatar

Watchers

 avatar  avatar  avatar

cordova-usercache's Issues

Updating the read timestamp after reading a document changes its key

This code

    private void updateReadTimestamp(int keyRes) {
        SQLiteDatabase writeDb = this.getWritableDatabase();
        ContentValues updateValues = new ContentValues();
        updateValues.put(KEY_READ_TS, ((double)System.currentTimeMillis())/1000);
        updateValues.put(KEY_KEY, getKey(keyRes));
        writeDb.update(TABLE_USER_CACHE, updateValues, null, null);
        writeDb.close();
    }

sets the key for all entries in the database to the key of the read document.

deleting overridden rw-documents is broken (at least on android)

According to the logs, this is the query that is executed.

03-29 02:30:28.178  11699-11723/edu.berkeley.eecs.emission D/BuiltinUserCache﹕ Clearing obsolete RW-DOCUMENTS using DELETE FROM userCache WHERE write_ts IN (SELECT B.write_ts FROM userCache A JOIN userCache B  on B.key == A.key WHERE (B.type == 'rw-document' AND A.type == 'document' AND A.write_ts > B.write_ts))

If I run the query manually, against a downloaded database, it works. But it doesn't work seem to work against the actual database. This is not actually a huge tragedy, and we have a lot of work to do today morning, so let's just punt for now.

ios doesn't fill in metadata timezone information for rw documents

While investigating documents created directly from javascript today, I discovered that iOS doesn't fill in metadata timezone information, at least for for rw documents. And since the metadata is consistent, it probably doesn't fill in the information for any documents.

We do workaround this by setting the timezone to America/Los_Angeles if it is not present, but that's incorrect for locations other than the west coast of the US. We should either stop using the metadata timezone, or fill it in correctly.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.