Uploaded image for project: 'Spring Roo'
  1. Spring Roo
  2. ROO-2814

Stack overflow error when certain @Roo annotations exist together on a class with no fields

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Complete
    • Affects Version/s: 1.2.0.M1
    • Fix Version/s: 1.2.0.RC1
    • Component/s: @ CORE
    • Labels:
      None

      Description

      With certain combinations of Roo annotations on an empty class (no fields), such as @RooEquals and @RooDisplayName or @RooEquals and @RooToString, a stack overflow error occurs in DefaultMetadataService like the following:

      [FelixDispatchQueue] java.lang.StackOverflowError
                               at sun.nio.cs.UTF_8$Encoder.encodeLoop(UTF_8.java:447)
                               at java.nio.charset.CharsetEncoder.encode(CharsetEncoder.java:544)
                               at java.lang.StringCoding$StringEncoder.encode(StringCoding.java:240)
                               at java.lang.StringCoding.encode(StringCoding.java:272)
                               at java.lang.String.getBytes(String.java:946)
                               at java.io.UnixFileSystem.getBooleanAttributes0(Native Method)
                               at java.io.UnixFileSystem.getBooleanAttributes(UnixFileSystem.java:228)
                               at java.io.File.exists(File.java:733)
                               at org.springframework.roo.process.manager.internal.DefaultFileManager.exists(DefaultFileManager.java:67)
                               at org.springframework.roo.classpath.itd.AbstractItdMetadataProvider.get(AbstractItdMetadataProvider.java:318)
                               at org.springframework.roo.metadata.DefaultMetadataService.getInternal(DefaultMetadataService.java:149)
                               at org.springframework.roo.metadata.DefaultMetadataService.get(DefaultMetadataService.java:83)
                               at org.springframework.roo.metadata.DefaultMetadataService.get(DefaultMetadataService.java:219)
                               at org.springframework.roo.classpath.scanner.MemberDetailsScannerImpl.getMemberDetails(MemberDetailsScannerImpl.java:139)
                               at org.springframework.roo.classpath.itd.AbstractItdMetadataProvider.getMemberDetails(AbstractItdMetadataProvider.java:480)
                               at org.springframework.roo.addon.equals.EqualsMetadataProviderImpl.getMetadata(EqualsMetadataProviderImpl.java:57)
                               at org.springframework.roo.classpath.itd.AbstractItdMetadataProvider.get(AbstractItdMetadataProvider.java:326)
                               at org.springframework.roo.metadata.DefaultMetadataService.getInternal(DefaultMetadataService.java:149)
                               at org.springframework.roo.metadata.DefaultMetadataService.get(DefaultMetadataService.java:83)
                               at org.springframework.roo.metadata.DefaultMetadataService.get(DefaultMetadataService.java:219)
                               at org.springframework.roo.classpath.scanner.MemberDetailsScannerImpl.getMemberDetails(MemberDetailsScannerImpl.java:139)
                               at org.springframework.roo.classpath.itd.AbstractItdMetadataProvider.getMemberDetails(AbstractItdMetadataProvider.java:480)
                               at org.springframework.roo.addon.displayname.DisplayNameMetadataProviderImpl.getMetadata(DisplayNameMetadataProviderImpl.java:74)
                               at org.springframework.roo.classpath.itd.AbstractItdMetadataProvider.get(AbstractItdMetadataProvider.java:326)
                               at org.springframework.roo.metadata.DefaultMetadataService.getInternal(DefaultMetadataService.java:149)
                               at org.springframework.roo.metadata.DefaultMetadataService.getInternal(DefaultMetadataService.java:199)
                               at org.springframework.roo.metadata.DefaultMetadataService.getInternal(DefaultMetadataService.java:199)
                               at org.springframework.roo.metadata.DefaultMetadataService.getInternal(DefaultMetadataService.java:199)
                               at org.springframework.roo.metadata.DefaultMetadataService.getInternal(DefaultMetadataService.java:199)
                               at org.springframework.roo.metadata.DefaultMetadataService.getInternal(DefaultMetadataService.java:199)
      ...
      

        Attachments

          Activity

            People

            Assignee:
            aswan Andrew Swan
            Reporter:
            stewarta Alan Stewart
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: