Hi team,
I have a pdfviewer on our angular ui and load controller in .net6 api. i am trying to implement redis for load balancing environment but i am getting an "failed to write"
after the load method is called, i see an entry in the redis db so i dont think error is in the redis setup
heres the load method code"
screenshot of error:
please let me know how to proceed
Hi Rangita Rajakumar,
Thank you for
reaching out to us. We have provided a sample that includes a Redis cache in
the service. Please check if the issue occurs in the provided sample. If you
are still experiencing any issues, kindly share a demo sample replicating the
problem so that we can investigate and provide a solution.
Client Sample
Server Sample
Replication Steps:
When using server-side components, delays may occur due to server communication for loading and rendering pages. To overcome this, we have introduced a standalone PDF viewer that performs rendering on the client side. For more details, please refer to the documentation on the standalone PDF viewer.
Documentation on Standalone PDF Viewer
Demo on Standalone PDF Viewer
Regards,
Sathiyaseelan K
Hi Sathiyaseelan, we are using server backed pdfviewer
Hi Rangita Rajakumar,
The
sample we provided features a server-backed PDF viewer component with Angular
on the client side and ASP.NET Core as the service. Please review the sample to
confirm whether the issue persists. If you continue to encounter any issues,
kindly provide a sample or demo video to help replicate the problem.
Regards,
Sathiyaseelan K
It is working now but its not working for documents more than 700 pages. is there anything else we need to do at the redis infrastructure level?
is there any limitation on how many pages can be loaded using redis?
Hi Rangita Rajakumar,
Thank you for the
update. The data transfer for Redis cache depends on the package you are using.
If you are using the premium package, the data transfer will be seamless, with
no exceptions thrown. Please verify whether the Standalone PDF Viewer component
we recommended meets your requirements. For your reference, we have included
the documentation and a sample once again.
Documentation
on Standalone PDF Viewer
Sample
on Standalone PDF Viewer
Regards,
Sathiyaseelan K
Yes this does meet the requirements but documents more than 1000 pages are not loading. Is the premium package you are referring to is the syncfusion package, or redis package?
these are the packages im using.
anything else is needed?
Also, is it possible to only render selected pages?
like if we want the user to enter page numbers like 1-5 in the ui and we render only those pages from the ui?
Hi Rangita Rajakumar,
Thank you for the
update. The premium package we referred to is for using the Redis package.
Additionally, please confirm whether your requirement is to initially load the
first five pages of the PDF and then load the remaining pages on demand. If
this is the case, you can achieve it using the initialRenderPages property to
specify the number of pages to render during the initial load.
Documentation
on initialRenderPages
Regards,
Sathiyaseelan K
I tried using the initialRenderPages property but the viewer still loads all the pages at once
initialRender is set to 10
we ideally want to load the entire document which sometimes can be upto 2000 pages but since the pdfviewer is unable to load it all the same time, we want to explore the option of loading pages in batch, what is a good approach for this ?
Hi Rangita Rajakumar,
Thank you for the
update. By default, the PDF Viewer component renders only the first two pages
of the PDF, with the remaining pages loading on demand. The provided property
allows increasing the initial page rendering count.
Please confirm
whether your requirement is to increase the initial page rendering count or to
load a specific number of pages first and then fetch the remaining pages upon
request from the customer. If your requirement is this, it can be achieved
using the PDF library to load only the required pages while removing the
remaining ones on the server side before displaying the PDF in the viewer.
Kindly confirm your requirement.
Regards,
Sathiyaseelan K