geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christopher Blythe" <cjblyth...@gmail.com>
Subject Re: Proposing an "SSB to JDBC" mode for Daytrader
Date Tue, 24 Oct 2006 15:05:10 GMT
I know it has been a while since this thread has been visited; however, I
finally got a chance to add a "Session Direct" mode to the DayTrader runtime
modes. Fortunately, it did not require that many changes to the source.

Here is a brief summary of the changes I made...
- Added an inSession flag to TradeDirect class. If this flag is true, we
skip the transaction management logic
- Added similar logic to the KeySequenceDirect class
- Created a new session bean (TradeJDBC) which implements the TradeServices
interface. Each service method within this session bean creates a new
instance of TradeDirect with inSession set to true
- Added two additional primitives: PingServlet2Session2JDBC and
PingServlet2Session2JDBCCollection

I tested the changes out under load without any exceptions. Just for
reference, I performed the tests on a 1 x 3.2 GHz Intel Xeon system
(connecting to a DB2 database) and noted the following results.

Direct Mode:   645 req/sec
Session Direct Mode:   119 req/sec

I have attached a patch file based off of a 10/24/2006 snapshot of
daytrader/trunk. If you have any comments, let me know. There are probably
some things in there that could be cleaned up (ie. comments, class names,
etc.), but I think this does provide a good starting point.

Thanks...

Chris

On 7/24/06, Matt Hogstrom <matt@hogstrom.org> wrote:
>
> I think this makes a lot of sense Chris.  I assume your adding a third
> runtime mode as opposed to
> removing the ejb mode?
>
> I'd like to start thinking about how to rearchitect DT ro be more
> relevant.  I'd like to include a
> Spring mode as well as update the EJBs to EJB 3.0.
>
> Any other thoughts out there?
>
> Christopher Blythe wrote:
> > The EJB and Direct modes in Daytrader provide a good measure of how a
> pure
> > EJB (Session/CMP Entity) application stacks up against a pure JDBC based
> > app. However, one of the things I have felt Trade/Daytrader has always
> > lacked is a middle ground. In my experience, I have neither seen nor
> heard
> > of a large number of customers out there in the market using the full
> EJB
> > programming model (Session and Entity beans). I think a more common
> > customer
> > usage scenario is the stateless session bean to JDBC model where the
> direct
> > JDBC calls are wrapped/managed by the SSB.
> >
> > I have already taken a quick stab at an implementation since all it
> really
> > requires is a merging of the TradeDirect and TradeBean code. I have most
> of
> > the operations working on a single client, but haven't performed any
> load
> > testing yet.
> >
> > Anyway, I wanted to submit the idea to group and see if there were any
> > comments.
> >
>



-- 
"I say never be complete, I say stop being perfect, I say let... lets
evolve, let the chips fall where they may." - Tyler Durden

Mime
View raw message