Re: Date Range Facet sort order

2023-04-05 Thread Thomas Redman
Yes indeed, my bad, I didn’t describe this correctly… at all. 

Still one question, is there a way to change the sort order for date range 
facets? Or do I do that on my end? There are some cases where I want to see 
results in count order, other cases where I want to see results sort on the 
button range.

> On Apr 4, 2023, at 3:12 PM, Chris Hostetter  wrote:
> 
> 
> : I see no way to change the sort order to index (I want the output in 
> : date order), I get results sorted on the count. I have tried adding the 
> : sort field like so:
> 
> This ... doesn't make sense.  
> 
> AFAIK "index" order (or more specifically: The "natural order" of the 
> bucket values) is the only possible sorting returned by JSON Range Facet 
> 
> ie: what you are asking for should be what you are getting, what you say 
> you are getting shouldn't be possible.
> (see examples below)
> 
> 
> What does your solrj code that consumes the QueryResponse look like?
> 
> 
> $ curl 'http://localhost:8983/solr/techproducts/query?rows=0&omitHeader=true' 
> -d '
> {
>  "query": "*:*",
>  "facet": {
>"prices": {
>  "type": "range",
>  "field": "price",
>  "start": 0,
>  "end": 100,
>  "gap": 20
>}
>  }
> }'
> {
>  "response":{"numFound":32,"start":0,"numFoundExact":true,"docs":[]
>  },
>  "facets":{
>"count":32,
>"prices":{
>  "buckets":[{
>  "val":0.0,
>  "count":5},
>{
>  "val":20.0,
>  "count":0},
>{
>  "val":40.0,
>  "count":0},
>{
>  "val":60.0,
>  "count":1},
>{
>  "val":80.0,
>  "count":1}]}}}
> 
> 
> $ curl 
> 'http://localhost:8983/solr/techproducts/query?rows=0&omitHeader=true' -d'
> {
>  "query": "*:*",
>  "facet": {
>"prices": {
>  "type": "range",
>  "field": "manufacturedate_dt",
>  "start": "1900-01-01T00:00:00Z",
>  "end": "2200-01-01T00:00:00Z",
>  "gap": "+100YEARS"
>}
>  }
> }'
> {
>  "response":{"numFound":32,"start":0,"numFoundExact":true,"docs":[]
>  },
>  "facets":{
>"count":32,
>"prices":{
>  "buckets":[{
>  "val":"1900-01-01T00:00:00Z",
>  "count":0},
>{
>  "val":"2000-01-01T00:00:00Z",
>  "count":11},
>{
>  "val":"2100-01-01T00:00:00Z",
>  "count":0}]}}}
> 
> Here's a test that uses SollrJ to assert that the execpted buckets come 
> back in the expected order (by bucket value, not by bucket count) ...
> 
> https://github.com/apache/solr/blob/releases/solr/9.0.0/solr/solrj/src/test/org/apache/solr/client/ref_guide_examples/JsonRequestApiTest.java#L573-L596
> 
> 
> 
> 
> 
> 
> -Hoss
> http://www.lucidworks.com/



Re: solr backups failing

2023-04-05 Thread r ohara
The logs did not show anything that would explain the error. I believe
the issue was because I had added a shard since the last backup. Once I
deleted the backup, it worked as expected and subsequent backups worked as
well.

Thanks for the comments.

On Wed, Mar 29, 2023 at 7:10 AM Vivaldi  wrote:

> Are you using HDFS to backup or shared network directory? In the case of
> shared directory the same location should be writable (accessible and has
> write permissions) from all solr nodes.
>
>
> > On 28 Mar 2023, at 19:22, Houston Putman 
> wrote:
> >
> > Can you provide more information, such as the request you send to solr
> and
> > logs that might explain the IOException?
> >
> > - Houston
> >
> >> On Wed, Mar 22, 2023 at 10:51 AM r ohara  wrote:
> >>
> >> Hi all,
> >> We are using solrcloud 8.11 with 10 shards. We've been getting errors
> >> trying to back up our index using the collections API. Here's the error
> we
> >> see in some of the nodes when we run the REQUESTSTATUS api.
> >>
> >> Failed to backup core=collection_02_replica_t21 because
> >> java.io.IOException: Input/output error
> >>
> >> We ran it successfully once, but since then at least one node, but not
> >> always the same one fails. It is a large index with almost 100 million
> >> documents and 2T total in size. What could cause this error?
> >>
> >> Thanks in advance
> >>
>
>