incubator-connectors-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kwri...@apache.org
Subject svn commit: r1005685 - in /incubator/lcf/trunk/modules/framework: core/src/main/java/org/apache/manifoldcf/core/system/ManifoldCF.java jetty-runner/src/main/java/org/apache/manifoldcf/jettyrunner/ManifoldCFJettyRunner.java
Date Fri, 08 Oct 2010 00:47:24 GMT
Author: kwright
Date: Fri Oct  8 00:47:24 2010
New Revision: 1005685

URL: http://svn.apache.org/viewvc?rev=1005685&view=rev
Log:
Change the default database instance name to ManifoldCF, and also allow quick-start users
to set the master database username and password in their config file (or, optionally, in
-D switches).

Modified:
    incubator/lcf/trunk/modules/framework/core/src/main/java/org/apache/manifoldcf/core/system/ManifoldCF.java
    incubator/lcf/trunk/modules/framework/jetty-runner/src/main/java/org/apache/manifoldcf/jettyrunner/ManifoldCFJettyRunner.java

Modified: incubator/lcf/trunk/modules/framework/core/src/main/java/org/apache/manifoldcf/core/system/ManifoldCF.java
URL: http://svn.apache.org/viewvc/incubator/lcf/trunk/modules/framework/core/src/main/java/org/apache/manifoldcf/core/system/ManifoldCF.java?rev=1005685&r1=1005684&r2=1005685&view=diff
==============================================================================
--- incubator/lcf/trunk/modules/framework/core/src/main/java/org/apache/manifoldcf/core/system/ManifoldCF.java
(original)
+++ incubator/lcf/trunk/modules/framework/core/src/main/java/org/apache/manifoldcf/core/system/ManifoldCF.java
Fri Oct  8 00:47:24 2010
@@ -183,7 +183,7 @@ public class ManifoldCF
           masterDatabaseName = "dbname";
         masterDatabaseUsername = getProperty(masterDatabaseUsernameProperty);
         if (masterDatabaseUsername == null)
-          masterDatabaseUsername = "lcf";
+          masterDatabaseUsername = "manifoldcf";
         masterDatabasePassword = getProperty(masterDatabasePasswordProperty);
         if (masterDatabasePassword == null)
           masterDatabasePassword = "local_pg_passwd";

Modified: incubator/lcf/trunk/modules/framework/jetty-runner/src/main/java/org/apache/manifoldcf/jettyrunner/ManifoldCFJettyRunner.java
URL: http://svn.apache.org/viewvc/incubator/lcf/trunk/modules/framework/jetty-runner/src/main/java/org/apache/manifoldcf/jettyrunner/ManifoldCFJettyRunner.java?rev=1005685&r1=1005684&r2=1005685&view=diff
==============================================================================
--- incubator/lcf/trunk/modules/framework/jetty-runner/src/main/java/org/apache/manifoldcf/jettyrunner/ManifoldCFJettyRunner.java
(original)
+++ incubator/lcf/trunk/modules/framework/jetty-runner/src/main/java/org/apache/manifoldcf/jettyrunner/ManifoldCFJettyRunner.java
Fri Oct  8 00:47:24 2010
@@ -53,6 +53,8 @@ public class ManifoldCFJettyRunner
 
   // Configuration parameters
   public static final String connectorsConfigurationFile = "org.apache.manifoldcf.connectorsconfigurationfile";
+  public static final String databaseSuperuserName = "org.apache.manifoldcf.dbsuperusername";
+  public static final String databaseSuperuserPassword = "org.apache.manifoldcf.dbsuperuserpassword";
   
   // Connectors configuration file
   public static final String NODE_OUTPUTCONNECTOR = "outputconnector";
@@ -188,8 +190,16 @@ public class ManifoldCFJettyRunner
         ManifoldCF.getMasterDatabaseUsername(),
         ManifoldCF.getMasterDatabasePassword());
 
+      // Get the specified superuser name and password, in case this isn't Derby we're using
+      String superuserName = ManifoldCF.getProperty(databaseSuperuserName);
+      if (superuserName == null)
+        superuserName = "";
+      String superuserPassword = ManifoldCF.getProperty(databaseSuperuserPassword);
+      if (superuserPassword == null)
+        superuserPassword = "";
+      
       // Do the basic initialization of the database and its schema
-      ManifoldCF.createSystemDatabase(tc,"","");
+      ManifoldCF.createSystemDatabase(tc,superuserName,superuserPassword);
       ManifoldCF.installTables(tc);
       IAgentManager agentMgr = AgentManagerFactory.make(tc);
       agentMgr.registerAgent("org.apache.manifoldcf.crawler.system.CrawlerAgent");



Mime
View raw message