A great plan Akila. Currently cartridge agent does not have an extension
point to send topology updates. As Lakmal suggested we could add a new
extension point to send member information of the cluster:

<cartridge_agent_home>/extensions/
artifacts-updated.sh  clean.sh  instance-activated.sh  instance-started.sh
mount_volumes.sh  start-servers.sh


On Tue, Apr 22, 2014 at 10:12 AM, Lakmal Warusawithana <[email protected]>wrote:

> Hi Akila,
>
> IMO, these are the exact use cases we need for mongoDB cartridges. And
> please extend cartridge agent in generic way to get other member
> information (eg. getting other mongodb nodes IPs), which we can used in any
> other cartridges. We can include this in the default cartridge agent.
>
>
> On Mon, Apr 21, 2014 at 6:08 PM, Akila Ravihansa Perera <
> [email protected]> wrote:
>
>> Hi,
>>
>> I'm working on creating a new cartridge for mongodb with auto-scaling
>> support. So far 3 use-cases have been identified so far.
>>
>> 1. mongodb scales horizontally (mongodb with sharding cluster)
>> 2. mongodb scales vertically (mongodb with replica cluster)
>> 3. mongodb replicated sharding cluster
>>
>> I have successfully deployed mongodb single node instance as a Stratos
>> cartridge by using this Puppet script [1]. However, implementing
>> auto-scaling for the mongodb cartridge requires some work.
>>
>> For a start, I'll be working on the first use-case scenario (mongodb with
>> sharding cluster). Following is a brief work plan.
>>
>> 1. mongos (query routers) and config servers will be bundled in a single
>> "mongolb" instance (mongo load balancer) which will be subscribed
>> automatically by Stratos as the load balancer.
>> 2. mongod servers (shard servers) will be bundled as "mongodb" instances
>> which will get scaled up or down.
>> 3. When an instance is spawned, it will get added to the mongos cluster
>> by a Puppet script.
>> Note - When implementing use-case scenario 2 and 3, Stratos Agent will
>> have to check the member list and depending on the member count, initialize
>> the replication set (master node) OR add the instance to the appropriate
>> replication set.
>>
>> Pl let me know your thoughts regarding this.
>>
>> [1] - https://github.com/echocat/puppet-mongodb
>>
>> Thanks.
>>
>> --
>> Akila Ravihansa Perera
>> Software Engineer
>> WSO2 Inc.
>> http://wso2.com
>>
>> Phone: +94 77 64 154 38
>> Blog: http://ravihansa3000.blogspot.com
>>
>
>
>
> --
> Lakmal Warusawithana
> Director - Cloud Architecture; WSO2 Inc.
> Mobile : +94714289692
> Blog : http://lakmalsview.blogspot.com/
>
>


-- 
Imesh Gunaratne

Technical Lead, WSO2
Committer & PPMC Member, Apache Stratos

Reply via email to