IntelliJ 2019.1 Ultimate not redeploying changes - intellij-idea

I have a java/jsp app running websphere 8.5.5.5. When I change code, the code does not appear upon redeploying the code. I've searched the web and have tried hot-swapping, tried deleting old copies of the ear in the target folder, tried removing the ear artifact and re-adding it, tried the exploded and non-exploded artifact settings, and otherwise pretty much gone thru all the IntelliJ configuration settings. I've located all copies of the ear that keeps getting deployed (that's not found in the target folder) and renamed the folders they sit in, stopped/re-started IntelliJ but nothing affects the problem. it I'm at a total loss.
I need new/fresh ideas.

I finally 'fingered' it out. Here's what I did-
In RAD, I started the server and opened the admin console. Navigate to where the EAR is defined and change it to point to the IntelliJ target folder (where IntelliJ deposits the new EAR each time you start the server from within IntelliJ). Save that setting.
In RAD, right-click on the server (in the server console tab) and select 'Add and Remove'. Select your app's current EAR in the configured frame and click the '< Remove' button.
After doing that, I was finally able to make a code change in IntelliJ and simply select to run my configured websphere. My code changes now appear.
The thing I did NOT try was not doing step 1 but only doing step 2. It's important enough for me that it's working. If you try just doing step 2 and it does work, then let us know - anything to simplify the process.
Enjoy!

Related

IntelliJ 2017.1.4 - Refusing to open terminal window

I recently downloaded the latest version of IntelliJ Ultimate (at this time, it is 2017.1.4) for work.
For some reason, I cannot get it to open a new terminal window. When clicking the plus button here:
...nothing happens. Additionally, nothing shows up in the event log. I restarted IntelliJ, my computer, and did the "invalidate caches and restart" option.
Any ideas? Is there a log file I can look at?
It could be a known issue that is already fixed in 2017.2.
Another possible case is that the native terminal library fails to initialize on your system (check idea.log for exceptions). This can be caused by an antivirus or a corrupted IDE installation.
Thanks to #CrazyCoder for reminding me to check idea.log - the native terminal library, as well as other plugins, failed to initialize.
The root cause of the issue is that at my workplace, there is a security restriction to not run any executable that exists outside of C:\Program Files. As a result, IntelliJ cannot run certain plugins, jars, etc. that exist outside of that location, because it will attempt to execute them from your user directory.
To fix this, in IntelliJ, go to Help > Edit Custom Properties and point the config and system path to a known path where you can run executables, like so:
# custom IntelliJ IDEA properties
idea.config.path=C:\\Program Files\\JetBrains\\.IntelliJIdea2017.2\\config
idea.system.path=C:\\Program Files\\JetBrains\\.IntelliJIdea2017.2\\system
You will need to make sure to copy the contents of both directories to the new location. Hopefully this helps anyone else who runs into this issue.

Where is the war file built in Intellij IDEA, located?

I'm using IntelliJ IDEA and I'm building and deploying the web-application project every time I'm running it. All of this happens magically within IntelliJ IDEA.
However, now I'm supposed to manually deploy it on a test server's wildfly, so I need an artifact file (WAR or EAR) to drop in the standalone/deployments directory on the test server's running WildFly10.
I can't for the life of me find where IntelliJ Idea exports the WAR / EAR artifacts so I could copy paste it to the said directory on the test server. Any help is appreciated.
Please follow the steps :
Click on Edit Configurations.
Click on Deployment and add your artifact.
Apply these changes.
You can see a Build Artifacts under Build.
Click on Build Artifacts and it will create a war/jar to the respective folder.
If I'm wrong somewhere let me know.

Intellij IDEA - JavaFX packager : access denied

I'm trying to generate an artifact of my JavaFX application using Intellij but for some reason I always end up having JavaFX packager throwing an access denied error on my output directory.
Generating a simple jar works fine though.
I'm using it on Windows 8.1 with Java 8.
I had the same problem. I kind of solved it:
by ticking the "Build on make" box in the Project Structur Dialog
starting a Run of my Java App in Intellij Idea
Now the executable jar magically appeared in my build folder. God knows why.
I had this problem and solved it by deleting the Artifact from IntellIJ, then deleting the "out/artifact" previously created folder where it tried to build my jar and finally re created an artifact from scratch. For no specific reason it now worked.
I have encountered the same problem recently. I checked the permissions of the directory and can read and write. Later I deleted the artifact and re-created a new one to solve the problem. I hope to help people who have encountered this problem.
I had this problem. I ran into it because When I added artifact with + button in Project Settings->Artifacts, I selected JAR artifact , and change JAR to JavaFx Application from type drop down box on right side pane. Later, I removed this artifact and pressed + button, then selected JavaFx Application from drop down list, then it was builded successfully. My JDK version is 8.
When I call JavaVXPacker from the command line I get the following:
C:\Users\Ingo>javafxpackager -help
javafxpackager.exe has been renamed javapackager.exe.
The original file may be removed in a future release in lieu of javapackager.
Please update your scripts.
...
...
So I guess IntelliJ has to update it's script to re-enable the feature???
(using Windows 10 and JDK Liberica 15+36)
Go to File > Project Structure
Click on Artifacts on the left panel.
Thereafter click on the plus icon to add a Jar From modules with dependencies…
A pop-up will be shown and there you would have to select for the startup class of your project.
Click on OK twice to save the changes.
Lastly go to Build > Build Artifacts... And select build action.
Now your jar will be generated in the out folder of your project.
For a more details guide, please refer to this post

IntelliJ & Wildfly - hot deploy webapp

I am using IntelliJ (14.0.3) and Wildfly (8).
When I recompile my Java classes, hot swapping is easy and everything works just fine. However, my HTML, JS and CSS files will not hot swap for me. I am sure it is just a configuration issue and was hoping for some help.
My HTML data is in:
<root>/<war_module>/src/main/webapp
My run/debug is setup for:
Before launch: Make, Build Artifacts
Make
Build 'mymodule:war' artifact
I had the exact same problem, this is how it worked for me:
After configuring your JBoss server (Wildfly), setup an artifact of type exploded, in my case I selected Web Application: Exploded, and then in the Output directory add .war to the end of the name.
In case you need a .ear, simply select JavaEE Application: exploded instead, but anyways always remember to add manually the extension.
After setting this artifact to work with your Application Server, in the edit configurations of your Wildfly server select the option Update resources in the list of options in the section On frame deactivation.
So every time you modify and save static content, it will update these changes as soon as you focus something else outside the IDE, like the browser.

Using Netbeans to configure context-root for JBoss

I have a Spring application that is being deployed to JBoss 4.2. I can manually edit the generated WAR file and alter the jboss-web.xml file to set the context-root value and that works perfectly well. I would like to be able to do the samething via netbeans (6.9.1), but I have been unable to locate where to make the adjustment. I've tried tweaking the project's properties and setting the Context Path value. When I Run the application that value is reset to the Project's name. I've located the jboss-web.xml file in the project and changed it there, also reset upon run. So it appears that Netbeans is deciding that the value need to be set but I can't locate where. If it's of any use, the project also uses Maven2, but all the controls I can find for impacting context-root are geared towards EAR files instead of WAR.
Has anyone been able to do this or am I just in a world of making the change post build?
I had a similar problem once where netbeans was sometimes removing the context-root element from the glassfish-web.xml configuration. I have not been able to track it down exactly but you could try to remove the file nb-configuration.xml in the project root folder and see if that helps.