Skip to content
This repository was archived by the owner on Mar 17, 2025. It is now read-only.

Database Offline Capabilities #13

Open
formatCvt opened this issue Oct 27, 2017 · 11 comments
Open

Database Offline Capabilities #13

formatCvt opened this issue Oct 27, 2017 · 11 comments

Comments

@formatCvt
Copy link
Contributor

formatCvt commented Oct 27, 2017

Can you please give example with offline support? Just set_persistence_enabled before creating any instances of DatabaseReference doesn't help. Feature query/set freezes with kFutureStatusPending status.

@stewartmiles
Copy link
Contributor

@formatCvt which platform are you testing on?

@formatCvt
Copy link
Contributor Author

@stewartmiles android (firebase sdk 4.2.0, cocos2d-x 3.14.1, ndk14b, database sample project from this repo)

@stewartmiles
Copy link
Contributor

@formatCvt thanks we'll get someone to take a look.

@formatCvt
Copy link
Contributor Author

@stewartmiles any news?

@jonsimantov
Copy link

Hi,

Looking into this, there seems to be an issue with disk persistence and the way GetValue is implemented (using single value listener). Does it work if you are online and GetValue first, then go offline and GetValue on the same path again?

Thanks,

Jon

@formatCvt
Copy link
Contributor Author

Nope. It's not working until connection is back.

@formatCvt
Copy link
Contributor Author

formatCvt commented Nov 4, 2017

Here is my changes formatCvt@a73f01d without this authentication fails when device is offline.

Steps to reproduce:

  1. Start example with internet connection
  2. Set key "a" and value "a"
  3. Press "Set" (wait until request successful)
  4. Press "Query"
    screenshot2017-11-04_13-00-46
  5. Close app and stop internet connection
  6. Start example without internet connection
  7. Set key "a" and value "a"
  8. Press "Query"
    Feature query_future_ freezes with kFutureStatusPending status until connection is back.
    screenshot2017-11-04_13-01-14

@formatCvt
Copy link
Contributor Author

any news?

@formatCvt
Copy link
Contributor Author

formatCvt commented Dec 18, 2017

Update firebase sdk up to 4.3.0 doesn't help

@formatCvt
Copy link
Contributor Author

Update firebase sdk up to 4.4.0 doesn't help

@formatCvt
Copy link
Contributor Author

formatCvt commented Feb 17, 2018

With 4.4.1 query is working, but set still freezes until connection is back.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants