need advice for non-ActiveRecord processing

Hey Guys... need some advice on the best way to set things up. I'll
explain my scenario below:

I have a rails app that does some processing through an xmlrpc API
connection with a third party application where I store the information.
I created a plugin that loads the API classes I created which contain
all the available methods through the API. It all works great, but my
question arises from how to go about certain things when using this
setup. For example, I have a basic form on the website where all the
processing goes through the api. Right now, I have that processing code
in my controller because I have no model. But the problem occurs when I
want to do things (like validation) that are only available when I only
have an ActiveRecord model. I guess my questions are:

1. Is it possible to create a model that extends ActiveRecord::Base and
overrides the save method to go through the API connection instead of
going to the local database?

I think Activerecord is really quite tied into the sql-ness. Have a look at ? I also remember seeing (but I can't remember where) an approach where you essentially just include the module from Activerecord that provides validations into your own model (plus write a few stubs that the validations stuff expects to find).

2. If that is possible, is that still the best way to do it?

3. If not, what would be the best way going about this?

Subvert ActiveResource or look at the work that leethal has been doing on active model ( ?


Try out Validatable (
Hope that helps.


Thanks for the replies!

I'll look into your suggestions.

Also, another question I have is should I be creating a model for the
information I'm collecting on the forms?.. or is it ok to just put the
processing information into the controller?