Re: understanding how configs are "mavenized"
Michael Nash <[email protected]>
| Newsgroups | gmane.comp.java.keel.devel |
|---|---|
| Organization | JGlobal Limited |
| Message-ID | <[email protected]> |
Adam: I've made a start at documenting the two different "types" of Keel project when using Maven here: http://keelframework.org/release/HEAD/docbook/keel-doc/html_chunk/manual/ch13.html#d0e5918 I'm not 100% sure, but I think it may be that you've got one project trying to be "both", from what you describe. E.g. if you're writing a webapp, there's going to be an "app-xxx" module, where you have your models, your UI files, etc. This app-xxx is turned into app-xxx-version.jar and made available in your local (only) repository with a "maven jar:install". Then you've got a second project, which is where you actually put app-xxx together with the Keel services it needs. There's no code in this project, no JSP,s nothing - just a project.xml and a couple of config files (at least a keel.properties, probably a build.properties). This is where you'd do a "maven war" to assemble the finished app and create a war file. On Sun, 2005-03-13 at 12:18, Adam Rossi wrote: > I have been trying to get an existing project to play in the new > mavenized environment, but I am running into some problems, I think due > to my lack of understanding of how all the pieces now fit together. > > I am having trouble getting the following configurations to get picked > up in the war file: > > conf/client/struts/struts-config.xml - this file has my struts forwards, > which should get folded in to the consolidated struts-config.xml. For > me, only associated projects like app-crud have the forwards in the > final war file, but my project entries in this file are not getting > picked up. Where do you have your entries? They should be in conf/client... within an "app-something" module. The conf/client dir in the module where you run a "maven war" will not be used. > > conf/server/logkit.xconf, system.xconf - these files are not getting > carried over into the war file. The merged.config in the war file does > not have any of my "stuff" from these files, but the dependency apps > like app-crud are working properly. > > xdoclet persistent stuff: I had a bunch of xdoclet stuff in my java > persistent classes, which ant used to pull out and automatically > generate persist-name.xconf files, which would then get folded into the > merged file. Now with my "maven war" process, these files are not > getting created, and when I look at the persistent menu in app-crud, I > do not see my app's schema. A "maven war" will not do this - application code should always be in a module that's generated with a "maven jar", which is where the plugin will run the appropriate xdoclet/Fortress processes to extract the configuration. The config then gets included in the app-xxx-version.jar file, where it is later extracted by the "war" (actually the "uberjar") process and bundled into the uberjar for the finished application (this is true for both webapps and standalone apps) > Any guidance on how to get these configuration items to flow through to > the war would be greatly appreciated. I have read the documentation, but > I have not found the relevant section which describes the structure of > configuration. The odd thing is, I have (I think) faithfully copied the > structure and layout of other apps in CVS, such as app-crud, and > app-poll, but what is apparently working there is not working for me. I hope the above helps, I may be on the wrong page as far as what the problem is! Mike > > Regards, > > Adam > > > http://keelframework.org/documentation.shtml > Keelgroup mailing list > [email protected] > http://lists.keelframework.com/listinfo.cgi/keelgroup-keelframework.com http://keelframework.org/documentation.shtml Keelgroup mailing list [email protected] http://lists.keelframework.com/listinfo.cgi/keelgroup-keelframework.com