You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "wy (Jira)" <ji...@apache.org> on 2023/10/16 14:27:00 UTC

[jira] [Created] (SPARK-45556) Inconsistent status code between web page and REST API when exception is thrown

wy created SPARK-45556:
--------------------------

             Summary: Inconsistent status code between web page and REST API when exception is thrown
                 Key: SPARK-45556
                 URL: https://issues.apache.org/jira/browse/SPARK-45556
             Project: Spark
          Issue Type: Bug
          Components: Web UI
    Affects Versions: 3.5.0
            Reporter: wy


Spark history server provides [AppHistoryServerPlugin|https://github.com/kuwii/spark/blob/dev/status-code/core/src/main/scala/org/apache/spark/status/AppHistoryServerPlugin.scala] to add extra REST API and web pages. However there's an issue when exceptions are thrown, causing incnosistent status code between web page and REST API.

For REST API, if the thrown exception is an instance of WebApplicationException, then the status code will be set as the one defined within the exception.

However for web page, all exceptions are wrapped within a 500 response.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org