- This topic has 3 replies, 2 voices, and was last updated 17 years, 3 months ago by Riyad Kalla.
-
AuthorPosts
-
bhammardhiMemberWe have been using Myeclipse to
1. Reverse engineer Hibernate objects [We manually select the db objects we want the tool to generate mappings and java classes for].
2. Generate Spring DAO’s for the selected Hibernate objects.We use Spring configuration file to store hibernate mappings as well.
We use a enterprise wide database and we have been noticing quiet a few changes (and oops situations) lately and we are planning to be more pro-active in finding issues that effect our development. As part of this we are planning to have nightly build process in place and are stuck with the development process we have setup right now.
To have nightly build in place we will have to or will need to be able to
1. Auto-generate the Hibernate and DAO objects at build time without user interaction.
a. Is it possible to have a list of db-objects in a properties file or xml file that can be used to generate the Hibernate and Spring DAO objects using ANT task?
b. Can we provide custom template information to the ant task so that the generated code uses our custom templates?
2. We have some db columns which are computed columns [values derived from a db function in MS SQL Server 2005]. We run an additional Java implementation on the mapping files to add update=’false’ and insert=’false’ so that are not part of the update or insert scripts generated by Hibernate at runtime. Is there a custom property or template that we can use to automate this?
3. We are not sure if we donot know how to use it or if its a limitation with the tool but the key generator information in the mapping file is not automatically generated as per the db setup. We used to use Middlegen and that tool used to get the right information. But in Myeclipse it asks for what key strategy should be used per db-object. Can we use some template that automatically finds what it should be (like what Middlegen does) and let that produce the correct key generating strategy. [We have only Identity or assigned as the posible key strategies in our enterprise db].Thank you all in advance for help.
Riyad KallaMember1a) No, MyEclipse doesn’t support this but you may find another tool that can do this in a headless mode from the command line. I don’t know of one off the top of my head though.
1b) Not applicable, because 1a is not true.
2) You can likely use a custom rev-eng strategy file to control this.
3) You mean during the rev-eng wizard you want this automatically selected for you?
bhammardhiMemberIs this a limitation in the tool — Which Myeclipse is or will be working on in the upcoming releases, or is was this delibrately done.
For organizations with nightly builds etc, this feature not being available seems to be a major limitation.
Riyad KallaMemberMyEclipse tooling is not geared towards automated nightly build processes. It *may* be something we introduce in a future release (support for something like this) but there are no plans on the books at the moment to do so.
-
AuthorPosts