using Eclipse Helios, and the Spring Source Tool Suite 2.8.1.201111221000-RELEASE, having two Eclipse projects with a Spring nature added, the second depending on the first - is there a way to add Spring bean configuration files from both projects to the "Spring/Bean Support" configuration of the second project?
In detail, say
- project A builds some
a.jar
, containing somemodule.xml
file, declaring some Spring beans implemented in A. - project B builds some
b.jar
, containing someapplication.xml
file, declaring the beans implemented in B - B's spring configuration references some beans which are declared in A's configuration
application.xml
does not importmodule.xml
, instead, at runtime anClassPathXmlApplicationContext
is created which loads (all) configurations files from the classpath which match a certain pattern (something like"classpath:application.xml","classpath*:module.xml"
)- B's spring nature is configured to use
application.xml
as config file (Project properties => Spring => Beans Support => Config Files)
What I want to do is to tell STS that B's spring configuration consists not only of B's application.xml
, but also of A's module.xml
. If A is not part of the workspace, but a.jar
is located in my Maven repo, with B declared to depend on that artifact, I can add the module.xml
config file to B's spring configuration. If, however, A is part of the workspace, referencing its module.xml
does not seem to be possible.
Do I miss something?
Thanks