Permalink
Browse files

Removing stale for more performance.

  • Loading branch information...
1 parent b232dea commit f2e8f12f454a139724a2cf55a2b0c71a31162d73 @daschl daschl committed Dec 12, 2012
View
5 src/main/java/com/couchbase/beersample/BeerServlet.java
@@ -150,7 +150,7 @@ private void handleIndex(HttpServletRequest request,
View view = client.getView("beer", "by_name");
Query query = new Query();
- query.setStale(Stale.FALSE).setIncludeDocs(true).setLimit(20);
+ query.setIncludeDocs(true).setLimit(20);
ViewResponse result = client.query(view, query);
ArrayList<HashMap<String, String>> beers =
@@ -262,8 +262,7 @@ private void handleSearch(HttpServletRequest request,
Query query = new Query();
- query.setStale(Stale.FALSE)
- .setIncludeDocs(true)
+ query.setIncludeDocs(true)
.setLimit(20)
.setRangeStart(ComplexKey.of(startKey))
.setRangeEnd(ComplexKey.of(startKey + "\uefff"));
View
5 src/main/java/com/couchbase/beersample/BreweryServlet.java
@@ -114,7 +114,7 @@ private void handleIndex(HttpServletRequest request,
View view = client.getView("brewery", "by_name");
Query query = new Query();
- query.setStale(Stale.FALSE).setIncludeDocs(true).setLimit(20);
+ query.setIncludeDocs(true).setLimit(20);
ViewResponse result = client.query(view, query);
ArrayList<HashMap<String, String>> breweries =
@@ -203,8 +203,7 @@ private void handleSearch(HttpServletRequest request,
Query query = new Query();
- query.setStale(Stale.FALSE)
- .setIncludeDocs(true)
+ query.setIncludeDocs(true)
.setLimit(20)
.setRangeStart(ComplexKey.of(startKey))
.setRangeEnd(ComplexKey.of(startKey + "\uefff"));

0 comments on commit f2e8f12

Please sign in to comment.