Hello Gregory,
Hope you have made tremendous progress with your project.
I assume from your SE perspective you are invoking the search function and other functional classes from the main method (public static void main(
String[] args) { ... }).
Ever heard of the term MVC? It's a very simple yet powerful design
pattern that lets you build a project with clear separation of fundamental concerns.
In your case the C-ontrol servlet's doGet() is like the main class of the SE application. The search function and other classes can be ported as they are either as other methods of the servlet (legal but poor practice) or as separate classes preferably in the same package as the controlling servlet. This class or group of classes becomes the M-odel. The HTML/JSP plus associated JavaScript/CSS is what you use to V-iew responses and issue further requests. You can use just servlets to render HTML views but this is generally discouraged.
You should use JSPs instead (which are just glorified sevlets themselves).
There is a wonderful chapter on MVC in Oriely's Head First Servlets &
JSP book. I think it's titled 'MVC Tutorial'. If you can, read this and then map your project to this 'clean separation of concerns' design methodology. You don't need the 'heavy weight lifting' that comes with the
EJB container and session beans. A web profile container such as Apache
Tomcat can get you over the line.
Hope i have helped somewhat in clarifying your concerns.
Regards.