This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Regarding Tomcat as webserver to deploy servlets adnd Weblogic to deploy ejb

 
Yogaraj Khanal
Ranch Hand
Posts: 52
Eclipse IDE Mac OS X Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am able to deploy a simple ejb application in weblogic 8.1 with the help of Weblogic builder.I want to deploy the same application using Tomcat i.e deploy servlets and jsp code here and deploy ejb in weblogic.I want to upgrade the same application to weblogic 9.1.
Plese share and multiply your knowledge.
Regards,
Yogaraj
 
Roger Chung-Wee
Ranch Hand
Posts: 1683
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I would build a WAR file and an EAR file for the client and EJB applications respectively. Each EJB which is called by the client must expose a remote interface.

You would need to include the RMI EJBHome and EJBObject stubs in the WAR file. This will enable Tomcat to use the stubs for EJB calls.
 
Yogaraj Khanal
Ranch Hand
Posts: 52
Eclipse IDE Mac OS X Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am getting this error while deploying the war in tomcat and jar in ejb.
Pls help me with this.
500 Servlet Exception

java.lang.NoSuchMethodError: org.apache.struts.action.ActionErrors.add(Ljava/lang/String;Lorg/apache/struts/action/ActionError V
at ActionBean.execute(ActionBean.java:33)
at org.apache.struts.chain.commands.servlet.ExecuteAction.execute(ExecuteAction.java:58)
at org.apache.struts.chain.commands.AbstractExecuteAction.execute(AbstractExecuteAction.java:67)
at org.apache.struts.chain.commands.ActionCommandBase.execute(ActionCommandBase.java:51)
at org.apache.commons.chain.impl.ChainBase.execute(ChainBase.java:190)
at org.apache.commons.chain.generic.LookupCommand.execute(LookupCommand.java:304)
at org.apache.commons.chain.impl.ChainBase.execute(ChainBase.java:190)
at org.apache.struts.chain.ComposableRequestProcessor.process(ComposableRequestProcessor.java:283)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1913)
at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:462)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at com.caucho.server.http.FilterChainServlet.doFilter(FilterChainServlet.java:96)
at com.caucho.server.http.Invocation.service(Invocation.java:315)
at com.caucho.server.http.CacheInvocation.service(CacheInvocation.java:135)
at com.caucho.server.http.HttpRequest.handleRequest(HttpRequest.java:253)
at com.caucho.server.http.HttpRequest.handleConnection(HttpRequest.java:171)
at com.caucho.server.TcpConnection.run(TcpConnection.java:139)
at java.lang.Thread.run(Thread.java:534)
 
Tony McClay
Ranch Hand
Posts: 33
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is this still an open question?

if it is I can look at it.

But the real reason I responded to this post, is that I thought about the issue.

A while back it was thought that separating the Servlet/JSP container from the EJB's would give better separation of processes. Which it does. This was common thinking in the Weblogic 8 time frame. Evolution/de-evolution?

But it also means that all request to the EJB Container is Serialized as well, which added a new bottleneck. In some application this was more than just a little bottleneck. It was HUGE!

We as a community rushed back to putting them in the same JVM, with some additional class loader code/magic to elegantly separate them.

If you can share more of why you are doing this, it may help better with the solution.

Generally speaking, I still use a Web Server to service Media (Pictures, movies, etc etc, and keep my Servelet Container and EJB Container in one JVM, because of the speed of not using Java Serialization.

It is still an option , which is why we have local and remote interfaces for EJB's, but the argument for using remote is tougher these days, unless there really is a good reason.

Tony
Sun Certified Web Business Component Developer
Sun Certified Web Components Developer
Sun Certified Programmer for the Java 2 Platform
 
Roger Chung-Wee
Ranch Hand
Posts: 1683
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In my company, the web and EJB apps are hosted on separate boxes (RedHat Linux I think) as there is a lot of traffic. In most cases, however, I'm sure that the best solution is to have a single app which comprises the EAR file which contains the WAR and EJB JAR files. When you know that the EJB clients are always part of the same app, then only local interfaces need to be exposed.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic