Uploaded image for project: 'OpenDJ'
  1. OpenDJ
  2. OPENDJ-2896

Remove Schema parameter from Indexer.createKeys()

    Details

    • Type: Task
    • Status: Dev backlog
    • Priority: Blocker
    • Resolution: Unresolved
    • Affects Version/s: 4.0.0, 3.5.0
    • Fix Version/s: 7.1.0
    • Component/s: core apis, tech-debt
    • Labels:
      None

      Description

      While reviewing PR 356:

      Since a MatchingRule / Syntax / etc are associated with a single Schema instance I don't think it is correct for client code to pass in the schema to methods like valueIsAcceptable(), since it opens up the possibility for client code to pass in a different Schema instance.

      Unfortunately, the method Indexer.createKeys() violates this principle by requiring client code to pass in the Schema as a parameter. The MatchingRuleImpl should create the Indexer with the Schema. In other words the method MatchingRuleImpl.createIndexers() should have a Schema parameter, rather than it being passed in with each call to Indexer.createKeys().

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                matthew Matthew Swift
                Reporter:
                matthew Matthew Swift
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated: