Seafile-Client: Set sync automatically on hold when a mobile network is used

Hi,

mobile networks are usually limited in terms of speed and available volume and users are forced to pause the entire client via the context menu of the tray icon (Disable auto sync) to prevent the client from consuming these limited resources.

I wonder if it might be possible that the Seafile desktop clients detect when the computer is connected to the internet by a mobile network and not via LAN or WLAN and - if this option is activated - disables auto sync automatically (and enables it if the computer is using a LAN or WLAN again):

Best regards

Thomas

3 Likes

Windows has an option for metered bandwidth, so there should be an API as well which could be queried by Seafile to identify the kind of network (at least windows update has an option to disallow updating on metered connections, it is hidden within more options (Erweiterte Optionen)).

On Linux Iā€™m not sure if there is anything that could work with all linux systems.

Edit: Possibly this would work on all systems: https://doc.qt.io/qt-5/bearer-management.html

  • QNetworkSession::NoBackgroundTrafficPolicy
  • enum QNetworkConfiguration::BearerType
3 Likes

I think this would be a great feature.

1 Like

+1

I would love to see this feature implemented. Network-manager in linux has the ability to define if a connection is a metered connection.