In the process of developing an angular application, I have implemented a websocket
for real-time updates transmission and reception.
Within my application, users have the ability to open multiple windows that are launched from the main window, solely for the purpose of displaying additional details related to the main page's data.
Each opened window must receive the same real-time updates from the websocket
as the main window, with the potential for there to be over 10 open windows at any given time.
The issue arises when considering the network resources required if a new websocket is opened in each window, leading to potential internet connectivity problems for users opening numerous windows.
One proposed solution from my team involves establishing a single websocket connection from the main page and utilizing Indexeddb
to store and distribute the real-time updates to all open windows. However, implementing this solution has resulted in lock issues when accessing Indexeddb
.
Therefore, I am left to ponder whether opening multiple websockets
would indeed strain network resources, and if there exists an alternative method for sharing real-time data across various tabs.