@Override
    public void close() throws GuacamoleException {

        // Set the end date to complete the connection history record
        this.connectionRecordModel.setEndDate(new Date());
        this.connectionRecordMapper.updateEndDate(this.connectionRecordModel);

        super.close();
    }
Creates a new HistoryTrackingTunnel that wraps the given tunnel,
automatically setting the end date for the provided connection history records,
using the provided connection history record mapper.

@param tunnel
    The tunnel to wrap.

@param connectionRecordMapper
    The mapper to use when writing connection history records.

@param connectionRecordModel
    The connection history record model representing the in-progress connection.
extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/java/org/apache/guacamole/auth/jdbc/HistoryTrackingTunnel.java