Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-74894

Header includes in files generated from accumulator spec in IDL

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major - P3 Major - P3
    • None
    • None
    • None
    • Query Integration
    • ALL
    • QE 2023-03-20, QE 2023-04-03

    Description

      For the $percentile accumulator we are using an IDL spec (accumulator_percentile.idl) and we need to include 'accumulator_percentile.h' into the generated cpp file to perform some additional custom validation of the arguments. However, the generated code adds the include into 'accumulator_percentile_gen.h' rather than 'accumulator_percentile_gen.cpp' making it impossible to use types – e.g. PercentileAlgorithmTypeEnum enum – defined via the IDL, in accumulator_percentile.h.

      The reason to include into the generated header is that the purpose of the includes is likely to be the custom types for the "types" fields. So we cannot just move the include into the generated cpp file but we can add another field, something like "cpp_impl_includes" for headers that are meant to be included only into the generated cpp file.

      Attachments

        Activity

          People

            backlog-query-integration Backlog - Query Integration
            irina.yatsenko@mongodb.com Irina Yatsenko (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: