[ https://issues.apache.org/jira/browse/GEODE-2266?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15802073#comment-15802073 ]
Jason Huynh commented on GEODE-2266: ------------------------------------ This chunk of code in executioncontext allows the un value-constrained non alias index to be created {code} if (!TypeUtils.OBJECT_TYPE.equals(itr.getElementType()) && itr.containsProperty(name, numArgs, mustBeMethod)) { hits.add(itr); } else if (TypeUtils.OBJECT_TYPE.equals(itr.getElementType())) { if (foundOneUnknown) { oneUnknown = null; // more than one } else { foundOneUnknown = true; oneUnknown = itr; } } {code} > index creation with value constraint of PdxInstance should not validate > indexed field > ------------------------------------------------------------------------------------- > > Key: GEODE-2266 > URL: https://issues.apache.org/jira/browse/GEODE-2266 > Project: Geode > Issue Type: Bug > Components: querying > Reporter: Jason Huynh > Assignee: Jason Huynh > > When creating an index on a region with a value constraint, we validate that > the indexed field exists as a value for the value constraint object type. It > makes sense to validate this field exists on a user domain object as the > index would be useless if the field did not exist for the only object type > for this region. However if the value constraint is a PdxInstance, we should > not validate this field exists and instead treat it similar to a non value > constrained region. This is because the PdxInstance can represent any object > type and the field is not specifically a field on the PdxInstance object but > rather a field on the pdx serialized object. -- This message was sent by Atlassian JIRA (v6.3.4#6332)