Java Reference
In-Depth Information
Chapter 6. Communicating
External Systems
In this chapter, we are going to add the possibility to communicate with different sys-
tems in our application. Technically, we will resolve a systems integration problem.
System integration problems include several cases: two applications that exchange
data synchronously or asynchronously, an application that accesses information
provided by another, an application that executes processes implemented in another,
and so on. Given the number of solutions that exist today, it is necessary to know
which one to choose depending on the problem, hence the importance of this chapter.
At the end of this chapter, you will be able to choose an integration solution and have
an overview of the changes made in the following APIs:
• JavaMail
• Java EE connector architecture
• Java message service
• JAX-RS: Java API for RESTful Web Services
The JavaMail 1.5 Specification was developed under JSR 919. This section just gives
you an overview of improvements in the API. The complete document specification
(for more information) can be downloaded from
typrocess/mrel/jsr919/index2.html .
Sending e-mails in Java
The expansion of the Internet has greatly facilitated communication across the world
through electronic messages (e-mail). Today, people at the ends of the earth can ex-
change information in a very short time. In order for this to be done, there must be a
mail server for storage of data exchanged and clients (for example, Outlook) for send-
ing and retrieving data. Communication between these elements requires different
types of protocols, for example, SMTP ( Simple Mail Transport Protocol ) for sending
mails, POP 3 ( Post Office Protocol ) for receiving mails, IMAP ( Internet Message
Access Protocol ) for receiving e-mails. This multitude of protocols can pose a prob-
lem to the developer.
Search WWH ::

Custom Search