Bug 268381 - In built-in editor a context menu launches 6 new processes
In built-in editor a context menu launches 6 new processes
Product: cnd
Classification: Unclassified
Component: execution
PC Solaris
: P3 (vote)
: Dev
Assigned To: ilia
Depends on:
  Show dependency treegraph
Reported: 2016-10-06 15:26 UTC by soldatov
Modified: 2017-07-20 17:51 UTC (History)
0 users

See Also:
Issue Type: DEFECT

Fix (5.30 KB, patch)
2017-06-21 21:44 UTC, ilia
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description soldatov 2016-10-06 15:26:06 UTC
Currently I use full IDE and I don't use C or C++ projects.

- Launch Dtrace script: dtrace -qn 'syscall::exec*:return { printf("%Y %s %s\n",walltimestamp,curpsinfo->pr_fname, curpsinfo->pr_psargs); }'
- Open Java file in NetBeans editor
- Call context menu in editor
- Wait 5 seconds
- Check Dtrace output
2016 Oct  6 18:10:01 jspawnhelper 396:410
2016 Oct  6 18:10:01 pty /var/tmp/dlight_sova/53e6af52/0644676033/pty --no-pty /bin/sh /var/tmp/dlight_s
2016 Oct  6 18:10:02 ksh93 /bin/sh /var/tmp/dlight_sova/53e6af52/sendto.1678152327.8692787425451500937 /ex
2016 Oct  6 18:10:03 ksh93 /bin/sh /var/tmp/dlight_sova/53e6af52/sendto.720080985.1944758128685490846 /exp
2016 Oct  6 18:10:03 ksh93 /bin/sh /var/tmp/dlight_sova/53e6af52/sendto.596765398.3898306705035691460 /exp
2016 Oct  6 18:10:03 jspawnhelper 406:413
2016 Oct  6 18:10:03 pty /var/tmp/dlight_sova/53e6af52/0644676033/pty --no-pty /bin/sh /var/tmp/dlight_s
2016 Oct  6 18:10:03 jspawnhelper 412:416
2016 Oct  6 18:10:03 pty /var/tmp/dlight_sova/53e6af52/0644676033/pty --no-pty /bin/sh /var/tmp/dlight_s

Every time IDE starts 6 external processes and 3 jspawnhelper processes.
Comment 1 Alexander Simon 2016-10-06 15:42:55 UTC
It's a send-to validators.
Remove all stuff from send-to and try again.
Does it help?
Comment 2 Vladimir Voskresensky 2016-10-06 15:56:03 UTC
Yes, it is "Send To..." container which initializes own not-yet-visible children-actions when become visible itself. The same issue we filed against Versioning: Initialize only when user goes into SendTo submenu
Comment 3 ilia 2017-06-14 10:28:24 UTC
I can't find (yet) a good way to initialize subMenu only when this subMenu is entered.

Maybe it's easier to wrap SendTo... with Tools menu, as it is done in file/project view.
Also it worth moving MixedDev there. (In file view it's also under tools).
Comment 4 ilia 2017-06-21 21:44:15 UTC
Created attachment 164594 [details]

This fix works, but it's not good to move initialization to getPopupMenu()
Comment 5 Quality Engineering 2017-07-20 17:51:40 UTC
Integrated into 'main-silver', will be available in build *201707201608* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/1d285dd9276e
User: Ilia Gromov <ilia@netbeans.org>
Log: Fixed #268381 - In built-in editor a context menu launches 6 new processes

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo