In case of Servlet:
You have to override all the life-cylce methods viz. init(), service() and destroy().
In case of HttpServlet:
No need to override all but only the doXXX method that you are using in your client-side(
JSP or HTML which will call this servlet), like doGet or doPost.This is because HttpServlet extends Generic servlet which already implements the life-cycle methods.The HttpServlet calls the service method when we call a doXXX method.
A servlet is meant to process a request.When you have a request, you have to provide a service or a doXXX method implementation in your servlet.