Is GRAILS usable for multi-tenant cloud applications?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
dev
Reply | Threaded
Open this post in threaded view
|

Is GRAILS usable for multi-tenant cloud applications?

dev
There is (still) a lot of (marketing) noise about cloud-computing. But I
have the impression for enterprise grade applications, support for
multi-tenancy ( a core cloud concept and characteristic) in web
application frameworks is still sparce. Multi-tenancy has impacts on
many areas such as datasources, caching, theming, configuration
management, etc.

So does anybody here have some experience with developing a
multi-tenancy app using grails? How is data separation done? What are
the impacts on other parts of the application?

Are there any best practices?

Consumer grade applications probably can put everything in one database
and separate data by adding a tenant_id to every table and every record.
For compliance and also flexibility reasons this is not acceptable in
many enterprise grade applications, specially for industries such as
finance and health care. This means a separate DB for every tenant or at
least a separate schema per tenant is required. In my scenario a tenant
is defined as a company which may have multiple users, not treated as
tenants.

Is there any way to add hundreds of JDBC datasources to a grails
application (in case you use separate databases)? Are there any
limitations?

Or is there any way of using a shared database with a separate schema
for every tenant. This would mean placing a filter on table level. It
would mean, that domain classes needed to be mapped to different names
depending on the currently active tenant. Seems all quite challenging!
Does anybody have some experience with that??


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|

Re: Is GRAILS usable for multi-tenant cloud applications?

tomas lin
start by looking at the multi tenant plugin -
http://www.grails.org/plugin/multi-tenant - it does a lot of what you
are asking for. However, doesn't seem to work with grails 2 yet.

On Thu, Jan 3, 2013 at 8:04 AM, dev <[hidden email]> wrote:

> There is (still) a lot of (marketing) noise about cloud-computing. But I
> have the impression for enterprise grade applications, support for
> multi-tenancy ( a core cloud concept and characteristic) in web application
> frameworks is still sparce. Multi-tenancy has impacts on many areas such as
> datasources, caching, theming, configuration management, etc.
>
> So does anybody here have some experience with developing a multi-tenancy
> app using grails? How is data separation done? What are the impacts on other
> parts of the application?
>
> Are there any best practices?
>
> Consumer grade applications probably can put everything in one database and
> separate data by adding a tenant_id to every table and every record. For
> compliance and also flexibility reasons this is not acceptable in many
> enterprise grade applications, specially for industries such as finance and
> health care. This means a separate DB for every tenant or at least a
> separate schema per tenant is required. In my scenario a tenant is defined
> as a company which may have multiple users, not treated as tenants.
>
> Is there any way to add hundreds of JDBC datasources to a grails application
> (in case you use separate databases)? Are there any limitations?
>
> Or is there any way of using a shared database with a separate schema for
> every tenant. This would mean placing a filter on table level. It would
> mean, that domain classes needed to be mapped to different names depending
> on the currently active tenant. Seems all quite challenging! Does anybody
> have some experience with that??
>
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email
>
>

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|

Re: Is GRAILS usable for multi-tenant cloud applications?

Jonathan Stott-5
We have implemented our own basic form of multi-tenancy by using Hibernate filters defined on the datasource. This does the trick as we don't need to worry about the multi-tenancy aspect when doing queries (i.e. when accessed as one tenant, objects for another tenant just aren't retrievable from the database).

We operate in the health care domain and our current (basic!) solution to multi-tenancy for clients that require it (which isn't many in our experience) is a separate instance of the application with its own datasources defined. I guess you could probably dynamically create datasources (Grails 2 has multiple datasource stuff built in) with some Hibernate jiggerypokery but I don't know about this.

Jonathan


On 3 January 2013 09:28, Tomas Lin <[hidden email]> wrote:
start by looking at the multi tenant plugin -
http://www.grails.org/plugin/multi-tenant - it does a lot of what you
are asking for. However, doesn't seem to work with grails 2 yet.

On Thu, Jan 3, 2013 at 8:04 AM, dev <[hidden email]> wrote:
> There is (still) a lot of (marketing) noise about cloud-computing. But I
> have the impression for enterprise grade applications, support for
> multi-tenancy ( a core cloud concept and characteristic) in web application
> frameworks is still sparce. Multi-tenancy has impacts on many areas such as
> datasources, caching, theming, configuration management, etc.
>
> So does anybody here have some experience with developing a multi-tenancy
> app using grails? How is data separation done? What are the impacts on other
> parts of the application?
>
> Are there any best practices?
>
> Consumer grade applications probably can put everything in one database and
> separate data by adding a tenant_id to every table and every record. For
> compliance and also flexibility reasons this is not acceptable in many
> enterprise grade applications, specially for industries such as finance and
> health care. This means a separate DB for every tenant or at least a
> separate schema per tenant is required. In my scenario a tenant is defined
> as a company which may have multiple users, not treated as tenants.
>
> Is there any way to add hundreds of JDBC datasources to a grails application
> (in case you use separate databases)? Are there any limitations?
>
> Or is there any way of using a shared database with a separate schema for
> every tenant. This would mean placing a filter on table level. It would
> mean, that domain classes needed to be mapped to different names depending
> on the currently active tenant. Seems all quite challenging! Does anybody
> have some experience with that??
>
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email
>
>

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email





--
Dr Jonathan Stott
Development Team Leader

Axon Limited
"Connecting Healthcare"
2 Venture Road
University of Southampton Science Park
Southampton SO16 7NP


Tel: +44 (0)2380 11 11 99
Mobile: +44(0)7950 467087

www.axonuk.com

This message and the information contained therein is intended only for the use of the person(s) to whom it is addressed.  It may contain information that is confidential or privileged within the meaning of applicable law.  If you are not the intended recipient, please contact the sender as soon as possible and delete this message from your system; please also note that any use or disclosure of the information contained in this message (including any attachments) is strictly prohibited and may be unlawful.  This correspondence may include examples or terms based upon current assumptions with any costs shown excluding VAT and cannot be considered as a quotation, offer or commitment in any way.  Whilst reasonable precaution has been taken to minimise the risk, the contents or an attachment to this e-mail may have become corrupted during transmission or contain viruses, we cannot accept liability in this regard, and you should carry out your own virus checks.

Axon Limited is a Company registered in England and Wales number 5728502. Registered Office: Imperial House, 18-21 Kings Park Road, Southampton SO15 2AT
Reply | Threaded
Open this post in threaded view
|

Re: Is GRAILS usable for multi-tenant cloud applications?

Göran Ehrsson

We have implemented our own basic form of multi-tenancy by using Hibernate filters defined on the datasource. This does the trick as we don't need to worry about the multi-tenancy aspect when doing queries (i.e. when accessed as one tenant, objects for another tenant just aren't retrievable from the database).

That sounds very interesting. I would love to read a blog post that explains how you implemented that. ;-)

Regards

/Göran Ehrsson
Reply | Threaded
Open this post in threaded view
|

Re: Is GRAILS usable for multi-tenant cloud applications?

Kimble
This is the same approach as the multi-tenant-single-db / hibernate-hijacker plugins.

https://github.com/multi-tenant
 - Kim A. Betti
Have a nice day!
Reply | Threaded
Open this post in threaded view
|

Re: Is GRAILS usable for multi-tenant cloud applications?

lucastex
In reply to this post by dev
We are using the multi-tenant-single-db plugin by kim, and doing excellent with our single app running more than 70 clients.

[]s,



On Thu, Jan 3, 2013 at 6:04 AM, dev <[hidden email]> wrote:
There is (still) a lot of (marketing) noise about cloud-computing. But I have the impression for enterprise grade applications, support for multi-tenancy ( a core cloud concept and characteristic) in web application frameworks is still sparce. Multi-tenancy has impacts on many areas such as datasources, caching, theming, configuration management, etc.

So does anybody here have some experience with developing a multi-tenancy app using grails? How is data separation done? What are the impacts on other parts of the application?

Are there any best practices?

Consumer grade applications probably can put everything in one database and separate data by adding a tenant_id to every table and every record. For compliance and also flexibility reasons this is not acceptable in many enterprise grade applications, specially for industries such as finance and health care. This means a separate DB for every tenant or at least a separate schema per tenant is required. In my scenario a tenant is defined as a company which may have multiple users, not treated as tenants.

Is there any way to add hundreds of JDBC datasources to a grails application (in case you use separate databases)? Are there any limitations?

Or is there any way of using a shared database with a separate schema for every tenant. This would mean placing a filter on table level. It would mean, that domain classes needed to be mapped to different names depending on the currently active tenant. Seems all quite challenging! Does anybody have some experience with that??


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

   http://xircles.codehaus.org/manage_email



Reply | Threaded
Open this post in threaded view
|

Re: Is GRAILS usable for multi-tenant cloud applications?

bdrhoa
In reply to this post by dev
I used hibernate filters in 
http://maflt.org/ibidem
---------------------------
www.maf.org/rhoads
www.ontherhoads.org


On Thu, Jan 3, 2013 at 1:04 AM, dev <[hidden email]> wrote:
There is (still) a lot of (marketing) noise about cloud-computing. But I have the impression for enterprise grade applications, support for multi-tenancy ( a core cloud concept and characteristic) in web application frameworks is still sparce. Multi-tenancy has impacts on many areas such as datasources, caching, theming, configuration management, etc.

So does anybody here have some experience with developing a multi-tenancy app using grails? How is data separation done? What are the impacts on other parts of the application?

Are there any best practices?

Consumer grade applications probably can put everything in one database and separate data by adding a tenant_id to every table and every record. For compliance and also flexibility reasons this is not acceptable in many enterprise grade applications, specially for industries such as finance and health care. This means a separate DB for every tenant or at least a separate schema per tenant is required. In my scenario a tenant is defined as a company which may have multiple users, not treated as tenants.

Is there any way to add hundreds of JDBC datasources to a grails application (in case you use separate databases)? Are there any limitations?

Or is there any way of using a shared database with a separate schema for every tenant. This would mean placing a filter on table level. It would mean, that domain classes needed to be mapped to different names depending on the currently active tenant. Seems all quite challenging! Does anybody have some experience with that??


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

   http://xircles.codehaus.org/manage_email