def filter_entity(org_name, app_name, collection_name, entity_data, source_client, target_client, attempts=0):
    """
    This is an example handler function which can filter entities. Multiple handler functions can be used to
    process a entity.  The response is an entity which will get passed to the next handler in the chain

    :param org_name: The org name from whence this entity came
    :param app_name: The app name from whence this entity came
    :param collection_name: The collection name from whence this entity came
    :param entity: The entity retrieved from the source instance
    :param source_client: The UsergridClient for the source Usergrid instance
    :param target_client: The UsergridClient for the target Usergrid instance
    :param attempts: the number of previous attempts this function was run (manual, not part of the framework)
    :return: an entity.  If response is None then the chain will stop.
    """

    # return None if you want to stop the chain (filter the entity out)
    if 'blah' in entity_data:
        return None

    # return the entity to keep going
    return entity_data