You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Ryan Cornia <rc...@dced.state.ut.us> on 2001/07/09 15:48:15 UTC

SilverStream Questions...

Those of you who are using Struts-SilverStream 3.7.X, I have a couple of questions -

1.) How are you getting a connection from the connection pool? Do you use struts connection pooling, or SilverStreams? (If SilverStreams, any example code on getting a connection?) 

2.) When you deploy different applications, do you deploy them to different databases, or put them all in one? For example, I would like to have one database "webapps", that I deploy all wars into, but depending on the answer for question 1, I'm not sure if this is possible. 

Thanks,
Ryan



RE: SilverStream Questions...

Posted by Pat Ludwig <pl...@silverstream.com>.
hi Ryan,

> 1.) How are you getting a connection from the connection
> pool? Do you use struts connection pooling, or SilverStreams?
> (If SilverStreams, any example code on getting a connection?)

In apps we have built here using Struts, we get our connections from the
Silverstream connection pool. usually, we do this through a EJB session
bean. If you have a Silverstream 3.7.x release, the SilverBooks store-front
example has code which provides connections from the Silverstream connection
pool. see JDBCSessionMgr.java in package com.sssw.demo.silverbooks.data. you
can also do this without the EJB, but the session bean provides additional
benefits like transactionality, and isn't really any more difficult to code.
and using the EJB approach,  the connection to a particular database
connection pool is managed by JNDI name.

> 2.) When you deploy different applications, do you deploy
> them to different databases, or put them all in one? For
> example, I would like to have one database "webapps", that I
> deploy all wars into, but depending on the answer for
> question 1, I'm not sure if this is possible.

This is more an operational question than a technical one. There is no
technical reason why you couldn't deploy all of your apps to one database
where those apps access data from another database, but from a dependency
and management standpoint, it might be better not put all your apps together
into one database. If that database needed to be backed up or becomes
unavailable for some reason, all your applications would become unavailable
at the same time.  Successful patterns we've seen include putting the app in
the same database as the data and having the app in a separate database from
the data. it just seems that putting all your apps in one database creates a
potential single point of failure which isn't wise.
hope this helps...

regards,

Pat Ludwig
Silverstream Software



> -----Original Message-----
> From: Ryan Cornia [mailto:rcornia@dced.state.ut.us]
> Sent: Monday, July 09, 2001 9:48 AM
> To: struts-user@jakarta.apache.org
> Subject: SilverStream Questions...
>
>
> Those of you who are using Struts-SilverStream 3.7.X, I have
> a couple of questions -
>
> 1.) How are you getting a connection from the connection
> pool? Do you use struts connection pooling, or SilverStreams?
> (If SilverStreams, any example code on getting a connection?)
>
> 2.) When you deploy different applications, do you deploy
> them to different databases, or put them all in one? For
> example, I would like to have one database "webapps", that I
> deploy all wars into, but depending on the answer for
> question 1, I'm not sure if this is possible.
>
> Thanks,
> Ryan
>