Re: Session persistence and initialization

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Tue Mar 07 2006 - 06:52:14 EST

  • Next message: Paul Furbacher: "Re: DbGenerator"

    So from your earlier message:

    > Finally, coming back to configuration/initialization, I'm going to
    > remake my question: I want to access two databases from the same
    > DataContext, when I keep all connection information in the
    > Node.driver.xml files I can do it, so it is possible, however if I
    > want to set the node parameters by code, how should I initialize
    > the Configuration instance?

    >> I have moved login and password from the node file to the
    >> initialization java code.

    If the JNDI option doesn't work for you, you can implement
    org.objectstyle.cayenne.conf.DataSourceFactory interface yourself and
    enter the name of such custom class in the Modeler. The number of
    DataNodes shouldn't make a difference - this is a per-node
    configuration.

    > I will consider to migrate our applications to 1.2, now we are with
    > 1.1. Do you consider 1.2M11 suitable for production? If you don't,
    > when is an stable 1.2 release expected?

    I'd say the quality of the old features available in 1.1 is not
    compromised. However if you use the new stuff, you may have to watch
    the release notes when you upgrade between the milestones as we make
    no guarantees that they will not change until Beta. Whether this is
    appropriate in your case is your call ;-)

    Cheers

    Andrus

    On Mar 7, 2006, at 2:28 PM, Oscar Maire-Richard wrote:

    > Thanks for your answer,
    >
    > I don't plan to use JNDI DataSource because is the same to have the
    > passwords in Cayenne's files that in Tomcat's files. What I want is
    > to keep our client away the database but being able to access the
    > server's file system.
    >
    > I will consider to migrate our applications to 1.2, now we are with
    > 1.1. Do you consider 1.2M11 suitable for production? If you don't,
    > when is an stable 1.2 release expected?
    >
    > Finally, coming back to configuration/initialization, I'm going to
    > remake my question: I want to access two databases from the same
    > DataContext, when I keep all connection information in the
    > Node.driver.xml files I can do it, so it is possible, however if I
    > want to set the node parameters by code, how should I initialize
    > the Configuration instance?
    >
    > Regards,
    >
    > Oscar



    This archive was generated by hypermail 2.0.0 : Tue Mar 07 2006 - 06:52:17 EST