Pages

Showing posts with label issue. Show all posts
Showing posts with label issue. Show all posts

Tuesday, January 15, 2013

Headless RCP - issue using other plugins

Issues and Solutions

Most of the issues you encounter when you work with headless RCP is highly likely with the “additial plug-ins”.

Missing constraints

Theoretically, if you have run your RCP in IDE, it should run as standalone without a problem. If you have some issues such as “Missing constraints” You can use this site.

http://stackoverflow.com/questions/14366421/the-bundle-xyz-could-not-resolved-reason-missing-constraint-import-package-a/14367997#14367997

Unbound class path container error

You get this error because your java library is wrongly setup.

Go to Add Library session in Build Path/Configure Build Path and set from “Execution environment” to “Workspace …”.

ScreenShot2013-01-16at11.54.58AM-2013-01-15-15-57.png

http://stackoverflow.com/questions/6798281/unbound-class-path-container-error-in-eclipse

IllegalStateException: “Workbench has not been created yet”

This error message is misleading, and it actually means “there is some race condition happening”.

You can solve this issue by

  1. add -clean option to the parameter
  2. Following the “NoClassFoundError case 1”, that is remove all the dependencies and add them again. When you just keep adding dependencies for whatever reasons you may end up this state.

http://waheedtechblog.blogspot.com/2011/11/javalangillegalstateexception-workbench.html

NoClassFoundError case 1

You add this, and that, and suddenly you got an error “NoClassFound”, what you can do is go to the product file, open the Dependencies. Delete all the plug-ins using “Remove” and “Add Required plug-ins” with the application that you are going to make standalone

NoClassFoundError case 2

You successfully created the plugin (utilities for example), but you may have this kind of error “NoClassDefFoundError”, when you execute the plugin that contains other plugin.

ScreenShot2013-01-15at3.56.41PM-2013-01-15-15-57.png

First thing you need to understand is that reference is built up already for you.

Lets’s say in the course of plugin development, you add “utilities” in “Dependencies”.

ScreenShot2013-01-15at4.03.34PM-2013-01-15-15-57.png

It makes your plugin know how to refer to the utilities during its build, as it finds the utilities, it can build the plugin successfully.

ScreenShot2013-01-15at4.02.43PM-2013-01-15-15-57.png

The issue is actually not in the user’s side, but in the provider’s side. You had to export the package in the “utilities” plugin.

ScreenShot2013-01-15at4.01.14PM-2013-01-15-15-57.png

ScreenShot2013-01-15at4.01.24PM-2013-01-15-15-57.png

Friday, November 30, 2012

Building eclipse source base and resolving its related issues

1. Download the eclipse source from CVS

You have to Checkout project from CVS Repository, refer to http://wiki.eclipse.org/CVS_Howto

ScreenShot2012-11-30at2.54.33PM-2012-11-30-14-53.png

Based on your workspace, you’ll have e4 directory that has many eclipse projects.

ScreenShot2012-11-30at3.00.13PM-2012-11-30-14-53.png

It’ll start building when you setup automatic build.

PastedGraphic1-2012-11-30-14-53.png

PastedGraphic-2012-11-30-14-53.png

2. Removing “API Baselines error”

After the automatic build, you may see a lot of “red !” and “red X” marks in some of the projects.

Refer to http://stackoverflow.com/questions/13650375/the-red-mark-after-the-build-in-eclipse. For your conveniences in debugging, you need to setup the filter. http://stackoverflow.com/a/13651021/260127

You’ll have “Adding API Baseline in eclipse” error.

http://stackoverflow.com/questions/13651144/adding-api-baseline-in-eclipse

You can remove all the errors by making “Missing API baseline” as warning.

PastedGraphic4-2012-11-30-14-53.png

3. Removing “Build path specifies execution environment J2SE-1.4” error

You may see “Build path specifies execution environment J2SE-1.4.” error in Mac OS X, it’s because some of the projects use JDK1.4, but the setup in the Mac is wrong.

http://stackoverflow.com/questions/13652032/build-path-specifies-execution-environment-j2se-1-4-error-in-eclipse

ScreenShot2012-11-30at1.35.53PM-2012-11-30-14-53.png

ScreenShot2012-11-30at2.32.59PM-2012-11-30-14-53.png

In eclipse Preference, you need to add Compatible JREs.

ScreenShot2012-11-30at12.46.32PM-2012-11-30-14-53.png

Check if you have Java SE correctly installed.

ScreenShot2012-11-30at1.39.46PM-2012-11-30-14-53.png

Then find all the projects with the “Build path specifies execution environment J2SE-1.4.” error.

PastedGraphic3-2012-11-30-14-53.png

Open the “Configure File Path”.

PastedGraphic2-2012-11-30-14-53.png

Replace the JRE System Library

ScreenShot2012-11-30at2.07.19PM-2012-11-30-14-53.png

with the one with you just setup.

ScreenShot2012-11-30at2.32.20PM-2012-11-30-14-53.png

Install Execution Environment Descriptor

http://stackoverflow.com/questions/13655635/installing-environment-descriptions-in-eclipse/13663453#13663453