Add notes for 2020-10-07

This commit is contained in:
2020-10-07 14:44:39 +03:00
parent 0a68ed0066
commit 8c05534ff9
22 changed files with 135 additions and 27 deletions

View File

@ -132,4 +132,55 @@ org.apache.solr.client.solrj.impl.HttpSolrServer$RemoteSolrException: Expected m
- Solr returns `hits=18` for the L&R query, but there are no result shown in the L&R UI
- I sent all this feedback to Atmire...
## 2020-10-07
- Udana from IWMI had asked about stats discrepencies from reports they had generated in previous months or years
- I told him that we very often purge bots and the number of stats can change drastically
- Also, I told him that it is not possible to compare stats from previous exports and that the stats should be taking with a grain of salt
- Testing POSTing items to the DSpace 6 REST API
- We need to authenticate to get a JSESSIONID cookie first:
```
$ http -f POST https://dspacetest.cgiar.org/rest/login email=aorth@fuuu.com 'password=fuuuu'
$ http https://dspacetest.cgiar.org/rest/status Cookie:JSESSIONID=EABAC9EFF942028AA52DFDA16DBCAFDE
```
- Then we post an item in JSON format to `/rest/collections/{uuid}/items`:
```
$ http POST https://dspacetest.cgiar.org/rest/collections/f10ad667-2746-4705-8b16-4439abe61d22/items Cookie:JSESSIONID=EABAC9EFF942028AA52DFDA16DBCAFDE < item-object.json
```
- Format of JSON is:
```
{ "metadata": [
{
"key": "dc.title",
"value": "Testing REST API post",
"language": "en_US"
},
{
"key": "dc.contributor.author",
"value": "Orth, Alan",
"language": "en_US"
},
{
"key": "dc.date.issued",
"value": "2020-09-01",
"language": "en_US"
}
],
"archived":"false",
"withdrawn":"false"
}
```
- What is unclear to me is the `archived` parameter, it seems to do nothing... perhaps it is only used for the `/items` endpoint when printing information about an item
- If I submit to a collection that has a workflow, even as a super admin and with "archived=false" in the JSON, the item enters the workflow ("Awaiting editor's attention")
- If I submit to a new collection without a workflow the item gets archived immediately
- I created [some notes](https://gist.github.com/alanorth/40fc3092aefd78f978cca00e8abeeb7a) to share with Salem and Leroy for future reference when we start discussion POSTing items to the REST API
- I created an account for Salem on DSpace Test and added it to the submitters group of an ICARDA collection with no other workflow steps so we can see what happens
- We are curious to see if he gets a UUID when posting from MEL
<!-- vim: set sw=2 ts=2: -->