[ 
https://issues.apache.org/jira/browse/IGNITE-9948?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16660663#comment-16660663
 ] 

Amelchev Nikita commented on IGNITE-9948:
-----------------------------------------

Hi, [~kuaw26]. Could you some clarify with the test issue?

The test creates and destroys caches with different configurations.
Sometimes the test fails with NPE. The reason is in the test:
1. jetty sends create cache query
2. Checkpoints on nodes take some more time than session timeout. (I found two 
incident in TC, with checkpoint time 32-35 seconds. Default session timeout is 
30 sec)
3. The test fails with NPE while checking that cache will be created.

I suggest to add the additional check after the jetty query(See my PR). This 
will clarify the cause of the fall. 

Can we increase session timeout to avoid test failing? Or how correctly handle 
this error?

The log clipping with checkpoints metrics:

{noformat}
[2018-10-10 00:19:56,858][INFO 
][db-checkpoint-thread-#3926%rest.JettyRestProcessorAuthenticationWithTokenSelfTest0%][GridCacheDatabaseSharedManager]
 Checkpoint finished [cpId=22760bff-a7e1-4267-8333-8df94db3a909, pages=29, 
markPos=FileWALPointer [idx=0, fileOff=0, len=0], walSegmentsCleared=0, 
walSegmentsCovered=[], markDuration=2940ms, pagesWrite=1ms, fsync=28485ms, 
total=31426ms]
[2018-10-10 00:19:56,862][INFO 
][db-checkpoint-thread-#3931%rest.JettyRestProcessorAuthenticationWithTokenSelfTest2%][GridCacheDatabaseSharedManager]
 Checkpoint finished [cpId=1fad88b8-a99e-47ca-a7e3-bede10dd9ded, pages=29, 
markPos=FileWALPointer [idx=0, fileOff=0, len=0], walSegmentsCleared=0, 
walSegmentsCovered=[], markDuration=2924ms, pagesWrite=1ms, fsync=28490ms, 
total=31415ms]
[2018-10-10 00:19:56,868][INFO 
][db-checkpoint-thread-#3920%rest.JettyRestProcessorAuthenticationWithTokenSelfTest1%][GridCacheDatabaseSharedManager]
 Checkpoint finished [cpId=5310c17f-7f52-43a6-bef2-d36d0d46be7f, pages=29, 
markPos=FileWALPointer [idx=0, fileOff=0, len=0], walSegmentsCleared=0, 
walSegmentsCovered=[], markDuration=3039ms, pagesWrite=1ms, fsync=28496ms, 
total=31536ms]



[2018-10-19 06:59:39,038][INFO 
][db-checkpoint-thread-#4009%rest.JettyRestProcessorAuthenticationWithTokenSelfTest1%][GridCacheDatabaseSharedManager]
 Checkpoint finished [cpId=22ac1abc-46e7-426a-a33f-e28bff164d4c, pages=29, 
markPos=FileWALPointer [idx=0, fileOff=0, len=0], walSegmentsCleared=0, 
walSegmentsCovered=[], markDuration=14482ms, pagesWrite=3ms, fsync=20525ms, 
total=35010ms]
[2018-10-19 06:59:39,038][INFO 
][db-checkpoint-thread-#4020%rest.JettyRestProcessorAuthenticationWithTokenSelfTest0%][GridCacheDatabaseSharedManager]
 Checkpoint finished [cpId=77effa54-ad3c-4036-a3f2-efc23f283928, pages=29, 
markPos=FileWALPointer [idx=0, fileOff=0, len=0], walSegmentsCleared=0, 
walSegmentsCovered=[], markDuration=14431ms, pagesWrite=2ms, fsync=20525ms, 
total=34958ms]
[2018-10-19 06:59:39,038][INFO 
][db-checkpoint-thread-#4008%rest.JettyRestProcessorAuthenticationWithTokenSelfTest2%][GridCacheDatabaseSharedManager]
 Checkpoint finished [cpId=2c6b7d4e-0e2d-4341-a678-0a9031f27b3c, pages=29, 
markPos=FileWALPointer [idx=0, fileOff=0, len=0], walSegmentsCleared=0, 
walSegmentsCovered=[], markDuration=14479ms, pagesWrite=1ms, fsync=20530ms, 
total=35010ms]
{noformat}


>  JettyRestProcessorAuthenticationWithTokenSelfTest.testGetOrCreateCache fails 
> on TC
> -----------------------------------------------------------------------------------
>
>                 Key: IGNITE-9948
>                 URL: https://issues.apache.org/jira/browse/IGNITE-9948
>             Project: Ignite
>          Issue Type: Bug
>            Reporter: Amelchev Nikita
>            Assignee: Amelchev Nikita
>            Priority: Major
>              Labels: MakeTeamcityGreenAgain
>             Fix For: 2.8
>
>
> [Example of 
> fail.|https://ci.ignite.apache.org/viewLog.html?buildId=2118632&tab=buildResultsDiv&buildTypeId=IgniteTests24Java8_JavaClient#testNameId-4416495803371140089]
>  Log details:
> {noformat}
> [2018-10-19 06:59:53,063][ERROR][main][root] Test failed.
> java.lang.NullPointerException
> at 
> org.apache.ignite.internal.processors.rest.JettyRestProcessorAbstractSelfTest.checkGetOrCreateAndDestroy(JettyRestProcessorAbstractSelfTest.java:593)
> at 
> org.apache.ignite.internal.processors.rest.JettyRestProcessorAbstractSelfTest.testGetOrCreateCache(JettyRestProcessorAbstractSelfTest.java:619)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:498)
> at junit.framework.TestCase.runTest(TestCase.java:176)
> at 
> org.apache.ignite.testframework.junits.GridAbstractTest.runTestInternal(GridAbstractTest.java:2176)
> at 
> org.apache.ignite.testframework.junits.GridAbstractTest.access$000(GridAbstractTest.java:142)
> at 
> org.apache.ignite.testframework.junits.GridAbstractTest$5.run(GridAbstractTest.java:2091)
> at java.lang.Thread.run(Thread.java:748){noformat}
> The possible reason is the race between getting cache instance on different 
> nodes:
> # Jetty query create cache successfully on one node.
> # PME doesn't have completed.
> # The test fails with NPE while getting the instance of cache on another node.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to