```ruby
  rescue_from 'MyAppError::Base' do |exception|
    render :xml => exception, :status => 500
  end
```