I have created a java library that fetches data from Elasticsearch cluster and shows hits. Is it possible to add a servlet and UI page in the same library, without creating another dynamic web project?
Asked
Active
Viewed 160 times
0
-
How does your library look? I assume a couple of classes that expose methods which fetch data and show them? Where do they show them? – gicig May 04 '20 at 10:58
-
They'll be shown in another service. – Nipun Soni May 06 '20 at 01:53
-
Ok. In general, the answer to your question is - yes, it is possible add servlet to your library. You would in that case have to create a [war file](https://stackoverflow.com/questions/5871053/difference-between-jar-and-war-in-java) and deploy it to a servlet container. – gicig May 06 '20 at 11:31