Zum Hauptinhalt springen

ExecuteCSharpNode

Namespace: Meshmakers.Octo.Sdk.Common.EtlDataPipeline.Nodes.Transforms

Executes inline C# code with typed arguments.

Arguments are passed as script globals (ExecuteCSharpGlobals.Args) resolved at run time, NOT inlined as literals. The compiled script text therefore only depends on the node's ExecuteCSharpNodeConfiguration.Code and its argument signature — never on the values — so it is compiled exactly once and reused for every subsequent execution. Baking values into the text (the previous behaviour) produced a distinct script per changing value, defeating the cache and leaking a compiled assembly per run (unbounded CPU + memory under a high-frequency pipeline).

public class ExecuteCSharpNode : IPipelineNode

Inheritance Object → ExecuteCSharpNode
Implements IPipelineNode

Constructors​

ExecuteCSharpNode(NodeDelegate)​

Executes inline C# code with typed arguments.

Arguments are passed as script globals (ExecuteCSharpGlobals.Args) resolved at run time, NOT inlined as literals. The compiled script text therefore only depends on the node's ExecuteCSharpNodeConfiguration.Code and its argument signature — never on the values — so it is compiled exactly once and reused for every subsequent execution. Baking values into the text (the previous behaviour) produced a distinct script per changing value, defeating the cache and leaking a compiled assembly per run (unbounded CPU + memory under a high-frequency pipeline).

public ExecuteCSharpNode(NodeDelegate next)

Parameters​

next NodeDelegate

Methods​

ProcessObjectAsync(IDataContext, INodeContext)​

public Task ProcessObjectAsync(IDataContext dataContext, INodeContext nodeContext)

Parameters​

dataContext IDataContext

nodeContext INodeContext

Returns​

Task

ClearCompiledScriptCache()​

Test seam: drop the process-wide compiled-script cache.

internal static void ClearCompiledScriptCache()