Uploaded image for project: 'Java Driver'
  1. Java Driver
  2. JAVA-5291

Use Gradle version catalogs to declare dependencies

    • Type: Icon: Improvement Improvement
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Build
    • None
    • Hide

      1. What would you like to communicate to the user about this feature?
      2. Would you like the user to see examples of the syntax and/or executable code and its output?
      3. Which versions of the driver/connector does this apply to?

      Show
      1. What would you like to communicate to the user about this feature? 2. Would you like the user to see examples of the syntax and/or executable code and its output? 3. Which versions of the driver/connector does this apply to?

      A version catalog is a list of dependencies, represented as dependency coordinates, that a user can pick from when declaring dependencies in a build script.

      The Gradle documentation is here: https://docs.gradle.org/7.3/userguide/platforms.html#sub:version-catalog-declaration

      It has a number of nice properties, but the main one is that tools like Dependabot require its use in order to report on Gradle projects.  See here: https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file#gradle

      POC here: https://github.com/jyemin/mongo-java-driver/commit/cc7d040afece1b58d24b9684deb929be2ed030b7

      Note that in Gradle 7.3 it's still in preview, so the feature has to be explicitly enabled.

       
       

            Assignee:
            Unassigned Unassigned
            Reporter:
            jeff.yemin@mongodb.com Jeffrey Yemin
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: