<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def end(self):
 """End of the Glances server session."""

        if not self.args.disable_autodiscover:
            self.autodiscover_client.close()
        self.server.end()