Skip to content
GitLab
  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • Genesys Backend Genesys Backend
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 26
    • Issues 26
    • List
    • Boards
    • Service Desk
    • Milestones
  • Deployments
    • Deployments
    • Releases
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Genesys PGR
  • Genesys BackendGenesys Backend
  • Issues
  • #358
Closed
Open
Created Oct 04, 2018 by Matija Obreza@mobrezaOwner

Linking subsets and datasets with accessions

Dataset currently uses a list of AccessionIdentifier records to specify which accessions (by instcode, accenumb, genus or doi) are referenced in the dataset.

Subset, on the other hand, uses a list of AccessionId so that even if the accession is deleted from Genesys (and is removed from Accession and added to AccessionHistoric) the subset still maintains the reference to the original record. This was a good idea originally, but it fails in the case where an accession is reuploaded to Genesys -- Subset will not link to the correct record anymore.

Properly referencing accessions

  • Rename and move org.genesys.catalog.model.dataset.AccessionIdentifier to org.genesys2.server.model.genesys.AccessionRef.
  • Change private AccessionId accession to private Accession accession
  • We can now use AccessionFilter in DatasetFilter!

Serialization

Serialize property accession of AccessionRef as @JsonUnwrapped. This will embed all key data from Accession into this object (hope that works).

AspectJ

  • When an accession is deleted from Accession (table accession) the code should update all AccessionRef#accession to null.
  • When an accession is saved to Accession (table accession) the code should update AccessionRef#accession where a match is found.

Subset update

Replace private List<AccessionId> accessions with private List<AccessionRef> accessions.

This allows us to have Subsets that "reference" an accession that does not have passport data in Genesys, but it will in the future. It also allows users to delete an accession (rarely) and re-upload it to the system.

Liquibase

  • Rename inverseJoinColumns = @JoinColumn(name = "acce_id") to a_id.
  • Migrate all existing data
Edited Oct 04, 2018 by Matija Obreza
Assignee
Assign to
Time tracking