Refactor BSONCollectionCatalogEntry::MetaData to encapsulate the logic for correctly loading the timeseries flag.

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Catalog and Routing
    • 1
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      In SERVER-93213 the setting of metadata within CollectionImpl for 2 timeseries flag has been encapsulated within a helper so that are always set correctly. As a consequence, setting _metadata without that helper may result in catalog inconsistencies.

      The current implementation makes the responsibility spread over multiple classes and harder to reason. We should provide a better API to avoid developers to introduce bugs, for example by encapsulating _metadata in an internal class only exposing setters and getters.

      The class should also encapsulate the logic on how to set those 2 flags on both the constructor and the parser

              Assignee:
              Unassigned
              Reporter:
              Enrico Golfieri
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated: