Issue
I am asked to work on portlets and portals.
I want to know the difference between a portlet and a servlet?
How / where does a portlet differ (may be functionally) from a servlet?
Solution
Portlets are part of JSR-168 standard that regulates portal containers and components. This is different standard from standards for web containers (and servlets). Though there are definitely strong parallels between these two standards they differ in containers, APIs, life cycle, configuration, deployment, etc.
The main difference between portlet vs. servlet could be that while servlet always responds to single type of action - request, portlet (due to nature of its life cycle and stronger container bindings) has to respond to two types of actions: render and request. There are of course more to it but I found this as the core difference between the two when I studied portal development.
Answered By - topchef
Answer Checked By - Terry (JavaFixing Volunteer)