You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geode.apache.org by Jakov Varenina <ja...@est.tech> on 2021/05/11 15:57:02 UTC
Exception when trying to use Continuous Queries in geode-wan module
distributed test
Hi all,
I'm trying to create distributed test in geode-wan module that combines
WAN and CQ functionality. When I execute the test case, I always get the
following error:
java.lang.IllegalStateException: CqService is not available.
at
org.apache.geode.cache.query.internal.cq.MissingCqService.start(MissingCqService.java:158)
at
org.apache.geode.cache.query.internal.DefaultQueryService.getCqService(DefaultQueryService.java:829)
at
org.apache.geode.cache.query.internal.DefaultQueryService.newCq(DefaultQueryService.java:569)
at
org.apache.geode.internal.cache.wan.parallel.ParallelGatewaySenderOperationClusterConfigDUnitTest.lambda$createDurableCQs$96c20508$1(ParallelGatewaySenderOperationClusterConfigDUnitTest.java:126)
It seems that the CqService is statically initialized using java service
provider interface:
- service provider class:
https://github.com/apache/geode/blob/a5bd36f9fa787d3a71c6e6efafed5a7b0fe52d2b/geode-core/src/main/java/org/apache/geode/cache/query/internal/cq/CqServiceProvider.java
- meta-inf.services file:
https://github.com/apache/geode/blob/a5bd36f9fa787d3a71c6e6efafed5a7b0fe52d2b/geode-cq/src/main/resources/META-INF/services/org.apache.geode.cache.query.internal.cq.spi.CqServiceFactory
So if I understood above exception correctly, the CqService cannot be
used in distributed test in geode-wan module, because it won't be
statically initialized in that case. Is this correct?
Do you maybe know how to overcome this issue?
Please feel free to ask any additional information or correct me if I
misunderstood this exception completely.
BRs/Jakov
Re: Exception when trying to use Continuous Queries in geode-wan
module distributed test
Posted by Jakov Varenina <ja...@est.tech>.
You can ignore this question, because I have been able to resolve it by
adding geode-cq dependency to geode-wan/build.gradle
Sorry to bother you all like this.
On 11. 05. 2021. 17:57, Jakov Varenina wrote:
> Hi all,
>
> I'm trying to create distributed test in geode-wan module that
> combines WAN and CQ functionality. When I execute the test case, I
> always get the following error:
>
> java.lang.IllegalStateException: CqService is not available.
> at
> org.apache.geode.cache.query.internal.cq.MissingCqService.start(MissingCqService.java:158)
> at
> org.apache.geode.cache.query.internal.DefaultQueryService.getCqService(DefaultQueryService.java:829)
> at
> org.apache.geode.cache.query.internal.DefaultQueryService.newCq(DefaultQueryService.java:569)
> at
> org.apache.geode.internal.cache.wan.parallel.ParallelGatewaySenderOperationClusterConfigDUnitTest.lambda$createDurableCQs$96c20508$1(ParallelGatewaySenderOperationClusterConfigDUnitTest.java:126)
>
> It seems that the CqService is statically initialized using java
> service provider interface:
>
> - service provider class:
> https://github.com/apache/geode/blob/a5bd36f9fa787d3a71c6e6efafed5a7b0fe52d2b/geode-core/src/main/java/org/apache/geode/cache/query/internal/cq/CqServiceProvider.java
>
> - meta-inf.services file:
> https://github.com/apache/geode/blob/a5bd36f9fa787d3a71c6e6efafed5a7b0fe52d2b/geode-cq/src/main/resources/META-INF/services/org.apache.geode.cache.query.internal.cq.spi.CqServiceFactory
>
> So if I understood above exception correctly, the CqService cannot be
> used in distributed test in geode-wan module, because it won't be
> statically initialized in that case. Is this correct?
>
> Do you maybe know how to overcome this issue?
>
> Please feel free to ask any additional information or correct me if I
> misunderstood this exception completely.
>
> BRs/Jakov
>
>
>
>
>