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

David Smiley updated SOLR-9690:
-------------------------------
    Attachment: DirectHashRouter.java

I started playing with the idea of a custom DocRouter subclassing 
HashBasedRouter in which the hash integer is parsed from the router.field 
instead of using a hash function.  I'm thinking that this approach would then 
allow someone to possibly use shard splitting, and it might allow for more 
existing Solr infrastructure to be leveraged, for example the shard/slice hash 
ranges to pick which slice to go to.  The code is attached; it's really an 
un-used toy at this time.

But I don't yet know if this approach makes sense for how Solr should do 
date/time routing as a 1st class feature.  For example, what's the implication 
of   HashBasedRouter.hashToSlice() throwing an exception if it doesn't see a 
Slice with a range covering this document?  Maybe it's okay.  Out of scope of 
this JIRA issue but a follow-on would be auto-creation of shards, perhaps 
just-in-time (when docs arrive and there is no suitable shard).  And another 
JIRA issue would be capping a shard by size such that the last shard range's 
end range integer could be lowered to whatever the time is of the last document.

[~shalinmangar] I'm especially curious what your opinion is, given that you've 
done work pertaining the the existing DocRouters.

> Date/Time DocRouter
> -------------------
>
>                 Key: SOLR-9690
>                 URL: https://issues.apache.org/jira/browse/SOLR-9690
>             Project: Solr
>          Issue Type: New Feature
>      Security Level: Public(Default Security Level. Issues are Public) 
>            Reporter: David Smiley
>         Attachments: DirectHashRouter.java
>
>
> This issue is for a custom Solr DocRouter that works with dates/times (or 
> perhaps any field providing an int).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

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

Reply via email to