Issue Details (XML | Word | Printable)

Key: APF-655
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Bryan Noll
Reporter: Bryan Noll
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
AppFuse

MailEngine.sendMessage method used for sending attachments does not preserve application-wide 'sender' property.

Created: 20/Feb/07 04:50 PM   Updated: 21/Feb/07 09:39 AM   Resolved: 21/Feb/07 09:39 AM
Component/s: Service Layer
Affects Version/s: 2.0-M2, 2.0-M3
Fix Version/s: 2.0-M4

File Attachments: 1. Text File MailEngine.patch (1 kB)



 Description  « Hide
There's no facility in the MailEngine.sendMessage method (javadoc that says: Convenience method for sending messages with attachments.) for maintaining that the sender/from attribute is consistent with what is specified in mail.properties.

I propose that the method signature has 'String sender' added to it. This makes sense to me, because the caller of this method most likely has access to the 'mailMessage' bean from the Spring app context, which can be used to get the from address.

Bryan Noll made changes - 20/Feb/07 04:51 PM
Field Original Value New Value
Status Open [ 1 ] In Progress [ 3 ]
Bryan Noll added a comment - 20/Feb/07 06:38 PM
The code as it is (before this patch) does the following. If using the method in this class that sends mail with an attachment, the 'from' address is...

bnoll@baitshop

...where bnoll is my username and baitshop is my hostname.

Obviously not a real email address, just something it grocked from the environment. This patch makes that 'from' address be whatever was set in the mail.properties file.

Bryan Noll made changes - 20/Feb/07 06:38 PM
Attachment MailEngine.patch [ 10287 ]
2507 by  Bryan Noll (1 file)
21/Feb/07 09:20 AM (41 months, 18 days ago)
2508 by  Bryan Noll (3 files)
21/Feb/07 09:38 AM (41 months, 18 days ago)
Bryan Noll added a comment - 21/Feb/07 09:39 AM
Checked in fix and tests to support. See MailEngineTest.java in the services module.

Bryan Noll made changes - 21/Feb/07 09:39 AM
Resolution Fixed [ 1 ]
Status In Progress [ 3 ] Resolved [ 5 ]
Bryan Noll added a comment - 21/Feb/07 09:39 AM
closing

Bryan Noll made changes - 21/Feb/07 09:39 AM
Status Resolved [ 5 ] Closed [ 6 ]