Skip to content

Remove index value for existing object #81

Description

@pavelsmolka

Let $object be \Riak\Object. It is easy to add new values to be indexed via secodary index (available for leveldb):

$object->addIndex($indexName, $indexValue);

When the $object already have some index values, it is also possible to read them, such as:

$indexMap = $object->getIndexMap();

However, there is no option to remove an existing index. This would be particularly useful when updating an existing record (re-writing $object retrieved via $object = $riakEntity->getFirstObject();). If I need to remove an existing index, I need to create a new Riak\Object and copy all values. It would be nice to have a method to remove an existing index, such as:

$object->removeIndex($indexName);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions