Uploaded image for project: 'Apache MADlib'
  1. Apache MADlib
  2. MADLIB-852

C++ AL does not support std::vector in HAWQ

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:

      Description

      Reproducible by calling .push_back() in a UDF with C++ DBAL.
      Insert these lines of code into any C++ UDF and call it in HAWQ. We should see the database crashes before "3" is printed while "2" is printed.

          {   
              warning("0");
              std::vector<int> a;                                                                          
              warning("1");
              a.push_back(1);                                                                              
              warning("2");                                                                                
          }   
          warning("3");
      

      It crashes the database when destructor of std::vector is called.

      We encountered this when writing display function for decision trees, worked around by using ArrayHandle<text *>.

        Attachments

          Activity

            People

            • Assignee:
              riyer Rahul Iyer
              Reporter:
              haying Xixuan (Aaron) Feng
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated: