With this course, we’re going to learn the Java Struts 2 Technology, presenting a Tomcat Web solution and exploring how a Finance Management software can be designed using these resources.
In this tutorial, we’ll download all the resources needed to the project, explaining how to install all of them. Also, we’ll install Java Runtime, Eclipse and tomcat web container and see how it works. After all, we’ll take a look on the log files generated by tomcat.
Java, Apache Struts 2, Eclipse, Tomcat
Keyword: Java, Eclipse, Struts 2, Tomcat, apache,
TranscriptHello. Everybody please be welcome. Let's start right now a new Java Struts
course provided by MrBool. Java Struts it's a software provided by Apache
Software Foundation. What means Struts? Struts is a web framework, free open
source solution for creating Java web applications. At this first time
let's download all the software needed to begin our study. Take a look at
this web page. Here you'll find the official Struts web page provided by
Apache Software Foundation. Here you will find all information needed to
provide you a tool to develop Struts application. We are going to use it as
a byline to provide us all information needed. At this first time and at
this course, of course we're going to study Struts 2. All right. To run any
Java application you have to have installed on your machine a Java run time
environment or a Java development kit. You choose one of them. I'm going to
choose the Java run-time environment and I will download it. You have to
make this download. You have to install this on your machine. This is a
very simple installation, it will not have any kind of difficult imposed to
this. After that the next step is to download the Apache Tomcat.
Apache Tomcat is a web container that will provide us access to the web
application. We are going to use the version number 7. You may find your
download here to your Windows machine. We're going to install the Tomcat as
a Windows Server C. We think we will be better provided to our needs. So,
make your download. Let's run. Here you have to select your type of
install, we recommend you to use a full install. The Tomcat will install
some kind of options that may help us in the future. In this frame you find
some nice and important information that we must concern about that. The
first three information tell us to choose the option about the port to have
a server shut down port, an HTTP connection ports. This port will provides
us access to the Tomcat manager provided in a web-page . That's very
important. After that you have to choose a name for your Windows Server C.
We are going to call it STomcat 7, not the full name. You can create
shortcuts for all users here and after that you have to choose and log in
user name and a password. I'm going to set admin for user name and
password. In here the Tomcat will inform and include some roles to these
users. Some administration roles of course.
After that the program will inform the folder where the Java run-time
environment is installed, a destination folder. After that just install.
OK. You can run the Tomcat right now. All right. At this point, how can I
make an access to Tomcat? It's simple. You go to your web browser and you
type, local host at the port 8080, and you got it. If are seeing these,
you've successfully installed the Tomcat. Congratulations. This is the main
web page from Tomcat. All the management page is provided by these link
called manager APP. Here you type your user name and your password. OK.
Here you are. Here you have all the options and all the applications
installed and deployed to the Tomcat web application manager. Here you'll
find it. You have documentation page providing information about the Tomcat
software. You have some kind of examples, servelets and JSP. OK. You have
the manager that right at this page we are reviewing now. Below this
section of the document you'll find deploy option that here you can deploy,
upload our word file that you can deploy directly to Tomcat. At this point
the next step is to download the Eclipse downloads web-page, right here,
and download Eclipse for Java either loopers. You must choose your version
between 32 to 64 bit and make a download. The download provided by Eclipse
is very simple to install. You will receive a zip package. You just have to
unzip all the contents in a folder on your computer and momentarily Eclipse
will be installed.
The next step is to download Struts 2 components to run Struts application.
As we talk earlier the Struts is a framework a nice way to provide web
applications. Let's download the components needed to make it. You have
several options to download in this web-page for downloads. We are going to
use just the essential dependence because we don't need more then these to
start developing our Struts application. Of course, after this first moment
you can download the full distribution but right now we are going to use
just the essential dependences to provide our main applications. At this
moment you only have to download this main content. You are going to find
some libraries inside the zip file. You just have to unzip all them on a
folder and wait. That we are going to use a lot in the future. This is the
main structure provided by the zip file. You have some text files, and you
have a folder named Leeb. That contains a lot of jar files. We are going to
use a bunch of them to develop our applications. After seeing these you
just have to open your Eclipse 2, and you're going to take a look for some
options here. First of all go to minute window, preference, and you have a
Tomcat options. You must select the version 7. You must set the folder
where Tomcat is installed. You'll find here. Tomcat 7. Here you go. After
that you have some options that we are not going to set right now. The run-
time settings, goes here. At this time, we'll have to set the manager
First of all you have to type here your user name and password that you
previously selected. Click and apply. OK. Right. Let's take a nice look on
this folder where Tomcat is installed. You have here a folder named Leeb.
What do you find here? You find several files that compose the Tomcat
environment. After that you have a logs folder. Here you find several files
separated by date and type. This is the main source to find anything that
goes wrong or right in your application. This is the full login system of
Tomcat. Let's take a look at one of these file. So when something goes
wrong on your application you have to come to this folder logs, and take a
look at these files to see what is going on. Which one is the better file
to consitute in each occasion? Well, it depends, it depends on what
happened in that moment. We are going to see several cases that we're going
to come here to consult all these files. We're going to see it. In the next
class we are going to explore the Eclipse environment too.
We are going to create a simple application and they're going to deploy on
Tomcat. You're going to see all this. OK? That's all for now. Thank you
very much. See you later.