Not sure if this will meet all your needs but you can probably do most of the work using AWS lambda. I haven't used it personally but it is supposed to launch custom code following some events.
I guess you could create a small Java class to do the required work following the birth of a new server or the death of the old one. If you can find an event source that provide you the entry point, you'll probably be fine. https://aws.amazon.com/lambda/faqs/ Good luck ________________________________________ From: Erick Erickson <erickerick...@gmail.com> Sent: Wednesday, December 9, 2015 2:19 PM To: solr-user Subject: Re: Fully automated replica creation in AWS Not that I know of. The two systems are somewhat disconnected. AWS doesn't know that Solr lives on those nodes, it's just spinning one up, right? Albeit with Solr running. There's nothing in Solr that auto-detects the existence of a new Solr node and automagically assigns collections and/or replicas. How would either system intuit that this new node is replacing something else and "do the right thing"? I'll tell you how, by interrogating Zookeeper and seeing that for some specific collection, shardX had fewer replicas than other shards and issuing the Collections API ADDREPLICA command. But now there are _three_ systems that need to be coordinated and doing the right thing in your situation would be the wrong thing in another. The last thing many sys ops want is having replicas started without their knowledge. And on top of that, I have doubts about the model. Having AWS elastically spin up a new replica is a heavyweight operation from Solr's perspective. I mean this potentially copies a many G set of index files from one place to another which could take a long time, is that really what's desired here? I have seen some folks spin up/down Solr instances based on a schedule if they know roughly when the peak load will be, but again there's nothing built in to handle this. Best, Erick On Wed, Dec 9, 2015 at 10:15 AM, Ugo Matrangolo <ugo.matrang...@gmail.com> wrote: > Hi, > > I was trying to setup a SolrCloud cluster in AWS backed by an ASG (auto > scaling group) serving a replicated collection. I have just came across a > case when one of the Solr node became unresponsive with AWS killing it and > spinning a new one. > > Unfortunately, this new Solr node did not join as a replica of the existing > collection requiring human intervention to configure it as a new replica. > > I was wondering if there is around something that will make this process > fully automated by detecting that a new node just joined the cluster and > instructing it (e.g. via Collections API) to join as a replica of a given > collection. > > Best > Ugo