facebook

CI9 prelease sporadic UI problem

  1. CodeMix & Angular IDE
  2.  > 
  3. Webclipse 1.x Help
Viewing 15 posts - 1 through 15 (of 21 total)
  • Author
    Posts
  • #543117 Reply

    Fedor Losev
    Participant

    With CI9 preview there is some strange problem. After a while UI stops working.

    It is not freezed and appears ok but many basic things do nothing, e.g. build, typing in open resource dialog, typing in Show View dialog just nothing happens.

    After closing the IDE, the main window closes and then either it suddnely shows progress dialog for build and then exits after rebuilding or hangs on “Saving workbench state”.

    I didn’t find convincing reproduction steps or scenarios but it happens after a while, probably after heavy changes like merging from git.

    I don’t see any relevant error in error log except this one (this may be relevant but it is logged also when problem is not present) .

    #543142 Reply

    Fedor Losev
    Participant

    This seems a critical issue, the last time it did hang and I had to kill Eclipse, the workspace was completely wiped out and initialized from scratch.

    #543236 Reply

    support-swapna
    Moderator

    Fedor,

    Sorry that you are seeing this issue. It does seem to be a critical problem. We haven’t seen this issue at our end. I have forwarded it to the dev team and they are looking into it. We will get back to you if we need more details.

    Apologies for inconvenience caused.

    –Swapna
    MyEclipse Support

    #543387 Reply

    Brian Fernandes
    Moderator

    Fedor,

    The build / saving workspace dialog can appear after you exit the IDE, but of course, it should terminate by itself. Prior to that, not being able to do anything in the IDE should obviously not happen either. Have you run into this problem again since your last report?

    Can you answer the following questions:
    1) Have you observed what build process is running in the dialog on exit workspace? (is it building TS, Java, etc.?)

    2) When the issue does occur, can you get a thread dump for us using jstack? In case you don’t know how, please see section one in this article: https://blog.fastthread.io/2016/06/06/how-to-take-thread-dumps-7-options/

    The dump will let us know what is running when you experience the issue and perhaps that will give us a clue on how to proceed.

    Apologies for the disruptive experience, we hope will be able to track this down with your help.

    #543486 Reply

    Fedor Losev
    Participant

    Here is more input:

    It happens right now. It happened by just leaving the IDE overnight, nothing was done and it was working fine before I leave.

    In seems not directly related to build operation (well, may be except that it causes operation progress to display differently without queue on exit) and is not a problem of exit itself (exit hang is just a consequence).

    With non-working build operation on exit if I remember correctly there was some simple waiting message “saving workspace”. Now I did restart after nothing is working but without invoking the build. What I saw is the progress queue of all operations I tried before (and which did nothing) – there was open resource for CTRL+R, git pull, etc. seemingly waiting for the first operation (I think git pull). Stopping an operation continued exiting regularly and without a problem.

    Of course difference with exit dialog may be (and probably is) just coincidence with build operation.

    Next time it happens I will try to see what is in progress queue before exit and if it is somehow related to specific operation like git pull. If no evidence I’ll do thread dump but if we can narrow down to specific operation that causes this probably there will be no need in dumps.

    • This reply was modified 6 years, 12 months ago by Fedor Losev.
    #544557 Reply

    Fedor Losev
    Participant

    Hi, this still happens in CI9 final. I think I found the cause.

    Symptoms:
    UI actions not responding (no errors in log)
    In Progress view some of invoked actions just aggregate and wait
    Many tern tasks waiting before other tasks
    Stopping all tasks in progress view does not help

    Progress screenshots and stack trace dump are attached.

    But after killing angular server and closing the terminal window, all waiting tasks rush to execute and UI returns to operate normally. May be auto-recompile hangs and somehow blocks the UI action queue.

    • This reply was modified 6 years, 11 months ago by Fedor Losev.
    Attachments:
    You must be logged in to view attached files.
    #544563 Reply

    Brian Fernandes
    Moderator

    Fedor,

    That helps. Do you have a lot of JavaScript resources in your workspace that you actually work with? Or are they just a byproduct of your TypeScript files and you don’t edit them much?

    There’s a setting to turn off Tern, if you go to Window > Preferences > JavaScript > Performance, there is a “Turn off Tern” setting. Of course, this will disable much of our JavaScript support, but perhaps you don’t actually need it? Could you try this and let us know if performance improves over the next few days?

    Thanks!

    #544567 Reply

    Fedor Losev
    Participant

    Not a lot, may be ~10 js standalone files and they are changed rarely (so the support for JS is needed but I can turn it on when needed only). Others are byproduct.

    I don’t think there is correlation between the time I edit js and the hang issue.

    May be setting Content scope to Current file is better option?

    May it be it includes node_modules somehow, despite being marked as derived?

    #544568 Reply

    Brian Fernandes
    Moderator

    Fedor,

    Yes, you could try some of the other settings too, like Content scope – though I was trying a “big hammer” approach of just turning it off entirely and seeing if that made a difference. Clearly with the small number of JS resources you have, it should not have been a problem already, so there could be something wrong with the scoping logic or some other bug with the JS resource handling.

    I don’t think we have a problem with node_modules because with the number of JS resources there, we’d be seeing a much bigger performance issue – but we’ll check, of course. What about the JS files generated from your TS, what folder do they go into, and is that folder marked derived?

    #544570 Reply

    Fedor Losev
    Participant

    I will try to turn it off, but I’m not completely convinced it is tern issue. May it be just blocked by another issue like other tasks were? Does closing server terminal affect tern tasks, since closing it released all queue including tern?

    I’m not 100% sure where compiled JS go, according to https://github.com/angular/angular-cli/issues/3839 in server they go into memory and on WebClipse validating builds you probably know better if and where they go (for sure not in regular project folders)

    #544644 Reply

    Fedor Losev
    Participant

    More info:

    1) It happened one time when tern scope was set to Current File. There were NO pending tasks in progress view except script resource sync (sleeping) which is probably not related as it also frequently appears like that when there is no any problem.

    2) It happened now when tern was OFF. There was “Synchronizing script resources with Tern server” waiting task despite tern being turned off (screenshot attached).

    I still think it is probably not related to tern. Something (related to angular server, see below) just blocks all tasks queue and tern happens there just by coincidence (though synchronizing when tern is OFF is probably another bug).

    Note the following observations:

    – This happens when Angular server is left running for long time.
    – When it happens, the server entry in Servers displays as [Stopped] (but the server process is running).
    – Terminal for ng serve does not show recompilation through page is recompiled and reloaded on changes and does not respond to keyboard e.g. CTRL+C
    – Closing ng serve terminal window does not solve the problem
    – Stopping hanging task in Eclipse + killing server process from task manager releases other waiting tasks and UI returns to operate normally.

    This time there was also slightly different behavior after killing server and UI restored (without restart) which may shed more light on the problem:

    – Starting the server shows webpack: Compiled successfully, after that UI actions don’t work again
    – The entry in Servers shows as [Stopped] but in menu Stop server is enabled and Start server is disabled
    – Pressing stop does nothing immediately
    – After 20-30 seconds message like “Stopping server has failed” pops, after that UI returns to work normally
    – The entry in Servers shows as [Stopped] but still in menu Stop server is enabled and Start server is disabled
    – After IDE restart everything works as usual

    Attachments:
    You must be logged in to view attached files.
    #544661 Reply

    Brian Fernandes
    Moderator

    Fedor,

    Thank you for the detailed notes provided. I was asking about the compiled file location earlier in case you had something custom specified.

    Yes, the performance problem may not be related to Tern, though clearly from your experience, something is going awry in the Tern behavior as well.

    I won’t comment on your other observations right now – every bit of detail you have provided from the screenshots to the thread dumps is invaluable, and we’re taking a detailed look at this issue at high priority. Hopefully all the info you’ve provided will help us fix it.

    Just one additional request – can you share your workspace error log with us? It’s at [workspace_location]/.metadata/.log – any synchronization errors or parser failures should make their way to the log as well.

    Thanks!

    #544801 Reply

    Fedor Losev
    Participant

    IDE left open from yesturday, today:

    – Search operation hangs: no other tasks in progress, angular server is running and shows in Servers as running but with stop disabled
    – Ctrl+C in [ng-serve] tab Terminal+, no reaction from terminal but server process is stopped, server still shows in Servers as running and search operation still hangs
    – Close [ng-serve] tab in Terminal+, search task is released but invoking the search again hangs
    – I notice there is additional tab in Terminal+ which is not [ng serve] but named as the project in Servers. On this tab close search operation is released and doesn’t hang anymore, everything seems to work fine after closing all terminals.

    The newest message in the log is since yesterday time when everything still worked, far before I left after midnight. New messages came only after IDE restart (may be log facility hangs too at some point?). So I guess there is nothing useful. In yesterday messages I also don’t see any message that doesn’t happen on regular operations when everything works. I’ll look at the log when it happens again.

    Note on 7 Dec there are some genuitec related errors, I think at this time there was something wrong with autocomplete or compilation and I had to restart the IDE but don’t remember all details now.

    Not sure if it is relevant, but note I run on JRE 1.8.60, not Java 7.

    There is also some rare problem when after huge changes especially components delete and following compile errors, everything compiles after error fix, webpack reloads and shows the page but short thereafter the page is replaced by old compilation error page (I guess it is ng / webpack bug and I think there is another message on the forum I wrote some time before). I think this happens most frequently (but not only) when you delete component, webpack shows error page “can’t read file” and after fix it replaces working page by old error page moment after reload. Only server restart helps.

    Attachments:
    You must be logged in to view attached files.
    #545029 Reply

    Fedor Losev
    Participant

    One more stack trace when Eclipse is stuck in saving workspace dialog after close.

    Attachments:
    You must be logged in to view attached files.
    #545086 Reply

    Brian Fernandes
    Moderator

    Fedor,

    Thank you for the continued details – our team is still investigating.

    I know a few of the issues here are related to the Node process that is serving your project going awry – perhaps consuming too much memory, or running out of memory etc., such that you have to kill it to restore functionality.

    a) Can you tell me what version of Node and NPM you are serving your project with?
    b) Can we try to modify the amount of memory that the Node process has to see if it improves the situation?

    To do this:
    1) Go Window > Preferences > JavaScript > Runtimes
    2) Select the version of Node you are working with and choose Edit
    3) In the Arguments field, add --max_old_space_size=4096 (this number is in megabytes, I think by default it would be 1.5 GB, you could certainly try a lower value)
    4) Click Finish and Apply to apply these changes.
    5) Now go ahead and serve your project as before.

    Disclaimer: I haven’t proved that the argument added on that preference page actually affects the node process started by ng serve – however, am suggesting this in the interest of saving some time. If the setting does work as expected, we might see some immediate benefits. I’ll try to run some tests and confirm that this works as it should.

Viewing 15 posts - 1 through 15 (of 21 total)
Reply To: CI9 prelease sporadic UI problem

This topic is marked as closed to new replies, however your posting capabilities still allow you to do so.

You must be logged in to post in the forum log in