how to define a datasource in struts?

2001-08-21 Thread Satyan Nair
Hi everyone, i m new to struts.. if anyone can tell me where to find the archive of the mailing lists then the problems already discussed won't come again and again... anyway i would like to know how to define datasource in struts... i tried using the example given with struts... but i mu

AW: cannot find the datasource in struts?

2001-08-21 Thread Hamelmann Stefan
) -Ursprüngliche Nachricht- Von: Bradley Cowen [mailto:[EMAIL PROTECTED]] Gesendet: Dienstag, 21. August 2001 01:36 An: [EMAIL PROTECTED] Betreff: RE: cannot find the datasource in struts? I can show you an example of what i'm using (MySQL): In struts-confi

RE: cannot find the datasource in struts?

2001-08-20 Thread Bradley Cowen
ublic ActionForward perform(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { Connection connection = null; DataSource dataSource = null; Stat

cannot find the datasource in struts?

2001-08-20 Thread Manish Pandya
a newbie in using struts... kindly let me know what i should be doing to define a datasource.. i have the struts-config.xml file where i defined the datasource parameters... and now i m trying to run the example provided in the struts but it is throwing error javax.sql.DataSource not found

JDBC DATASOURCE ACCESS

2001-08-16 Thread Hamelmann Stefan
Hi How do I implement a JDBC Database Access class ? Do I have to use the ActionServlet class because of the needed method "findDataSource" ? Thanks in advance Stefan

Re: How can I get the DataSource from a JSP page

2001-08-14 Thread BinhMinh Nguyen
Hi Kent, Luis, I do agree that a datasource should be in the logic layer, not in the JSP/prsentation layer, but I have a problem to populate the JSP combo box with data that is retrieved from the database when they first logn the page. And I think getting a datasource here is good enouhg :) . Do

Re: How can I get the DataSource from a JSP page

2001-08-14 Thread Luis Olivares
Why don't you put it inside a Custom Tag? That way you don't put it in the presentation layer. I think with the code sample that Craig shows us is possible. <% DataSource ds = (DataSource) application.getAttribute("org.apache.struts.action.DATA_SOURCE"); ... %

RE: How can I get the DataSource from a JSP page

2001-08-13 Thread Kent Roylance
Binh, Why would you want to get a DataSource from a JSP page? I would not recommend using a DataSource at the presentation level. Normally, you would get the data from the action class and store it in the session so that your presentation layer can use it. It is much easier that way, and a

Re: How can I get the DataSource from a JSP page

2001-08-13 Thread Craig R. McClanahan
On Mon, 13 Aug 2001, BinhMinh Nguyen wrote: > Hi, > > I know how to get a DataSource from a Action java > class > but I do not know how to obtain a DataSource from a > JSP page. > Please show me how. Doing this violates the usual separation of business logic and appli

RE: DataSource timeouts?

2001-08-05 Thread Craig R. McClanahan
On Thu, 2 Aug 2001 [EMAIL PROTECTED] wrote: > I understand that--my app does "close" connections (release back to the > pool). The problem is that the pool itself maintains open connections to > the database, and doesn't seem to recover very well when the databsae dies > and comes back. >

Re: DataSource and Factories

2001-08-05 Thread Craig R. McClanahan
epository using JNDI for use by the persistenc layer? > > That is the solution we think will work. Is this different from that? > > Thanks, > Bud > > >DataSource can be obtained either Deployment descriptor as > >"java:comp/jdbc/MyDataSource" > >(assoc

RE: DataSource timeouts?

2001-08-03 Thread VASQUEZ_JASON
2/2001 11:31 AM Please respond to struts-user To: [EMAIL PROTECTED] cc: Subject: RE: DataSource timeouts? in the documentation it says that you close the connection after you have used it... ie. conn.close(); this wont close the connection but will release it fo

RE: DataSource timeouts?

2001-08-02 Thread Satyen . Chikane
: [EMAIL PROTECTED] Subject: DataSource timeouts? Is there any parameter that can be set to timeout datasources, or to re-init them after a specified period of time? We recently bounced our Oracle database that our struts connection pool points to, and I noticed that all the connections had

DataSource timeouts?

2001-08-02 Thread VASQUEZ_JASON
Is there any parameter that can be set to timeout datasources, or to re-init them after a specified period of time? We recently bounced our Oracle database that our struts connection pool points to, and I noticed that all the connections had hung (the app just hung while trying to perform que

problem loading ActionServlet with DataSource

2001-07-30 Thread BinhMinh Nguyen
For some reason, my application cannot load ActionServlet if we use Connection Pooling using DataSource in the struts-config.xml, Please help me spot my error. Thank you. B Nguyen -- strut-config.xml: http://jakarta.apache.org/struts/dtds

AW: DataSource and Factories

2001-07-25 Thread Andreas Leitner
> Take a look to the Castor project - > http://castor.exolab.org That does indeed look awesome! Do you have experience with it? Is it ready for production use? Many thanks for that great hint! Andreas

Re: DataSource and Factories

2001-07-25 Thread Bud Gibson
solution we think will work. Is this different from that? Thanks, Bud >DataSource can be obtained either Deployment descriptor as >"java:comp/jdbc/MyDataSource" >(associate a Jndi name to the Datasource >) >

how to add property to DataSource

2001-07-25 Thread Zeltser, Mark
Hello, I am trying to add property to DataSource object. There is addProperty( String, String) method that I used but it had no affect. My impression is that all connections are initialized after ActionServlet is loaded ( I extended ActionServlet and added properties after calling super.init

Re: DataSource and Factories

2001-07-25 Thread suhas
DataSource can be obtained either Deployment descriptor as "java:comp/jdbc/MyDataSource" (associate a Jndi name to the Datasource ) - Original Message - From: Andreas Leitner <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]>; 'Aapo Laakkonen' <[EMAIL PROTECT

Re: DataSource and Factories

2001-07-25 Thread Oleg V Alexeev
AL> This pattern also comes in handy, when you have classes that inherit AL> from Person. If the DB access would happen in the constructor, one could AL> only create Person objects, with a factory, you can create an object of AL> the real type instead. AL> Anyway, what I want is to

DataSource and Factories

2001-07-25 Thread Andreas Leitner
constructor, one could only create Person objects, with a factory, you can create an object of the real type instead. Anyway, what I want is to get a DataSource without knowing about a servlet. Is this somehow possible? Is there some static access to the DataSource Repository? Tia, Andreas

Datasource doesn't load with JConnect 5.2

2001-07-17 Thread Zeltser, Mark
Hello, Did anyone encounter the following error while trying to load datasource for Sybase jconnect 5.2? How did you resolve it? Is there a property that would indicate for not checking for metadata accessor info? === 2001

Re: Problems with Database because of Datasource-Config of Struts!

2001-07-12 Thread Howie
On Thu, 12 Jul 2001, Maik Mrazovic wrote: > thanks, > > but it´s indifferent if Autocommit is "false" or "true" it does not > work with both options! > > Database is IBM DB2 7, but the reason for my problem ist the > connection-object from the datasour

Re: Problems with Database because of Datasource-Config of Struts!

2001-07-12 Thread Maik Mrazovic
thanks,   but it´s indifferent if Autocommit is "false" or "true" it does not work with both options!   Database is IBM DB2 7, but the reason for my problem ist the connection-object from the datasource-config.   regards,   Maik   - Original Message

RE: Problems with Database because of Datasource-Config of Struts!

2001-07-12 Thread Meeraj Kunnumpurath
Check your autocommit mode   Regards -Original Message-From: Maik Mrazovic [mailto:[EMAIL PROTECTED]]Sent: Thursday, July 12, 2001 1:30 PMTo: [EMAIL PROTECTED]Subject: Problems with Database because of Datasource-Config of Struts! Hello,   all parameters for a

Problems with Database because of Datasource-Config of Struts!

2001-07-12 Thread Maik Mrazovic
the Connection Object with   java.sql.Connection myConnection = null; try {  javax.sql.DataSource dataSource = this.getServlet().findDataSource(null);     if (dataSource != null)  { myConnection = dataSource.getConnection();  ... and so on

Re: Struts Datasource problem

2001-06-13 Thread Martin Cooper
this error when you try to open your connection. Hope this helps. -- Martin Cooper - Original Message - From: "Bill Clinton" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, June 13, 2001 1:47 PM Subject: Struts Datasource problem > Hello, >

Struts Datasource problem

2001-06-13 Thread Bill Clinton
Hello, I am having a recurring problem with struts and jdbc. The demo driver I am using, inet's Sprinta200, only allows 2 connections. I have my data source max set to 1, but I still get errors from the driver: java.sql.SQLException: [TDS Driver]Too many connections :3 at com.inet.tds.e.

datasource and jndi

2001-04-18 Thread Waumans, Jef
Hi, I want to use a datasource in a Struts based application but I also want to lookup this dataSource in objects that do not have an action or a servlet object in their scope, f.e. DAO's. In this case, using the struts-config.xml dataSource description doesn't seem the best of sollut

Timeout for DataSource

2001-04-09 Thread David Winterfeldt
What is the easiest way to set a timeout for a query in the struts connection pool? I'm using Oracle 8 with the native driver. David __ Do You Yahoo!? Get email at your own domain with Yahoo! Mail. http://personal.mail.yahoo.com/

SOLVED: What has changed in the DataSource part?

2001-03-30 Thread Shamdasani Nimmi-ANS004
It was a small mistake

What has changed in the DataSource part?

2001-03-30 Thread Shamdasani Nimmi-ANS004
be the DATASOURCE. I do not get an error but it seems the application is not connecting to the database. Has something changed in Datasource definition in struts-config file. This is what I have it defined as(and it works fine with 1/29/01 version): Thanks in advance -Nimmi

Re: Connection to Oracle 8i datasource

2001-03-28 Thread Donnie_Hall
I'm kind of new to struts, but I have this working. Your data source configuration in struts-config.xml looks fine. You can check your logs to make sure no errors are thrown when you start your server (I use Tomcat 3.2.1). In your code you set up datasource, as below: javax.sql.DataS

Newbie datasource Q

2001-03-28 Thread Nick Afshartous
JOEL VOGT writes: > Hopefully this is an easy question for somebody. > In my struts-config I have the datasource > > autoCommit="false" > description="Access data source config" > driverClass="sun.jdbc.od

Connection to Oracle 8i datasource

2001-03-28 Thread suresh
Hello, We at Tufan Infotech are evaluating Struts for using in our web application development. I am not able to connect to a Oracle 8i database and retrieve or update data. The datasource configuration in struts-config.xml is given below. The code snippet which tried to connect

Re: Newbie datasource Q

2001-03-27 Thread piyush raj jain
kartik! url depends on driver class used. piyush Kartik Sudarsan wrote: > i think the problem lies in your url. i have implemented datasource in my > application using datasource and this is what my url looks like > jdbc:oracle:thin:@sandstorm:1521:testdb > here sandstorm is

RE: Newbie datasource Q

2001-03-27 Thread Kartik Sudarsan
i think the problem lies in your url. i have implemented datasource in my application using datasource and this is what my url looks like jdbc:oracle:thin:@sandstorm:1521:testdb here sandstorm is the name of the machine on which the database is and testdb is the global database name i

Re: Newbie datasource Q

2001-03-27 Thread Jim Richards
What specific operation are you trying to do? Since you don't have autocommit set to true, you may be having transaction problems. I found it helpful to create a Test.java file with the same operations as creating the datasource (with the same parameters), a connection and doing a s

Newbie datasource Q

2001-03-27 Thread JOEL VOGT
Hi all, Hopefully this is an easy question for somebody. In my struts-config I have the datasource later on in a servlet I have javax.sql.DataSource dataSource = servlet.findDataSource(null); con = dataSource.getConnection(); When I try to use this however, I get an java.sql

RE: datasource - connection timeout

2001-03-16 Thread Kartik Sudarsan
PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Matthias Bauer Sent: Friday, March 16, 2001 4:45 PM To: Kartik Sudarsan Cc: [EMAIL PROTECTED] Subject: Re: datasource - connection timeout Here is the change in class GenericDataSource: I am just checking whether the connection has been closed by the

Re: datasource - connection timeout

2001-03-16 Thread Matthias Bauer
> > } > > // We have timed out awaiting an available connection > throw new SQLException > ("getConnection: Timeout awaiting connection"); > > } > Kartik Sudarsan wrote: > > hi, > i saw your posted me

Re: Question about struts application model (DataSource, Business Logic beans)

2001-03-13 Thread Ted Husted
> My problem is that > access to the DataSource is through the servlet.findDataSource() call. Struts stores the JDBC Connection pools as servlet context attributes (in JSP terms, application-scope beans). You can also access them that way. If you do not specify a name in the Struts-confi

Question about struts application model (DataSource, Business Logic beans)

2001-03-12 Thread Carles Pi-Sunyer
Title: Question about struts application model (DataSource, Business Logic beans) Hi, I'm using Struts for a new application that I'm developing. I have a question about the separation between the Action classes and the Business Logic beans. My Business Logic beans are makin

Re: Question about struts application model (DataSource, BusinessLog ic beans)

2001-03-12 Thread Craig R. McClanahan
base accesses to manipulate the > underlying data model. I am planning on using the struts db connection pool, > which is supplied through the DataSource. My problem is that access to the > DataSource is through the servlet.getDataSource() call. How do I make the > Business Logic

Re: Question about struts application model (DataSource, Business Log ic beans)

2001-03-12 Thread Michael McCallister
and your DataSource. I modeled my context object after the Servlet session API, but you could make it much more structured if you like. Second, depending on your servlet environment, create some mechanism to initialize your application context object. Using Tomcat, you could do this using

Question about struts application model (DataSource, Business Logic beans)

2001-03-12 Thread Carles Pi-Sunyer
Title: Question about struts application model (DataSource, Business Logic beans) Hi, I'm using Struts for a new application that I'm developing. I have a question about the separation between the Action classes and the Business Logic beans. My Business Logic beans are makin

Datasource proposal

2001-03-08 Thread Johan Compagner
So i propose a new interface: interface StrutsDataSource extends DataSource { open() close() setProperty(String str,String) } those property can be everything: url,driver class ect ect exactly the things that can be specified in the struts-config.xml Then the implementor must map the s

Re: Datasource serializeable (Was: 1.0 status of MessageBundle and non-serializable application resources)

2001-01-12 Thread Johan Compagner
But the problem is that i am writing a Web app at this time. And i want it to run on both environments. (A normal JSP/servlet container and a J2EE container) Because i want it to run on both environments i must just the lowest common denominator (do i say this right?) And that is using a Dataso

Re: Datasource serializeable (Was: 1.0 status of MessageBundle and non-serializable application resources)

2001-01-12 Thread Craig R. McClanahan
Johan Compagner wrote: > > As I pointed out in a subsequent message on this thread ... you > > need to avoid the use of the initialization service > > if your container requires context attributes to be serializable. > > In such cases, the app server will provide an alternative means > > (JNDI I

Datasource serializeable (Was: 1.0 status of MessageBundle and non-serializable application resources)

2001-01-12 Thread Johan Compagner
> As I pointed out in a subsequent message on this thread ... you > need to avoid the use of the initialization service > if your container requires context attributes to be serializable. > In such cases, the app server will provide an alternative means > (JNDI InitialContext) to gain access to t

Re: DataSource

2000-12-20 Thread craig mcclanahan
ed to update the README to be more explicit about this.) If you are just compiling your own classes, you should not need them, but will again at runtime (even if you do not use a DataSource in your app. Craig

DataSource

2000-12-20 Thread Sayles, Scott SAXONHQ
Pardon me if I'm missing something, but is it intended that the javax.sql.DataSource be required in the ActionServlet? It's just that I downloaded a recent build and I'm now getting errors when trying to compile my actions. They relate to javax.sql.DataSource not being found on the import. Is

DataSource question.

2000-12-17 Thread Johan Compagner
Does a datasource object always have one Driver and url for it's connections? (and the username and password can change) If so than i find that stupid, because it is possible that i must access multiple databases from my applications. And in struts i can only define one. (at this time i

<    1   2   3   4