def METHOD_NAME(self, reason):
    """
    Disconnect all the parts of the connection.
    :param reason: reason for disconnection
    """
    self.recordConnectionClose()
    self.recorder.finalize()
    self.log.info("Server connection closed. %(reason)s", {"reason": reason.value})
    self.client.disconnect(True)
    # For the attacker, we want to make sure we don't abort the connection to make sure that the close event is sent
    self.attacker.disconnect()
    self.detach()