Genesys Backend issueshttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues2020-04-29T10:04:42+02:00https://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/515ES search with date2020-04-29T10:04:42+02:00Matija ObrezaES search with dateFix support for dates:
> failed to parse date field [Tue Dec 31 23:00:00 UTC 2019] with format [strict_date_optional_time||epoch_millis]
> Parse failure at index [0] of [Tue Dec 31 23:00:00 UTC 2019]Fix support for dates:
> failed to parse date field [Tue Dec 31 23:00:00 UTC 2019] with format [strict_date_optional_time||epoch_millis]
> Parse failure at index [0] of [Tue Dec 31 23:00:00 UTC 2019]2.5Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/513Accession lists unpublished Subsets2020-04-25T10:45:19+02:00Matija ObrezaAccession lists unpublished Subsetshttps://sandbox.genesys-pgr.org/a/5b0080b4-c151-495f-8fd8-483595d5469a lists unpublished subsets. Opening such Subset results in a call loop in the UI.https://sandbox.genesys-pgr.org/a/5b0080b4-c151-495f-8fd8-483595d5469a lists unpublished subsets. Opening such Subset results in a call loop in the UI.2.5Matija ObrezaMatija Obrezahttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/512Filter: Accession number2020-05-10T11:47:53+02:00Matija ObrezaFilter: Accession numbergenesys-pgr/genesys-ui#704 describes that the "Accession number" filter should behave as a string array filter -- accepting a number of entries.
> https://gitlab.croptrust.org/genesys-pgr/genesys-ui/merge_requests/686#note_40309
The `a...genesys-pgr/genesys-ui#704 describes that the "Accession number" filter should behave as a string array filter -- accepting a number of entries.
> https://gitlab.croptrust.org/genesys-pgr/genesys-ui/merge_requests/686#note_40309
The `accessionNumber` is indexed as *Text* due to its length. Perhaps we should allow for `eq`, `contains`, `starts` operators in `StringFilter` to allow for multiple values.2.5Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/511ES6 for Genesys2020-11-20T10:01:24+01:00Matija ObrezaES6 for GenesysIn grin-global/grin-global-server!13 we implemented support for ES6. Let's see how that works on Genesys!In grin-global/grin-global-server!13 we implemented support for ES6. Let's see how that works on Genesys!2.5Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/510Add dataProviderId for uploading Accessions2020-04-24T13:45:48+02:00Matija ObrezaAdd dataProviderId for uploading AccessionsAccession Uploader now uses the `doi` **or** `instituteCode` and `accessionNumber` (and `genus` if institute is flagged as having unique `accessionNumber` entries) to find an existing record in Genesys. This causes some problems for part...Accession Uploader now uses the `doi` **or** `instituteCode` and `accessionNumber` (and `genus` if institute is flagged as having unique `accessionNumber` entries) to find an existing record in Genesys. This causes some problems for partners that do not use DOI.
Data providers would like to use their internal identifiers to refer to their entries on Genesys.
When calling `/{instCode}/upsert`, they will include a new field in the incoming JSON:
```json
[
{ "dataProviderId": "USDA:123133", "accessionNumber": "FOOBAR", ... },
{ "dataProviderId": "USDA:5424", .... },
...
]
```
When this field is provided, the Uploader should:
1. If `doi` is provided, use `doi` first.
1. .. if not found by `doi`, then load `Accession` by `dataProviderId` if provided (see below)
1. .. if not found then use existing logic.
The `dataProviderId` is unique for the data provider, not to `FaoInstitute`. We require that the `dataProviderId` has a prefix `${partner.shortName}:`
The database must have a new unique key on `dataProviderId`.
Please also update the `/delete` Accession call to support `dataProviderId`.
2.5Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/509Query performance2020-04-03T11:56:25+02:00Matija ObrezaQuery performanceLoading dataset details loads the list of attached files. This query is very slow:
> select repository0_.datasetId as datasetI1_33_0_, repository0_.repositoryfileId as reposito2_39_0_, repository0_.position as position3_0_, repository1_...Loading dataset details loads the list of attached files. This query is very slow:
> select repository0_.datasetId as datasetI1_33_0_, repository0_.repositoryfileId as reposito2_39_0_, repository0_.position as position3_0_, repository1_.id as id1_81_1_, repository1_.active as active2_81_1_, repository1_.version as version3_81_1_, repository1_.createdBy as createdB4_81_1_, repository1_.createdDate as createdD5_81_1_, repository1_.lastModifiedBy as lastModi6_81_1_, repository1_.lastModifiedDate as lastModi7_81_1_, repository1_.accessRights as accessRi8_81_1_, repository1_.bibliographicCitation as bibliogr9_81_1_, repository1_.contentType as content10_81_1_, repository1_.created as created11_81_1_, repository1_.creator as creator12_81_1_, repository1_.dateRetrieved as dateRet13_81_1_, repository1_.description as descrip14_81_1_, repository1_.extension as extensi15_81_1_, repository1_.extent as extent16_81_1_, repository1_.folder_id as folder_28_81_1_, repository1_.license as license17_81_1_, repository1_.md5Sum as md18_81_1_, repository1_.originalFilename as origina19_81_1_, repository1_.originalUrl as origina20_81_1_, repository1_.path as path21_81_1_, repository1_.rightsHolder as rightsH22_81_1_, repository1_.sha1Sum as sha23_81_1_, repository1_.size as size24_81_1_, repository1_.subject as subject25_81_1_, repository1_.title as title26_81_1_, repository1_.uuid as uuid27_81_1_, repository1_.height as height1_84_1_, repository1_.orientation as orientat2_84_1_, repository1_.width as width3_84_1_, repository1_.abstract as abstract1_80_1_, repository1_.language as language2_80_1_, repository1_.clazz_ as clazz_1_ from dataset_repositoryfile repository0_ inner join ( select id, active, version, createdBy, createdDate, lastModifiedBy, lastModifiedDate, accessRights, bibliographicCitation, contentType, created, creator, dateRetrieved, description, extension, extent, license, md5Sum, originalFilename, originalUrl, path, rightsHolder, sha1Sum, size, subject, title, uuid, folder_id, null as height, null as orientation, null as width, null as abstract, null as language, 0 as clazz_ from repository_file union select id, active, version, createdBy, createdDate, lastModifiedBy, lastModifiedDate, accessRights, bibliographicCitation, contentType, created, creator, dateRetrieved, description, extension, extent, license, md5Sum, originalFilename, originalUrl, path, rightsHolder, sha1Sum, size, subject, title, uuid, folder_id, height, orientation, width, null as abstract, null as language, 1 as clazz_ from repository_image union select id, active, version, createdBy, createdDate, lastModifiedBy, lastModifiedDate, accessRights, bibliographicCitation, contentType, created, creator, dateRetrieved, description, extension, extent, license, md5Sum, originalFilename, originalUrl, path, rightsHolder, sha1Sum, size, subject, title, uuid, folder_id, null as height, null as orientation, null as width, abstract, language, 2 as clazz_ from repository_document ) repository1_ on repository0_.repositoryfileId=repository1_.id where repository0_.datasetId=81
maybe because of the inner join to a union join?
Please find a better query.2.5Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/508Scheduled checking of Easy-SMTA accounts2020-03-27T15:59:24+01:00Matija ObrezaScheduled checking of Easy-SMTA accountsWhen users make request for material on Genesys they are asked to register with Easy-SMTA and then click a link on Genesys that triggers another check if they have done the registration. When that check is successful, we send the request...When users make request for material on Genesys they are asked to register with Easy-SMTA and then click a link on Genesys that triggers another check if they have done the registration. When that check is successful, we send the request to the genebanks.
Users frequently forget to click the link and the request is then stuck.
Add a scheduled job (every 8 hours, only one run in entire cluster) that checks for Easy-SMTA accounts of incomplete requests younger than 1 month. If the account exists with Easy-SMTA, the request can be validated and sent to the genebanks.2.5Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/507Spring 52020-03-05T14:57:52+01:00Matija ObrezaSpring 5Upgrade to Spring 5.Upgrade to Spring 5.2.5Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/506OpenAPI v32021-02-10T20:28:56+01:00Matija ObrezaOpenAPI v3Migrate from swagger to springdoc OpenAPI. The code from https://gitlab.croptrust.org/grin-global/grin-global-server/merge_requests/2/diffs?commit_id=b2332b48fa49eaee32af38e606f404e21594b7fa can be recycled.Migrate from swagger to springdoc OpenAPI. The code from https://gitlab.croptrust.org/grin-global/grin-global-server/merge_requests/2/diffs?commit_id=b2332b48fa49eaee32af38e606f404e21594b7fa can be recycled.2.5Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/505Account expired2020-02-18T16:48:00+01:00Matija ObrezaAccount expiredThere is no mechanism to un-expire a user account:
![image](/uploads/13d8a4dfa628a479117c5e31321a1d34/image.png)
When the account expires I ask users to reset their password. If the password reset is successful, it should also set acco...There is no mechanism to un-expire a user account:
![image](/uploads/13d8a4dfa628a479117c5e31321a1d34/image.png)
When the account expires I ask users to reset their password. If the password reset is successful, it should also set account expiration date to `today + 1 month`.
Add admin API to extend expired account for 3 months.2.5Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/504Jetty 9.4.272020-03-02T11:56:31+01:00Matija ObrezaJetty 9.4.27With Jetty `9.4.26.v20200117` the MVC does not render JSPs.
Update pom.xml `<jetty.version>9.4.26.v20200117</jetty.version>` and observe http://localhost:8080/welcome with no content.
```
openjdk version "1.8.0_242"
OpenJDK Runtime Env...With Jetty `9.4.26.v20200117` the MVC does not render JSPs.
Update pom.xml `<jetty.version>9.4.26.v20200117</jetty.version>` and observe http://localhost:8080/welcome with no content.
```
openjdk version "1.8.0_242"
OpenJDK Runtime Environment (build 1.8.0_242-b08)
```
sitemesh3 doesn't work with jetty `>9.4.18` and `<9.4.27`. Wait for **9.4.27** release.2.5Matija ObrezaMatija Obrezahttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/503Remove documents from ES2020-02-12T06:05:12+01:00Matija ObrezaRemove documents from ESSometimes ES contains invalid documents. Allow admin to remove documents from ES using filters.Sometimes ES contains invalid documents. Allow admin to remove documents from ES using filters.2.5Matija ObrezaMatija Obrezahttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/502AccessionFilter: add data provider2020-01-30T11:44:32+01:00Matija ObrezaAccessionFilter: add data providerSimilar to PGRFA network, add "partner" filtering (using UUID) that fetches institutes of the `Partner` and lists/overviews accessions like we do for Networks.Similar to PGRFA network, add "partner" filtering (using UUID) that fetches institutes of the `Partner` and lists/overviews accessions like we do for Networks.2.5Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/500Sitemap: Add sitemap-genus.xml2020-01-30T11:42:37+01:00Matija ObrezaSitemap: Add sitemap-genus.xmlAdd a new item to the `sitemap.xml` controller to include `sitemap-genus.xml` sitemap.
This XML should list links to all "valid" genera (see below) at `{fontendURL}/t/{genus}` (a new page added to the UI):
```xml
<urlset xsi:schemaLoca...Add a new item to the `sitemap.xml` controller to include `sitemap-genus.xml` sitemap.
This XML should list links to all "valid" genera (see below) at `{fontendURL}/t/{genus}` (a new page added to the UI):
```xml
<urlset xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9 http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd">
<url>
<loc>https://www.genesys-pgr.org/t/Arabidopsis</loc>
<changefreq>monthly</changefreq>
<priority>0.4</priority>
</url>
...
```
## The page
The page on the UI will have:
```html
<h1><em>{genus}</em></h1>
<p>Find and request <em>{genus}</em> material for research and breeding from <em>ex-situ</em> collections (genebanks) through Genesys.</p>
<ul>
<li><em>{genus} {species}</em> {spAuthor} <em>{subTaxa}</em>{subtAuthor}</li>
...
```
A click on `h1` should open the accession overview page for the selected genus.
Optional: Each `li` on the website will (onClick) issue a call to list the accessions matching the selected species.
The page needs to retrieve the list of `Taxonomy2` for the selected `genus` from */api/v1/taxonomy* using `{ "genus": "TheGenus" }` filter.
## "Valid" names
A "valid" genus name is one that matches `^[a-zA-Z ]+$` (only ascii chars + space) that can be used as valid URLs.
99% of names match this regular expression, but there are some names that contain `?` and that would cause problems.
## API controller
We need an API endpoint at */api/v[1,2]/taxonomy* that will accept a `TaxonomyFilter` and return a `List<Taxonomy2>` results.2.5Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/499Text search filter doesn't work on the Dashboard catalog`s browse pages;2020-01-27T16:21:14+01:00Kiril MorhalenkoText search filter doesn't work on the Dashboard catalog`s browse pages;**Steps:**
1. Go to any catalog browse page
(
* "https://sandbox.genesys-pgr.org/dashboard/datasets"
or
* "https://sandbox.genesys-pgr.org/dashboard/descriptorlists"
)
2. Enter to the Text search filter some text (e.g. "qwerty");
3....**Steps:**
1. Go to any catalog browse page
(
* "https://sandbox.genesys-pgr.org/dashboard/datasets"
or
* "https://sandbox.genesys-pgr.org/dashboard/descriptorlists"
)
2. Enter to the Text search filter some text (e.g. "qwerty");
3. Click "Apply filters" button;
**Expected result:**
Search results should be match the query;
**Actual result:**
All available items is displayed as search results;
![image](/uploads/d5c5a8ec787708f6a3893955eb7c94f8/image.png)
![image](/uploads/5466910dd8c28f53d1c2daac7b757052/image.png)Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/501Admin user can create the same CMS articles;2020-01-28T16:52:42+01:00Kiril MorhalenkoAdmin user can create the same CMS articles;**Steps:**
1. Go to "https://sandbox.genesys-pgr.org/admin/content" as admin user;
2. Click "+" button;
3. Enter to the "Slug" field "test";
4. Enter to the "Language" field "en";
5. Click "Back to article list";
6. Click "+" button;
7. ...**Steps:**
1. Go to "https://sandbox.genesys-pgr.org/admin/content" as admin user;
2. Click "+" button;
3. Enter to the "Slug" field "test";
4. Enter to the "Language" field "en";
5. Click "Back to article list";
6. Click "+" button;
7. Enter to the "Slug" field "test";
8. Enter to the "Language" field "en";
9. Click "Back to article list";
10. Try to open one of created article;
or you can open "https://sandbox.genesys-pgr.org/admin/content/v2LYA5yzWq8" as admin and try to open one of articles;
**Expected result:**
User cann`t create two or more same articles. When user try to create article which already exist he should see snack bar "Article should be unique" or something like this;
**Actual result:**
User can create two or more same articles. Also if user try to open one of them request failed with status code 500;
![image](/uploads/a2fbfea7f5a62eae27be134226b85abc/image.png)
![image](/uploads/8e2e81dd046c7133944bb5a0528380c4/image.png)Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/497JSP Admin OAuth editor2020-01-22T16:59:57+01:00Matija ObrezaJSP Admin OAuth editorPlease update the OAuth client editor in JSP so that all properties can be managed with the JSP version.
![image](/uploads/931c5c824e78607307f6fd3bbdc9a84a/image.png)
At the moment, when the genesys-ui is not able to talk to the backen...Please update the OAuth client editor in JSP so that all properties can be managed with the JSP version.
![image](/uploads/931c5c824e78607307f6fd3bbdc9a84a/image.png)
At the moment, when the genesys-ui is not able to talk to the backend, there is no way to manage the settings of the OAuth client.2.5Maxym BorodenkoMaxym Borodenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/496Database configuration2020-01-22T11:19:49+01:00Matija ObrezaDatabase configurationAdd *wait timeout* to Genesys settings.Add *wait timeout* to Genesys settings.2.5Matija ObrezaMatija Obrezahttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/495PGR Network accessions2020-01-28T15:11:12+01:00Matija ObrezaPGR Network accessionsThe query to fetch accessions for a PGR Network member is too slow.
Update the `InstituteFilter` so members of the network are loaded by `slug` and passed in as `id`.The query to fetch accessions for a PGR Network member is too slow.
Update the `InstituteFilter` so members of the network are loaded by `slug` and passed in as `id`.2.5Matija ObrezaMatija Obrezahttps://gitlab.croptrust.org/genesys-pgr/genesys-server/-/issues/498Genebank can confirm the same request several times;2020-01-27T10:28:12+01:00Kiril MorhalenkoGenebank can confirm the same request several times;**Steps:**
1. Make a request to test genebank;
2. Confirm this request on your email;
3. Go to "https://sandbox.genesys-pgr.org/admin/requests" as admin user;
4. Open your request;
5. Click on the "Resend" button in the "Dispatched to" b...**Steps:**
1. Make a request to test genebank;
2. Confirm this request on your email;
3. Go to "https://sandbox.genesys-pgr.org/admin/requests" as admin user;
4. Open your request;
5. Click on the "Resend" button in the "Dispatched to" block two times;
6. Open genebank`s email (you should have 3 massages from Genesys);
7. Open the first email from Genesys;
8. Click on the link and confirm your request;
9. Open the second email from Genesys;
10. Click on the link and confirm your request;
**Expected result:**
Snack bar with message "Request is already validated or dispatched." should be displayed;
**Actual result:**
Any snack bar isn`t displayed;
![same_request_confirmation](/uploads/e7fb07d6895e4191ad4cac46849e28af/same_request_confirmation.gif)Maxym BorodenkoMaxym Borodenko