1

I'm trying to migrate a maven project from Eclipse to IntelliJ and would like to start/run/deploy to WebSphere portal. My problem is that Eclipse IDE allows multiple open projects and one of the projects is an EAR that deploys a war file to WebSphere portal.

Eclipse Project structure:

enter image description here

Websphere Artifact deployed:

enter image description here

So how can I achieve the same thing in IntelliJ IDE using the already installed WebSphere? I already configured successfully Websphere Portal and I can start the server but I don´t know what type of artifact I'm supposed to configure here because there's no EAR artifact because that was a project back in eclipse:

enter image description here

If I go to artifacts setting for WebSphere I can add the war file, but it is not deployed.

enter image description here enter image description here

I have googled a lot about this in IntelliJ documentation, IBM documentation but there are no concrete solutions, at least that I have the knowledge to implement. I'm a bit new to IntelliJ. Can someone share a light on this please, thx.

Henrique C.
  • 948
  • 1
  • 14
  • 36

2 Answers2

1

If it is a Maven-based project - just open and import it from the main pom.xml in IntelliJ IDEA - IDE will automatically configure project structure.

If Maven project has corresponding configuration for ear artifact - IDE will automatically create the artifact of the same ear type which then you will deploy to an application server.

If you do not configure ear in Maven, you can create one manually, see examples in documentation.

Andrey
  • 15,144
  • 25
  • 91
  • 187
  • I managed to create the artifact but on deploy i got a alot of errors. I'm going to give up. Because WAS is outdated regarding new tecs. Since we are switching from IBM products to opensource ones, its not worth the time. Thanks anyway. – Henrique C. Sep 02 '19 at 08:44
0

The name of your artifact is important, even if deployed as an exploded-archive. The file (archive) or directory (exploded) must end with .ear, .war or .jar. The default name set by Intellij may not work.

myProject_ear/ is wrong
myProject.ear/ is correct

The deployment system of your application server is likely configured to only deploy files or directories ending with the correct file-type. This is especially true if the server is using the file scanner to detect modules to deploy or un-deploy.

ScrambledRK
  • 334
  • 1
  • 4