Skip to content

Javascript configuration prototype#49

Open
martinkuba wants to merge 1 commit intoMrAlias:mainfrom
martinkuba:js-prototype
Open

Javascript configuration prototype#49
martinkuba wants to merge 1 commit intoMrAlias:mainfrom
martinkuba:js-prototype

Conversation

@martinkuba
Copy link
Copy Markdown
Contributor

@martinkuba martinkuba commented Feb 16, 2023

For this prototype, I have converted the yaml configuration file to JSON since it is easier to read in JS. There are various yaml libraries, so I can change it to yaml if needed.

For dynamic loading of modules, I have used the import() function. It is an async operation, which means that applying the configuration would by async. This in turn means that potentially some data may be missed during startup (if the app creates spans/metrics/logs immediately on startup). Alternatively, we could use require(), which is a synchronous call.

The mapping of processor/exporter/etc. names to packages/classes will have to be hard-coded (or mapped somewhere).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant