Remote ActiveRecord relation (over network)


I have a has and belongs to many relation between User and Article
models, and I would like to link them even if an article if not hosted
on the same database then a user.

For example, If an article exists at and a
user exists at, If would like to be able to do
from web interface or web interface this
kind of query: a_user.articles (or an_article.users).

I think this can be possible adding a field like "url" in users and
articles tables. But I don't know how to process for ActiveRecord. My
Article model looks like this:

class Article < ActiveRecord::Base
  has_and_belongs_to_many :users

Is there yet some example of project using this kind of relation over

Many thanks