HttpServlet in IBM Java?

122 Views Asked by At

I'm trying to build an app using IBM Bluemix that takes user input in an HTML form, processes it in a server-side Java application, and returns the processed data to the user. This kind of thing is really simple to implement using HttpServlet, but that class doesn't seem to exist in IBM's jdk. Where can I find this class?

Apologies, I'm very new to any web development concepts beyond building a static HTML website.

2

There are 2 best solutions below

0
On BEST ANSWER

HttpServlet is not part of the Java Standard Edition runtime, it's provided by your application server--Tomcat or WebSphere Liberty, for instance. At development-time, you'll need one of these on-hand to provide you that class to compile against.

0
On

I presume you are using "Liberty for Java" runtime. I believe HttpServlet is part of Liberty, and the default configuration of Liberty runtime includes the "servlet-3.0" feature (see here). There's also mention of it in the Liberty documentation here. So you should be able to use it in Bluemix.