OpenJPA
  1. OpenJPA
  2. OPENJPA-2025

Byte[] and Char[] should be treated as SingularAttributes, not lists by the metamodel generator

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.1.0
    • Fix Version/s: 2.2.0
    • Component/s: tooling
    • Labels:
      None

      Description

      Per discussion on the mailing list, the generated metamodel code treats all arrays as persistent collections. This does not make sense for byte[] or char[], but has merit for other types.

        Issue Links

          Activity

          Hide
          Jody Grassel added a comment -

          Add this to the javac command: -Aopenjpa.Compatibility=UseListAttributeForArrays=

          {true or false}

          , ie.

          -Aopenjpa.Compatibility=UseListAttributeForArrays=false

          Show
          Jody Grassel added a comment - Add this to the javac command: -Aopenjpa.Compatibility=UseListAttributeForArrays= {true or false} , ie. -Aopenjpa.Compatibility=UseListAttributeForArrays=false
          Hide
          Heath Thomann added a comment -

          Hi Joe! Thanks much for the Compatibility option to enable the code in AnnotationProcessor6. As a user, how do I make use of this new option and the code gated by it?

          Thanks,

          Heath

          Show
          Heath Thomann added a comment - Hi Joe! Thanks much for the Compatibility option to enable the code in AnnotationProcessor6. As a user, how do I make use of this new option and the code gated by it? Thanks, Heath
          Hide
          ASF subversion and git services added a comment -

          Commit 1497841 from Jody Grassel
          [ https://svn.apache.org/r1497841 ]

          OPENJPA-2025: Add Compatibility option to AnnotationProcessor6 tool so that the default generated class can be processed cleanly by the default runtime processor

          Show
          ASF subversion and git services added a comment - Commit 1497841 from Jody Grassel [ https://svn.apache.org/r1497841 ] OPENJPA-2025 : Add Compatibility option to AnnotationProcessor6 tool so that the default generated class can be processed cleanly by the default runtime processor
          Hide
          ASF subversion and git services added a comment -

          Commit 1469097 from hthomann
          [ https://svn.apache.org/r1469097 ]

          OPENJPA-2025: Byte[] and Char[] should be treated as SingularAttributes, not lists by the metamodel generator - merged Mike Dick's trunk changes to 2.1.x

          Show
          ASF subversion and git services added a comment - Commit 1469097 from hthomann [ https://svn.apache.org/r1469097 ] OPENJPA-2025 : Byte[] and Char[] should be treated as SingularAttributes, not lists by the metamodel generator - merged Mike Dick's trunk changes to 2.1.x
          Hide
          Kevin Sutter added a comment -

          As a reference, the mailing list discussion that created this JIRA is documented here:
          http://openjpa.208410.n2.nabble.com/Metamodel-generates-ListAttribute-for-arrays-instead-of-SingularAttribute-tc6529049.html

          Show
          Kevin Sutter added a comment - As a reference, the mailing list discussion that created this JIRA is documented here: http://openjpa.208410.n2.nabble.com/Metamodel-generates-ListAttribute-for-arrays-instead-of-SingularAttribute-tc6529049.html
          Hide
          Pinaki Poddar added a comment -

          Neat. I thought it would be more complex

          Show
          Pinaki Poddar added a comment - Neat. I thought it would be more complex

            People

            • Assignee:
              Michael Dick
              Reporter:
              Michael Dick
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development