[Yanel-commits] rev 26169 -
public/yanel/trunk/src/resources/add-realm/src/java/org/wyona/yanel/impl/resources
michi at wyona.com
michi at wyona.com
Fri Jul 20 14:40:05 CEST 2007
Author: michi
Date: 2007-07-20 14:40:05 +0200 (Fri, 20 Jul 2007)
New Revision: 26169
Modified:
public/yanel/trunk/src/resources/add-realm/src/java/org/wyona/yanel/impl/resources/AddRealmResource2.java
Log:
dump dir changed
Modified: public/yanel/trunk/src/resources/add-realm/src/java/org/wyona/yanel/impl/resources/AddRealmResource2.java
===================================================================
--- public/yanel/trunk/src/resources/add-realm/src/java/org/wyona/yanel/impl/resources/AddRealmResource2.java 2007-07-20 10:05:18 UTC (rev 26168)
+++ public/yanel/trunk/src/resources/add-realm/src/java/org/wyona/yanel/impl/resources/AddRealmResource2.java 2007-07-20 12:40:05 UTC (rev 26169)
@@ -568,7 +568,7 @@
getYanel().getRealmConfiguration().copyRealm(getTemplateRealmId(), realmidip.getValue(), realmnameip.getValue(), "/" + realmidip.getValue() + "/", new File(fsLocationValue));
fromExistingWebsiteElement.appendChild(doc.createElementNS(NAMESPACE, "realm-created"));
- importSite(urlip.getValue(), scopeip.getValue(), new Integer(cmpip.getValue()).intValue(), new Integer(cdip.getValue()).intValue(), new Integer(cmsip.getValue()).intValue(), realmidip.getValue());
+ importSite(urlip.getValue(), scopeip.getValue(), new Integer(cmpip.getValue()).intValue(), new Integer(cdip.getValue()).intValue(), new Integer(cmsip.getValue()).intValue(), realmidip.getValue(), fsLocationValue);
fromExistingWebsiteElement.appendChild(doc.createElementNS(NAMESPACE, "crawler-running"));
} catch (Exception e) {
log.error(e.getMessage(), e);
@@ -643,7 +643,7 @@
* @param realmID
* @throws Exception
*/
- protected void importSite(String crawlStartURL, String crawlScopeURL, int maxPages, int maxDepth, int maxPageSize, String realmID) throws Exception {
+ protected void importSite(String crawlStartURL, String crawlScopeURL, int maxPages, int maxDepth, int maxPageSize, String realmID, String baseDir) throws Exception {
String[] crawlScopeURLs = null;
if (crawlScopeURL == null || crawlScopeURL.length() == 0) {
String path = new URL(crawlStartURL).getPath();
@@ -657,7 +657,9 @@
crawlScopeURLs = crawlScopeURL.split(",");
}
- String dumpDir = System.getProperty("java.io.tmpdir") + File.separator + "import_" + System.currentTimeMillis();
+ //String dumpDir = System.getProperty("java.io.tmpdir") + File.separator + "import_" + System.currentTimeMillis();
+ String dumpDir = baseDir + File.separator + realmID + File.separator + "import_" + System.currentTimeMillis();
+ if (log.isDebugEnabled()) log.debug("Dump dir: " + dumpDir);
DumpingCrawler crawler = new DumpingCrawler(crawlStartURL, crawlScopeURLs, dumpDir);
crawler.setMaxPages(maxPages);
crawler.setMaxDepth(maxDepth);
More information about the Yanel-commits
mailing list