I am facing a issue in image retrieving from MSSQL database to ignition perspective image component via SQL query.
I can store and fetch then view the image data for smaller size images
but when i tried to retrieve file size more than 2 or 3 MB, Gateway connection is frequently lost and image is fail to retrieve.
My Actual requirement is 8 to 20 MB size images need to save and display in the perspective Dashboard
In Inductive forum, I found some suggestions use Web Dev Module to solve this.
How long does the query take?
Are there any errors in the gateway logs?
What errors are there in the browser logs?
How are you providing the image data to the image component?
What format are you storing the image in the database as?
Websocket connection closed unexpectedly. code=1009, reason=Text message too large: 2,098,813 > 2,097,152, codeMeaning=Message Too Big, codeDescription=The endpoint is terminating the connection because a data frame was received that is too large.
Worth mentioning you should consider if you truly do need a 8-20mb graphic on a screen. Remake things to SVG files or at the least use a better compression/resolution to bring the file size down.
These are probably images from a camera, not process graphics if I had to guess.
But on a note of using large images, you might look into storing only a file/storage path in the database, then storing all the files in a folder (or a structure of folders). This keeps the database lightweight and allows the file handling to be handled by the file system. This has the advantage of keeping database backups small and if you ever want to look at what's being stored, it's much easier to just look at an organized file structure where you can just open the images to look at them when testing, plus you can back them up using regular file backups.
yes thanks for suggestions. I used Blob serve module to retrieve the image files from mssql database to ignition as per the document. It works fine. Images are displayed without much delay.
Will this module is good for video files as well? I need to play some machine operation videos as well
You should segment the video into chunks of a few megabytes, and update the playlist file to use Blob Server URLs. Put all of the chunks and the playlist into the DB. Use the playlist Blob Server URL as the video URL.