You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by "banifou (via GitHub)" <gi...@apache.org> on 2024/09/26 15:18:33 UTC

[I] Unnecessary redeploys by "deploy on save" [netbeans]

banifou opened a new issue, #7802:
URL: https://github.com/apache/netbeans/issues/7802

   ### Apache NetBeans version
   
   Apache NetBeans 23
   
   ### What happened
   
   Working and making changes on different files and jumping from one file to another one sometimes triggers a webapp redeploy even though when no file has been saved at all.
   This is a problem because Wildfly, Tomcat and Glassfish run out of PermGen after 10 or so redeploys. 
   The webapp should only redeploy when changes has been saved. Or am I misunderstanding  this feature?
   
   ### Language / Project Type / NetBeans Component
   
   Java maven project
   
   ### How to reproduce
   
   Reproduceable with any maven webapp.
   
   ### Did this work correctly in an earlier version?
   
   No / Don't know
   
   ### Operating System
   
   ubuntu 24.04
   
   ### JDK
   
   openjdk 17
   
   ### Apache NetBeans packaging
   
   Apache NetBeans Snap Package
   
   ### Anything else
   
   _No response_
   
   ### Are you willing to submit a pull request?
   
   No


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


Re: [I] Unnecessary redeploys by "deploy on save" [netbeans]

Posted by "banifou22 (via GitHub)" <gi...@apache.org>.
banifou22 commented on issue #7802:
URL: https://github.com/apache/netbeans/issues/7802#issuecomment-2563856766

   Hi,
   any news or progress regarding this issue? Thanks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


Re: [I] Unnecessary redeploys by "deploy on save" [netbeans]

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on issue #7802:
URL: https://github.com/apache/netbeans/issues/7802#issuecomment-2563882561

   Hi @banifou22 and @banifou, now there are two of you ;)
   
   I don't think anyone is working on this. Your best chance to improve this usecase is to try to get involved yourself and figure out why deploy-on-save runs so often.
   
   The underlying compile-on-save mechanism sidelines the project build and lets NB directly compile to the output folder. This is the root cause for many other issues and essentially deprecated since no longer maintained (CoS itself is also fairly complex). Today, the project build tools like maven or gradle are responsible for all this, NB only interfaces with the tools, scans input and output etc.
   
   Also keep in mind that the second part of the fix is to run your application on java versions which don't use permgen anymore. Since anything which reduces deployments would only mitigate the issue, you will run out of memory still, just later.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


Re: [I] Unnecessary redeploys by "deploy on save" [netbeans]

Posted by "banifou (via GitHub)" <gi...@apache.org>.
banifou commented on issue #7802:
URL: https://github.com/apache/netbeans/issues/7802#issuecomment-2404631076

   Autosave and "Save files when focus is lost" are disabled.  
   When "compile on save" is uncheked than it disabled "deploy on save"! I'm not sure if it's enabled?
   
   ![Bildschirmfoto vom 2024-10-10 11-13-52](https://github.com/user-attachments/assets/2131fcaa-e70b-4f38-a5a8-a890131d17cb)
   By the way the link to "Learn more about Deploy.." is broken. Don't know where to report this.
   
   The redeploy is somehow triggered by something else when jumping from one tab to another. More investigation is required.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


Re: [I] Unnecessary redeploys by "deploy on save" [netbeans]

Posted by "banifou (via GitHub)" <gi...@apache.org>.
banifou commented on issue #7802:
URL: https://github.com/apache/netbeans/issues/7802#issuecomment-2403561031

   And under "Build -> Compile" the "compile on save" is checked.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


Re: [I] Unnecessary redeploys by "deploy on save" [netbeans]

Posted by "JoachimRohde (via GitHub)" <gi...@apache.org>.
JoachimRohde commented on issue #7802:
URL: https://github.com/apache/netbeans/issues/7802#issuecomment-2378587035

   I cannot say anything regarding your actual problem, but are your servers really running with Java <= 7? Because PermGen has been removed in JDK 8.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


Re: [I] Unnecessary redeploys by "deploy on save" [netbeans]

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on issue #7802:
URL: https://github.com/apache/netbeans/issues/7802#issuecomment-2404681796

   you are right. deploy-on-save does depend on compile-on-save. The dialog has a bug where it has DoC enabled by default without checking if CoS is toggled on. CoS is a fairly complex feature and wasn't very well maintained so we switched it off by default for new projects, the DoC checkbox was likely overlooked.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


Re: [I] Unnecessary redeploys by "deploy on save" [netbeans]

Posted by "banifou (via GitHub)" <gi...@apache.org>.
banifou commented on issue #7802:
URL: https://github.com/apache/netbeans/issues/7802#issuecomment-2643360494

   I use JDK 17! It doesn't have permgen but still get "java.lang.OutOfMemoryError". 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


Re: [I] Unnecessary redeploys by "deploy on save" [netbeans]

Posted by "banifou (via GitHub)" <gi...@apache.org>.
banifou commented on issue #7802:
URL: https://github.com/apache/netbeans/issues/7802#issuecomment-2403559661

   Never seen such a checkbox like "save files when focus is lost" or periodic autosave !
   This is what I have:
   
   ![Bildschirmfoto vom 2024-10-10 00-48-24](https://github.com/user-attachments/assets/ba7a8722-c20e-4ee6-a7a4-9adf22fba9a1)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


Re: [I] Unnecessary redeploys by "deploy on save" [netbeans]

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on issue #7802:
URL: https://github.com/apache/netbeans/issues/7802#issuecomment-2400921954

   I am a bit surprised that this works at all, since javac itself doesn't even support the 1.7 target anymore.
   
   but you are saying that:
    - you have deploy on save enabled
    - and things deploy without you saving anything?
   
   just to check the obvious: you don't have periodic autosave enabled or "save files when focus is lost"? Since this sounds like you are one checkbox away from resolving this issue ;)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


Re: [I] Unnecessary redeploys by "deploy on save" [netbeans]

Posted by "mbien (via GitHub)" <gi...@apache.org>.
mbien commented on issue #7802:
URL: https://github.com/apache/netbeans/issues/7802#issuecomment-2403572219

   autosave is a global setting in `options -> editor -> autosave` which makes NB save files periodically or on focus loss events depends on how it is configured. (default has everything disabled)
   
   project settings like deploy on save are simply hooking into any save event - auto saves included.
   
   the only anomaly is "compile on save", this setting is fairly invasive and does more than simply triggering a build target, a scary dialog should show up if you enable it (at least in maven projects, can't remember how it is implemented in ant projects - it was never implemented for gradle projects)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists


Re: [I] Unnecessary redeploys by "deploy on save" [netbeans]

Posted by "banifou (via GitHub)" <gi...@apache.org>.
banifou commented on issue #7802:
URL: https://github.com/apache/netbeans/issues/7802#issuecomment-2378675569

   That's right, I meant "out of memory". 
   "deploy on save" shouldn't redeploy until any changes has been saved. But not before.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists