Uploaded image for project: 'Ignite'
  1. Ignite
  2. IGNITE-15454

ITSchemaChangeTableViewTest hangs on the main branch

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 3.0.0-alpha3
    • None

    Description

      A number of integration tests (SchemaChangeKVViewTest, SchemaChangeTableViewTest, LiveSchemaChangeTableTest, LiveSchemaChangeKVViewTest) hang with the following exception:

       

      2021-09-04 16:37:42:122 +0300 [ERROR][Thread-71][CursorImpl] Unable to evaluate cursor hasNext command java.util.concurrent.ExecutionException: java.util.concurrent.TimeoutException: Did not observe any item or terminal signal within 1000ms in 'source(MonoDefer)' (and no fallback has been configured)
      	at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:395)
      	at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:1999)
      	at org.apache.ignite.internal.metastorage.client.CursorImpl$InnerIterator.hasNext(CursorImpl.java:101)
      	at org.apache.ignite.internal.metastorage.client.MetaStorageServiceImpl$WatchProcessor$Watcher.run(MetaStorageServiceImpl.java:453)
      Caused by: java.util.concurrent.TimeoutException: Did not observe any item or terminal signal within 1000ms in 'source(MonoDefer)' (and no fallback has been configured)
      	at reactor.core.publisher.FluxTimeout$TimeoutMainSubscriber.handleTimeout(FluxTimeout.java:289)
      	at reactor.core.publisher.FluxTimeout$TimeoutMainSubscriber.doTimeout(FluxTimeout.java:274)
      	at reactor.core.publisher.FluxTimeout$TimeoutTimeoutSubscriber.onNext(FluxTimeout.java:396)
      	at reactor.core.publisher.StrictSubscriber.onNext(StrictSubscriber.java:89)
      	at reactor.core.publisher.FluxOnErrorResume$ResumeSubscriber.onNext(FluxOnErrorResume.java:73)
      	at reactor.core.publisher.MonoDelay$MonoDelayRunnable.run(MonoDelay.java:117)
      	at reactor.core.scheduler.SchedulerTask.call(SchedulerTask.java:68)
      	at reactor.core.scheduler.SchedulerTask.call(SchedulerTask.java:28)
      	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
      	at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304)
      	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
      	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
      	at java.base/java.lang.Thread.run(Thread.java:834)

      It seems that the root cause is the following event triggered by TableManager#changeSchema

                  CompletableFuture.allOf(schemaReadyFut)
                      .exceptionally(e -> {
                          LOG.error("Failed to upgrade schema for a table [name=" + tblName + ", id=" + tblId + ']', e);
      
                          onEvent(TableEvent.ALTER, new TableEventParameters(tblId, tblName), e);
                          return null;
                      })
                      .thenRun(() ->
                          onEvent(TableEvent.ALTER, new TableEventParameters(tblId, tblName), null)
                      );
      

      It should be changed to

       onEvent(TableEvent.ALTER, new TableEventParameters(tblId, tblName, tbl), e);

      Thread dump attached.

      Attachments

        1. ignite-15454-threaddump.txt
          450 kB
          Vyacheslav Koptilin

        Issue Links

          Activity

            People

              slava.koptilin Vyacheslav Koptilin
              slava.koptilin Vyacheslav Koptilin
              Mirza Aliev Mirza Aliev
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 10m
                  10m