[rules-dev] Running Workbench applications in GWT SuperDevMode

Michael Anstis michael.anstis at gmail.com
Fri May 23 05:02:18 EDT 2014


So, now Chrome (35+) and FireFox don't support GWT "classic" DevMode, I've
managed to run drools-wb in SuperDevMode.

The "classic" DevMode will not be supported in GWT 2.6:
http://www.gwtproject.org/release-notes.html#Release_Notes_2_6_1

Here's my findings on how to configure your webapp, IDE and run (or debug)
the damn thing.

These instructions are for IDEA (NetBeans will probably follow a similar
route).

(1) Create a regular GWT Launcher:


​
(2) Create a new GWT Launcher for SuperDevmode:


​
(3) Add the following to your webapp's gwt.xml (module) file:

  <!-- SuperDevMode -->
  <add-linker name="xsiframe"/>
  <set-configuration-property name="devModeRedirectEnabled" value="true"/>
  <set-property name="compiler.useSourceMaps" value="true"/>
  <set-configuration-property name='xsiframe.failIfScriptTag'
value='false'/>

(4) Launch your regular webapp (the "classic" GWT Launcher):

... <tick>, <tock>, <tick>, <tock> while it compiles and launches...


​
(5) Launch the SuperDevMode code server (the "SuperDevMode" GWT Launcher):

... <tick>, <tock>, <tick>, <tock> while it compiles and launches...


​(6) Drag the "Dev Mode On" and "Dev Mode Off" buttons to your bookmark bar
(as advised) - but we don't normally read these sort of things, right! ;)

(7) Go back to the webapp's browser tab

(8) Click on the "Dev Mode On" bookmark you created in step (6)


​
(9) Click on "compile"


​
(10) Delete the "codesvr" part of the URL and press enter (dismiss the
popups that appear; which ones depends on what browser your GWT module
targets; e.g. I had to dismiss a popup about using Chrome but the GWT model
targets FireFox).


​(11) Done!


​
(12) What's that? You want to debug your application?!?

This isn't too bad. Just launch both your "classic" GWT Launcher in debug
mode and the "SuperDevMode" GWT Launcher in normal mode.

Server-side code needs break-points in IDEA, and client-side break-points
need to be added using Chrome's Developer Tools (you'll need to make sure
"sourceMaps" are enabled, but this appears to be the default in Chrome 35).

Accessing Chrome's debugger:


​
Debugging:


​
Simple!

It takes a bit of getting used to debugging client-side stuff in Chrome,
and server-side stuff in IDEA, but it's not terrible (although don't expect
to be able to introspect everything in Chrome like you used to in IDEA).

I hope this helps (probably more so as others find "DevMode" stops working
for them.... and when we move to GWT 2.6.1 --- for IE10 support --- so it
is coming sooner than later).

Cheers,

Mike
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-dev/attachments/20140523/4713f861/attachment-0001.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: compiling.png
Type: image/png
Size: 73762 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-dev/attachments/20140523/4713f861/attachment-0010.png 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: superdevmode.png
Type: image/png
Size: 44394 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-dev/attachments/20140523/4713f861/attachment-0011.png 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: remove-codeserv.png
Type: image/png
Size: 70858 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-dev/attachments/20140523/4713f861/attachment-0012.png 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: normal-devmode-launch.png
Type: image/png
Size: 67463 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-dev/attachments/20140523/4713f861/attachment-0013.png 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: debugging.png
Type: image/png
Size: 237629 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-dev/attachments/20140523/4713f861/attachment-0014.png 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ready.png
Type: image/png
Size: 71834 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-dev/attachments/20140523/4713f861/attachment-0015.png 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dev-tools.png
Type: image/png
Size: 130501 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-dev/attachments/20140523/4713f861/attachment-0016.png 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: superdevmodel-launch.png
Type: image/png
Size: 87598 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-dev/attachments/20140523/4713f861/attachment-0017.png 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: done.png
Type: image/png
Size: 339820 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-dev/attachments/20140523/4713f861/attachment-0018.png 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: devmode.png
Type: image/png
Size: 46934 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-dev/attachments/20140523/4713f861/attachment-0019.png 


More information about the rules-dev mailing list