NM-Qt: tens of blocking DBus calls for every nm device
Jan Grulich
jgrulich at redhat.com
Wed Sep 21 06:29:31 UTC 2016
Hi,
I'm aware that we do this. Give me few days to fix this in all NMQT classes,
like we do in Manager class.
Regards,
Jan
--
Jan Grulich <jgrulich at redhat.com>
Software Engineer, Desktop team
Red Hat Czech
On středa 21. září 2016 1:46:29 CEST Aleix Pol wrote:
> Hi networkmanagerers, plasmers,
> I have been looking into what kind of things happen between the plasma
> shell is booted and actually starts.
> An obvious way to check where we're blocking, is by seeing who is
> making blocking dbus calls. Adding a breakpoint to whenever there's a
> blocking dbus call goes lengths.
>
> A big pain point I've found is nm-qt's Device initialization.
>
> Maintainers, do you think it would be possible to lazily fetch these
> values instead of just populating everything upon construction? I'm
> positive it would have an immediate impact.
> I see few solutions:
> - Just using QDBusPendingReply so it will issue the call and only
> block when the value is actually read.
> - Issue a dbus call that gets all properties at once
> (org.freedesktop.DBus.Properties.GetAll). It will still block, but
> less.
> - Only ask for the value when requested, not before. Then it's
> probably less bad to block.
>
> HTH,
> Aleix
>
> [1]
> #0 QDBusConnection::call() at
> /home/apol/devel/frameworks/qt5/qtbase/src/dbus/qdbusconnection.cpp:689
> #1 QDBusAbstractInterfacePrivate::property() at
> /home/apol/devel/frameworks/qt5/qtbase/src/dbus/qdbusabstractinterface.cpp:1
> 79 #2 QDBusAbstractInterfaceBase::qt_metacall() at
> /home/apol/devel/frameworks/qt5/qtbase/src/dbus/qdbusabstractinterface.cpp:2
> 90 #3 QDBusAbstractInterface::qt_metacall() at
> /home/apol/build-devel/qt5/qtbase/src/dbus/.moc/moc_qdbusabstractinterface.c
> pp:97 #4 OrgFreedesktopNetworkManagerDeviceInterface::qt_metacall() at
> /home/apol/build-devel/frameworks/networkmanager-qt/src/moc_nm-deviceinterfa
> ce.cpp:248 #5 QMetaProperty::read(QObject const*) const() at
> /home/apol/devel/kde5/lib/libQt5Core.so.5
> #6 QObject::property(char const*) const() at
> /home/apol/devel/kde5/lib/libQt5Core.so.5
> #7 OrgFreedesktopNetworkManagerDeviceInterface::managed() at
> /home/apol/devel/frameworks/networkmanager-qt/src/dbus/nm-deviceinterface.h:
> 155 #8 NetworkManager::DevicePrivate::DevicePrivate() at
> /home/apol/devel/frameworks/networkmanager-qt/src/device.cpp:112
> #9 NetworkManager::Device::Device() at
> /home/apol/devel/frameworks/networkmanager-qt/src/device.cpp:198
> #10 NetworkManager::NetworkManagerPrivate::createNetworkInterface() at
> /home/apol/devel/frameworks/networkmanager-qt/src/manager.cpp:287
> #11 NetworkManager::NetworkManagerPrivate::findRegisteredNetworkInterface()
> at /home/apol/devel/frameworks/networkmanager-qt/src/manager.cpp:254
> #12 NetworkManager::NetworkManagerPrivate::networkInterfaces() at
> /home/apol/devel/frameworks/networkmanager-qt/src/manager.cpp:360
> #13 NetworkManager::networkInterfaces() at
> /home/apol/devel/frameworks/networkmanager-qt/src/manager.cpp:936
> #14 ConnectionIcon::ConnectionIcon() at
> /home/apol/devel/frameworks/plasma-nm/libs/declarative/connectionicon.cpp:63
> #15 QQmlPrivate::QQmlElement<ConnectionIcon>::QQmlElement() at
> /home/apol/devel/kde5/include/QtQml/qqmlprivate.h:99
> #16 QQmlPrivate::createInto<ConnectionIcon>() at
> /home/apol/devel/kde5/include/QtQml/qqmlprivate.h:108
> #17 QQmlType::create() at
> /home/apol/devel/frameworks/qt5/qtdeclarative/src/qml/qml/qqmlmetatype.cpp:7
> 61 #18 QQmlObjectCreator::createInstance() at
> /home/apol/devel/frameworks/qt5/qtdeclarative/src/qml/qml/qqmlobjectcreator.
> cpp:1057 #19 QQmlObjectCreator::setPropertyBinding() at
> /home/apol/devel/frameworks/qt5/qtdeclarative/src/qml/qml/qqmlobjectcreator.
> cpp:738 #20 QQmlObjectCreator::setupBindings() at
> /home/apol/devel/frameworks/qt5/qtdeclarative/src/qml/qml/qqmlobjectcreator.
> cpp:690 #21 QQmlObjectCreator::populateInstance() at
> /home/apol/devel/frameworks/qt5/qtdeclarative/src/qml/qml/qqmlobjectcreator.
> cpp:1325 #22 QQmlObjectCreator::createInstance() at
> /home/apol/devel/frameworks/qt5/qtdeclarative/src/qml/qml/qqmlobjectcreator.
> cpp:1183 #23 QQmlObjectCreator::create() at
> /home/apol/devel/frameworks/qt5/qtdeclarative/src/qml/qml/qqmlobjectcreator.
> cpp:200 #24 QQmlIncubatorPrivate::incubate() at
> /home/apol/devel/frameworks/qt5/qtdeclarative/src/qml/qml/qqmlincubator.cpp:
> 301 #25 QQmlIncubationController::incubateFor() at
> /home/apol/devel/frameworks/qt5/qtdeclarative/src/qml/qml/qqmlincubator.cpp:
> 394 #26 KDeclarative::QmlObjectIncubationController::incubate() at
> /home/apol/devel/frameworks/kdeclarative/src/kdeclarative/private/qmlobject_
> p.h:63
More information about the Plasma-devel
mailing list