Uploaded image for project: 'Apache Ozone'
  1. Apache Ozone
  2. HDDS-11396

NPE due to empty Handler#clusterId

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.4.0
    • 2.0.0
    • DN

    Description

      When KeyValueHandler executes handleCreateContainer, it shows that Handler#clusterId is null.
      Here are some logs:

      2024-08-31 13:29:30,924 [1134f6e4-49f6-4831-ad13-6bdb8ea23409-ContainerOp-113adaf2-c5da-479c-b677-5ec11ac5d97a-2] WARN org.apache.hadoop.ozone.container.keyvalue.KeyValueHandler: Operation: CreateContainer , Trace ID:  , Message: java.lang.NullPointerException: clusterId cannot be null , Result: CONTAINER_INTERNAL_ERROR , StorageContainerException Occurred.
      org.apache.hadoop.hdds.scm.container.common.helpers.StorageContainerException: java.lang.NullPointerException: clusterId cannot be null
      	at org.apache.hadoop.ozone.container.keyvalue.KeyValueHandler.handle(KeyValueHandler.java:225)
      	at org.apache.hadoop.ozone.container.common.impl.HddsDispatcher.createContainer(HddsDispatcher.java:469)
      	at org.apache.hadoop.ozone.container.common.impl.HddsDispatcher.dispatchRequest(HddsDispatcher.java:275)
      	at org.apache.hadoop.ozone.container.common.impl.HddsDispatcher.lambda$dispatch$0(HddsDispatcher.java:179)
      	at org.apache.hadoop.hdds.server.OzoneProtocolMessageDispatcher.processRequest(OzoneProtocolMessageDispatcher.java:89)
      	at org.apache.hadoop.ozone.container.common.impl.HddsDispatcher.dispatch(HddsDispatcher.java:178)
      	at org.apache.hadoop.ozone.container.common.transport.server.ratis.ContainerStateMachine.dispatchCommand(ContainerStateMachine.java:485)
      	at org.apache.hadoop.ozone.container.common.transport.server.ratis.ContainerStateMachine.lambda$applyTransaction$9(ContainerStateMachine.java:900)
      	at org.apache.ratis.util.TaskQueue.lambda$submit$0(TaskQueue.java:121)
      	at org.apache.ratis.util.LogUtils.runAndLog(LogUtils.java:38)
      	at org.apache.ratis.util.LogUtils$1.run(LogUtils.java:78)
      	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539)
      	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
      	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
      	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
      	at java.base/java.lang.Thread.run(Thread.java:833)
      Caused by: java.lang.NullPointerException: clusterId cannot be null
      	at com.google.common.base.Preconditions.checkNotNull(Preconditions.java:921)
      	at org.apache.hadoop.ozone.container.keyvalue.KeyValueContainer.create(KeyValueContainer.java:148)
      	at org.apache.hadoop.ozone.container.keyvalue.KeyValueHandler.handleCreateContainer(KeyValueHandler.java:367)
      	at org.apache.hadoop.ozone.container.keyvalue.KeyValueHandler.dispatchRequest(KeyValueHandler.java:239)
      	at org.apache.hadoop.ozone.container.keyvalue.KeyValueHandler.handle(KeyValueHandler.java:222)
      

      Attachments

        1. screenshot-1.png
          17 kB
          JiangHua Zhu
        2. image-2024-09-02-22-53-22-487.png
          72 kB
          JiangHua Zhu
        3. image-2024-08-31-17-26-22-105.png
          58 kB
          JiangHua Zhu

        Issue Links

          Activity

            People

              jianghuazhu JiangHua Zhu
              jianghuazhu JiangHua Zhu
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: