'Clean up after the application.
Only necessary for dynamically created apps, and you should
probably use the :keyword:`with` statement instead.
Example:
>>> with Celery(set_as_current=False) as app:
...     with app.connection_for_write() as conn:
...         pass'

def close(self):

    self._pool = None
    _deregister_app(self)
