IBM®
Skip to main content
    Country/region [select]      Terms of use
 
 
    
     Home      Products      Services & solutions      Support & downloads      My account     
 
developerworks > Dashboard > IBM Composite Applications > ... > Developing Composite Applications with Eclipse > Debugging and Troubleshooting Eclipse Components
developerWorks
Log In   View a printable version of the current page.
Overview Spaces Forums Blogs Podcasts Wikis Exchange
Debugging and Troubleshooting Eclipse Components
Added by behrends, last edited by behrends on Mar 10, 2008  (view change)
Labels: 
(None)

Debugging and Troubleshooting Eclipse Components

This article explains how to debug Eclipse components. Debugging and troubleshooting composite applications in general is covered in this article.

Using Eclipse and the remote debugger

*Screen shots and content taken from Balfes.net

Here are some quick tips for debugging your eclipse plugins in the Lotus Notes 8.x client. This first entry will assume you are using base Eclipse (not using the XPD Toolkit) and remote debugging the Notes client via the Eclipse PDE. So in short, this technique will work with any Eclipse derivation - Eclipse PDE, RAD, RSA, etc.  If you are using the Lotus Expeditor toolkit you may want to check out these articles written by Pierre Carlson:

The first step is to get Notes 8.x and install it. This will be used as your plugin runtime during development.

The second step is getting your Eclipse installation to recognize the Notes runtime as the plugin runtime environment. This is so your plugin code can resolve the plugins from your installed Notes client. You set this under Window | Preferences menu option from the plugin development perspective:

From that screen you simply select the location of the "framework\eclipse" directory under the Notes install location.

Now we are ready to code our plugin!

Third step, how do we get our plugin into the Notes install? Well, the only way today is to create an Eclipse feature, reference your plugin and then create an Eclipse update site. You should check the help on eclipse.org to figure that out. Once the site is created you install your plugins into your notes client using the File | Application | Installmenu option to launch the Eclipse install screens. You want to walk through those screens and select "New plugins" and select the folder you exported your Eclipse update site to. Once the plugins are installed you are now ready to walk through your code from the Eclipse PDE!

To launch from the command line allows to always attach Eclise to the notes client to see if something strange is going on:

C:\notes\framework\rcp\rcplauncher.exe -console -config notes -vmargs -Duser.language=en -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=8020

Notice I use the port 8020 - you will need to remember that later. You can use whatever port you want.

Fourth step, in your Eclipse PDE you need to create a new debug runtime session. Click the following menu from the debug icon in the PDE:

When you select "Debug..." you will be presented with a new dialog where you will navigate down to the "Remote Java Application" entry in the tree and select the "New Launch Configuration" from the toolbar at the top. Really, the only thing left is to make sure the port you specified in the Notes launch is the same as the one you enter here:

Once you have that you are ready to debug. This article aims at getting you started with PDE/Eclipse remote debugging. Hopefully you can figure out how to set breakpoints and step through the code form here. Since your Notes launches with the debug listening port, you will be able to debug the code any time.

Resources

Need support?
This wiki is designed to provide valuable information to help you, but it does not replace other technical support services. Refer the following resources for more information.

 Don't forget to Sign in to edit or comment on information. Learn how to work with the wiki. Please review the Terms and conditions, which govern your use of this site.


    About IBM Privacy Contact