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

[SBE] Allow ^@ to be used as a $split delimiter with collation and runtime computing, and re-enable $split

    • Type: Icon: Task Task
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Execution

      In BF-22757, a fuzzer test failed when SBE was on, with the aggregation:

      [{$project: {"a": {$split: ["$b", "^@"]}}}]

      the collation:

      {collation: {locale: 'el'}}

      in the AggregationOptionsList, and any document, such as:

      {_id: 1, "b": "c"}

      The error it fails with is "$split delimiter must not be an empty string", but "^@" is not an empty string; it is the null character. This passes in the classic engine, and even passes with SBE without the collation or without runtime computing (it does not fail if "$b" is replaced with "c"; but it does fail if "^@" is replaced with $delimiter and computed to "^@" at runtime, so there just needs to be some runtime computing happening.)

      The error doesn't reproduce in the shell, so the easiest way to reproduce is to download the original failing fuzzer test from the BF and simplify the aggregation, aggregationOptionsList, and document list to just the simplified ones specified.

      We need to investigate why it fails in this specific edge case and ensure SBE allows "^@" as a delimiter in all cases.

      Additionally, as a temporary fix, I've marked $split as not SBE compatible in SERVER-60359. Once this is fixed, we should mark it as SBE-compatible again as part of this ticket.

            Assignee:
            backlog-query-execution [DO NOT USE] Backlog - Query Execution
            Reporter:
            jennifer.peshansky@mongodb.com Jennifer Peshansky (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated: