Improving page creation performance

24 views
Skip to first unread message

Ramkrishna Kulkarni

unread,
Dec 15, 2015, 1:13:20 AM12/15/15
to Nitrogen Project / The Nitrogen Web Framework for Erlang
Hello Jesse,

I've noticed a considerable drop in performance as the number of Nitrogen elements increases per page. Below are results of some load tests. Do you have any idea how to improve performance here?

--- case #1 no elements ---

➜  oex git:(master) ✗ wrk -c100 -t4 -d10S --timeout 2000 "http://127.0.0.1:8000/hello?mode=text"
  4 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     6.82ms    2.55ms  39.09ms   78.25%
    Req/Sec     3.71k   241.56     4.44k    78.75%
  147850 requests in 10.00s, 51.88MB read
Requests/sec:  14779.24
Transfer/sec:      5.19MB

--- case #2 1 element ---

➜  oex git:(master) ✗ wrk -c100 -t4 -d10S --timeout 2000 "http://127.0.0.1:8000/hello?mode=template"
  4 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     9.70ms    2.68ms  45.44ms   78.48%
    Req/Sec     2.59k   147.60     3.31k    76.00%
  103075 requests in 10.01s, 101.03MB read
Requests/sec:  10301.43
Transfer/sec:     10.10MB

--- case #3 10 elements ---

➜  oex git:(master) ✗ wrk -c100 -t4 -d10S --timeout 2000 "http://127.0.0.1:8000/hello?mode=elements"
  4 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency    16.29ms    3.94ms  37.40ms   80.60%
    Req/Sec     1.54k   101.04     1.93k    73.00%
  61334 requests in 10.01s, 101.52MB read
Requests/sec:   6127.34
Transfer/sec:     10.14MB

--- case #4 26 elements ---

➜  oex git:(master) ✗ wrk -c100 -t4 -d10S --timeout 2000 "http://127.0.0.1:8000/hello?mode=elements"
  4 threads and 100 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency    25.82ms    5.81ms  53.08ms   82.08%
    Req/Sec     0.97k    72.78     1.27k    78.25%
  38710 requests in 10.02s, 102.22MB read
Requests/sec:   3864.02
Transfer/sec:     10.20MB
 

Jesse Gumm

unread,
Dec 15, 2015, 2:57:06 PM12/15/15
to nitrogenweb
Hi Ram,

These are definitely things I'm looking to improve. I had been
meaning to spend more time optimizing element rendering in general,
but alas, ran out of time.

But indeed, improving element rendering time (without breaking
backwards compatibility) is on the list of the things to do :)

-Jesse
> --
> You received this message because you are subscribed to the Google Groups
> "Nitrogen Project / The Nitrogen Web Framework for Erlang" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to nitrogenweb...@googlegroups.com.
> To post to this group, send email to nitro...@googlegroups.com.
> Visit this group at https://groups.google.com/group/nitrogenweb.
> For more options, visit https://groups.google.com/d/optout.



--
Jesse Gumm
Owner, Sigma Star Systems
414.940.4866 || sigma-star.com || @jessegumm
Reply all
Reply to author
Forward
0 new messages