Uploaded image for project: 'Spring Data MongoDB'
  1. Spring Data MongoDB
  2. DATAMONGO-456

XSD incorrectly states the default value for the mongo-ref attribute of the mongo:db-factory configuration element

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: 1.0.1, 1.1 M1
    • Fix Version/s: 1.1 GA
    • Component/s: Documentation
    • Labels:

      Description

      There is a disconnect between the full Spring Mongo documentation and spring-mongo-1.0.xsd (also spring-mongo-1.1.xsd.) Essentially, the XSD says that when declaring a <mongo:db-factory> element, the default value for the mongo-ref attribute is mongo, implying that if you declare no mongo-ref attribute, the configuration will reference any existing <mongo:mongo /> element for further configuration of mongo. However, that is not the case. As the full documentation states, you must declare this mongo-ref if you want to use another mongo instance (with advanced options for example) instead of the one configured by <mongo:db-factory />.

      tl;dr - The XSD description of the db-factory element should be changed from "The reference to a Mongo. Will default to mongo." to something more accurate, such as "The reference to a Mongo. Set this value if you need to create a more advanced Mongo beyond the capabilities of the db-factory element." =)

        Attachments

          Activity

            People

            Assignee:
            olivergierke Oliver Drotbohm
            Reporter:
            kungfuters Matt Senter
            Last updater:
            Spring Issues Spring Issues
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: