[ https://issues.apache.org/jira/browse/SOLR-5017?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13704598#comment-13704598 ]
Jack Krupansky commented on SOLR-5017: -------------------------------------- bq. If the id no longer contains enough information to tell what shard it's on... Great point. Automatic routing needs to be able to work when presented with just the ID field. An atomic update is a great example - the shard field may not be available on the client. Better to just forever say that automatic routing needs to be based solely on the ID key value, and that if the app needs to use the value of another field for routing, they absolutely do need to use a "composite key" with the routing key prepended to the nominal key value. OTOH, maybe they might want to use some other subset of the key value for router, such as a product category that is a part of a SKU used as the ID key. I think the idea there is that this would be custom sharding that uses most of the logic of CompositeID routing, but just different logic for how to extract the routing key from the full ID key value. Manual or custom routing is another story. There, the user can use whatever contrived "rules" they want. > Allow sharding based on the value of a field > -------------------------------------------- > > Key: SOLR-5017 > URL: https://issues.apache.org/jira/browse/SOLR-5017 > Project: Solr > Issue Type: Sub-task > Reporter: Noble Paul > Assignee: Noble Paul > > We should be able to create a collection where sharding is done based on the > value of a given field > collections can be created with shardField=fieldName, which will be persisted > in DocCollection in ZK > implicit DocRouter would look at this field instead of _shard_ field > CompositeIdDocRouter can also use this field instead of looking at the id > field. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org