[
https://issues.apache.org/jira/browse/GEODE-1190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15241856#comment-15241856
]
ASF GitHub Bot commented on GEODE-1190:
---------------------------------------
GitHub user nabarunnag opened a pull request:
https://github.com/apache/incubator-geode/pull/129
GEODE-1190: LuceneServiceProvider.get now accepts GemFireCache as a
parameter.
GEODE-1190: LuceneServiceProvider.get now accepts GemFireCache as a
parameter.
* Modified the LuceneServiceProvider.get function signature to use
GemFireCache as a parameter.
* Wrote a small test case to check that LuceneServiceProvider.get does not
return null when ClientCache is passed as a parameter.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/nabarunnag/incubator-geode feature/GEODE-1190
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/incubator-geode/pull/129.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #129
----
commit 02607af9bbcbdb79588d70f1d2b5b4b7930df999
Author: nabarun <[email protected]>
Date: 2016-04-14T01:13:37Z
GEODE-1190: LuceneServiceProvider.get now accepts GemFireCache as a
parameter.
* Modified the LuceneServiceProvider.get function signature to use
GemFireCache as a parameter.
* Wrote a small test case to check that LuceneServiceProvider.get does not
return null when ClientCache is passed as a parameter.
----
> Should the LuceneServiceProvider get API take a GemFireCache instead of a
> Cache?
> --------------------------------------------------------------------------------
>
> Key: GEODE-1190
> URL: https://issues.apache.org/jira/browse/GEODE-1190
> Project: Geode
> Issue Type: Bug
> Components: lucene
> Reporter: Barry Oglesby
>
> Should the LuceneServiceProvider get API take a GemFireCache instead of a
> Cache?
> The {{LuceneServiceProvider get}} API takes a {{Cache}} like:
> {noformat}
> public static LuceneService get(Cache cache)
> {noformat}
> If I create a {{ClientCache}}, I can't pass that into this method.
> Code like this doesn't compile:
> {noformat}
> ClientCache cache = new ClientCacheFactory().create();
> LuceneService luceneService = LuceneServiceProvider.get(cache);
> {noformat}
> Instead I have to cast the {{ClientCache}} to a {{Cache}}, but that doesn't
> seem right:
> {noformat}
> ClientCache clientCache = new ClientCacheFactory().create();
> LuceneService luceneService = LuceneServiceProvider.get((Cache) clientCache);
> {noformat}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)