What is the default behavior of the service() method in the HttpServlet class?

  • Forwarding the request to the init() method.
  • Invoking the doGet() method.
  • Invoking the doPost() method.
  • Providing an HTTP 405 (Method Not Allowed) error.
The default behavior of the service() method in the HttpServlet class is to provide an HTTP 405 error (Method Not Allowed) response, indicating that the requested HTTP method is not supported.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *