diff options
author | Ryan Bigg <radarlistener@gmail.com> | 2012-03-07 07:36:08 -0800 |
---|---|---|
committer | Ryan Bigg <radarlistener@gmail.com> | 2012-03-11 16:19:09 -0700 |
commit | 4daef7427b3d63bdda4ac99df25fb3de32dfe9cd (patch) | |
tree | ed89476d06747c6faf1770b1fc89c445cf68e9d9 | |
parent | ddbea9474e20a40e80110944c1e3493ba0efe572 (diff) | |
download | rails-4daef7427b3d63bdda4ac99df25fb3de32dfe9cd.tar.gz rails-4daef7427b3d63bdda4ac99df25fb3de32dfe9cd.tar.bz2 rails-4daef7427b3d63bdda4ac99df25fb3de32dfe9cd.zip |
[instrumentation guide] Cover receive.action_mailer event
-rw-r--r-- | railties/guides/source/active_support_instrumentation.textile | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/railties/guides/source/active_support_instrumentation.textile b/railties/guides/source/active_support_instrumentation.textile index f9452400ad..79901a619c 100644 --- a/railties/guides/source/active_support_instrumentation.textile +++ b/railties/guides/source/active_support_instrumentation.textile @@ -21,8 +21,35 @@ You are even able to create your own events inside your application which you ca h3. Rails framework hooks +Within the Ruby on Rails framework, there are a number of hooks provided for common events. These are detailed below. + h4. Action Mailer +h5. receive.action_mailer + +This hook is called when the +receive+ method of an +ActionMailer::Base+ class is called: + +<ruby> + class Mailer < ActionMailer::Base + def receive(mail) + + end + end +</ruby> + +The payload for this event has the following parameters related to the incoming email: + +|_.Key |_.Value| +|mailer |Name of the mailer class| +|message_id |ID of the message, generated by the Mail gem| +|subject |Subject of the mail| +|to |To address(es) of the mail| +|from |From address of the mail| +|bcc |BCC addresses of the mail| +|cc |CC addresses of the mail| +|date |Date of the mail| +|mail |The encoded form of the mail| + h4. Action Controller h4. Action View |