Announcement Announcement Module
Collapse
No announcement yet.
@ManagedBean can only be placed on a class Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • @ManagedBean can only be placed on a class

    I'm developing an application with STS using Spring Roo. When I deploy the app in a JBoss As 7 Server, logs shows me this ERROR:

    Caused by: org.jboss.as.server.deployment.DeploymentUnitProce ssingException: @ManagedBean can only be placed on a class

    That is because the .aj files with @ManagedBean annotations (e.g. ApplicationBean_Roo_ApplicationBean.aj). I have the same problem with some Convert annotations. I thougth that JBoss should not knowing about this from a .class. If a Refactor -> Push In those files, the problem is gone, but it's not a good way to do it. Then I must to Ctrl-Z the changes. I don't want to do that.

    There is a way to fix that? Thanks a lot!

    Regards,

    Sebastian.

  • #2
    żnobody?

    The same problem for me, żnobody?

    Comment


    • #3
      Solution

      Hi!

      You must to put @ManagedBean into the java file with the Roo console active. Immediately the annotation @ManagedBean will be deleted from the .aj file

      Do the same with every annotation that troubles you.

      Regards!

      Regards!

      Originally posted by david24365 View Post
      The same problem for me, żnobody?

      Comment

      Working...
      X