← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 3267: Increased caching in the system. Removed 60% of database traffic during data entry.

 

------------------------------------------------------------
revno: 3267
committer: Lars Helge Overland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Sun 2011-04-03 12:25:42 +0200
message:
  Increased caching in the system. Removed 60% of database traffic during data entry.
modified:
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/DataSetService.java
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/DataSetStore.java
  dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataset/DefaultDataSetService.java
  dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataset/hibernate/HibernateDataSetStore.java
  dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/period/hibernate/HibernatePeriodStore.java
  dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategory.hbm.xml
  dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategoryCombo.hbm.xml
  dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategoryOption.hbm.xml
  dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategoryOptionCombo.hbm.xml
  dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataset/hibernate/DataSet.hbm.xml
  dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/period/hibernate/Period.hbm.xml
  dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/period/hibernate/PeriodType.hbm.xml
  dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/source/hibernate/Source.hbm.xml
  dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/dataset/DataSetServiceTest.java
  dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/dataset/DataSetStoreTest.java
  dhis-2/dhis-support/dhis-support-hibernate/src/main/resources/ehcache.xml
  dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/service/FacilityReportingServiceImpl.java
  dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/paging/paging.vm
  dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/security/intercept/LoginInterceptor.java
  dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/util/JRExportUtils.java
  dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/action/SectionFormAction.java
  dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/state/DefaultSelectedStateManager.java
  dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/inputReportParamsForm.vm


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/DataSetService.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/DataSetService.java	2011-03-03 06:16:22 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/DataSetService.java	2011-04-03 10:25:42 +0000
@@ -109,11 +109,6 @@
     DataSet getDataSetByCode( String code );
 
     /**
-     * Returns all DataSets associated with the specified source.
-     */
-    Collection<DataSet> getDataSetsBySource( Source source );
-
-    /**
      * Returns all DataSets associated with the specified sources.
      */
     Collection<DataSet> getDataSetsBySources( Collection<? extends Source> sources );

=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/DataSetStore.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/DataSetStore.java	2011-03-03 06:16:22 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/DataSetStore.java	2011-04-03 10:25:42 +0000
@@ -122,8 +122,6 @@
      */
     Collection<DataSet> getDataSetsByPeriodType( PeriodType periodType );
 
-    Collection<DataSet> getDataSetsBySource( Source source );
-    
     /**
      * Returns all DataSets that can be collected through mobile.
      */

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataset/DefaultDataSetService.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataset/DefaultDataSetService.java	2011-03-03 06:16:22 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataset/DefaultDataSetService.java	2011-04-03 10:25:42 +0000
@@ -153,11 +153,6 @@
         return i18n( i18nService, dataSetStore.getDataSetByCode( code ) );
     }
 
-    public Collection<DataSet> getDataSetsBySource( Source source )
-    {
-        return i18n( i18nService, dataSetStore.getDataSetsBySource( source ) );
-    }
-
     public Collection<DataSet> getDataSetsBySources( Collection<? extends Source> sources )
     {
         return i18n( i18nService, dataSetStore.getDataSetsBySources( sources ) );

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataset/hibernate/HibernateDataSetStore.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataset/hibernate/HibernateDataSetStore.java	2011-03-03 06:16:22 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataset/hibernate/HibernateDataSetStore.java	2011-04-03 10:25:42 +0000
@@ -181,17 +181,6 @@
     }
 
     @SuppressWarnings( "unchecked" )
-    public Collection<DataSet> getDataSetsBySource( Source source )
-    {
-        String hql = "from DataSet d where :source in elements(d.sources)";
-
-        Query query = sessionFactory.getCurrentSession().createQuery( hql );
-        query.setEntity( "source", source );
-
-        return query.list();
-    }
-
-    @SuppressWarnings( "unchecked" )
     public Collection<DataSet> getDataSetsBySources( Collection<? extends Source> sources )
     {
         String hql = "select distinct d from DataSet d join d.sources s where s.id in (:ids)";

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/period/hibernate/HibernatePeriodStore.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/period/hibernate/HibernatePeriodStore.java	2011-03-11 08:13:14 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/period/hibernate/HibernatePeriodStore.java	2011-04-03 10:25:42 +0000
@@ -98,6 +98,7 @@
         criteria.add( Restrictions.eq( "startDate", startDate ) );
         criteria.add( Restrictions.eq( "endDate", endDate ) );
         criteria.add( Restrictions.eq( "periodType", reloadPeriodType( periodType ) ) );
+        criteria.setCacheable( true );
 
         return (Period) criteria.uniqueResult();
     }
@@ -118,6 +119,7 @@
         Criteria criteria = session.createCriteria( Period.class );
         criteria.add( Restrictions.ge( "startDate", startDate ) );
         criteria.add( Restrictions.le( "endDate", endDate ) );
+        criteria.setCacheable( true );
 
         return criteria.list();
     }
@@ -131,6 +133,7 @@
         criteria.add( Restrictions.eq( "periodType", reloadPeriodType( periodType ) ) );
         criteria.add( Restrictions.ge( "startDate", startDate ) );
         criteria.add( Restrictions.le( "endDate", endDate ) );
+        criteria.setCacheable( true );
 
         return criteria.list();
     }
@@ -152,6 +155,7 @@
         criteria.add( Restrictions.eq( "periodType", reloadPeriodType( periodType ) ) );
         criteria.add( Restrictions.ge( "endDate", startDate ) );
         criteria.add( Restrictions.le( "startDate", endDate ) );
+        criteria.setCacheable( true );
 
         return criteria.list();
     }
@@ -164,6 +168,7 @@
         Criteria criteria = session.createCriteria( Period.class );
         criteria.add( Restrictions.ge( "endDate", startDate ) );
         criteria.add( Restrictions.le( "startDate", endDate ) );
+        criteria.setCacheable( true );
         
         return criteria.list();
     }
@@ -175,6 +180,7 @@
 
         Criteria criteria = session.createCriteria( Period.class );
         criteria.add( Restrictions.eq( "periodType", reloadPeriodType( periodType ) ) );
+        criteria.setCacheable( true );
 
         return criteria.list();
     }

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategory.hbm.xml'
--- dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategory.hbm.xml	2011-01-07 11:38:55 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategory.hbm.xml	2011-04-03 10:25:42 +0000
@@ -6,6 +6,8 @@
 <hibernate-mapping>
   <class name="org.hisp.dhis.dataelement.DataElementCategory" table="dataelementcategory">
     
+    <cache usage="read-write"/>
+    
     <id name="id" column="categoryid">
       <generator class="native"/>
     </id>

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategoryCombo.hbm.xml'
--- dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategoryCombo.hbm.xml	2011-01-07 11:38:55 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategoryCombo.hbm.xml	2011-04-03 10:25:42 +0000
@@ -6,6 +6,8 @@
 <hibernate-mapping>
   <class name="org.hisp.dhis.dataelement.DataElementCategoryCombo" table="categorycombo">
 
+    <cache usage="read-write"/>
+    
     <id name="id" column="categorycomboid">
       <generator class="native"/>
     </id>

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategoryOption.hbm.xml'
--- dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategoryOption.hbm.xml	2011-01-07 11:38:55 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategoryOption.hbm.xml	2011-04-03 10:25:42 +0000
@@ -6,6 +6,8 @@
 <hibernate-mapping>
   <class name="org.hisp.dhis.dataelement.DataElementCategoryOption" table="dataelementcategoryoption">
 
+    <cache usage="read-write"/>
+    
     <id name="id" column="categoryoptionid">
       <generator class="native"/>
     </id>

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategoryOptionCombo.hbm.xml'
--- dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategoryOptionCombo.hbm.xml	2011-02-15 06:38:47 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataelement/hibernate/DataElementCategoryOptionCombo.hbm.xml	2011-04-03 10:25:42 +0000
@@ -6,6 +6,8 @@
 <hibernate-mapping>
     <class name="org.hisp.dhis.dataelement.DataElementCategoryOptionCombo" table="categoryoptioncombo">
 
+    <cache usage="read-write"/>
+    
     <id name="id" column="categoryoptioncomboid">
       <generator class="native"/>
     </id>      

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataset/hibernate/DataSet.hbm.xml'
--- dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataset/hibernate/DataSet.hbm.xml	2011-02-15 06:36:28 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/dataset/hibernate/DataSet.hbm.xml	2011-04-03 10:25:42 +0000
@@ -5,6 +5,9 @@
 
 <hibernate-mapping>
   <class name="org.hisp.dhis.dataset.DataSet" table="dataset">
+  
+    <cache usage="read-write"/>
+  
     <id name="id" column="datasetid">
       <generator class="native"/>
     </id>

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/period/hibernate/Period.hbm.xml'
--- dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/period/hibernate/Period.hbm.xml	2009-03-03 16:46:36 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/period/hibernate/Period.hbm.xml	2011-04-03 10:25:42 +0000
@@ -4,6 +4,9 @@
 
 <hibernate-mapping>
   <class name="org.hisp.dhis.period.Period" table="period">
+  
+    <cache usage="read-write"/>
+  
     <id name="id" column="periodid">
       <generator class="native"/>
     </id>

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/period/hibernate/PeriodType.hbm.xml'
--- dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/period/hibernate/PeriodType.hbm.xml	2011-03-03 18:29:05 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/period/hibernate/PeriodType.hbm.xml	2011-04-03 10:25:42 +0000
@@ -5,6 +5,9 @@
 
 <hibernate-mapping>
   <class name="org.hisp.dhis.period.PeriodType" table="periodtype">
+  
+    <cache usage="read-write"/>
+  
     <id name="id" column="periodtypeid">
       <generator class="native"/>
     </id>

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/source/hibernate/Source.hbm.xml'
--- dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/source/hibernate/Source.hbm.xml	2009-06-30 23:08:22 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/resources/org/hisp/dhis/source/hibernate/Source.hbm.xml	2011-04-03 10:25:42 +0000
@@ -6,6 +6,8 @@
   
   <class name="org.hisp.dhis.source.Source" table="source" abstract="true">
       
+    <cache usage="read-write"/>
+      
     <id name="id" column="sourceid">
       <generator class="native"/>
     </id>

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/dataset/DataSetServiceTest.java'
--- dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/dataset/DataSetServiceTest.java	2011-02-15 20:14:22 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/dataset/DataSetServiceTest.java	2011-04-03 10:25:42 +0000
@@ -188,53 +188,6 @@
     }
 
     @Test
-    public void testGetDataSetsBySource()
-    {
-        OrganisationUnit sourceA = createOrganisationUnit( 'A' );
-        OrganisationUnit sourceB = createOrganisationUnit( 'B' );
-        OrganisationUnit sourceC = createOrganisationUnit( 'C' );
-        
-        organisationUnitService.addOrganisationUnit( sourceA );
-        organisationUnitService.addOrganisationUnit( sourceB );
-        organisationUnitService.addOrganisationUnit( sourceC );
-        
-        DataSet dataSetA = createDataSet( 'A', periodType );
-        DataSet dataSetB = createDataSet( 'B', periodType );
-        DataSet dataSetC = createDataSet( 'C', periodType );
-        
-        dataSetA.getSources().add( sourceA );
-        dataSetA.getSources().add( sourceB );
-        
-        dataSetB.getSources().add( sourceB );
-        dataSetB.getSources().add( sourceC );        
-
-        dataSetC.getSources().add( sourceA );
-        dataSetC.getSources().add( sourceC );
-        
-        dataSetService.addDataSet( dataSetA );
-        dataSetService.addDataSet( dataSetB );
-        dataSetService.addDataSet( dataSetC );
-        
-        Collection<DataSet> dataSets = dataSetService.getDataSetsBySource( sourceA );
-        
-        assertEquals( 2, dataSets.size() );
-        assertTrue( dataSets.contains( dataSetA ) );
-        assertTrue( dataSets.contains( dataSetC ) );
-        
-        dataSets = dataSetService.getDataSetsBySource( sourceB );        
-
-        assertEquals( 2, dataSets.size() );
-        assertTrue( dataSets.contains( dataSetA ) );
-        assertTrue( dataSets.contains( dataSetB ) );
-
-        dataSets = dataSetService.getDataSetsBySource( sourceC );
-        
-        assertEquals( 2, dataSets.size() );
-        assertTrue( dataSets.contains( dataSetB ) );
-        assertTrue( dataSets.contains( dataSetC ) );        
-    }
-
-    @Test
     public void testGetDataSetsBySources()
     {
         OrganisationUnit unitA = createOrganisationUnit( 'A' );

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/dataset/DataSetStoreTest.java'
--- dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/dataset/DataSetStoreTest.java	2011-02-15 20:14:22 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/dataset/DataSetStoreTest.java	2011-04-03 10:25:42 +0000
@@ -94,43 +94,6 @@
     // -------------------------------------------------------------------------
 
     @Test
-    public void testGetDataSetsBySource()
-    {
-        OrganisationUnit unitA = createOrganisationUnit( 'A' );
-        OrganisationUnit unitB = createOrganisationUnit( 'B' );  
-        OrganisationUnit unitC = createOrganisationUnit( 'C' );  
-        organisationUnitService.addOrganisationUnit( unitA );
-        organisationUnitService.addOrganisationUnit( unitB );
-        organisationUnitService.addOrganisationUnit( unitC );
-
-        DataSet dataSetA = createDataSet( 'A', periodType );
-        DataSet dataSetB = createDataSet( 'B', periodType );
-        DataSet dataSetC = createDataSet( 'C', periodType );
-        dataSetA.getSources().add( unitA );
-        dataSetA.getSources().add( unitB );
-        dataSetB.getSources().add( unitA );
-        
-        dataSetStore.addDataSet( dataSetA );
-        dataSetStore.addDataSet( dataSetB );
-        dataSetStore.addDataSet( dataSetC );
-        
-        Collection<DataSet> dataSets = dataSetStore.getDataSetsBySource( unitA );
-
-        assertEquals( 2, dataSets.size() );
-        assertTrue( dataSets.contains( dataSetA ) );
-        assertTrue( dataSets.contains( dataSetB ) );
-
-        dataSets = dataSetStore.getDataSetsBySource( unitB );
-        
-        assertEquals( 1, dataSets.size() );
-        assertTrue( dataSets.contains( dataSetA ) );
-
-        dataSets = dataSetStore.getDataSetsBySource( unitC );
-        
-        assertEquals( 0, dataSets.size() );
-    }
-
-    @Test
     public void testGetDataSetsBySources()
     {
         OrganisationUnit unitA = createOrganisationUnit( 'A' );

=== modified file 'dhis-2/dhis-support/dhis-support-hibernate/src/main/resources/ehcache.xml'
--- dhis-2/dhis-support/dhis-support-hibernate/src/main/resources/ehcache.xml	2011-03-31 14:39:14 +0000
+++ dhis-2/dhis-support/dhis-support-hibernate/src/main/resources/ehcache.xml	2011-04-03 10:25:42 +0000
@@ -20,6 +20,22 @@
     maxElementsInMemory="4000"
   />
 
+  <cache name="org.hisp.dhis.dataelement.DataElementCategoryCombo"
+    maxElementsInMemory="100"
+  />
+  
+  <cache name="org.hisp.dhis.dataelement.DataElementCategory"
+    maxElementsInMemory="200"
+  />
+  
+  <cache name="org.hisp.dhis.dataelement.DataElementCategoryOption"
+    maxElementsInMemory="400"
+  />
+  
+  <cache name="org.hisp.dhis.dataelement.DataElementCategoryOptionCombo"
+    maxElementsInMemory="800"
+  />
+  
   <cache name="org.hisp.dhis.dataelement.DataElementGroup"
     maxElementsInMemory="200"
   />
@@ -40,6 +56,22 @@
     maxElementsInMemory="200"
   />
   
+  <cache name="org.hisp.dhis.period.Period"
+    maxElementsInMemory="200"
+  />
+  
+  <cache name="org.hisp.dhis.period.PeriodType"
+    maxElementsInMemory="50"
+  />
+  
+  <cache name="org.hisp.dhis.dataset.DataSet"
+    maxElementsInMemory="100"
+  />
+  
+  <cache name="org.hisp.dhis.source.Source"
+    maxElementsInMemory="10000"
+  />
+  
   <cache name="org.hisp.dhis.user.User"
     maxElementsInMemory="200"
   />
@@ -69,7 +101,7 @@
   />
   
   <cache name="org.hisp.dhis.message.UserMessage"
-    maxElementsInMemory="100000"/>
+    maxElementsInMemory="50000"/>
   
   <!-- Hibernate Query Cache -->
   

=== modified file 'dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/service/FacilityReportingServiceImpl.java'
--- dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/service/FacilityReportingServiceImpl.java	2011-02-25 07:08:59 +0000
+++ dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/web/api/service/FacilityReportingServiceImpl.java	2011-04-03 10:25:42 +0000
@@ -338,7 +338,7 @@
 
     private boolean dataSetAssociatedWithOrgUnit( OrganisationUnit unit, org.hisp.dhis.dataset.DataSet dataSet )
     {
-        return dataSetService.getDataSetsBySource( unit ).contains( dataSet );
+        return unit.getDataSets().contains( dataSet );
     }
 
     private void saveValue( OrganisationUnit unit, Period period, org.hisp.dhis.dataelement.DataElement dataElement,

=== modified file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/paging/paging.vm'
--- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/paging/paging.vm	2011-01-19 11:38:59 +0000
+++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/paging/paging.vm	2011-04-03 10:25:42 +0000
@@ -40,7 +40,7 @@
 				<span class="prev" title="Previous">&laquo;</span>
 			#end
 			
-			#foreach( $i in [0..4]   )
+			#foreach( $i in [0..4] )
 				#set( $p = $startPage + $i )
 				#if ( $p <= $numberOfPages )
 					#if( $i > 0 )

=== modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/security/intercept/LoginInterceptor.java'
--- dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/security/intercept/LoginInterceptor.java	2011-03-29 21:28:45 +0000
+++ dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/security/intercept/LoginInterceptor.java	2011-04-03 10:25:42 +0000
@@ -71,7 +71,7 @@
 
         if ( jli != null )
         {
-            log.info( "JLI marker is present. Running " + actions.size() + " JLI actions." );
+            log.debug( "JLI marker is present. Running " + actions.size() + " JLI actions." );
 
             for ( Action a : actions )
             {

=== modified file 'dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/util/JRExportUtils.java'
--- dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/util/JRExportUtils.java	2011-03-08 01:55:01 +0000
+++ dhis-2/dhis-web/dhis-web-commons/src/main/java/org/hisp/dhis/util/JRExportUtils.java	2011-04-03 10:25:42 +0000
@@ -46,8 +46,8 @@
  */
 public class JRExportUtils
 {
-    public static String TYPE_XLS = "xls";
-    public static String TYPE_PDF = "pdf";
+    public static final String TYPE_XLS = "xls";
+    public static final String TYPE_PDF = "pdf";
     
     private static final Map<String, JRExportProvider> exporters = new HashMap<String, JRExportProvider>() { {
         put( TYPE_XLS, new JRXlsExportProvider() );

=== modified file 'dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/action/SectionFormAction.java'
--- dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/action/SectionFormAction.java	2011-01-25 22:15:46 +0000
+++ dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/action/SectionFormAction.java	2011-04-03 10:25:42 +0000
@@ -214,7 +214,7 @@
         return orderdCategoryOptionCombos;
     }
 
-    Collection<DataElementCategoryOptionCombo> allOptionCombos = new ArrayList<DataElementCategoryOptionCombo>();
+    private Collection<DataElementCategoryOptionCombo> allOptionCombos = new ArrayList<DataElementCategoryOptionCombo>();
 
     public Collection<DataElementCategoryOptionCombo> getAllOptionCombos()
     {
@@ -319,7 +319,6 @@
 
         for ( Section section : sections )
         {
-
             if ( section.getDataElements().size() > 0 )
             {
                 orderedCategoryCombos.add( section.getDataElements().iterator().next().getCategoryCombo() );

=== modified file 'dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/state/DefaultSelectedStateManager.java'
--- dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/state/DefaultSelectedStateManager.java	2011-01-24 20:34:45 +0000
+++ dhis-2/dhis-web/dhis-web-dataentry/src/main/java/org/hisp/dhis/de/state/DefaultSelectedStateManager.java	2011-04-03 10:25:42 +0000
@@ -151,7 +151,7 @@
 
     public List<DataSet> loadDataSetsForSelectedOrgUnit()
     {
-        List<DataSet> dataSets = new ArrayList<DataSet>( dataSetService.getDataSetsBySource( getSelectedOrganisationUnit() ) );
+        List<DataSet> dataSets = new ArrayList<DataSet>( getSelectedOrganisationUnit().getDataSets() );
 
         // ---------------------------------------------------------------------
         // Retain only DataSets from current user's authority groups

=== modified file 'dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/inputReportParamsForm.vm'
--- dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/inputReportParamsForm.vm	2011-03-29 20:06:47 +0000
+++ dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/inputReportParamsForm.vm	2011-04-03 10:25:42 +0000
@@ -69,7 +69,7 @@
 			<script type="text/javascript">
 				selectionTreeSelection.setMultipleSelectionAllowed( false );
 				selectionTreeSelection.setListenerFunction( paramOrganisationUnitSet );
-				selectionTree.clearSelectedOrganisationUnits();
+				//selectionTree.clearSelectedOrganisationUnits();
 			    selectionTree.buildSelectionTree();
 			</script>
 	    </td>