Hi!

I'm one of the developers hired to implement the blogs for Trygve Lie.
As he mentioned in his post, one of our requirements is to set up one
blog server for several (say 50) domains, with separate look and feel,
and separate blogs and users. One way to do this is of course to install
50 roller servers with 50 database instances. But this would require a
lot of database connections that are not shared, and a lot of extra
overhead for caching 50 different Roller servers etc. 

Instead we plan to extend Roller with an optional multi-domain mode. We
are still planning how we can accomplish this, but we now have some
ideas. One of our goals is to get our patches accepted in the official
Roller source. We want to do this because we want to give something back
to the Roller community, and we believe more companies will need this
feature. Another reason is that we don't want to maintain a separate set
of patches we need to apply to all future versions of Roller before we
put them in production. To ensure that we make the changes in a fashion
compatible with the rest of the Roller-community, we are now asking for
feedback and ideas before we start implementing changes. 

What's needed here is a way to group "rolleruser"s and "website"s in
domains so they can be controlled by domain administrators. The domain
administrator also needs to be able to control default themes and
available themes for one domain. (ie. blog.comany1.no has a default
theme with the Company1-logo at the top, blog.company2.no has a
different default theme, and the company1-theme is not available).

One way to do this might be to add some extra tables to the database
describing the domain. The table will contain name, description, domain
settings etc. When a user is added to a domain, a connection between
rolleruser and domain is created in a new table called domainuser. When
a website is added to a domain, a connection between website and domain
is created in a table called domainwebsite to show that a website is
part of that domain (ie. a user can exist in more than one domain, and
so can a website). The names of the tables are not final yet.  

The normal behavior in Roller should be left as it is now, but the
administrator is given an option to turn on multidomain-mode. When this
is enabled, the administrator can add new domains, and add an
administrator-user to that domain. Existing websites and users will
continue to exist as before under roller/page/sitename, what's new here
is a new configuration where a domain administrator can add users,
wesites and set configuration for the domain. This could be put under
roller/domain/domainname for example. This level would also have
functionality like the front page for roller, but would only contain
blogs from this domain, a planet uniqe for this domain, and optionally
the ability for a user to register for this domain only. (in the
background, the user would also be registered as a global rolleruser,
but the global site could be filtered out so this would be transparent
for users). 

To make the sentral server invisible to the end user, the URLs must be
filtered and rewritten so blog.company1.no is translated to
bigblog.no/roller/domain/company1, and blog.company1.no/blogname is
translated to bigblog.no/roller/page/blogname etc. This functionality
should be done by mod_rewrite or a UrlRewriteFilter and be kept out of
Roller, but should be possible and documented to allow others to do the
same.   

What we need now is some feedback on what mistakes we are likely to make
here, and how you would like us to proceed so we can get patches
upstream and not break your incredible application. Ideas on how to do
this would certainly help! 


--
Regards,
Henning Kulander
Systems consultant
Linpro AS - Norway's #1 Linux company


Reply via email to