Author: indika
Date: Mon Jul  7 08:41:47 2008
New Revision: 18907
URL: http://wso2.org/svn/browse/wso2?view=rev&revision=18907

Log:
update pom , add cipher-text file


Added:
   trunk/esb/java/modules/distribution/src/main/conf/cipher-text.properties
   trunk/esb/java/modules/distribution/src/main/conf/secret-manager.properties
Modified:
   
trunk/esb/java/modules/core/src/main/java/org/wso2/esb/registry/ESBRegistry.java
   trunk/esb/java/modules/distribution/src/main/conf/synapse.properties
   trunk/esb/java/pom.xml

Modified: 
trunk/esb/java/modules/core/src/main/java/org/wso2/esb/registry/ESBRegistry.java
URL: 
http://wso2.org/svn/browse/wso2/trunk/esb/java/modules/core/src/main/java/org/wso2/esb/registry/ESBRegistry.java?rev=18907&r1=18906&r2=18907&view=diff
==============================================================================
--- 
trunk/esb/java/modules/core/src/main/java/org/wso2/esb/registry/ESBRegistry.java
    (original)
+++ 
trunk/esb/java/modules/core/src/main/java/org/wso2/esb/registry/ESBRegistry.java
    Mon Jul  7 08:41:47 2008
@@ -112,7 +112,7 @@
 
         log.info("==> Repository fetch of resource with key : " + key);
 
-        URLConnection urlc;
+        URLConnection connection;
         URL url = null;
         try {
             url = new URL(getRoot() + key);
@@ -142,15 +142,21 @@
         }
 
         try {
-            urlc = url.openConnection();
-            urlc.connect();
+            connection = SynapseConfigUtils.getURLConnection(url);
+            if (connection == null) {
+                if (log.isDebugEnabled()) {
+                    log.debug("Cannot create a URLConnection for given URL : " 
+ url);
+                }
+                return null;
+            }
+            connection.connect();
         } catch (IOException e) {
             return null;
         }
 
         InputStream input = null;
         try {
-            input = urlc.getInputStream();
+            input = connection.getInputStream();
         } catch (IOException e) {
             handleException("Error when getting a stream from the URL", e);
         }
@@ -214,6 +220,7 @@
         RegistryEntryImpl entryEmbedded = new RegistryEntryImpl();
 
         try {
+
             URL url = new URL(getRoot() + key);
             if ("file".equals(url.getProtocol())) {
                 try {
@@ -230,18 +237,25 @@
                     }
                 }
             }
-            URLConnection urlc = url.openConnection();
+
+            URLConnection connection = 
SynapseConfigUtils.getURLConnection(url);
+            if (connection == null) {
+                if (log.isDebugEnabled()) {
+                    log.debug("Cannot create a URLConnection for given URL : " 
+ url);
+                }
+                return null;
+            }
 
             entryEmbedded.setKey(key);
             entryEmbedded.setName(url.getFile());
             entryEmbedded.setType(ServiceBusConstants.file);
 
             entryEmbedded.setDescription("Resource at : " + url.toString());
-            entryEmbedded.setLastModified(urlc.getLastModified());
-            entryEmbedded.setVersion(urlc.getLastModified());
-            if (urlc.getExpiration() > 0) {
+            entryEmbedded.setLastModified(connection.getLastModified());
+            entryEmbedded.setVersion(connection.getLastModified());
+            if (connection.getExpiration() > 0) {
                 entryEmbedded.setCachableDuration(
-                        urlc.getExpiration() - System.currentTimeMillis());
+                        connection.getExpiration() - 
System.currentTimeMillis());
             } else {
                 entryEmbedded.setCachableDuration(getCachableDuration());
             }

Added: trunk/esb/java/modules/distribution/src/main/conf/cipher-text.properties
URL: 
http://wso2.org/svn/browse/wso2/trunk/esb/java/modules/distribution/src/main/conf/cipher-text.properties?pathrev=18907
==============================================================================
--- (empty file)
+++ trunk/esb/java/modules/distribution/src/main/conf/cipher-text.properties    
Mon Jul  7 08:41:47 2008
@@ -0,0 +1,7 @@
+#aliases=synapse,password
+#
+## configuration  per each plain text
+#synapse.secret=EsY65tztE9R5b9pErVxLp8Br5d3ol6vRdWAkYHdc7XkZteGf37VJ+iNlCenqxYSEto0vcjpcmmzwf7K2wd9u3KQtVGKEoNLSe2LYZtrm3tKmGd6PX9YpdN72ml3JISNXPJ69yybFi6DVUIJfE5MFOd7gswWfCnkmZ3eJ6M1nuiI=
+#synapse.secret.algorithm=RSA
+#synapse.secret.alias=synapse
+#synapse.secret.keystore=identity

Added: 
trunk/esb/java/modules/distribution/src/main/conf/secret-manager.properties
URL: 
http://wso2.org/svn/browse/wso2/trunk/esb/java/modules/distribution/src/main/conf/secret-manager.properties?pathrev=18907
==============================================================================
--- (empty file)
+++ trunk/esb/java/modules/distribution/src/main/conf/secret-manager.properties 
Mon Jul  7 08:41:47 2008
@@ -0,0 +1,4 @@
+#secretRepositories=file
+#
+#secretRepositories.file.type=file
+#secretRepositories.file.location=cipher-text.properties

Modified: trunk/esb/java/modules/distribution/src/main/conf/synapse.properties
URL: 
http://wso2.org/svn/browse/wso2/trunk/esb/java/modules/distribution/src/main/conf/synapse.properties?rev=18907&r1=18906&r2=18907&view=diff
==============================================================================
--- trunk/esb/java/modules/distribution/src/main/conf/synapse.properties        
(original)
+++ trunk/esb/java/modules/distribution/src/main/conf/synapse.properties        
Mon Jul  7 08:41:47 2008
@@ -24,6 +24,21 @@
 synapse.threads.group = synapse-thread-group
 synapse.threads.idprefix = SynapseWorker
 
+# KeyStores configurations
+
+#keystore.identity.location=webapp/WEB-INF/classes/conf/identity.jks
+#keystore.identity.type=JKS
+#keystore.identity.storePassword=password
+#keystore.identity.keyPassword=password
+#keystore.identity.parameters=enableHostnameVerifier=false;keyStoreCertificateFilePath=/home/esb.cer
+#
+#keystore.trust.location=webapp/WEB-INF/classes/conf/trust.jks
+#keystore.trust.type=JKS
+#keystore.trust.storePassword=password
+#keystore.trust.parameters=enableHostnameVerifier=false;keyStoreCertificateFilePath=/home/esb.cer
+
+# DataSources Configurations
+
 #synapse.datasources=lookupds,reportds
 #synapse.datasources.icFactory=com.sun.jndi.rmi.registry.RegistryContextFactory
 #synapse.datasources.providerUrl=rmi://localhost:2199

Modified: trunk/esb/java/pom.xml
URL: 
http://wso2.org/svn/browse/wso2/trunk/esb/java/pom.xml?rev=18907&r1=18906&r2=18907&view=diff
==============================================================================
--- trunk/esb/java/pom.xml      (original)
+++ trunk/esb/java/pom.xml      Mon Jul  7 08:41:47 2008
@@ -872,7 +872,7 @@
         <slf4j.version>1.0.1</slf4j.version>
 
         <!-- Synapse and related components -->
-           <synapse.version>SNAPSHOT</synapse.version>
+           <synapse.version>1.3-SNAPSHOT</synapse.version>
         <httpcore.nio.version>4.0-beta1</httpcore.nio.version>
         <smack.version>2.2.1</smack.version>
 

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

Reply via email to