Same output parameter from multiple plugins #146
-
I am currently initiating a project around plugins, and came around this question, What happens when two or more plugins are calculating the same metric, for ex. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
What should happen is the plugin later on in the pipeline overrides the value output by the plugin previous. It's valid that different plugins return different values for a parameter, they could be calculating them using different methodologies for instance. There are several examples already of plugins which calculate this and yet return very different values. The boavista CPU plug-in computes a very different CPU energy value because it's computing primary energy and is therefore computing a completely different methodology than the other plugins. One use case for two plugins in the same pipeline is perhaps the earlier plug-in gives a more ubiquitous general value and a later plug-in only gives more accurate values for a specific subset of CPUs. The canonical example here might be a generic plugin which tries to calculate a rough CPU energy for all CPUs and then later on you add an Intel only plugin which perhaps would give you more accurate values just for an Intel CPU. |
Beta Was this translation helpful? Give feedback.
-
@jawache yes valid points. Maybe something like |
Beta Was this translation helpful? Give feedback.
What should happen is the plugin later on in the pipeline overrides the value output by the plugin previous.
It's valid that different plugins return different values for a parameter, they could be calculating them using different methodologies for instance. There are several examples already of plugins which calculate this and yet return very different values. The boavista CPU plug-in computes a very different CPU energy value because it's computing primary energy and is therefore computing a completely different methodology than the other plugins.
One use case for two plugins in the same pipeline is perhaps the earlier plug-in gives a more ubiquitous general value and a later plug-in on…