Setting Up a JavaMail Resource on the Sun Java System Web Server

See Also

The JavaMail API is a set of abstract APIs that model a mail system. The API provides a platform-independent and protocol-independent framework to build mail and messaging applications. The JavaMail API provides facilities for reading and sending email. Service providers implement particular protocols.

The JavaMail API is implemented as a Java platform optional package and is also available as part of the J2EE platform.

To create a JavaMail resource:

  1. Ensure the Sun Java System Web Server is running.
  2. In the Projects window, select your project's root node to make it the active node and choose File > New File (Ctrl-N).
  3. In the Categories list, select Sun Web Server 7.0 Resources, and in the File Types list, select JavaMail Resource, then click Next.
  4. In the General Attributes page, in the General area, do the following:
    1. (required) Enter a unique JNDI name for the resource.
      • When you register the resource with the server, if a resource already exists with the name you enter here, the existing resource will be updated with the attributes and properties of the resource you are registering.
    2. (required) In the Mail Host field, enter the DNS name of the default mail server.
    3. (required) In the Default User field, enter the user name to use when connecting to the mail server.
    4. (required) In the Default Return Address field, enter the email address of the default user, in the form username@host.domain.
    5. Enable or disable the resource by choosing true or false.
    6. Enter a description.
  5. In the Advanced area, change the field values only if the Sun Java System Web Server's mail provider has been reconfigured to use a nondefault store or transport protocol.
  6. Click Finish.
  7. Register the resource with the Sun Java System Web Server.
See Also

Copyright © 2006 Sun Microsystems, Inc. All rights reserved.
Legal Notices