Solved

Question about Tomcat 7.x   regarding Alowed HTTP verbs

Posted on 2014-07-27
5
113 Views
Last Modified: 2014-08-29
Is it true the webapp controls the allowance of the VERBS if the webservice accepts it then so does Tomcat or is there
a setting to allow say PUT,GET,POST, DELETE   and what about OPTIONS or the other obscure verbs?
0
Comment
Question by:Robert Silver
  • 3
  • 2
5 Comments
 
LVL 58

Expert Comment

by:Gary
ID: 40223117
Not sure I'm following you but if your webapp doesn't recognize the verb then it's not going to do anything so it will end there.
0
 
LVL 2

Author Comment

by:Robert Silver
ID: 40248859
My question was really on a Tomcat 7.x or greater version server by default capable of handling PUT,DELETE, HEAD, OPTIONS and all the typical RESTFUL Verbs or is this fully controlled by what Spring MVC Rest controller specifies in each webapp?
0
 
LVL 58

Accepted Solution

by:
Gary earned 500 total points
ID: 40248869
controlled by what Spring MVC Rest controller - Simple answer is Yes
0
 
LVL 2

Author Comment

by:Robert Silver
ID: 40248977
Any Spring MVC controller I would  write e.g:
within a Conrtoller  class:
  @RequestMapping(method = RequestMethod.DELETE, value = "/{gameId}")
    ResponseEntity<Void> destroyGame(@PathVariable Long gameId) throws GameDoesNotExistException {
        this.gameRepository.remove(gameId);
        return new ResponseEntity<Void>(HttpStatus.OK);
    }
I mean to ask by default are these HTTP verbs enabled   or should I say not disable in versions 7.x and above?
0
 
LVL 2

Author Closing Comment

by:Robert Silver
ID: 40292907
I would have appreciated a bit of history like when in the history of Tomcat these verbs were enabled by default was that always the case?
I know Trace has to be enabled right? Also taking it another step if Mod_JK or  mod_proxy were used to go through an HTTPD apache server would those HTTP verbs  also be enabled by default Or are there additional settings needed on the Apache HTTPD server???
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
PHP Installer 5 37
Need help deploying my first MVC.Net app with a SQL Server backend 3 25
Syntax for query to update table 2 29
Link failure 16 34
Get to know the ins and outs of building a web-based ERP system for your enterprise. Development timeline, technology, and costs outlined.
FAQ pages provide a simple way for you to supply and for customers to find answers to the most common questions about your company. Here are six reasons why your company website should have a FAQ page
The viewer will learn how to count occurrences of each item in an array.
The viewer will get a basic understanding of what section 508 compliance can entail, learn about skip navigation links, alt text, transcripts, and font size controls.

861 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question