• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Junilu Lacar
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • Rob Spoor
  • Bear Bibeault
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Piet Souris
  • Carey Brown
  • Stephan van Hulst
Bartenders:
  • Frits Walraven
  • fred rosenberger
  • salvin francis

Sharing bean(s) between applicationContext-security.xml and dispatcher-servlet.xml **SOLVED**

 
Ranch Hand
Posts: 65
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
EDIT: This is solved but any other ideas are more than welcome

Hello,

I'm incorporating Spring Security into my application. My web.xml contains another contextConfigLocation called /WEB-INF/applicationContext-security.xml.

I have an existing xml configuration for my dispatcher servlet: dispatcher-servlet.xml. This includes configuration for a few DAO service beans.

The "issue" is that some beans defined in the security configuration need to be injected with DAO/service beans.

This is where my knowledge of these bean containers and contexts gets sketchy so I ask what is the best way to do this?

Thanks,

Ed

N.B. Also posted at springsource.org but didn't get a reply.
 
Edward Winchester
Ranch Hand
Posts: 65
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Have discovered the import tag:



Even though I will have two instances of the common beans, this fits my requirements (for now!).

Thanks,

Ed
 
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic