File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
    Bookmark Topic Watch Topic
  • New Topic

Statelesss Session Bean Vs Java class

 
Srivastava Praveen
Greenhorn
Posts: 14
  • 0
  • Mark post as helpful
  • send pies
  • Report post to moderator
I am preparing for SCEA-Part II. In one scenario, I have sesion facade which is stateless session bean. Now I want to call another class from session facade to do the rest of task. What type of class should I create to help session facade and code rest of business logic. Should I go for statelss session bean or simple java class to code business logic? Please suggest.

Thanks
Praveen
 
Sub swamy
Ranch Hand
Posts: 121
  • 0
  • Mark post as helpful
  • send pies
  • Report post to moderator
I too have a similar question. Is there any advantage in having the business logic in POJO classes - does(or doesn't) that make the application light weight and hence perform and scale better ? Is (or isn't) it a good practice to reduce the number of EJBs?

Also, wont usage of POJO classes minimize the EJB-EJB call, yet give us the container capabilities that come with the usage of EJBs?
 
badari gururaj
Ranch Hand
Posts: 63
  • 0
  • Mark post as helpful
  • send pies
  • Report post to moderator
A few questions...this might help you decide what to do...


what are the benifits of having an EJB behind the facade layer?

Do you want to handle any transcations and security in this EJB or will you do it from facade layer?

Can you isolate your business logic into a POJO and use it as a statless service being called from the facade layer?

Is the information propagating out of POJO into another layer (Database, EIS etc)? Can this propagation be handled from the POJO in a statless manner (You mentioned scalability..do you want this layer to handle information in a stateless manner?)

Regards
Badari
 
Andrew Monkhouse
author and jackaroo
Marshal Commander
Pie
Posts: 11833
181
C++ Firefox Browser IntelliJ IDE Java Mac Oracle
  • 0
  • Mark post as helpful
  • send pies
  • Report post to moderator
Welcome to JavaRanch.

As specified in the JavaRanch SCEA FAQ:
  • What is the policy on posting questions I saw on the exam / details of how to do the assignment?



  • You may not describe or talk about the questions you saw on any of the Sun exams - see the JavaRanch Policy on Real Questions for further details. (http://www.javaranch.com/realquestions.jsp)

    For questions / discussions on the assignment, in general we will allow discussion where members are trying to understand the domain model and/or terms used in the assignment. We will also allow questions about which tools to use.

    But we will not allow discussion on a solution to the assignment (or a part of the assignment) itself.

    Refer to the thread IMPORTANT - Position on real assignment (Part 2) questions for more information.

    Normally I would remove this question, however Badari has provided generic questions that may help you in finding an answer. So I am leaving your question and his answer, but closing this topic.

    Regards, Andrew
     
    I agree. Here's the link: http://aspose.com/file-tools
      Bookmark Topic Watch Topic
    • New Topic