I'm writing a Ruby application and doing some testing with RSpec. As part
of the RSpec setup process I'm creating indexes with the string "_test"
appended to the name.
After each test, I delete the indexes to ensure the data is clean for the
next test. However, I would like to avoid doing all of if possible.
Is there a command to simply clear and existing index?
I think dropping the index is the best option here. if you use delete by
query mappings will stay around that will not work for your tests.
What is your concern, performance?
simon
On Tuesday, August 6, 2013 9:14:50 PM UTC+2, Brandon Hilkert wrote:
I'm writing a Ruby application and doing some testing with RSpec. As part
of the RSpec setup process I'm creating indexes with the string "_test"
appended to the name.
After each test, I delete the indexes to ensure the data is clean for the
next test. However, I would like to avoid doing all of if possible.
Is there a command to simply clear and existing index?
Yeah, I have to add a non-trivial amount of sleep before each test to make
sure the test doesn't run before the index creation and fixture data gets
pushed.
I think dropping the index is the best option here. if you use delete by
query mappings will stay around that will not work for your tests.
What is your concern, performance?
simon
On Tuesday, August 6, 2013 9:14:50 PM UTC+2, Brandon Hilkert wrote:
I'm writing a Ruby application and doing some testing with RSpec. As part
of the RSpec setup process I'm creating indexes with the string "_test"
appended to the name.
After each test, I delete the indexes to ensure the data is clean for the
next test. However, I would like to avoid doing all of if possible.
Is there a command to simply clear and existing index?
Yeah, I have to add a non-trivial amount of sleep before each test to make sure the test doesn't run before the index creation and fixture data gets pushed.
I think dropping the index is the best option here. if you use delete by query mappings will stay around that will not work for your tests.
What is your concern, performance?
simon
On Tuesday, August 6, 2013 9:14:50 PM UTC+2, Brandon Hilkert wrote:
I'm writing a Ruby application and doing some testing with RSpec. As part of the RSpec setup process I'm creating indexes with the string "_test" appended to the name.
After each test, I delete the indexes to ensure the data is clean for the next test. However, I would like to avoid doing all of if possible.
Is there a command to simply clear and existing index?
Yeah, I have to add a non-trivial amount of sleep before each test to make
sure the test doesn't run before the index creation and fixture data gets
pushed.
I think dropping the index is the best option here. if you use delete by
query mappings will stay around that will not work for your tests.
What is your concern, performance?
simon
On Tuesday, August 6, 2013 9:14:50 PM UTC+2, Brandon Hilkert wrote:
I'm writing a Ruby application and doing some testing with RSpec. As
part of the RSpec setup process I'm creating indexes with the string
"_test" appended to the name.
After each test, I delete the indexes to ensure the data is clean for
the next test. However, I would like to avoid doing all of if possible.
Is there a command to simply clear and existing index?
--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearch+unsubscribe@googlegroups.com.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.