Using an external EXE program to control CDR is extremely slow.

The external EXE program uses Type.GetTypeFromProgID to obtain a COM object instance to manipulate CDR, which is extremely slow.
I tested the same functionality: using Type.GetTypeFromProgID in C# to write the Position of Curve.Nodes for multiple shapes into a JSON file took 130 seconds.
However, when this functionality is built into the Addons folder as a plugin and performs the same steps, it only takes 10 seconds.
Is this normal?