Is Firestore charging us when offline more than 30

2020-01-29 17:51发布

I read this answer, where Doug Stevenson (Firebase engineer) said:

Cached document reads are not charged.

But I read in the docs:

Also, if the listener is disconnected for more than 30 minutes (for example, if the user goes offline), you will be charged for reads as if you had issued a brand-new query.

So if I'm going offline, even if I haven't changed any document, am I charged again? So the data that is already cached, isn't consider a cached data after 30 minutes anymore?

Hope someone can help me about this annoying situation. Thanks in advance!

1条回答
疯言疯语
2楼-- · 2020-01-29 18:23

If the cache can satisfy the reconnected query, then there are still no reads charged for each cached document. You are still charged a single read for the query itself, even if it returns no new results that are newer than what's in the cache.

Minimum charge for queries

There is a minimum charge of one document read for each query that you perform, even if the query returns no results.

查看更多
登录 后发表回答