Solved

How do I set up a development/debugging environment for a Java/Spring/Tomcat application on my local machine?

Posted on 2013-12-19
1
590 Views
Last Modified: 2014-11-12
Hi:

I'm at the beginning stages of immersing myself into a web based project. The project is hosted on AWS running Tomcat. It's a MySQL database on the backend. The middle tier is in JAVA and utilizes the Spring Framework. The front end is series of HTML5 based screens.

I come from a heavy Microsoft Environment, so I'm used to using MSVS to build and debug applications. I would like to set up a similar scenario where a build/development environment is hosted locally on my Windows 7 box. I'd like to be able to code, build and test the application locally before pushing WAR files out to Tomcat on our AWS site.

I have to think there's a way to do this. I'm not sure if it involves extensions to Eclipse.
I have to start by saying that I'm very new to Java and a totally new to the Spring framework. The ability to step through things in a debugging environment would certainly accelerate my learning curve.

Can someone point me to straightforward tutorial or at least point me in the right direction to get started on this. Once I figure this out, we will role this environment/solution out to new developers as they join our team.

Thanks in advance for your time,
JohnB
0
Comment
Question by:jxbma
1 Comment
 
LVL 35

Accepted Solution

by:
mccarl earned 500 total points
ID: 39730808
I can see two options for you...

1) Use an all in one type of solution called "Spring Tool Suite" (http://spring.io/tools), this download also includes a modified version of Tomcat called "VMware vFabric tc server", the fact that this is different to a plain Tomcat installation (or to the installation on AWS) should not make much/any difference in real terms. STS is still based on Eclipse so it should be familar if you already have an idea of Eclipse but because this is a Spring-oriented product, there are also other little add-ons that can make Spring development a little easier.

2) If you don't want to move away from your current Eclipse environment, you can still just "install" a server environment into it for running an application on Tomcat. Firstly, just download and install to your development machine, a normal version of Tomcat that you want to use. Then, if you already have your web-app in Eclipse, you should just be able to right-click the project and then in the "Run As..." menu, there should be a "Run on Server" option. If you select that there should be an option to "Manually define a new server" near the top and then you should be able to follow the wizard, in order to point to the installation of Tomcat that you did above.



With either of the above approaches, you can start/stop this Tomcat instance from within Eclipse, as well as easily deploy your application to the server. Also, changes you make to your application get automatically published to the server so that when you have finished making a set of changes, just start the server up again to see the results. There are some possibilities of doing "hot-deployments", ie. change the code and the classes get modified while the server is still running, but I've never had too much luck with that, your mileage may vary though.


If anything above is not clear, just let us know!
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
It’s a strangely common occurrence that when you send someone their login details for a system, they can’t get in. This article will help you understand why it happens, and what you can do about it.
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.
Use Wufoo, an online form creation tool, to make powerful forms. Learn how to choose which pages of your form are visible to your users based on their inputs. The page rules feature provides you with an opportunity to create if:then statements for y…

831 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question