Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5987403
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T22:48:35+00:00 2026-05-22T22:48:35+00:00

I have a Tomcat application server and this Java source code: public class MyServlet

  • 0

I have a Tomcat application server and this Java source code:

public class MyServlet extends HttpServlet {
    public MyServlet() {}

    protected void doPut(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException {
        // ... PUT code
    }

    protected void doGet(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException {
        // ... GET code
    }
}

With GET everything is fine. The method doGet is called. But from my iPhone app doing a put the doPut method is not called. Nothing happens on the server, I see nothing in the log files. So what´s wrong? Are there any PUT limitations on Tomcat?
How can I debug this? On the iOS device I use a library which I can tell that PUT shall be used, so it should work, because it is a very common framework.

Does anyone have an idea?

Best Regards Tim.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T22:48:36+00:00Added an answer on May 22, 2026 at 10:48 pm

    Use wireshark to trace the packets to make sure you actually get a PUT request.

    Or similarly setup a separate access log for tomcat (it is already in the default config file, but commented out I believe) to see what is coming in.

    If you open in your favorit texteditor the file conf/server.xml in the tomcat directory then you’ll find near the end :

        <!-- Access log processes all example.
             Documentation at: /docs/config/valve.html -->
        <!--
        <Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs"  
               prefix="localhost_access_log." suffix=".txt" pattern="common" resolveHosts="false"/>
        -->
    

    if you remove the comment tokens all access will be logged to logs/localhost_access_log.

    e.g. :

        <!-- Access log processes all example.
             Documentation at: /docs/config/valve.html -->
        <Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs"  
               prefix="localhost_access_log." suffix=".txt" pattern="common" resolveHosts="false"/>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have inherited a Java application (servlets) that runs under Tomcat. For historical reasons,
I have the following method being called in a Java EE web application. public
My Servlet just won't use UTF-8 for JSON responses. MyServlet.java : public class MyServlet
We have recently migrated a large, high demand web application to Tomcat 5.5 from
I have an application running in tomcat that has a bunch of configuration files
I'd like to setup Tomcat on Windows and have authentication in my web application
We have a Java web application and we'd like to set up some basic
I have a Java EE web application that does not make use of EJBs.
I have two applications under tomcat/webapps folder. tomcat/webapps/App1 tomcat/webapps/App2 Both applications share the same
I have two web applications running in the same Tomcat Instance. In one of

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.