Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-20519

When the input parameter is null, may be a runtime exception occurs

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Trivial
    • Resolution: Fixed
    • Affects Version/s: 2.1.0
    • Fix Version/s: 2.3.0
    • Component/s: Spark Core, SQL
    • Labels:
      None

      Description

      sqlContext.tables(null)
      setCustomHostname(null)
      checkHost(null, "test")
      checkHostPort(null, "test")

      throws exception at runtime:
      java.lang.NullPointerException was thrown.
      java.lang.NullPointerException
      at org.apache.spark.sql.catalyst.catalog.SessionCatalog.formatDatabaseName(SessionCatalog.scala:125)
      at org.apache.spark.sql.catalyst.catalog.SessionCatalog.listTables(SessionCatalog.scala:715)
      at org.apache.spark.sql.catalyst.catalog.SessionCatalog.listTables(SessionCatalog.scala:706)
      at org.apache.spark.sql.execution.command.ShowTablesCommand$$anonfun$11.apply(tables.scala:655)

        Attachments

          Activity

            People

            • Assignee:
              10110346 liuxian
              Reporter:
              10110346 liuxian
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: