clerezza-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r...@apache.org
Subject svn commit: r1476911 - in /clerezza/trunk/rdf.cris/core: nbactions.xml src/main/java/org/apache/clerezza/rdf/cris/LuceneTools.java
Date Mon, 29 Apr 2013 07:36:02 GMT
Author: reto
Date: Mon Apr 29 07:36:02 2013
New Revision: 1476911

URL: http://svn.apache.org/r1476911
Log:
CLEREZZA-778: reenabled optimizeIndex

Added:
    clerezza/trunk/rdf.cris/core/nbactions.xml
Modified:
    clerezza/trunk/rdf.cris/core/src/main/java/org/apache/clerezza/rdf/cris/LuceneTools.java

Added: clerezza/trunk/rdf.cris/core/nbactions.xml
URL: http://svn.apache.org/viewvc/clerezza/trunk/rdf.cris/core/nbactions.xml?rev=1476911&view=auto
==============================================================================
--- clerezza/trunk/rdf.cris/core/nbactions.xml (added)
+++ clerezza/trunk/rdf.cris/core/nbactions.xml Mon Apr 29 07:36:02 2013
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<actions>
+  <action>
+    <actionName>CUSTOM-deploy to localhost:8080</actionName>
+    <displayName>deploy to localhost:8080</displayName>
+    <goals>
+      <goal>install</goal>
+      <goal>org.apache.sling:maven-sling-plugin:install</goal>
+    </goals>
+  </action>
+</actions>

Modified: clerezza/trunk/rdf.cris/core/src/main/java/org/apache/clerezza/rdf/cris/LuceneTools.java
URL: http://svn.apache.org/viewvc/clerezza/trunk/rdf.cris/core/src/main/java/org/apache/clerezza/rdf/cris/LuceneTools.java?rev=1476911&r1=1476910&r2=1476911&view=diff
==============================================================================
--- clerezza/trunk/rdf.cris/core/src/main/java/org/apache/clerezza/rdf/cris/LuceneTools.java
(original)
+++ clerezza/trunk/rdf.cris/core/src/main/java/org/apache/clerezza/rdf/cris/LuceneTools.java
Mon Apr 29 07:36:02 2013
@@ -235,7 +235,7 @@ public class LuceneTools {
      * //no more, see: http://www.searchworkings.org/blog/-/blogs/simon-says%3A-optimize-is-bad-for-you
      */
     synchronized public void optimizeIndex() {
-      /*  if(optimizeInProgress) {
+        if(optimizeInProgress) {
             return;
         }
         new Thread(new Runnable() {
@@ -250,7 +250,7 @@ public class LuceneTools {
                     @Override
                     public Void run() {
                         try {
-                            getIndexWriter().optimize(true);
+                            getIndexWriter().forceMerge(1, true);
                             commit();
                             logger.info("Index optimized.");
                         } catch(IOException ex) {
@@ -266,7 +266,7 @@ public class LuceneTools {
                     }
                 });
             }
-        }).start();*/
+        }).start();  
     }
     
     @Override



Mime
View raw message