Uploaded image for project: 'Flink'
  1. Flink
  2. FLINK-14411

OrcTableSource read error

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Cannot Reproduce
    • 1.9.0
    • None
    • Table SQL / Ecosystem
    • None
    •  

       

    Description

      Hello, when I used BatchTableEnvironment to run a query on OrcTableSource, I got a Exception.can any one can help me?

      Below is my program code:

       

      ExecutionEnvironment env = ExecutionEnvironment.getExecutionEnvironment();
      BatchTableEnvironment tableEnvironment = BatchTableEnvironment.create(env);
      TypeDescription schema = TypeDescription.fromString("struct<id:int,name:int,count:int>");
      OrcTableSource orcTs = OrcTableSource.builder().path("hdfs://localhost:9000/user/xxx/orc/test.orc")
      .forOrcSchema(schema).build();
      tableEnvironment.registerTableSource("OrcTable", orcTs);
      Table result = tableEnvironment.sqlQuery("select * from OrcTable");

      DataSet<Row> rowDataSet = tableEnvironment.toDataSet(result, Row.class);
      rowDataSet.print();

       

      The Exception is:

      Caused by: org.apache.flink.runtime.rest.util.RestClientException: [Internal server error., <Exception on server side:

      org.apache.flink.runtime.client.JobSubmissionException: Failed to submit job.

      at org.apache.flink.runtime.dispatcher.Dispatcher.lambda$internalSubmitJob$2(Dispatcher.java:333)

      at java.util.concurrent.CompletableFuture.uniHandle(CompletableFuture.java:822)

      at java.util.concurrent.CompletableFuture$UniHandle.tryFire(CompletableFuture.java:797)

      at java.util.concurrent.CompletableFuture$Completion.run(CompletableFuture.java:442)

      at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:40)

      at akka.dispatch.ForkJoinExecutorConfigurator$AkkaForkJoinTask.exec(ForkJoinExecutorConfigurator.scala:44)

      at akka.dispatch.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260)

      at akka.dispatch.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339)

      at akka.dispatch.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979)

      at akka.dispatch.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)

      Caused by: java.lang.RuntimeException: org.apache.flink.runtime.client.JobExecutionException: Could not set up JobManager

      at org.apache.flink.util.function.CheckedSupplier.lambda$unchecked$0(CheckedSupplier.java:36)

      at java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1590)

      ... 6 more

      Caused by: org.apache.flink.runtime.client.JobExecutionException: Could not set up JobManager

      at org.apache.flink.runtime.jobmaster.JobManagerRunner.<init>(JobManagerRunner.java:152)

      at org.apache.flink.runtime.dispatcher.DefaultJobManagerRunnerFactory.createJobManagerRunner(DefaultJobManagerRunnerFactory.java:83)

      at org.apache.flink.runtime.dispatcher.Dispatcher.lambda$createJobManagerRunner$5(Dispatcher.java:375)

      at org.apache.flink.util.function.CheckedSupplier.lambda$unchecked$0(CheckedSupplier.java:34)

      ... 7 more

      Caused by: org.apache.flink.runtime.client.JobExecutionException: Cannot initialize task 'DataSource (OrcFile[path=hdfs://localhost:9000/user/xxx/orc/test.orc, schema=struct<id:int,name:int,count:int>, filter=TRUE])': Loading the input/output formats failed: File Input ([hdfs://localhost:9000/user/xxx/orc/test.orc])

      at org.apache.flink.runtime.executiongraph.ExecutionGraphBuilder.buildGraph(ExecutionGraphBuilder.java:218)

      at org.apache.flink.runtime.executiongraph.ExecutionGraphBuilder.buildGraph(ExecutionGraphBuilder.java:106)

      at org.apache.flink.runtime.scheduler.LegacyScheduler.createExecutionGraph(LegacyScheduler.java:207)

      at org.apache.flink.runtime.scheduler.LegacyScheduler.createAndRestoreExecutionGraph(LegacyScheduler.java:184)

      at org.apache.flink.runtime.scheduler.LegacyScheduler.<init>(LegacyScheduler.java:176)

      at org.apache.flink.runtime.scheduler.LegacySchedulerFactory.createInstance(LegacySchedulerFactory.java:70)

      at org.apache.flink.runtime.jobmaster.JobMaster.createScheduler(JobMaster.java:275)

      at org.apache.flink.runtime.jobmaster.JobMaster.<init>(JobMaster.java:265)

      at org.apache.flink.runtime.jobmaster.factories.DefaultJobMasterServiceFactory.createJobMasterService(DefaultJobMasterServiceFactory.java:98)

      at org.apache.flink.runtime.jobmaster.factories.DefaultJobMasterServiceFactory.createJobMasterService(DefaultJobMasterServiceFactory.java:40)

      at org.apache.flink.runtime.jobmaster.JobManagerRunner.<init>(JobManagerRunner.java:146)

      ... 10 more

      Caused by: java.lang.Exception: Loading the input/output formats failed: File Input ([hdfs://localhost:9000/user/xxx/orc/test.orc])

      at org.apache.flink.runtime.jobgraph.InputOutputFormatVertex.initInputOutputformatContainer(InputOutputFormatVertex.java:156)

      at org.apache.flink.runtime.jobgraph.InputOutputFormatVertex.initializeOnMaster(InputOutputFormatVertex.java:60)

      at org.apache.flink.runtime.executiongraph.ExecutionGraphBuilder.buildGraph(ExecutionGraphBuilder.java:214)

      ... 20 more

      Caused by: java.lang.RuntimeException: Deserializing the input/output formats failed: unread block data

      at org.apache.flink.runtime.jobgraph.InputOutputFormatContainer.<init>(InputOutputFormatContainer.java:68)

      at org.apache.flink.runtime.jobgraph.InputOutputFormatVertex.initInputOutputformatContainer(InputOutputFormatVertex.java:153)

      ... 22 more

      Caused by: java.lang.IllegalStateException: unread block data

      at java.io.ObjectInputStream$BlockDataInputStream.setBlockDataMode(ObjectInputStream.java:2773)

      at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1599)

      at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2278)

      at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2202)

      at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2060)

      at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1567)

      at java.io.ObjectInputStream.readObject(ObjectInputStream.java:427)

      at org.apache.flink.util.InstantiationUtil.deserializeObject(InstantiationUtil.java:576)

      at org.apache.flink.util.InstantiationUtil.deserializeObject(InstantiationUtil.java:562)

      at org.apache.flink.util.InstantiationUtil.deserializeObject(InstantiationUtil.java:550)

      at org.apache.flink.util.InstantiationUtil.readObjectFromConfig(InstantiationUtil.java:511)

      at org.apache.flink.runtime.operators.util.TaskConfig.getStubWrapper(TaskConfig.java:288)

      at org.apache.flink.runtime.jobgraph.InputOutputFormatContainer.<init>(InputOutputFormatContainer.java:66)

      ... 23 more

       

      End of exception on server side>]

      at org.apache.flink.runtime.rest.RestClient.parseResponse(RestClient.java:389)

      at org.apache.flink.runtime.rest.RestClient.lambda$submitRequest$3(RestClient.java:373)

      at java.util.concurrent.CompletableFuture.uniCompose(CompletableFuture.java:952)

      at java.util.concurrent.CompletableFuture$UniCompose.tryFire(CompletableFuture.java:926)

      ... 4 more

      Attachments

        Activity

          People

            Unassigned Unassigned
            zlzhang0122 zlzhang0122
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: