Skip to content

Poor performance or normal behaviour? #2539

Closed
@icalvete

Description

@icalvete

Issue Description

We in the middle of migration from parse.com to our own parse server on AWS EC2.

We are almost ready to go so we are testing the new platfrom.

We see weird behaviour. It's seems that parse-server don't works well with concurrent requests.

We have tested the whole app with jmeter and ab with the same result.

Parse-server tend to eat all free CPU. Even with a few requests.

We are using this simple script.

#!/bin/bash

ab -n1 -c1 \
-p parse.json \
-H "X-Parse-Application-Id: XXXXXXXXXXXX" \
-H "X-Parse-Client-Key: XXXXXXXXXXXX" \
-H "Content-Type: application/json" \
-H "Accept-Encoding: gzip" \
https://XXXXXXXXXXXX.XXXXXXXXXXXXcom:1337/parse/login

Where parse.json content is ...

{"username":"user1","password":"pass1","_method":"GET"}

We have done the tests with an empty database too. Our mongodb platform is really close to our parse-servers. There aren't any slow queries in our mongodb (80 ms is slow to us)

We hace un ELB with only one instance behind.

Results

10 requests. 1 concurrent request
Concurrency Level:      1
Time taken for tests:   2.266 seconds
Complete requests:      10
Failed requests:        0
Total transferred:      8890 bytes
Total body sent:        4090
HTML transferred:       3680 bytes
Requests per second:    4.41 [#/sec] (mean)
Time per request:       226.572 [ms] (mean)
Time per request:       226.572 [ms] (mean, across all concurrent requests)
Transfer rate:          3.83 [Kbytes/sec] received
                        1.76 kb/s sent
                        5.59 kb/s total

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        5    5   0.2      5       6
Processing:   219  221   2.2    221     225
Waiting:      218  221   2.2    221     225
Total:        224  226   2.2    226     231

Percentage of the requests served within a certain time (ms)
  50%    226
  66%    227
  75%    228
  80%    229
  90%    231
  95%    231
  98%    231
  99%    231
 100%    231 (longest request)
10 requests. 2 concurrent requests
Concurrency Level:      2
Time taken for tests:   2.169 seconds
Complete requests:      10
Failed requests:        0
Total transferred:      8890 bytes
Total body sent:        4090
HTML transferred:       3680 bytes
Requests per second:    4.61 [#/sec] (mean)
Time per request:       433.873 [ms] (mean)
Time per request:       216.936 [ms] (mean, across all concurrent requests)
Transfer rate:          4.00 [Kbytes/sec] received
                        1.84 kb/s sent
                        5.84 kb/s total

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        5    6   0.8      6       8
Processing:   414  428  10.0    431     440
Waiting:      414  428   9.9    431     440
Total:        419  434  10.2    439     446

Percentage of the requests served within a certain time (ms)
  50%    439
  66%    441
  75%    441
  80%    443
  90%    446
  95%    446
  98%    446
  99%    446
 100%    446 (longest request)
10 requests. 4 concurrent requests
Concurrency Level:      4
Time taken for tests:   2.145 seconds
Complete requests:      10
Failed requests:        0
Total transferred:      8890 bytes
Total body sent:        4090
HTML transferred:       3680 bytes
Requests per second:    4.66 [#/sec] (mean)
Time per request:       857.880 [ms] (mean)
Time per request:       214.470 [ms] (mean, across all concurrent requests)
Transfer rate:          4.05 [Kbytes/sec] received
                        1.86 kb/s sent
                        5.91 kb/s total

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        5    6   0.9      6       7
Processing:   426  765 177.6    849     857
Waiting:      426  765 177.6    849     857
Total:        431  771 178.0    856     863

Percentage of the requests served within a certain time (ms)
  50%    856
  66%    857
  75%    861
  80%    861
  90%    863
  95%    863
  98%    863
  99%    863
 100%    863 (longest request)

Even with only two concurrent requests response times grows to double.

2 requests. 2 concurrent requests
Concurrency Level:      2
Time taken for tests:   0.432 seconds
Complete requests:      2
Failed requests:        0
Total transferred:      1778 bytes
Total body sent:        818
HTML transferred:       736 bytes
Requests per second:    4.63 [#/sec] (mean)
Time per request:       432.359 [ms] (mean)
Time per request:       216.179 [ms] (mean, across all concurrent requests)
Transfer rate:          4.02 [Kbytes/sec] received
                        1.85 kb/s sent
                        5.86 kb/s total

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        6    6   0.8      7       7
Processing:   426  426   0.2    426     426
Waiting:      426  426   0.2    426     426
Total:        431  432   0.6    432     432
WARNING: The median and mean for the initial connection time are not within a normal deviation
        These results are probably not that reliable.

Percentage of the requests served within a certain time (ms)
  50%    432
  66%    432
  75%    432
  80%    432
  90%    432
  95%    432
  98%    432
  99%    432
 100%    432 (longest request)

Environment Setup

  • Server
    • parse-server version: 2.2.17
    • Operating System: ubuntu 14.04
    • Hardware: AWS EC2 c4.large
  • Database
    • MongoDB version: 3.0
    • Storage engine: WiredTiger
    • Hardware: AWS EC2 m4.large

Logs/Trace

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