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

Stop unconditionally throwing an error when a text search language is unsupported

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Minor - P4
    • Resolution: Unresolved
    • Affects Version/s: 4.0.3
    • Fix Version/s: Backlog
    • Component/s: Text Search
    • Labels:
    • Sprint:
      Query 2020-06-01

      Description

      Context: https://stackoverflow.com/questions/61418548

      I receive language codes from twitch.tv, and store in mongodb. I'd like to utilize text search on supported languages. For unsupported languages, I'd like mongo to just ignore it, instead of throwing an error. This way, I can use one field to store the language code.

      Currently, it seems like I have to detect if mongo supports a lang, if not, I have to store it in another field. So now every document requires 2 fields, `language` for supported langs, and `language2` for unsupported langs. This is an ugly hack and I'd like a better solution.

        Attachments

          Activity

            People

            Assignee:
            backlog-query-execution Backlog - Query Execution
            Reporter:
            guanzo91@gmail.com Eric Guan
            Participants:
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated: