Showing posts with label Intellij. Show all posts
Showing posts with label Intellij. Show all posts

Thursday, 5 June 2025

Intellij: Use local module instead of maven dependency on JBoss

 Intellij 2025.1.1.1


Sometimes you want to use a dependency from your project workspace when running a server, in my case an old JBoss.

Unfortunately the JBoss does not get this right out of the box , so I made this change:

- right click on the JBoss in the Services tab

- Edit Configuration

- Deployment tab

- Edit artifact (in my case the ear:exploded)

- In the Output Layout mark the .war entry

- press the + element

- Choose Module Output

- Choose the module you want to be used


This way I got my JBoss running with the local module


Addendum:

Sometimes this stops working, unload and load seems to work most of the time to fix it




Monday, 12 May 2025

Intellij: Disable "Flip comparison" tipp for null checks

IntelliJ IDEA 2025.1.1.1 (Ultimate Edition)

Since a short amount of time IntelliJ wants me to change something like "x != null" to "null != x", because it likes the constant on the left side and null seems to be a constant for IntelliJ.

I really don't think this is something I should pay attention to and I wanted this new behavior gone in my IDE.

To disable this: Settings > Editor > Inspections > Java > Code style issues > Constant on wrong side of comparison




Tuesday, 15 October 2024

Updating Maven SNAPSHOT dependencies in Intellij

 Intellij 2024.2.3 (Ultimate Editon)


Sometimes updating SNAPSHOT dependencies in big projects just does not work. When something is changed in one workspace and a maven clean install is done, it can be  hard to get this in another workspace as updated dependency, at least in my experience.

What worked for me was the Maven Helper Plugin, where you get a "Dependency Analyzer" Tab for the pom file. There is a button "Reimport", which works fine to get the wanted updates for the SNAPSHOT dependencies.





Monday, 24 June 2024