jakarta-cactus-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael Mattox" <mich...@idtect.com>
Subject Testing EJB local interfaces
Date Tue, 06 Aug 2002 14:47:47 GMT
I was hoping to use Cactus to unit test my EJB 2.0 local interface
entity beans.  I read on the Cactus website that Cactus supports local
interfaces, but after reading the documentation I saw a big flaw in the
current design:  This only works if the servlet engine & EJB server are
using the same JVM.  While evaluating JBuilder, I was using the tomcat
built into JBuilder but deploying EJBs to JBoss.  With this
configuration, Cactus would not work for local EJB interfaces.  But even
when using a configuration with the servlet engine and EJB server in the
same JVM, I think routing tests through a servlet is not the best
design.  I think it'd be more efficient to have a standard Java class
talk directly to an EJB Session Bean (via a remote interface), which
would in turn execute tests with local interfaces.  In fact, this
approach (a command pattern) is what most people talk about doing to
test their entity beans but I haven't found any testing tools or
frameworks that implement this.

I see on the Cactus TODO list an EJBRedirector, which I think would
solve all of these issues.  Is anybody working on this?  Once Cactus has
this feature, I think it will gain even more support for unit testing
EJBs.

Thanks,
Michael



--
To unsubscribe, e-mail:   <mailto:cactus-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:cactus-user-help@jakarta.apache.org>


Mime
View raw message