Skip to content

Have a problem using Local Datastore in Android after parse server migration #490

Closed
@slickker

Description

@slickker

I request this issue to parse.com/help.
They said you might report this issue to here.

I try migration to my local parse server.
I succeeded development local parse server.
And my android application connect to this server successfully.

But to use Local Datastore has problem.
I'm using local datastore.
This is my code.

  • MyApplication.java
    Parse.enableLocalDatastore(this);
  • userProfileDao.java
    try {
    ParseQuery query = ParseQuery.getQuery(PARSE_OBJECT);
    query.fromLocalDatastore();
    mParseObject = query.getFirst();
    } catch (ParseException e) {
    mParseObject = new ParseObject(PARSE_OBJECT);
    }

In userProfileDao.java,
query.fromLocalDatastore(); <- ERROR.... Caused by: java.lang.IllegalStateException: Method requires Local Datastore. Please refer to Parse#enableLocalDatastore(Context).

Before migration, this is no problem.
Currently, I used Parse SDK version 1.13 and Parse server version 2.1.
Please to solve this problem.

Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions