Skip to content

fix: initialize lazy compilation backend earlier#9342

Merged
JSerFeng merged 1 commit intomainfrom
lazy_backend_0217
Feb 17, 2025
Merged

fix: initialize lazy compilation backend earlier#9342
JSerFeng merged 1 commit intomainfrom
lazy_backend_0217

Conversation

@chenjiahan
Copy link
Copy Markdown
Member

@chenjiahan chenjiahan commented Feb 17, 2025

Summary

The lazy compilation backend needs to listen to the server's "listening" event, and we need to ensure that the backend is initialized before the listen() call.

There are two cases:

  1. When using Rspack's default lazy compilation server, we can ensure this.
  2. When users configured backend.server, the listen() method is called by the user, which is usually earlier than compiler.hooks.beforeCompile hook.

This PR moves up the timing of the backend initialization to avoid the second case.

Checklist

  • Tests updated (or not required).
  • Documentation updated (or not required).

@github-actions github-actions bot added release: bug fix release: bug related release(mr only) team The issue/pr is created by the member of Rspack. labels Feb 17, 2025
@netlify
Copy link
Copy Markdown

netlify bot commented Feb 17, 2025

Deploy Preview for rspack canceled.

Name Link
🔨 Latest commit f6d91bf
🔍 Latest deploy log https://app.netlify.com/sites/rspack/deploys/67b306ad8089b5000842a356

@codspeed-hq
Copy link
Copy Markdown

codspeed-hq bot commented Feb 17, 2025

CodSpeed Performance Report

Merging #9342 will not alter performance

Comparing lazy_backend_0217 (f6d91bf) with main (d1c321f)

🎉 Hooray! codspeed-node just leveled up to 4.0.0!

A heads-up, this is a breaking change and it might affect your current performance baseline a bit. But here's the exciting part - it's packed with new, cool features and promises improved result stability 🥳!
Curious about what's new? Visit our releases page to delve into all the awesome details about this new version.

Summary

✅ 6 untouched benchmarks

@chenjiahan chenjiahan requested a review from JSerFeng February 17, 2025 10:30
@JSerFeng JSerFeng merged commit fd5c313 into main Feb 17, 2025
40 checks passed
@JSerFeng JSerFeng deleted the lazy_backend_0217 branch February 17, 2025 10:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release: bug fix release: bug related release(mr only) team The issue/pr is created by the member of Rspack.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants