How can debugging and logging be enabled in the FTP adapter to troubleshoot connection issues and receive detailed error messages during file uploads?

To enable debugging and logging in the FTP adapter for troubleshooting connection issues and receiving detailed error messages during file uploads, you can set the `ftp_debug` option to true and specify a log file path using the `ftp_log` option in the adapter configuration.

$ftp = new \ZendFtp\Ftp(array(
    'host' => 'ftp.example.com',
    'username' => 'username',
    'password' => 'password',
    'ftp_debug' => true,
    'ftp_log' => '/path/to/log/file.log'
));