[ 
https://issues.apache.org/jira/browse/SOLR-5308?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Shalin Shekhar Mangar updated SOLR-5308:
----------------------------------------

    Attachment: SOLR-5308.patch

# Added a simple test that tests for migration of a route key from a static 
index (i.e. no updates in progress)
# Cleaning up existing temporary collections was broken in the last patch. I 
fixed it.

I started working on forwarding requests in this patch. A RoutingRule is added 
to the clusterstate.json inside the source shard. Such a rule may be used by 
the DistributedUpdateProcessor to forward requests from source shard to target 
collection. Example below:
{code}
"shard2":{
              "range":"0-7fffffff",
              "state":"active",
              "replicas":{
                "core_node2":{
                  "state":"active",
                  "base_url":"http://127.0.0.1:51321/ckvmo/du";,
                  "core":"collection1",
                  "node_name":"127.0.0.1:51321_ckvmo%2Fdu",
                  "leader":"true"},
                "core_node4":{
                  "state":"active",
                  "base_url":"http://127.0.0.1:51328/ckvmo/du";,
                  "core":"collection1",
                  "node_name":"127.0.0.1:51328_ckvmo%2Fdu"}},
              "routingRules":{"a!":[{
                    "targetShard":"shard1",
                    "routeRange":"3c250000-3c25ffff",
                    "expireAt":"1382449837040",
                    "targetCollection":"migrate_routekey_test_targetCollection",
                    "routeKey":"a!"}]}}}
{code}

The expireAt is hard coded to System.currentTimeMillis() + 10 minutes but may 
be passed as a parameter in future. The intent is to forward update requests 
for the given route key and the given hash range from a source shard to the 
target collection (target shard doesn't matter) temporarily i.e. during the 
migration and for some time afterwards. This is still a work in progress.

> Split all documents of a route key into another collection
> ----------------------------------------------------------
>
>                 Key: SOLR-5308
>                 URL: https://issues.apache.org/jira/browse/SOLR-5308
>             Project: Solr
>          Issue Type: New Feature
>          Components: SolrCloud
>            Reporter: Shalin Shekhar Mangar
>            Assignee: Shalin Shekhar Mangar
>             Fix For: 4.6, 5.0
>
>         Attachments: SOLR-5308.patch, SOLR-5308.patch, SOLR-5308.patch
>
>
> Enable SolrCloud users to split out a set of documents from a source 
> collection into another collection.
> This will be useful in multi-tenant environments. This feature will make it 
> possible to split a tenant out of a collection and put them into their own 
> collection which can be scaled separately.



--
This message was sent by Atlassian JIRA
(v6.1#6144)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to