EJB3 Entity Bean, POJO, without annotations
I develop an application where the EJB3 is used.
According to some advises got from the net, POJO classes are used as entity beans and they contain some EJB3 annotations like @Entity, @Id, @GeneratedValue, @ManyToMany etc. The application server is JBOSS.
To manage and communicate with the server side, a web GUI was created.
It communicates with server by means of EJB3 interface (@Remote).
At the moment I'm introducing a web interface (webservice) for one of a server side interfaces.
Doing this I realized, that the output parameter (an entity bean (POJO)) hardly depends on all the packages that support all the annotations stuff that is used in it.
Therefore, the web service client must be aware of them (when it uses the POJO declaration for the unmarchalling).
My question is:
How is it possible to stay in the frame of the EJB3 model (beans, persisting) and get rid of annotations in POJO?
What is (if any) the standard practice for such a case? (POJO Inheritance, XML descriptions, etc...) ?