Skip to content

Conversation

@mayya-sharipova
Copy link
Contributor

Add debug log when index is flushed to investigate a failure
in IndicesRequestCacheIT

"DEBUG" level is used as "TRACES" produces too much output irrelevant for this
issue

Relates to #32827

Add debug log when index is flushed to investigate a failure
in IndicesRequestCacheIT

"DEBUG" level is used as "TRACES" produces too  much output irrelevant for this
issue

Relates to elastic#32827
@mayya-sharipova mayya-sharipova added >test Issues or PRs that are addressing/adding tests :Search/Search Search-related issues that do not fall into other categories labels Feb 27, 2019
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-search

Copy link
Member

@cbuescher cbuescher left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@colings86 colings86 left a comment

Choose a reason for hiding this comment

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

I left a couple of suggestions in case we can get extra information but I'll leave them up to you as I'm not sure about the risk that the extra logging might cause the test failure to not reproduce due to changing the timing so there is probably an argument for being careful how much we do at one time.

logger.trace("finished commit for flush");

// a temporary debugging to investigate test failure - issue#32827. Remove when the issue is resolved
logger.debug("new commit on flush");
Copy link
Contributor

Choose a reason for hiding this comment

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

It might help to know which of the conditions (indexWriter.hasUncommittedChanges(), force or shouldPeriodicallyFlush()) triggered this flush to help us work out what is causing this?

import static org.hamcrest.Matchers.greaterThan;

@TestLogging(value = "org.elasticsearch.indices.IndicesRequestCache:TRACE")
@TestLogging(value = "org.elasticsearch.indices.IndicesRequestCache:TRACE,org.elasticsearch.index.engine.Engine:DEBUG")
Copy link
Contributor

Choose a reason for hiding this comment

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

I wonder if we should actually enable trace logging on the Engine for this test? My thought here is with trace logging we might also be able to see if the unexpected flush is waiting for an ongoing flush or if its acquired immediately?

@mayya-sharipova
Copy link
Contributor Author

@cbuescher, @colings86 thanks for the review
@colings86 I have added conditions that trigged flush into debugging. I have opted to for now keep the log level to debug instead of trace, as trace produces a big amount of output. Later we may switch to trace if we still haven't found an explanation.

@mayya-sharipova
Copy link
Contributor Author

@elasticmachine run elasticsearch-ci/1

@mayya-sharipova mayya-sharipova merged commit 29938b1 into elastic:master Feb 28, 2019
@mayya-sharipova mayya-sharipova deleted the debug-flush-IndicesRequestCacheIT branch February 28, 2019 20:41
mayya-sharipova added a commit that referenced this pull request Mar 1, 2019
Add debug log when index is flushed to investigate a failure
in IndicesRequestCacheIT

"DEBUG" level is used as "TRACE" produces too  much output irrelevant for this
issue

Relates to #32827
javanna added a commit to javanna/elasticsearch that referenced this pull request Sep 17, 2020
In the context of of a recurring test failure tracked by elastic#32827, we added trace logging and an extra cache key renderer argument to IndicesRequestCache#getOrCompute (see elastic#39475 and elastic#34180).

We addressed the issue with elastic#54071, but the extra argument was left behind, with a NORELEASE comment saying it should be removed.

With this commit, we remove the extra cache key rendered argument and the corresponding log lines which are not so useful without it.

Closes elastic#55837
javanna added a commit that referenced this pull request Sep 18, 2020
In the context of of a recurring test failure tracked by #32827, we added trace logging and an extra cache key renderer argument to IndicesRequestCache#getOrCompute (see #39475 and #34180).

We addressed the issue with #54071, but the extra argument was left behind, with a NORELEASE comment saying it should be removed.

With this commit, we remove the extra cache key rendered argument and the corresponding log lines which are not so useful without it.

Closes #55837
javanna added a commit to javanna/elasticsearch that referenced this pull request Sep 18, 2020
…62534)

In the context of of a recurring test failure tracked by elastic#32827, we added trace logging and an extra cache key renderer argument to IndicesRequestCache#getOrCompute (see elastic#39475 and elastic#34180).

We addressed the issue with elastic#54071, but the extra argument was left behind, with a NORELEASE comment saying it should be removed.

With this commit, we remove the extra cache key rendered argument and the corresponding log lines which are not so useful without it.

Closes elastic#55837
javanna added a commit that referenced this pull request Sep 18, 2020
In the context of of a recurring test failure tracked by #32827, we added trace logging and an extra cache key renderer argument to IndicesRequestCache#getOrCompute (see #39475 and #34180).

We addressed the issue with #54071, but the extra argument was left behind, with a NORELEASE comment saying it should be removed.

With this commit, we remove the extra cache key rendered argument and the corresponding log lines which are not so useful without it.

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

Labels

:Search/Search Search-related issues that do not fall into other categories >test Issues or PRs that are addressing/adding tests v7.2.0 v8.0.0-alpha1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants