Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Migration from AbstractBranding / InvalidThreadAccess(At which point in lifecycle the access to RWT.getResourceManager() is allowed?)
Migration from AbstractBranding / InvalidThreadAccess [message #1443853] Mon, 13 October 2014 09:41
Frank Jakop is currently offline Frank JakopFriend
Messages: 8
Registered: July 2012
Junior Member
Hello,

we're migrating our webapps (running in Tomcat) from RAP 1.5.2 to 2.3.1 and used AbstractBranding to add some Body HTML, which is now replaced by EnryPoint-properties.
So far so good.

Now, we're providing an image for the body
final String body = "<img src=\"" + RWT.getResourceManager().getLocation("some/path/to/image") + \" />";
properties.put(WebClient.BODY_HTML, body)
...

and configure the application with the properties
application.addEntryPoint(myPath, myEntryPoint, properties);


At startup we get an
Schwerwiegend: Exception sending context initialized event to listener instance of class org.eclipse.rap.rwt.engine.RWTServletContextListener
java.lang.IllegalStateException: Invalid thread access
	at org.eclipse.rap.rwt.RWT.checkContext(RWT.java:733)
	at org.eclipse.rap.rwt.RWT.getApplicationContext(RWT.java:621)
	at org.eclipse.rap.rwt.RWT.getResourceManager(RWT.java:544)
...


so it seems, we cannot access the RWT.getResourceManager() at this time / in this thread.

So my question is, can anyone tell me how to reference resources in the body part corectly?
Previous Topic:No access to ajax.googleapis.com
Next Topic:Trouble opening EntryPoint in Windowbuilder (Eclipse luna 4.4, Windowbuilder 1.7.0)
Goto Forum:
  


Current Time: Thu Apr 25 12:00:40 GMT 2024

Powered by FUDForum. Page generated in 0.02681 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top