Go to the latest version of this document.

# ``twisted`.`protocols`.`policies``

module documentation
(source)

Resource limiting policies.

See Also
See also `twisted.protocols.htb` for rate limiting.

Class | `LimitConnectionsByPeer` | Undocumented
Class | `LimitTotalConnectionsFactory` | Factory that limits the number of simultaneous connections.
Class | `ProtocolWrapper` | Wraps protocol instances and acts as their transport as well.
Class | `SpewingFactory` | Undocumented
Class | `SpewingProtocol` | Undocumented
Class | `ThrottlingFactory` | Throttles bandwidth and number of connections.
Class | `ThrottlingProtocol` | Protocol for `ThrottlingFactory`.
Class | `TimeoutFactory` | Factory for TimeoutWrapper.
Class | `TimeoutMixin` | Mixin for protocols which wish to timeout connections.
Class | `TimeoutProtocol` | Protocol that automatically disconnects when the connection is idle.
Class | `TrafficLoggingFactory` | No class docstring; 0/3 instance variable, 1/4 method documented
Class | `TrafficLoggingProtocol` | No class docstring; 0/3 instance variable, 1/9 method documented
Class | `WrappingFactory` | Wraps a factory and its protocols, and keeps track of them.
Type Variable | `WP` | Undocumented
Function | `_wrappedLogPrefix` | Compute a log prefix for a wrapper and the object it wraps.

WP = (source)

Undocumented

Value

    TypeVar('WP',
            bound=ProtocolWrapper, default=ProtocolWrapper)

def _wrappedLogPrefix(wrapper, wrapped): (source)

Compute a log prefix for a wrapper and the object it wraps.

Returns
`str` | Undocumented