Skip to content

feat: Nuxt module for Elastic APM on SSR & CSR#218

Open
rwd wants to merge 21 commits into
mainfrom
feat/EC-7573-elastic-apm-node
Open

feat: Nuxt module for Elastic APM on SSR & CSR#218
rwd wants to merge 21 commits into
mainfrom
feat/EC-7573-elastic-apm-node

Conversation

@rwd

@rwd rwd commented Jan 22, 2026

Copy link
Copy Markdown
Contributor
  • without elastic-apm-node as a dependency of the app pkg itself, i.e. the ds4ch app here, errors about ES imports were encountered when running the production build; not sure why, but having the dependency on the module pkg alone did not suffice
  • adding the --loader arg to the build step is necessary if the Elastic APM Node agent is able to auto-instrument node libraries in such an ES build
  • adding the --import arg to the runtime cmd is necessary to start the APM agent running early, before the Nuxt/Nitro app starts importing libraries, so that they actually are instrumented
  • to run the production build in Docker with the APM enabled:
    docker run \
      --env-file packages/apps/ds4ch/.env \
      --env NODE_OPTIONS="--import ./server/elastic-apm.server.mjs" \
      -i --rm --name europeana_ds4ch -p 8080:8080 \
      europeana/ds4ch

@github-actions

Copy link
Copy Markdown
Contributor

JIRA ticket: EC-7573

Comment thread packages/layers/base/package.json Outdated
Comment thread packages/modules/elastic-apm-nuxt/src/plugins/01-elastic-apm.server.ts Outdated
Comment thread packages/modules/elastic-apm-nuxt/src/elastic-apm.server.js
@rwd rwd changed the title feat: Nuxt module for elastic-apm-node feat: Nuxt module for Elastic APM on SSR & CSR Jan 28, 2026
@rwd rwd marked this pull request as ready for review January 28, 2026 15:07
Comment thread packages/apps/ds4ch/package.json
@sonarqubecloud

sonarqubecloud Bot commented Apr 8, 2026

Copy link
Copy Markdown

Quality Gate Failed Quality Gate failed

Failed conditions
5.0% Coverage on New Code (required ≥ 80%)

See analysis details on SonarQube Cloud

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.

3 participants