Skip to content

perf(plugin-native): move runtime_param_schema and get_source_config to worker thread #356

@staging-devin-ai-integration

Description

Context

runtime_param_schema (wrapper.rs:776) and get_source_config (wrapper.rs:1250) remain synchronous/unguarded outliers — they are called on the async side without timeout, catch_unwind, or routing through the worker thread.

What needs to happen

  1. Route both calls through the worker thread's WorkerRequest channel (add new variants)
  2. Apply the same catch_unwind + timeout pattern used for other FFI calls
  3. Handle the chicken-and-egg problem: get_source_config is called before the tick loop starts, and runtime_param_schema is called during node registration (before the worker exists)

Why not now

This was identified during the PR 3 (worker thread) review. Both calls happen at low frequency (once per instance creation / start), so the risk is low. The refactor requires rethinking the call timing vs. worker lifecycle, which is better handled as a separate change.

References

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions