I've got a bunch of services and dao's in one project jar, and it contains an applicationContext that is mixed with the war project. I guess this means that the beans in the webapp (or their programmers) could just ignore the service beans and start futzing with the dao's directly.
How do I stop this? How do I expose the service beans to the webapp, but not the DAOs. Note: some daos are known by multiple services , so I can't just make them anonymous in the service definition.
Is there a way to enforce that a bean in that xml file is *only* used in that xml file?