René's URL Explorer Experiment


Title: [platform-server] SSR for Standalone Component: bootstrapApplication have memory leaks · Issue #46473 · angular/angular · GitHub

Open Graph Title: [platform-server] SSR for Standalone Component: bootstrapApplication have memory leaks · Issue #46473 · angular/angular

X Title: [platform-server] SSR for Standalone Component: bootstrapApplication have memory leaks · Issue #46473 · angular/angular

Description: Which @angular/* package(s) are the source of the bug? platform-server Is this a regression? No Description ngModule version I clone the Angular Universal repo version from angular: checkout master then: pnpm install pnpm dev:ssr to serv...

Open Graph Description: Which @angular/* package(s) are the source of the bug? platform-server Is this a regression? No Description ngModule version I clone the Angular Universal repo version from angular: checkout master...

X Description: Which @angular/* package(s) are the source of the bug? platform-server Is this a regression? No Description ngModule version I clone the Angular Universal repo version from angular: checkout master...

Opengraph URL: https://github.com/angular/angular/issues/46473

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"[platform-server] SSR for Standalone Component: bootstrapApplication have memory leaks ","articleBody":"### Which @angular/* package(s) are the source of the bug?\r\n\r\nplatform-server\r\n\r\n### Is this a regression?\r\n\r\nNo\r\n\r\n### Description\r\n\r\n# ngModule version\r\nI clone the Angular Universal repo version from angular:\r\n\r\n- checkout master then: `pnpm install`\r\n- `pnpm dev:ssr` to serve\r\n- `nodemon --inspect=localhost:9236 dist/server/main.js` to inspect\r\n\r\nThen I start it and make a heap snapshot. it's fine.\r\nOpen dev tools for Node.js to inspect, Go to memory tab, search `module` keyword\r\n![image](https://user-images.githubusercontent.com/16970990/175274730-f916ae29-6844-4fb8-80bd-31d3163f0d65.png)\r\n\r\nfirst-time load home page:\r\n![image](https://user-images.githubusercontent.com/16970990/175272300-fb9306f2-1c90-42ec-a7d9-729302bc6772.png)\r\nload home page at second time:\r\n![image](https://user-images.githubusercontent.com/16970990/175272485-6b60981c-b889-4b8f-9179-3e99ef2a37ef.png)\r\n\r\nload home page at 20th times:\r\n![image](https://user-images.githubusercontent.com/16970990/175272463-3c3d8131-c363-48bf-901e-4e861569b972.png)\r\n\r\neverything is fine and no leak. NgModule only have 2 instance\r\n\r\n# Standalone version\r\n\r\nI upgrade the universal version of the standalone component, I'm going to make this on the universal repo, but first, it has a memory leak.\r\n\r\n- checkout master then: `pnpm install`\r\n- `pnpm dev:ssr` to serve\r\n- `nodemon --inspect=localhost:9236 dist/server/main.js` to inspect\r\n\r\ngo home page and f5 for 6 times:\r\n![image](https://user-images.githubusercontent.com/16970990/175273653-42ad493b-93df-4216-8d60-0b0910fcceff.png)\r\n\r\ngo home page and f5 for more 5 times:\r\n![image](https://user-images.githubusercontent.com/16970990/175273755-f871720a-ab46-4c2a-91b7-867dee1bb9df.png)\r\n\r\nwe get too many modules that are not clear and the heap memory goes \"To infinity and beyond\".\r\nThe ApplicationModule goes to x6 on 6 load pages, and x11 if you have 11 load pages.\r\n\r\n\r\n### Please provide a link to a minimal reproduction of the bug\r\n\r\nhttps://github.com/hiepxanh/universal-test\r\n\r\n### Please provide the exception or error you saw\r\n\r\n_No response_\r\n\r\n### Please provide the environment you discovered this bug in (run `ng version`)\r\n\r\n```true\r\nAngular CLI: 14.0.2\r\nNode: 16.13.1\r\nPackage Manager: pnpm 7.1.5\r\nOS: win32 x64\r\n\r\nAngular: 14.0.3\r\n... animations, common, compiler, compiler-cli, core, forms\r\n... platform-browser, platform-browser-dynamic, platform-server\r\n... router\r\n\r\nPackage                         Version\r\n---------------------------------------------------------\r\n@angular-devkit/architect       0.1400.2\r\n@angular-devkit/build-angular   14.0.2\r\n@angular-devkit/core            14.0.2\r\n@angular-devkit/schematics      14.0.2\r\n@angular/cli                    14.0.2\r\n@nguniversal/builders           14.0.1\r\n@nguniversal/common             14.0.1\r\n@nguniversal/express-engine     14.0.1\r\n@schematics/angular             14.0.2\r\nrxjs                            7.5.5\r\ntypescript                      4.7.4\r\n```\r\n\r\n\r\n### Anything else?\r\n\r\nI'm running the standalone SSR version in my production version. Current work around is restart the server :D","author":{"url":"https://github.com/hiepxanh","@type":"Person","name":"hiepxanh"},"datePublished":"2022-06-23T10:05:02Z","url":"https://github.com/angular/angular/issues/46473"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:360272d0-474d-3189-314f-17dbe43fced5
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idABDE:3D8CBB:1404255:1A6579F:6B0120D5
html-safe-noncec6d93257bd20b7899ff15475a8b221964c834fc5f1e9549cfbdacea2dd3d56aa
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBQkRFOjNEOENCQjoxNDA0MjU1OjFBNjU3OUY6NkIwMTIwRDUiLCJ2aXNpdG9yX2lkIjoiMjA0NjkwNzM5NTYwMjQ1Njc4OSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac149ab1f5a4d78f92bba73fc8213b0f9860c6ae70b242788ff9d701394f3cbcf7
hovercard-subject-tagissue:1282153094
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/angular/angular/46473/issue_layout
twitter:imagehttps://opengraph.githubassets.com/c4a948761168863d9251fd130aa5bfc07c36115e29416a5e0d2a3afb7cb3bf5c/angular/angular/issues/46473
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/c4a948761168863d9251fd130aa5bfc07c36115e29416a5e0d2a3afb7cb3bf5c/angular/angular/issues/46473
og:image:altWhich @angular/* package(s) are the source of the bug? platform-server Is this a regression? No Description ngModule version I clone the Angular Universal repo version from angular: checkout master...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamehiepxanh
hostnamegithub.com
expected-hostnamegithub.com
Nonecc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c
turbo-cache-controlno-preview
go-importgithub.com/angular/angular git https://github.com/angular/angular.git
octolytics-dimension-user_id139426
octolytics-dimension-user_loginangular
octolytics-dimension-repository_id24195339
octolytics-dimension-repository_nwoangular/angular
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id24195339
octolytics-dimension-repository_network_root_nwoangular/angular
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release8c77c9e8439031ad54c75a250694842892f693e1
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/angular/angular/issues/46473#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fangular%2Fangular%2Fissues%2F46473
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fangular%2Fangular%2Fissues%2F46473
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=angular%2Fangular
Reloadhttps://github.com/angular/angular/issues/46473
Reloadhttps://github.com/angular/angular/issues/46473
Reloadhttps://github.com/angular/angular/issues/46473
angularhttps://github.com/angular
angularhttps://github.com/angular/angular
Codehttps://github.com/angular/angular
Issues835 (835)https://github.com/angular/angular/issues
Pull requests141 (141)https://github.com/angular/angular/pulls
Discussionshttps://github.com/angular/angular/discussions
Actionshttps://github.com/angular/angular/actions
Projectshttps://github.com/angular/angular/projects
Security and quality40 (40)https://github.com/angular/angular/security
Insightshttps://github.com/angular/angular/insights
https://github.com/angular/angular
New issuehttps://github.com/login?return_to=https://github.com/angular/angular/issues/46473
New issuehttps://github.com/login?return_to=https://github.com/angular/angular/issues/46473
[platform-server] SSR for Standalone Component: bootstrapApplication have memory leaks https://github.com/angular/angular/issues/46473#top
https://github.com/AndrewKushnir
P2The issue is important to a large percentage of users, with a workaroundhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22P2%22
area: serverIssues related to server-side renderinghttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22area%3A%20server%22
bughttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22bug%22
cross-cutting: standaloneIssues related to the NgModule-less worldhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22cross-cutting%3A%20standalone%22
memory leakIssue related to a memory leakhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22memory%20leak%22
state: has PRhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22state%3A%20has%20PR%22
Backloghttps://github.com/angular/angular/milestone/82
https://github.com/hiepxanh
hiepxanhhttps://github.com/hiepxanh
on Jun 23, 2022https://github.com/angular/angular/issues/46473#issue-1282153094
https://user-images.githubusercontent.com/16970990/175274730-f916ae29-6844-4fb8-80bd-31d3163f0d65.png
https://user-images.githubusercontent.com/16970990/175272300-fb9306f2-1c90-42ec-a7d9-729302bc6772.png
https://user-images.githubusercontent.com/16970990/175272485-6b60981c-b889-4b8f-9179-3e99ef2a37ef.png
https://user-images.githubusercontent.com/16970990/175272463-3c3d8131-c363-48bf-901e-4e861569b972.png
https://user-images.githubusercontent.com/16970990/175273653-42ad493b-93df-4216-8d60-0b0910fcceff.png
https://user-images.githubusercontent.com/16970990/175273755-f871720a-ab46-4c2a-91b7-867dee1bb9df.png
https://github.com/hiepxanh/universal-testhttps://github.com/hiepxanh/universal-test
Nexthttps://github.com/angular/angular/issues/46473?timeline_page=1
https://github.com/hiepxanh
hiepxanhhttps://github.com/hiepxanh
on Jun 23, 2022https://github.com/angular/angular/issues/46473#issuecomment-1164230041
https://user-images.githubusercontent.com/16970990/175276203-26448b32-0bf9-47c1-8250-2f86c57f4c9c.png
https://user-images.githubusercontent.com/16970990/175276048-fbf13fc3-fd98-4b12-980e-d1b38223b08f.png
https://github.com/hiepxanh
hiepxanhhttps://github.com/hiepxanh
on Jun 23, 2022https://github.com/angular/angular/issues/46473#issuecomment-1164231932
https://user-images.githubusercontent.com/16970990/175276416-46b9890f-dbd7-478f-ad42-48f179554e59.png
https://user-images.githubusercontent.com/16970990/175276509-98c78ee1-b364-43be-95ac-e0c391d628ce.png
https://user-images.githubusercontent.com/16970990/175277136-1b9260c5-b1de-4fbc-a2dd-deb2ad2d423f.png
hiepxanhhttps://github.com/hiepxanh
on Jun 23, 2022https://github.com/angular/angular/issues/46473#event-6865036630
hiepxanhhttps://github.com/hiepxanh
on Jun 23, 2022https://github.com/angular/angular/issues/46473#event-6865040208
pkozlowski-opensourcehttps://github.com/pkozlowski-opensource
area: serverIssues related to server-side renderinghttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22area%3A%20server%22
cross-cutting: standaloneIssues related to the NgModule-less worldhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22cross-cutting%3A%20standalone%22
on Jun 23, 2022https://github.com/angular/angular/issues/46473#event-6865512578
ngbothttps://github.com/apps/ngbot
needsTriagehttps://github.com/angular/angular/milestone/83
on Jun 23, 2022https://github.com/angular/angular/issues/46473#event-6865512855
https://github.com/alan-agius4
alan-agius4https://github.com/alan-agius4
on Jun 23, 2022https://github.com/angular/angular/issues/46473#issuecomment-1164448920
pkozlowski-opensourcehttps://github.com/pkozlowski-opensource
memory leakIssue related to a memory leakhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22memory%20leak%22
on Jun 23, 2022https://github.com/angular/angular/issues/46473#event-6866996608
https://github.com/hiepxanh
hiepxanhhttps://github.com/hiepxanh
on Jun 23, 2022https://github.com/angular/angular/issues/46473#issuecomment-1164595138
https://github.com/alxhub
alxhubhttps://github.com/alxhub
on Jun 23, 2022https://github.com/angular/angular/issues/46473#issuecomment-1165003258
alxhubhttps://github.com/alxhub
P2The issue is important to a large percentage of users, with a workaroundhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22P2%22
bughttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22bug%22
on Jun 23, 2022https://github.com/angular/angular/issues/46473#event-6870400604
ngbothttps://github.com/apps/ngbot
needsTriagehttps://github.com/angular/angular/milestone/83
on Jun 23, 2022https://github.com/angular/angular/issues/46473#event-6870400725
https://github.com/AndrewKushnir
AndrewKushnirhttps://github.com/AndrewKushnir
on Jun 25, 2022https://github.com/angular/angular/issues/46473#issuecomment-1166174742
@hiepxanhhttps://github.com/hiepxanh
from that PRhttps://app.circleci.com/pipelines/github/angular/angular/47728/workflows/f3d30c24-04dc-4895-a264-a76b95ab7a88/jobs/1184898/artifacts
https://github.com/hiepxanh
hiepxanhhttps://github.com/hiepxanh
on Jun 25, 2022https://github.com/angular/angular/issues/46473#issuecomment-1166174918
@AndrewKushnirhttps://github.com/AndrewKushnir
https://github.com/hiepxanh
hiepxanhhttps://github.com/hiepxanh
on Jun 25, 2022https://github.com/angular/angular/issues/46473#issuecomment-1166177376
@AndrewKushnirhttps://github.com/AndrewKushnir
https://user-images.githubusercontent.com/16970990/175755621-51ae7402-e1b9-4e6f-909b-01d6ef51041c.png
https://github.com/AndrewKushnir
AndrewKushnirhttps://github.com/AndrewKushnir
on Jun 27, 2022https://github.com/angular/angular/issues/46473#issuecomment-1167634063
@hiepxanhhttps://github.com/hiepxanh
dylhunnhttps://github.com/dylhunn
completedhttps://github.com/angular/angular/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
8b6f421https://github.com/angular/angular/commit/8b6f4215a3c13a44d989d6068f6fb4625f3bab67
on Jun 28, 2022https://github.com/angular/angular/issues/46473#event-6896956979
dylhunnhttps://github.com/dylhunn
on Jun 28, 2022https://github.com/angular/angular/issues/46473#event-6896957106
fix(core): trigger `ApplicationRef.destroy` when Platform is destroyed (https://github.com/angular/angular/commit/1e7f22f00ab10a6ae01729e3355871e51bc8bf4d
https://docs.github.com/articles/closing-issues-via-commit-messages
1e7f22fhttps://github.com/angular/angular/commit/1e7f22f00ab10a6ae01729e3355871e51bc8bf4d
https://github.com/AndrewKushnir
AndrewKushnirhttps://github.com/AndrewKushnir
on Jun 29, 2022https://github.com/angular/angular/issues/46473#issuecomment-1170562228
@hiepxanhhttps://github.com/hiepxanh
https://github.com/hiepxanh
hiepxanhhttps://github.com/hiepxanh
on Jun 29, 2022https://github.com/angular/angular/issues/46473#issuecomment-1170563543
https://github.com/hiepxanh
hiepxanhhttps://github.com/hiepxanh
on Jun 29, 2022https://github.com/angular/angular/issues/46473#issuecomment-1170578692
@AndrewKushnirhttps://github.com/AndrewKushnir
https://user-images.githubusercontent.com/16970990/176560408-95b97abd-24d5-49ec-81fc-ef1dadc312b1.png
https://github.com/AndrewKushnir
AndrewKushnirhttps://github.com/AndrewKushnir
on Jun 29, 2022https://github.com/angular/angular/issues/46473#issuecomment-1170593104
@hiepxanhhttps://github.com/hiepxanh
https://github.com/apps/angular-automatic-lock-bot
angular-automatic-lock-bothttps://github.com/apps/angular-automatic-lock-bot
on Jul 30, 2022https://github.com/angular/angular/issues/46473#issuecomment-1200244050
automatic conversation locking policyhttps://github.com/angular/angular/blob/8f24bc9443b3872fe095d9f7f77b308a361a13b4/docs/GITHUB_PROCESS.md#conversation-locking
angular-automatic-lock-bothttps://github.com/apps/angular-automatic-lock-bot
on Jul 30, 2022https://github.com/angular/angular/issues/46473#event-7094659712
Sign up for freehttps://github.com/signup?return_to=https://github.com/angular/angular/issues/46473
Sign in to commenthttps://github.com/login?return_to=https://github.com/angular/angular/issues/46473
AndrewKushnirhttps://github.com/AndrewKushnir
P2The issue is important to a large percentage of users, with a workaroundhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22P2%22
area: serverIssues related to server-side renderinghttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22area%3A%20server%22
bughttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22bug%22
cross-cutting: standaloneIssues related to the NgModule-less worldhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22cross-cutting%3A%20standalone%22
memory leakIssue related to a memory leakhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22memory%20leak%22
state: has PRhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22state%3A%20has%20PR%22
BacklogNo due datehttps://github.com/angular/angular/milestone/82
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.