Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
  • Wellbore Domain Services Wellbore Domain Services
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 16
    • Issues 16
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
    • Requirements
  • Merge requests 9
    • Merge requests 9
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Container Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Open Subsurface Data Universe SoftwareOpen Subsurface Data Universe Software
  • Platform
  • Domain Data Management Services
  • Wellbore
  • Wellbore Domain ServicesWellbore Domain Services
  • Merge requests
  • !301

Review bulk uri

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Yannick requested to merge review_bulk_uri into master Nov 05, 2021
  • Overview 36
  • Commits 17
  • Pipelines 20
  • Changes 18

Review bulk URI to be explicit and centralized management. Especially, it's used to differentiate storage engine. A meaningless prefix constant usage were found in multiple places in the code with some confusion between bulk id and bulk URI making quite hard to follow.

This MR introduce a new class BulkURI that encapsulates encode/decoding the URI value. It contains 2 attributes:

  • bulkd id
  • storage engine version

Storage engine version encapsulates its specific prefix value used in URI value. This prefix is no longer exposed and not meant to be used directly. Storage engine version on construction, check is made explicit.

Usage examples:

    - ctor from URI string value:
        `bulk_uri = BulkURI.decode(uri_str)`

    - ctor explicit given a bulk_id and a storage version:
        `bulk_uri = BulkURI(bulk_id=bulk_id_value, version=BulkStorageVersion_V1)`

    - ctor explict using class method:
        `bulk_uri  = BulkURI.from_bulk_storage_V1(bulk_id_value)`

    - encode to URI string value:
        `uri_str: str = bulk_uri.encode()`

    - check which storage engine version is:
        `bulk_uri.storage_version == BulkStorageVersion_V0`
        `bulk_uri.is_bulk_storage_V0()`
Edited Nov 10, 2021 by Yannick
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: review_bulk_uri