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

Jason Gerlowski resolved SOLR-17113.
------------------------------------
    Fix Version/s: main (10.0)
                   9.6.0
       Resolution: Fixed

Thanks for the report and PR [~pciezkowski]; merged this in for 9.6!

> When backup fails unexpected json schema is returned
> ----------------------------------------------------
>
>                 Key: SOLR-17113
>                 URL: https://issues.apache.org/jira/browse/SOLR-17113
>             Project: Solr
>          Issue Type: Bug
>          Components: Backup/Restore
>    Affects Versions: 9.4
>            Reporter: Przemyslaw Ciezkowski
>            Assignee: Jason Gerlowski
>            Priority: Major
>             Fix For: main (10.0), 9.6.0
>
>          Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> After triggering backup with
> {noformat}
> curl 
> 'localhost:8983/solr/core/replication?command=backup&repository=gcs_backup'{noformat}
> I can watch its result with
>  
> {noformat}
> curl 'http://localhost:8983/solr/core/replication?command=details'{noformat}
> Which returns this json:
>  
> {noformat}
> {
>     "responseHeader": {
>         "status": 0,
>         "QTime": 3
>     },
>     "status": "OK",
>     "details": {
>         // redacted
>         "backup": {
>             "startTime": "2023-12-20T14:51:06.388847Z",
>             "fileCount": 594,
>             "indexFileCount": 594,
>             "status": "success",
>             "snapshotCompletedAt": "2023-12-20T17:14:32.257828Z",
>             "endTime": "2023-12-20T17:14:32.257828Z",
>             "snapshotName": "name",
>             "directoryName": "dir"
>         }
>     }
> }
> {noformat}
> Notice that backup is an object. However when exception occurs this json is 
> returned:
> {noformat}
> {
>     "responseHeader":{
>       "status":0,
>       "QTime":1
>     },
>     "status":"OK",
>     "details":{
>       //redacted
>       "backup":["exception","The specified bucket does not exist."]
>     }
>   }
> {noformat}
> Notice that backup is no longer an object. It became an array. I believe it 
> was supposed to be an object as first element is key name ("exception").
> I believe bug is in this line:
> https://github.com/apache/solr/blob/91a19404fc90929b70c8513a058cfb1d560496da/solr/core/src/java/org/apache/solr/handler/SnapShooter.java#L258-L259



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

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

Reply via email to