Eclipse Preference Page Extension Wizard troubleshooting

Today I tried to add a Preference Page to an RCP application that I’m working on with no luck. After executing the Extension -> Add -> Extension Wizards -> Preference Page I end up with 3 new classes. But 2 of then have compilation errors, they refer to an unexisting PreferenceClass. After googling a bit I found this message in a mailing list describing the same exact problem: >Hello, I ’ve added preference page in my application using plugin.xml extensions template. Then, in a new package, Eclipse created 3 classes (Template preferences page extending FieldEditorPreferencePage, a preference constants class and a preference initializer class). The template preferences page uses a PreferenceClass which doesn’t already exists… I suppose this class has to initialize the preference store, in the preference template class constructor, unsing the plugin instance of the product : “setPreferenceStore(PreferenceClass.getDefault().getPreferenceStore());” I’ve tried to extend the AbstractUIPlugin (I’ve read in differents articles from eclipse.org) to catch the plugin instance when it is created, but without succes (when to catch this single instance during startup of eclispe core runtime ?). Then I’ve found the existance of the WorkBenchPlugin class which holds this static instance, I used it, discarding PreferenceClass , but Eclispe tells me that the use of this class is discouraged. Why ? How is it possible to store the plugin instance at startup ? Thanks a lot for your help, frank ...

June 29, 2007

Inspecting Tomcat HTTPS connection with Wireshark

Wireshark allows you to inspect SSL connection as long as you have the corresponding private key of the server side. You can read the details here. But if you are using java and tomcat you’ll probably have the certificate and private key stored in a JKS keystore so how can you extract the key in the right format for WireShark? First of all, keytool doesn’t allow you to extract the private key from a keystore. So you need external help. I use the DumpPrivateKey.java which is a modified version on the DumpPrivateKey found in this forum post. ...

June 29, 2007

Compiling and building JMeter with Eclipse 3.2.x

The developer notes on how to compile and debug Jmeter with Eclipse 1 and 2 are very difficult to follow and outdated. If you are interested in modifying Jmeter using Eclipse 3.2 Callisto you can follow the following procedure: Install Subclipse Callisto release (update site: http://subclipse.tigris.org/update_1.2.x) Download optional libraries. Although they’re optional is better if you download them. mail.jar activation.jar beanshell bsf jexl Use SVN Repository Exploring and add the following repository http://svn.apache.org/repos/asf/jakarta/jmeter Navigate to tags/v2_2. Right-click on it and select Checkout. Use then New Project Wizard. Rename the the eclipse.classpath to .classpath. Delete the eclipse generated .classpath first. Change the Build Classpath. Select the project in the Package Explorer. Right-click it and select Properties~~Java Build Path~~> Source. Then uncheck Allow output folders for source folders and set the Default output folder to the <Project name>/lib/ext. Remove the exclusion patterns for images/*, etc. in the Build Path->Source Look with the Navigator (not the Package Explorer) in the lib/ext folder and see if eclipse is compiling ok. If not check the Problems view to see if the project was not built since its build path is incomplete. Probably your are missing some library. Commons-logging has to be change from commons-logging-1.1 to commons-logging. If it complains about javax.mail.MessagingException then you have to add mail.jar to the build path At startup JMeter search for classes deriving from JMeterGUIComponent or TestBean. Now the context menus are populated with items. ...

April 25, 2007

Silly Apache JMeter 2.2 bug

The JDBC Sampler always commits (it doesn’t honor the auto-commit = false parameter) http://issues.apache.org/bugzilla/show_bug.cgi?id=42018. I’ve provided a patch that solved it at Bugzilla

April 25, 2007

New views don't show up when using Eclipse RCP setSaveAndRestore

If you add a new view to an Eclipse RCP and when launch it the new view is not there you probably hit the problem described in this CT Arrington’s Weblog post. The IWorkbenchConfigurer.setSaveAndRestore(true) called from your WorkbenchAdvisor can be the source of the problem. The Eclipse RCP platform is trying to restore the perspective from the serialized version stored on disk so it fails to load you new changes. You have several solutions [from the CT Arrington’s Weblog post]. ...

April 23, 2007

Enhanced JDBC Sampler code merged into Apache Jmeter

It seems that my patch to the JDBC Sampler in Apache JMeter has been finally merged into the subversion tree . I didn’t check it yet tought.

April 15, 2007

(Tomcat 5.5.x) java.lang.NoClassDefFoundError: javax/servlet/http/HttpSessionListener

Or java.lang.NoClassDefFoundError: javax/servlet/ServletContextListener for that matter. NoClassDefFoundError on HttpSessionListener , ServletListener , ServletContextListener, etc. can be caused by a custom classloader like Sysdeo DevLoader (I use it with Eclipse) in you Context definition in the Tomcat’s server.xml file. <Loader classname="org.apache.catalina.loader.DevLoader" reloadable="true" debug="1" /> the solution: add useSystemClassLoaderAsParent="false" to the Loader <Loader classname="org.apache.catalina.loader.DevLoader" reloadable="true" debug="1" useSystemClassLoaderAsParent="false"/> This should do the trick. More information here and here

April 13, 2007

Source code for enhanced jdbc sampler released

I released the Enhanced JDBC Sampler for Apache JMeter 2.2 source code today. See the bottom of this page to find the downloadable zip and instructions.

January 17, 2007

Source code for Statistical Visualizer plugin for Apache Jmeter 2.2

I just released the source code for the other Apache Jmeter plugin that I host here. Just go to the end of this page to download the file and get instructions.

January 17, 2007

Better JMeter Graphs

If you are tired of the old “Graph Results” listener that JMeter provides and want better charts in your Jmeter test plan take a look at this JMeter plugin. This is how the old “Graph Results” look like: Click on the above image or here to see an enlarged version of the old Graph Results Checkout this new JMeter plugin that provides a new Statistical Aggregate Report listener. (see the screenshot) ...

January 2, 2007