Permalink
Browse files

remove deprecated properties.

  • Loading branch information...
1 parent f1f7345 commit 61eeb4466b88020c2bfe0605328cdc0011960e0a Robert Newson committed Mar 26, 2009
@@ -54,13 +54,8 @@
static final int MAX_LIMIT = Integer.getInteger("couchdb.lucene.max_fetch", 250);
-
static final int COMMIT_MIN = Integer.getInteger("couchdb.lucene.commit.min", 10 * 1000);
static final int COMMIT_MAX = Integer.getInteger("couchdb.lucene.commit.max", 5 * 60 * 1000);
- @Deprecated
- static final int TIME_THRESHOLD = 0;
- static final int CHANGE_THRESHOLD = 0;
-
}
@@ -16,8 +16,8 @@
* limitations under the License.
*/
-import static java.lang.Math.min;
import static java.lang.Math.max;
+import static java.lang.Math.min;
import java.io.IOException;
import java.util.HashSet;
@@ -155,7 +155,7 @@ public String execute(final IndexSearcher searcher) throws IOException {
stopWatch.lap("search");
// Fetch matches (if any).
final int max = max(0, min(td.totalHits - skip, limit));
-
+
final JSONArray rows = new JSONArray();
final String[] fetch_ids = new String[max];
for (int i = skip; i < skip + max; i++) {
@@ -200,7 +200,7 @@ public String execute(final IndexSearcher searcher) throws IOException {
result.put("code", 200);
final JSONObject headers = new JSONObject();
- headers.put("Cache-Control", "max-age=" + Config.TIME_THRESHOLD);
+ headers.put("Cache-Control", "max-age=" + Config.COMMIT_MAX / 1000);
// Results can't change unless the IndexReader does.
headers.put("ETag", etag);
result.put("headers", headers);

0 comments on commit 61eeb44

Please sign in to comment.