Answer the question
In order to leave comments, you need to log in
Why, when translated into production, the call to the servlet began to return Status Code: 404 OK?
Hello.
In my web application for Apache Tomcat, the interaction between frontend and backend traditionally goes through the get web service.
while testing on Localhost everything was OK:
Request URL:http://localhost:8000/GetINFO?get_info=NAME
Request Method:GET
Status Code:200 OK
Request URL:http://server01/example/GetINFO?get_info=NAME
Request Method:GET
Status Code:404 OK
@WebServlet(name = "GetINFO", description = "GetINFO", urlPatterns = "/GetINFO")
public class GetHPBSMEvents extends HttpServlet {
protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
}
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
...
}
}
$.getJSON('../GetINFO?get_info=NAME', function (jsondata) {
..
});
Answer the question
In order to leave comments, you need to log in
after reloading Intellige IDEA and cleaning out all Java processes, the web service started working...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question