aloo
aloo

Reputation: 5389

Why would scaling up increase latency?

We are scaling the number of users on our GAE java app. We now have about triple the active users we had a few days ago.

We've noticed that average latency as reported by the GAE dashboard has increased almost by a factor of 2. There have been no code changes.

What would cause latency per request to go up just by having more users? Presumably in a well designed app, appengine would scale the number of instances so that our latency is kept to a minimum. I have not altered any of the default pending latency settings and similar.

What are the most common design flaws in implementing an appengine app that would cause latency to go up as usage goes up?

Contention on the datastore? The data we store is in seperate entity groups per user so this seems like a low probability.....

Upvotes: 3

Views: 242

Answers (2)

TommyN
TommyN

Reputation: 2381

It seems there is an issue with latency when setting "threadsafe" to "yes". Are you perhaps hitting the same issue as found here: http://code.google.com/p/googleappengine/issues/detail?id=6323

Update: By default, each web server processes only one request at a time. If you mark your application as thread-safe, App Engine may dispatch multiple requests to each web server in parallel. To do so, simply add a true element to appengine-web.xml as described in Using Concurrent Requests.

Upvotes: 0

Shay Erlichmen
Shay Erlichmen

Reputation: 31928

You need to provide more info about your app, for example writes to the datastore. If many clients write to the datastore, you will create a traffic jam if you use a single entity.

What you need to do is to measure each part how long it takes and compare the results between the two loads.

Upvotes: 1

Related Questions