nx-console: [WebStorm/IntelliJ] Nx console plugin causes high CPU load
Current Behavior
- When the plugin is active, it often spawns a “node” process which will consume a lot of CPU.
- It seems one “node” process will be spawned per project
- It happens both on Webstorm and Intellij
- Even after you close the IDE, the
nodeprocess will keep running until you either force-quit it or restart the machine
Expected Behavior
This should not happen
Steps to Reproduce
- Use
WebStorm 2023.3.4 - Install
Nx Console 1.18.0and enable the plugin - Observe the high CPU load caused by some
nodeprocess - Not sure if this makes a difference, probably not, but I tried on several Angular-based projects
Failure Logs / Images / Videos
No logs available
Environment
- macOS 13.6.3
- Nx Console version: 1.18.0
- WebStorm version: 2023.3.4
- (also tried on IntelliJ)
About this issue
- Original URL
- State: open
- Created 4 months ago
- Reactions: 2
- Comments: 23 (5 by maintainers)
@jaysoo Here is an additional log tail from closing PyCharm moment. Maybe it will be helpful.
`2024-05-01 23:46:40,610 [2604912] INFO - #c.i.o.w.i.WindowManagerImpl - === Release(true) frame on closed project === 2024-05-01 23:46:40,616 [2604918] INFO - #dev.nx.console.nxls.NxlsWrapper - Stopping nxls 2024-05-01 23:46:40,616 [2604918] FINER - #dev.nx.console.nxls.NxlsWrapper - Sending request to nxls: shutdown (null) 2024-05-01 23:46:40,619 [2604921] INFO - #dev.nx.console.nxls.client.NxlsLanguageClient - [Nxls] - 2024-05-01T20:46:40.618Z - Unregistering file watcher
2024-05-01 23:46:40,625 [2604927] INFO - #zielu.gittoolbox.blame.cache.xodus - Deleted 0 expired files 2024-05-01 23:46:40,626 [2604928] INFO - #zielu.gittoolbox.blame.cache.xodus - Deleted 0 expired revisions 2024-05-01 23:46:40,629 [2604931] FINER - #dev.nx.console.nxls.NxlsWrapper - Error from nxls: Request shutdown failed with message: Connection is disposed. 2024-05-01 23:46:40,662 [2604964] INFO - #c.i.u.s.SvgCacheManager - SVG icon cache is closed 2024-05-01 23:46:40,667 [2604969] INFO - #c.i.o.v.i.l.NativeFileWatcherImpl - Watcher terminated with exit code 0 2024-05-01 23:46:40,671 [2604973] INFO - #o.j.i.BuiltInServer - web server stopped 2024-05-01 23:46:40,680 [2604982] INFO - #c.i.u.i.FileBasedIndexImpl - Index dispose started 2024-05-01 23:46:40,717 [2605019] INFO - #c.i.p.s.StubIndexImpl - StubIndexExtension-s were unloaded 2024-05-01 23:46:40,717 [2605019] INFO - #c.i.p.s.SerializationManagerImpl - Start shutting down /Users/…/Library/Caches/JetBrains/PyCharm2024.1/index/rep.names 2024-05-01 23:46:40,718 [2605020] INFO - #c.i.p.s.SerializationManagerImpl - Finished shutting down /Users/…/Library/Caches/JetBrains/PyCharm2024.1/index/rep.names 2024-05-01 23:46:40,719 [2605021] INFO - #c.i.u.i.FileBasedIndexImpl - Index dispose completed in 39ms. 2024-05-01 23:46:40,726 [2605028] INFO - #c.i.o.v.n.p.PersistentFSImpl - VFS dispose started 2024-05-01 23:46:40,728 [2605030] INFO - #c.i.o.v.n.p.FSRecordsImpl - VFS closing 2024-05-01 23:46:40,729 [2605031] INFO - #c.i.o.v.n.p.PersistentFSImpl - VFS dispose completed in 2 ms. 2024-05-01 23:46:40,731 [2605033] INFO - #c.i.o.f.i.FileTypeDetectionService - 21 auto-detected files. Detection took 55 ms 2024-05-01 23:46:40,739 [2605041] INFO - #c.i.p.i.b.AppStarter - ------------------------------------------------------ IDE SHUTDOWN ------------------------------------------------------`
@MaxKless It’s fixed and works well in my case. Thanks.
@jaysoo idea.log_sanitized.zip
Thank you, that is consistent with what I observe as well. We’ll fix this.
I’ve got issues with node process CPU sage after closing PyCharm 2024.1. Everything works well before I close the PyCharm. After closing the node process doesn’t stop and use 150% of CPU.
M1Pro Macbook