|
Comments
Did you read today's front page stories & breaking news?
SYS-CON.TV
|
Product Reviews Apache James
A customizable e-mail server solution
Jan. 8, 2004 12:00 AM
In today's society, it's second nature to contact family, friends, and colleagues via e-mail. E-mail has become so integral to our daily ritual that we cannot stay away from it as we make use of personal digital assistants (PDAs) and other pervasive devices to have it readily available. How do these billions of digital messages get to users across the globe? A client/server setup is required to participate in the exchange of e-mails. It was just a few years ago that expensive server software packages were used for the typical e-mail solution. Cheaper solutions have been plagued by a lack of robustness and scalability. To the avail of shrinking corporate budgets comes the Java Apache Mail Enterprise Server (known as Apache James). Apache James is a free, open source, robust offering from the Apache Software Foundation that aims to provide enterprises with a Java-based mail server solution. James provides a Java API for developers to process e-mail services. In this article, we'll explore James and what it can offer your enterprise operation. Understanding E-Mail SMTP POP3 Getting Hold of James Firing Up James
![]() The configuration files are unpacked the first time James runs. At this point stop the server, make the necessary configuration changes, and restart the server for the modifications to take effect. A needed modification is in the config.xml file located in the <james-installdir>\apps\james\ SAR-INF directory. <servernames autodetect="true" autodetectIP="true"> Add the Domain Name Service (DNS) namespace you want served by James. For example, to have James provide e-mail services for somedomain.com, the configuration would look like the following: <servernames autodetect="true" autodetectIP="true"> Note: The assumption is that the necessary upstream configurations are in place for the DNS and Mail Exchanger (MX) records. Administering James telnet localhost 4555 Replace "localhost" in the above code with the appropriate host name or IP address. The default login/password for the Remote Manager Service is root/root. To alter this information, edit the config.xml file located in the <james-installdir>\apps\ james\SAR-INF directory. Look for the following section: <administrator_accounts> The Remote Manager Service provides the user with an easily accessible help facility through the command HELP. Now, begin administration of the e-mail server by adding user mailboxes. This is accomplished by issuing the following command: adduser [username] [password] For this exercise, we added two users, kulvir and kwang, with the same password of security. adduser kulvir security As shown in Figure 2, James will not echo the process of you creating the user.
![]() Sending and Receiving Some Mail The Mailet API For our exercise, we will enable "AddFooter", a prepackaged mailet. First, modify the "config.xml" file by adding the code in Listing 1. Let's discuss two important attributes of the mailet tag. The class attribute refers to the mailet's Java class. The match attribute refers to the matcher, a Java class that implements the Matcher API. Matchers return a collection of recipients that satisfy the defined conditions. There are a number of matchers prebundled with the James distribution. The "All" matcher returns all recipients for all messages processed by a mailet. James registers mailets during initial startup. Restart the server to enable the newly defined mailet. Send an e-mail to one of your registered accounts. The recipient should see the specified footer text added to the end of a message sent to him or her (see Figure 3).
![]() Extensibility Mailing Lists Contributing to James Conclusion Reader Feedback: Page 1 of 1
Your Feedback
Latest Cloud Developer Stories
Subscribe to the World's Most Powerful Newsletters
Subscribe to Our Rss Feeds & Get Your SYS-CON News Live!
|
SYS-CON Featured Whitepapers
Most Read This Week
Breaking Cloud Computing News
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||