title: Run function after a certain type of model is committed
body: <p>I want to run a function when instances of the <code>Post</code> model are committed.  I want to run it <em>any</em> time they are committed, so I'd rather not explicitly call the function everywhere.  How can I do this?</p>
  
  <pre><code>def notify_subscribers(post):
      """ send email to subscribers """
      ...
  
  post = Post("Hello World", "This is my first blog entry.")
  session.commit() # How to run notify_subscribers with post as argument
                   # as soon as post is committed successfully?
  
  post.title = "Hello World!!1"
  session.commit() # Run notify_subscribers once again.
  </code></pre>