[ https://issues.apache.org/jira/browse/GEODE-2595?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15905416#comment-15905416 ]
ASF GitHub Bot commented on GEODE-2595: --------------------------------------- Github user gesterzhou commented on a diff in the pull request: https://github.com/apache/geode/pull/421#discussion_r105441883 --- Diff: geode-lucene/src/main/java/org/apache/geode/cache/lucene/LuceneService.java --- @@ -37,15 +36,17 @@ * </p> * <p> * Lucene indexes can be created using gfsh, xml, or the java API. Below is an example of creating a - * Lucene index with the java API. The Lucene index created on each member that will host data for - * the region. + * Lucene index with the java API. The Lucene index should be created on each member that has the + * region that is being indexed. * </p> * * <pre> * { * @code - * LuceneIndex index = - * luceneService.createIndex(indexName, regionName, "field1", "field2", "field3"); +* luceneService.createCreateIndexFactory() --- End diff -- I don't like the name "createCreateIndexFactory". 2 create? > Change LuceneService.createIndex to use a factory pattern > --------------------------------------------------------- > > Key: GEODE-2595 > URL: https://issues.apache.org/jira/browse/GEODE-2595 > Project: Geode > Issue Type: Improvement > Components: lucene > Reporter: Dan Smith > Assignee: Dan Smith > Fix For: 1.2.0 > > > Before we remove the Experimental annotation from the LuceneService, we > should change createIndex to use a factory pattern rather than having a > single method with parameters to create the index. In other words, the method > needs to change from: > {code} > luceneService.createIndex(region, index, ...) > {code} > to > {code} > luceneService.createIndexFactory() > .setXXX() > .setYYY() > .create() > {code} > This will allow us to add additional set methods in the future to configure > other things like the async event queue batch size, etc. -- This message was sent by Atlassian JIRA (v6.3.15#6346)