[Building Sakai] EmailService patch
Adrian Fish
a.fish at lancaster.ac.uk
Tue Aug 11 09:00:38 PDT 2009
Hi All,
I've attached an svn diff file for Sakai 2.5.x's email service. This
patch adds a set of attributes to the BasicEmailService class. These are:
m_smtpUser
m_smtpPassword
m_smtpUseSSL
m_smtpDebug
These can be set from sakai.properties, like this:
smtpUser at org.sakaiproject.email.api.EmailService=<SMTP_USER>
smtpPassword at org.sakaiproject.email.api.EmailService=<SMTP_PASSWORD>
smtpUseSSL at org.sakaiproject.email.api.EmailService=true
smtpDebug at org.sakaiproject.email.api.EmailService=true
Two methods in the class have changed, sendMail and sendToUsers, the
changes involving setting up the Session properties to use
authentication and perhaps SSL.
To use this patch against 2.5.x you need to remove old versions of
mail.jar (in my case it was mail-1.3.1.jar) and make sure that 1.4.2
gets placed in shared by maven.
I've tested this against gmail using authentication and SSL, and it
works. What I've not tested is that Digests still work okay, but they
should as BaseDigestService uses the send, and consequently the sendMail
method which I've patched.
To apply it, cd into your 2.5.x SAKAI_SRC/email directory, copy
email.diff in, and run this:
patch -p0 < email.diff
You should hopefully get some output like this:
patching file email-shared-deploy/pom.xml
patching file email-impl/.classpath
patching file
email-impl/impl/src/java/org/sakaiproject/email/impl/BasicEmailService.java
patching file email-impl/impl/pom.xml
patching file email-api/.classpath
patching file email-api/api/pom.xml
Any problems, drop me a line.
Cheers,
Adrian.
--
==================================
Adrian Fish
Software Engineer
Centre for e-Science
Bowland Tower South C Floor
Lancaster University
Lancaster
LA1 4YW
email: a.fish at lancaster.ac.uk
http://confluence.sakaiproject.org/display/YAFT/Yaft
http://confluence.sakaiproject.org/display/BLOG/Home
http://confluence.sakaiproject.org/display/AGORA/Home
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: email.diff
Url: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20090811/6dfab96b/attachment.pl
-------------- next part --------------
A non-text attachment was scrubbed...
Name: a_fish.vcf
Type: text/x-vcard
Size: 289 bytes
Desc: not available
Url : http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20090811/6dfab96b/attachment.vcf
More information about the sakai-dev
mailing list