Replacing QDBusInterface usage with the interface generated by qdbusxml2cpp
ClosedPublic

Authored by ivan on Nov 14 2015, 9:33 PM.

Details

Summary

This patch replaces QDBusInterface usage for checking KAMD service version with the interface generated by qdbusxml2cpp.

The reason is that QDBusInterface has blocking introspection calls in its constructor (!?) which can block for up to 25 seconds. According to Thiago (I've found this bug from the Harmattan era) it is not a bug. Or it is a really low priority one, and we should all use just interfaces generated with qdbusxml2cpp.

Diff Detail

Repository
R6 KActivities
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
ivan updated this revision to Diff 1287.Nov 14 2015, 9:33 PM
ivan retitled this revision from to Replacing QDBusInterface usage with the interface generated by qdbusxml2cpp.
ivan updated this object.
ivan edited the test plan for this revision. (Show Details)
ivan added a reviewer: graesslin.
ivan set the repository for this revision to R6 KActivities.
ivan added a project: KActivities.
davidedmundson accepted this revision.Nov 14 2015, 9:49 PM
davidedmundson added a reviewer: davidedmundson.
davidedmundson added a subscriber: davidedmundson.

Yeah, QDBusInterface blocks as it needs introspection to generate the properties/slots and stuff. It's a confusingly rubbish class.

FYI you could have also solved it by creating a QDBusMessage::createMethodCall by hand, rather than making an interface object at all. It'd be a smaller patch, but this is good too.

This revision is now accepted and ready to land.Nov 14 2015, 9:49 PM
This revision was automatically updated to reflect the committed changes.
ivan added a comment.Nov 14 2015, 10:48 PM

FYI you could have also solved it by creating a QDBusMessage::createMethodCall

You are becoming David 5 (after David 4) :)

Thanks for the hint.