Details
-
Epic
-
Resolution: Unresolved
-
Not Evaluated
-
None
-
None
-
Stable API for Runcontrol / Runworker
-
bd818c7f0 (11.0), 2cc496745 (master), 941c99c89 (master), e53bc1630 (master), a5ecc6207 (master), b196f5f03 (master), f9fb3f487 (master), 619c49958 (master), 382e003de (master), e75b81b0a (master), 9888e1982 (master), 4c8c793c0 (master)
Description
RunControl, together with a number of dynamically created instances of RunWorker (45 different subclasses), is responsible for running user applications / profilers / debuggers, etc. The current implementation is error-prone with regards to the manual managing of the RunWorkers' lifetime, hidden dependencies between them, unexpected state transitions, and cumbersome data exchange between them.
The alternative design would be to use TaskTree as a replacement of RunControl, and operate on task tree recipes returned by relevant RunWorkerFactories instead on instances of RunWorker subclasses.
More details:
The request for "stable Qt Creator Plugin API" comes up regularly. We currently still need the freedom to change also core API, but for limited areas this seems in reach. This here is one of them.
The current API is sufficient for the current purposes and has not changed significantly since 2019, but it's not good enough to set in stone in its current shape.
We have (among others) two special kind of plugins, one set providing "platform" support (i.e. organize the actual of process on certain devices, possibly accessing the file system there - 'local', android, baremetal, ios, (remote)linux, docker, qnx, [webassembly, vxworks]) and "tool" support (input/output handling of certain 'tools' that can potentially run on different devices = 'normal application run', debugger (c++/qml/mixed - gdb/lldb/cdb), qmlprofiler, perf, profiler (memcheck, cachegrind),). The challenge here is to organize combination of those (i.e. "run a given tool on a certain plugin") without creating dependencies between the respective "platform plugin" and "tool plugins" (internally known as "The Matrix Problem" as the "obvious" solution to have specialized plugins for each combination does not scale).
With the current RunWorker system we have a partial solution to the Matrix problem, splitting the platform and tool parts into two workers, but setting up the right dependencies between them, especially when extra glue is needed (e.g. using PortGatherers to get free ports for comunication) it is pretty much ad hoc.
We should move the whole machinery to use uniformly TaskTree for dependency management and Aspects for data.
Attachments
Issue Links
- relates to
-
QTCREATORBUG-29337 New plugin/extension manager
- Open
-
QTCREATORBUG-31844 Redesign of RunControl / RunWorker
- Closed
Gerrit Reviews
For Gerrit Dashboard: QTCREATORBUG-29168 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
605420,8 | QmlPreview: Remove RefreshTranslationWorker | master | qt-creator/qt-creator | Status: NEW | -2 | 0 |
605776,17 | Ios: Move part of start setup into IosDebugSupport's c'tor | master | qt-creator/qt-creator | Status: NEW | 0 | 0 |