• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

One sceaj mock question

 
walter wang
Ranch Hand
Posts: 159
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Toysrfuss, a national toy store is creating a new e-front for Order processing. Customers have to create an account to transact with them, although an account is not required for browsing the catalog. Customers can browse items and add them to a shopping cart. They can then proceed to checkout. At this time, they can update quantities and submit the order. What technologies may be best suited for this application?
Choosing 4 correct answers
1) JSP for presentation and Servlets as controllers
2) Servlets for presentation and JSP as controller.
3) Stateless Session Bean for Shopping cart.
4) Stateless session bean for catalog retrieval.
5) Stateful Session bean for shopping cart.
6) Stateful session bean for Order update
7) Entity bean for Catalog retrieval.
8) Entity bean for Order update.
My choice is
1) 5) 7) 8)
but it is wrong..
anyone knows what are right answer?
 
Billy JK
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Normally at the end of the mock you should be able to review the questions/answers and see what's wrong and find the correct answer, but I'd rather discuss about why some of your answer are probably wrong.
For instance :
7) Entity bean for Catalog retrieval
The catalog is probably something huge, with a lot of products, so I think it is fair to assume that each customer will get only o very small part of it at a time, based on some selection criteria. Basically it will be a small and static view of a very limited part of the catalog, with the only possibility of picking a product at a time and adding it to the shopping cart. So the client won't modify or alter in any other way the catalog itself, it will have just a snapshot of some data. So, no transactions involving the catalog itself, no persistence to update, no concurrency between different clients to be concerned about - each one has its static, read-only list of products, eventuallly some concurrency on the product level might be useful, but not on the catalog level.
On the other hand it looks more like a service call, gimme a list of so-and-so-products, service provided by the store to actual and potential clients, service that doesn't look client related, just a short, one-time query and retrieval of the list. Hence it looks like a stateless session bean to me.
Billy
 
christy smile
Ranch Hand
Posts: 101
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I agree with Billy's opinion about choice 7, therefore, I thought the anwser is 1, 4, 5, 8
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic