Skip to content

Handle Bad Request: E.g. Request size exceeds limit #36

Description

@ismailsunni

When sending a json specification that is more than the size limit, we get a HTTP error in HTML. This will cause a parsing error that expect a JSON. We should be able to handle this issue and give proper error message.

<!doctype html>
<html lang="en">
    <head>
        <title>HTTP Status 400 – Bad Request</title>
        <style type="text/css">
            body {
                font-family: Tahoma,Arial,sans-serif;
            }

            h1, h2, h3, b {
                color: white;
                background-color: #525D76;
            }

            h1 {
                font-size: 22px;
            }

            h2 {
                font-size: 16px;
            }

            h3 {
                font-size: 14px;
            }

            p {
                font-size: 12px;
            }

            a {
                color: black;
            }

            .line {
                height: 1px;
                background-color: #525D76;
                border: none;
            }
        </style>
    </head>
    <body>
        <h1>HTTP Status 400 – Bad Request</h1>
        <hr class="line"/>
        <p>
            <b>Type</b>
            Status Report
        </p>
        <p>
            <b>Message</b>
            Request size exceeds limit
        </p>
        <p>
            <b>Description</b>
            The server cannot or will not process the request due to something that is perceived to be a client error (e.g., malformed request syntax, invalid request message framing, or deceptive request routing).
        </p>
        <hr class="line"/>
        <h3>Apache Tomcat/9.0.80</h3>
    </body>
</html>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions