Return-Path: Delivered-To: apmail-tomcat-dev-archive@www.apache.org Received: (qmail 30330 invoked from network); 19 Nov 2010 18:50:27 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 19 Nov 2010 18:50:27 -0000 Received: (qmail 58520 invoked by uid 500); 19 Nov 2010 18:50:57 -0000 Delivered-To: apmail-tomcat-dev-archive@tomcat.apache.org Received: (qmail 58444 invoked by uid 500); 19 Nov 2010 18:50:57 -0000 Mailing-List: contact dev-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Developers List" Delivered-To: mailing list dev@tomcat.apache.org Received: (qmail 58435 invoked by uid 99); 19 Nov 2010 18:50:57 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 19 Nov 2010 18:50:57 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 19 Nov 2010 18:50:55 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 81CE423889E7; Fri, 19 Nov 2010 18:49:40 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1036976 - in /tomcat/tc6.0.x/trunk/webapps/docs: changelog.xml jndi-resources-howto.xml Date: Fri, 19 Nov 2010 18:49:40 -0000 To: dev@tomcat.apache.org From: markt@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20101119184940.81CE423889E7@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: markt Date: Fri Nov 19 18:49:40 2010 New Revision: 1036976 URL: http://svn.apache.org/viewvc?rev=1036976&view=rev Log: Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=50303 Update JavaMail and JAF download locations JAF is included in Java SE 6 Modified: tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml tomcat/tc6.0.x/trunk/webapps/docs/jndi-resources-howto.xml Modified: tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml?rev=1036976&r1=1036975&r2=1036976&view=diff ============================================================================== --- tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml (original) +++ tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml Fri Nov 19 18:49:40 2010 @@ -308,6 +308,10 @@ must be removed from all users and the new admin-gui and admin-script roles used instead. (markt) + + 50303: Update JNDI how-to to reflect new JavaMail and JAF + download locations and that JAF is now included in Java SE 6. (markt) + Modified: tomcat/tc6.0.x/trunk/webapps/docs/jndi-resources-howto.xml URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/webapps/docs/jndi-resources-howto.xml?rev=1036976&r1=1036975&r2=1036976&view=diff ============================================================================== --- tomcat/tc6.0.x/trunk/webapps/docs/jndi-resources-howto.xml (original) +++ tomcat/tc6.0.x/trunk/webapps/docs/jndi-resources-howto.xml Fri Nov 19 18:49:40 2010 @@ -456,7 +456,7 @@ Context envCtx = (Context) initCtx.looku Session session = (Session) envCtx.lookup("mail/Session"); Message message = new MimeMessage(session); -message.setFrom(new InternetAddress(request.getParameter("from")); +message.setFrom(new InternetAddress(request.getParameter("from"))); InternetAddress to[] = new InternetAddress[1]; to[0] = new InternetAddress(request.getParameter("to")); message.setRecipients(Message.RecipientType.TO, to); @@ -494,19 +494,20 @@ Transport.send(message);

4. Install the JavaMail libraries

-

+

Download the JavaMail API. The JavaMail API requires the Java Activation - Framework (JAF) API as well. The Java Activation Framework can be downloaded - from Sun's site. + Framework (JAF) API as well. The Java Activation Framework is included in + Java SE 6 onwards. Java SE 5 users can download the latest version, + + JAF 1.1.1.

-

This download includes 2 vital libraries for the configuration; - activation.jar and mail.jar. Unpackage both distributions and place - them into $CATALINA_HOME/lib so that they are available to - Tomcat during the initialization of the mail Session Resource. - Note: placing these jars in both $CATALINA_HOME/lib and a - web application's lib folder will cause an error, so ensure you have - them in the $CATALINA_HOME/lib location only. +

Unpackage the distribution(s) and place mail.jar (and activation.jar if + required) into $CATALINA_HOME/lib so the JAR(s) is(are) available to Tomcat + during the initialization of the mail Session Resource. + Note: placing jars in both $CATALINA_HOME/lib and a web + application's lib folder will cause an error, so ensure mail.jar (and + activation.jar) is(are) placed only the $CATALINA_HOME/lib location.

Example Application

--------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org For additional commands, e-mail: dev-help@tomcat.apache.org