Search code examples
javanumbersstacklinetrace

java stack trace's line number mismatch with hadoop lib


  1. I don't know the exact meaning of <init> function, why there is an <>
  2. Actually there is no inner Class Conf in DFSClient
  3. I trace the function flow, until DistributedFileSystem.initialize the line number is right, why top seven traces' line number not match with source.

Stacktrace:

[DEBUG] [main] |service.AbstractService|: noteFailure java.lang.NumberFormatException: For input string: "30s"
[INFO] [main] |service.AbstractService|: Service org.apache.tez.dag.app.DAGAppMaster failed in state INITED; cause: java.lang.NumberFormatException: For input string: "30s"
    java.lang.NumberFormatException: For input string: "30s"
    at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
    at java.lang.Long.parseLong(Long.java:589)
    at java.lang.Long.parseLong(Long.java:631)
    at org.apache.hadoop.conf.Configuration.getLong(Configuration.java:1311)
    at org.apache.hadoop.hdfs.DFSClient$Conf.<init>(DFSClient.java:502)
    at org.apache.hadoop.hdfs.DFSClient.<init>(DFSClient.java:637)
    at org.apache.hadoop.hdfs.DFSClient.<init>(DFSClient.java:619)
    at org.apache.hadoop.hdfs.DistributedFileSystem.initialize(DistributedFileSystem.java:149)
    at org.apache.hadoop.fs.FileSystem.createFileSystem(FileSystem.java:2653)
    at org.apache.hadoop.fs.FileSystem.access$200(FileSystem.java:92)
    at org.apache.hadoop.fs.FileSystem$Cache.getInternal(FileSystem.java:2687)
    at org.apache.hadoop.fs.FileSystem$Cache.get(FileSystem.java:2669)
    at org.apache.hadoop.fs.FileSystem.get(FileSystem.java:371)
    at org.apache.hadoop.fs.FileSystem.get(FileSystem.java:170)
    at org.apache.hadoop.fs.FileSystem.get(FileSystem.java:355)
    at org.apache.hadoop.fs.Path.getFileSystem(Path.java:295)
    at org.apache.tez.common.TezCommonUtils.getTezBaseStagingPath(TezCommonUtils.java:87)
    at org.apache.tez.common.TezCommonUtils.getTezSystemStagingPath(TezCommonUtils.java:146)
    at org.apache.tez.dag.app.DAGAppMaster.serviceInit(DAGAppMaster.java:492)
    at org.apache.hadoop.service.AbstractService.init(AbstractService.java:163)
    at org.apache.tez.dag.app.DAGAppMaster$9.run(DAGAppMaster.java:2662)
    at java.security.AccessController.doPrivileged(Native Method)
    at javax.security.auth.Subject.doAs(Subject.java:422)
    at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1657)
    at org.apache.tez.dag.app.DAGAppMaster.initAndStartAppMaster(DAGAppMaster.java:2659)
    at org.apache.tez.dag.app.DAGAppMaster.main(DAGAppMaster.java:2464)

Solution

  • 1) I don't know the exact meaning of <init> function, why there is an <>

    The <init> denotes a constructor. (If you see a <cinit> that is a static initialization pseudo-method.)

    2) Actually there is no inner class Conf in DFSClient

    You probably have the wrong version of the source code.

    3) I trace the function flow, until DistributedFileSystem.initialize the line number is right, why top seven traces' line number not match with source.

    You probably have the wrong version of the source code.