We are building a voice and video solution using WebRTC - mostly to work on Chromium-based browsers such as Google Chrome and Microsoft Edge.
On the Chrome developer console - network tab, there is a feature to see how your app performs under various simulated network conditions such as fast-3G, slow-3G, or altogether going offline.
Unfortunately, the network simulations do not work on WebRTC apps. I am assuming this is due to WebRTC using UDP protocol, and the network throttle is built for TCP.
Can you suggest ways to simulate varying network conditions? We want to test how the video app performs on varying bandwidth and latency conditions. Are there any plugins that would simulate this? It would be good to have the Google Chrome team extend their network throttling feature to include voice, video, and data streams that primarily run on UDP.
Related
In Loadrunner Truclient protocol while recording the web application Google Chrome/Firefox instances is opening in incognito mode but the issue is my application will not work incognito mode.
My application is working fine in only normal mode of Google Chrome/Firefox instances.
Could anyone please let me know during recording with truclient how to change the Chrome/Firefox instances from incognito mode to normal mode.
You already posted this question on the official product forum (https://community.softwaregrp.com/t5/LoadRunner-Practitioners-Forum/Urgent-Truclient-chrome-instance-is-opening-in-Incognito-mode/m-p/1624503) and got a response by the lead developer of the TruClient protocol.
His answer is:
TruClient runs the browser in Incognito/Privacy mode to allow separation of
Vusers during a load test.
This cannot be disabled or changed.
Perhaps you can elaborate on why your application is not working in these
modes, so we can try to find a workaround.
and then
Some browser features behave differently in privacy mode.
For example, IndexedDB cache mechanism is not implemented in Firefox
private mode [See the bug in Mozilla]
https://bugzilla.mozilla.org/show_bug.cgi?id=781982
From the error you mentioned, it seems this is related a similar browser issue.
As mentioned before, it is not possible to run TruClient in non-private mode.
Workaround: Run one full GUI Virtual User in a singular operating system instance. run one of these per business process on dedicated OS instances. Run the remainder of your load using API level (HTTP) virtual users.
Most modern browsers can display the network traffic of the currently open webpage and its dependencies in its dev tools.
When the browser sends the initial HTTP request for a webpage, it uses the response to display the webpage. A javascript file that the webpage depends on may send another request through AJAX.
Does the browser monitor the execution of the javascript file and display the subsequent requests in the original page's network log?
EDIT: For a bit of background, I'm trying to write a python program that will display all the network traffic generated by a webpage and its dependancies.
if you use chrome browser, you can use network feature on Developer tools.
through this feature, you can monitor all of network activities on page.
for monitoring execution of javascript, search firebug on google.
How do web browsers monitor network of current open webpage?
The short answer: the browser knows about all this, because it has to prepare and send/receive all requests to the webserver. That's his job, and involves much more than monitoring only.
Does the browser monitor the execution of the javascript file and
display the subsequent requests in the original page's network log?
The browser not only has to monitor the execution of the script, it has to execute the script itself. The script then forwards the subsequent request to that same browser, thus no need for the browser to monitor the script to get that information.
For a bit of background, I'm trying to write a python program that
will display all the network traffic generated by a webpage and its
dependancies.
Since this seems to be for educational purposes, you might want to start with writing a plugin for the browser to get an idea of what's happening inside (this will be mostly in JavaScript). In your plugin you can make direct API-calls to the browser-engine, or use call-backs to get notified when requests are made or pages/images arrive.
To monitor that traffic from within a stand-alone application, more work needs to be done. You'll have to sit somewhere in between the browser and your network card. This can be done by:
Writing some kind of proxy to catch and forward the HTTP-traffic and direct your browser to that proxy.
Using a library such as libpcap to catch all network traffic and analyzing the TCP-packets.
I would like to build a web application that lets two peers see and hear each other using video and audio streaming with HTML5 and no plugins (except for IE, that I pretend to use getUserMediajs to use a flash fallback).
I also want to transmit that data using NodeJS but I have no idea where to start. In an example:
Peer A <---> Node JS <---> Peer B
I'm interested in this Peer 2 Server 2 Peer approach instead of a Peer 2 Peer solution like PeerJS because:
1) I think it will be more compatible will all browsers. If this is not entirely true, please let me know.
2) PeerJS (which I'm not interested in) relies on black magic STUN-TURN-ICE signaling for some cases. I read somewhere that only the 70% of the connections are suitable for this kind of transmission, and I can not afford a loss of the 30%. Again let me know if this is no entirely true.
I have already played around with socket.io and know the concepts of getUserMedia() to get user's webcam, but don't know how to link that with socket.io and transmit that to the other client.
The browser compatibility has nothing to do with adding a server side component. You could be p2p, or p2s2p, if what you send is not recognized by the receiving browser, it won't work.
ICE is mandatory for webrtc, you can't do without, period. by default, you can only connect to computers in the same network (hosts candidates). If you provide a STUN server, you will be able to connect in 70% of the cases all together, much less in enterprise context. http://webrtcstats.com/webrtc-revolution-in-progress/ has the latest stats from some vendors. You can see that for social sites, as of june 2014, 92% of the calls can work through firewalls and NAT using simple STUN. The remaining of the called needed to be relayed through a TURN server. You have a lot of Free STUN server providers out there, this is the minimum you should use.
webRTC for Desktop IE and Safari.
While flash callbacks are interesting (read, easy) they pause two problems:
They do not generate video stream compatible with peer connection or with HTML5. Not being compatible with peer connection means, you cannot send the images or the video, but only use it locally. Not being compatible with HTML5 means you cannot use the generated image and video in a element, and you do not have anyway simple way to render it outside of a flash plugin element. In the case of the shim you point to, they copy over from the flash plugin to HTML each single frame, and they mention in the read me that this is too computationally extensive to be used for lived video.
flash use different protocols (RTMP, RTMFP, ..) and codecs from webrtc and they are not mutually interoperable. You would need to maintain both separately or to have a complicated, dual use infrastructure to deal with it. OpenClove is a vendor that propose such dual purpose infrastructure for example.
Another solution is to install on Desktop IE and Safari a webRTC plugin (not flash), which implements "pure" webRTC. In which case, you can directly interoperate with chrome, firefox, opera, and any other browser which implements natively webRTC 1.0
We propose such a plugin, for free (no cost) and for all (not vendor specific) here
Whatever you do, you need WebRTC support on the browser ("no plugins"). So, the "it will be more compatible will all browsers" is a moot point because browser support
From the documents of Chrome DevTool I have see this,
One key aspect for the responsiveness of a site is its network performance. Fear not, the DevTools offers network throttling. Now you can test your site against different network conditions and optimize for them.
Network conditioning does bandwidth throttling and latency manipulation. The bandwidth is how much speed the client has to talk to the server while latency is the delay in connection. A few presets are available in the network dropdown, as well as the ability to go completely offline. All changes only affect this tab's traffic; your other tabs are unaffected.
But I am unable to find this option Chrome with Windows 7.
From the Chrome DevTools page:
Note: Some of our documentation may be ahead of the stable version of Chrome. If you are unable to locate a feature listed, we recommend trying Chrome Canary which contains the latest version of the DevTools.
I am interested in filtering traffic comming into Chrome. I've seen WebRequest API and ignoring the fact that it's experimental it seems that you can't stop traffic since events are asynchronous.
I was also exploring the NPAPI plugins for filtering but it seems that they are plugins that need to be registered for particular content type.
Is there any other way for filtering and blocking incoming HTTP traffic in Chrome?
EDIT
I don't know if using a proxy would be a viable option. I am building a software that can be installed on a client machine and this software supports traffic filtering based on custom criteria for IE and FF. I would like to add Chrome support also. Proxy is a third-party app. How would I control it? User would also have to change it's network connection settings.