[ https://issues.apache.org/jira/browse/GEODE-2216?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15788023#comment-15788023 ]
ASF subversion and git services commented on GEODE-2216: -------------------------------------------------------- Commit 19047faf864f1f57dadb6eb53ebe767991a33295 in geode's branch refs/heads/develop from [~huynhja] [ https://git-wip-us.apache.org/repos/asf?p=geode.git;h=19047fa ] GEODE-2216: Indexes no longer get removed but instead do not set populated flag > PartitionedRegion.createIndexes ignores exceptions, resulting in corrupt > indexes > -------------------------------------------------------------------------------- > > Key: GEODE-2216 > URL: https://issues.apache.org/jira/browse/GEODE-2216 > Project: Geode > Issue Type: Bug > Components: querying > Reporter: Dan Smith > Assignee: Dan Smith > Fix For: 1.1.0 > > > I tried to create an index on a region with objects that could not be > deserialized (it was a mistake in my code). I found that it actually > *allowed* me to create the index, but my values were not actually indexed. > Looking at the code in PartitionedRegion.createIndexes, it has some > interesting code to maintain a boolean flag that an exception should be > thrown. However, it keeps losing the value of the flag. Here's some of the > code: > {code} > boolean throwException = false; > ... > throwException = > createEmptyIndexes(indexDefinitions, remotelyOriginated, indexes, > exceptionsMap); > ... > //This overwrites the value of throwException > if (unpopulatedIndexes != null && unpopulatedIndexes.size() > 0) { > throwException = populateEmptyIndexes(unpopulatedIndexes, > exceptionsMap); > } > //Same thing here > throwException = > sendCreateIndexesMessage(remotelyOriginated, indexDefinitions, > indexes, exceptionsMap); > {code} > This method should always throw an exception if the index creation failed. -- This message was sent by Atlassian JIRA (v6.3.4#6332)