16

I am a newbie to IntelliJ IDEA. I was trying to deploy a web app in Tomcat.

It failed to deploy and i was not able to see any errors in the log console.

After much searching, I was able to find out the log files at ~/Library/Caches/IntelliJIdea10/tomcat/_p1/logs/ folder.

There were a bunch of log files here and one of the files contained the error. I then could solve the issue and proceed.

I was a user of eclipse and this error would have come directly in the log console in eclipse. However this is not the case in IntelliJ IDEA. Can somebody please explain what I am missing here?

Also, it would be nice if somebody could point out how the integration with Tomcat is done in IDEA (for better understanding). Note: I am using IntelliJ IDEA 10.5.2 Ultimate edition on Mac OS 10.6.8.

CrazyCoder
  • 389,263
  • 172
  • 990
  • 904
Pipalayan Nayak
  • 937
  • 2
  • 8
  • 13
  • 1
    possible duplicate of [Where is my app placed when deploying to Tomcat?](http://stackoverflow.com/questions/10461702/where-is-my-app-placed-when-deploying-to-tomcat) – Sled Aug 20 '14 at 21:42

3 Answers3

15

IntelliJ IDEA instructs Tomcat to use temporary directory as CATALINA_BASE where it places context configuration with the Artifact path from your project settings, it doesn't copy your web application into webapps directory.

In the Tomcat Run/Debug configuration there is Logs tab where you can specify custom logs to show in IDEA console, it should work out of the box, but probably you have customized logging in Tomcat configuration or in the application itself. Or maybe Tomcat 7 logging configuration is different and doesn't work with IDEA in which case you should submit a bug.

CrazyCoder
  • 389,263
  • 172
  • 990
  • 904
  • thanks for the info on IntelliJ Idea tomcat integration. Will look deepr into the logging issue and raise a bug ticket – Pipalayan Nayak Oct 10 '11 at 05:35
  • And I believe there is no deployment descriptor XML as you might see in some standalone deployments. All the app configuration values are specified in the shell command. Run `ps aux | grep -i catalina` and you'll see exactly where the artifacts are. – Sridhar Sarnobat Jun 18 '19 at 22:42
2

Here's some info for Windows users....if you check the boxes for 'Show console when stdout/stderr change', you may find that the Output tab does not show up even if stdout/stderr change.

For me, this was due to directory structure for the project containing spaces.

When I renamed the directory structure so that it did not contain spaces the Output tab showed up.

Paul
  • 21
  • 1
1

Found solution here: Cannot deploy project to tomcat inside intellij IDEA 14. Applications Context was incorrect.

Run/Debug Configurations -> Deployment tab -> Applications Context

Community
  • 1
  • 1
bausov
  • 387
  • 3
  • 12