mirror of
https://github.com/samuelclay/NewsBlur.git
synced 2025-04-13 09:42:01 +00:00
Postgres min log statement to 0.5s. Syncing haproxy debug with haproxy config.
This commit is contained in:
parent
e602b52a5d
commit
84c22ca36c
3 changed files with 7 additions and 6 deletions
|
@ -1,7 +1,5 @@
|
||||||
global
|
global
|
||||||
maxconn 100000
|
maxconn 100000
|
||||||
user haproxy
|
|
||||||
group haproxy
|
|
||||||
daemon
|
daemon
|
||||||
ca-base /srv/newsblur/config/certificates
|
ca-base /srv/newsblur/config/certificates
|
||||||
crt-base /srv/newsblur/config/certificates
|
crt-base /srv/newsblur/config/certificates
|
||||||
|
@ -44,6 +42,7 @@ frontend public
|
||||||
acl gunicorn_dead nbsrv(gunicorn) lt 1
|
acl gunicorn_dead nbsrv(gunicorn) lt 1
|
||||||
acl nginx_dead nbsrv(nginx) lt 1
|
acl nginx_dead nbsrv(nginx) lt 1
|
||||||
acl mx_mode nbsrv(maintenance) lt 1
|
acl mx_mode nbsrv(maintenance) lt 1
|
||||||
|
acl is_unread_count url_beg /reader/feed_unread_count
|
||||||
|
|
||||||
monitor-uri /status
|
monitor-uri /status
|
||||||
monitor fail if gunicorn_dead
|
monitor fail if gunicorn_dead
|
||||||
|
@ -61,7 +60,7 @@ frontend public
|
||||||
|
|
||||||
use_backend nginx if mx_mode
|
use_backend nginx if mx_mode
|
||||||
|
|
||||||
use_backend gunicorn_counts if { path_beg /reader/feed_unread_count }
|
use_backend gunicorn_counts if is_unread_count
|
||||||
use_backend gunicorn unless gunicorn_dead || nginx_dead
|
use_backend gunicorn unless gunicorn_dead || nginx_dead
|
||||||
|
|
||||||
backend node_socket
|
backend node_socket
|
||||||
|
|
|
@ -25,5 +25,7 @@ else:
|
||||||
|
|
||||||
if workers <= 4:
|
if workers <= 4:
|
||||||
workers = max(int(math.floor(GIGS_OF_MEMORY * 1000 / 512)), 4)
|
workers = max(int(math.floor(GIGS_OF_MEMORY * 1000 / 512)), 4)
|
||||||
|
|
||||||
if workers > 8:
|
if workers > 8:
|
||||||
workers = 8
|
workers = 8
|
||||||
|
|
||||||
|
|
|
@ -338,7 +338,7 @@ effective_cache_size = 32GB
|
||||||
# fatal
|
# fatal
|
||||||
# panic (effectively off)
|
# panic (effectively off)
|
||||||
|
|
||||||
log_min_duration_statement = 1000 # -1 is disabled, 0 logs all statements
|
log_min_duration_statement = 500 # -1 is disabled, 0 logs all statements
|
||||||
# and their durations, > 0 logs only
|
# and their durations, > 0 logs only
|
||||||
# statements running at least this number
|
# statements running at least this number
|
||||||
# of milliseconds
|
# of milliseconds
|
||||||
|
|
Loading…
Add table
Reference in a new issue