Raymond Feng wrote:
> Hi,
> 
> I started to play with SDO2 APIs such as XSDHelper to deal with the
> XSD metadata for Type/Property and ran into some issues.
> 

<snip emf related stuff/>

> 
> 2) The helper provider discovery doesn't work very well in the
> Eclipse environment.
> 
> For exmaple, it searches for the first instance of
> "META-INF/services/commonj.sdo.impl.HelperProvider" file on the
> classpath to read the implementation class name. But the file appears
> twice in the "sdo.api" (src/test/resources) and "tuscany-sdo-impl"
> (src/main/resources). Depending on the order of the classpath
> setting, you may get wrong HelperProvider instances.
> 
> I think it's NOT a problem for the SDO case only. In our code
> structure, the test resources are always in the same project as the
> main resources. I assume it works fine in command-line with finer
> control of the classpath but not for the IDE. Does anybody have any
> creative ideas for the IDE folks?
> 

Won't Eclipse let you set up the classpath for the projects in such a
way that test classes and resources do not leak to other projects? If
the default maven-generated project isn't doing this, is there a way to
manually configure this (and then perhaps get the maven eclipse plugin
to generate it that way)?

If there is no work around for Eclipse, it should be possible to patch
the tests so that the test configuration does not include this file and
the tests work by using a custom classloader (like the TCCL tests do).
However, this is going to make the tests more complex than needed and
still won't solve the problem of classes leaking between projects.

--
Jeremy

Reply via email to