R
R
rPman2012-06-25 14:28:03
Google Cloud Platform
rPman, 2012-06-25 14:28:03

Problems with GAE limits, why are Datastore Read Operations too high?

Didn't work seriously with google app engine, but needed hosting the most reliable cloud storage for a very simple application. Moreover, according to the calculations, I had to fit into the free limits quite well (there will be no problems paying a couple of bucks a month, more will not work there).
The project is primitive:
Two Datastore objects (one root with 2 fields and a constantly updated list of objects with 4 fields), one periodically launched task, a transaction is opened in it, the root object is read and one list element is created (data is collected by one request to the fetchurl service).
So within three hours I run out of Datastore Read Operations limits - 100%, while Datastore Write Operations - 5%
appstore dashboard:
XLTr9.png
installed regular google appstats : I can't figure out where such an increased number of reads comes from, moreover, even appstat statistics do not show 50k Next requests (I use java.jdo, no enumerations, no work with cursors ... the only place where reading the related list could be considered objects - when adding, the list element constructor contains the line root.addItem(this) (and in the root object Root it is a stupid method this.items.add(item); And all the more incomprehensible!!! Since the task has 19 reads and 2 writes (by the way, it’s also not clear, I fill in four fields plus the key one), then in 3 hours (the task is executed with a frequency of one in 70 seconds), 154 requests * 19 reads = 2926 should have been disposed of!
BCQMQ.png
What other means can be used to control google billing. Indeed, with such discrepancies by an order of magnitude, you can get a good penny.
upd. Google has a problem with billing for a high replication datastore, this is clearly not my jamb, because there are a hundred read requests for a database with two !!! records is overkill, I don’t even have that many calls in my code. Recreated and re-uploaded the application in Master/Slave mode (by the way, now it's marked as Deprecated! cunning), now appstats shows intelligible information, 1 or 2 requests per task call, i.e. as it should be, also the statistics in the GAE admin panel show similar numbers (tomorrow I will estimate the load more accurately)

Answer the question

In order to leave comments, you need to log in

4 answer(s)
T
theli, 2012-06-25
@theli

If the code is not a terrible trade secret, then it would be easier to tell from it.

X
xSkyFoXx, 2012-06-25
@xSkyFoXx

It is possible that you have Low-Level Operations displayed, and you have a High-Level Operation in your code. That. it turns out a lot of quotas.

A
Arthur, 2012-06-25
@ArthurG

If I understand correctly what you did. This is elementary, if you shove a list into one object, then in order to add something to it, you first need to read it all. Hence the many readings.

T
TipTop, 2012-06-26
@TipTop

AppStats shows 1933 RPC's for 11 requests to /tasks/test. It turns out 178 readings of the database for the task. 50k requests in this mode are enough for 4 hours.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question