Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-8663

Improve data structure layering

    XMLWordPrintable

    Details

    • Type: Technical Debt
    • Status: In Progress
    • Priority: Major - P3
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: Backlog
    • Component/s: None
    • Labels:
      None
    • Story Points:
      13
    • Sprint:
      Storage - Ra 2022-01-24

      Description

      Summary

      The goal of this spike would be to reduce the complexity of one of the large data structures in WiredTiger. It should find a set of data structure members that belong to a single subsystem, and move them somewhere more obviously associated with that subsystem. It should also make an attempt to ensure those members are only directly accessed from that subsystem.

      An example model of where this has been (sort of) done is the WT_CACHE data structure, which hangs off the WT_CONNECTION.

      Care should be taken to choose a modest and achievable change with this spike.

      A candidate might be moving the recovery specific fields from the WT_CONNECTION structure into their own data structure. Some of the fields that would be candidates for that are:

      • rec_maximum_seconds
      • recovery_ckpt_*
      • recovery_[major|minor|patch]
      • compat_[major|minor]
      • req_max_[major|minor|patch]

      As a starting point these could be pulled into a sub-data-structure WT_CONN_RECOVERY or similar. Then if it’s possible to limit where they are accessed, that data structure could be passed as a parameter to relevant functions rather than being referenced from the connection.

      Motivation

      • Does this affect any team outside of WT? No
      • How likely is it that this use case or problem will occur? N/A
      • If the problem does occur, what are the consequences and how severe are they? N/A
      • Is this issue urgent? No

      Acceptance Criteria (Definition of Done)

      At least one collection of data structure members have been moved out of one of the existing large WiredTiger data structures into a smaller sub-data-structure, and the related code refactored appropriately.

      Testing

      New tests should be created if required, and all existing WiredTiger tests should continue to pass.

      Documentation update

      TBD

       

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              will.korteland Will Korteland
              Reporter:
              jeremy.thorp Jeremy Thorp
              Collaborators:
              Andrew Morton
              Votes:
              0 Vote for this issue
              Watchers:
              8 Start watching this issue

                Dates

                Created:
                Updated: