Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Agile forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

how to connect EJBs in app server From Web Server(Tomcat)

 
Chao Garreson
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
how to connect to EJBs in App Server From Web Server(Tomcat) Where Web Clients(JSP/Servlets) are located ?

What do i need to know

Thanks in Advance
 
Valentin Tanase
Ranch Hand
Posts: 704
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Chao,

In a nutshell they will use the same kind of code like your remote clients. One thing you can do is to deploy your ejbs and look in the samples that your container provides and get a remote client that connects to the server and invokes a business method on your ejb. You probably need to twist the code little bit in order to satisfy your needs, but this shouldn�t be very difficult. Once this works you can copy the code in your JSP or servlet and see how it works. What you�ll end up doing is far from being a �commercial� version of your application, but you�ll have something that will help you understanding how things work. Finally you need to do some designing work, using a service locator, data transfer objects, session fa�ade, business delegates, etc. Lot of work true, but you should remember that everything should start from having a clear understanding of the small and fundamental concepts.
Regards.
 
Chao Garreson
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi Valentin

look like some J2ee design patterns are needed to imply in designing work.so what are the APIs I need to know. can you name them? because before I really start to code, I want to get the whole picture of idea.By the way, thank you for your message.
 
jim stone
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Pick up a copy of the 'J2EE Design Patterns' book and you'll see firsthand how to fully architect what you're trying to do. Also, the SUN J2EE Tutorial is also helpful. These books will contain all the design patterns that you'll need.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic