Uploaded image for project: 'Calcite'
  1. Calcite
  2. CALCITE-2594

Ensure forbiddenapis and maven-compiler use the correct JDK version

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • avatica-1.13.0, 1.18.0
    • avatica, core
    • None

    Description

      I was looking at the build logs the other day for Avatica and noticed the following:

      [INFO] --- forbiddenapis:2.6:testCheck (default) @ avatica-core ---
      [INFO] Scanning for classes to check...
      [INFO] Reading bundled API signatures: jdk-unsafe-1.7
      [INFO] Reading bundled API signatures: jdk-deprecated-1.7

      The 1.7 being the JDK version that forbiddenapis is picking up for the signatures. I double checked that we were setting the compiler to use JDK 8 and moved on.

      Today I was looking at the ASF POM for a different project and noticed:

      <maven.compiler.source>1.7</maven.compiler.source>
      <maven.compiler.target>1.7</maven.compiler.target>
      

      I double checked the forbiddenapis docs and those two properties are used to determine the correct signatures.

      This Jira is to override the base ASF POM properties in the top level pom to be the following:

      <maven.compiler.source>8</maven.compiler.source>
      <maven.compiler.target>8</maven.compiler.target>
      

      After making that change locally I can see forbiddenapis picking up the correct signatures.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            krisden Kevin Risden
            krisden Kevin Risden
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment