Return-Path: Delivered-To: apmail-geronimo-xbean-dev-archive@minotaur.apache.org Received: (qmail 28813 invoked from network); 25 Jul 2010 19:44:14 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 25 Jul 2010 19:44:14 -0000 Received: (qmail 69884 invoked by uid 500); 25 Jul 2010 19:44:14 -0000 Delivered-To: apmail-geronimo-xbean-dev-archive@geronimo.apache.org Received: (qmail 69835 invoked by uid 500); 25 Jul 2010 19:44:14 -0000 Mailing-List: contact xbean-dev-help@geronimo.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: xbean-dev@geronimo.apache.org Delivered-To: mailing list xbean-dev@geronimo.apache.org Received: (qmail 69827 invoked by uid 99); 25 Jul 2010 19:44:14 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 25 Jul 2010 19:44:14 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 25 Jul 2010 19:44:11 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id o6PJhneP011408 for ; Sun, 25 Jul 2010 19:43:50 GMT Message-ID: <9931578.575561280087029843.JavaMail.jira@thor> Date: Sun, 25 Jul 2010 15:43:49 -0400 (EDT) From: "Ryan Moquin (JIRA)" To: xbean-dev@geronimo.apache.org Subject: [jira] Updated: (XBEAN-151) Xbean-Spring is "incompatible" with Spring Framework 3.0.x In-Reply-To: <33208489.575421280085709942.JavaMail.jira@thor> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/XBEAN-151?page=3Dcom.atlassian= .jira.plugin.system.issuetabpanels:all-tabpanel ] Ryan Moquin updated XBEAN-151: ------------------------------ Attachment: ResourceXmlApplicationContext.java ClassPathXmlApplicationContext.java It's easy enough to just add the method to the two source files to see that= it fixes the issue, but just for covenience, here are the two files I modi= fied that include the method to turn of validation which makes the unit tes= ts pass. > Xbean-Spring is "incompatible" with Spring Framework 3.0.x > ---------------------------------------------------------- > > Key: XBEAN-151 > URL: https://issues.apache.org/jira/browse/XBEAN-151 > Project: XBean > Issue Type: Bug > Components: spring > Environment: Any > Reporter: Ryan Moquin > Attachments: ClassPathXmlApplicationContext.java, org.apache.xbea= n.spring.context.RestaurantUsingXBeanTest.txt, ResourceXmlApplicationContex= t.java > > > A lot of people have complained about this but haven't opened an issue fo= r it. I've investigate it a bit and really it's not that xbean-spring is t= ruly incompatible, it's that everyone (including the spring-xbean unit test= s) creates xbean-spring configurations that assume Spring validation is tur= ned off. This means that an xbean-spring configuration will fail to load w= ithout the schemaLocation defined with all custom namespaces. This can get= a little tricky with xbean-spring syntax since when you add the appropriat= e schemas for validation, the xbean-configuration will fail to validate eve= n though the configuration loads and operates correctly at runtime. I've f= ound a few constructs I've used to be tough to figure out how to get to val= idate in order to run with Spring 3.0.x. The easiest solution to deal with= this is to something turn off the default validation in Spring 3.0.x (whic= h wasn't turned on by default in versions of Spring previous to 3.0.x). To= reproduce this, simply get the project's code from trunk, and change the s= pring dependency versions to, 3.0.3.RELEASE and build. xbean-spring will f= ail. I'm attaching the results of one of the failed tests and you'll see t= he xbean configuration for that test failed validation for the "beans" tag. > Here is what the results of the build look like, in case it helps in anyw= ay: > Results : > Tests in error: > testPizza(org.apache.xbean.spring.context.RestaurantUsingXBeanTest) > testPizza(org.apache.xbean.spring.context.RestaurantUsingXBeanAsRootTes= t) > testBeer(org.apache.xbean.spring.context.BeerNullTest) > testFavs(org.apache.xbean.spring.context.FavoriteUsingXBeanMixedTest) > testBeer(org.apache.xbean.spring.context.KegXBeanTest) > testBeer(org.apache.xbean.spring.context.KegXBeanAndPropertiesTest) > testPizza(org.apache.xbean.spring.context.PizzaUsingXBeanWithJavaNamesp= aceTest) > testConfigureJndiInsideSpringXml(org.apache.xbean.spring.jndi.JndiTest) > testBeer(org.apache.xbean.spring.context.BeerUsingXBeanSystemPropTest) > testPizza(org.apache.xbean.spring.context.PizzaUsingXBeanTest) > testPizza(org.apache.xbean.spring.context.RestaurantUsingXBeanWithSimpl= erConfigTest) > testRecipes(org.apache.xbean.spring.context.RecipeUsingXBeanMixedTest) > testPizza(org.apache.xbean.spring.context.RestaurantUsingResourceXmlApp= licationContextTest) > test(org.apache.xbean.spring.context.SpringExtensionTest) > testSocketService(org.apache.xbean.spring.context.SocketAddressXBeanTes= t) > testSocketAddress(org.apache.xbean.spring.context.SocketAddressXBeanTes= t) > testRecipes(org.apache.xbean.spring.context.RecipeUsingXBeanTest) > testFavs(org.apache.xbean.spring.context.FavoriteUsingXBeanTest) > testBeer(org.apache.xbean.spring.context.BeerUsingXBeanTest) > testWine(org.apache.xbean.spring.context.WineUsingXBeanTest) > testPizza(org.apache.xbean.spring.context.PizzaUsingXBeanWithProperties= TextNodeTest) > testSoup(org.apache.xbean.spring.context.SoupUsingXBeanTest) > testFlatMap(org.apache.xbean.spring.context.FlatMapTest) > test1(org.apache.xbean.spring.context.ComponentTest) > test2(org.apache.xbean.spring.context.ComponentTest) > testQName(org.apache.xbean.spring.context.QNameUsingXBeanTest) > testWine(org.apache.xbean.spring.context.GinUsingSpringTest) > testPizza(org.apache.xbean.spring.context.PizzaUsingXBeanWinBeanRefTest= ) > testWine(org.apache.xbean.spring.context.VodkaUsingXBeanTest) > testSalad(org.apache.xbean.spring.context.SaladUsingXBeanTest) > testPizza(org.apache.xbean.spring.context.RestaurantUsingXBeanMixedTest= ) > testPizza(org.apache.xbean.spring.context.RestaurantUsingSpringExtended= Test) > Tests run: 58, Failures: 0, Errors: 32, Skipped: 0 --=20 This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.