Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Webpack serialization performance warnings when using @sentry/nextjs #15100

Open
3 tasks done
scobbe opened this issue Jan 20, 2025 · 1 comment
Open
3 tasks done

Webpack serialization performance warnings when using @sentry/nextjs #15100

scobbe opened this issue Jan 20, 2025 · 1 comment
Labels
Package: nestjs Issues related to the Sentry Nestjs SDK Waiting for: Community

Comments

@scobbe
Copy link

scobbe commented Jan 20, 2025

Is there an existing issue for this?

How do you use Sentry?

Sentry Saas (sentry.io)

Which SDK are you using?

@sentry/nestjs

SDK Version

8.50.0

Framework Version

React 19.0.0, Next 15.1.4, Node 22.9.0

Link to Sentry event

No response

Reproduction Example/SDK Setup

Description

When adding Sentry configuration to next.config.ts using withSentryConfig, I encounter the following warning during the build process:

<w> [webpack.cache.PackFileCacheStrategy] Serializing big strings (318kiB) impacts deserialization performance (consider using Buffer instead and decode when needed)

Is this a known issue? Are there any recommendations for addressing this warning, such as additional configuration options or workarounds?

Thank you!

Steps to Reproduce

  1. Start with a minimal next.config.ts file:

    import type { NextConfig } from "next";
    
    const nextConfig: NextConfig = {};
    
    export default nextConfig;
  2. Update the file to include Sentry's configuration using withSentryConfig:

    import type { NextConfig } from "next";
    
    import { withSentryConfig } from "@sentry/nextjs";
    
    const nextConfig: NextConfig = {};
    
    export default withSentryConfig(nextConfig, {
      automaticVercelMonitors: true,
      disableLogger: true,
      hideSourceMaps: true,
      org: "MyOrg",
      project: "javascript-nextjs",
      reactComponentAnnotation: {
        enabled: true,
      },
      silent: !process.env.CI,
      sourcemaps: {
        deleteSourcemapsAfterUpload: true,
        disable: process.env.NODE_ENV === "development",
      },
      tunnelRoute: "/monitoring",
      widenClientFileUpload: true,
    });
  3. Run the build process.

Expected Result

The build completes without warnings or errors.

Actual Result

The following warning appears during the build process:

<w> [webpack.cache.PackFileCacheStrategy] Serializing big strings (318kiB) impacts deserialization performance (consider using Buffer instead and decode when needed)
@getsantry getsantry bot moved this to Waiting for: Product Owner in GitHub Issues with 👀 3 Jan 20, 2025
@github-actions github-actions bot added the Package: nestjs Issues related to the Sentry Nestjs SDK label Jan 20, 2025
@andreiborza
Copy link
Member

Hello @scobbe, thank you for filing this.

Could you please provide a reproduction repo? I tried setting up a new nextjs project using npx create-next-app@latest and setting Sentry up using npx @sentry/wizard@latest -i nextjs but did not run into any such warnings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Package: nestjs Issues related to the Sentry Nestjs SDK Waiting for: Community
Projects
Status: Waiting for: Community
Development

No branches or pull requests

3 participants