0

I'm running Eclipse Kepler with Glassfish 4. I'm developing a set of bundles/plugins, which get deployed to the glassfish autodeploy folder. Also deployed to that folder are bundles from my target definition.

The problem is when debugging the source lookup for the bundles from the target doesn't work.

  • I have added the bundle pool directory to the source lookup to no avail.
  • I have added the glassfish autodeploy directory to the source lookup to no avail.

The source bundles are in both folders together with the "binary" bundles and they share the same name with the "binary" bundles except for "source", e.g.:

  • com.x.y.z_1.3.jar
  • com.x.y.z.source_1.3.jar

I can get Eclipse to recognize the source bundle correctly if instead of adding the directory I add the individual jar files. But this is cumbersome because then I have to add each jar file and also update the source lookup every time I update the target definition to a newer version.

Is there a way to make Eclipse find the correct source bundles?

Roland
  • 7,525
  • 13
  • 61
  • 124

2 Answers2

0

If you look in configure build path , you can add a class folder or add jars manually. Eclipse configure build path

You can use this plugin. It will dynamically use jars contained in a folder. http://benjchristensen.com/2011/05/26/dynamic-directory-of-jar-files-in-classpath-via-eclipse-plugin/

ogm
  • 379
  • 1
  • 8
  • My build path is fine. The problem is the source lookup. – Roland Mar 12 '14 at 15:59
  • Have you looked at the [eclipse documentation on source bundling](http://help.eclipse.org/indigo/index.jsp?topic=%2Forg.eclipse.pde.doc.user%2Ftasks%2Fpde_individual_source.htm) ? – ogm Mar 12 '14 at 17:17
  • I can lookup the source with no problem during *development*. But after deploying those bundles to the Glassfish folder the debugger doesn't find the sources anymore during *runtime*. – Roland Apr 25 '14 at 16:42
0

Did you try to "attach" the source folder, when right-clicking a jar of your classpath?

enter image description here

robermann
  • 1,722
  • 10
  • 19
  • 1
    Yes. The source is attached and I can browse it while developing. The problem is those jars then get deployed to the Glassfish server and so the source is not available during runtime. I need to configure the source lookup for runtime. – Roland Apr 25 '14 at 16:30