Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 474141

Summary: [Browser] Setting HTML content from inside a BrowserFunction fails in Safari
Product: [RT] RAP Reporter: Tim Buschtoens <tbuschto>
Component: RWTAssignee: Project Inbox <rap-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 3.0   
Target Milestone: 3.1 M1   
Hardware: All   
OS: All   
Whiteboard:

Description Tim Buschtoens CLA 2015-08-03 08:06:35 EDT
This is the scenario:
- Add a BrowserFunction to browser widget A.
- Within the BrowserFunction, call setHtml on browser widget B

The URL the iframe of browser widget B attempts to load will be different from the one that is set by the JavaScript code and obviously fail to load.

This happens only in Safari, and only when doing it from within a BrowserFunction, possibly because it's an synchronous request. This seems to be a pure Safari issue and not related to any changes in RAP.
Comment 1 Ivan Furnadjiev CLA 2015-08-20 05:59:36 EDT
Fixed in master with change https://git.eclipse.org/r/#/c/53061/
Comment 2 Frank Jakop CLA 2016-07-01 03:11:33 EDT
This fix breaks Browser.setUrl() in Chrome (v51) and IE (v11).

Calling setUrl("some.url") using the previous commit #02147589 produces just one GET request to "some.url" as expected. 
On commit #98a0f159 we see two GET requests  to "some.url" in the network timeline of Chrome dev tools, where the first one has state "cancelled".
This breaks amongst others the capability to call service handlers as described in https://wiki.eclipse.org/RAP/FAQ#How_to_provide_a_download_link.3F because the handler is called twice.
Comment 3 Ivan Furnadjiev CLA 2016-07-04 04:07:13 EDT
Please open a separate bugzilla and attach a simple snippet there to demonstrate the issue.