Author: indika
Date: Thu Jun 11 00:25:13 2009
New Revision: 38604
URL: http://wso2.org/svn/browse/wso2?view=rev&revision=38604

Log:
sync with 2.0 branch 

Modified:
   
branches/synapse/1.3-wso2v1/modules/commons/src/main/java/org/apache/synapse/commons/datasource/factory/DataSourceInformationRepositoryFactory.java

Modified: 
branches/synapse/1.3-wso2v1/modules/commons/src/main/java/org/apache/synapse/commons/datasource/factory/DataSourceInformationRepositoryFactory.java
URL: 
http://wso2.org/svn/browse/wso2/branches/synapse/1.3-wso2v1/modules/commons/src/main/java/org/apache/synapse/commons/datasource/factory/DataSourceInformationRepositoryFactory.java?rev=38604&r1=38603&r2=38604&view=diff
==============================================================================
--- 
branches/synapse/1.3-wso2v1/modules/commons/src/main/java/org/apache/synapse/commons/datasource/factory/DataSourceInformationRepositoryFactory.java
 (original)
+++ 
branches/synapse/1.3-wso2v1/modules/commons/src/main/java/org/apache/synapse/commons/datasource/factory/DataSourceInformationRepositoryFactory.java
 Thu Jun 11 00:25:13 2009
@@ -43,8 +43,8 @@
             Properties properties) {
         return createDataSourceInformationRepository(
                 new DataSourceRepositoryManager(
-                    new InMemoryDataSourceRepository(),
-                    new JNDIBasedDataSourceRepository()), properties);
+                        new InMemoryDataSourceRepository(),
+                        new JNDIBasedDataSourceRepository()), properties);
     }
 
     /**
@@ -62,7 +62,7 @@
             log.debug("Creating a new DataSourceInformationRepository");
         }
         DataSourceInformationRepository datasourceInformationRepository =
-            new DataSourceInformationRepository();
+                new DataSourceInformationRepository();
 
         datasourceInformationRepository.setRepositoryListener(listener);
         setupDatasourceInformationRepository(datasourceInformationRepository, 
properties);
@@ -78,19 +78,19 @@
      * @param properties DataSource properties
      */
     public static void setupDatasourceInformationRepository(
-            DataSourceInformationRepository datasourceInformationRepository,
-            Properties properties) {
-
-        if (properties != null && !properties.isEmpty()) {
-            
datasourceInformationRepository.setConfigurationProperties(properties);
-        }
-        List<DataSourceInformation> sourceInformationList =
-            
DataSourceInformationListFactory.createDataSourceInformationList(properties);
+             DataSourceInformationRepository datasourceInformationRepository,
+             Properties properties) {
 
-        for (DataSourceInformation information : sourceInformationList) {
-            if (information != null) {
-                
datasourceInformationRepository.addDataSourceInformation(information);
-            }
-        }
-    }
+         if (properties != null) {
+             
datasourceInformationRepository.setConfigurationProperties(properties);
+         }
+         List<DataSourceInformation> sourceInformationList =
+                 
DataSourceInformationListFactory.createDataSourceInformationList(properties);
+
+         for (DataSourceInformation information : sourceInformationList) {
+             if (information != null) {
+                 
datasourceInformationRepository.addDataSourceInformation(information);
+             }
+         }
+     }
 }

_______________________________________________
Esb-java-dev mailing list
[email protected]
https://wso2.org/cgi-bin/mailman/listinfo/esb-java-dev

Reply via email to