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

Assert that DocumentSource::clone() is not overridden for stages that mongostream supports.

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 8.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Atlas Streams
    • Fully Compatible
    • Sprint 50, Sprint 51

      All the stages that mongostream supports should use the new SerializationOptions.serializeForCloning param and should not need to override DocumentSource::clone(). Such an assert will help ensure that a future code change does not break the SerializationOptions.serializeForCloning support that we rely on.

       

      Stack Overflow says something like this should work to add this assert

      if constexpr (!std::is_same_v<decltype(&Derived::foo), decltype(&Base::foo)>) {
        std::cout << "overrided" << std::endl;
      }
      

       

            Assignee:
            sandeep.dhoot@mongodb.com Sandeep Dhoot
            Reporter:
            sandeep.dhoot@mongodb.com Sandeep Dhoot
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: