openstack.load_balancer.v2.listener

The Listener Class

The Listener class inherits from Resource.

class openstack.load_balancer.v2.listener.Listener(_synchronized=False, connection=None, **attrs)

The base resource

Parameters:
  • _synchronized (bool) – This is not intended to be used directly. See new() and existing().

  • connection (openstack.connection.Connection) – Reference to the Connection being used. Defaults to None to allow Resource objects to be used without an active Connection, such as in unit tests. Use of self._connection in Resource code should protect itself with a check for None.

resource_key = 'listener'

Singular form of key for resource.

resources_key = 'listeners'

Plural form of key for resource.

base_path = '/lbaas/listeners'

The base part of the URI for this resource.

allow_create = True

Allow create operation for this resource.

allow_fetch = True

Allow get operation for this resource.

allow_commit = True

Allow update operation for this resource.

allow_delete = True

Allow delete operation for this resource.

allow_list = True

Allow list operation for this resource.

allowed_cidrs

List of IPv4 or IPv6 CIDRs.

alpn_protocols

List of ALPN protocols.

connection_limit

The maximum number of connections permitted for this load balancer. Default is infinite.

created_at

Timestamp when the listener was created.

default_pool

Default pool to which the requests will be routed.

default_pool_id

ID of default pool. Must have compatible protocol with listener.

default_tls_container_ref

A reference to a container of TLS secrets.

description

Description for the listener.

is_hsts_include_subdomains

Defines whether the include_subdomains directive is used for HSTS or not

hsts_max_age

Enables HTTP Strict Transport Security (HSTS) and sets the max_age directive to given value

is_hsts_preload

Defines whether the hsts_preload directive is used for HSTS or not

insert_headers

Dictionary of additional headers insertion into HTTP header.

is_admin_state_up

The administrative state of the listener, which is up True or down False. Type: bool

l7_policies

List of l7policies associated with this listener.

load_balancer_id

The ID of the parent load balancer.

load_balancers

List of load balancers associated with this listener. Type: list of dicts which contain the load balancer IDs

name

Name of the listener

operating_status

Operating status of the listener.

project_id

The ID of the project this listener is associated with.

protocol

The protocol of the listener, which is TCP, HTTP, HTTPS or TERMINATED_HTTPS.

protocol_port

Port the listener will listen to, e.g. 80.

provisioning_status

The provisioning status of this listener.

sni_container_refs

A list of references to TLS secrets. Type: list

updated_at

Timestamp when the listener was last updated.

timeout_client_data

Frontend client inactivity timeout in milliseconds.

timeout_member_connect

Backend member connection timeout in milliseconds.

timeout_member_data

Backend member inactivity timeout in milliseconds.

timeout_tcp_inspect

Time, in milliseconds, to wait for additional TCP packets for content inspection.

tls_ciphers

Stores a cipher string in OpenSSL format.

tls_versions

A lsit of TLS protocols to be used by the listener

The ListenerStats Class

The ListenerStats class inherits from Resource.

class openstack.load_balancer.v2.listener.ListenerStats(_synchronized=False, connection=None, **attrs)

The base resource

Parameters:
  • _synchronized (bool) – This is not intended to be used directly. See new() and existing().

  • connection (openstack.connection.Connection) – Reference to the Connection being used. Defaults to None to allow Resource objects to be used without an active Connection, such as in unit tests. Use of self._connection in Resource code should protect itself with a check for None.

resource_key = 'stats'

Singular form of key for resource.

base_path = '/lbaas/listeners/%(listener_id)s/stats'

The base part of the URI for this resource.

allow_create = False

Allow create operation for this resource.

allow_fetch = True

Allow get operation for this resource.

allow_commit = False

Allow update operation for this resource.

allow_delete = False

Allow delete operation for this resource.

allow_list = False

Allow list operation for this resource.

listener_id

The ID of the listener.

active_connections

The currently active connections.

bytes_in

The total bytes received.

bytes_out

The total bytes sent.

request_errors

The total requests that were unable to be fulfilled.

total_connections

The total connections handled.