Local node indexing for unit testing behaves differently in 0.11.0

I have a number of unit tests that utilize a local node. Each test
starts a node, checks for the existence of an index the unit test will
be working with and creates the index if it does not exist.

In 0.10.0, the same index would get created for each unit test
(exception would be thrown for a count against the index and I would
create the index). Any documents that I index are never persisted
across a given unit test.

In 0.11.0, exception is only thrown for missing index if the work
directory is cleaned out. Once the index is created though, it is
found by each subsequent unit test run. Also, all documents I index
are persisted across tests.

If I revert back to 0.10.0, missing index exception is thrown for
count, index is created for each test, and no data is persisted across
test. If I then switch to 0.11.0, no missing index exception is
thrown for count and all data is persisted across tests.

Just want to make sure that this is expected. Thanks!

The default gateway for 0.11 has changed to the local one, meaning that
state + indices are retained across node restarts. You can configure
elasticsearch with the "none" gateway to have the same behavior
("gateway.type" set to "none").

On Thu, Sep 30, 2010 at 2:40 AM, dmcclure duane.mcclure@gmail.com wrote:

I have a number of unit tests that utilize a local node. Each test
starts a node, checks for the existence of an index the unit test will
be working with and creates the index if it does not exist.

In 0.10.0, the same index would get created for each unit test
(exception would be thrown for a count against the index and I would
create the index). Any documents that I index are never persisted
across a given unit test.

In 0.11.0, exception is only thrown for missing index if the work
directory is cleaned out. Once the index is created though, it is
found by each subsequent unit test run. Also, all documents I index
are persisted across tests.

If I revert back to 0.10.0, missing index exception is thrown for
count, index is created for each test, and no data is persisted across
test. If I then switch to 0.11.0, no missing index exception is
thrown for count and all data is persisted across tests.

Just want to make sure that this is expected. Thanks!

Yeah, even read that prior to post, just didn't want to sink in I
guess... thank you!

On Sep 30, 1:11 am, Shay Banon shay.ba...@elasticsearch.com wrote:

The default gateway for 0.11 has changed to the local one, meaning that
state + indices are retained across node restarts. You can configure
elasticsearch with the "none" gateway to have the same behavior
("gateway.type" set to "none").

On Thu, Sep 30, 2010 at 2:40 AM, dmcclure duane.mccl...@gmail.com wrote:

I have a number of unit tests that utilize a local node. Each test
starts a node, checks for the existence of an index the unit test will
be working with and creates the index if it does not exist.

In 0.10.0, the same index would get created for each unit test
(exception would be thrown for a count against the index and I would
create the index). Any documents that I index are never persisted
across a given unit test.

In 0.11.0, exception is only thrown for missing index if the work
directory is cleaned out. Once the index is created though, it is
found by each subsequent unit test run. Also, all documents I index
are persisted across tests.

If I revert back to 0.10.0, missing index exception is thrown for
count, index is created for each test, and no data is persisted across
test. If I then switch to 0.11.0, no missing index exception is
thrown for count and all data is persisted across tests.

Just want to make sure that this is expected. Thanks!