geode-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nabarun Nag <n...@apache.org>
Subject [DISCUSS] Addition of isValid API to Index interface
Date Fri, 08 Sep 2017 04:14:53 GMT
*Proposal:*
* Index interface will include an API - isValid() which will return true if
the index is still valid / uncorrupted, else will return false if it
corrupted / invalid.
* gfsh command "list index" will have one more column "Is Valid" which will
state the status as "true" or "false".
* Invalid indexes will not be used during query executions.
* In case the index is found to be invalid, the user will be able to
remove/destroy the index.
* When a put operation corrupts an index, it will be logged.

*Reasoning:*
* Currently if a put operation raises an exception while updating the
index, the put operation fails with an exception to the putter.
* For example, if an index is created on an object method, and that method
causes an exception while updating the index as a part of a put operation,
then the put operation fails for that particular entry and the index is
left in a bad state.
* This may occur also due to lack of permission to update index but have
permission to do puts.
* We are proposing that in the above mentioned scenarios, the put succeeds
in putting the entry in the region but the index which it was trying to
update will be marked invalid and will not be used for query executions.
* This can be justified because the corrupted index will not correctly
represent the region entries.

*Status Quo:*
* Index creation will still fail if we are trying to create an index over a
region containing an entry/entries  which will cause an exception while
loading the entry into the index.

Regards
Nabarun Nag

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message