Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Equinox » "Unresolved compilation problem" upon starting a bundle
"Unresolved compilation problem" upon starting a bundle [message #534752] Thu, 20 May 2010 08:49 Go to next message
Robert K. is currently offline Robert K.Friend
Messages: 14
Registered: July 2009
Junior Member
Hi,

I hope someone can me help to understand what is going wrong with my
Equinox installation:

Upon starting my bundle I get an error message that there is an "Unresolved
compilation problem: The method getData(String) of type MyServiceImpl must
override a superclass method."

The error message itself is clearly a Java profiles problem (Java prior to
v1.6 outputs that error if you mark an method that implements an interface
method with @Override). But that is not my problem - my bundle is developed
for Java 1.6 therefore this error is a "false positive".

My problem is that I do not understand why Equinox tries to re-compile my
bundle - all required .class files are included and in the bundle-classpath
(and there are no .java files in the bundle).
How can I tell Equinox just to load my bundle and don't touch the also
included Java files?

Jan
Re: "Unresolved compilation problem" upon starting a bundle [message #534844 is a reply to message #534752] Thu, 20 May 2010 13:35 Go to previous messageGo to next message
Thomas Watson is currently offline Thomas WatsonFriend
Messages: 503
Registered: July 2009
Senior Member
I am assuming you are using a Java or Plug-in project in Eclipse which contains your bundle manifest and the .class files as well as the .java files. If you are using a typical Java/Plug-in project then you likely have an src/ and an bin/ folder. If your Java project is setup to use the src/ folder as the source folder and the bin/ folder as the output folder then you will find that JDT will recompile the .class files

I suspect that is what is happening to you. But I am a bit confused why recompiling the classes would be an issue in your workspace. If you don't want to recompile the classes then why import the bundle content into the workspace at all. It seems like you really just want to run the bundle in "binary" jar form from your target.

Tom.
Re: "Unresolved compilation problem" upon starting a bundle [message #534858 is a reply to message #534844] Thu, 20 May 2010 13:48 Go to previous message
Robert K. is currently offline Robert K.Friend
Messages: 14
Registered: July 2009
Junior Member
Thomas Watson schrieb:

> I am assuming you are using a Java or Plug-in project in Eclipse which
> contains your bundle manifest and the .class files as well as the .java
> files. If you are using a typical Java/Plug-in project then you likely
> have an src/ and an bin/ folder. If your Java project is setup to use
> the src/ folder as the source folder and the bin/ folder as the output
> folder then you will find that JDT will recompile the .class files

Yes, I have three plugin projects but they will be automatically
"bundelized" via PaxRunner before starting the OSGi environment.

I just found out that the error is caused by Eclipse which does not respect
the project configuration in such a case. After setting the overall Eclipse
compiler settings to Java 1.6 the error is gone.

> I suspect that is what is happening to you. But I am a bit confused why
> recompiling the classes would be an issue in your workspace. If you
> don't want to recompile the classes then why import the bundle content
> into the workspace at all. It seems like you really just want to run
> the bundle in "binary" jar form from your target.

I have about a dozen common binary bundles which are automatically
downloaded and installed into the OSGi environment via PaxRunner and three
plugin/bundle projects containing my code.

OSGI development (with Eclipse) is really a pain...
Previous Topic:Problems with headless build on 3.5
Next Topic:Multivalue VM arguments in config.ini
Goto Forum:
  


Current Time: Tue Apr 23 10:23:42 GMT 2024

Powered by FUDForum. Page generated in 0.03141 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top