XWiki Platform GWT
Retired Google WebToolkit modules.
Debugging the Java code
Debugging the client side Java code
Starting with GWT 2.0 we can run and debug the client side Java code directly in the browser. This is called Development Mode. Follow these steps:
xwiki-gwt-wysiwyg-servermodule to the root of your XWiki Enterprise installation. For the standard jetty+hsqldb distribution this is the directory where
chmod 755 start_wysiwyg_noserver_debug.sh
start_wysiwyg_noserver_debug.shwith a text editor and make sure that the variables defined at the beginning of the file match what you have on your system.
- The GWT Development Mode requires GWT Java sources (so not only the byte code) to be in the class path. The debug script looks for the needed dependencies in the local maven repository. Building the
xwiki-gwt-*modules ensures these dependencies are in your local maven repository. Alternatively you can edit the debug script and reference these dependencies with a different path.
- Start the server (e.g.
- Connect to the specified port using your IDE. The client side code is in the
xwiki-gwt-wysiwyg-clientmaven module. Make sure you have imported it in your IDE.
- The GWT Development Mode window should have opened. Click "Copy to Clipboard" to copy the startup URL.
- Paste the startup URL in your browser's address bar and load it.
- You may be asked to login since you're going to edit a wiki page in WYSIWYG mode.
- You may be asked to install the GWT Developer plugin, if this is the first time you try to debug GWT code in Development Mode.
resources/js/xwiki/wysiwyg/xwe) might be affected so you should backup it if you don't have other means of restoring it.
- At this point the WYSIWYG editor should be loaded and you should be able to add break points using your Java IDE. Currently the editor toolbar is badly displayed in debug mode due to some CSS issue we need to fix.
Debugging the server side code
You can debug the server side code remotely. Start your wiki in debug mode (e.g. using the ##start_xwiki_debug.sh## script) and then connect with your IDE to the specified port. The server side code of the WYSIWYG editor is in the ##xwiki-gwt-wysiwyg-server## module. Make sure you have imported it in your IDE.
-Pdev maven profile. Alternatively you can edit the pom of the
xwiki-gwt-wysiwyg-server module and change the value of the
<hash>.cache.html file that is loaded by your browser and add