Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-14743] BlackBerry: 'java' processes belonging to 'Appcelerator Studio' might kill the CPU

GitHub Issuen/a
TypeBug
PriorityCritical
StatusClosed
ResolutionFixed
Resolution Date2013-08-05T20:35:06.000+0000
Affected Version/sRelease 3.1.2
Fix Version/s2013 Sprint 16, Release 3.1.2, Release 3.2.0
ComponentsBlackBerry
Labelsperformance, qe-3.1.2, qe-testadded
ReporterFederico Casali
AssigneeRussell McMahon
Created2013-07-26T23:21:21.000+0000
Updated2013-10-01T22:12:15.000+0000

Description

Attachments

FileDateSize
processes.png2013-08-01T21:11:14.000+000035114
processes-commandLine.png2013-08-01T21:27:55.000+000032315
Screen Shot 2013-07-26 at 12.52.47 PM.png2013-07-26T23:21:21.000+0000102292
Screen Shot 2013-07-26 at 12.53.42 PM.png2013-07-26T23:21:21.000+000065676
Screen Shot 2013-07-26 at 4.11.22 PM.png2013-07-26T23:21:21.000+000047144

Comments

  1. Michael Xia 2013-07-31

    Both Federico and Pedro experienced the issue on Mac. It will be good to know if this happens on Windows as well.
  2. Shalom Gibly 2013-08-01

    Investigated this for a while, and looks like not much can be done from the Studio side. We call for a titanium process once and from that moment the node process is spawning other processes that are out of our control. The previously attached screen shot do not show the process hierarchy of those Java processes. I've attached another "processes.png" that shows it. You will notice that a node process is spawning sh processes that eventually spawn a java process. These processes on my system were getting a new pid every second, which may mean that there is some sort of a loop in the scripts that does that. I believe that something went wrong killing those processes and they kept on adding up.
  3. Shalom Gibly 2013-08-01

    Also attaching a screenshot that shows the same behavior when launching from a command-line with the following parameters:
       titanium --no-colors --no-prompt build --platform blackberry --sdk 3.2.0.v20130730132443 --log-level trace --target simulator --ndk /Applications/bbndk --ip-address 192.168.110.131
       
  4. Michael Xia 2013-08-01

    Hi Russ, could you or Pedro help take a look at this issue? If we look at both the process hierarchy tree or the screenshot Federico attached, the Java process belongs to the "sh" process, which comes from the node call. Running from the command line shows the similar tree. It appears there might be cases where some Java processes spawn by CLI didn't get terminated correctly and left running, causing issue with CPU and memory. Let me know if additional information is needed. Thanks.
  5. Russell McMahon 2013-08-02

    I'll take a look. The log file is retrieved on a timer and output printed to standard out. It's probably that interaction that is causing trouble, also are you able to reproduce using just terminal? It's probably easier to fix and debug if you can create a reproducible case using just CLI and terminal.
  6. Russell McMahon 2013-08-05

    https://github.com/appcelerator/titanium_mobile_blackberry/pull/148
  7. Federico Casali 2013-08-08

    Not able to reproduce the issue using the latest 3.1.2 SDK Titanium SDK 3.1.2.v20130807111603 Alloy 1.2.0-alpha6 Appcelerator Studio 3.1.2.201308021524 CLI 3.1.1 Node 0.10.13 Closing.

JSON Source