• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

integrate mail server to J2ee application

 
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi,

How is it possible to integrate mail server into the j2ee application. i mean the client should be able to mail using that mail server. and the address also should be changes accordingly rather than 127.0.0.9 or some some sort of ip.
can somebosy please help me out with this and als suggest which is a good mail server for windows platform
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Java can you use any mail server using the JavaMail API (which supports the SMTP, POP3 and IMAP protocols). To make a mail server the default for a particular domain is a matter of setting up DNS accordingly; that's outside the realm of Java. You need to talk to the network admin about that.

You can find any number of free and commercial email servers by googling for "windows email server".
 
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You can integrate it into your j2ee server once you have identified an external mail server.

First tell your app server about the mail server. In tomcat's META-INF/context.xml file:



Then tell your application about the JNDI resource on the app server. In web.xml:



You can then access the mail session via JNDI. Here we usually just set it up with spring injection.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic