API

API Middleware

class designate.api.middleware.APIv2ValidationErrorMiddleware(application)[source]

Bases: Middleware

class designate.api.middleware.ContextMiddleware(application, conf=None)[source]

Bases: Middleware

make_context(request, *args, **kwargs)[source]
class designate.api.middleware.FaultWrapperMiddleware(application)[source]

Bases: Middleware

class designate.api.middleware.KeystoneContextMiddleware(application)[source]

Bases: ContextMiddleware

process_request(request)[source]

Called on each request.

If this returns None, the next application down the stack will be executed. If it returns a response then that response will be returned and execution will stop here.

class designate.api.middleware.MaintenanceMiddleware(application)[source]

Bases: Middleware

process_request(request)[source]

Called on each request.

If this returns None, the next application down the stack will be executed. If it returns a response then that response will be returned and execution will stop here.

class designate.api.middleware.NoAuthContextMiddleware(application)[source]

Bases: ContextMiddleware

process_request(request)[source]

Called on each request.

If this returns None, the next application down the stack will be executed. If it returns a response then that response will be returned and execution will stop here.

class designate.api.middleware.NormalizeURIMiddleware(application, conf=None)[source]

Bases: Middleware

class designate.api.middleware.TestContextMiddleware(application, tenant_id=None, user_id=None)[source]

Bases: ContextMiddleware

process_request(request)[source]

Called on each request.

If this returns None, the next application down the stack will be executed. If it returns a response then that response will be returned and execution will stop here.

designate.api.middleware.auth_pipeline_factory(loader, global_conf, **local_conf)[source]

A paste pipeline replica that keys off of auth_strategy.

Code nabbed from cinder.

API Service

class designate.api.service.Service[source]

Bases: WSGIService

property service_name
start()[source]

Start a service.

stop(graceful=True)[source]

Stop a service.

Parameters:

graceful – indicates whether to wait for all threads to finish or terminate them instantly

property wsgi_application