You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@geode.apache.org by nn...@apache.org on 2018/03/26 03:42:46 UTC
[geode] branch develop updated: GEODE-4827: null check for the
cache. (#1646)
This is an automated email from the ASF dual-hosted git repository.
nnag pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/geode.git
The following commit(s) were added to refs/heads/develop by this push:
new d79a2b2 GEODE-4827: null check for the cache. (#1646)
d79a2b2 is described below
commit d79a2b2d62e76e9bf39063930ca421446b195444
Author: Nabarun Nag <na...@users.noreply.github.com>
AuthorDate: Sun Mar 25 20:42:40 2018 -0700
GEODE-4827: null check for the cache. (#1646)
* While the servers are shutting down, getInstance may result in a null cache.
* This may result in NPE.
* NULL checks are added.
---
.../src/main/java/org/apache/geode/internal/cache/FilterProfile.java | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/geode-core/src/main/java/org/apache/geode/internal/cache/FilterProfile.java b/geode-core/src/main/java/org/apache/geode/internal/cache/FilterProfile.java
index 8a2e884..a0523cf 100755
--- a/geode-core/src/main/java/org/apache/geode/internal/cache/FilterProfile.java
+++ b/geode-core/src/main/java/org/apache/geode/internal/cache/FilterProfile.java
@@ -831,6 +831,11 @@ public class FilterProfile implements DataSerializableFixedID {
*/
void processRegisterCq(String serverCqName, ServerCQ ServerCQ, boolean addToCqMap,
GemFireCacheImpl cache) {
+ if (cache == null) {
+ logger.info("Error while initializing the CQs with FilterProfile for CQ " + serverCqName
+ + ", Error : Cache has been closed.");
+ return;
+ }
ServerCQ cq = (ServerCQ) ServerCQ;
try {
CqService cqService = cache.getCqService();
--
To stop receiving notification emails like this one, please contact
nnag@apache.org.