Search code examples
c#.netsaas

Programming SaaS applications


I want to build a SaaS application, but I am confused at how to technically program it.

Are there any .NET based frameworks to build SaaS applications, helping in managing the different configurations.

Thank You


Solution

  • SaaS means Software As A Service

    So, any software that you can produce that, instead of selling it as a final package, you sell it as a service will go directly to that category.

    For example, you can buy a CRM Application that you can install in your computer and that's it... kind'a Office, that's a software as a product, but, you can buy a CRM application and pay every month (kind'a SalesForce).

    You as a user do not need to worry with IT infrastructure, Servers, Updates, etc ...

    You as a developer provide not a simple product to be installed but a resource to be consumed, where you will be in charge of providing hosting, updates, etc.

    That's a Software As A Service, and not As A Product.


    There are tools to ease or developing line like Patterns for SaaS, Database Migrations, Farming, etc, but essentially it's this.

    In the .NET World, and if you want to read more about this, I would strongly suggest Mike's blog post, part 1 and part 2... as well download and check the source of he's code


    A good way to start.

    Video on Multi-tenant ASP.NET MVC Projects from Rob in DDD8


    Let me talk about my story a little bit. Seeing for the first time the video above I realize that I'm currently publish to the public a multi-tenant SaaS application and I did not knew anything about SaaS specificly, I just started coding with my own logic.

    I ended up with 3 main products, an address book and a calendar (those are the real products) and an Administration (add users, set properties in a nice control panel way), and I choose to follow the ASP.NET MVC 3 road using custom domain names.

    I have in my route something like this:

    routes.MapRoute(
        "ClientRequest", "{cliurl}/{id}",
        new { cliurl = "none", controller = "ABook", action = "Index", id = "none" }
    );
    

    And in my controller I load all configuration of that user using the {cliurl} property of the URL, those names are set up by the user in the control panel, and they will ending up being:

    http://abook.domain.com/myclientname/myencodeduser
    

    for a real client domain and encode user:

    http://abook.domain.com/demo1/iHiMFrQq0AdYBR45Q2kvww
    

    plus I give them the ability of each user change it's own settings using:

    http://abook.domain.com/demo1/iHiMFrQq0AdYBR45Q2kvww/settings

    or see a log of it's actions

    http://abook.domain.com/demo1/iHiMFrQq0AdYBR45Q2kvww/about

    So, it's pretty rudimentary but I ended up having a nice solution without reading anything specific on SaaS, as I'm happy with the result, I'm just sharing the experience.