You are looking at the documentation of a prior release. To read the documentation of the latest release, please visit here.

New to Voyager? Please start here.

Hard Stop After

[] annotation defines the maximum duration an old haproxy configuration process may exist after configuration reload (e.g. any change in your ingress or backend service or deployment that invokes haproxy configuration change). Note that, this old configuration won’t accept any new requests. It only holds importance if there are existing connections that haven’t finished serving. If not mentioned, it will have 30s as default value. Read More

Note that, if you change your backend pod’s terminationGracePeriodSeconds (default value 30s) to allow graceful shutdown and finish serving current requests for more than 30s, then you will have to change this value accordingly (to allow remaining connections to route via haproxy process).

Ingress Example:

kind: Ingress
  name: test-ingress
  namespace: default
  annotations: 60s
  - host: voyager.appscode.test
      - path: /foo
          	name: test-server
              number: 80

Generated haproxy.cfg:

# HAProxy configuration generated by
	stats socket /tmp/haproxy
	server-state-file global
	server-state-base /var/state/haproxy/
	# log using a syslog socket
	log /dev/log local0 info
	log /dev/log local0 notice
	tune.ssl.default-dh-param 2048
	hard-stop-after 60s
	log global
	option dontlognull
	option http-server-close
	# Timeout values
	timeout client 50s
	timeout client-fin 50s
	timeout connect 5s
	timeout server 50s
	timeout tunnel 50s
	# Configure error files
	# default traffic mode is http
	# mode is overwritten in case of tcp services
	mode http
frontend http-0_0_0_0-80
	bind *:80
	mode http
	option httplog
	option forwardfor
	acl is_proxy_https hdr(X-Forwarded-Proto) https
	acl acl_voyager.appscode.test hdr(host) -i voyager.appscode.test
	acl acl_voyager.appscode.test hdr(host) -i voyager.appscode.test:80
	acl acl_voyager.appscode.test:foo path_beg /foo
	use_backend test-server.default:80 if acl_voyager.appscode.test acl_voyager.appscode.test:foo
backend test-server.default:80
	server pod-test-server-68ddc845cd-x7dtv

Time Format

These timeout values are generally expressed in milliseconds (unless explicitly stated otherwise) but may be expressed in any other unit by suffixing the unit to the numeric value. Supported units are :

  • us : microseconds. 1 microsecond = 1/1000000 second
  • ms : milliseconds. 1 millisecond = 1/1000 second. This is the default.
  • s : seconds. 1s = 1000ms
  • m : minutes. 1m = 60s = 60000ms
  • h : hours. 1h = 60m = 3600s = 3600000ms
  • d : days. 1d = 24h = 1440m = 86400s = 86400000ms