Frontmatter
| id | 9419 |
| title | Implement Dynamic Module Loading in `Neo.worker.Data` |
| state | Closed |
| labels | enhancementaicore |
| assignees | tobiu |
| createdAt | Mar 9, 2026, 4:46 PM |
| updatedAt | Mar 12, 2026, 3:54 PM |
| githubUrl | https://github.com/neomjs/neo/issues/9419 |
| author | tobiu |
| commentsCount | 1 |
| parentIssue | 9449 |
| subIssues | [] |
| subIssuesCompleted | 0 |
| subIssuesTotal | 0 |
| blockedBy | [] |
| blocking | [] |
| closedAt | Mar 12, 2026, 3:54 PM |
Implement Dynamic Module Loading in Neo.worker.Data
tobiu added parent issue #9404 on Mar 9, 2026, 4:46 PM
tobiu cross-referenced by #9420 on Mar 9, 2026, 4:46 PM
tobiu assigned to @tobiu on Mar 9, 2026, 4:47 PM
tobiu cross-referenced by #9449 on Mar 12, 2026, 3:20 PM
tobiu removed parent issue #9404 on Mar 12, 2026, 3:21 PM
tobiu added parent issue #9449 on Mar 12, 2026, 3:21 PM

tobiu
Mar 12, 2026, 3:54 PM
Input from Gemini 3.1 Pro:
✦ I have successfully implemented dynamic module loading in
Neo.worker.Data.Changes Made
- Added the
remoteconfig mapping to exposeloadModuleto theappworker.- Implemented
async loadModule({path})which utilizes Webpack's dynamicimport()capabilities natively.- Integrated the specific
webpackExcluderule/* webpackExclude: /(?:\/|\\)(dist|node_modules)\/(?!neo.mjs)/ */to ensure robust bundler chunking and ignore irrelevant system folders.- Ran all unit tests (331) successfully.
Code has been committed and pushed under
#9419.
tobiu closed this issue on Mar 12, 2026, 3:54 PM
Goal
Add a remote method access (RMA) endpoint to the Data Worker to dynamically import ES modules at runtime.
Context
To achieve a high-performance
Connection -> Parser -> Normalizerpipeline inside the Data Worker, the Data Worker needs access to application-specificParserandNormalizerclasses. Instead of serializing complex mapping functions across thread boundaries, the App Worker will instruct the Data Worker to dynamicallyimport()the necessary module files.Architecture
async loadModule({path})method insrc/worker/Data.mjs(similar to the existing test helper in the App Worker).await import(/* webpackIgnore: true */ path)to load the module natively.