Skip to content
Snippets Groups Projects

External String IDs

Merged Timm Fitschen requested to merge f-external-ids into dev
All threads resolved!

Summary

Back-end implementation for caosdb-server!78 (merged)

Focus

  • Externally used entities ids and internal ids are mapped in the new entity_ids table.
  • Internal_ids are beeing generatated by the auto_increment feature of the entities table.
  • Most of the changes have the pattern: Replace any occurrence of SELECT ... FROM entities WHERE id = ? with SELECT ... FROM entities JOIN entity_ids ON entities.id = entity_ids.internal_id WHERE entity_ids.id = ?
  • Some of the procedure now take a EntityID VARCHAR(255) instead of ÈntityID UNSIGNED INT. These belong to the public api which is used by the server. The remaining procedure where the parameter is names InternalEntityID UNSIGNED INT now, are part of the implementation.
  • There should be only one case where internal ids are being leaked into the public api, that is as replacement ids. In that case the internal ids are then being replaced by the server during the transformation from the flat property internal representation to the deep public one.
  • Some of the new procedures are just old code from the server, copied and refactored.
  • Also, some unrelated refactoring and clean-up was done.

Test Environment

No manual testing.

Check List for the Author

Please, prepare your MR for a review. Be sure to write a summary and a focus and create gitlab comments for the reviewer. They should guide the reviewer through the changes, explain your changes and also point out open questions. For further good practices have a look at our review guidelines

  • All automated tests pass
  • Reference related issues
  • Up-to-date CHANGELOG.md (or not necessary)
  • Annotations in code (Gitlab comments)
    • Intent of new code
    • Problems with old code
    • Why this implementation?

Check List for the Reviewer

  • I understand the intent of this MR
  • All automated tests pass
  • Up-to-date CHANGELOG.md (or not necessary)
  • The test environment setup works and the intended behavior is reproducible in the test environment
  • In-code documentation and comments are up-to-date.
  • Check: Are there specifications? Are they satisfied?

For further good practices have a look at our review guidelines.

Edited by Daniel Hornung

Merge request reports

Pipeline #42255 passed with warnings

Pipeline: LinkAhead

#42256

    Pipeline passed with warnings for 58e97cb0 on f-external-ids

    Merged by Timm FitschenTimm Fitschen 1 year ago (Oct 16, 2023 12:35pm UTC)

    Loading

    Pipeline #42315 passed with warnings

    Pipeline: LinkAhead

    #42319

      Pipeline passed with warnings for dd3b1d7a on dev

      Activity

      Filter activity
      • Approvals
      • Assignees & reviewers
      • Comments (from bots)
      • Comments (from users)
      • Commits & branches
      • Edits
      • Labels
      • Lock status
      • Mentions
      • Merge request status
      • Tracking
    • Timm Fitschen
    • Timm Fitschen
    • Timm Fitschen
    • Timm Fitschen
    • Timm Fitschen
    • Timm Fitschen
    • Timm Fitschen
    • Timm Fitschen
    • Timm Fitschen
    • Timm Fitschen added 2 commits

      added 2 commits

      Compare with previous version

    • Timm Fitschen marked the checklist item All automated tests pass as completed

      marked the checklist item All automated tests pass as completed

    • Timm Fitschen marked the checklist item Reference related issues as completed

      marked the checklist item Reference related issues as completed

    • Timm Fitschen marked the checklist item Up-to-date CHANGELOG.md (or not necessary) as completed

      marked the checklist item Up-to-date CHANGELOG.md (or not necessary) as completed

    • Timm Fitschen marked the checklist item Annotations in code (Gitlab comments) as completed

      marked the checklist item Annotations in code (Gitlab comments) as completed

    • Timm Fitschen requested review from @daniel

      requested review from @daniel

    • Daniel Hornung
    • Three questions remaining. Apart from that, looks good.

    • Daniel Hornung added 1 commit

      added 1 commit

      • 07c540b1 - STY: Mainly styling and typos.

      Compare with previous version

    • Daniel Hornung marked the checklist item I understand the intent of this MR as completed

      marked the checklist item I understand the intent of this MR as completed

    • Daniel Hornung marked the checklist item Up-to-date CHANGELOG.md (or not necessary) as completed

      marked the checklist item Up-to-date CHANGELOG.md (or not necessary) as completed

    • Daniel Hornung marked the checklist item The test environment setup works and the intended behavior is reproducible in the test as completed

      marked the checklist item The test environment setup works and the intended behavior is reproducible in the test as completed

    • Daniel Hornung marked the checklist item In-code documentation and comments are up-to-date. as completed

      marked the checklist item In-code documentation and comments are up-to-date. as completed

    • Timm Fitschen added 2 commits

      added 2 commits

      • 1967fa05 - MAINT: renamed registerSubdomain.sql to registerReplacementIds.sql
      • fce61eca - Merge branch 'f-external-ids' of...

      Compare with previous version

    • Timm Fitschen added 1 commit

      added 1 commit

      Compare with previous version

    • Timm Fitschen resolved all threads

      resolved all threads

    • Timm Fitschen mentioned in commit dd3b1d7a

      mentioned in commit dd3b1d7a

    • merged

    • Please register or sign in to reply
      Loading