ashish shrivastava wrote:
Can you elaborate
have your tasks set the connection by setting a resource
getProject().setResource("my.task.-secret-jdbc-resource",jdbcConnection);
then let them fetch it later
JDBCConnection conn=(JDBCConnection)
getProject().getResource("my.task.-secret-jdbc-resource);
the connection will last until the project goes away. This could be a
bit long to hold a connection open, incidentally.
By using spaces in the resource name, you shou
On 6/12/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
Only some thoughts ....
- datatypes support id/refid and are registered on the project
http://svn.apache.org/repos/asf/ant/core/trunk/src/main/org/apache/tools/ant/types/
http://svn.apache.org/repos/asf/ant/core/trunk/src/main/org/apache/tools/ant/types/DataType.java
Jan
>-----Ursprüngliche Nachricht-----
>Von: ashish shrivastava [mailto:[EMAIL PROTECTED]
>Gesendet: Montag, 12. Juni 2006 09:10
>An: user@ant.apache.org
>Betreff: How to share a database connection between Tasks in ANT?
>
>I have a set of Tasks all requiring access to the very same
>class instance (a db connection in practice). How can I
>implement that with ANT?
>
> So far, I have tried to implement this behaviour via a
>TaskContainer but I can't get back the TaskContainer instance
>from a Task, and hence the reference to the object I would
>like to share via the TaskContainer, as far as the
>TaskContainer and the Tasks are loaded in separate class loaders.
>
>I am converting a java based deploytool to ANT deployment
>process.Theexisiting deploytool creates a connection pool and
>then uses it subsequently to perform any database operation.I
>am trying to implement the same.myimpression of SQL Task in
>ANT is that i need to create a new connection each time for
>performing DB operation.
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]