Skip to content

Conversation

@stephenykp
Copy link
Member

  • Improved speed of deletebyquery tool by moving cassandra delete to each solr page delete
  • Added -f and --force flag that will skip the prompts before deleting


doc_ids.extend([uuid.UUID(doc['id']) for doc in solr_response.result.response.docs])
ids = [uuid.UUID(doc['id']) for doc in solr_response.result.response.docs]
delete_from_cassandra(ids)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you moved the cassandra delete into the do_solr_query function? This seems like it would break things. do_solr_query is collecting all of the tile ids that need to be deleted. Once that is done it asks the user to confirm the number of documents before executing the delete. With this new flow, the cassandra rows get removed before the solr docs and a user could decide to cancel without realizing data has already been deleted.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@frankinspace Whoops, good point. I'll refactor this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants