Network Deployment (Distributed operating systems), v8.0 > Reference > Sets


Mail service providers and mail sessions

A mail service provider is a driver that supports mail interaction with mail servers that use a particular mail protocol. The application server includes service providers, which are also known as protocol providers, for mail protocols.

A mail provider encapsulates a collection of protocol providers. For example, the application server has a built-in mail provider that encompasses the most common protocol providers. These protocol providers are installed as the default and suffice for most applications. If we have a particular application that requires custom protocol providers, follow the steps that are outlined in the chapter on mail sessions in the JavaMail API Design Specification to install your own protocol providers.

Mail sessions are represented by the javax.mail.Session class. A mail session object authenticates users and controls access to messaging systems.

To create mail applications that are platform independent, use a resource factory reference to create a mail session. A resource factory is an object that provides access to resources in the deployed environment of a program. Resource factories use the naming conventions that are defined by the JNDI.

Ensure that every mail session is defined under a parent mail provider. Select a mail provider first and then create your new mail session.


Related


Mail: Resources for learning
JavaMail API Design Specification, V1.4 (PDF)

+

Search Tips   |   Advanced Search