continuum-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From car...@apache.org
Subject svn commit: r1099430 - in /continuum/trunk/continuum-xmlrpc: continuum-xmlrpc-api/src/main/mdo/continuum-service.xml continuum-xmlrpc-server/src/test/java/org/apache/continuum/xmlrpc/server/ContinuumServiceImplTest.java
Date Wed, 04 May 2011 12:43:02 GMT
Author: carlos
Date: Wed May  4 12:43:02 2011
New Revision: 1099430

URL: http://svn.apache.org/viewvc?rev=1099430&view=rev
Log:
[CONTINUUM-2625] Remove projectGroup from ProjectScmRoot xmlrpc api so it doesn't fetch a
big graph of objects

Modified:
    continuum/trunk/continuum-xmlrpc/continuum-xmlrpc-api/src/main/mdo/continuum-service.xml
    continuum/trunk/continuum-xmlrpc/continuum-xmlrpc-server/src/test/java/org/apache/continuum/xmlrpc/server/ContinuumServiceImplTest.java

Modified: continuum/trunk/continuum-xmlrpc/continuum-xmlrpc-api/src/main/mdo/continuum-service.xml
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-xmlrpc/continuum-xmlrpc-api/src/main/mdo/continuum-service.xml?rev=1099430&r1=1099429&r2=1099430&view=diff
==============================================================================
--- continuum/trunk/continuum-xmlrpc/continuum-xmlrpc-api/src/main/mdo/continuum-service.xml
(original)
+++ continuum/trunk/continuum-xmlrpc/continuum-xmlrpc-api/src/main/mdo/continuum-service.xml
Wed May  4 12:43:02 2011
@@ -1531,15 +1531,7 @@
           <version>1.4.1+</version>
           <type>String</type>
         </field>
-        <field>
-          <name>projectGroup</name>
-          <version>1.4.1+</version>
-          <association xml.reference="true" stash.part="true" jpox.dependent="false">
-            <type>ProjectGroup</type>
-          </association>
-          <required>true</required>
-        </field>
       </fields>
-    </class>    
+    </class>
   </classes>
 </model>

Modified: continuum/trunk/continuum-xmlrpc/continuum-xmlrpc-server/src/test/java/org/apache/continuum/xmlrpc/server/ContinuumServiceImplTest.java
URL: http://svn.apache.org/viewvc/continuum/trunk/continuum-xmlrpc/continuum-xmlrpc-server/src/test/java/org/apache/continuum/xmlrpc/server/ContinuumServiceImplTest.java?rev=1099430&r1=1099429&r2=1099430&view=diff
==============================================================================
--- continuum/trunk/continuum-xmlrpc/continuum-xmlrpc-server/src/test/java/org/apache/continuum/xmlrpc/server/ContinuumServiceImplTest.java
(original)
+++ continuum/trunk/continuum-xmlrpc/continuum-xmlrpc-server/src/test/java/org/apache/continuum/xmlrpc/server/ContinuumServiceImplTest.java
Wed May  4 12:43:02 2011
@@ -235,7 +235,7 @@ public class ContinuumServiceImplTest
     public void testGetProjectScmRootByProject()
         throws Exception
     {
-        final ProjectGroup projectGroup = new ProjectGroup();
+        final ProjectGroup projectGroup = new ProjectGroupStub();
         projectGroup.setName( "test-group" );
         projectGroup.setId( 1 );
 
@@ -261,8 +261,6 @@ public class ContinuumServiceImplTest
         assertEquals( 1, projectScmRoot.getState() );
         assertEquals( 3, projectScmRoot.getOldState() );
         assertEquals( "address1", projectScmRoot.getScmRootAddress() );
-        assertEquals( projectGroup.getName(), projectScmRoot.getProjectGroup().getName()
);
-        assertEquals( projectGroup.getId(), projectScmRoot.getProjectGroup().getId() );
     }
 
     private BuildDefinition createBuildDefinition()
@@ -288,4 +286,16 @@ public class ContinuumServiceImplTest
         map.put( "completed-release-phases", Arrays.asList( "completed-phase" ) );
         return map;
     }
+
+    public class ProjectGroupStub
+        extends ProjectGroup
+    {
+        private static final long serialVersionUID = 1L;
+
+        @Override
+        public List<Project> getProjects()
+        {
+            throw new RuntimeException( "Can't call getProjects as it will throw JDODetachedFieldAccessException"
);
+        }
+    }
 }



Mime
View raw message