Models served from a servlet

Hi!
I’m writing here because I need some help with the HttpDataSetReader. The situation is as follows: the server I’m using generates the model as the HttpDataSetReader wants (with the index.json and the data folder) and stores it in a folder. This folder is can’t served as static content as we need it this way. The way we wanted to serve the files is through a servlet but the reader, when setting the url, tries to always search for the index.json, ignoring eventually any buffer already sent to the client (for example, using axios or simply fetch). Is there a way to set an arraybuffer or something overriding the internal fetch call instead of passing an url to the file?
Also, little off-topic but needed, in terms of performances and times (from when the model is arrived to the moment the model is ready to be rendered) which could be the better reader? (without considering the internet speed or pc performances). I know that it is a hard question but something to think on is also welcome.

Thanks!

I think you could use your own implementation DataAccessHelper so you can cache the data that was already sent/fetch.

The HttpDataSetReader is pretty efficient especially if your servlet use the gzip compression header.

Hi and thanks for your answer.
Trying to find a solution I stumbled upon the ZipHttpReader example and I saw three things that I can’t really understand:

  1. In the example three of these DataAccessHelper are imported but then the vtkHttpDataSetReader is used to perform the query. So my question is: how does these Helpers should work?
  2. In the same example two models are queried. These models have the extension .vti-web. What’s this exension, how can I produce a model with this extension and also does it require the structure index.json + zipped data?
  3. What options are available and what do they mean for the method setURL() in the HttpDataSetReader?

Thanks!