• Post Reply Bookmark Topic Watch Topic
  • New Topic

EJB files that appear to be auto-generated

 
Bill Clar
Ranch Hand
Posts: 163
Eclipse IDE Java Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

I'm new to EJBs and they appear to have auto-generated code. I have the following classes:

WhoIsApplyingEJB.java
WhoIsApplyingEJBBean.java
WhoIsApplyingEJBHome.java

EJSLocalStatelessWhoIsApplyingEJB_fc0e15cc.java
EJSLocalStatelessWhoIsApplyingEJBHome_fc0e15cc.java
EJSLocalStatelessWhoIsApplyingEJBHomeBean_fc0e15cc.java

What procedure triggers the creation of the EJS* files? I tried googling to no avail.
 
Rob Spoor
Sheriff
Posts: 20820
68
Chrome Eclipse IDE Java Windows
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Containers usually don't return instances of your EJBs to you when you inject them, but proxy objects. That allows the container to add aspects like security and interceptors to it without you having to worry about that in your code. When you call a method, the proxy objects first do their own thing (security, interceptors, etc), then call your implementation, then possibly do some more things. This is the main reason why EJBs can't be final or have final business methods. Usually these proxies are automatically generated classes like the ones you've seen.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!