Uploaded image for project: 'Go Driver'
  1. Go Driver
  2. GODRIVER-985

Design & Implement drivergen

    XMLWordPrintable

Details

    • New Feature
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • 1.1.0
    • Core API
    • None
    • Minor Change

    Description

      The Core API prototype contained a new tool, called drivergen. This tool read in a Go type and produced an operation implementation from it. We originally chose a Go struct as an IDL with struct tags to indicate how to generate the operation.

      While this worked it was bulky and required extra fields added to the struct to indicate metadata. Additionally, the original design didn't have the driver.Operation type that handled all of the operation execution, including legacy operation execution. The results, which were not originally planned to be generated are of a known complex type, such as a driver.BatchCursor or are simple enough to generate an IDL.

      All this together means we can generate the entire operation. We should swap the Go struct IDL format for a simpler YAML IDL format, which will ensure we can define the operation and its result in a single file. This also allows us to express the necessary information without hacking around Go struct tags.

      Attachments

        Activity

          People

            kris.brandow@mongodb.com Kristofer Brandow (Inactive)
            kris.brandow@mongodb.com Kristofer Brandow (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: