FtpService improvements
Description
- FtpTileService convert to Kotlin
- Replace EventBus with kotlinx.coroutines
- FtpServerFragment update code to recommended
- FtpService explicitly acquires wakelock and enforces
START_STICKYto ensure it's still running in the background even in the doze mode - Upgrade ACRA to 2.13 for fixing https://github.com/square/leakcanary/issues/2568, which would also break FtpService when device screen is turned off
Issue tracker
Fixes #4125
Automatic tests
- [ ] Added test cases
Manual tests
- [x] Done
Device: Fairphone 5 running LineageOS 22 (Android 15)
- Start FTP server
- Connect to the FTP server using other device
- Start a file transfer
- Turn off the screen while transfer in progress
- File transfer should not break
Build tasks success
Successfully running following tasks on local:
- [x]
./gradlew assembledebug - [x]
./gradlew spotlessCheck
Related PR
Depends on PR #4378
3e2cbf3 for the conflict introduced by #4371
Need to pass #4378 first to fix the foregroundService problem.
Filezilla is not able to connect to the server. I have rebased to release/4.0 head:
Estado: Conectando a 192.168.100.13:2211...
Respuesta: fzSftp started, protocol_version=11
Comando: open "[email protected]" 2211
Error: FATAL ERROR: Remote side unexpectedly closed network connection
Error: No se pudo conectar al servidor
Device: Moto G73 5G
Filezilla is not able to connect to the server. I have rebased to release/4.0 head:
Estado: Conectando a 192.168.100.13:2211... Respuesta: fzSftp started, protocol_version=11 Comando: open "[email protected]" 2211 Error: FATAL ERROR: Remote side unexpectedly closed network connection Error: No se pudo conectar al servidorDevice: Moto G73 5G
SFTP is not FTPS which we have here - a FTP server with TLS support :eyes:
Okay,how are you testing this? I cannot get it to connect. With lftp on a real phone I get "`ls' en 0 [Negociando FEAT...]". For an emulator it doesn't even connect, but I suspect the ip bridging is broken.
Easiest way would be let the FTP server run on real device, then connect over LAN. I too have a lot of trouble to get it run on emulator for local clients to connect.