[ https://issues.apache.org/jira/browse/GEODE-9409?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17397925#comment-17397925 ]
ASF subversion and git services commented on GEODE-9409: -------------------------------------------------------- Commit 88860d03a1f02130f243201ed057bd460d0e0492 in geode's branch refs/heads/develop from Mario Kevo [ https://gitbox.apache.org/repos/asf?p=geode.git;h=88860d0 ] GEODE-9409: wait for PdxRegistry before executing create region (#6743) * GEODE-9409: wait for PdxRegistry is finished before executing create region > NullPointerException while create region during server restart > -------------------------------------------------------------- > > Key: GEODE-9409 > URL: https://issues.apache.org/jira/browse/GEODE-9409 > Project: Geode > Issue Type: Bug > Components: gfsh, regions > Reporter: Mario Kevo > Assignee: Mario Kevo > Priority: Major > Labels: pull-request-available > > If the "create region" command is executed while the Geode server is > restarting it will fail with NullPointerException on that server. > It happens for persistent regions as it tries to findDiskStore but in that > method, it first tries to get PdxRegistry from the cache and create a > persistent Region on that. But in that case, when the cache is creating(it > takes some more time if the server is restarting), if the command is executed > fast it happened that creating cache is not finished and pdxRegistry is null, > so every method executed on that will throw NullPointerException. > > {code:java} > gfsh>create region --name=/test_region2 --type=PARTITION_REDUNDANT_PERSISTENT > --total-num-buckets=113 --disk-store=dataDiskStore > --enable-synchronous-disk=false > Member | Status | Message > ------- | ------ | > ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- > server1 | OK | Region "/test_region2" created on "server1" > server2 | OK | Region "/test_region2" created on "server2" > server3 | ERROR | java.lang.NullPointerException > at > org.apache.geode.internal.cache.LocalRegion.findDiskStore(LocalRegion.java:7498) > at > org.apache.geode.internal.cache.PartitionedRegion.findDiskStore(PartitionedRe.. > Cluster configuration for group 'cluster' is updated. > {code} > -- This message was sent by Atlassian Jira (v8.3.4#803005)