Project

General

Profile

Actions

task #10222

open

Use DTOs for portal taxon page

Added by Andreas Müller 2 months ago. Updated about 15 hours ago.

Status:
In Progress
Priority:
Highest
Category:
cdm-dataportal
Target version:
Start date:
Due date:
% Done:

20%

Estimated time:
Severity:
major
Tags:

Description

... to improve performance and simplify dataportal rendering. If possible formatting should take place server side.

Open issues: how to pass configuration?

  • huge number of parameters
  • json configuration

Discussion about data, contained in DTO(s):

  • taxonName: should everything be handled in typedLabel or in own DTO? => typedLabel or taggedText should be enough
    • if we have an own dto, we can add rank and rankorder index, but maybe we only need the rank string if all ordering is done serverside => ordering is done serverside
    • nomenclatural source is missing
    • to create a link to the name page the uuid is needed.
  • name relationships => implemented -> ruleConsidered is missing => added
  • name facts
  • protologue links
  • specimen: could we reuse or reorganize the already existing derivedUnit/fieldunit dtos? They are already implemented for the use in dataportal
    • there are already methods implemented to get the specimen subtree for one taxon to get the data for the specimen tree view, they already return dtos (OccurrenceController.doGetRootUnitDTOs() and this calls OccurenceServiceImpl.findRootUnitDTOs)
  • currently the facts are merged into the feature tree (see _mergeFeatureTreeDescriptions in cdm_api.module of the dataportal code), we should handle this similar when creating the dto => implemented, see #note-27
  • the distribution facts are handled separately in dataportal, maybe we should handle them in a separate item in the dto as well.
  • name type designations
    • still throw an exception if >1 name type designation exists per HG (example Crepis/Cichorieae, HG: Dianthoseris Sch. Bip. ex A. Rich., Tent. Fl. Abyss. 1: 468. 1848)
    • add name type designations to names, not homotypic groups (ticket exists), this will also solve the above problem
  • include description sources in description element sources
  • handle resolvable identifiers (see #10260)

https://test.e-taxonomy.eu/dataportal/preview/cyprus/cdm_dataportal/newtaxon/a4637006-8ea3-443b-b4e6-b6f66884e7bc (Amaranthus cruentus, but currently Error only )
https://test.e-taxonomy.eu/dataportal/preview/cichorieae/cdm_dataportal/newtaxon/b335ceee-d6c1-4c93-841d-3b4bd279d855 (Erythroseris amabilis)
https://test.e-taxonomy.eu/cdmserver/cyprus/portal/taxon/a4637006-8ea3-443b-b4e6-b6f66884e7bc/page
https://test.e-taxonomy.eu/dataportal/preview/euromed/cdm_dataportal/newtaxon/6a8e85bd-5e52-4ae2-9444-99128c87a672 (Abies alba)
https://int.e-taxonomy.eu/dataportal/integration/flora-malesiana/cdm_dataportal/taxon/87e76e43-e4b7-44a1-a195-2c36a63b34bb/synonymy (Tristiropsis acutangula)


Files

clipboard-202302201350-qnda3.png (25.3 KB) clipboard-202302201350-qnda3.png Andreas Müller, 02/20/2023 01:50 PM

Related issues

Related to EDIT - feature request #9271: Improve E+M dataportal performanceNewAndreas Müller

Actions
Related to EDIT - task #6208: implement synonymy service responding with DTONewAndreas Müller

Actions
Related to EDIT - feature request #8285: Handle taxonomically valueless taxa in data portalNewKatja Luther

Actions
Related to EDIT - bug #9396: nomenclatural status missing in typedesignations shown in synonymy NewAndreas Müller

Actions
Related to EDIT - feature request #5807: implement sub-distribution area inclusion in TaxonService.findTaxaAndNamesByFullText()NewAndreas Müller

Actions
Related to EDIT - feature request #10127: Add full reference information to sec. references in dataportalNewKatja Luther

Actions
Related to EDIT - feature request #10260: Add resolve mechanism to (external) identifiersClosedAndreas Müller

Actions
Actions #1

Updated by Andreas Müller 2 months ago

Actions #2

Updated by Andreas Müller 2 months ago

  • Status changed from New to In Progress
Actions #4

Updated by Katja Luther 2 months ago

  • Description updated (diff)
Actions #5

Updated by Katja Luther 2 months ago

  • Description updated (diff)
Actions #6

Updated by Katja Luther 2 months ago

  • Description updated (diff)
Actions #7

Updated by Andreas Müller 2 months ago

  • taxonName: should everything be handled in typedLabel or in own DTO?
    • if we have an own dto, we can add rank and rankorder index, but maybe we only need the rank string if all ordering is done serverside

Is there done any ordering via ranks in the current taxon pages?

Actions #8

Updated by Andreas Müller 2 months ago

  • specimen: could we reuse or reorganize the already existing derivedUnit/fieldunit dtos? They are already implemented for the use in dataportal
    • there are already methods implemented to get the specimen subtree for one taxon to get the data for the specimen tree view, they already return dtos

Can you leave a note which methods are used there?

Actions #9

Updated by Katja Luther 2 months ago

  • Description updated (diff)
Actions #11

Updated by Andreas Müller 2 months ago

  • Description updated (diff)
Actions #12

Updated by Andreas Müller 2 months ago

  • % Done changed from 0 to 10

taxonNode agent relationships should be implemented now. Please review. Do we need more fields (I tried to use only the absolute minimum).

Actions #13

Updated by Katja Luther 2 months ago

  • Description updated (diff)
Actions #14

Updated by Andreas Müller 2 months ago

  • Description updated (diff)
Actions #15

Updated by Andreas Müller about 2 months ago

Actions #16

Updated by Katja Luther about 2 months ago

  • Description updated (diff)
Actions #17

Updated by Katja Luther about 2 months ago

  • Description updated (diff)
Actions #18

Updated by Katja Luther about 2 months ago

  • Description updated (diff)
Actions #19

Updated by Katja Luther about 2 months ago

  • Description updated (diff)
Actions #20

Updated by Andreas Müller about 2 months ago

  • Related to bug #9396: nomenclatural status missing in typedesignations shown in synonymy added
Actions #21

Updated by Andreas Müller about 2 months ago

  • Related to feature request #5807: implement sub-distribution area inclusion in TaxonService.findTaxaAndNamesByFullText() added
Actions #22

Updated by Katja Luther about 1 month ago

There is a first implementation for the dataportal available, you can have a look if you exchange the taxon with newtaxon in the url, for example https://test.e-taxonomy.eu/dataportal/preview/cichorieae/cdm_dataportal/newtaxon/b335ceee-d6c1-4c93-841d-3b4bd279d855

Actions #23

Updated by Andreas Müller about 1 month ago

  • % Done changed from 10 to 20

Katja Luther wrote:

  • the distribution facts are handled separately in dataportal, maybe we should handle them in a separate item in the dto as well.

Distribution data are now handled within the feature tree, using the same datastructure for urlmapping and condensed distribtion string as before and using a DTO representation for tree that is similar (but not equal) to the one used in the previous version.
Please leave a not if something is missing.

Actions #24

Updated by Andreas Müller about 1 month ago

  • Description updated (diff)
Actions #25

Updated by Andreas Müller about 1 month ago

  • Description updated (diff)
Actions #26

Updated by Andreas Müller about 1 month ago

  • Description updated (diff)

Katja Luther wrote:

  • currently the facts are merged into the feature tree (see _mergeFeatureTreeDescriptions in cdm_api.module of the dataportal code), we should handle this similar when creating the dto

The webservice allows passing a parameter "featureTree". This will be used to order and filter the returned factual data accordingly. (implementing soon)

Actions #27

Updated by Andreas Müller about 1 month ago

Andreas Müller wrote in #note-26:

Katja Luther wrote:

  • currently the facts are merged into the feature tree (see _mergeFeatureTreeDescriptions in cdm_api.module of the dataportal code), we should handle this similar when creating the dto

The webservice allows passing a parameter "featureTree". This will be used to order and filter the returned factual data accordingly. (implementing soon)

This is implemented now.

Actions #28

Updated by Andreas Müller about 1 month ago

  • Description updated (diff)
Actions #29

Updated by Andreas Müller about 1 month ago

  • Description updated (diff)
Actions #30

Updated by Andreas Müller about 1 month ago

  • Description updated (diff)
Actions #31

Updated by Andreas Müller about 1 month ago

  • Description updated (diff)
Actions #32

Updated by Katja Luther about 1 month ago

The dto for common name dtos are different to the other facts, therefore it is more difficult to handle it in a generic way. It is necessary to know where to find the type of the fact otherwise it is difficult to decide how to render the content.

For example for the common name there is no typedLabel.

Actions #33

Updated by Andreas Müller about 1 month ago

I implemented basic error handling. So the message field can be evaluated now and empty results should not happen anymore.

Actions #34

Updated by Andreas Müller about 1 month ago

  • Description updated (diff)
Actions #35

Updated by Katja Luther about 1 month ago

To create the same html code like before it is necessary to provide the feature uuid for the descriptions.

Actions #36

Updated by Katja Luther about 1 month ago

The order of the (homotypic?) synonyms is not correct, for example for Aizoon hispanicum L.(Cyprus) the order of the synonyms should be

  • Aizoanthemum hispanicum (L.) H. E. K. Hartmann
  • Aizoanthemopsis hispanica (L.) Klak

but is the other way round.

Actions #37

Updated by Andreas Müller about 1 month ago

Katja Luther wrote in #note-35:

To create the same html code like before it is necessary to provide the feature uuid for the descriptions.

I do not fully understand what you mean here. What is "the feature uuid for the description"? A description does not have feature. Do you mean fact/description element? Why can't you take this form the factual data tree which is ordered first by feature (including uuid) and then by it's attached factual data. So each facts has a feature uuid attached via it's "parent feature".
If this does not answer your request please add an example html to make clear how the feature uuid is used.

Actions #38

Updated by Katja Luther about 1 month ago

Andreas Müller wrote in #note-37:

Katja Luther wrote in #note-35:

To create the same html code like before it is necessary to provide the feature uuid for the descriptions.

I do not fully understand what you mean here. What is "the feature uuid for the description"? A description does not have feature. Do you mean fact/description element? Why can't you take this form the factual data tree which is ordered first by feature (including uuid) and then by it's attached factual data. So each facts has a feature uuid attached via it's "parent feature".
If this does not answer your request please add an example html to make clear how the feature uuid is used.

Sorry that was the wrong term, I meant the uuid of the feature of the facts. This should be added to the object containing the facts of one feature, actually only the label of the feature is contained.

Actions #39

Updated by Andreas Müller about 1 month ago

Katja Luther wrote in #note-38:

Andreas Müller wrote in #note-37:

Katja Luther wrote in #note-35:

To create the same html code like before it is necessary to provide the feature uuid for the descriptions.

I do not fully understand what you mean here. What is "the feature uuid for the description"? A description does not have feature. Do you mean fact/description element? Why can't you take this form the factual data tree which is ordered first by feature (including uuid) and then by it's attached factual data. So each facts has a feature uuid attached via it's "parent feature".
If this does not answer your request please add an example html to make clear how the feature uuid is used.

Sorry that was the wrong term, I meant the uuid of the feature of the facts. This should be added to the object containing the facts of one feature, actually only the label of the feature is contained.

I still do not understand why you say that it is not there. It is available via the tree. E.g.

Example from https://test.e-taxonomy.eu/cdmserver/cyprus/portal/taxon/a4637006-8ea3-443b-b4e6-b6f66884e7bc/page

Repeating it in the fact itself is possbile but redundant which I would like to avoid in general. If there is an important reason to have this redundancy please explain. If really needed we can add it ofcourse.

Actions #40

Updated by Andreas Müller about 1 month ago

Katja Luther wrote in #note-36:

The order of the (homotypic?) synonyms is not correct, for example for Aizoon hispanicum L.(Cyprus) the order of the synonyms should be

  • Aizoanthemum hispanicum (L.) H. E. K. Hartmann
  • Aizoanthemopsis hispanica (L.) Klak

but is the other way round.

Hmm, this is strange. The PortalDtoLoader uses a comparator (eu.etaxonomy.cdm.compare.taxon.TaxonComparator). This comparator results in the "newtaxon" ordering. Which in IMO is correct as the only difference between the 2 synonyms is the alphabetic string which should have Aizoanthemopsis before Aizoanthemum (no difference in date, rank or status). However, I can see that on the old taxon page AND in the taxEditor it is ordered the other way round.
Do you know which comparator is used e.g. in taxEditor or for the old pages? And if it is the TaxonComparator class which configuration it uses (with rank/without rank)? And could you debug the ordering in taxEditor to see why exactly it orderes the names the other way round?

Actions #41

Updated by Katja Luther about 1 month ago

  • Description updated (diff)
Actions #42

Updated by Andreas Müller about 1 month ago

  • Description updated (diff)

Andreas Müller wrote:

  • name relationships => implemented -> ruleConsidered is missing

added

Actions #43

Updated by Andreas Müller about 1 month ago

Actions #44

Updated by Andreas Müller about 1 month ago

  • Description updated (diff)
Actions #45

Updated by Katja Luther 30 days ago

  • Description updated (diff)
Actions #46

Updated by Andreas Müller 24 days ago

  • Description updated (diff)
Actions #47

Updated by Andreas Müller 11 days ago

  • Description updated (diff)
Actions #48

Updated by Andreas Müller 2 days ago

  • Description updated (diff)
Actions #49

Updated by Andreas Müller about 15 hours ago

  • Description updated (diff)
Actions #50

Updated by Andreas Müller about 15 hours ago

Actions

Also available in: Atom PDF