I have an ajax client that often needs to get 3-10 static documents from the server. These 3-10 documents are selected by the client from approximately 100 documents. I do not know in advance which 3-10 documents a client will require.
In addition, these 100 documents are generated from the contents of the database and are dynamic. This does not seem logical though to create one ajax request per document.
My first thought was to write a JSP that uses the include action.
those. in pseudo code:
for (param in params){
jsp:include page="[param]"
}
Tomcat cannot support this because it does not just include the html resource, it recompiles it by generating a class file every time, which also seems expensive.
Can the community provide a solution for combining apache requests to static files in order to use single requests, and not several, but without overhead additional class files for each of the static files and in such a way as to avoid regeneration every time the static file changes?
source
share