Re: Ant task to generate datamap.map.xml from database?

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Thu Nov 13 2003 - 11:00:36 EST

  • Next message: Andrus Adamchik: "Re: Equivalent for WebObjects localInstanceOfObject() or Toplink registerExistingObject()?"

    Hi Mark,

    At present I am not aware of such task written by anyone, so if you
    start on it, your effort won't be wasted (and we will gladly accept it
    in Cayenne if you are willing to donate it). It shouldn't be too hard
    to write it, since all the wiring is already there. All that is needed
    is to put Ant interface on it. Take a look at DbLoader and
    DbLoaderDelegate:

    http://objectstyle.org/cayenne/api/cayenne/org/objectstyle/cayenne/
    access/DbLoader.html
    http://objectstyle.org/cayenne/api/cayenne/org/objectstyle/cayenne/
    access/DbLoaderDelegate.html

    As for the Ant interface, the most obvious way would be to configure
    connection info via the task bindings. But I can see a few ways to make
    it more user friendly. E.g. create a partial Cayenne project in the
    modeler, with a DataNode in it containing all connection info, and
    update its DataMaps dynamically in this project via Ant. You can likely
    leverage some of the "cdeploy" task logic for that:

    http://objectstyle.org/cayenne/userguide/deploy/cdeploy.html

    Hope this will help you to get started.

    Cheers
    Andrus

    On Nov 13, 2003, at 4:37 AM, Mark Evenson wrote:

    > Does anyone have an Ant task to generate datamap.map.xml from a
    > database?
    >
    > Our group is using a modeler other than Cayenne (Sybase PowerDesigner)
    > to
    > create the database schema from which we then reverse engineer via the
    > Cayenne Modeler GUI to create the associated datamaps. We would like
    > to
    > automate the process via an Ant task, to shorten our design/test cycle
    > as
    > much as possible.
    >
    > It doesn't look like such a task exists in cayenne-src-1.0.2, so I
    > thought
    > I would ask the list if anyone had such a task (or the rudimentary
    > beginnings of one) floating around somewhere?
    >
    > Would there be any major architectural problems in implementing such a
    > task
    > that I should be advised of before slogging off to create such an item?
    >
    >
    > --
    > Mark Evenson <evenso..anix.com>
    >
    > "A screaming comes across the sky. It has happened before, but there
    > is
    > nothing to compare to it now."
    >
    >



    This archive was generated by hypermail 2.0.0 : Thu Nov 13 2003 - 11:00:42 EST