
Time for action — downloading the JAF API
In this exercise, we're going to download the JAF API from the Sun website. The steps are almost identical to the JavaMail exercise, so you can use it as a reference.
- Open your web browser and go to http://java.sun.com/javase/technologies/desktop/javabeans/jaf/downloads/index.html. Scroll down through the page until you find the Download JavaBeans Activation Framework 1.1.1 release Download link, and click on it:
- Select I agree to the Software License Agreement and click on Continue:
- Click on the jaf-1_1_1.zip link to open the Opening jaf-1_1_1.zip dialog. Select the Save File radio button and click on the OK button:
- Once the download is complete, go to the directory where you downloaded the
jaf-1_1_1.zip
file. - Unzip the
jaf-1_1_1.zip
file and locate theactivation.jar
file inside thejaf-1_1_1
folder. Right-click on theactivation.jar
file and select Copy from the pop-up menu: - Use Windows Explorer to navigate to Tomcat's
lib
directory and paste theactivation.jar
file in there. Your Tomcat'slib
folder should now include the activation.jar and mail.jar files, as shown in the following screenshot: - You can close Windows Explorer and your web browser now.
What just happened?
Now that you have the mail.jar
and activation.jar
files inside Tomcat's lib
folder, Roller will be able to send e-mail notifications when someone leaves comments on your blog. The good part is that you don't need to know how to manipulate the Java code inside mail.jar
or activation.jar
, Roller takes care of that automatically, and you just have to blog, blog, and blog!
The MySQL JDBC driver
MySQL Connector/J 5.1
is the official JDBC driver used for connecting to MySQL databases from Java applications such as Apache Roller. In this next exercise, you'll download the Connector/J 5.1 jar
file and copy it to Tomcat's lib
folder, so that Roller can communicate with the rollerdb
database that you'll create in a later section.