[HUE-5959] Enable Persistent connections using CONN_MAX_AGE

Review Request #9666 — Created Feb. 27, 2017 and submitted

ranade
hue
master
HUE-5959
hue
enricoberti, jennykim, johan, krish, ranade, romain, subrata, weixia
commit a1f9f60419ba2cc8540338dcafd7a619af807135
Author: Prakash Ranade <ranade@cloudera.com>
Date:   Mon Feb 27 14:58:50 2017 -0800

    [HUE-5959] Enable Persistent connections using CONN_MAX_AGE
    
    Enable CONN_MAX_AGE parameter. Django does not offer connection pooling or
    singleton object for database connection pool. Also Django opens
    a connection to the database when it first makes a database query.
    It keeps this connection open and reuses it in subsequent requests.
    Django closes the connection once it exceeds the maximum age defined by
    CONN_MAX_AGE or when it isn’t usable any longer.
    Till now HUE Django code was not using CONN_MAX_AGE configuration value.
    By default CONN_MAX_AGE value is 600 seconds but anyone can change.
    
    Tested:
    Perform testing on Oracle, MySQL and SQLite.

:100644 100644 b43dc25... 7e7b0b7... M	desktop/conf.dist/hue.ini
:100644 100644 e9b544d... caeeb61... M	desktop/conf/pseudo-distributed.ini.tmpl
:100644 100644 6937fa5... 4aadb17... M	desktop/core/src/desktop/conf.py
:100644 100644 3e08d39... 762bbb4... M	desktop/core/src/desktop/settings.py


  • 0
  • 0
  • 2
  • 0
  • 2
Description From Last Updated
romain
  1. 
      
  2. Could we default to 0 for v1?

    Then we can test different values easily.

    1. Perfect, that is what I was thinking too...

  3. 
      
ranade
romain
  1. 
      
  2. desktop/core/src/desktop/conf.py (Diff revision 2)
     
     

    Persistent connection --> connections persistency

    ?

  3. 
      
ranade
ranade
Review request changed

Status: Closed (submitted)

Loading...