[appfuse-user] A serious problem about appfuse2 hibernate

2007-10-29 Thread Matthew Wu
In my DAO, I want to query all data from database. In Appfuse1.9.x, I write: "getHibernateTemplate().find("from DqMenu"); Now, In appfuse2.0. When execute this code there will be a error. because there is no hbm.xml in appfuse2.0 when i use "getHibernateTemplate().find("from com.bt.agora.d

Re: [appfuse-user] Problem with HIbernate Version

2007-10-29 Thread Matt Raible
Yes, you should be able to upgrade by adding a newer dependency in your pom.xml. However, you should be aware that the following issue may occur: http://issues.appfuse.org/browse/APF-853 Matt On 10/29/07, Thomas Ramapuram <[EMAIL PROTECTED]> wrote: > Hi, > I have a problem with Hibernate. A

[appfuse-user] Problem with HIbernate Version

2007-10-29 Thread Thomas Ramapuram
Hi, I have a problem with Hibernate. Actually it is a hibernate issue http://opensource.atlassian.com/projects/hibernate/browse/HHH-2572?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel I wanted to know if it is possible to change the version of Hibernate to 3.2.2 which does

Re: [appfuse-user] Problem with cssHorizontalMenu.vm

2007-10-29 Thread Thomas Ramapuram
Hi Matt. I just checked out a project and dumped my menu-config.xml and menu.jsp into it. The menus render all wacky. I just checked the cssHorizontalMenu.vm in target/work/webapp/WEB-INF/classes/cssHorizontalMenu.vm and it is the one with the patch applied. I tried testing it with pre

Re: [appfuse-user] Some mvn appfuse:gen resulting in empty pages

2007-10-29 Thread Matt Raible
At the version least, we should change from using HTML comments () to JSP comments (<%-- --%>) so the tag doesn't processed. Matt On 10/29/07, Mike McCown <[EMAIL PROTECTED]> wrote: > > Thank you both for your ideas. > > The tag generated by Appfuse is definitely the problem. What > made it int

Re: [appfuse-user] Some mvn appfuse:gen resulting in empty pages

2007-10-29 Thread Mike McCown
Thank you both for your ideas. The tag generated by Appfuse is definitely the problem. What made it interesting is that even when commented out with , it *still* causes a problem with the form! Not sure why, need to step through the form parser still. But this is why no amount of commenting o

Re: [appfuse-user] simple redirect in Struts2 from index.jsp

2007-10-29 Thread Ron Anderson
This guy has some useful info as well. http://www.vitarara.org/cms/struts_2_cookbook/post_and_redirect Ron - Original Message From: Matt Raible <[EMAIL PROTECTED]> To: users@appfuse.dev.java.net Sent: Monday, October 29, 2007 3:39:46 PM Subject: Re: [appfuse-user] simple redirect in Str

Re: [appfuse-user] simple redirect in Struts2 from index.jsp

2007-10-29 Thread Matt Raible
You could use the same thing we use in index.jsp: Matt On 10/29/07, kla <[EMAIL PROTECTED]> wrote: > > I'm assuming there's an easy equivalent for Struts2 but I can't figure it > out. I need to immediately redirect the user to my 'list' action when they > go to the index.jsp page. Is there an

[appfuse-user] simple redirect in Struts2 from index.jsp

2007-10-29 Thread kla
I'm assuming there's an easy equivalent for Struts2 but I can't figure it out. I need to immediately redirect the user to my 'list' action when they go to the index.jsp page. Is there an equivalent for the html tag's redirect in Struts2? I thought maybe would do it but it doesn't seem to work.

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread mschipperheyn
Ok, tried removing all items with appfuse:remove both in web and core and then regenerating. No joy. Generated Controller files have correct package names package xyz.webapp.controller; wrong references to the Model class import xyz.model.Barrio; should be import xyz.core.model.Barrio; and wro

Re: [appfuse-user] Sample Code for Acegi CustomAuthenticationProvider

2007-10-29 Thread Nathan Anderson
You can even leave the definition of the daoAuthenticationProvider in place, add a new definition for your customeDaoAuthenticationProvider [or whatever you call it], and then switch back and forth while testing [or if appropriate, you can use both providers]. Nathan - Original Message

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread Matt Raible
The directory structure used by "appfuse:gen" is groupId (from your root pom.xml), then packages as follows: http://appfuse.org/display/APF/FAQ#FAQ-packagenaming I suspect you might have these sub-directories because you tried running "gen" with a fully-qualified class name. The good news is 1)

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread mschipperheyn
I'm using simple names iso full qualified names. The subdir is from some model classes I have in seperate model/subdir packages. Hell, no idea where those dirs are coming from either. Dont know how the directory structure is determined for appfuse:gen. Is there any way I can backtrack this? Chee

Re: [appfuse-user] Duplicate Users in List

2007-10-29 Thread Matt Raible
On 10/29/07, George.Francis <[EMAIL PROTECTED]> wrote: > > OK, I have now iteratively added Users to a Set in UserController. > Is this really a necessary step for anyone wanting to use Hibernate in their > AppFuse app? No, it shouldn't be necessary. I remember a similar discussing happening on th

Re: [appfuse-user] Duplicate Users in List

2007-10-29 Thread George.Francis
OK, I have now iteratively added Users to a Set in UserController. Is this really a necessary step for anyone wanting to use Hibernate in their AppFuse app? syg6 wrote: > > Yep. You're using Hibernate right? Just cast the List of Users to a > LinkedHashSet in your UserController. List allows du

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread Matt Raible
On 10/29/07, mschipperheyn <[EMAIL PROTECTED]> wrote: > > This issue is actually more cumbersome than I thought b/c it affects stuff in > different directories and requires me to fix for each POJO before I run mvn > appfuse:gen again. It does look like a 'real' issue. My setup is prety > vanilla. >

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread mschipperheyn
This issue is actually more cumbersome than I thought b/c it affects stuff in different directories and requires me to fix for each POJO before I run mvn appfuse:gen again. It does look like a 'real' issue. My setup is prety vanilla. So, summarizing: Running appfuse:gen from the web dir I get: *

Re: [appfuse-user] Duplicate Users in List

2007-10-29 Thread George.Francis
Doing this cast causes the following exception to be thrown from Manage Users: org.springframework.web.util.NestedServletException: Request processing failed; nested exception is java.lang.ClassCastException: java.util.ArrayList cannot be cast to java.util.LinkedHashSet Caused by: java.lang.Class

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread Matt Raible
On 10/29/07, mschipperheyn <[EMAIL PROTECTED]> wrote: > > Noticed another small thing. > The individual sample data files in > core/target/appfuse/generated-sources/test/resources/Barrio-sample-data.xml > etc are all missing the opening key This is correct as the XML snippet will be merged into s

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread mschipperheyn
Noticed another small thing. The individual sample data files in core/target/appfuse/generated-sources/test/resources/Barrio-sample-data.xml etc are all missing the opening key Cheers, Marc mraible wrote: > > You could also disable foreign keys while DbUnit is inserting data. > Just add "ses

Re: [appfuse-user] Sample Code for Acegi CustomAuthenticationProvider

2007-10-29 Thread John Kwon
So if I implement my own CustomAuthenticationProvider, and replace the entry for the daoAuthenticationProvider with my own class, (I'm looking at the code for DaoAuthenticationProvider), I should be able to drop mine neatly in?

Re: [appfuse-user] Sample Code for Acegi CustomAuthenticationProvider

2007-10-29 Thread Nathan Anderson
The best examples I have found are in Acegi itself. http://tinyurl.com/2s42qb Nathan - Original Message - From: "John Kwon" <[EMAIL PROTECTED]> To: users@appfuse.dev.java.net Sent: Monday, October 29, 2007 12:18:41 PM (GMT-0800) America/Los_Angeles Subject: [appfuse-user] Sample Code fo

[appfuse-user] Sample Code for Acegi CustomAuthenticationProvider

2007-10-29 Thread John Kwon
I need a sample so I can see what I have to implement to make my own authentication provider to Documentum. Does anyone have a code example of a CustomAuthenticationProvider? I've Googled, and only found incomplete examples.

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread mschipperheyn
And the reference to Barrio within the Controller file is xyz.model.Barrio in stead of xyz.core.model.Barrio. Again, this maybe something I f up. Cheers, Marc mschipperheyn wrote: > > One more thing I'm noticing is the following error, may or may not have > something to do with me: > Afte

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread mschipperheyn
One more thing I'm noticing is the following error, may or may not have something to do with me: After running mvn instal in the root, then mvn appfuse:gen on Barrio, I get this issue: The created package is xyz.core.webapp.controller which should be xyz.webapp.controller which is also the package

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread mschipperheyn
I ran mvn install on the cor dir and from the web dir (following the docs), not the top level. I'm trying that now. Yeh, some things are starting to work. Ok, so you need to run mvn install at the root dir and then do mvn appfuse:gen on the web dir. Ok, got some errors running mvn install in web d

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread Michael Horwitz
Have you run mvn:install either from the top level or in your core project? Mike On 10/29/07, mschipperheyn <[EMAIL PROTECTED]> wrote: > > > Ok, noted some small issues: > 1. the sample data doesn't take into account column lenght. If you have a > column length of say 5, it will fail on mvn insta

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread Matt Raible
The first issue has been entered into JIRA and I have a fix ready to checkin. As for the error you're getting from Hibernate, I'd make sure your package name matches what's in the JAR. Also, you should only have one hibernate.cfg.xml - in core/src/main/resources. You may need to delete any other hi

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread mschipperheyn
Ok, noted some small issues: 1. the sample data doesn't take into account column lenght. If you have a column length of say 5, it will fail on mvn install 2. the sample data doesn't take references into account, you should gen the referenced POJOs first and then the POJOs with references to them.

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread Rob Hills
Hi Marc, mschipperheyn wrote: Right, ok. Hmm, getting a Caused by: org.dbunit.DatabaseUnitException: com.mysql.jdbc.exceptions.MySQLInte grityConstraintViolationException: Cannot add or update a child row: a foreign k ey constraint fails (`compraventa/barrios`, CONSTRAINT `FK4F5D3CCEB9857FF2` F

Re: [appfuse-user] Many-to-many collection problem

2007-10-29 Thread Dale Newfield
syg6 wrote: The only problem left is that when I create a new ObjectA and at the same time associate AAndBJoin objects (as opposed to first saving a new ObjectA and then editing it and associating AAndBJoin objects), the associated AAndBObjects are saved in the database with idObjectA=null, thus

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread Matt Raible
You could also disable foreign keys while DbUnit is inserting data. Just add "sessionVariables=FOREIGN_KEY_CHECKS=0" to your JDBC URL. http://raibledesigns.com/rd/entry/dbunit_tip_turn_off_foreign Matt On 10/29/07, mschipperheyn <[EMAIL PROTECTED]> wrote: > > Right, ok. Hmm, getting a > Caused b

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread mschipperheyn
Right, ok. Hmm, getting a Caused by: org.dbunit.DatabaseUnitException: com.mysql.jdbc.exceptions.MySQLInte grityConstraintViolationException: Cannot add or update a child row: a foreign k ey constraint fails (`compraventa/barrios`, CONSTRAINT `FK4F5D3CCEB9857FF2` FORE IGN KEY (`FK_CityId`) REFERE

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread Matt Raible
In the core directory, you should run "mvn install", not "mvn appfuse:install". Matt On 10/29/07, mschipperheyn <[EMAIL PROTECTED]> wrote: > > Yes, completed without fail. However, I dont see any code generated in the > core dir (I guess dont need that with universal stuff). Did see the entries >

Re: [appfuse-user] Some mvn appfuse:gen resulting in empty pages

2007-10-29 Thread Mike McCown
Thanks Matt. I've tried that (the select is actually commented out in the snippet below). I've commented out just about everything - still none of it renders. I've taken it down to just this.. __ <%@ include file="/common/taglibs.jsp"%> FOO! _ and I st

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread mschipperheyn
Yes, completed without fail. However, I dont see any code generated in the core dir (I guess dont need that with universal stuff). Did see the entries in applicationContext.xml added. Marc D:\Java\Projects\CompraVenta\core>mvn appfuse:gen [INFO] Scanning for projects... [INFO] Searching reposito

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread Matt Raible
Did you generate code in your core module and run "mvn install"? Matt On 10/29/07, mschipperheyn <[EMAIL PROTECTED]> wrote: > > You're right! Well, off course. So, now, when I run the same command from the > web directory, I get the error message that I mentioned in my initial post. > The Archive

Re: [appfuse-user] Appfuse 2.0 app that integrates with with crystal reports

2007-10-29 Thread Matt Raible
I don't know of any integration work that's been done to support Crystal Reports with Spring MVC. However, if you can integrate it with Servlets, you should be able to do that in an AppFuse project. Is there any documentation for Crystal Reports that shows how to integrate with something like Stru

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread mschipperheyn
You're right! Well, off course. So, now, when I run the same command from the web directory, I get the error message that I mentioned in my initial post. The Archive reference is actually the first element in the list of Pojos in my hibernate.cfg.xml. [INFO] Unable to load class declared as in

Re: [appfuse-user] can DBUNIT maven plugin load data from multiple files?

2007-10-29 Thread RoyPorter
ros wrote: > > Hi All! > > An isse submited to http://jira.codehaus.org/browse/MOJO-941 > > Thanks! > > ros > > I've just uploaded a patch onto the Jira issue above to implement this. -- View this message in context: http://www.nabble.com/can-DBUNIT-maven-plugin-load-data-from-multiple-

Re: [appfuse-user] populate doesn't seem to work

2007-10-29 Thread mschipperheyn
Ok, that didn't work either. I'll just go with hard coding for now. Cheers, Marc mschipperheyn wrote: > > Ok, following the manual I thought it had to go into the same directory as > the actual test class. So, I need to do something like > test/resources//UserDaoTest.properties. > > Cheers,

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread Matt Raible
You should use the simple name of your class, not the fully-quallified name. In your case, you should use "Barr". Matt On 10/29/07, mschipperheyn <[EMAIL PROTECTED]> wrote: > > So, the above error occurs when I run appfuse:gen from the web dir. WhenI run > it from the core dir, I get this error:

Re: [appfuse-user] populate doesn't seem to work

2007-10-29 Thread mschipperheyn
Ok, following the manual I thought it had to go into the same directory as the actual test class. So, I need to do something like test/resources//UserDaoTest.properties. Cheers, Marc Mike Horwitz wrote: > > Are you using AppFuse 2.00? If so the properties file should go in a > matching direc

Re: [appfuse-user] app:gen Unable to load class declared as mapping class="xyz" in the configuration

2007-10-29 Thread mschipperheyn
So, the above error occurs when I run appfuse:gen from the web dir. WhenI run it from the core dir, I get this error: What is the name of your pojo (i.e. Person)?: nl.msw.compraventa.core.model.Barr io [INFO] Configuration XML file loaded: D:\Java\Projects\CompraVenta\core\src\main \resources\hib

Re: [appfuse-user] Some mvn appfuse:gen resulting in empty pages

2007-10-29 Thread Rob Hills
Hi All, On 29 Oct 2007 at 8:18, Matt Raible wrote: > In your creditcardForm.jsp, I'd try deleting parts of it until you get > a better error message. You might start by deleting the as > that could be causing issues. I don't know if it's the same for you Mike, but I have found a number of my j

Re: [appfuse-user] Some mvn appfuse:gen resulting in empty pages

2007-10-29 Thread Matt Raible
In your creditcardForm.jsp, I'd try deleting parts of it until you get a better error message. You might start by deleting the as that could be causing issues. Matt On 10/28/07, Mike McCown <[EMAIL PROTECTED]> wrote: > > I took a number of annotated entity files from another project and put them

Re: [appfuse-user] How to get labels and fields side-by-side

2007-10-29 Thread Rob Hills
Hi Roy, Thanks for the reply. On 29 Oct 2007 at 7:20, RoyPorter wrote: > I had a similar issue, although with 2.0M5 > > You should have something similar to this in your struts.xml > > Yes, I do, though mine is set to "css_xhtml" and that was the root of my confusion. According to my

Re: [appfuse-user] How to get labels and fields side-by-side

2007-10-29 Thread RoyPorter
I had a similar issue, although with 2.0M5 You should have something similar to this in your struts.xml If it still isn't working, you may need to do as I did and copy the template directory out of the struts jar, and have it under you webapp directory. At the time I put this down to App

Re: [appfuse-user] Data Access Failure

2007-10-29 Thread Daniel Kibler
Mike Yes - I should have mentioned I'm using Struts2 - Spring - Hibernate. But, I had already deleted those files. I couldn't even start Jetty before doing that. Thanks Dan Mike Horwitz wrote: > > Which web stack are you using? If it is Struts, please make sure you > delete > the copy of W

[appfuse-user] problem displaying many2one / one2many relations

2007-10-29 Thread g.assies
Hi, I've been playing with appfuse 2.0, here's what i've done so far I've run the basic appfuse with spring MVC archetype and hibernate as my orm I've added a Team pojo, and the manager/controller/tests/master, detail jsp's i've enabled the OpenSessionInView filter (without it i got a session

[appfuse-user] Design by Contract with Spring or AppFuse

2007-10-29 Thread Joachim Ansorg
Hi, I'm quite new to Appfuse and Spring. And I'm currently thinking about to use Design By Contract for the software I'm working on. Is there any stable and usable integration of a DbC framework in Spring or Appfuse available? I'd be glad for some advice or opinions about this topic. Thanks,

Re: [appfuse-user] Many-to-many collection problem

2007-10-29 Thread syg6
Using DELETE_ORPHAN did the trick, thanks very much! The only problem left is that when I create a new ObjectA and at the same time associate AAndBJoin objects (as opposed to first saving a new ObjectA and then editing it and associating AAndBJoin objects), the associated AAndBObjects are saved i

Re: [appfuse-user] Data Access Failure

2007-10-29 Thread Michael Horwitz
Which web stack are you using? If it is Struts, please make sure you delete the copy of WEB-INF/classes/struts.xml and the contents of the WEB-INF/lib directory under the source tree. Mike. On 10/28/07, Daniel Kibler <[EMAIL PROTECTED]> wrote: > > > My application was working fine until I ran mv