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

Consider updating error message when $$USER_ROLES is used with enableAccessUserRoles=false

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

      When the server is started up with enableAccessToUserRoles=false, any queries using the $$USER_ROLES builtin variable will fail. The error message today simply states:

      Builtin variable $$USER_ROLES is not available
      

      This is the default error message reported when any variable is used in an aggregation.

      We could update that error message to say something like

      Builtin variable $$USER_ROLES is not available since the server is not configured to accept it
      

      This would provide some extra context as to why $$USER_ROLES is unavailable. 

            Assignee:
            Unassigned Unassigned
            Reporter:
            varun.ravichandran@mongodb.com Varun Ravichandran
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              None
              None
              None
              None