Move explicit resource management into the driver's main export from the`lib/beta` export

    • Type: Task
    • Resolution: Unresolved
    • Priority: Unknown
    • None
    • Affects Version/s: None
    • Component/s: None
    • 3
    • Not Needed
    • None
    • Hide

      Create a copy of the Kickoff Template with the issue key (NODE-XXX) in the filename and share a link to the new doc via this field.

      Show
      Create a copy of the Kickoff Template with the issue key (NODE-XXX) in the filename and share a link to the new doc via this field.
    • Not Needed
    • Hide

      1. What would you like to communicate to the user about this feature?
      2. Would you like the user to see examples of the syntax and/or executable code and its output?
      3. Which versions of the driver/connector does this apply to?

      Show
      1. What would you like to communicate to the user about this feature? 2. Would you like the user to see examples of the syntax and/or executable code and its output? 3. Which versions of the driver/connector does this apply to?
    • None
    • None
    • None
    • None
    • None
    • None

      Use Case

      As a driver user using explicit resource management,
      I want to easily access this feature,
      So that I can use explicit resource management easily.

      As a driver engineer developing on Node 20+,
      I want to support explicit resource management in the driver without a special export,
      So that explicit resource management is easier to use and easier to support.

      User Experience

      • Users will be able to use explicit resource management without any special imports.

      Dependencies

      • Our minimum supported Node version must define `Symbol.asyncDispose` natively (this is present in Node20+).

      Risks/Unknowns

      • n/a

      Acceptance Criteria

      Implementation Requirements

      • Remove resource_management.ts
        • Remove the TS interfaces - these are now included in Node types
        • Remove the `configureExplicitResourceManagement` function - instead, define `asyncDispose` methods directly on each class.
        • Ensure that the asyncDispose methods are experimental.
      • Remove API extractor configuration that generates the beta namespace.
      • Remove `beta.ts`
      • Remove the explicit resource management tests that test Node versions without `Symbol.dispose` defined.

      Testing Requirements

      • Ensure all tests continue to pass.

      Documentation Requirements

      • Release note

      Follow Up Requirements

      • n/a

            Assignee:
            Bailey Pearson
            Reporter:
            Bailey Pearson
            Durran Jordan
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: