Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

org.elasticsearch.index.translog.TranslogTests#testStats failing on 6.8 #55064

Closed
dliappis opened this issue Apr 10, 2020 · 3 comments
Closed
Assignees
Labels
:Distributed Indexing/Engine Anything around managing Lucene and the Translog in an open shard. >test-failure Triaged test failures from CI

Comments

@dliappis
Copy link
Contributor

Observed a failure on branch 6.8 for TranslogTests in #testStats:

  | FAILURE 0.02s J15 \| TranslogTests.testStats <<< FAILURES! |  
  | > Throwable #1: java.lang.AssertionError: |  
  | > Expected: a value greater than <1L> |  
  | >      but: <1L> was equal to <1L> |  
  | > 	at __randomizedtesting.SeedInfo.seed([6B2A44E9E0939A49:F1AB1D56884F546A]:0) |  
  | > 	at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:20) |  
  | > 	at org.elasticsearch.index.translog.TranslogTests.testStats(TranslogTests.java:439) |  
  | > 	at java.lang.Thread.run(Thread.java:748)

Reproduction line:

./gradlew ':server:unitTest' -Dtests.seed=6B2A44E9E0939A49 -Dtests.class=org.elasticsearch.index.translog.TranslogTests -Dtests.method="testStats" -Dtests.security.manager=true -Dtests.locale=ru -Dtests.timezone=SystemV/MST7MDT -Dcompiler.java=12 -Druntime.java=8

Unfortunately I wasn't able to reproduce after 50 iterations on the same operating system.

CI link: https://elasticsearch-ci.elastic.co/job/elastic+elasticsearch+6.8+matrix-java-periodic/ES_RUNTIME_JAVA=adoptopenjdk8,nodes=general-purpose/622/console / https://gradle-enterprise.elastic.co/s/6xn7qjvruu5x6

Interestingly enough this is the first time if fails on 6.8, however, there were a number of failures on master in February that got fixed by #51905.

@dnhatn :

The specific line in 6.8 asserts >1 in

assertThat(stats.getEarliestLastModifiedAge(), greaterThan(1L));

however, in #51905, we started asserting >0

assertThat(stats.getEarliestLastModifiedAge(), greaterThan(0L));

Is there a reason for this difference?

@dliappis dliappis added >test-failure Triaged test failures from CI :Distributed Indexing/Engine Anything around managing Lucene and the Translog in an open shard. labels Apr 10, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-distributed (:Distributed/Engine)

@dnhatn
Copy link
Member

dnhatn commented Apr 10, 2020

Thanks @dliappis. I've opened #55085.

@dnhatn dnhatn self-assigned this Apr 10, 2020
dnhatn added a commit that referenced this issue Apr 11, 2020
This test failed because it was executed too fast :D. If creating the 
first translog generation and checking the translog stats happen within
the same second, then the earliestLastModifiedAge will be zero.

Closes #55064
@dnhatn
Copy link
Member

dnhatn commented Apr 11, 2020

Fixed in #55085

@dnhatn dnhatn closed this as completed Apr 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Distributed Indexing/Engine Anything around managing Lucene and the Translog in an open shard. >test-failure Triaged test failures from CI
Projects
None yet
Development

No branches or pull requests

3 participants